pypz.core.specs.dtos module

class pypz.core.specs.dtos.InstanceDTO(name: str = None, parameters: dict = None, dependsOn: list[str] = None, spec: SpecDTO = None)

Bases: object

This class represents the base Data Transfer Object for an instance. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the instance

  • parameters – parameters of the instance

  • dependsOn – list of instances that this instance depends on

class pypz.core.specs.dtos.OperatorConnection(inputPortName: str = None, source: dict | OperatorConnectionSource = None)

Bases: object

This class represents the base Data Transfer Object for a connection between operator instances. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • inputPortName – name of the input port of the connection

  • source – source DTO of the connection

class pypz.core.specs.dtos.OperatorConnectionSource(instanceName: str = None, outputPortName: str = None)

Bases: object

This class represents the base Data Transfer Object for the source of a connection between operator instances. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • instanceName – name of the source instance

  • outputPortName – name of the output port in the source instance

class pypz.core.specs.dtos.OperatorInstanceDTO(name: str = None, parameters: dict = None, dependsOn: list[str] = None, spec: OperatorSpecDTO = None, connections: list[OperatorConnection] = None)

Bases: InstanceDTO

This class represents the base Data Transfer Object for an operator instance. Operator instances have additional instance information that shall be modelled via the DTO e.g., since Operator instances can be connected through port plugins, those connections shall be modelled as well.

Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the instance

  • parameters – parameters of the instance

  • dependsOn – list of instances that this instance depends on

class pypz.core.specs.dtos.OperatorSpecDTO(name: str = None, location: str = None, expectedParameters: dict = None, types: list = None, nestedInstanceType: str = None, nestedInstances: list[PluginInstanceDTO] = None)

Bases: SpecDTO

This class represents the Data Transfer Object for an operator spec. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the specs

  • location – the location of the spec to retrieve it from

  • expectedParameters – the expected parameters by the spec

  • types – the implemented types of the spec

  • nestedInstanceType – the expected type of the nested instances

  • nestedInstances – the list of the actual nested instances

class pypz.core.specs.dtos.PipelineInstanceDTO(name: str = None, parameters: dict = None, dependsOn: list[str] = None, spec: PipelineSpecDTO = None)

Bases: InstanceDTO

This class represents the base Data Transfer Object for a pipeline instance. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the instance

  • parameters – parameters of the instance

  • dependsOn – list of instances that this instance depends on

class pypz.core.specs.dtos.PipelineSpecDTO(name: str = None, location: str = None, expectedParameters: dict = None, types: list = None, nestedInstanceType: str = None, nestedInstances: list[OperatorInstanceDTO] = None)

Bases: SpecDTO

This class represents the Data Transfer Object for a pipeline spec. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the specs

  • location – the location of the spec to retrieve it from

  • expectedParameters – the expected parameters by the spec

  • types – the implemented types of the spec

  • nestedInstanceType – the expected type of the nested instances

  • nestedInstances – the list of the actual nested instances

class pypz.core.specs.dtos.PluginInstanceDTO(name: str = None, parameters: dict = None, dependsOn: list[str] = None, spec: PluginSpecDTO = None)

Bases: InstanceDTO

This class represents the base Data Transfer Object for a plugin instance. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the instance

  • parameters – parameters of the instance

  • dependsOn – list of instances that this instance depends on

class pypz.core.specs.dtos.PluginSpecDTO(name: str = None, location: str = None, expectedParameters: dict = None, types: list = None, nestedInstanceType: str = None, nestedInstances: list = None)

Bases: SpecDTO

This class represents the Data Transfer Object for a plugin spec. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the specs

  • location – the location of the spec to retrieve it from

  • expectedParameters – the expected parameters by the spec

  • types – the implemented types of the spec

  • nestedInstanceType – the expected type of the nested instances

  • nestedInstances – the list of the actual nested instances

class pypz.core.specs.dtos.SpecDTO(name: str = None, location: str = None, expectedParameters: dict = None, types: list = None, nestedInstanceType: str = None, nestedInstances: list[NestedInstanceDTOType] = None, nested_instance_dto_type: Type[NestedInstanceDTOType] | str | None = 'default')

Bases: object

This class represents the base Data Transfer Object for an instance spec. Note that using the coding language as analogy, the instance spec is like a class, where the instance itself is like the object created from the class. If we want to transfer the instance spec remotely, we need to convert it into this DTO representation. This class acts as base for every other specs.

Note

Notice that the names of the attributes and ctor arguments will be used for serialization, hence those are not following python’s format guidelines.

Parameters:
  • name – name of the specs

  • location – the location of the spec to retrieve it from

  • expectedParameters – the expected parameters by the spec

  • types – the implemented types of the spec

  • nestedInstanceType – the expected type of the nested instances

  • nestedInstances – the list of the actual nested instances

  • nested_instance_dto_type – helper to specify the nested DTO type