Containers
|
|
|
|
Containers data classes
- class cognite.client.data_classes.data_modeling.containers.BTreeIndex(
- state: Literal['current', 'failed', 'pending'],
- *,
- properties: list[str],
- cursorable: bool,
Bases:
IndexRead version of btree index with state information.
- as_apply() BTreeIndexApply
Return the write version of this index.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.BTreeIndexApply(properties: list[str], cursorable: bool = False)
Bases:
IndexApplyWrite version of btree index.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.Constraint(state: Literal['current', 'failed', 'pending'])
Bases:
ConstraintCore,ABCRead version of constraint with state information.
- class cognite.client.data_classes.data_modeling.containers.ConstraintApply
Bases:
ConstraintCore,ABCWrite version of constraint without state information.
- as_apply() ConstraintApply
Return this ConstraintApply instance.
- class cognite.client.data_classes.data_modeling.containers.ConstraintCore
Bases:
CogniteResource,ABCBase class for constraints with shared functionality.
- abstract as_apply() ConstraintApply
Return the write version of this constraint.
- abstract dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.Container(space: str, external_id: str, description: str | None = None, name: str | None = None, *, properties: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.ContainerProperty], constraints: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.Constraint] = <factory>, indexes: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.Index] = <factory>, is_global: bool, last_updated_time: int, created_time: int, used_for: ~typing.Literal['node', 'edge', 'record', 'all'])
Bases:
ContainerCoreRepresent the physical storage of data. This is the read format of the container
- Parameters:
space (str) – The workspace for the container, a unique identifier for the space.
external_id (str) – Combined with the space is the unique identifier of the container.
description (str | None) – Textual description of the container
name (str | None) – Human readable name for the container.
properties (Mapping[str, ContainerProperty]) – We index the property by a local unique identifier.
constraints (Mapping[str, Constraint]) – Set of constraints to apply to the container
indexes (Mapping[str, Index]) – Set of indexes to apply to the container.
is_global (bool) – Whether this is a global container, i.e., one of the out-of-the-box models.
last_updated_time (int) – The number of milliseconds since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.
created_time (int) – The number of milliseconds since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.
used_for (ContainerUsedFor) – Whether the container is for nodes, edges, records, or both nodes and edges (
all).
- class cognite.client.data_classes.data_modeling.containers.ContainerApply(space: str, external_id: str, properties: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.ContainerPropertyApply], description: str | None = None, name: str | None = None, constraints: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.ConstraintApply] = <factory>, indexes: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.IndexApply] = <factory>, used_for: ~typing.Literal['node', 'edge', 'record', 'all'] | None = None)
Bases:
ContainerCoreRepresent the physical storage of data. This is the write format of the container
- Parameters:
space (str) – The workspace for the container, a unique identifier for the space.
external_id (str) – Combined with the space is the unique identifier of the container.
properties (Mapping[str, ContainerPropertyApply]) – We index the property by a local unique identifier.
description (str | None) – Textual description of the container
name (str | None) – Human readable name for the container.
constraints (Mapping[str, ConstraintApply]) – Set of constraints to apply to the container
indexes (Mapping[str, IndexApply]) – Set of indexes to apply to the container.
used_for (ContainerUsedFor | None) – Whether the container is for nodes, edges, records, or both nodes and edges (
all).
- as_write() ContainerApply
Returns this ContainerApply instance.
- class cognite.client.data_classes.data_modeling.containers.ContainerApplyList(
- resources: Sequence[T_CogniteResource],
Bases:
CogniteResourceList[ContainerApply]- as_ids() list[ContainerId]
Convert to a container id list.
- Returns:
The container id list.
- Return type:
list[ContainerId]
- class cognite.client.data_classes.data_modeling.containers.ContainerCore(space: str, external_id: str, properties: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.ContainerPropertyCore], description: str | None = None, name: str | None = None, constraints: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.ConstraintCore] = <factory>, indexes: ~collections.abc.Mapping[str, ~cognite.client.data_classes.data_modeling.containers.IndexCore] = <factory>)
Bases:
DataModelingSchemaResource[ContainerApply],ABCRepresent the physical storage of data. This is the base class for the read and write version.
- Parameters:
space (str) – The workspace for the container, a unique identifier for the space.
external_id (str) – Combined with the space is the unique identifier of the container.
properties (Mapping[str, ContainerPropertyCore]) – We index the property by a local unique identifier.
description (str | None) – Textual description of the container
name (str | None) – Human readable name for the container.
constraints (Mapping[str, ConstraintCore]) – Set of constraints to apply to the container
indexes (Mapping[str, IndexCore]) – Set of indexes to apply to the container.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.ContainerList(
- resources: Sequence[T_CogniteResource],
Bases:
WriteableCogniteResourceList[ContainerApply,Container]- as_apply() ContainerApplyList
Convert to a ContainerApply list.
- Returns:
The container apply list.
- Return type:
- as_ids() list[ContainerId]
Convert to a container id list.
- Returns:
The container id list.
- Return type:
list[ContainerId]
- class cognite.client.data_classes.data_modeling.containers.ContainerProperty(
- type: ~cognite.client.data_classes.data_modeling.data_types.PropertyType,
- nullable: bool = True,
- auto_increment: bool = False,
- name: str | None = None,
- default_value: str | int | float | bool | dict | None = None,
- description: str | None = None,
- immutable: bool = False,
- constraint_state: ~cognite.client.data_classes.data_modeling.containers.PropertyConstraintState = <factory>,
Bases:
ContainerPropertyCoreRead version of container property with state information.
- as_apply() ContainerPropertyApply
Return the write version of this property.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.ContainerPropertyApply(
- type: PropertyType,
- nullable: bool = True,
- auto_increment: bool = False,
- name: str | None = None,
- default_value: str | int | float | bool | dict | None = None,
- description: str | None = None,
- immutable: bool = False,
Bases:
ContainerPropertyCoreWrite version of container property.
- as_apply() ContainerPropertyApply
Return this ContainerPropertyApply instance.
- class cognite.client.data_classes.data_modeling.containers.ContainerPropertyCore(
- type: PropertyType,
- nullable: bool = True,
- auto_increment: bool = False,
- name: str | None = None,
- default_value: str | int | float | bool | dict | None = None,
- description: str | None = None,
- immutable: bool = False,
Bases:
CogniteResource,ABCBase class for container properties with shared functionality.
- abstract as_apply() ContainerPropertyApply
Return the write version of this property.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.Index(state: Literal['current', 'failed', 'pending'])
Bases:
IndexCore,ABCRead version of index with state information.
- class cognite.client.data_classes.data_modeling.containers.IndexApply
Bases:
IndexCore,ABCWrite version of index without state information.
- as_apply() IndexApply
Return this IndexApply instance.
- class cognite.client.data_classes.data_modeling.containers.IndexCore
Bases:
CogniteResource,ABCBase class for indexes with shared functionality.
- abstract as_apply() IndexApply
Return the write version of this index.
- abstract dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.InvertedIndex(
- state: Literal['current', 'failed', 'pending'],
- *,
- properties: list[str],
Bases:
IndexRead version of inverted index with state information.
- as_apply() InvertedIndexApply
Return the write version of this index.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.InvertedIndexApply(properties: list[str])
Bases:
IndexApplyWrite version of inverted index.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.PropertyConstraintState(
- nullability: "Literal['current', 'failed', 'pending'] | None" = None,
- max_list_size: "Literal['current', 'failed', 'pending'] | None" = None,
- max_text_size: "Literal['current', 'failed', 'pending'] | None" = None,
Bases:
CogniteResource- dump(camel_case: bool = True) dict[str, str]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.RequiresConstraint(
- state: Literal['current', 'failed', 'pending'],
- *,
- require: ContainerId,
Bases:
ConstraintRead version of requires constraint with state information.
- as_apply() RequiresConstraintApply
Return the write version of this constraint.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.RequiresConstraintApply(
- require: ContainerId,
Bases:
ConstraintApplyWrite version of requires constraint.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.UniquenessConstraint(
- state: Literal['current', 'failed', 'pending'],
- properties: list[str],
Bases:
ConstraintRead version of uniqueness constraint with state information.
- as_apply() UniquenessConstraintApply
Return the write version of this constraint.
- dump(camel_case: bool = True) dict[str, Any]
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]
- class cognite.client.data_classes.data_modeling.containers.UniquenessConstraintApply(properties: list[str])
Bases:
ConstraintApplyWrite version of uniqueness constraint.
- dump(
- camel_case: bool = True,
Dump the instance into a json serializable Python data type.
- Parameters:
camel_case (bool) – Use camelCase for attribute names. Defaults to True.
- Returns:
A dictionary representation of the instance.
- Return type:
dict[str, Any]