Class Functions
On this page
io.realm.mongodb.functions
A Functions manager to call remote Realm functions for the associated Realm App.Arguments and results are encoded/decoded with the Functions' codec registry either inherited from the AppConfiguration.getDefaultCodecRegistry() or set explicitly when creating the
Functions-instance through User.getFunctions(CodecRegistry) or through the individual calls to callFunction(String, List, Class, CodecRegistry) .
Method Summary
Modifier and Type | Method and Description |
---|---|
public ResultT | Call a MongoDB Realm function synchronously with custom result decoder. |
public ResultT | Call a MongoDB Realm function synchronously with default codec registry encoding/decoding arguments/results. |
public ResultT | callFunction <ResultT >( ) Call a MongoDB Realm function synchronously with custom codec registry encoding/decoding arguments/results. |
public RealmAsyncTask | callFunctionAsync <T >( ) Call a MongoDB Realm function asynchronously with custom result decoder. |
public RealmAsyncTask | callFunctionAsync <T >( String name, java.util.List<?> args, java.lang.Class<T> resultClass, io.realm.mongodb.App.Callback<T> callback ) Call a MongoDB Realm function asynchronously with custom codec registry for encoding/decoding arguments/results. |
public RealmAsyncTask | callFunctionAsync <T >( String name, java.util.List<?> args, java.lang.Class<T> resultClass, CodecRegistry codecRegistry, io.realm.mongodb.App.Callback<T> callback ) Call a MongoDB Realm function asynchronously with custom codec registry for encoding/decoding arguments/results. |
public App | |
public CodecRegistry | Returns the default codec registry used for encoding arguments and decoding results for this Realm functions instance. |
public User | |
protected abstract T |
Inherited Methods
Methods inherited from class java.lang.Object :
getClass
,hashCode
,equals
,clone
,toString
,notify
,notifyAll
,wait
,wait
,wait
,finalize
Method Detail
callFunction
Call a MongoDB Realm function synchronously with custom result decoder.The arguments will be encoded with the default codec registry encoding. Type Parameters
Parameters
Returns Result of the Realm function. Throws
|
public ResultT callFunction <ResultT >( ) |
---|
Call a MongoDB Realm function synchronously with default codec registry encoding/decoding arguments/results. Type Parameters
Parameters
Returns Result of the Realm function. Throws
|
public ResultT callFunction <ResultT >( ) |
---|
Call a MongoDB Realm function synchronously with custom codec registry encoding/decoding arguments/results. Type Parameters
Parameters
Returns Result of the Realm function. Throws
|
callFunctionAsync
public RealmAsyncTask callFunctionAsync <T >( ) |
---|
Call a MongoDB Realm function asynchronously with custom result decoder.This is the asynchronous equivalent of callFunction(String, List, Decoder). Type Parameters
Parameters
Returns The task representing the ongoing operation. Throws
|
public RealmAsyncTask callFunctionAsync <T >( String name, java.util.List<?> args, java.lang.Class<T> resultClass, io.realm.mongodb.App.Callback<T> callback ) |
---|
Call a MongoDB Realm function asynchronously with custom codec registry for encoding/decoding arguments/results.This is the asynchronous equivalent of callFunction(String, List, Class) . Type Parameters
Parameters
Returns The task representing the ongoing operation. Throws
|
public RealmAsyncTask callFunctionAsync <T >( String name, java.util.List<?> args, java.lang.Class<T> resultClass, CodecRegistry codecRegistry, io.realm.mongodb.App.Callback<T> callback ) |
---|
Call a MongoDB Realm function asynchronously with custom codec registry for encoding/decoding arguments/results.This is the asynchronous equivalent of callFunction(String, List, Class, CodecRegistry) . Type Parameters
Parameters
Returns The task representing the ongoing operation. Throws
|
getApp
getDefaultCodecRegistry
public CodecRegistry getDefaultCodecRegistry () |
---|
Returns the default codec registry used for encoding arguments and decoding results for this Realm functions instance. Returns The default codec registry. |
getUser
invoke
protected abstract T invoke <T >( ) |
---|