ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject ignite git commit: IGNITE-1364: GridEnvironment -> IgniteEnvironment.
Date Thu, 03 Sep 2015 12:31:50 GMT
Repository: ignite
Updated Branches:
  refs/heads/ignite-1364 778170b4a -> 6b9ec314b


IGNITE-1364: GridEnvironment -> IgniteEnvironment.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/6b9ec314
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/6b9ec314
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/6b9ec314

Branch: refs/heads/ignite-1364
Commit: 6b9ec314b406a5763dda4fcc6566d15b03799e46
Parents: 778170b
Author: vozerov-gridgain <vozerov@gridgain.com>
Authored: Thu Sep 3 15:32:30 2015 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Thu Sep 3 15:32:30 2015 +0300

----------------------------------------------------------------------
 modules/platform/src/main/cpp/core/Makefile.am  |   2 +-
 .../src/main/cpp/core/include/Makefile.am       |   2 +-
 .../core/include/ignite/impl/cache/cache_impl.h |   6 +-
 .../ignite/impl/cache/query/query_impl.h        |   6 +-
 .../core/include/ignite/impl/grid_environment.h | 130 ---------------
 .../include/ignite/impl/ignite_environment.h    | 130 +++++++++++++++
 .../cpp/core/include/ignite/impl/ignite_impl.h  |   6 +-
 .../portable/portable_metadata_updater_impl.h   |   6 +-
 .../src/main/cpp/core/project/vs/core.vcxproj   |   4 +-
 .../cpp/core/project/vs/core.vcxproj.filters    |   4 +-
 .../main/cpp/core/project/vs/core.vcxprojrel    |   4 +-
 .../platform/src/main/cpp/core/src/ignition.cpp |  14 +-
 .../main/cpp/core/src/impl/cache/cache_impl.cpp |   2 +-
 .../core/src/impl/cache/query/query_impl.cpp    |   2 +-
 .../main/cpp/core/src/impl/grid_environment.cpp | 166 -------------------
 .../cpp/core/src/impl/ignite_environment.cpp    | 166 +++++++++++++++++++
 .../src/main/cpp/core/src/impl/ignite_impl.cpp  |   2 +-
 .../portable/portable_metadata_updater_impl.cpp |   2 +-
 18 files changed, 327 insertions(+), 327 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/Makefile.am
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/Makefile.am b/modules/platform/src/main/cpp/core/Makefile.am
index 27b7213..dcbfdee 100644
--- a/modules/platform/src/main/cpp/core/Makefile.am
+++ b/modules/platform/src/main/cpp/core/Makefile.am
@@ -45,7 +45,7 @@ COMMON_SRC = os/linux/src/impl/utils.cpp \
              src/portable/portable_reader.cpp \
              src/portable/portable_writer.cpp \
              src/impl/portable/portable_metadata_updater_impl.cpp \
-             src/impl/grid_environment.cpp \
+             src/impl/ignite_environment.cpp \
              src/impl/cache/query/query_impl.cpp \
              src/impl/cache/cache_impl.cpp \
              src/impl/ignite_impl.cpp \

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/Makefile.am
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/Makefile.am b/modules/platform/src/main/cpp/core/include/Makefile.am
index bba330b..10a223e 100644
--- a/modules/platform/src/main/cpp/core/include/Makefile.am
+++ b/modules/platform/src/main/cpp/core/include/Makefile.am
@@ -42,7 +42,7 @@ nobase_include_HEADERS = ignite/cache/cache.h \
                          ignite/impl/portable/portable_reader_impl.h \
                          ignite/impl/portable/portable_utils.h \
                          ignite/impl/portable/portable_writer_impl.h \
-                         ignite/impl/grid_environment.h \
+                         ignite/impl/ignite_environment.h \
                          ignite/impl/ignite_impl.h \
                          ignite/impl/handle_registry.h \
                          ignite/impl/operations.h \

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/cache/cache_impl.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/cache/cache_impl.h b/modules/platform/src/main/cpp/core/include/ignite/impl/cache/cache_impl.h
index c797c29..8c744e0 100644
--- a/modules/platform/src/main/cpp/core/include/ignite/impl/cache/cache_impl.h
+++ b/modules/platform/src/main/cpp/core/include/ignite/impl/cache/cache_impl.h
@@ -21,7 +21,7 @@
 #include "ignite/cache/query/query_scan.h"
 #include "ignite/cache/query/query_sql.h"
 #include "ignite/cache/query/query_text.h"
-#include "ignite/impl/grid_environment.h"
+#include "ignite/impl/ignite_environment.h"
 #include "ignite/impl/cache/query/query_impl.h"
 #include "ignite/impl/operations.h"
 
@@ -44,7 +44,7 @@ namespace ignite
                  * @param env Environment.
                  * @param javaRef Reference to java object.
                  */
-                CacheImpl(char* name, ignite::common::concurrent::SharedPointer<GridEnvironment>
env, jobject javaRef);
+                CacheImpl(char* name, ignite::common::concurrent::SharedPointer<IgniteEnvironment>
env, jobject javaRef);
                 
                 /**
                  * Destructor.
@@ -322,7 +322,7 @@ namespace ignite
                 char* name; 
                 
                 /** Environment. */
-                ignite::common::concurrent::SharedPointer<GridEnvironment> env;
+                ignite::common::concurrent::SharedPointer<IgniteEnvironment> env;
                 
                 /** Handle to Java object. */
                 jobject javaRef;                     

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/cache/query/query_impl.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/cache/query/query_impl.h
b/modules/platform/src/main/cpp/core/include/ignite/impl/cache/query/query_impl.h
index 58c6255..e65eeb6 100644
--- a/modules/platform/src/main/cpp/core/include/ignite/impl/cache/query/query_impl.h
+++ b/modules/platform/src/main/cpp/core/include/ignite/impl/cache/query/query_impl.h
@@ -19,7 +19,7 @@
 #define _IGNITE_CACHE_QUERY_IMPL
 
 #include "ignite/ignite_error.h"
-#include "ignite/impl/grid_environment.h"
+#include "ignite/impl/ignite_environment.h"
 #include "ignite/impl/operations.h"
 
 namespace ignite
@@ -42,7 +42,7 @@ namespace ignite
                      * @param env Environment.
                      * @param javaRef Java reference.
                      */
-                    QueryCursorImpl(ignite::common::concurrent::SharedPointer<GridEnvironment>
env, jobject javaRef);
+                    QueryCursorImpl(ignite::common::concurrent::SharedPointer<IgniteEnvironment>
env, jobject javaRef);
 
                     /**
                      * Destructor.
@@ -75,7 +75,7 @@ namespace ignite
 
                 private:
                     /** Environment. */
-                    ignite::common::concurrent::SharedPointer<impl::GridEnvironment>
env;
+                    ignite::common::concurrent::SharedPointer<impl::IgniteEnvironment>
env;
 
                     /** Handle to Java object. */
                     jobject javaRef;

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/grid_environment.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/grid_environment.h b/modules/platform/src/main/cpp/core/include/ignite/impl/grid_environment.h
deleted file mode 100644
index 8731d29..0000000
--- a/modules/platform/src/main/cpp/core/include/ignite/impl/grid_environment.h
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- */
-
-#ifndef _IGNITE_GRID_ENVIRONMENT
-#define _IGNITE_GRID_ENVIRONMENT
-
-#include <ignite/common/concurrent.h>
-#include <ignite/common/java.h>
-
-#include "ignite/impl/interop/interop_memory.h"
-#include "portable/portable_metadata_manager.h"
-
-namespace ignite 
-{    
-    namespace impl 
-    {
-        /**
-         * Defines environment in which Ignite operates.
-         */
-        class IGNITE_IMPORT_EXPORT GridEnvironment
-        {                
-        public:
-            /**
-             * Default constructor.
-             */
-            GridEnvironment();
-
-            /**
-             * Destructor.
-             */
-            ~GridEnvironment();
-
-            /**
-             * Populate callback handlers.
-             *
-             * @param Target (current env wrapped into a shared pointer).
-             * @return JNI handlers.
-             */
-            ignite::common::java::JniHandlers GetJniHandlers(ignite::common::concurrent::SharedPointer<GridEnvironment>*
target);
-                
-            /**
-             * Perform initialization on successful start.
-             *
-             * @param ctx Context.
-             */
-            void Initialize(ignite::common::concurrent::SharedPointer<ignite::common::java::JniContext>
ctx);
-
-            /**
-             * Start callback.
-             *
-             * @param memPtr Memory pointer.
-             */
-            void OnStartCallback(long long memPtr);        
-            
-            /**
-             * Get name of the grid.
-             *
-             * @return Name.
-             */
-            char* GridName();
-
-            /**
-             * Get JNI context.
-             *
-             * @return Context.
-             */
-            ignite::common::java::JniContext* Context();
-
-            /**
-             * Get memory for interop operations.
-             *
-             * @return Memory.
-             */
-            ignite::common::concurrent::SharedPointer<interop::InteropMemory> AllocateMemory();
-
-            /**
-             * Get memory chunk for interop operations with desired capacity.
-             *
-             * @param cap Capacity.
-             * @return Memory.
-             */
-            ignite::common::concurrent::SharedPointer<interop::InteropMemory> AllocateMemory(int32_t
cap);
-
-            /**
-             * Get memory chunk located at the given pointer.
-             *
-             * @param memPtr Memory pointer.
-             * @retrun Memory.
-             */
-            ignite::common::concurrent::SharedPointer<interop::InteropMemory> GetMemory(int64_t
memPtr);
-
-            /**
-             * Get metadata manager.
-             *
-             * @param Metadata manager.
-             */
-            portable::PortableMetadataManager* GetMetadataManager();
-        private:
-            /** Context to access Java. */
-            ignite::common::concurrent::SharedPointer<ignite::common::java::JniContext>
ctx;
-
-            /** Startup latch. */
-            ignite::common::concurrent::SingleLatch* latch;
-
-            /** Grid name. */
-            char* gridName;                                   
-
-            /** Metadata manager. */
-            portable::PortableMetadataManager* metaMgr;       
-
-            IGNITE_NO_COPY_ASSIGNMENT(GridEnvironment);
-        };
-    }    
-}
-
-#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_environment.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_environment.h b/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_environment.h
new file mode 100644
index 0000000..40dc4ae
--- /dev/null
+++ b/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_environment.h
@@ -0,0 +1,130 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.
+ */
+
+#ifndef _IGNITE_ENVIRONMENT
+#define _IGNITE_ENVIRONMENT
+
+#include <ignite/common/concurrent.h>
+#include <ignite/common/java.h>
+
+#include "ignite/impl/interop/interop_memory.h"
+#include "portable/portable_metadata_manager.h"
+
+namespace ignite 
+{    
+    namespace impl 
+    {
+        /**
+         * Defines environment in which Ignite operates.
+         */
+        class IGNITE_IMPORT_EXPORT IgniteEnvironment
+        {                
+        public:
+            /**
+             * Default constructor.
+             */
+            IgniteEnvironment();
+
+            /**
+             * Destructor.
+             */
+            ~IgniteEnvironment();
+
+            /**
+             * Populate callback handlers.
+             *
+             * @param Target (current env wrapped into a shared pointer).
+             * @return JNI handlers.
+             */
+            ignite::common::java::JniHandlers GetJniHandlers(ignite::common::concurrent::SharedPointer<IgniteEnvironment>*
target);
+                
+            /**
+             * Perform initialization on successful start.
+             *
+             * @param ctx Context.
+             */
+            void Initialize(ignite::common::concurrent::SharedPointer<ignite::common::java::JniContext>
ctx);
+
+            /**
+             * Start callback.
+             *
+             * @param memPtr Memory pointer.
+             */
+            void OnStartCallback(long long memPtr);        
+            
+            /**
+             * Get name of the grid.
+             *
+             * @return Name.
+             */
+            char* GridName();
+
+            /**
+             * Get JNI context.
+             *
+             * @return Context.
+             */
+            ignite::common::java::JniContext* Context();
+
+            /**
+             * Get memory for interop operations.
+             *
+             * @return Memory.
+             */
+            ignite::common::concurrent::SharedPointer<interop::InteropMemory> AllocateMemory();
+
+            /**
+             * Get memory chunk for interop operations with desired capacity.
+             *
+             * @param cap Capacity.
+             * @return Memory.
+             */
+            ignite::common::concurrent::SharedPointer<interop::InteropMemory> AllocateMemory(int32_t
cap);
+
+            /**
+             * Get memory chunk located at the given pointer.
+             *
+             * @param memPtr Memory pointer.
+             * @retrun Memory.
+             */
+            ignite::common::concurrent::SharedPointer<interop::InteropMemory> GetMemory(int64_t
memPtr);
+
+            /**
+             * Get metadata manager.
+             *
+             * @param Metadata manager.
+             */
+            portable::PortableMetadataManager* GetMetadataManager();
+        private:
+            /** Context to access Java. */
+            ignite::common::concurrent::SharedPointer<ignite::common::java::JniContext>
ctx;
+
+            /** Startup latch. */
+            ignite::common::concurrent::SingleLatch* latch;
+
+            /** Grid name. */
+            char* gridName;                                   
+
+            /** Metadata manager. */
+            portable::PortableMetadataManager* metaMgr;       
+
+            IGNITE_NO_COPY_ASSIGNMENT(IgniteEnvironment);
+        };
+    }    
+}
+
+#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_impl.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_impl.h b/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_impl.h
index a69b2b5..fab7a2d 100644
--- a/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_impl.h
+++ b/modules/platform/src/main/cpp/core/include/ignite/impl/ignite_impl.h
@@ -22,7 +22,7 @@
 #include <ignite/common/java.h>
 
 #include "ignite/impl/cache/cache_impl.h"
-#include "ignite/impl/grid_environment.h"
+#include "ignite/impl/ignite_environment.h"
 #include "ignite/impl/utils.h"
 
 namespace ignite 
@@ -42,7 +42,7 @@ namespace ignite
              * @param env Environment.
              * @param javaRef Reference to java object.
              */
-            IgniteImpl(ignite::common::concurrent::SharedPointer<GridEnvironment> env,
jobject javaRef);
+            IgniteImpl(ignite::common::concurrent::SharedPointer<IgniteEnvironment>
env, jobject javaRef);
             
             /**
              * Destructor.
@@ -132,7 +132,7 @@ namespace ignite
             }
         private:
             /** Environment. */
-            ignite::common::concurrent::SharedPointer<GridEnvironment> env;
+            ignite::common::concurrent::SharedPointer<IgniteEnvironment> env;
             
             /** Native Java counterpart. */
             jobject javaRef;   

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/include/ignite/impl/portable/portable_metadata_updater_impl.h
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/include/ignite/impl/portable/portable_metadata_updater_impl.h
b/modules/platform/src/main/cpp/core/include/ignite/impl/portable/portable_metadata_updater_impl.h
index 277cd83..832c2a3 100644
--- a/modules/platform/src/main/cpp/core/include/ignite/impl/portable/portable_metadata_updater_impl.h
+++ b/modules/platform/src/main/cpp/core/include/ignite/impl/portable/portable_metadata_updater_impl.h
@@ -20,7 +20,7 @@
 
 #include <ignite/common/exports.h>
 
-#include "ignite/impl/grid_environment.h"
+#include "ignite/impl/ignite_environment.h"
 #include "ignite/impl/portable/portable_metadata_updater.h"
 
 namespace ignite
@@ -41,7 +41,7 @@ namespace ignite
                  * @param env Environment.
                  * @param javaRef Reference to Java object which is able to process metadata
request.
                  */
-                PortableMetadataUpdaterImpl(ignite::common::concurrent::SharedPointer<GridEnvironment>
env, jobject javaRef);
+                PortableMetadataUpdaterImpl(ignite::common::concurrent::SharedPointer<IgniteEnvironment>
env, jobject javaRef);
 
                 /**
                  * Destructor.
@@ -51,7 +51,7 @@ namespace ignite
                 bool Update(Snap* snapshot, IgniteError* err);
             private:
                 /** Environment. */
-                ignite::common::concurrent::SharedPointer<GridEnvironment> env;
+                ignite::common::concurrent::SharedPointer<IgniteEnvironment> env;
                 
                 /** Handle to Java object. */
                 jobject javaRef;                 

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/project/vs/core.vcxproj
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/project/vs/core.vcxproj b/modules/platform/src/main/cpp/core/project/vs/core.vcxproj
index 124bea8..32ea6e4 100644
--- a/modules/platform/src/main/cpp/core/project/vs/core.vcxproj
+++ b/modules/platform/src/main/cpp/core/project/vs/core.vcxproj
@@ -204,7 +204,7 @@
     <ClInclude Include="..\..\include\ignite\guid.h" />
     <ClInclude Include="..\..\include\ignite\impl\cache\cache_impl.h" />
     <ClInclude Include="..\..\include\ignite\impl\cache\query\query_impl.h" />
-    <ClInclude Include="..\..\include\ignite\impl\grid_environment.h" />
+    <ClInclude Include="..\..\include\ignite\impl\ignite_environment.h" />
     <ClInclude Include="..\..\include\ignite\impl\ignite_impl.h" />
     <ClInclude Include="..\..\include\ignite\impl\handle_registry.h" />
     <ClInclude Include="..\..\include\ignite\impl\interop\interop.h" />
@@ -240,7 +240,7 @@
     <ClCompile Include="..\..\src\guid.cpp" />
     <ClCompile Include="..\..\src\impl\cache\cache_impl.cpp" />
     <ClCompile Include="..\..\src\impl\cache\query\query_impl.cpp" />
-    <ClCompile Include="..\..\src\impl\grid_environment.cpp" />
+    <ClCompile Include="..\..\src\impl\ignite_environment.cpp" />
     <ClCompile Include="..\..\src\impl\ignite_impl.cpp" />
     <ClCompile Include="..\..\src\impl\handle_registry.cpp" />
     <ClCompile Include="..\..\src\impl\interop\interop_input_stream.cpp" />

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/project/vs/core.vcxproj.filters
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/project/vs/core.vcxproj.filters b/modules/platform/src/main/cpp/core/project/vs/core.vcxproj.filters
index d7daaca..d01a7f5 100644
--- a/modules/platform/src/main/cpp/core/project/vs/core.vcxproj.filters
+++ b/modules/platform/src/main/cpp/core/project/vs/core.vcxproj.filters
@@ -13,7 +13,7 @@
     <ClCompile Include="..\..\src\impl\interop\interop_output_stream.cpp">
       <Filter>Code\impl\interop</Filter>
     </ClCompile>
-    <ClCompile Include="..\..\src\impl\grid_environment.cpp">
+    <ClCompile Include="..\..\src\impl\ignite_environment.cpp">
       <Filter>Code\impl</Filter>
     </ClCompile>
     <ClCompile Include="..\..\src\impl\ignite_impl.cpp">
@@ -105,7 +105,7 @@
     <ClInclude Include="..\..\include\ignite\impl\interop\interop_output_stream.h">
       <Filter>Code\impl\interop</Filter>
     </ClInclude>
-    <ClInclude Include="..\..\include\ignite\impl\grid_environment.h">
+    <ClInclude Include="..\..\include\ignite\impl\ignite_environment.h">
       <Filter>Code\impl</Filter>
     </ClInclude>
     <ClInclude Include="..\..\include\ignite\impl\ignite_impl.h">

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/project/vs/core.vcxprojrel
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/project/vs/core.vcxprojrel b/modules/platform/src/main/cpp/core/project/vs/core.vcxprojrel
index 124bea8..32ea6e4 100644
--- a/modules/platform/src/main/cpp/core/project/vs/core.vcxprojrel
+++ b/modules/platform/src/main/cpp/core/project/vs/core.vcxprojrel
@@ -204,7 +204,7 @@
     <ClInclude Include="..\..\include\ignite\guid.h" />
     <ClInclude Include="..\..\include\ignite\impl\cache\cache_impl.h" />
     <ClInclude Include="..\..\include\ignite\impl\cache\query\query_impl.h" />
-    <ClInclude Include="..\..\include\ignite\impl\grid_environment.h" />
+    <ClInclude Include="..\..\include\ignite\impl\ignite_environment.h" />
     <ClInclude Include="..\..\include\ignite\impl\ignite_impl.h" />
     <ClInclude Include="..\..\include\ignite\impl\handle_registry.h" />
     <ClInclude Include="..\..\include\ignite\impl\interop\interop.h" />
@@ -240,7 +240,7 @@
     <ClCompile Include="..\..\src\guid.cpp" />
     <ClCompile Include="..\..\src\impl\cache\cache_impl.cpp" />
     <ClCompile Include="..\..\src\impl\cache\query\query_impl.cpp" />
-    <ClCompile Include="..\..\src\impl\grid_environment.cpp" />
+    <ClCompile Include="..\..\src\impl\ignite_environment.cpp" />
     <ClCompile Include="..\..\src\impl\ignite_impl.cpp" />
     <ClCompile Include="..\..\src\impl\handle_registry.cpp" />
     <ClCompile Include="..\..\src\impl\interop\interop_input_stream.cpp" />

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/ignition.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/ignition.cpp b/modules/platform/src/main/cpp/core/src/ignition.cpp
index ccd40fc..ed0731b 100644
--- a/modules/platform/src/main/cpp/core/src/ignition.cpp
+++ b/modules/platform/src/main/cpp/core/src/ignition.cpp
@@ -22,7 +22,7 @@
 #include <ignite/common/exports.h>
 #include <ignite/common/java.h>
 
-#include "ignite/impl/grid_environment.h"
+#include "ignite/impl/ignite_environment.h"
 #include "ignite/impl/ignite_impl.h"
 #include "ignite/impl/utils.h"
 #include "ignite/ignition.h"
@@ -134,8 +134,8 @@ namespace ignite
     {
         bool failed = false;
 
-        SharedPointer<GridEnvironment> env;
-        SharedPointer<GridEnvironment>* envTarget = NULL;
+        SharedPointer<IgniteEnvironment> env;
+        SharedPointer<IgniteEnvironment>* envTarget = NULL;
 
         jobject javaRef = NULL;
 
@@ -208,12 +208,12 @@ namespace ignite
                 // 4. Start JVM if needed.
                 JniErrorInfo jniErr;
 
-                env = SharedPointer<GridEnvironment>(new GridEnvironment());
+                env = SharedPointer<IgniteEnvironment>(new IgniteEnvironment());
 
                 int optsLen;
                 char** opts = CreateJvmOptions(cfg, homeFound ? &home : NULL, cp, &optsLen);
 
-                envTarget = new SharedPointer<GridEnvironment>(env);
+                envTarget = new SharedPointer<IgniteEnvironment>(env);
                 
                 SharedPointer<JniContext> ctx(
                     JniContext::Create(opts, optsLen, env.Get()->GetJniHandlers(envTarget),
&jniErr));
@@ -340,8 +340,8 @@ namespace ignite
                         // 3. Obtain real environment for this instance.
                         JniHandlers* hnds = reinterpret_cast<JniHandlers*>(ptr);
 
-                        SharedPointer<GridEnvironment>* env = 
-                            static_cast<SharedPointer<GridEnvironment>*>(hnds->target);
+                        SharedPointer<IgniteEnvironment>* env =
+                            static_cast<SharedPointer<IgniteEnvironment>*>(hnds->target);
 
                         // 4. Get fresh node reference.
                         jobject ref = ctx.Get()->IgnitionInstance(name0, &jniErr);

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/cache/cache_impl.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/cache/cache_impl.cpp b/modules/platform/src/main/cpp/core/src/impl/cache/cache_impl.cpp
index bf7a126..2f211e7 100644
--- a/modules/platform/src/main/cpp/core/src/impl/cache/cache_impl.cpp
+++ b/modules/platform/src/main/cpp/core/src/impl/cache/cache_impl.cpp
@@ -118,7 +118,7 @@ namespace ignite
             /** Operation: Replace(K, V, V). */
             const int32_t OP_REPLACE_3 = 38;
 
-            CacheImpl::CacheImpl(char* name, SharedPointer<GridEnvironment> env, jobject
javaRef) : 
+            CacheImpl::CacheImpl(char* name, SharedPointer<IgniteEnvironment> env,
jobject javaRef) :
                 name(name), env(env), javaRef(javaRef)
             {
                 // No-op.

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/cache/query/query_impl.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/cache/query/query_impl.cpp b/modules/platform/src/main/cpp/core/src/impl/cache/query/query_impl.cpp
index eb42a3e..7d89321 100644
--- a/modules/platform/src/main/cpp/core/src/impl/cache/query/query_impl.cpp
+++ b/modules/platform/src/main/cpp/core/src/impl/cache/query/query_impl.cpp
@@ -36,7 +36,7 @@ namespace ignite
                 /** Operation: get single entry. */
                 const int32_t OP_GET_SINGLE = 3;
 
-                QueryCursorImpl::QueryCursorImpl(SharedPointer<GridEnvironment> env,
jobject javaRef) : 
+                QueryCursorImpl::QueryCursorImpl(SharedPointer<IgniteEnvironment> env,
jobject javaRef) :
                     env(env), javaRef(javaRef), iterCalled(false), getAllCalled(false), hasNext(false)
                 {
                     // No-op.

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/grid_environment.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/grid_environment.cpp b/modules/platform/src/main/cpp/core/src/impl/grid_environment.cpp
deleted file mode 100644
index 0eaf60d..0000000
--- a/modules/platform/src/main/cpp/core/src/impl/grid_environment.cpp
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- */
-
-#include "ignite/impl/portable/portable_reader_impl.h"
-#include "ignite/impl/grid_environment.h"
-#include "ignite/portable/portable.h"
-
-using namespace ignite::common::concurrent;
-using namespace ignite::common::java;
-using namespace ignite::impl::interop;
-using namespace ignite::impl::portable;
-using namespace ignite::portable;
-
-namespace ignite 
-{
-    namespace impl 
-    {
-        /**
-         * OnStart callback.
-         *
-         * @param target Target environment.
-         * @param memPtr Memory pointer.
-         */
-        void IGNITE_CALL OnStart(void* target, long long memPtr)
-        {
-            SharedPointer<GridEnvironment>* ptr = static_cast<SharedPointer<GridEnvironment>*>(target);
-
-            ptr->Get()->OnStartCallback(memPtr);
-        }
-
-        /**
-         * OnStop callback.
-         *
-         * @param target Target environment.
-         */
-        void IGNITE_CALL OnStop(void* target)
-        {
-            SharedPointer<GridEnvironment>* ptr = static_cast<SharedPointer<GridEnvironment>*>(target);
-
-            delete ptr;
-        } 
-
-        GridEnvironment::GridEnvironment() : ctx(SharedPointer<JniContext>()), latch(new
SingleLatch), gridName(NULL), 
-            metaMgr(new PortableMetadataManager())
-        {
-            // No-op.
-        }
-
-        GridEnvironment::~GridEnvironment() 
-        {
-            delete latch;
-
-            if (gridName)
-                delete gridName;
-
-            delete metaMgr;
-        }
-
-        JniHandlers GridEnvironment::GetJniHandlers(SharedPointer<GridEnvironment>*
target)
-        {
-            JniHandlers hnds = JniHandlers();
-
-            hnds.target = target;
-
-            hnds.onStart = OnStart;
-            hnds.onStop = OnStop;
-
-            hnds.error = NULL;
-
-            return hnds;
-        }
-            
-        void GridEnvironment::Initialize(SharedPointer<JniContext> ctx)
-        {
-            this->ctx = ctx;
-                
-            latch->CountDown();
-        }
-        
-        char* GridEnvironment::GridName() 
-        {
-            return gridName;
-        }
-
-        JniContext* GridEnvironment::Context()
-        {
-            return ctx.Get();
-        }
-
-        SharedPointer<InteropMemory> GridEnvironment::AllocateMemory()
-        {
-            SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(1024));
-
-            return ptr;
-        }
-
-        SharedPointer<InteropMemory> GridEnvironment::AllocateMemory(int32_t cap)
-        {
-            SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(cap));
-
-            return ptr;
-        }
-
-        SharedPointer<InteropMemory> GridEnvironment::GetMemory(int64_t memPtr)
-        {
-            int8_t* memPtr0 = reinterpret_cast<int8_t*>(memPtr);
-
-            int32_t flags = InteropMemory::Flags(memPtr0);
-
-            if (InteropMemory::IsExternal(flags))
-            {
-                SharedPointer<InteropMemory> ptr(new InteropExternalMemory(memPtr0));
-
-                return ptr;
-            }
-            else
-            {
-                SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(memPtr0));
-
-                return ptr;
-            }
-        }
-
-        PortableMetadataManager* GridEnvironment::GetMetadataManager()
-        {
-            return metaMgr;
-        }
-
-        void GridEnvironment::OnStartCallback(long long memPtr)
-        {
-            InteropExternalMemory mem(reinterpret_cast<int8_t*>(memPtr));
-            InteropInputStream stream(&mem);
-
-            PortableReaderImpl reader(&stream);
-            
-            int32_t gridNameLen = reader.ReadString(NULL, 0);
-
-            if (gridNameLen >= 0)
-            {
-                gridName = new char[gridNameLen + 1];
-                reader.ReadString(gridName, gridNameLen + 1);
-            }
-            else
-                gridName = NULL;
-        }
-    }
-}
-
-
-
-
-

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/ignite_environment.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/ignite_environment.cpp b/modules/platform/src/main/cpp/core/src/impl/ignite_environment.cpp
new file mode 100644
index 0000000..033d529
--- /dev/null
+++ b/modules/platform/src/main/cpp/core/src/impl/ignite_environment.cpp
@@ -0,0 +1,166 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.
+ */
+
+#include "ignite/impl/portable/portable_reader_impl.h"
+#include "ignite/impl/ignite_environment.h"
+#include "ignite/portable/portable.h"
+
+using namespace ignite::common::concurrent;
+using namespace ignite::common::java;
+using namespace ignite::impl::interop;
+using namespace ignite::impl::portable;
+using namespace ignite::portable;
+
+namespace ignite 
+{
+    namespace impl 
+    {
+        /**
+         * OnStart callback.
+         *
+         * @param target Target environment.
+         * @param memPtr Memory pointer.
+         */
+        void IGNITE_CALL OnStart(void* target, long long memPtr)
+        {
+            SharedPointer<IgniteEnvironment>* ptr = static_cast<SharedPointer<IgniteEnvironment>*>(target);
+
+            ptr->Get()->OnStartCallback(memPtr);
+        }
+
+        /**
+         * OnStop callback.
+         *
+         * @param target Target environment.
+         */
+        void IGNITE_CALL OnStop(void* target)
+        {
+            SharedPointer<IgniteEnvironment>* ptr = static_cast<SharedPointer<IgniteEnvironment>*>(target);
+
+            delete ptr;
+        } 
+
+        IgniteEnvironment::IgniteEnvironment() : ctx(SharedPointer<JniContext>()),
latch(new SingleLatch), gridName(NULL),
+            metaMgr(new PortableMetadataManager())
+        {
+            // No-op.
+        }
+
+        IgniteEnvironment::~IgniteEnvironment()
+        {
+            delete latch;
+
+            if (gridName)
+                delete gridName;
+
+            delete metaMgr;
+        }
+
+        JniHandlers IgniteEnvironment::GetJniHandlers(SharedPointer<IgniteEnvironment>*
target)
+        {
+            JniHandlers hnds = JniHandlers();
+
+            hnds.target = target;
+
+            hnds.onStart = OnStart;
+            hnds.onStop = OnStop;
+
+            hnds.error = NULL;
+
+            return hnds;
+        }
+            
+        void IgniteEnvironment::Initialize(SharedPointer<JniContext> ctx)
+        {
+            this->ctx = ctx;
+                
+            latch->CountDown();
+        }
+        
+        char* IgniteEnvironment::GridName()
+        {
+            return gridName;
+        }
+
+        JniContext* IgniteEnvironment::Context()
+        {
+            return ctx.Get();
+        }
+
+        SharedPointer<InteropMemory> IgniteEnvironment::AllocateMemory()
+        {
+            SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(1024));
+
+            return ptr;
+        }
+
+        SharedPointer<InteropMemory> IgniteEnvironment::AllocateMemory(int32_t cap)
+        {
+            SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(cap));
+
+            return ptr;
+        }
+
+        SharedPointer<InteropMemory> IgniteEnvironment::GetMemory(int64_t memPtr)
+        {
+            int8_t* memPtr0 = reinterpret_cast<int8_t*>(memPtr);
+
+            int32_t flags = InteropMemory::Flags(memPtr0);
+
+            if (InteropMemory::IsExternal(flags))
+            {
+                SharedPointer<InteropMemory> ptr(new InteropExternalMemory(memPtr0));
+
+                return ptr;
+            }
+            else
+            {
+                SharedPointer<InteropMemory> ptr(new InteropUnpooledMemory(memPtr0));
+
+                return ptr;
+            }
+        }
+
+        PortableMetadataManager* IgniteEnvironment::GetMetadataManager()
+        {
+            return metaMgr;
+        }
+
+        void IgniteEnvironment::OnStartCallback(long long memPtr)
+        {
+            InteropExternalMemory mem(reinterpret_cast<int8_t*>(memPtr));
+            InteropInputStream stream(&mem);
+
+            PortableReaderImpl reader(&stream);
+            
+            int32_t gridNameLen = reader.ReadString(NULL, 0);
+
+            if (gridNameLen >= 0)
+            {
+                gridName = new char[gridNameLen + 1];
+                reader.ReadString(gridName, gridNameLen + 1);
+            }
+            else
+                gridName = NULL;
+        }
+    }
+}
+
+
+
+
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/ignite_impl.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/ignite_impl.cpp b/modules/platform/src/main/cpp/core/src/impl/ignite_impl.cpp
index 189b6b0..51bf87b 100644
--- a/modules/platform/src/main/cpp/core/src/impl/ignite_impl.cpp
+++ b/modules/platform/src/main/cpp/core/src/impl/ignite_impl.cpp
@@ -24,7 +24,7 @@ namespace ignite
 {    
     namespace impl
     {
-        IgniteImpl::IgniteImpl(SharedPointer<GridEnvironment> env, jobject javaRef)
: env(env), javaRef(javaRef)
+        IgniteImpl::IgniteImpl(SharedPointer<IgniteEnvironment> env, jobject javaRef)
: env(env), javaRef(javaRef)
         {
             // No-op.
         }

http://git-wip-us.apache.org/repos/asf/ignite/blob/6b9ec314/modules/platform/src/main/cpp/core/src/impl/portable/portable_metadata_updater_impl.cpp
----------------------------------------------------------------------
diff --git a/modules/platform/src/main/cpp/core/src/impl/portable/portable_metadata_updater_impl.cpp
b/modules/platform/src/main/cpp/core/src/impl/portable/portable_metadata_updater_impl.cpp
index acaa1fe..07a1758 100644
--- a/modules/platform/src/main/cpp/core/src/impl/portable/portable_metadata_updater_impl.cpp
+++ b/modules/platform/src/main/cpp/core/src/impl/portable/portable_metadata_updater_impl.cpp
@@ -35,7 +35,7 @@ namespace ignite
             /** Operation: Clear. */
             const int32_t OP_METADATA = -1;
 
-            PortableMetadataUpdaterImpl::PortableMetadataUpdaterImpl(SharedPointer<GridEnvironment>
env, 
+            PortableMetadataUpdaterImpl::PortableMetadataUpdaterImpl(SharedPointer<IgniteEnvironment>
env,
                 jobject javaRef) :  env(env), javaRef(javaRef)
             {
                 // No-op.


Mime
View raw message