ClassesClassesClassesClasses | | | | Operators

tuple_str_bit_selecttuple_str_bit_selectTupleStrBitSelecttuple_str_bit_selectTupleStrBitSelectTupleStrBitSelect (Operator)

Name

tuple_str_bit_selecttuple_str_bit_selectTupleStrBitSelecttuple_str_bit_selectTupleStrBitSelectTupleStrBitSelect — Select single character or bit from a tuple.

Signature

tuple_str_bit_select( : : Tuple, Index : Selected)

Herror tuple_str_bit_select(const char* Tuple, const Hlong Index, char* Selected)

Herror T_tuple_str_bit_select(const Htuple Tuple, const Htuple Index, Htuple* Selected)

Herror tuple_str_bit_select(const HTuple& Tuple, const HTuple& Index, char* Selected)

Herror tuple_str_bit_select(const HTuple& Tuple, const HTuple& Index, HTuple* Selected)

void TupleStrBitSelect(const HTuple& Tuple, const HTuple& Index, HTuple* Selected)

HTuple HTuple::TupleStrBitSelect(const HTuple& Index) const

void HOperatorSetX.TupleStrBitSelect(
[in] VARIANT Tuple, [in] VARIANT Index, [out] VARIANT* Selected)

VARIANT HTupleX.TupleStrBitSelect(
[in] VARIANT Tuple, [in] VARIANT Index)

static void HOperatorSet.TupleStrBitSelect(HTuple tuple, HTuple index, out HTuple selected)

HTuple HTuple.TupleStrBitSelect(HTuple index)

Description

tuple_str_bit_selecttuple_str_bit_selectTupleStrBitSelecttuple_str_bit_selectTupleStrBitSelectTupleStrBitSelect selects a single character or bit from a tuple TupleTupleTupleTupleTupletuple of integer numbers and/or strings. The input parameter IndexIndexIndexIndexIndexindex determines the character or bit position to select. IndexIndexIndexIndexIndexindex must contain a single number. If IndexIndexIndexIndexIndexindex contains a floating point number, this may only represent an integer value (without fraction). The result tuple SelectedSelectedSelectedSelectedSelectedselected contains a new element for each element of TupleTupleTupleTupleTupletuple. Let IndexIndexIndexIndexIndexindex contain the number “n” then each element of SelectedSelectedSelectedSelectedSelectedselected consists of the “n-th” character (for strings) or “n-th” bit (for integers) of the corresponding element of TupleTupleTupleTupleTupletuple.

Exception: Empty input tuples

If TupleTupleTupleTupleTupletuple is empty, an exception is raised.

HDevelop In-line Operation

HDevelop provides an in-line operation for tuple_str_bit_selecttuple_str_bit_selectTupleStrBitSelecttuple_str_bit_selectTupleStrBitSelectTupleStrBitSelect, which can be used in an expression in the following syntax:

Selected := Tuple{Index}

Parallelization

Parameters

TupleTupleTupleTupleTupletuple (input_control)  number(-array) HTupleHTupleHTupleVARIANTHtuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong) (BSTR / Hlong) (char* / Hlong)

Input tuple.

IndexIndexIndexIndexIndexindex (input_control)  number HTupleHTupleHTupleVARIANTHtuple (integer / real) (int / long / double) (Hlong / double) (Hlong / double) (Hlong / double) (Hlong / double)

Position of character or bit to select.

SelectedSelectedSelectedSelectedSelectedselected (output_control)  number(-array) HTupleHTupleHTupleVARIANTHtuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong) (BSTR / Hlong) (char* / Hlong)

Tuple containing the selected characters and bits.

Alternatives

tuple_selecttuple_selectTupleSelecttuple_selectTupleSelectTupleSelect, tuple_first_ntuple_first_nTupleFirstNtuple_first_nTupleFirstNTupleFirstN, tuple_last_ntuple_last_nTupleLastNtuple_last_nTupleLastNTupleLastN, tuple_concattuple_concatTupleConcattuple_concatTupleConcatTupleConcat, tuple_strchrtuple_strchrTupleStrchrtuple_strchrTupleStrchrTupleStrchr, tuple_strrchrtuple_strrchrTupleStrrchrtuple_strrchrTupleStrrchrTupleStrrchr, tuple_str_first_ntuple_str_first_nTupleStrFirstNtuple_str_first_nTupleStrFirstNTupleStrFirstN, tuple_str_last_ntuple_str_last_nTupleStrLastNtuple_str_last_nTupleStrLastNTupleStrLastN, tuple_substrtuple_substrTupleSubstrtuple_substrTupleSubstrTupleSubstr, tuple_andtuple_andTupleAndtuple_andTupleAndTupleAnd, tuple_ortuple_orTupleOrtuple_orTupleOrTupleOr, tuple_xortuple_xorTupleXortuple_xorTupleXorTupleXor, tuple_nottuple_notTupleNottuple_notTupleNotTupleNot

See also

tuple_removetuple_removeTupleRemovetuple_removeTupleRemoveTupleRemove

Module

Foundation


ClassesClassesClassesClasses | | | | Operators