cwl_utils.types
Shared Python type definitions for commons JSON like CWL objects.
Attributes
Classes
dict() -> new empty dictionary |
|
dict() -> new empty dictionary |
|
dict() -> new empty dictionary |
Functions
|
|
|
|
|
|
|
|
|
Module Contents
- cwl_utils.types.built_in_types: list[str] = ['null', 'boolean', 'int', 'long', 'float', 'double', 'string', 'File', 'Directory', 'stdin',...
- cwl_utils.types.CWLDirectoryType
- cwl_utils.types.CWLFileType
- type cwl_utils.types.CWLOutputType = bool | str | int | float | CWLFileType | CWLDirectoryType | MutableSequence['CWLOutputType | None'] | MutableMapping[str, 'CWLOutputType | None']
- type cwl_utils.types.CWLObjectType = MutableMapping[str, CWLOutputType | None]
- type cwl_utils.types.SinkType = CWLOutputType | CWLObjectType
- class cwl_utils.types.CWLRuntimeParameterContext
Bases:
TypedDict
dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object’s
(key, value) pairs
- dict(iterable) -> new dictionary initialized as if via:
d = {} for k, v in iterable:
d[k] = v
- dict(**kwargs) -> new dictionary initialized with the name=value pairs
in the keyword argument list. For example: dict(one=1, two=2)
- class cwl_utils.types.CWLParameterContext
Bases:
TypedDict
dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object’s
(key, value) pairs
- dict(iterable) -> new dictionary initialized as if via:
d = {} for k, v in iterable:
d[k] = v
- dict(**kwargs) -> new dictionary initialized with the name=value pairs
in the keyword argument list. For example: dict(one=1, two=2)
- inputs: CWLObjectType
- self: CWLOutputType | None
- runtime: CWLRuntimeParameterContext
- class cwl_utils.types.DirentType
Bases:
TypedDict
dict() -> new empty dictionary dict(mapping) -> new dictionary initialized from a mapping object’s
(key, value) pairs
- dict(iterable) -> new dictionary initialized as if via:
d = {} for k, v in iterable:
d[k] = v
- dict(**kwargs) -> new dictionary initialized with the name=value pairs
in the keyword argument list. For example: dict(one=1, two=2)
- cwl_utils.types.is_cwl_parameter_context_key(key)
- Parameters:
key (Any)
- Return type:
TypeGuard[Literal[‘inputs’, ‘self’, ‘runtime’]]
- cwl_utils.types.is_directory(value)
- Parameters:
value (Any)
- Return type:
TypeIs[CWLDirectoryType]
- cwl_utils.types.is_directory_key(key)
- Parameters:
key (Any)
- Return type:
TypeGuard[Literal[‘class’, ‘location’, ‘path’, ‘basename’, ‘listing’]]
- cwl_utils.types.is_file(value)
- Parameters:
value (Any)
- Return type:
TypeIs[CWLFileType]
- cwl_utils.types.is_file_key(key)
- Parameters:
key (Any)
- Return type:
TypeGuard[Literal[‘class’, ‘location’, ‘path’, ‘basename’, ‘dirname’, ‘nameroot’, ‘nameext’, ‘checksum’, ‘size’, ‘secondaryFiles’, ‘format’, ‘contents’]]
- cwl_utils.types.is_file_or_directory(value)
- Parameters:
value (Any)
- Return type:
TypeIs[CWLFileType | CWLDirectoryType]