23 #ifndef HAZELCAST_PortableReader 
   24 #define HAZELCAST_PortableReader 
   26 #include "hazelcast/util/HazelcastDll.h" 
   27 #include "hazelcast/client/serialization/pimpl/DefaultPortableReader.h" 
   28 #include "hazelcast/client/serialization/pimpl/MorphingPortableReader.h" 
   31 #if  defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) 
   33 #pragma warning(disable: 4251) //for dll export 
   38         namespace serialization {
 
   41                 class PortableContext;
 
   46             class ClassDefinition;
 
   58                 PortableReader(pimpl::PortableContext& context, pimpl::DataInput& dataInput,
 
   59                                 boost::shared_ptr<ClassDefinition> cd, 
bool isDefaultReader);
 
   70                 int readInt(
const char *fieldName);
 
   77                 long readLong(
const char *fieldName);
 
   84                 bool readBoolean(
const char *fieldName);
 
   91                 byte readByte(
const char *fieldName);
 
   98                 char readChar(
const char *fieldName);
 
  105                 double readDouble(
const char *fieldName);
 
  112                 float readFloat(
const char *fieldName);
 
  119                 short readShort(
const char *fieldName);
 
  126                 std::auto_ptr<std::string> readUTF(
const char *fieldName);
 
  133                 std::auto_ptr<std::vector<byte> > readByteArray(
const char *fieldName);
 
  140                 std::auto_ptr<std::vector<char> > readCharArray(
const char *fieldName);
 
  147                 std::auto_ptr<std::vector<int> > readIntArray(
const char *fieldName);
 
  154                 std::auto_ptr<std::vector<long> > readLongArray(
const char *fieldName);
 
  161                 std::auto_ptr<std::vector<double> > readDoubleArray(
const char *fieldName);
 
  168                 std::auto_ptr<std::vector<float> > readFloatArray(
const char *fieldName);
 
  175                 std::auto_ptr<std::vector<short> > readShortArray(
const char *fieldName);
 
  186                         return defaultPortableReader->readPortable<T>(fieldName);
 
  187                     return morphingPortableReader->readPortable<T>(fieldName);
 
  199                         return defaultPortableReader->readPortableArray<T>(fieldName);
 
  200                     return morphingPortableReader->readPortableArray<T>(fieldName);
 
  220                 bool isDefaultReader;
 
  221                 mutable std::auto_ptr<pimpl::DefaultPortableReader> defaultPortableReader;
 
  222                 mutable std::auto_ptr<pimpl::MorphingPortableReader> morphingPortableReader;
 
  229 #if  defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) 
  233 #endif //HAZELCAST_PortableReader 
std::vector< T > readPortableArray(const char *fieldName)
Definition: PortableReader.h:197
 
Provides a mean of reading portable fields from a binary in form of java primitives arrays of java pr...
Definition: PortableReader.h:52
 
boost::shared_ptr< T > readPortable(const char *fieldName)
Definition: PortableReader.h:184