Modifiers for TlArgument.type

interface TlTypeModifiers {
    constructorId?: number;
    isBareType?: boolean;
    isBareUnion?: boolean;
    isBareVector?: boolean;
    isVector?: boolean;
    predicate?: string;
}

Properties

constructorId?: number

For simplicity, when isBareUnion or isBareType is true, this field contains the constructor ID of the type being referenced.

May still be undefined if the constructor ID is not known.

isBareType?: boolean

Whether type is in fact a "bare" type (a %-prefixed type)

The difference between T and %T is that in the latter case constructor ID of T is omitted.

The difference with isBareUnion is in the kind of type. For isBareUnion, type is a name of a union (e.g. Message), for isBareType it is a name of a type (e.g. message).

isBareUnion?: boolean

Whether type is in fact a "bare" type (a %-prefixed type) from within a union.

The difference between T and %T is that in the latter case constructor ID of T is omitted.

Note: If there are more than 1 types within that union, this syntax is not valid.

`type=Message, isBare=true => %Message
isBareVector?: boolean

Whether type is in fact a vector (a bare vector, not to be confused with Vector).

The difference between Vector<T> and vector<T> is that in the latter case constructor ID of the vector itself (1cb5c415) is omitted

`type=long, isVector=false, isBareVector=true => vector<long>
isVector?: boolean

Whether type is in fact a Vector

`type=long, isVector=true => Vector<long>
predicate?: string

Predicate of the argument

`flags.3`