Declares ignite::binary::BinaryType class template and helping macros to declare binary type specialisation for user types.  
More...
#include <stdint.h>
#include <ignite/common/common.h>
#include <ignite/impl/binary/binary_type_impl.h>
Go to the source code of this file.
Declares ignite::binary::BinaryType class template and helping macros to declare binary type specialisation for user types. 
 
◆ IGNITE_BINARY_GET_FIELD_ID_AS_HASH
      
        
          | #define IGNITE_BINARY_GET_FIELD_ID_AS_HASH | 
        
      
 
Value:static int32_t GetFieldId(const char* name) \
{ \
}
IGNITE_IMPORT_EXPORT int32_t GetBinaryStringHashCode(const char *val)
Get binary string hash code. 
Definition: binary_type.cpp:24
 
 
Default implementation of GetFieldId() function which returns Java-way hash code of the string. 
 
 
◆ IGNITE_BINARY_GET_NULL_DEFAULT_CTOR
      
        
          | #define IGNITE_BINARY_GET_NULL_DEFAULT_CTOR | 
          ( | 
            | 
          T | ) | 
           | 
        
      
 
Value:static void GetNull(T& dst) \
{ \
    dst = T(); \
}
 
Implementation of GetNull() function which returns an instance created with defult constructor. 
 
 
◆ IGNITE_BINARY_GET_NULL_NULLPTR
      
        
          | #define IGNITE_BINARY_GET_NULL_NULLPTR | 
          ( | 
            | 
          T | ) | 
           | 
        
      
 
Value:static void GetNull(T& dst) \
{ \
    dst = 0; \
}
 
Implementation of GetNull() function which returns NULL pointer. 
 
 
◆ IGNITE_BINARY_GET_TYPE_ID_AS_CONST
      
        
          | #define IGNITE_BINARY_GET_TYPE_ID_AS_CONST | 
          ( | 
            | 
          id | ) | 
           | 
        
      
 
Value:static int32_t GetTypeId() \
{ \
    return id; \
}
 
Implementation of GetTypeId() which returns predefined constant. 
 
 
◆ IGNITE_BINARY_GET_TYPE_ID_AS_HASH
      
        
          | #define IGNITE_BINARY_GET_TYPE_ID_AS_HASH | 
          ( | 
            | 
          typeName | ) | 
           | 
        
      
 
Value:static int32_t GetTypeId() \
{ \
}
IGNITE_IMPORT_EXPORT int32_t GetBinaryStringHashCode(const char *val)
Get binary string hash code. 
Definition: binary_type.cpp:24
 
 
Implementation of GetTypeId() which returns hash of passed type name. 
 
 
◆ IGNITE_BINARY_GET_TYPE_NAME_AS_IS
      
        
          | #define IGNITE_BINARY_GET_TYPE_NAME_AS_IS | 
          ( | 
            | 
          typeName | ) | 
           | 
        
      
 
Value:static void GetTypeName(std::string& dst) \
{ \
    dst = #typeName; \
}
 
Implementation of GetTypeName() which returns type name as is. 
 
 
◆ IGNITE_BINARY_IS_NULL_FALSE
      
        
          | #define IGNITE_BINARY_IS_NULL_FALSE | 
          ( | 
            | 
          T | ) | 
           | 
        
      
 
Value:static bool IsNull(const T& obj) \
{ \
    return false; \
}
 
Implementation of IsNull() function which always returns false. 
 
 
◆ IGNITE_BINARY_IS_NULL_IF_NULLPTR
      
        
          | #define IGNITE_BINARY_IS_NULL_IF_NULLPTR | 
          ( | 
            | 
          T | ) | 
           | 
        
      
 
Value:static bool IsNull(const T& obj) \
{ \
    return obj; \
}
 
Implementation of IsNull() function which return true if passed object is null pointer. 
 
 
◆ IGNITE_BINARY_TYPE_START
      
        
          | #define IGNITE_BINARY_TYPE_START | 
          ( | 
            | 
          T | ) | 
           | 
        
      
 
Value:template<> \
struct BinaryType<T> \
{
 
Start binary type definition.