get_dict_tupleT_get_dict_tupleGetDictTupleGetDictTupleget_dict_tuple (Operator)

Name

get_dict_tupleT_get_dict_tupleGetDictTupleGetDictTupleget_dict_tuple — Zurückgeben der in einem Dictionary über einen Schüssel referenzierten Tupeldaten.

Signatur

get_dict_tuple( : : DictHandle, Key : Tuple)

Herror T_get_dict_tuple(const Htuple DictHandle, const Htuple Key, Htuple* Tuple)

void GetDictTuple(const HTuple& DictHandle, const HTuple& Key, HTuple* Tuple)

HTuple HDict::GetDictTuple(const HTuple& Key) const

HTuple HDict::GetDictTuple(const HString& Key) const

HTuple HDict::GetDictTuple(const char* Key) const

HTuple HDict::GetDictTuple(const wchar_t* Key) const   (Nur Windows)

static void HOperatorSet.GetDictTuple(HTuple dictHandle, HTuple key, out HTuple tuple)

HTuple HDict.GetDictTuple(HTuple key)

HTuple HDict.GetDictTuple(string key)

def get_dict_tuple(dict_handle: HHandle, key: Union[str, int]) -> Sequence[Union[int, float, str]]

def get_dict_tuple_s(dict_handle: HHandle, key: Union[str, int]) -> Union[int, float, str]

Beschreibung

get_dict_tupleget_dict_tupleGetDictTupleGetDictTupleGetDictTupleget_dict_tuple fragt aus dem Dictionary DictHandleDictHandleDictHandleDictHandledictHandledict_handle die mit einem Schlüssel KeyKeyKeyKeykeykey assoziierten Tupeldaten TupleTupleTupleTupletupletuple ab. Die Tupeldaten müssen zuvor mit Hilfe des Operators set_dict_tupleset_dict_tupleSetDictTupleSetDictTupleSetDictTupleset_dict_tuple in dem Dictionary abgespeichert worden sein.

Falls der spezifizierte Schlüssel KeyKeyKeyKeykeykey nicht in dem Dictionary hinterlegt ist oder der mit ihm verbundene Eintrag kein Datentupel sondern ein ikonisches Objekt ist, schlägt get_dict_tupleget_dict_tupleGetDictTupleGetDictTupleGetDictTupleget_dict_tuple fehl. Die gespeicherten Schlüssel und die Information über die von ihnen referenzierten Daten kann über den Operator get_dict_paramget_dict_paramGetDictParamGetDictParamGetDictParamget_dict_param abgefragt werden.

Ausführungsinformationen

Parameter

DictHandleDictHandleDictHandleDictHandledictHandledict_handle (input_control)  dict HDict, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle des Dictionaries.

Parameteranzahl: DictHandle == 1

KeyKeyKeyKeykeykey (input_control)  string HTupleUnion[str, int]HTupleHtuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong)

Schlüssel.

Parameteranzahl: Key == 1

Restriktion: length(Key) > 0

TupleTupleTupleTupletupletuple (output_control)  tuple(-array) HTupleSequence[Union[int, float, str]]HTupleHtuple (string / integer / real) (string / int / long / double) (HString / Hlong / double) (char* / Hlong / double)

Vom Schlüssel referenzierte Tupeldaten.

Beispiel (HDevelop)

* ...
get_dict_param (Dict, 'key_exists', ['simple_string','foo','my_image'], \
                KeysPresence)
get_dict_param (Dict, 'key_data_type', ['simple_string','my_image'], \
                KeysType)
get_dict_tuple (Dict, 'simple_string', TupleString)

Ergebnis

Im Erfolgsfall gibt get_dict_tupleget_dict_tupleGetDictTupleGetDictTupleGetDictTupleget_dict_tuple den Wert TRUE zurück. Andernfalls wird eine Fehlerbehandlung durchgeführt. Mögliche Fehler sind ungültige Parameter (Dictionary oder Schlüssel), Abwesenheit des Schlüssels in dem Dictionary oder wenn der Schüssel andere Datentypen als ein Datentupel referenziert.

Vorgänger

set_dict_tupleset_dict_tupleSetDictTupleSetDictTupleSetDictTupleset_dict_tuple

Nachfolger

get_dict_tupleget_dict_tupleGetDictTupleGetDictTupleGetDictTupleget_dict_tuple

Alternativen

get_dict_objectget_dict_objectGetDictObjectGetDictObjectGetDictObjectget_dict_object

Siehe auch

create_dictcreate_dictCreateDictCreateDictCreateDictcreate_dict, set_dict_tupleset_dict_tupleSetDictTupleSetDictTupleSetDictTupleset_dict_tuple, set_dict_objectset_dict_objectSetDictObjectSetDictObjectSetDictObjectset_dict_object, get_dict_objectget_dict_objectGetDictObjectGetDictObjectGetDictObjectget_dict_object, remove_dict_keyremove_dict_keyRemoveDictKeyRemoveDictKeyRemoveDictKeyremove_dict_key, get_dict_paramget_dict_paramGetDictParamGetDictParamGetDictParamget_dict_param

Modul

Foundation