Operator Reference

serialize_tupleT_serialize_tupleSerializeTupleSerializeTupleserialize_tuple (Operator)

serialize_tupleT_serialize_tupleSerializeTupleSerializeTupleserialize_tuple — Serialize a tuple.

Signature

serialize_tuple( : : Tuple : SerializedItemHandle)

Herror T_serialize_tuple(const Htuple Tuple, Htuple* SerializedItemHandle)

void SerializeTuple(const HTuple& Tuple, HTuple* SerializedItemHandle)

HSerializedItem HTuple::SerializeTuple() const

static void HOperatorSet.SerializeTuple(HTuple tuple, out HTuple serializedItemHandle)

HSerializedItem HTuple.SerializeTuple()

def serialize_tuple(tuple: HTupleType) -> HHandle

Description

serialize_tupleserialize_tupleSerializeTupleSerializeTupleserialize_tuple serializes the data of a tuple (see fwrite_serialized_itemfwrite_serialized_itemFwriteSerializedItemFwriteSerializedItemfwrite_serialized_item for an introduction of the basic principle of serialization). The same data that is written in a file by write_tuplewrite_tupleWriteTupleWriteTuplewrite_tuple is converted to a serialized item. The tuple is defined by the handle TupleTupleTupletupletuple. The serialized data of a tuple is returned by the handle SerializedItemHandleSerializedItemHandleSerializedItemHandleserializedItemHandleserialized_item_handle and can be deserialized by deserialize_tupledeserialize_tupleDeserializeTupleDeserializeTupledeserialize_tuple.

Note that not all handle types can be serialized. If TupleTupleTupletupletuple contains a handle that can not be serialized or that has been freed already, an exception is raised. The operators tuple_is_serializabletuple_is_serializableTupleIsSerializableTupleIsSerializabletuple_is_serializable and tuple_is_serializable_elemtuple_is_serializable_elemTupleIsSerializableElemTupleIsSerializableElemtuple_is_serializable_elem can be used to find out if a tuple or its elements can be serialized.

Execution Information

  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).
  • Multithreading scope: global (may be called from any thread).
  • Processed without parallelization.

Parameters

TupleTupleTupletupletuple (input_control)  tuple(-array) HTupleHTupleTypeHTupleHtuple (real / integer / string / handle) (double / int / long / string / HHandle) (double / Hlong / HString / HHandle) (double / Hlong / char* / handle)

Tuple.

SerializedItemHandleSerializedItemHandleSerializedItemHandleserializedItemHandleserialized_item_handle (output_control)  serialized_item HSerializedItem, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the serialized item.

Result

If the parameters are valid, the operator serialize_tupleserialize_tupleSerializeTupleSerializeTupleserialize_tuple returns the value 2 ( H_MSG_TRUE) . If necessary, an exception is raised.

Possible Successors

fwrite_serialized_itemfwrite_serialized_itemFwriteSerializedItemFwriteSerializedItemfwrite_serialized_item, send_serialized_itemsend_serialized_itemSendSerializedItemSendSerializedItemsend_serialized_item, deserialize_tupledeserialize_tupleDeserializeTupleDeserializeTupledeserialize_tuple

Module

Foundation