ua_types_encoding_binary.h 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. /* This Source Code Form is subject to the terms of the Mozilla Public
  2. * License, v. 2.0. If a copy of the MPL was not distributed with this
  3. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  4. #ifndef UA_TYPES_ENCODING_BINARY_H_
  5. #define UA_TYPES_ENCODING_BINARY_H_
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9. #include "ua_types.h"
  10. typedef UA_StatusCode (*UA_exchangeEncodeBuffer)(void *handle, UA_Byte **bufPos, const UA_Byte **bufEnd);
  11. UA_StatusCode
  12. UA_encodeBinary(const void *src, const UA_DataType *type,
  13. UA_Byte **bufPos, const UA_Byte **bufEnd,
  14. UA_exchangeEncodeBuffer exchangeCallback, void *exchangeHandle) UA_FUNC_ATTR_WARN_UNUSED_RESULT;
  15. UA_StatusCode
  16. UA_decodeBinary(const UA_ByteString *src, size_t *offset, void *dst,
  17. const UA_DataType *type, size_t customTypesSize,
  18. const UA_DataType *customTypes) UA_FUNC_ATTR_WARN_UNUSED_RESULT;
  19. size_t UA_calcSizeBinary(void *p, const UA_DataType *type);
  20. #ifdef __cplusplus
  21. }
  22. #endif
  23. #endif /* UA_TYPES_ENCODING_BINARY_H_ */