Repository: ignite Updated Branches: refs/heads/ignite-1364 [created] 0735eb237
http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/impl/portable/portable_utils.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/impl/portable/portable_utils.cpp b/modules/platform/src/main/cpp/core/src/impl/portable/portable_utils.cpp new file mode 100644 index 0000000..4842f32 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/impl/portable/portable_utils.cpp @@ -0,0 +1,206 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/interop/interop.h" +#include "gridgain/impl/portable/portable_utils.h" + +using namespace gridgain::impl::interop; +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace impl + { + namespace portable + { + int8_t PortableUtils::ReadInt8(InteropInputStream* stream) + { + return stream->ReadInt8(); + } + + void PortableUtils::WriteInt8(InteropOutputStream* stream, int8_t val) + { + stream->WriteInt8(val); + } + + void PortableUtils::ReadInt8Array(InteropInputStream* stream, int8_t* res, const int32_t len) + { + stream->ReadInt8Array(res, len); + } + + void PortableUtils::WriteInt8Array(InteropOutputStream* stream, const int8_t* val, const int32_t len) + { + stream->WriteInt8Array(val, len); + } + + bool PortableUtils::ReadBool(InteropInputStream* stream) + { + return stream->ReadBool(); + } + + void PortableUtils::WriteBool(InteropOutputStream* stream, bool val) + { + stream->WriteBool(val); + } + + void PortableUtils::ReadBoolArray(InteropInputStream* stream, bool* res, const int32_t len) + { + stream->ReadBoolArray(res, len); + } + + void PortableUtils::WriteBoolArray(InteropOutputStream* stream, const bool* val, const int32_t len) + { + stream->WriteBoolArray(val, len); + } + + int16_t PortableUtils::ReadInt16(InteropInputStream* stream) + { + return stream->ReadInt16(); + } + + void PortableUtils::WriteInt16(InteropOutputStream* stream, int16_t val) + { + stream->WriteInt16(val); + } + + void PortableUtils::ReadInt16Array(InteropInputStream* stream, int16_t* res, const int32_t len) + { + stream->ReadInt16Array(res, len); + } + + void PortableUtils::WriteInt16Array(InteropOutputStream* stream, const int16_t* val, const int32_t len) + { + stream->WriteInt16Array(val, len); + } + + uint16_t PortableUtils::ReadUInt16(InteropInputStream* stream) + { + return stream->ReadUInt16(); + } + + void PortableUtils::WriteUInt16(InteropOutputStream* stream, uint16_t val) + { + stream->WriteUInt16(val); + } + + void PortableUtils::ReadUInt16Array(InteropInputStream* stream, uint16_t* res, const int32_t len) + { + stream->ReadUInt16Array(res, len); + } + + void PortableUtils::WriteUInt16Array(InteropOutputStream* stream, const uint16_t* val, const int32_t len) + { + stream->WriteUInt16Array(val, len); + } + + int32_t PortableUtils::ReadInt32(InteropInputStream* stream) + { + return stream->ReadInt32(); + } + + void PortableUtils::WriteInt32(InteropOutputStream* stream, int32_t val) + { + stream->WriteInt32(val); + } + + void PortableUtils::ReadInt32Array(InteropInputStream* stream, int32_t* res, const int32_t len) + { + stream->ReadInt32Array(res, len); + } + + void PortableUtils::WriteInt32Array(InteropOutputStream* stream, const int32_t* val, const int32_t len) + { + stream->WriteInt32Array(val, len); + } + + int64_t PortableUtils::ReadInt64(InteropInputStream* stream) + { + return stream->ReadInt64(); + } + + void PortableUtils::WriteInt64(InteropOutputStream* stream, int64_t val) + { + stream->WriteInt64(val); + } + + void PortableUtils::ReadInt64Array(InteropInputStream* stream, int64_t* res, const int32_t len) + { + stream->ReadInt64Array(res, len); + } + + void PortableUtils::WriteInt64Array(InteropOutputStream* stream, const int64_t* val, const int32_t len) + { + stream->WriteInt64Array(val, len); + } + + float PortableUtils::ReadFloat(InteropInputStream* stream) + { + return stream->ReadFloat(); + } + + void PortableUtils::WriteFloat(InteropOutputStream* stream, float val) + { + stream->WriteFloat(val); + } + + void PortableUtils::ReadFloatArray(InteropInputStream* stream, float* res, const int32_t len) + { + stream->ReadFloatArray(res, len); + } + + void PortableUtils::WriteFloatArray(InteropOutputStream* stream, const float* val, const int32_t len) + { + stream->WriteFloatArray(val, len); + } + + double PortableUtils::ReadDouble(InteropInputStream* stream) + { + return stream->ReadDouble(); + } + + void PortableUtils::WriteDouble(InteropOutputStream* stream, double val) + { + stream->WriteDouble(val); + } + + void PortableUtils::ReadDoubleArray(InteropInputStream* stream, double* res, const int32_t len) + { + stream->ReadDoubleArray(res, len); + } + + void PortableUtils::WriteDoubleArray(InteropOutputStream* stream, const double* val, const int32_t len) + { + stream->WriteDoubleArray(val, len); + } + + Guid PortableUtils::ReadGuid(interop::InteropInputStream* stream) + { + int64_t most = stream->ReadInt64(); + int64_t least = stream->ReadInt64(); + + return Guid(most, least); + } + + void PortableUtils::WriteGuid(interop::InteropOutputStream* stream, const Guid val) + { + stream->WriteInt64(val.GetMostSignificantBits()); + stream->WriteInt64(val.GetLeastSignificantBits()); + } + + void PortableUtils::WriteString(interop::InteropOutputStream* stream, const char* val, const int32_t len) + { + stream->WriteBool(false); + stream->WriteInt32(len); + + for (int i = 0; i < len; i++) + stream->WriteUInt16(*(val + i)); + } + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/impl/portable/portable_writer_impl.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/impl/portable/portable_writer_impl.cpp b/modules/platform/src/main/cpp/core/src/impl/portable/portable_writer_impl.cpp new file mode 100644 index 0000000..6bf2703 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/impl/portable/portable_writer_impl.cpp @@ -0,0 +1,592 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/portable/portable_writer_impl.h" +#include "gridgain/grid_error.h" + +using namespace gridgain::impl::interop; +using namespace gridgain::impl::portable; +using namespace gridgain::portable; + +namespace gridgain +{ + namespace impl + { + namespace portable + { + PortableWriterImpl::PortableWriterImpl(InteropOutputStream* stream, PortableIdResolver* idRslvr, + PortableMetadataManager* metaMgr, PortableMetadataHandler* metaHnd) : + stream(stream), idRslvr(idRslvr), metaMgr(metaMgr), metaHnd(metaHnd), typeId(idRslvr->GetTypeId()), + elemIdGen(0), elemId(0), elemCnt(0), elemPos(-1), rawPos(-1) + { + // No-op. + } + + PortableWriterImpl::PortableWriterImpl(InteropOutputStream* stream, PortableMetadataManager* metaMgr) : + stream(stream), idRslvr(NULL), metaMgr(metaMgr), metaHnd(NULL), typeId(0), + elemIdGen(0), elemId(0), elemCnt(0), elemPos(-1), rawPos(0) + { + // No-op. + } + + void PortableWriterImpl::WriteInt8(const int8_t val) + { + WritePrimitiveRaw<int8_t>(val, PortableUtils::WriteInt8); + } + + void PortableWriterImpl::WriteInt8Array(const int8_t* val, const int32_t len) + { + WritePrimitiveArrayRaw<int8_t>(val, len, PortableUtils::WriteInt8Array, GG_TYPE_ARRAY_BYTE); + } + + void PortableWriterImpl::WriteInt8(const char* fieldName, const int8_t val) + { + WritePrimitive<int8_t>(fieldName, val, PortableUtils::WriteInt8, GG_TYPE_BYTE, 1); + } + + void PortableWriterImpl::WriteInt8Array(const char* fieldName, const int8_t* val, const int32_t len) + { + WritePrimitiveArray<int8_t>(fieldName, val, len, PortableUtils::WriteInt8Array, GG_TYPE_ARRAY_BYTE, 0); + } + + void PortableWriterImpl::WriteBool(const bool val) + { + WritePrimitiveRaw<bool>(val, PortableUtils::WriteBool); + } + + void PortableWriterImpl::WriteBoolArray(const bool* val, const int32_t len) + { + WritePrimitiveArrayRaw<bool>(val, len, PortableUtils::WriteBoolArray, GG_TYPE_ARRAY_BOOL); + } + + void PortableWriterImpl::WriteBool(const char* fieldName, const bool val) + { + WritePrimitive<bool>(fieldName, val, PortableUtils::WriteBool, GG_TYPE_BOOL, 1); + } + + void PortableWriterImpl::WriteBoolArray(const char* fieldName, const bool* val, const int32_t len) + { + WritePrimitiveArray<bool>(fieldName, val, len, PortableUtils::WriteBoolArray, GG_TYPE_ARRAY_BOOL, 0); + } + + void PortableWriterImpl::WriteInt16(const int16_t val) + { + WritePrimitiveRaw<int16_t>(val, PortableUtils::WriteInt16); + } + + void PortableWriterImpl::WriteInt16Array(const int16_t* val, const int32_t len) + { + WritePrimitiveArrayRaw<int16_t>(val, len, PortableUtils::WriteInt16Array, GG_TYPE_ARRAY_SHORT); + } + + void PortableWriterImpl::WriteInt16(const char* fieldName, const int16_t val) + { + WritePrimitive<int16_t>(fieldName, val, PortableUtils::WriteInt16, GG_TYPE_SHORT, 2); + } + + void PortableWriterImpl::WriteInt16Array(const char* fieldName, const int16_t* val, const int32_t len) + { + WritePrimitiveArray<int16_t>(fieldName, val, len, PortableUtils::WriteInt16Array, GG_TYPE_ARRAY_SHORT, 1); + } + + void PortableWriterImpl::WriteUInt16(const uint16_t val) + { + WritePrimitiveRaw<uint16_t>(val, PortableUtils::WriteUInt16); + } + + void PortableWriterImpl::WriteUInt16Array(const uint16_t* val, const int32_t len) + { + WritePrimitiveArrayRaw<uint16_t>(val, len, PortableUtils::WriteUInt16Array, GG_TYPE_ARRAY_CHAR); + } + + void PortableWriterImpl::WriteUInt16(const char* fieldName, const uint16_t val) + { + WritePrimitive<uint16_t>(fieldName, val, PortableUtils::WriteUInt16, GG_TYPE_CHAR, 2); + } + + void PortableWriterImpl::WriteUInt16Array(const char* fieldName, const uint16_t* val, const int32_t len) + { + WritePrimitiveArray<uint16_t>(fieldName, val, len, PortableUtils::WriteUInt16Array, GG_TYPE_ARRAY_CHAR, 1); + } + + void PortableWriterImpl::WriteInt32(const int32_t val) + { + WritePrimitiveRaw<int32_t>(val, PortableUtils::WriteInt32); + } + + void PortableWriterImpl::WriteInt32Array(const int32_t* val, const int32_t len) + { + WritePrimitiveArrayRaw<int32_t>(val, len, PortableUtils::WriteInt32Array, GG_TYPE_ARRAY_INT); + } + + void PortableWriterImpl::WriteInt32(const char* fieldName, const int32_t val) + { + WritePrimitive<int32_t>(fieldName, val, PortableUtils::WriteInt32, GG_TYPE_INT, 4); + } + + void PortableWriterImpl::WriteInt32Array(const char* fieldName, const int32_t* val, const int32_t len) + { + WritePrimitiveArray<int32_t>(fieldName, val, len, PortableUtils::WriteInt32Array, GG_TYPE_ARRAY_INT, 2); + } + + void PortableWriterImpl::WriteInt64(const int64_t val) + { + WritePrimitiveRaw<int64_t>(val, PortableUtils::WriteInt64); + } + + void PortableWriterImpl::WriteInt64Array(const int64_t* val, const int32_t len) + { + WritePrimitiveArrayRaw<int64_t>(val, len, PortableUtils::WriteInt64Array, GG_TYPE_ARRAY_LONG); + } + + void PortableWriterImpl::WriteInt64(const char* fieldName, const int64_t val) + { + WritePrimitive<int64_t>(fieldName, val, PortableUtils::WriteInt64, GG_TYPE_LONG, 8); + } + + void PortableWriterImpl::WriteInt64Array(const char* fieldName, const int64_t* val, const int32_t len) + { + WritePrimitiveArray<int64_t>(fieldName, val, len, PortableUtils::WriteInt64Array, GG_TYPE_ARRAY_LONG, 3); + } + + void PortableWriterImpl::WriteFloat(const float val) + { + WritePrimitiveRaw<float>(val, PortableUtils::WriteFloat); + } + + void PortableWriterImpl::WriteFloatArray(const float* val, const int32_t len) + { + WritePrimitiveArrayRaw<float>(val, len, PortableUtils::WriteFloatArray, GG_TYPE_ARRAY_FLOAT); + } + + void PortableWriterImpl::WriteFloat(const char* fieldName, const float val) + { + WritePrimitive<float>(fieldName, val, PortableUtils::WriteFloat, GG_TYPE_FLOAT, 4); + } + + void PortableWriterImpl::WriteFloatArray(const char* fieldName, const float* val, const int32_t len) + { + WritePrimitiveArray<float>(fieldName, val, len, PortableUtils::WriteFloatArray, GG_TYPE_ARRAY_FLOAT, 2); + } + + void PortableWriterImpl::WriteDouble(const double val) + { + WritePrimitiveRaw<double>(val, PortableUtils::WriteDouble); + } + + void PortableWriterImpl::WriteDoubleArray(const double* val, const int32_t len) + { + WritePrimitiveArrayRaw<double>(val, len, PortableUtils::WriteDoubleArray, GG_TYPE_ARRAY_DOUBLE); + } + + void PortableWriterImpl::WriteDouble(const char* fieldName, const double val) + { + WritePrimitive<double>(fieldName, val, PortableUtils::WriteDouble, GG_TYPE_DOUBLE, 8); + } + + void PortableWriterImpl::WriteDoubleArray(const char* fieldName, const double* val, const int32_t len) + { + WritePrimitiveArray<double>(fieldName, val, len, PortableUtils::WriteDoubleArray, GG_TYPE_ARRAY_DOUBLE, 3); + } + + void PortableWriterImpl::WriteGuid(const Guid val) + { + CheckRawMode(true); + CheckSingleMode(true); + + stream->WriteInt8(GG_TYPE_UUID); + + PortableUtils::WriteGuid(stream, val); + } + + void PortableWriterImpl::WriteGuidArray(const Guid* val, const int32_t len) + { + CheckRawMode(true); + CheckSingleMode(true); + + if (val) + { + stream->WriteInt8(GG_TYPE_ARRAY_UUID); + stream->WriteInt32(len); + + for (int i = 0; i < len; i++) + { + Guid elem = *(val + i); + + stream->WriteInt8(GG_TYPE_UUID); + PortableUtils::WriteGuid(stream, elem); + } + } + else + stream->WriteInt8(GG_HDR_NULL); + } + + void PortableWriterImpl::WriteGuid(const char* fieldName, const Guid val) + { + CheckRawMode(false); + CheckSingleMode(true); + + WriteFieldIdAndLength(fieldName, GG_TYPE_UUID, 1 + 16); + + stream->WriteInt8(GG_TYPE_UUID); + + PortableUtils::WriteGuid(stream, val); + } + + void PortableWriterImpl::WriteGuidArray(const char* fieldName, const Guid* val, const int32_t len) + { + CheckRawMode(false); + CheckSingleMode(true); + + WriteFieldId(fieldName, GG_TYPE_ARRAY_UUID); + + if (val) + { + stream->WriteInt32(5 + len * 17); + stream->WriteInt8(GG_TYPE_ARRAY_UUID); + stream->WriteInt32(len); + + for (int i = 0; i < len; i++) + { + Guid elem = *(val + i); + + WriteTopObject(elem); + } + } + else + { + stream->WriteInt32(1); + stream->WriteInt8(GG_HDR_NULL); + } + } + + void PortableWriterImpl::WriteString(const char* val, const int32_t len) + { + CheckRawMode(true); + CheckSingleMode(true); + + if (val) + { + stream->WriteInt8(GG_TYPE_STRING); + + PortableUtils::WriteString(stream, val, len); + } + else + stream->WriteInt8(GG_HDR_NULL); + } + + void PortableWriterImpl::WriteString(const char* fieldName, const char* val, const int32_t len) + { + CheckRawMode(false); + CheckSingleMode(true); + + WriteFieldId(fieldName, GG_TYPE_STRING); + + if (val) + { + int32_t lenPos = stream->Position(); + stream->Position(lenPos + 4); + + stream->WriteInt8(GG_TYPE_STRING); + stream->WriteBool(false); + stream->WriteInt32(len); + + for (int i = 0; i < len; i++) + stream->WriteUInt16(*(val + i)); + + stream->WriteInt32(lenPos, stream->Position() - lenPos - 4); + } + else + { + stream->WriteInt32(1); + stream->WriteInt8(GG_HDR_NULL); + } + } + + int32_t PortableWriterImpl::WriteStringArray() + { + StartContainerSession(true); + + stream->WriteInt8(GG_TYPE_ARRAY_STRING); + stream->Position(stream->Position() + 4); + + return elemId; + } + + int32_t PortableWriterImpl::WriteStringArray(const char* fieldName) + { + StartContainerSession(false); + + WriteFieldIdSkipLength(fieldName, GG_TYPE_ARRAY_STRING); + + stream->WriteInt8(GG_TYPE_ARRAY_STRING); + stream->Position(stream->Position() + 4); + + return elemId; + } + + void PortableWriterImpl::WriteStringElement(int32_t id, const char* val, int32_t len) + { + CheckSession(id); + + if (val) + { + stream->WriteInt8(GG_TYPE_STRING); + + PortableUtils::WriteString(stream, val, len); + } + else + stream->WriteInt8(GG_HDR_NULL); + + elemCnt++; + } + + void PortableWriterImpl::WriteNull() + { + CheckRawMode(true); + CheckSingleMode(true); + + stream->WriteInt8(GG_HDR_NULL); + } + + void PortableWriterImpl::WriteNull(const char* fieldName) + { + CheckRawMode(false); + CheckSingleMode(true); + + WriteFieldIdAndLength(fieldName, GG_TYPE_OBJECT, 1); + stream->WriteInt8(GG_HDR_NULL); + } + + int32_t PortableWriterImpl::WriteArray() + { + StartContainerSession(true); + + stream->WriteInt8(GG_TYPE_ARRAY); + stream->Position(stream->Position() + 4); + + return elemId; + } + + int32_t PortableWriterImpl::WriteArray(const char* fieldName) + { + StartContainerSession(false); + + WriteFieldIdSkipLength(fieldName, GG_TYPE_ARRAY); + + stream->WriteInt8(GG_TYPE_ARRAY); + stream->Position(stream->Position() + 4); + + return elemId; + } + + int32_t PortableWriterImpl::WriteCollection(CollectionType typ) + { + StartContainerSession(true); + + stream->WriteInt8(GG_TYPE_COLLECTION); + stream->Position(stream->Position() + 4); + stream->WriteInt8(typ); + + return elemId; + } + + int32_t PortableWriterImpl::WriteCollection(const char* fieldName, CollectionType typ) + { + StartContainerSession(false); + + WriteFieldIdSkipLength(fieldName, GG_TYPE_COLLECTION); + + stream->WriteInt8(GG_TYPE_COLLECTION); + stream->Position(stream->Position() + 4); + stream->WriteInt8(typ); + + return elemId; + } + + int32_t PortableWriterImpl::WriteMap(gridgain::portable::MapType typ) + { + StartContainerSession(true); + + stream->WriteInt8(GG_TYPE_MAP); + stream->Position(stream->Position() + 4); + stream->WriteInt8(typ); + + return elemId; + } + + int32_t PortableWriterImpl::WriteMap(const char* fieldName, gridgain::portable::MapType typ) + { + StartContainerSession(false); + + WriteFieldIdSkipLength(fieldName, GG_TYPE_MAP); + + stream->WriteInt8(GG_TYPE_MAP); + stream->Position(stream->Position() + 4); + stream->WriteInt8(typ); + + return elemId; + } + + void PortableWriterImpl::CommitContainer(int32_t id) + { + CheckSession(id); + + if (rawPos == -1) + { + int32_t len = stream->Position() - elemPos - 4; + + stream->WriteInt32(elemPos + 4, len); + stream->WriteInt32(elemPos + 9, elemCnt); + } + else + stream->WriteInt32(elemPos + 1, elemCnt); + + elemId = 0; + elemCnt = 0; + elemPos = -1; + } + + void PortableWriterImpl::SetRawMode() + { + CheckRawMode(false); + CheckSingleMode(true); + + rawPos = stream->Position(); + } + + int32_t PortableWriterImpl::GetRawPosition() + { + return rawPos == -1 ? stream->Position() : rawPos; + } + + void PortableWriterImpl::CheckRawMode(bool expected) + { + bool rawMode = rawPos != -1; + + if (expected && !rawMode) { + GG_ERROR_1(GridError::GG_ERR_PORTABLE, "Operation can be performed only in raw mode."); + } + else if (!expected && rawMode) { + GG_ERROR_1(GridError::GG_ERR_PORTABLE, "Operation cannot be performed in raw mode."); + } + } + + void PortableWriterImpl::CheckSingleMode(bool expected) + { + if (expected && elemId != 0) { + GG_ERROR_1(GridError::GG_ERR_PORTABLE, "Operation cannot be performed when container is being written."); + } + else if (!expected && elemId == 0) { + GG_ERROR_1(GridError::GG_ERR_PORTABLE, "Operation can be performed only when container is being written."); + } + } + + void PortableWriterImpl::StartContainerSession(bool expRawMode) + { + CheckRawMode(expRawMode); + CheckSingleMode(true); + + elemId = ++elemIdGen; + elemPos = stream->Position(); + } + + void PortableWriterImpl::CheckSession(int32_t expSes) + { + if (elemId != expSes) + { + GG_ERROR_1(GridError::GG_ERR_PORTABLE, "Containter write session has been finished or is not started yet."); + } + } + + void PortableWriterImpl::WriteFieldId(const char* fieldName, int32_t fieldTypeId) + { + int32_t fieldId = idRslvr->GetFieldId(typeId, fieldName); + + stream->WriteInt32(fieldId); + + if (metaHnd) + metaHnd->OnFieldWritten(fieldId, fieldName, fieldTypeId); + } + + void PortableWriterImpl::WriteFieldIdSkipLength(const char* fieldName, int32_t fieldTypeId) + { + WriteFieldId(fieldName, fieldTypeId); + + stream->Position(stream->Position() + 4); + } + + void PortableWriterImpl::WriteFieldIdAndLength(const char* fieldName, int32_t fieldTypeId, int32_t len) + { + WriteFieldId(fieldName, fieldTypeId); + + stream->WriteInt32(len); + } + + template <> + void PortableWriterImpl::WriteTopObject<int8_t>(const int8_t& obj) + { + WriteTopObject0<int8_t>(obj, PortableUtils::WriteInt8, GG_TYPE_BYTE); + } + + template <> + void PortableWriterImpl::WriteTopObject<bool>(const bool& obj) + { + WriteTopObject0<bool>(obj, PortableUtils::WriteBool, GG_TYPE_BOOL); + } + + template <> + void PortableWriterImpl::WriteTopObject<int16_t>(const int16_t& obj) + { + WriteTopObject0<int16_t>(obj, PortableUtils::WriteInt16, GG_TYPE_SHORT); + } + + template <> + void PortableWriterImpl::WriteTopObject<uint16_t>(const uint16_t& obj) + { + WriteTopObject0<uint16_t>(obj, PortableUtils::WriteUInt16, GG_TYPE_CHAR); + } + + template <> + void PortableWriterImpl::WriteTopObject<int32_t>(const int32_t& obj) + { + WriteTopObject0<int32_t>(obj, PortableUtils::WriteInt32, GG_TYPE_INT); + } + + template <> + void PortableWriterImpl::WriteTopObject<int64_t>(const int64_t& obj) + { + WriteTopObject0<int64_t>(obj, PortableUtils::WriteInt64, GG_TYPE_LONG); + } + + template <> + void PortableWriterImpl::WriteTopObject<float>(const float& obj) + { + WriteTopObject0<float>(obj, PortableUtils::WriteFloat, GG_TYPE_FLOAT); + } + + template <> + void PortableWriterImpl::WriteTopObject<double>(const double& obj) + { + WriteTopObject0<double>(obj, PortableUtils::WriteDouble, GG_TYPE_DOUBLE); + } + + template <> + void PortableWriterImpl::WriteTopObject<Guid>(const Guid& obj) + { + WriteTopObject0<Guid>(obj, PortableUtils::WriteGuid, GG_TYPE_UUID); + } + + InteropOutputStream* PortableWriterImpl::GetStream() + { + return stream; + } + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_containers.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_containers.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_containers.cpp new file mode 100644 index 0000000..d02d224 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_containers.cpp @@ -0,0 +1,68 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/portable/portable_containers.h" + +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace portable + { + PortableStringArrayWriter::PortableStringArrayWriter(PortableWriterImpl* impl, const int32_t id) : + impl(impl), id(id) + { + // No-op. + } + + void PortableStringArrayWriter::Write(const char* val) + { + if (val) + Write(val, static_cast<int32_t>(strlen(val))); + else + Write(NULL, -1); + } + + void PortableStringArrayWriter::Write(const char* val, const int32_t len) + { + impl->WriteStringElement(id, val, len); + } + + void PortableStringArrayWriter::Close() + { + impl->CommitContainer(id); + } + + PortableStringArrayReader::PortableStringArrayReader(impl::portable::PortableReaderImpl* impl, + int32_t id, int32_t size) : impl(impl), id(id), size(size) + { + // No-op. + } + + bool PortableStringArrayReader::HasNext() + { + return impl->HasNextElement(id); + } + + int32_t PortableStringArrayReader::GetNext(char* res, const int32_t len) + { + return impl->ReadStringElement(id, res, len); + } + + int32_t PortableStringArrayReader::GetSize() + { + return size; + } + + bool PortableStringArrayReader::IsNull() + { + return size == -1; + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_raw_reader.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_raw_reader.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_raw_reader.cpp new file mode 100644 index 0000000..26aea33 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_raw_reader.cpp @@ -0,0 +1,128 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/portable/portable_reader_impl.h" +#include "gridgain/portable/portable_raw_reader.h" + +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace portable + { + PortableRawReader::PortableRawReader(PortableReaderImpl* impl) : impl(impl) + { + // No-op. + } + + int8_t PortableRawReader::ReadInt8() + { + return impl->ReadInt8(); + } + + int32_t PortableRawReader::ReadInt8Array(int8_t* res, const int32_t len) + { + return impl->ReadInt8Array(res, len); + } + + bool PortableRawReader::ReadBool() + { + return impl->ReadBool(); + } + + int32_t PortableRawReader::ReadBoolArray(bool* res, const int32_t len) + { + return impl->ReadBoolArray(res, len); + } + + int16_t PortableRawReader::ReadInt16() + { + return impl->ReadInt16(); + } + + int32_t PortableRawReader::ReadInt16Array(int16_t* res, const int32_t len) + { + return impl->ReadInt16Array(res, len); + } + + uint16_t PortableRawReader::ReadUInt16() + { + return impl->ReadUInt16(); + } + + int32_t PortableRawReader::ReadUInt16Array(uint16_t* res, const int32_t len) + { + return impl->ReadUInt16Array(res, len); + } + + int32_t PortableRawReader::ReadInt32() + { + return impl->ReadInt32(); + } + + int32_t PortableRawReader::ReadInt32Array(int32_t* res, const int32_t len) + { + return impl->ReadInt32Array(res, len); + } + + int64_t PortableRawReader::ReadInt64() + { + return impl->ReadInt64(); + } + + int32_t PortableRawReader::ReadInt64Array(int64_t* res, const int32_t len) + { + return impl->ReadInt64Array(res, len); + } + + float PortableRawReader::ReadFloat() + { + return impl->ReadFloat(); + } + + int32_t PortableRawReader::ReadFloatArray(float* res, const int32_t len) + { + return impl->ReadFloatArray(res, len); + } + + double PortableRawReader::ReadDouble() + { + return impl->ReadDouble(); + } + + int32_t PortableRawReader::ReadDoubleArray(double* res, const int32_t len) + { + return impl->ReadDoubleArray(res, len); + } + + Guid PortableRawReader::ReadGuid() + { + return impl->ReadGuid(); + } + + int32_t PortableRawReader::ReadGuidArray(Guid* res, const int32_t len) + { + return impl->ReadGuidArray(res, len); + } + + int32_t PortableRawReader::ReadString(char* res, const int32_t len) + { + return impl->ReadString(res, len); + } + + PortableStringArrayReader PortableRawReader::ReadStringArray() + { + int32_t size; + + int32_t id = impl->ReadStringArray(&size); + + return PortableStringArrayReader(impl, id, size); + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_raw_writer.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_raw_writer.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_raw_writer.cpp new file mode 100644 index 0000000..674b546 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_raw_writer.cpp @@ -0,0 +1,139 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/portable/portable_writer_impl.h" +#include "gridgain/portable/portable_raw_writer.h" + +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace portable + { + PortableRawWriter::PortableRawWriter(PortableWriterImpl* impl) : impl(impl) + { + // No-op. + } + + void PortableRawWriter::WriteInt8(const int8_t val) + { + impl->WriteInt8(val); + } + + void PortableRawWriter::WriteInt8Array(const int8_t* val, const int32_t len) + { + impl->WriteInt8Array(val, len); + } + + void PortableRawWriter::WriteBool(const bool val) + { + impl->WriteBool(val); + } + + void PortableRawWriter::WriteBoolArray(const bool* val, const int32_t len) + { + impl->WriteBoolArray(val, len); + } + + void PortableRawWriter::WriteInt16(const int16_t val) + { + impl->WriteInt16(val); + } + + void PortableRawWriter::WriteInt16Array(const int16_t* val, const int32_t len) + { + impl->WriteInt16Array(val, len); + } + + void PortableRawWriter::WriteUInt16(const uint16_t val) + { + impl->WriteUInt16(val); + } + + void PortableRawWriter::WriteUInt16Array(const uint16_t* val, const int32_t len) + { + impl->WriteUInt16Array(val, len); + } + + void PortableRawWriter::WriteInt32(const int32_t val) + { + impl->WriteInt32(val); + } + + void PortableRawWriter::WriteInt32Array(const int32_t* val, const int32_t len) + { + impl->WriteInt32Array(val, len); + } + + void PortableRawWriter::WriteInt64(const int64_t val) + { + impl->WriteInt64(val); + } + + void PortableRawWriter::WriteInt64Array(const int64_t* val, const int32_t len) + { + impl->WriteInt64Array(val, len); + } + + void PortableRawWriter::WriteFloat(const float val) + { + impl->WriteFloat(val); + } + + void PortableRawWriter::WriteFloatArray(const float* val, const int32_t len) + { + impl->WriteFloatArray(val, len); + } + + void PortableRawWriter::WriteDouble(const double val) + { + impl->WriteDouble(val); + } + + void PortableRawWriter::WriteDoubleArray(const double* val, const int32_t len) + { + impl->WriteDoubleArray(val, len); + } + + void PortableRawWriter::WriteGuid(const Guid val) + { + impl->WriteGuid(val); + } + + void PortableRawWriter::WriteGuidArray(const Guid* val, const int32_t len) + { + impl->WriteGuidArray(val, len); + } + + void PortableRawWriter::WriteString(const char* val) + { + if (val) + WriteString(val, static_cast<int32_t>(strlen(val))); + else + WriteNull(); + } + + void PortableRawWriter::WriteString(const char* val, const int32_t len) + { + impl->WriteString(val, len); + } + + PortableStringArrayWriter PortableRawWriter::WriteStringArray() + { + int32_t id = impl->WriteStringArray(); + + return PortableStringArrayWriter(impl, id); + } + + void PortableRawWriter::WriteNull() + { + impl->WriteNull(); + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_reader.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_reader.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_reader.cpp new file mode 100644 index 0000000..393221b --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_reader.cpp @@ -0,0 +1,135 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/portable/portable_reader_impl.h" +#include "gridgain/portable/portable_reader.h" + +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace portable + { + PortableReader::PortableReader(PortableReaderImpl* impl) : impl(impl) + { + // No-op. + } + + int8_t PortableReader::ReadInt8(const char* fieldName) + { + return impl->ReadInt8(fieldName); + } + + int32_t PortableReader::ReadInt8Array(const char* fieldName, int8_t* res, const int32_t len) + { + return impl->ReadInt8Array(fieldName, res, len); + } + + bool PortableReader::ReadBool(const char* fieldName) + { + return impl->ReadBool(fieldName); + } + + int32_t PortableReader::ReadBoolArray(const char* fieldName, bool* res, const int32_t len) + { + return impl->ReadBoolArray(fieldName, res, len); + } + + int16_t PortableReader::ReadInt16(const char* fieldName) + { + return impl->ReadInt16(fieldName); + } + + int32_t PortableReader::ReadInt16Array(const char* fieldName, int16_t* res, const int32_t len) + { + return impl->ReadInt16Array(fieldName, res, len); + } + + uint16_t PortableReader::ReadUInt16(const char* fieldName) + { + return impl->ReadUInt16(fieldName); + } + + int32_t PortableReader::ReadUInt16Array(const char* fieldName, uint16_t* res, const int32_t len) + { + return impl->ReadUInt16Array(fieldName, res, len); + } + + int32_t PortableReader::ReadInt32(const char* fieldName) + { + return impl->ReadInt32(fieldName); + } + + int32_t PortableReader::ReadInt32Array(const char* fieldName, int32_t* res, const int32_t len) + { + return impl->ReadInt32Array(fieldName, res, len); + } + + int64_t PortableReader::ReadInt64(const char* fieldName) + { + return impl->ReadInt64(fieldName); + } + + int32_t PortableReader::ReadInt64Array(const char* fieldName, int64_t* res, const int32_t len) + { + return impl->ReadInt64Array(fieldName, res, len); + } + + float PortableReader::ReadFloat(const char* fieldName) + { + return impl->ReadFloat(fieldName); + } + + int32_t PortableReader::ReadFloatArray(const char* fieldName, float* res, const int32_t len) + { + return impl->ReadFloatArray(fieldName, res, len); + } + + double PortableReader::ReadDouble(const char* fieldName) + { + return impl->ReadDouble(fieldName); + } + + int32_t PortableReader::ReadDoubleArray(const char* fieldName, double* res, const int32_t len) + { + return impl->ReadDoubleArray(fieldName, res, len); + } + + Guid PortableReader::ReadGuid(const char* fieldName) + { + return impl->ReadGuid(fieldName); + } + + int32_t PortableReader::ReadGuidArray(const char* fieldName, Guid* res, const int32_t len) + { + return impl->ReadGuidArray(fieldName, res, len); + } + + int32_t PortableReader::ReadString(const char* fieldName, char* res, const int32_t len) + { + return impl->ReadString(fieldName, res, len); + } + + PortableStringArrayReader PortableReader::ReadStringArray(const char* fieldName) + { + int32_t size; + + int32_t id = impl->ReadStringArray(fieldName, &size); + + return PortableStringArrayReader(impl, id, size); + } + + PortableRawReader PortableReader::RawReader() + { + impl->SetRawMode(); + + return PortableRawReader(impl); + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_type.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_type.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_type.cpp new file mode 100644 index 0000000..ff0c10e --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_type.cpp @@ -0,0 +1,43 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/portable/portable_type.h" + +namespace gridgain +{ + namespace portable + { + int32_t GetPortableStringHashCode(const char* val) + { + if (val) + { + int32_t hash = 0; + + int i = 0; + + while (true) + { + char c = *(val + i++); + + if (c == '\0') + break; + + if ('A' <= c && c <= 'Z') + c = c | 0x20; + + hash = 31 * hash + c; + } + + return hash; + } + else + return 0; + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/core/src/portable/portable_writer.cpp ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/core/src/portable/portable_writer.cpp b/modules/platform/src/main/cpp/core/src/portable/portable_writer.cpp new file mode 100644 index 0000000..f123311 --- /dev/null +++ b/modules/platform/src/main/cpp/core/src/portable/portable_writer.cpp @@ -0,0 +1,146 @@ +/* + * Copyright (C) GridGain Systems. All Rights Reserved. + * _________ _____ __________________ _____ + * __ ____/___________(_)______ /__ ____/______ ____(_)_______ + * _ / __ __ ___/__ / _ __ / _ / __ _ __ `/__ / __ __ \ + * / /_/ / _ / _ / / /_/ / / /_/ / / /_/ / _ / _ / / / + * \____/ /_/ /_/ \_,__/ \____/ \__,_/ /_/ /_/ /_/ + */ + +#include "gridgain/impl/portable/portable_writer_impl.h" +#include "gridgain/portable/portable_writer.h" + +using namespace gridgain::impl::portable; + +namespace gridgain +{ + namespace portable + { + PortableWriter::PortableWriter(PortableWriterImpl* impl) : impl(impl) + { + // No-op. + } + + void PortableWriter::WriteInt8(const char* fieldName, const int8_t val) + { + impl->WriteInt8(fieldName, val); + } + + void PortableWriter::WriteInt8Array(const char* fieldName, const int8_t* val, const int32_t len) + { + impl->WriteInt8Array(fieldName, val, len); + } + + void PortableWriter::WriteBool(const char* fieldName, const bool val) + { + impl->WriteBool(fieldName, val); + } + + void PortableWriter::WriteBoolArray(const char* fieldName, const bool* val, const int32_t len) + { + impl->WriteBoolArray(fieldName, val, len); + } + + void PortableWriter::WriteInt16(const char* fieldName, const int16_t val) + { + impl->WriteInt16(fieldName, val); + } + + void PortableWriter::WriteInt16Array(const char* fieldName, const int16_t* val, const int32_t len) + { + impl->WriteInt16Array(fieldName, val, len); + } + + void PortableWriter::WriteUInt16(const char* fieldName, const uint16_t val) + { + impl->WriteUInt16(fieldName, val); + } + + void PortableWriter::WriteUInt16Array(const char* fieldName, const uint16_t* val, const int32_t len) + { + impl->WriteUInt16Array(fieldName, val, len); + } + + void PortableWriter::WriteInt32(const char* fieldName, const int32_t val) + { + impl->WriteInt32(fieldName, val); + } + + void PortableWriter::WriteInt32Array(const char* fieldName, const int32_t* val, const int32_t len) + { + impl->WriteInt32Array(fieldName, val, len); + } + + void PortableWriter::WriteInt64(const char* fieldName, const int64_t val) + { + impl->WriteInt64(fieldName, val); + } + + void PortableWriter::WriteInt64Array(const char* fieldName, const int64_t* val, const int32_t len) + { + impl->WriteInt64Array(fieldName, val, len); + } + + void PortableWriter::WriteFloat(const char* fieldName, const float val) + { + impl->WriteFloat(fieldName, val); + } + + void PortableWriter::WriteFloatArray(const char* fieldName, const float* val, const int32_t len) + { + impl->WriteFloatArray(fieldName, val, len); + } + + void PortableWriter::WriteDouble(const char* fieldName, const double val) + { + impl->WriteDouble(fieldName, val); + } + + void PortableWriter::WriteDoubleArray(const char* fieldName, const double* val, const int32_t len) + { + impl->WriteDoubleArray(fieldName, val, len); + } + + void PortableWriter::WriteGuid(const char* fieldName, const Guid val) + { + impl->WriteGuid(fieldName, val); + } + + void PortableWriter::WriteGuidArray(const char* fieldName, const Guid* val, const int32_t len) + { + impl->WriteGuidArray(fieldName, val, len); + } + + void PortableWriter::WriteString(const char* fieldName, const char* val) + { + if (val) + WriteString(fieldName, val, static_cast<int32_t>(strlen(val))); + else + WriteNull(fieldName); + } + + void PortableWriter::WriteString(const char* fieldName, const char* val, const int32_t len) + { + impl->WriteString(fieldName, val, len); + } + + PortableStringArrayWriter PortableWriter::WriteStringArray(const char* fieldName) + { + int32_t id = impl->WriteStringArray(fieldName); + + return PortableStringArrayWriter(impl, id); + } + + void PortableWriter::WriteNull(const char* fieldName) + { + impl->WriteNull(fieldName); + } + + PortableRawWriter PortableWriter::RawWriter() + { + impl->SetRawMode(); + + return PortableRawWriter(impl); + } + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/project/vs/README.TXT ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/project/vs/README.TXT b/modules/platform/src/main/cpp/project/vs/README.TXT new file mode 100644 index 0000000..f4fb456 --- /dev/null +++ b/modules/platform/src/main/cpp/project/vs/README.TXT @@ -0,0 +1 @@ +Contains Visual Studio project artifacts. \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/project/vs/gridgain.sdf ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/project/vs/gridgain.sdf b/modules/platform/src/main/cpp/project/vs/gridgain.sdf new file mode 100644 index 0000000..8223a32 Binary files /dev/null and b/modules/platform/src/main/cpp/project/vs/gridgain.sdf differ http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/project/vs/gridgain.sln ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/project/vs/gridgain.sln b/modules/platform/src/main/cpp/project/vs/gridgain.sln new file mode 100644 index 0000000..3d656bc --- /dev/null +++ b/modules/platform/src/main/cpp/project/vs/gridgain.sln @@ -0,0 +1,46 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Visual Studio 2010 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common", "..\..\common\project\vs\common.vcxproj", "{4F7E4917-4612-4B96-9838-025711ADE391}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "core", "..\..\core\project\vs\core.vcxproj", "{E2DEA693-F2EA-43C2-A813-053378F6E4DB}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "core-test", "..\..\core-test\project\vs\core-test.vcxproj", "{133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|Win32.ActiveCfg = Debug|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|Win32.Build.0 = Debug|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|x64.ActiveCfg = Debug|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|x64.Build.0 = Debug|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|Win32.ActiveCfg = Release|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|Win32.Build.0 = Release|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|x64.ActiveCfg = Release|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|x64.Build.0 = Release|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|Win32.ActiveCfg = Debug|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|Win32.Build.0 = Debug|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|x64.ActiveCfg = Debug|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|x64.Build.0 = Debug|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|Win32.ActiveCfg = Release|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|Win32.Build.0 = Release|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|x64.ActiveCfg = Release|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|x64.Build.0 = Release|x64 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Debug|Win32.ActiveCfg = Debug|Win32 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Debug|Win32.Build.0 = Debug|Win32 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Debug|x64.ActiveCfg = Debug|x64 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Debug|x64.Build.0 = Debug|x64 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Release|Win32.ActiveCfg = Release|Win32 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Release|Win32.Build.0 = Release|Win32 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Release|x64.ActiveCfg = Release|x64 + {133A22DB-FD60-44B9-B5E3-6CBB3EA5ABF0}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal http://git-wip-us.apache.org/repos/asf/ignite/blob/1e18fa32/modules/platform/src/main/cpp/project/vs/gridgain.slnrel ---------------------------------------------------------------------- diff --git a/modules/platform/src/main/cpp/project/vs/gridgain.slnrel b/modules/platform/src/main/cpp/project/vs/gridgain.slnrel new file mode 100644 index 0000000..347fc04 --- /dev/null +++ b/modules/platform/src/main/cpp/project/vs/gridgain.slnrel @@ -0,0 +1,33 @@ + +Microsoft Visual Studio Solution File, Format Version 11.00 +# Visual Studio 2010 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common", "..\..\common\project\vs\common.vcxproj", "{4F7E4917-4612-4B96-9838-025711ADE391}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "core", "..\..\core\project\vs\core.vcxproj", "{E2DEA693-F2EA-43C2-A813-053378F6E4DB}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|Win32.ActiveCfg = Debug|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|Win32.Build.0 = Debug|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|x64.ActiveCfg = Debug|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Debug|x64.Build.0 = Debug|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|Win32.ActiveCfg = Release|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|Win32.Build.0 = Release|Win32 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|x64.ActiveCfg = Release|x64 + {E2DEA693-F2EA-43C2-A813-053378F6E4DB}.Release|x64.Build.0 = Release|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|Win32.ActiveCfg = Debug|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|Win32.Build.0 = Debug|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|x64.ActiveCfg = Debug|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Debug|x64.Build.0 = Debug|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|Win32.ActiveCfg = Release|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|Win32.Build.0 = Release|Win32 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|x64.ActiveCfg = Release|x64 + {4F7E4917-4612-4B96-9838-025711ADE391}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal
