TaskModel
Task model class.
:property input_specs: The specs of the input :type input_specs: dict :property output_specs: The specs of the output :type output_specs: dict :property config_specs: The specs of the config :type config_specs: dict
community_agent_version_id: strcommunity_agent_version_modified: boolconfig: Configdata: Dict[str, Any]error_info: ProcessErrorInfoparent_protocol_id: strprogress_bar: ProgressBarscenario: Scenariosource_config_id: strstatus: ProcessStatusstyle: TypingStyleConstructor
Return true if the process can be auto run now.
boolbool - Truebool - Truebool - FalsestrboolOptional[ProcessErrorInfo]Return the execution time of the process
floatreturn the instance name in the context
strReturn the instance path
strReturn the last message of the process
Optional[ProgressBarMessageDTO]Return the name of the process
strType[Process]Optional[Typing]Return the last message of the process
floatReturns the port of the inputs by its name.
strInPortReturn true if the process is automatically run when added to a protocol
boolReturn true if the process is enable in sub protocol
boolreturn true if the process is of type InputTask
boolreturn true if the process is of type OutputTask
boolboolboolReturns True if the model is saved in db, False otherwise
boolProcessErrorInfoProcessRunExceptionstrReturns the port of the outputs by its name.
strOutPortCheck if the process typing exists
boolModelTypeRun the process and save its state in the database.
Override save to save the inputs and outputs
'ProcessModel'Function to run overrided by the sub classes
TaskModelMethod run just before the task run to save the input resource for this task. this will allow to know what resource this task uses as input
Save the process run stat. If it's a autorun process, it doesnt save.
Set the config
ConfigSet a value of the config
strAnySet the config values
DictProcessErrorInfoSet the inputs from a DTO
IODTObool - FalseSet the inputs from specs
IOSpecsSet the outputs from a DTO
IODTObool - FalseSet the outputs from specs
IOSpecsSets the parent protocol of the process
ProtocolModelMethod used when creating a new task model, it init the input and output from task specs
TypeScenarioReturn the config DTO
bool - FalseProcessConfigDTOReturn the minium json to recognize this process
ProcessMinimumDTOAnyCreate the foreign keys because it was deffered
Method call after the table is created
Usefull to create the full text indexes
AnyAnybool - Truebool - TrueAnyAnybool - Truebool - TrueAnyAnyAnyAnyAnyReturns the name of the class
bool - Falsebool - Falsebool - FalsestrReturns True if the column exists in the table
strboolAnyCreate a foreign key for a Foreign key field only if the foreign key does not exists
ForeignKeyFieldMethod to create a full text index
ListstrCreate model table
AnyDrop model table
Execute a raw SQL query. Can use the [TABLE_NAME] to replace by the table name
strAnyAnystrboolReturns the full name of the class
bool - Falsebool - FalsestrAnyAnystrOptionalGet by ID and throw 404 error if object not found
strModelTypeListListGet all the processes by parent protocol id
strList['ProcessModel']DatabaseProxyReturns the (current) DbManager of this model
TypeAnyAnyReturn all the Input task Model of the scenario
ListModelSelectReturns the table name of this class
strAnyReturns True if the index exists in the table
strboolGet all the classes that inherit this class
ListAnyAnyAnyAnyAnyAnyAnyAnyAnyAnyAnyAnyPerforms full-text search on the field. Must be overrided by child class to work
strstrModelSelectAnyAnyAnyAnyAnyAnyAny