client-c  0.8.1
kaa.h File Reference

Kaa C endpoint library. More...

#include <stdbool.h>
#include "kaa_context.h"
#include "kaa_error.h"
+ Include dependency graph for kaa.h:

Go to the source code of this file.

Functions

kaa_error_t kaa_init (kaa_context_t **kaa_context_p)
 Creates and initializes general Kaa endpoint context. More...
 
kaa_error_t kaa_start (kaa_context_t *kaa_context)
 Starts Kaa's workflow. More...
 
kaa_error_t kaa_stop (kaa_context_t *kaa_context)
 Stops Kaa's workflow. More...
 
kaa_error_t kaa_deinit (kaa_context_t *kaa_context)
 De-initializes and destroys general Kaa endpoint context. More...
 
bool kaa_process_failover (kaa_context_t *kaa_context)
 Processes failovers. More...
 
kaa_error_t kaa_check_readiness (kaa_context_t *kaa_context)
 Checks if Kaa context is initialized and ready to be used. More...
 

Detailed Description

Kaa C endpoint library.

Copyright 2014-2016 CyberVision, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

 http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Supplies API for initializing and de-initializing general Kaa endpoint context.

Definition in file kaa.h.

Function Documentation

kaa_error_t kaa_check_readiness ( kaa_context_t kaa_context)

Checks if Kaa context is initialized and ready to be used.

Parameters
[in]kaa_contextPointer to an initialized Kaa endpoint context.
Returns
KAA_ERR_NONE if Kaa context is ready to be used.
kaa_error_t kaa_deinit ( kaa_context_t kaa_context)

De-initializes and destroys general Kaa endpoint context.

After a successful call kaa_context pointer becomes invalid.

Parameters
[in]kaa_contextPointer to an initialized Kaa endpoint context.
Returns
Error code.
kaa_error_t kaa_init ( kaa_context_t **  kaa_context_p)

Creates and initializes general Kaa endpoint context.

The endpoint SDK assumes ownership of the memory allocated for the context and nested data structures.

Parameters
[in,out]kaa_context_pPointer to return the address of initialized Kaa endpoint context to.
Returns
Error code.
bool kaa_process_failover ( kaa_context_t kaa_context)

Processes failovers.

Parameters
[in]kaa_contextBootstrap manager.
Return values
trueFailover is scheduled
falseOtherwise
kaa_error_t kaa_start ( kaa_context_t kaa_context)

Starts Kaa's workflow.

Note
Should be called after kaa_init().
Parameters
[in]kaa_contextPointer to an initialized Kaa endpoint context.
Returns
Error code.
kaa_error_t kaa_stop ( kaa_context_t kaa_context)

Stops Kaa's workflow.

Note
Should be called after kaa_start().
Parameters
[in]kaa_contextPointer to an initialized Kaa endpoint context.
Returns
Error code.