Skip to main content

Auki::ConjureKit::IConjureKit

Generic interface for ConjureKit API

Inherited by Auki.ConjureKit.ConjureKit

Public Functions​

Name
ConjureKitConfigurationGetConfiguration()
Gets the current configuration.
TransformGetCameraTransform()
Gets the camera transform.
AukiCredentialsGetCredentials()
Gets the current credentials.
void_SendBytes(byte[] data)
(Internal) Sends a message directly to Hagall.
State State.
NetworkQualityGetNetworkQuality()
Returns the current NetworkQuality object.
voidRegisterModule(IConjureKitModule module)
(Internal) Registers IAukiModule-conforming objects so they get updated and receive messages.
TimestampGetNowAsProtobufTimestamp()
Standard way of getting the current time.
longGetNowMilliseconds()
Gets current time in milliseconds.
uintGetNewRequestId()
(Internal) Returns a new request id.
voidRequest(uint requestId, MsgType msgType, byte[] request, Action< byte[]> onResponse, Action< string > onError)
(Internal) Sends a request to the server.
voidRequest(uint requestId, byte[] request, Action< byte[]> onResponse, Action< string > onError)
(Internal) Sends a request to the server. Deprecated version without the message type.
voidMeasurePing(Action< double > onComplete =null, Action< string > onError =null)
Perform a millisecond ping measurement of the current session. The measurement is aggregated to ConjureKit's NetworkQuality object, accessible via ConjureKit.GetNetworkQuality().
boolSendCustomMessage(uint[] participantIds, byte[] data)
Sends a custom message to other Participants.
voidNotifyARCameraCalibrated()
Notify Auki calibration has been achieved.
ConjureKitBridgeGetConjureKitBridge()
Gets an object with common Unity callbacks.
SessionGetSession()
Gets currently joined Session object.
voidConnect(Action< Session > onComplete =null, Action< string > onFailed =null)
Call when you want to connect to the Aukiverse with the default or current ConjureKitConfiguration. The onComplete callback is invoked with the same argument as ConjureKit.OnJoined, prior to ConjureKit.OnJoined.
voidConnect(string sessionId, Action< Session > onComplete =null, Action< string > onFailed =null)
Call when you want to connect to the Aukiverse to a specific session with the default or current ConjureKitConfiguration. The session argument can also be set to the empty string in which case a new session will be created.
voidConnect(string sessionId, string configUri, Action< Session > onComplete =null, Action< string > onFailed =null)
Call when you want to connect to the Aukiverse to a specific session with a custom ConjureKitConfiguration URI. The initialization process related to the configUri is idempotent, and will not result in re-initialization if the same URI is provided twice.
voidConnect(string sessionId, ConjureKitConfiguration configuration, Action< Session > onComplete =null, Action< string > onFailed =null)
Call when you want to connect to the Aukiverse to a specific session with a custom ConjureKitConfiguration struct. The initialization process related to the configUri is idempotent, and will not result in re-initialization if the same struct is provided twice.
boolIsInitialized(string configUri, out string reason)
Determines if ConjureKit and all of its modules are initialized for a specific given configuration URI. Returns also a reason for not being initialized.
boolIsInitialized(out string reason)
Determines if ConjureKit and all of its modules are initialized for the configuration currently being available or used. Returns also a reason for not being initialized.
boolIsInitialized(string configUri ="")
Determines if ConjureKit and all of its modules are initialized for the configuration currently being used or, when a URI is provided, for the given configuration URI.
voidInit(string configUrl, Action onComplete =null, Action< string > onFailed =null)
Optional manual initialization ConjureKit and its modules for a non-default configUrl. Note that one must be in a Disconnected or Initializing state to call this function.
voidInit(ConjureKitConfiguration configuration, Action onComplete =null, Action< string > onFailed =null)
Optional manual initialization of ConjureKit and its modules for a given ConjureKitConfiguration object. One must be in a Disconnected or Initializing state to call this function.
boolConnectionErrorMessageIsInternetConnectivityIssue(string errorMessage)
Tells whether a string returned by the onError callback of ConjureKit.Connect() denotes an internet connectivity issue.
voidDisconnect()
Call to disconnect from a session.
voidSetHagallFeatureConfiguration(IEnumerable< string > modules =null, IEnumerable< string > featureFlags =null)
Sets lists of required Hagall modules and feature flags.
voidSetHagallMinVersion(string version)
Sets application-side request for minimum Hagall version.
voidAddComponentType(string componentTypeName, Action< uint > onComplete, Action< string > onError =null)
Low-level ECS method to add a component type to the Session. Might later be replaced by Systems.
voidGetComponentTypeId(string componentTypeName, Action< uint > onComplete, Action< string > onError =null)
Low-level ECS method to get the id of a component type by name from a Session. Might later be replaced by Systems.
voidGetComponentTypeName(uint componentTypeId, Action< string > onComplete, Action< string > onError =null)
Low-level ECS method to get the name of a component type by id from a Hagall Session. Might later be replaced by Systems.
voidAddComponent(uint componentTypeId, uint entityId, byte[] data, Action onComplete, Action< string > onError =null)
Low-level ECS method to add a component to an Entity in a Session. Might later be replaced by Systems.
voidDeleteComponent(uint componentTypeId, uint entityId, Action onComplete, Action< string > onError =null)
Low-level ECS method to delete a component from an Entity in a Session. Might later be replaced by Systems.
voidGetComponents(uint componentTypeId, Action< List< EntityComponent >> onComplete, Action< string > onError =null)
Low-level ECS method to get all components of a component type in a Session. Might later be replaced by Systems.
boolUpdateComponent(uint componentTypeId, uint entityId, byte[] data)
Low-level ECS method to update a component on an Entity in a Session. Might later be replaced by Systems.
voidSubscribeToComponentType(uint componentTypeId, Action onComplete, Action< string > onError =null)
Low-level ECS method to subscribe to updates of a component type Might later be replaced by Systems.
voidUnsubscribeToComponentType(uint componentTypeId, Action onComplete, Action< string > onError =null)
Low-level ECS method to unsubscribe to updates of a component type Might later be replaced by Systems.

Public Properties​

Name
Action< ConjureKitConfiguration >OnInit
Called after successful initialization or re-initialization of ConjureKit and its modules. The argument passed to OnInit is the configuration for which initialization took place.
Action< Participant >OnParticipantJoined
Called when a new Participant joins the Session.
Action< uint >OnParticipantLeft
Called when a Participant left the Session.
Action< Entity >OnEntityAdded
Called when an Entity is added to the Session.
Action< Entity >OnEntityAddedResponse
Called when an Entity add request was successful.
Action< uint >OnEntityDeleted
Called when an Entity was deleted from the Session.
Action< uint >OnEntityDeletedResponse
Called when an Entity delete request was successful.
Action< Session >OnJoined
Called when a Session was joined.
Action< Entity >OnParticipantEntityCreated
Called after calibration or immediately after joining a Session if this Participant is its host.
Action< Session >OnLeft
Called when a Session was left. The argument is an inert copy of the old Session object as it stood before leaving.
Action< State state has changed.
Action< Entity >OnEntityUpdatePose
Called when an Entity's Pose has been updated.
Action< CustomMessageBroadcast >OnCustomMessageBroadcast
Called when a custom message broadcast has been received.
ActionOnApplicationBackground
Called when the application was sent to the background.
ActionOnApplicationForeground
Called when the application was sent to the foreground.
Action< ComponentUpdateBroadcast >OnComponentUpdate
Low-level ECS callback method that is called when a component update is broadcast from a Session. Might later be replaced by Systems.
Action< ComponentAddBroadcast >OnComponentAdd
Low-level ECS callback method that is called when a component is added to an Entity in a Session. Might later be replaced by Systems.
Action< ComponentDeleteBroadcast >OnComponentDelete
Low-level ECS callback method that is called when a component is deleted from an Entity in a Session. Might later be replaced by Systems.

Public Functions Documentation​

function GetConfiguration​

ConjureKitConfiguration GetConfiguration()

Gets the current configuration.

Return: ConjureKitConfiguration struct

Reimplemented by: Auki::ConjureKit::ConjureKit::GetConfiguration

function GetCameraTransform​

Transform GetCameraTransform()

Gets the camera transform.

Return: Transform

Reimplemented by: Auki::ConjureKit::ConjureKit::GetCameraTransform

function GetCredentials​

AukiCredentials GetCredentials()

Gets the current credentials.

Return: AukiCredentials struct

Reimplemented by: Auki::ConjureKit::ConjureKit::GetCredentials

function _SendBytes​

void _SendBytes(
byte[] data
)

(Internal) Sends a message directly to Hagall.

Parameters:

  • data

Reimplemented by: Auki::ConjureKit::ConjureKit::_SendBytes

function GetState​

State GetState()

Gets current ConjureKit State.

Return: ConjureKit State

Reimplemented by: Auki::ConjureKit::ConjureKit::GetState

function GetNetworkQuality​

NetworkQuality GetNetworkQuality()

Returns the current NetworkQuality object.

Return: NetworkQuality object

Reimplemented by: Auki::ConjureKit::ConjureKit::GetNetworkQuality

function RegisterModule​

void RegisterModule(
IConjureKitModule module
)

(Internal) Registers IAukiModule-conforming objects so they get updated and receive messages.

Parameters:

  • module Module to be registered

Reimplemented by: Auki::ConjureKit::ConjureKit::RegisterModule

function GetNowAsProtobufTimestamp​

Timestamp GetNowAsProtobufTimestamp()

Standard way of getting the current time.

Return: Current time

Reimplemented by: Auki::ConjureKit::ConjureKit::GetNowAsProtobufTimestamp

function GetNowMilliseconds​

long GetNowMilliseconds()

Gets current time in milliseconds.

Return: Current time in milliseconds

Reimplemented by: Auki::ConjureKit::ConjureKit::GetNowMilliseconds

function GetNewRequestId​

uint GetNewRequestId()

(Internal) Returns a new request id.

Return: New request id

Reimplemented by: Auki::ConjureKit::ConjureKit::GetNewRequestId

function Request​

void Request(
uint requestId,
MsgType msgType,
byte[] request,
Action< byte[]> onResponse,
Action< string > onError
)

(Internal) Sends a request to the server.

Parameters:

  • requestId Request id
  • msgType Request MsgType
  • request Byte array-encoded request
  • onResponse Callback on success
  • onError Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Request

function Request​

void Request(
uint requestId,
byte[] request,
Action< byte[]> onResponse,
Action< string > onError
)

(Internal) Sends a request to the server. Deprecated version without the message type.

Parameters:

  • requestId Request id
  • request Byte array-encoded request
  • onResponse Callback on success
  • onError Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Request

function MeasurePing​

void MeasurePing(
Action< double > onComplete =null,
Action< string > onError =null
)

Perform a millisecond ping measurement of the current session. The measurement is aggregated to ConjureKit's NetworkQuality object, accessible via ConjureKit.GetNetworkQuality().

Parameters:

  • onComplete Callback on success, invoked with millisecond amount
  • onError Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::MeasurePing

function SendCustomMessage​

bool SendCustomMessage(
uint[] participantIds,
byte[] data
)

Sends a custom message to other Participants.

Parameters:

  • participantIds An array of Participant Ids
  • data An array of custom data

Return: Success or failure

Reimplemented by: Auki::ConjureKit::ConjureKit::SendCustomMessage

function NotifyARCameraCalibrated​

void NotifyARCameraCalibrated()

Notify Auki calibration has been achieved.

Reimplemented by: Auki::ConjureKit::ConjureKit::NotifyARCameraCalibrated

function GetConjureKitBridge​

ConjureKitBridge GetConjureKitBridge()

Gets an object with common Unity callbacks.

Return: AukiUnityBridge object

Reimplemented by: Auki::ConjureKit::ConjureKit::GetConjureKitBridge

function GetSession​

Session GetSession()

Gets currently joined Session object.

Return: Session object or null when not in a Session

Reimplemented by: Auki::ConjureKit::ConjureKit::GetSession

function Connect​

void Connect(
Action< Session > onComplete =null,
Action< string > onFailed =null
)

Call when you want to connect to the Aukiverse with the default or current ConjureKitConfiguration. The onComplete callback is invoked with the same argument as ConjureKit.OnJoined, prior to ConjureKit.OnJoined.

Parameters:

  • onComplete Callback on success (invoked before ConjureKit.OnJoined)
  • onFailed Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Connect

function Connect​

void Connect(
string sessionId,
Action< Session > onComplete =null,
Action< string > onFailed =null
)

Call when you want to connect to the Aukiverse to a specific session with the default or current ConjureKitConfiguration. The session argument can also be set to the empty string in which case a new session will be created.

Parameters:

  • sessionId Desired Session id (can be left blank)
  • onComplete Callback on success (invoked before ConjureKit.OnJoined)
  • onFailed Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Connect

function Connect​

void Connect(
string sessionId,
string configUri,
Action< Session > onComplete =null,
Action< string > onFailed =null
)

Call when you want to connect to the Aukiverse to a specific session with a custom ConjureKitConfiguration URI. The initialization process related to the configUri is idempotent, and will not result in re-initialization if the same URI is provided twice.

Parameters:

  • sessionId Desired Session id (can be left blank)
  • configUri Custom configUri
  • onComplete Callback on success (invoked before ConjureKit.OnJoined)
  • onFailed Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Connect

function Connect​

void Connect(
string sessionId,
ConjureKitConfiguration configuration,
Action< Session > onComplete =null,
Action< string > onFailed =null
)

Call when you want to connect to the Aukiverse to a specific session with a custom ConjureKitConfiguration struct. The initialization process related to the configUri is idempotent, and will not result in re-initialization if the same struct is provided twice.

Parameters:

Reimplemented by: Auki::ConjureKit::ConjureKit::Connect

function IsInitialized​

bool IsInitialized(
string configUri,
out string reason
)

Determines if ConjureKit and all of its modules are initialized for a specific given configuration URI. Returns also a reason for not being initialized.

Parameters:

  • configUri URI for configuration.
  • reason Reason for not being initialized.

Return: true if they are initialized, false if not.

Reimplemented by: Auki::ConjureKit::ConjureKit::IsInitialized

function IsInitialized​

bool IsInitialized(
out string reason
)

Determines if ConjureKit and all of its modules are initialized for the configuration currently being available or used. Returns also a reason for not being initialized.

Parameters:

  • reason Reason for not being initialized.

Return: true if they are initialized, false if not.

Reimplemented by: Auki::ConjureKit::ConjureKit::IsInitialized

function IsInitialized​

bool IsInitialized(
string configUri =""
)

Determines if ConjureKit and all of its modules are initialized for the configuration currently being used or, when a URI is provided, for the given configuration URI.

Parameters:

  • configUri Optional URI for configuration.

Return: true if they are initialized, false if not.

Reimplemented by: Auki::ConjureKit::ConjureKit::IsInitialized

function Init​

void Init(
string configUrl,
Action onComplete =null,
Action< string > onFailed =null
)

Optional manual initialization ConjureKit and its modules for a non-default configUrl. Note that one must be in a Disconnected or Initializing state to call this function.

Parameters:

  • configUrl Url of the configuration file (json)
  • onComplete Callback on success
  • onFailed Callback on failure

Reimplemented by: Auki::ConjureKit::ConjureKit::Init

function Init​

void Init(
ConjureKitConfiguration configuration,
Action onComplete =null,
Action< string > onFailed =null
)

Optional manual initialization of ConjureKit and its modules for a given ConjureKitConfiguration object. One must be in a Disconnected or Initializing state to call this function.

Parameters:

Reimplemented by: Auki::ConjureKit::ConjureKit::Init

function ConnectionErrorMessageIsInternetConnectivityIssue​

bool ConnectionErrorMessageIsInternetConnectivityIssue(
string errorMessage
)

Tells whether a string returned by the onError callback of ConjureKit.Connect() denotes an internet connectivity issue.

Parameters:

  • errorMessage The argument passed to the ConjureKit onError callback

Return: bool

Reimplemented by: Auki::ConjureKit::ConjureKit::ConnectionErrorMessageIsInternetConnectivityIssue

function Disconnect​

void Disconnect()

Call to disconnect from a session.

Reimplemented by: Auki::ConjureKit::ConjureKit::Disconnect

function SetHagallFeatureConfiguration​

void SetHagallFeatureConfiguration(
IEnumerable< string > modules =null,
IEnumerable< string > featureFlags =null
)

Sets lists of required Hagall modules and feature flags.

Parameters:

  • modules List of required Hagall modules, default is null for none
  • featureFlags List of required Hagall feature flags, default is null for none

Reimplemented by: Auki::ConjureKit::ConjureKit::SetHagallFeatureConfiguration

function SetHagallMinVersion​

void SetHagallMinVersion(
string version
)

Sets application-side request for minimum Hagall version.

Parameters:

  • version Hagall version number in format vMajor[.Minor][.Patch](e.g.,)

Reimplemented by: Auki::ConjureKit::ConjureKit::SetHagallMinVersion

function AddComponentType​

void AddComponentType(
string componentTypeName,
Action< uint > onComplete,
Action< string > onError =null
)

Low-level ECS method to add a component type to the Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::AddComponentType

function GetComponentTypeId​

void GetComponentTypeId(
string componentTypeName,
Action< uint > onComplete,
Action< string > onError =null
)

Low-level ECS method to get the id of a component type by name from a Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::GetComponentTypeId

function GetComponentTypeName​

void GetComponentTypeName(
uint componentTypeId,
Action< string > onComplete,
Action< string > onError =null
)

Low-level ECS method to get the name of a component type by id from a Hagall Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::GetComponentTypeName

function AddComponent​

void AddComponent(
uint componentTypeId,
uint entityId,
byte[] data,
Action onComplete,
Action< string > onError =null
)

Low-level ECS method to add a component to an Entity in a Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::AddComponent

function DeleteComponent​

void DeleteComponent(
uint componentTypeId,
uint entityId,
Action onComplete,
Action< string > onError =null
)

Low-level ECS method to delete a component from an Entity in a Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::DeleteComponent

function GetComponents​

void GetComponents(
uint componentTypeId,
Action< List< EntityComponent >> onComplete,
Action< string > onError =null
)

Low-level ECS method to get all components of a component type in a Session. Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::GetComponents

function UpdateComponent​

bool UpdateComponent(
uint componentTypeId,
uint entityId,
byte[] data
)

Low-level ECS method to update a component on an Entity in a Session. Might later be replaced by Systems.

Return: bool indicating success or failure of putting update message on send queue

Reimplemented by: Auki::ConjureKit::ConjureKit::UpdateComponent

function SubscribeToComponentType​

void SubscribeToComponentType(
uint componentTypeId,
Action onComplete,
Action< string > onError =null
)

Low-level ECS method to subscribe to updates of a component type Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::SubscribeToComponentType

function UnsubscribeToComponentType​

void UnsubscribeToComponentType(
uint componentTypeId,
Action onComplete,
Action< string > onError =null
)

Low-level ECS method to unsubscribe to updates of a component type Might later be replaced by Systems.

Reimplemented by: Auki::ConjureKit::ConjureKit::UnsubscribeToComponentType

Public Property Documentation​

property OnInit​

Action< ConjureKitConfiguration > OnInit;

Called after successful initialization or re-initialization of ConjureKit and its modules. The argument passed to OnInit is the configuration for which initialization took place.

property OnParticipantJoined​

Action< Participant > OnParticipantJoined;

Called when a new Participant joins the Session.

Return: Joining Participant object

property OnParticipantLeft​

Action< uint > OnParticipantLeft;

Called when a Participant left the Session.

Return: Id of Participant that left

property OnEntityAdded​

Action< Entity > OnEntityAdded;

Called when an Entity is added to the Session.

Return: Added Entity object

Note: This event is triggered only for entities created by other participants in the session.

property OnEntityAddedResponse​

Action< Entity > OnEntityAddedResponse;

Called when an Entity add request was successful.

Return: Added Entity object

property OnEntityDeleted​

Action< uint > OnEntityDeleted;

Called when an Entity was deleted from the Session.

Return: Id of deleted Entity

Note: This event is triggered only for entities deleted by other participants in the session.

property OnEntityDeletedResponse​

Action< uint > OnEntityDeletedResponse;

Called when an Entity delete request was successful.

Return: Id of deleted Entity

property OnJoined​

Action< Session > OnJoined;

Called when a Session was joined.

property OnParticipantEntityCreated​

Action< Entity > OnParticipantEntityCreated;

Called after calibration or immediately after joining a Session if this Participant is its host.

Return: ParticipantEntity object

property OnLeft​

Action< Session > OnLeft;

Called when a Session was left. The argument is an inert copy of the old Session object as it stood before leaving.

property OnStateChanged​

Action< State > OnStateChanged;

Called when the ConjureKit state has changed.

Return: New ConjureKit state

property OnEntityUpdatePose​

Action< Entity > OnEntityUpdatePose;

Called when an Entity's Pose has been updated.

property OnCustomMessageBroadcast​

Action< CustomMessageBroadcast > OnCustomMessageBroadcast;

Called when a custom message broadcast has been received.

Return: CustomMessageBroadcast object

property OnApplicationBackground​

Action OnApplicationBackground;

Called when the application was sent to the background.

property OnApplicationForeground​

Action OnApplicationForeground;

Called when the application was sent to the foreground.

property OnComponentUpdate​

Action< ComponentUpdateBroadcast > OnComponentUpdate;

Low-level ECS callback method that is called when a component update is broadcast from a Session. Might later be replaced by Systems.

Return: ComponentUpdateBroadcast

property OnComponentAdd​

Action< ComponentAddBroadcast > OnComponentAdd;

Low-level ECS callback method that is called when a component is added to an Entity in a Session. Might later be replaced by Systems.

Return: ComponentAddBroadcast

property OnComponentDelete​

Action< ComponentDeleteBroadcast > OnComponentDelete;

Low-level ECS callback method that is called when a component is deleted from an Entity in a Session. Might later be replaced by Systems.

Return: ComponentDeleteBroadcast