ADTF  3.12.8
EditorPluginBase
Inheritance diagram for EditorPluginBase:

Signals

void execute ()
 type:void is called when the editor is loaded by the ADTF Configuration Editor
 

Public Member Functions

void findService (string name)
 Search for a configured service in the .adtfsystem file. More...
 
void findProperty (object component, string name)
 Search for a property in a component. More...
 
void findPropertyDescription (object component, string name)
 Search for a property description in a component. More...
 
void createProperty (object component, string name, string value, string type, string link)
 Create a new property for the given component. More...
 
void setProperty (object component, string name, string value)
 Set the value of a property. More...
 
void getPropertyValue (object component, string name)
 Get property value from properties file if the property exists else from the property description. More...
 
void findInputPin (string name)
 Search for a input pin in the selected filter or streaming Service. More...
 
void createInputPin (string name)
 Create a new input pin in the selected filter or streaming Service. More...
 
void listInputPins ()
 List input pin names. More...
 
void removeInputPin (object pin)
 Remove a input pin. More...
 
void findOutputPin (string name)
 Search for a output pin in the selected filter or streaming Service. More...
 
void createOutputPin (string name)
 Create a new output pin in the selected filter or streaming Service. More...
 
void listOutputPins ()
 List output pin names. More...
 
void removeOutputPin (object pin)
 Remove a output pin. More...
 
void listRunner ()
 List runner names. More...
 
void findRunner (string runnerName)
 Search for a runner in the selected filter or streaming Service. More...
 
void createRunner (string name)
 Create a new runner in the selected filter or streaming Service. More...
 
void removeRunner (object runner)
 Remove a runner. More...
 
void resolveAndGetAbsoluteUrl (string path, string basePath)
 Resolve macros in a path and convert it to an absolute path based on the given basePath. More...
 
void getPropertyFile ()
 Get .adtfproperty file path. More...
 
void launch (string command, string args, string workingDirectory)
 Launchs a executable from the configuration editor. More...
 
void parseJsonResult (string result)
 Parse the result of the executable. More...
 
void forEach (array array, function callback)
 iterate over an array and execute given callback on each element More...
 
void removeFromArray (array array, function callback)
 iterate over an array and remove elements if the callback results in false More...
 
void contains (array array, any value, function compare_callback)
 iterate over an array and cheack if a specific value is in the array More...
 

Properties

var filenameHelper
 for downward compatibility filenameHelper was once an instance now it is just a property pointing to the singleton FilenameHelper
 
object targetModel
 The model representing the filter this editor belongs to.
 
object commandCallback
 An object which gives acces to the configuration editor command functions.
 
object editorDescription
 The editor description.
 
object dialogManager
 The dialogManager can be used to open dialogs from within the filter editor.
 

Private Attributes

var Component onCompleted
 

Detailed Description

This qml class can be used as basis to develop your own filter or streaming service editors embedded in the ADTF Configuration Editor. The intended use case would be to derive from this class and implement your own ui and the corresponding logic in your class based on the functionality provided by this class.

Definition at line 23 of file EditorPluginBase.qml.

Member Function Documentation

◆ contains()

void contains ( array  array,
any  value,
function  compare_callback 
)

iterate over an array and cheack if a specific value is in the array

Parameters
arrayThe array to check for given value
valueThe comparison value
compare_callbackThe callback to execute on each element to do more complex comparing
Returns
true or false

◆ createInputPin()

void createInputPin ( string  name)

Create a new input pin in the selected filter or streaming Service.

Parameters
nameName of the pin

◆ createOutputPin()

void createOutputPin ( string  name)

Create a new output pin in the selected filter or streaming Service.

Parameters
nameName of the pin

◆ createProperty()

void createProperty ( object  component,
string  name,
string  value,
string  type,
string  link 
)

Create a new property for the given component.

Parameters
componentThe component
nameThe new property name
valueThe new value of the property
typeIf specified the function creates a dynamicProperty but only if the property does not exist in the plugindescription
linkIf specified the property will be linked to the given graph property possible values are for exammple "cString", "tInt", "tFloat", "tFilename", ...

◆ createRunner()

void createRunner ( string  name)

Create a new runner in the selected filter or streaming Service.

Parameters
nameName of the runner

◆ findInputPin()

void findInputPin ( string  name)

Search for a input pin in the selected filter or streaming Service.

Parameters
nameName of the pin
Returns
The pin if found, else null

◆ findOutputPin()

void findOutputPin ( string  name)

Search for a output pin in the selected filter or streaming Service.

Parameters
nameName of the pin
Returns
The pin if found, else null

◆ findProperty()

void findProperty ( object  component,
string  name 
)

Search for a property in a component.

A component could be a Filter, a streaming service or a service

Parameters
componentModel of a filter, a streaming service or a service
nameThe name of the property
Returns
The property if found, else null

◆ findPropertyDescription()

void findPropertyDescription ( object  component,
string  name 
)

Search for a property description in a component.

A component could be a Filter, a streaming service or a service

Parameters
componentModel of a filter, a streaming service or a service
nameThe name of the property
Returns
The property description if found, else null

◆ findRunner()

void findRunner ( string  runnerName)

Search for a runner in the selected filter or streaming Service.

Parameters
runnerNameName of the runner
Returns
The runner if found, else null

◆ findService()

void findService ( string  name)

Search for a configured service in the .adtfsystem file.

Parameters
nameName of the service
Returns
The service if found otherwise null

◆ forEach()

void forEach ( array  array,
function  callback 
)

iterate over an array and execute given callback on each element

Parameters
arrayThe array to iterate
callbackThe callback to execute on each element

◆ getPropertyFile()

void getPropertyFile ( )

Get .adtfproperty file path.

Returns
url to file

◆ getPropertyValue()

void getPropertyValue ( object  component,
string  name 
)

Get property value from properties file if the property exists else from the property description.

Parameters
componentThe component
nameThe property name
Returns
The property value if found, else an empty string

◆ launch()

void launch ( string  command,
string  args,
string  workingDirectory 
)

Launchs a executable from the configuration editor.

Parameters
commandThe path to the executable
argsSome arguments (default: "")
workingDirectoryThe working directory (default: "") If empty the working directory will be the current working directory
Returns
the content as type:string of the std::out or std::error depending on the successful startup of the process

◆ listInputPins()

void listInputPins ( )

List input pin names.

Returns
Array with all input pins

◆ listOutputPins()

void listOutputPins ( )

List output pin names.

Returns
Array with all output pins

◆ listRunner()

void listRunner ( )

List runner names.

Returns
Array with all runner names

◆ parseJsonResult()

void parseJsonResult ( string  result)

Parse the result of the executable.

Searching a json string surrounded by json_result:(.*):end and converts it to an javascript object

Parameters
resultResult of the executable (see launch)
Returns
A javascript object

◆ removeFromArray()

void removeFromArray ( array  array,
function  callback 
)

iterate over an array and remove elements if the callback results in false

Parameters
arrayThe array to remove elements from
callbackThe callback to execute on each element

◆ removeInputPin()

void removeInputPin ( object  pin)

Remove a input pin.

Parameters
pinThe pin to be removed

◆ removeOutputPin()

void removeOutputPin ( object  pin)

Remove a output pin.

Parameters
pinThe pin to be removed

◆ removeRunner()

void removeRunner ( object  runner)

Remove a runner.

Parameters
runnerThe runner to be removed

◆ resolveAndGetAbsoluteUrl()

void resolveAndGetAbsoluteUrl ( string  path,
string  basePath 
)

Resolve macros in a path and convert it to an absolute path based on the given basePath.

If the given basePath is not set, it will be resolved from the path, where the plugin description has been saved to and this editor is used for.

Parameters
pathPath to be resolved
basePathPath to resolve relative paths default is (".")
Returns
a string containing the resolved path

◆ setProperty()

void setProperty ( object  component,
string  name,
string  value 
)

Set the value of a property.

Parameters
componentThe component
nameThe property name
valueThe value of the property

Copyright © Audi Electronics Venture GmbH. All rights reserved. (Generated on Thu Aug 19 2021 by doxygen 1.8.14)