get_handle_paramT_get_handle_paramGetHandleParamGetHandleParamget_handle_param (Operator)

Name

get_handle_paramT_get_handle_paramGetHandleParamGetHandleParamget_handle_param — Return information about a handle.

Signature

get_handle_param( : : Handle, GenParamName, Key : GenParamValue)

Herror T_get_handle_param(const Htuple Handle, const Htuple GenParamName, const Htuple Key, Htuple* GenParamValue)

void GetHandleParam(const HTuple& Handle, const HTuple& GenParamName, const HTuple& Key, HTuple* GenParamValue)

static void HOperatorSet.GetHandleParam(HTuple handle, HTuple genParamName, HTuple key, out HTuple genParamValue)

def get_handle_param(handle: HHandle, gen_param_name: str, key: MaybeSequence[str]) -> Sequence[Union[int, float, str]]

def get_handle_param_s(handle: HHandle, gen_param_name: str, key: MaybeSequence[str]) -> Union[int, float, str]

Description

get_handle_paramget_handle_paramGetHandleParamGetHandleParamget_handle_param returns details about HandleHandleHandlehandlehandle in GenParamValueGenParamValueGenParamValuegenParamValuegen_param_value. It provides a generic mechanism for inspecting and debugging handles of any type by returning keys of that handle that can later be queried using get_handle_tupleget_handle_tupleGetHandleTupleGetHandleTupleget_handle_tuple and get_handle_objectget_handle_objectGetHandleObjectGetHandleObjectget_handle_object.

Note that this operator is provided only for implementing generic debug and inspection mechanisms. The keys returned for certain handle types can change without notice. Additionally, some handle types might not be supported by this operator. Also, this operator is not optimized for performance. To obtain more reliable information about a handle in a program, it is strongly recommended to use the operators specialized for the particular handle type, such as get_object_model_3d_paramsget_object_model_3d_paramsGetObjectModel3dParamsGetObjectModel3dParamsget_object_model_3d_params, get_generic_shape_model_paramget_generic_shape_model_paramGetGenericShapeModelParamGetGenericShapeModelParamget_generic_shape_model_param etc.

Depending on the value of GenParamNameGenParamNameGenParamNamegenParamNamegen_param_name, the following values can be queried:

'keys'"keys""keys""keys""keys":

Returns a list of keys that this handle supports in GenParamValueGenParamValueGenParamValuegenParamValuegen_param_value. Each key contains either a tuple or an iconic object. For this query, the parameter KeyKeyKeykeykey must be empty. Note that due to the generic nature of this operator, some of the returned keys might not be valid for the particular handle. In this case, get_handle_tupleget_handle_tupleGetHandleTupleGetHandleTupleget_handle_tuple or get_handle_objectget_handle_objectGetHandleObjectGetHandleObjectget_handle_object will return an error for those keys.

'key_data_type'"key_data_type""key_data_type""key_data_type""key_data_type":

Returns the data type of KeyKeyKeykeykey. The type is returned in GenParamValueGenParamValueGenParamValuegenParamValuegen_param_value and is either 'tuple'"tuple""tuple""tuple""tuple" or 'object'"object""object""object""object". Depending on the type, the key's corresponding value can be queried with get_handle_tupleget_handle_tupleGetHandleTupleGetHandleTupleget_handle_tuple or get_handle_objectget_handle_objectGetHandleObjectGetHandleObjectget_handle_object, respectively.

Execution Information

Parameters

HandleHandleHandlehandlehandle (input_control)  handle HHandle, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of which to get the parameter.

GenParamNameGenParamNameGenParamNamegenParamNamegen_param_name (input_control)  string HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Parameter to get.

Default: 'keys' "keys" "keys" "keys" "keys"

List of values: 'key_data_type'"key_data_type""key_data_type""key_data_type""key_data_type", 'keys'"keys""keys""keys""keys"

KeyKeyKeykeykey (input_control)  string(-array) HTupleMaybeSequence[str]HTupleHtuple (string) (string) (HString) (char*)

Optional key.

Default: []

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

Returned value.

Result

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

Possible Successors

clear_handleclear_handleClearHandleClearHandleclear_handle, get_handle_tupleget_handle_tupleGetHandleTupleGetHandleTupleget_handle_tuple, get_handle_objectget_handle_objectGetHandleObjectGetHandleObjectget_handle_object

See also

get_handle_tupleget_handle_tupleGetHandleTupleGetHandleTupleget_handle_tuple, get_handle_objectget_handle_objectGetHandleObjectGetHandleObjectget_handle_object

Module

Foundation