graviti.portex.external#

Portex external base class.

Module Contents#

Classes#

PortexExternalType

The base class of Portex external type.

Attributes#

graviti.portex.external.EXTERNAL_TYPE_TO_CONTAINER[source]#
class graviti.portex.external.PortexExternalType(*args, **kwargs)[source]#

Bases: graviti.portex.base.PortexType

The base class of Portex external type.

Parameters
  • args (Any) –

  • kwargs (Any) –

property internal_type(self)[source]#

Get the internal type of the PortexExternalType.

Returns

The internal type of the PortexExternalType.

Return type

graviti.portex.base.PortexType

to_pyarrow(self)[source]#

Convert the Portex type to the corresponding builtin PyArrow DataType.

Returns

The corresponding builtin PyArrow DataType.

Return type

pyarrow.DataType

to_builtin(self)[source]#

Expand the top level of the Portex external type to Portex builtin type.

Returns

The expanded Portex builtin type.

Return type

graviti.portex.builtin.PortexBuiltinType

get_keys(self, type_name=None)[source]#

Get the keys to locate all data, or only get keys of one type if type_name is given.

Parameters

type_name (Optional[str]) – The name of the target PortexType.

Returns

A list of keys to locate the data.

Return type

List[Tuple[str, Ellipsis]]