struct#

class jsonpolars.expr.struct.Struct(type: str = 'struct', expr: T_EXPR = Sentinel('REQUIRED'))[source]#

Ref: https://docs.pola.rs/api/python/stable/reference/expressions/struct.html

classmethod from_dict(dct: Dict[str, Any])[source]#

Construct an instance from dataclass-like data. It could be a dictionary, an instance of this class, or None.

class jsonpolars.expr.struct.StructField(type: str = 'struct_field', expr: Optional[T_EXPR] = None, name: Union[str, List[str]] = Sentinel('REQUIRED'))[source]#

Ref: https://docs.pola.rs/api/python/stable/reference/expressions/api/polars.Expr.struct.field.html

classmethod from_dict(dct: Dict[str, Any])[source]#

Construct an instance from dataclass-like data. It could be a dictionary, an instance of this class, or None.

class jsonpolars.expr.struct.StructRenameFields(type: str = 'struct_rename_fields', expr: T_EXPR = Sentinel('REQUIRED'), names: List[str] = Sentinel('REQUIRED'))[source]#

Ref: https://docs.pola.rs/api/python/stable/reference/expressions/api/polars.Expr.struct.rename_fields.html

classmethod from_dict(dct: Dict[str, Any])[source]#

Construct an instance from dataclass-like data. It could be a dictionary, an instance of this class, or None.

class jsonpolars.expr.struct.StructWithFields(type: str = 'struct_with_fields', expr: T_EXPR = Sentinel('REQUIRED'), exprs: ~typing.List[IntoExpr] = <factory>, named_exprs: ~typing.Dict[str, IntoExpr] = <factory>)[source]#

Ref: https://docs.pola.rs/api/python/stable/reference/expressions/api/polars.Expr.struct.with_fields.html

classmethod from_dict(dct: Dict[str, Any])[source]#

Construct an instance from dataclass-like data. It could be a dictionary, an instance of this class, or None.