Example
GitHub
Preparing search index...
The search index is not available
ic-reactor
ic-reactor
visitor
VisitTransform
Class VisitTransform
Visit the candid file and extract the fields. It returns the extracted service fields.
Hierarchy (
view full
)
types
.
IDL
.
Visitor
<
types
.
DynamicDataArgs
,
MethodResult
>
VisitTransform
Index
Constructors
constructor
Methods
visit
Empty
visit
Reserved
visit
Construct
visit
Service
visit
Func
visit
Rec
visit
Opt
visit
Record
visit
Tuple
visit
Variant
visit
Vec
visit
Text
visit
Number
visit
Int
visit
Nat
visit
Float
visit
Fixed
Int
visit
Fixed
Nat
visit
Primitive
visit
Null
visit
Bool
visit
Principal
visit
Type
Constructors
constructor
new
Visit
Transform
(
)
:
VisitTransform
Returns
VisitTransform
Methods
visit
Empty
visit
Empty
(
t
,
data
)
:
MethodResult
Parameters
t
:
types
.
IDL
.
EmptyClass
data
:
types
.
DynamicDataArgs
<
unknown
>
Returns
MethodResult
visit
Reserved
visit
Reserved
(
t
,
data
)
:
MethodResult
Parameters
t
:
types
.
IDL
.
ReservedClass
data
:
types
.
DynamicDataArgs
<
unknown
>
Returns
MethodResult
visit
Construct
visit
Construct
<
T
>
(
t
,
data
)
:
MethodResult
Type Parameters
T
Parameters
t
:
types
.
IDL
.
ConstructType
<
T
>
data
:
types
.
DynamicDataArgs
<
unknown
>
Returns
MethodResult
visit
Service
visit
Service
(
t
,
data
)
:
MethodResult
Parameters
t
:
types
.
IDL
.
ServiceClass
data
:
types
.
DynamicDataArgs
<
unknown
>
Returns
MethodResult
visit
Func
visit
Func
(
t
,
__namedParameters
)
:
NormalMethodResult
Parameters
t
:
types
.
IDL
.
FuncClass
__namedParameters
:
types
.
DynamicDataArgs
<
unknown
>
Returns
NormalMethodResult
visit
Rec
visit
Rec
<
T
>
(
_t
,
ty
,
data
)
:
MethodResult
Type Parameters
T
Parameters
_t
:
types
.
IDL
.
RecClass
<
T
>
ty
:
types
.
IDL
.
ConstructType
<
T
>
data
:
types
.
DynamicDataArgs
<
T
>
Returns
MethodResult
visit
Opt
visit
Opt
<
T
>
(
_t
,
ty
,
__namedParameters
)
:
OptionalMethodResult
Type Parameters
T
Parameters
_t
:
types
.
IDL
.
OptClass
<
T
>
ty
:
types
.
IDL
.
Type
<
T
>
__namedParameters
:
types
.
DynamicDataArgs
<
null
|
T
[]
>
Returns
OptionalMethodResult
visit
Record
visit
Record
(
_t
,
fields
,
__namedParameters
)
:
RecordMethodResult
Parameters
_t
:
types
.
IDL
.
RecordClass
fields
:
[
string
,
types
.
IDL
.
Type
<
any
>
]
[]
__namedParameters
:
types
.
DynamicDataArgs
<
Record
<
string
,
unknown
>
>
Returns
RecordMethodResult
visit
Tuple
visit
Tuple
<
T
>
(
_t
,
components
,
__namedParameters
)
:
DefaultMethodResult
&
(
{
type
:
"tuple"
;
componentType
:
"normal"
;
values
:
(
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
)
[]
;
}
|
{
type
:
"tuple"
;
componentType
:
"record"
;
key
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
|
{
type
:
"tuple"
;
componentType
:
"title"
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
|
{
type
:
"tuple"
;
componentType
:
"keyValue"
;
key
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
)
Type Parameters
T
extends
types
.
IDL
.
Type
<
any
>
[]
Parameters
_t
:
types
.
IDL
.
TupleClass
<
T
>
components
:
types
.
IDL
.
Type
<
any
>
[]
__namedParameters
:
types
.
DynamicDataArgs
<
unknown
[]
>
Returns
DefaultMethodResult
&
(
{
type
:
"tuple"
;
componentType
:
"normal"
;
values
:
(
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
)
[]
;
}
|
{
type
:
"tuple"
;
componentType
:
"record"
;
key
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
|
{
type
:
"tuple"
;
componentType
:
"title"
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
|
{
type
:
"tuple"
;
componentType
:
"keyValue"
;
key
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
value
:
NormalMethodResult | RecordMethodResult | VariantMethodResult | (DefaultMethodResult & ({ ...; } | ... 2 more ... | { ...; })) | ... 7 more ... | UnknownMethodResult
;
}
)
visit
Variant
visit
Variant
(
_t
,
fields
,
__namedParameters
)
:
MethodResult
Parameters
_t
:
types
.
IDL
.
VariantClass
fields
:
[
string
,
types
.
IDL
.
Type
<
any
>
]
[]
__namedParameters
:
types
.
DynamicDataArgs
<
Record
<
string
,
unknown
>
>
Returns
MethodResult
visit
Vec
visit
Vec
<
T
>
(
t
,
ty
,
__namedParameters
)
:
VectorMethodResult
Type Parameters
T
Parameters
t
:
types
.
IDL
.
VecClass
<
T
>
ty
:
types
.
IDL
.
Type
<
T
>
__namedParameters
:
types
.
DynamicDataArgs
<
T
[]
>
Returns
VectorMethodResult
visit
Text
visit
Text
(
_t
,
__namedParameters
)
:
TextMethodResult
Parameters
_t
:
types
.
IDL
.
TextClass
__namedParameters
:
types
.
DynamicDataArgs
<
string
>
Returns
TextMethodResult
visit
Number
visit
Number
<
T
>
(
_t
,
__namedParameters
)
:
NumberMethodResult
Type Parameters
T
Parameters
_t
:
types
.
IDL
.
Type
<
T
>
__namedParameters
:
types
.
DynamicDataArgs
<
number
|
bigint
>
Returns
NumberMethodResult
visit
Int
visit
Int
(
t
,
data
)
:
NumberMethodResult
Parameters
t
:
types
.
IDL
.
IntClass
data
:
types
.
DynamicDataArgs
<
number
>
Returns
NumberMethodResult
visit
Nat
visit
Nat
(
t
,
data
)
:
NumberMethodResult
Parameters
t
:
types
.
IDL
.
NatClass
data
:
types
.
DynamicDataArgs
<
number
>
Returns
NumberMethodResult
visit
Float
visit
Float
(
t
,
data
)
:
NumberMethodResult
Parameters
t
:
types
.
IDL
.
FloatClass
data
:
types
.
DynamicDataArgs
<
number
>
Returns
NumberMethodResult
visit
Fixed
Int
visit
Fixed
Int
(
t
,
data
)
:
NumberMethodResult
Parameters
t
:
types
.
IDL
.
FixedIntClass
data
:
types
.
DynamicDataArgs
<
number
>
Returns
NumberMethodResult
visit
Fixed
Nat
visit
Fixed
Nat
(
t
,
data
)
:
NumberMethodResult
Parameters
t
:
types
.
IDL
.
FixedNatClass
data
:
types
.
DynamicDataArgs
<
number
>
Returns
NumberMethodResult
visit
Primitive
visit
Primitive
<
T
>
(
t
,
data
)
:
MethodResult
Type Parameters
T
Parameters
t
:
types
.
IDL
.
PrimitiveType
<
T
>
data
:
types
.
DynamicDataArgs
<
unknown
>
Returns
MethodResult
visit
Null
visit
Null
(
_t
,
__namedParameters
)
:
TextMethodResult
Parameters
_t
:
types
.
IDL
.
NullClass
__namedParameters
:
types
.
DynamicDataArgs
<
string
>
Returns
TextMethodResult
visit
Bool
visit
Bool
(
_t
,
__namedParameters
)
:
BooleanMethodResult
Parameters
_t
:
types
.
IDL
.
BoolClass
__namedParameters
:
types
.
DynamicDataArgs
<
boolean
>
Returns
BooleanMethodResult
visit
Principal
visit
Principal
(
_t
,
__namedParameters
)
:
PrincipalMethodResult
Parameters
_t
:
types
.
IDL
.
PrincipalClass
__namedParameters
:
types
.
DynamicDataArgs
<
types
.
Principal
>
Returns
PrincipalMethodResult
visit
Type
visit
Type
<
T
>
(
t
,
__namedParameters
)
:
UnknownMethodResult
Type Parameters
T
Parameters
t
:
types
.
IDL
.
Type
<
T
>
__namedParameters
:
types
.
DynamicDataArgs
<
T
>
Returns
UnknownMethodResult
Settings
Member Visibility
Protected
Private
Inherited
External
Theme
OS
Light
Dark
On This Page
constructor
visit
Empty
visit
Reserved
visit
Construct
visit
Service
visit
Func
visit
Rec
visit
Opt
visit
Record
visit
Tuple
visit
Variant
visit
Vec
visit
Text
visit
Number
visit
Int
visit
Nat
visit
Float
visit
Fixed
Int
visit
Fixed
Nat
visit
Primitive
visit
Null
visit
Bool
visit
Principal
visit
Type
ic-reactor
Loading...
Visit the candid file and extract the fields. It returns the extracted service fields.