Search
Preparing search index...
The search index is not available
API Reference | Injective - Powering the future of decentralized finance.
Options
All
Public
Public/Protected
All
Inherited
Externals
Menu
API Reference | Injective - Powering the future of decentralized finance.
@injectivelabs/sdk-ts
internal
ObservableQuery
Class ObservableQuery<TData, TVariables>
Type Parameters
TData =
any
TVariables =
OperationVariables
Hierarchy
Observable
<
ApolloQueryResult
<
TData
>
>
ObservableQuery
Index
Constructors
constructor
Properties
apply
Next
Fetch
Policy
concast
fetch
get
Last
is
Torn
Down
last
observe
observer
observers
options
polling
Info
query
Id
query
Info
query
Manager
query
Name
report
Error
report
Result
subscriptions
tear
Down
Query
update
Last
Result
update
Polling
Accessors
query
variables
Methods
[observable]
concat
fetch
More
filter
flat
Map
for
Each
get
Current
Result
get
Last
Error
get
Last
Result
has
Observers
is
Different
From
Last
Result
map
reduce
refetch
reobserve
reset
Last
Results
reset
Query
Store
Errors
result
set
Options
set
Variables
start
Polling
stop
Polling
subscribe
subscribe
To
More
update
Query
apply
call
from
of
Constructors
constructor
new
Observable
Query
<
TData
,
TVariables
>
(
__namedParameters
:
{
options
:
WatchQueryOptions
<
TVariables
,
TData
>
;
queryInfo
:
QueryInfo
;
queryManager
:
QueryManager
<
any
>
}
)
:
ObservableQuery
<
TData
,
TVariables
>
Type Parameters
TData =
any
TVariables =
OperationVariables
Parameters
__namedParameters:
{
options
:
WatchQueryOptions
<
TVariables
,
TData
>
;
queryInfo
:
QueryInfo
;
queryManager
:
QueryManager
<
any
>
}
options
:
WatchQueryOptions
<
TVariables
,
TData
>
query
Info
:
QueryInfo
query
Manager
:
QueryManager
<
any
>
Returns
ObservableQuery
<
TData
,
TVariables
>
Properties
Private
apply
Next
Fetch
Policy
apply
Next
Fetch
Policy
:
any
Private
Optional
concast
concast
?:
any
Private
fetch
fetch
:
any
Private
get
Last
get
Last
:
any
Private
is
Torn
Down
is
Torn
Down
:
any
Private
Optional
last
last
?:
any
Private
observe
observe
:
any
Private
Optional
observer
observer
?:
any
Private
observers
observers
:
any
Readonly
options
options
:
WatchQueryOptions
<
TVariables
,
TData
>
Private
Optional
polling
Info
polling
Info
?:
any
Readonly
query
Id
query
Id
:
string
Private
query
Info
query
Info
:
any
Private
query
Manager
query
Manager
:
any
Optional
Readonly
query
Name
query
Name
?:
string
Private
report
Error
report
Error
:
any
Private
report
Result
report
Result
:
any
Private
subscriptions
subscriptions
:
any
Private
tear
Down
Query
tear
Down
Query
:
any
Private
update
Last
Result
update
Last
Result
:
any
Private
update
Polling
update
Polling
:
any
Accessors
query
get
query
(
)
:
TypedDocumentNode
<
TData
,
TVariables
>
Returns
TypedDocumentNode
<
TData
,
TVariables
>
variables
get
variables
(
)
:
undefined
|
TVariables
Returns
undefined
|
TVariables
Methods
[observable]
[observable]
(
)
:
Observable
<
ApolloQueryResult
<
TData
>
>
Returns
Observable
<
ApolloQueryResult
<
TData
>
>
concat
concat
<
R
>
(
...
observable
:
Observable
<
R
>
[]
)
:
Observable
<
R
>
Type Parameters
R
Parameters
Rest
...
observable:
Observable
<
R
>
[]
Returns
Observable
<
R
>
fetch
More
fetch
More
<
TFetchData
,
TFetchVars
>
(
fetchMoreOptions
:
FetchMoreQueryOptions
<
TFetchVars
,
TFetchData
>
&
{
updateQuery
?:
any
}
)
:
internal
.
Promise
<
ApolloQueryResult
<
TFetchData
>
>
Type Parameters
TFetchData =
TData
TFetchVars =
TVariables
Parameters
fetchMoreOptions:
FetchMoreQueryOptions
<
TFetchVars
,
TFetchData
>
&
{
updateQuery
?:
any
}
Returns
internal
.
Promise
<
ApolloQueryResult
<
TFetchData
>
>
filter
filter
<
S
>
(
callback
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
value
is
S
)
)
:
Observable
<
S
>
filter
(
callback
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
boolean
)
)
:
Observable
<
ApolloQueryResult
<
TData
>
>
Type Parameters
S
extends
ApolloQueryResult
<
TData
>
Parameters
callback:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
value
is
S
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
value
is
S
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
value
is
S
Returns
Observable
<
S
>
Parameters
callback:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
boolean
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
boolean
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
boolean
Returns
Observable
<
ApolloQueryResult
<
TData
>
>
flat
Map
flat
Map
<
R
>
(
callback
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
ObservableLike
<
R
>
)
)
:
Observable
<
R
>
Type Parameters
R
Parameters
callback:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
ObservableLike
<
R
>
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
ObservableLike
<
R
>
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
ObservableLike
<
R
>
Returns
Observable
<
R
>
for
Each
for
Each
(
callback
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
void
)
)
:
internal
.
Promise
<
void
>
Parameters
callback:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
void
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
void
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
void
Returns
internal
.
Promise
<
void
>
get
Current
Result
get
Current
Result
(
saveAsLastResult
?:
boolean
)
:
ApolloQueryResult
<
TData
>
Parameters
Optional
saveAsLastResult:
boolean
Returns
ApolloQueryResult
<
TData
>
get
Last
Error
get
Last
Error
(
variablesMustMatch
?:
boolean
)
:
undefined
|
ApolloError
Parameters
Optional
variablesMustMatch:
boolean
Returns
undefined
|
ApolloError
get
Last
Result
get
Last
Result
(
variablesMustMatch
?:
boolean
)
:
undefined
|
ApolloQueryResult
<
TData
>
Parameters
Optional
variablesMustMatch:
boolean
Returns
undefined
|
ApolloQueryResult
<
TData
>
has
Observers
has
Observers
(
)
:
boolean
Returns
boolean
is
Different
From
Last
Result
is
Different
From
Last
Result
(
newResult
:
ApolloQueryResult
<
TData
>
, variables
?:
TVariables
)
:
undefined
|
boolean
Parameters
newResult:
ApolloQueryResult
<
TData
>
Optional
variables:
TVariables
Returns
undefined
|
boolean
map
map
<
R
>
(
callback
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
R
)
)
:
Observable
<
R
>
Type Parameters
R
Parameters
callback:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
R
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
R
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
R
Returns
Observable
<
R
>
reduce
reduce
(
callback
:
(
(
previousValue
:
ApolloQueryResult
<
TData
>
, currentValue
:
ApolloQueryResult
<
TData
>
)
=>
ApolloQueryResult
<
TData
>
)
, initialValue
?:
ApolloQueryResult
<
TData
>
)
:
Observable
<
ApolloQueryResult
<
TData
>
>
reduce
<
R
>
(
callback
:
(
(
previousValue
:
R
, currentValue
:
ApolloQueryResult
<
TData
>
)
=>
R
)
, initialValue
?:
R
)
:
Observable
<
R
>
Parameters
callback:
(
(
previousValue
:
ApolloQueryResult
<
TData
>
, currentValue
:
ApolloQueryResult
<
TData
>
)
=>
ApolloQueryResult
<
TData
>
)
(
previousValue
:
ApolloQueryResult
<
TData
>
, currentValue
:
ApolloQueryResult
<
TData
>
)
:
ApolloQueryResult
<
TData
>
Parameters
previousValue:
ApolloQueryResult
<
TData
>
currentValue:
ApolloQueryResult
<
TData
>
Returns
ApolloQueryResult
<
TData
>
Optional
initialValue:
ApolloQueryResult
<
TData
>
Returns
Observable
<
ApolloQueryResult
<
TData
>
>
Type Parameters
R
Parameters
callback:
(
(
previousValue
:
R
, currentValue
:
ApolloQueryResult
<
TData
>
)
=>
R
)
(
previousValue
:
R
, currentValue
:
ApolloQueryResult
<
TData
>
)
:
R
Parameters
previousValue:
R
currentValue:
ApolloQueryResult
<
TData
>
Returns
R
Optional
initialValue:
R
Returns
Observable
<
R
>
refetch
refetch
(
variables
?:
Partial
<
TVariables
>
)
:
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
Parameters
Optional
variables:
Partial
<
TVariables
>
Returns
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
reobserve
reobserve
(
newOptions
?:
Partial
<
WatchQueryOptions
<
TVariables
,
TData
>
>
, newNetworkStatus
?:
NetworkStatus
)
:
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
Parameters
Optional
newOptions:
Partial
<
WatchQueryOptions
<
TVariables
,
TData
>
>
Optional
newNetworkStatus:
NetworkStatus
Returns
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
reset
Last
Results
reset
Last
Results
(
)
:
void
Returns
void
reset
Query
Store
Errors
reset
Query
Store
Errors
(
)
:
void
Returns
void
result
result
(
)
:
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
Returns
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
set
Options
set
Options
(
newOptions
:
Partial
<
WatchQueryOptions
<
TVariables
,
TData
>
>
)
:
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
Parameters
newOptions:
Partial
<
WatchQueryOptions
<
TVariables
,
TData
>
>
Returns
internal
.
Promise
<
ApolloQueryResult
<
TData
>
>
set
Variables
set
Variables
(
variables
:
TVariables
)
:
internal
.
Promise
<
void
|
ApolloQueryResult
<
TData
>
>
Parameters
variables:
TVariables
Returns
internal
.
Promise
<
void
|
ApolloQueryResult
<
TData
>
>
start
Polling
start
Polling
(
pollInterval
:
number
)
:
void
Parameters
pollInterval:
number
Returns
void
stop
Polling
stop
Polling
(
)
:
void
Returns
void
subscribe
subscribe
(
observer
:
Observer
<
ApolloQueryResult
<
TData
>
>
)
:
Subscription
subscribe
(
onNext
:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
void
)
, onError
?:
(
(
error
:
any
)
=>
void
)
, onComplete
?:
(
(
)
=>
void
)
)
:
Subscription
Parameters
observer:
Observer
<
ApolloQueryResult
<
TData
>
>
Returns
Subscription
Parameters
onNext:
(
(
value
:
ApolloQueryResult
<
TData
>
)
=>
void
)
(
value
:
ApolloQueryResult
<
TData
>
)
:
void
Parameters
value:
ApolloQueryResult
<
TData
>
Returns
void
Optional
onError:
(
(
error
:
any
)
=>
void
)
(
error
:
any
)
:
void
Parameters
error:
any
Returns
void
Optional
onComplete:
(
(
)
=>
void
)
(
)
:
void
Returns
void
Returns
Subscription
subscribe
To
More
subscribe
To
More
<
TSubscriptionData
,
TSubscriptionVariables
>
(
options
:
SubscribeToMoreOptions
<
TData
,
TSubscriptionVariables
,
TSubscriptionData
>
)
:
(
(
)
=>
void
)
Type Parameters
TSubscriptionData =
TData
TSubscriptionVariables =
TVariables
Parameters
options:
SubscribeToMoreOptions
<
TData
,
TSubscriptionVariables
,
TSubscriptionData
>
Returns
(
(
)
=>
void
)
(
)
:
void
Returns
void
update
Query
update
Query
<
TVars
>
(
mapFn
:
(
(
previousQueryResult
:
TData
, options
:
Pick
<
WatchQueryOptions
<
TVars
,
TData
>
,
"variables"
>
)
=>
TData
)
)
:
void
Type Parameters
TVars =
TVariables
Parameters
mapFn:
(
(
previousQueryResult
:
TData
, options
:
Pick
<
WatchQueryOptions
<
TVars
,
TData
>
,
"variables"
>
)
=>
TData
)
(
previousQueryResult
:
TData
, options
:
Pick
<
WatchQueryOptions
<
TVars
,
TData
>
,
"variables"
>
)
:
TData
Parameters
previousQueryResult:
TData
options:
Pick
<
WatchQueryOptions
<
TVars
,
TData
>
,
"variables"
>
Returns
TData
Returns
void
Static
apply
apply
<
R
>
(
instance
:
Observable
<
R
>
, args
:
IArguments
|
[
Subscriber
<
R
>
]
)
:
undefined
Type Parameters
R
Parameters
instance:
Observable
<
R
>
args:
IArguments
|
[
Subscriber
<
R
>
]
Returns
undefined
Static
call
call
<
R
>
(
instance
:
Observable
<
R
>
, subscriber
:
Subscriber
<
R
>
)
:
undefined
Type Parameters
R
Parameters
instance:
Observable
<
R
>
subscriber:
Subscriber
<
R
>
Returns
undefined
Static
from
from
<
R
>
(
observable
:
Observable
<
R
>
|
ObservableLike
<
R
>
|
ArrayLike
<
R
>
)
:
Observable
<
R
>
Type Parameters
R
Parameters
observable:
Observable
<
R
>
|
ObservableLike
<
R
>
|
ArrayLike
<
R
>
Returns
Observable
<
R
>
Static
of
of
<
R
>
(
...
items
:
R
[]
)
:
Observable
<
R
>
Type Parameters
R
Parameters
Rest
...
items:
R
[]
Returns
Observable
<
R
>
Modules
@injectivelabs/sdk-
ts
internal
Big
Number
Browser
Headers
Data
Proxy
global
This
@injectivelabs/wallet-
ts
Observable
Query
constructor
apply
Next
Fetch
Policy
concast
fetch
get
Last
is
Torn
Down
last
observe
observer
observers
options
polling
Info
query
Id
query
Info
query
Manager
query
Name
report
Error
report
Result
subscriptions
tear
Down
Query
update
Last
Result
update
Polling
query
variables
[observable]
concat
fetch
More
filter
flat
Map
for
Each
get
Current
Result
get
Last
Error
get
Last
Result
has
Observers
is
Different
From
Last
Result
map
reduce
refetch
reobserve
reset
Last
Results
reset
Query
Store
Errors
result
set
Options
set
Variables
start
Polling
stop
Polling
subscribe
subscribe
To
More
update
Query
apply
call
from
of
Generated using
TypeDoc