geode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@apache.org
Subject [07/51] [partial] incubator-geode git commit: Add source for geode c++ and .net clients
Date Thu, 19 May 2016 15:14:14 GMT
http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/TransactionEventM.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/TransactionEventM.cpp b/geode-client-native/src/clicache/TransactionEventM.cpp
new file mode 100644
index 0000000..bf32506
--- /dev/null
+++ b/geode-client-native/src/clicache/TransactionEventM.cpp
@@ -0,0 +1,54 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+#ifdef CSTX_COMMENTED
+#include "gf_includes.hpp"
+#include "TransactionEventM.hpp"
+#include "impl/SafeConvert.hpp"
+#include "CacheM.hpp"
+
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+
+      GemStone::GemFire::Cache::Cache^ TransactionEvent::Cache::get( )
+      {
+        gemfire::CachePtr& cacheptr( NativePtr->getCache( ) );
+        return GemStone::GemFire::Cache::Cache::Create( cacheptr.ptr( ) );
+      }
+
+      TransactionId^ TransactionEvent::TransactionId::get( )
+      {
+        gemfire::TransactionIdPtr& tidptr( NativePtr->getTransactionId( ) );
+        return GemStone::GemFire::Cache::TransactionId::Create( tidptr.ptr( ) );
+      }
+
+      array<EntryEvent^>^ TransactionEvent::Events::get( )
+      {
+        gemfire::VectorOfEntryEvent vee;
+        vee = NativePtr->getEvents();
+        array<EntryEvent^>^ events =
+          gcnew array<EntryEvent^>( vee.size( ) );
+        // Loop through the unmanaged event objects to convert them to the managed objects. 
+        for( int32_t index = 0; index < vee.size( ); index++ )
+        {
+          gemfire::EntryEventPtr& nativeptr( vee[ index ] );
+          EntryEvent entryEvent( nativeptr.ptr( ) );
+          events[ index ] = (%entryEvent);
+        }
+        return events;
+      }
+    }
+  }
+}
+#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/TransactionEventM.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/TransactionEventM.hpp b/geode-client-native/src/clicache/TransactionEventM.hpp
new file mode 100644
index 0000000..abc82db
--- /dev/null
+++ b/geode-client-native/src/clicache/TransactionEventM.hpp
@@ -0,0 +1,73 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+#ifdef CSTX_COMMENTED
+#pragma once
+
+#include "gf_defs.hpp"
+#include "EntryEventM.hpp"
+#include "cppcache/TransactionEvent.hpp"
+#include "impl/NativeWrapper.hpp"
+#include "TransactionIdM.hpp"
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+      ref class Cache;
+
+      /// <summary>
+      /// This class encapsulates events that occur for an transaction in a cache.
+      /// </summary>
+      public ref class TransactionEvent sealed
+        : public Internal::SBWrap<gemfire::TransactionEvent>
+      {
+      public:
+
+        /// <summary>
+        /// Gets the transaction id for this transaction.
+        /// </summary>
+        property GemStone::GemFire::Cache::TransactionId^ TransactionId
+        {
+          GemStone::GemFire::Cache::TransactionId^ get( );
+        }
+
+     		/// <summary>
+        /// Returns an ordered list of every event for this transaction.
+        /// The event order is consistent with the order in which the operations were
+        /// performed during the transaction.
+        /// </summary>
+        property array<EntryEvent^>^ Events
+        {
+          array<EntryEvent^>^ get( );
+        }
+
+        /// <summary>
+        /// Gets the Cache for this transaction event
+        /// </summary>
+        property GemStone::GemFire::Cache::Cache^ Cache
+        {
+          GemStone::GemFire::Cache::Cache^ get( );
+        }
+      
+     internal:
+        /// <summary>
+        /// Internal constructor to wrap a native object pointer
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        inline TransactionEvent( const gemfire::TransactionEvent* nativeptr )
+          : SBWrap( const_cast<gemfire::TransactionEvent*>( nativeptr )) { }
+      };
+
+    }
+  }
+}
+#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/TransactionListenerAdapter.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/TransactionListenerAdapter.hpp b/geode-client-native/src/clicache/TransactionListenerAdapter.hpp
new file mode 100644
index 0000000..d36f40c
--- /dev/null
+++ b/geode-client-native/src/clicache/TransactionListenerAdapter.hpp
@@ -0,0 +1,49 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+#ifdef CSTX_COMMENTED
+#pragma once
+
+#include "gf_defs.hpp"
+#include "ITransactionListener.hpp"
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+      /// <summary>
+      /// Utility class that implements all methods in <c>ITransactionListener</c>
+      /// with empty implementations. Applications can subclass this class
+      /// and only override the methods for the events of interest.
+      /// </summary>
+      public ref class TransactionListenerAdapter
+        : public ITransactionListener
+      {
+      public:
+        virtual void AfterCommit(TransactionEvent^ te)
+        {
+        }
+
+	      virtual void AfterFailedCommit(TransactionEvent^ te)
+        {
+        }
+
+	      virtual void AfterRollback(TransactionEvent^ te)
+        {
+        }
+    
+        virtual void Close()
+        {
+        }
+      };
+
+    }
+  }
+}
+#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/TransactionWriterAdapter.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/TransactionWriterAdapter.hpp b/geode-client-native/src/clicache/TransactionWriterAdapter.hpp
new file mode 100644
index 0000000..e515cd0
--- /dev/null
+++ b/geode-client-native/src/clicache/TransactionWriterAdapter.hpp
@@ -0,0 +1,38 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+#ifdef CSTX_COMMENTED
+#pragma once
+
+#include "gf_defs.hpp"
+#include "ITransactionWriter.hpp"
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+
+      /// <summary>
+      /// Utility class that implements all methods in <c>ITransactionWriter</c>
+      /// with empty implementations. Applications can subclass this class
+      /// and only override the methods for the events of interest.
+      /// </summary>
+      public ref class TransactionWriterAdapter
+        : public ITransactionWriter
+      {
+      public:
+        virtual void BeforeCommit(TransactionEvent^ te)
+        {
+        }
+      };
+
+    }
+  }
+}
+#endif
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.cpp b/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.cpp
new file mode 100644
index 0000000..dbcd87d
--- /dev/null
+++ b/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.cpp
@@ -0,0 +1,63 @@
+/*=========================================================================
+* Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+*=========================================================================
+*/
+
+#include "UserFunctionExecutionExceptionM.hpp"
+#include "CacheableStringM.hpp"
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+      // IGFSerializable methods
+      void UserFunctionExecutionException::ToData( DataOutput^ output )
+      {
+        throw gcnew IllegalStateException("UserFunctionExecutionException::ToData is not intended for use.");
+      }
+
+      IGFSerializable^ UserFunctionExecutionException::FromData( DataInput^ input )
+      {
+        throw gcnew IllegalStateException("UserFunctionExecutionException::FromData is not intended for use.");
+        return this;
+      } 
+
+      uint32_t UserFunctionExecutionException::ObjectSize::get( )
+      {        
+        _GF_MG_EXCEPTION_TRY
+          throw gcnew IllegalStateException("UserFunctionExecutionException::ObjectSize is not intended for use.");
+          return NativePtr->objectSize( );
+
+        _GF_MG_EXCEPTION_CATCH_ALL
+      }
+
+      String^ UserFunctionExecutionException::Message::get() 
+      {
+        _GF_MG_EXCEPTION_TRY
+
+          gemfire::CacheableStringPtr value = NativePtr->getMessage(  );
+          return CacheableString::GetString( value.ptr( ) );          
+
+        _GF_MG_EXCEPTION_CATCH_ALL
+      }
+
+      String^ UserFunctionExecutionException::Name::get() 
+      {
+        _GF_MG_EXCEPTION_TRY
+
+          gemfire::CacheableStringPtr value = NativePtr->getName(  );
+          return CacheableString::GetString( value.ptr( ) );          
+
+        _GF_MG_EXCEPTION_CATCH_ALL
+      }
+    }
+  }
+}
+

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.hpp b/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.hpp
new file mode 100644
index 0000000..e98a02c
--- /dev/null
+++ b/geode-client-native/src/clicache/UserFunctionExecutionExceptionM.hpp
@@ -0,0 +1,124 @@
+/*=========================================================================
+* Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+*=========================================================================
+*/
+
+#pragma once
+
+#include "gf_defs.hpp"
+#include "cppcache/UserFunctionExecutionException.hpp"
+#include "IGFSerializable.hpp"
+#include "DataInputM.hpp"
+#include "DataOutputM.hpp"
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache
+    {
+
+      /// <summary>
+      /// UserFunctionExecutionException class is used to encapsulate gemfire sendException in case of Function execution.
+      /// </summary>
+      [Obsolete("Use classes and APIs from the GemStone.GemFire.Cache.Generic namespace")]
+      public ref class UserFunctionExecutionException sealed
+        : public Internal::SBWrap<gemfire::UserFunctionExecutionException>, public IGFSerializable
+      {
+      public:
+
+        // IGFSerializable members
+
+        /// <summary>
+        /// Serializes this object.
+        /// Users should not implement/call this api as it is only intended for internal use.
+        /// </summary>
+        /// <param name="output">
+        /// the DataOutput stream to use for serialization
+        /// </param>
+        /// <exception cref="IllegalStateException">
+        /// If this api is called from User code.
+        /// </exception>
+        virtual void ToData( DataOutput^ output );
+
+        /// <summary>
+        /// Deserializes this object.
+        /// Users should not implement/call this api as it is only intended for internal use.
+        /// </summary>
+        /// <param name="input">
+        /// the DataInput stream to use for reading data
+        /// </param>
+        /// <exception cref="IllegalStateException">
+        /// If this api is called from User code.
+        /// </exception>
+        /// <returns>the deserialized object</returns>
+        virtual IGFSerializable^ FromData( DataInput^ input );        
+
+        /// <summary>
+        /// Returns the classId of this class for serialization.
+        /// Users should not implement/call this api as it is only intended for internal use.
+        /// </summary>
+        /// <exception cref="IllegalStateException">
+        /// If this api is called from User code.
+        /// </exception>
+        /// <returns>classId of this class</returns>
+        /// <seealso cref="IGFSerializable.ClassId" />
+        virtual property uint32_t ClassId
+        {
+          inline virtual uint32_t get( )
+          {
+            throw gcnew IllegalStateException("UserFunctionExecutionException::ClassId is not intended for use.");
+            return 0;
+          }
+        }
+
+        /// <summary>
+        /// return the size of this object in bytes
+        /// Users should not implement/call this api as it is only intended for internal use.
+        /// </summary>
+        /// <exception cref="IllegalStateException">
+        /// If this api is called from User code.
+        /// </exception>
+        virtual property uint32_t ObjectSize
+        {
+          virtual uint32_t get( ); 
+        }
+
+        // End: IGFSerializable members   
+
+        /// <summary>
+        /// return as String the Exception message returned from gemfire sendException api.          
+        /// </summary>
+        /// <returns>the String Exception Message</returns>
+        property String^ Message
+        {
+          String^ get();          
+        }
+
+        /// <summary>
+        /// return as String the Exception name returned from gemfire sendException api.          
+        /// </summary>
+        /// <returns>the String Exception Name</returns>
+        property String^ Name
+        {
+          String^ get();          
+        }
+
+      internal:
+
+        /// <summary>
+        /// Private constructor to wrap a native object pointer.
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        inline UserFunctionExecutionException( gemfire::UserFunctionExecutionException* nativeptr )
+          : SBWrap( nativeptr ) { }
+      };
+
+    }
+  }
+}

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/Utils.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/Utils.cpp b/geode-client-native/src/clicache/Utils.cpp
new file mode 100644
index 0000000..725a4ae
--- /dev/null
+++ b/geode-client-native/src/clicache/Utils.cpp
@@ -0,0 +1,63 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+#include "gf_includes.hpp"
+#include "Utils.hpp"
+#include "cppcache/impl/Utils.hpp"
+
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+
+    MethodInfo^ Utils::LoadMethod( String^ assemblyName,
+      String^ typeName, String^ methodName)
+    {
+      Type^ loadType;
+
+      loadType = Type::GetType( typeName + ',' + assemblyName, false, true );
+      if (loadType != nullptr)
+      {
+        return loadType->GetMethod( methodName, BindingFlags::Public |
+          BindingFlags::Static | BindingFlags::IgnoreCase );
+      }
+      return nullptr;
+    }
+
+    MethodInfo^ Utils::LoadMethodFrom( String^ assemblyPath,
+      String^ typeName, String^ methodName)
+    {
+      String^ assemblyName;
+      Type^ loadType;
+
+      assemblyName = System::IO::Path::GetFileNameWithoutExtension(
+        assemblyPath );
+      loadType = Type::GetType( typeName + ',' + assemblyName, false, true );
+      if (loadType == nullptr)
+      {
+        Assembly^ assmb = Assembly::LoadFrom( assemblyPath );
+        if (assmb != nullptr)
+        {
+          loadType = assmb->GetType(typeName, false, true);
+        }
+      }
+      if (loadType != nullptr)
+      {
+        return loadType->GetMethod( methodName, BindingFlags::Public |
+          BindingFlags::Static | BindingFlags::IgnoreCase );
+      }
+      return nullptr;
+    }
+
+    int32_t Utils::LastError::get( )
+    {
+      return gemfire::Utils::getLastError( );
+    }
+  }
+}

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/Utils.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/Utils.hpp b/geode-client-native/src/clicache/Utils.hpp
new file mode 100644
index 0000000..8154b21
--- /dev/null
+++ b/geode-client-native/src/clicache/Utils.hpp
@@ -0,0 +1,75 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+#pragma once
+
+#include "gf_defs.hpp"
+//#include "cppcache/SystemProperties.hpp"
+#include "impl/NativeWrapper.hpp"
+#include "LogM.hpp"
+
+
+using namespace System;
+using namespace System::Reflection;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+
+    /// <summary>
+    /// Some static utility methods.
+    /// </summary>
+      [Obsolete("Use classes and APIs from the GemStone.GemFire.Cache.Generic namespace")]
+    public ref class Utils STATICCLASS
+    {
+    public:
+
+      /// <summary>
+      /// Load a method from the given assembly path using the default
+      /// constructor (if not a static method) of the given type.
+      /// </summary>
+      /// <param name="assemblyPath">The path of the assembly.</param>
+      /// <param name="typeName">
+      /// The name of the class containing the method.
+      /// </param>
+      /// <param name="methodName">The name of the method.</param>
+      /// <returns>
+      /// The <c>System.Reflection.MethodInfo</c> for the given method,
+      /// or null if the method is not found.
+      /// </returns>
+      static MethodInfo^ LoadMethod( String^ assemblyPath,
+        String^ typeName, String^ methodName);
+
+      /// <summary>
+      /// Load a method from the given assembly name using the default
+      /// constructor (if not a static method) of the given type.
+      /// </summary>
+      /// <param name="assemblyName">The name of the assembly.</param>
+      /// <param name="typeName">
+      /// The name of the class containing the method.
+      /// </param>
+      /// <param name="methodName">The name of the method.</param>
+      /// <returns>
+      /// The <c>System.Reflection.MethodInfo</c> for the given method,
+      /// or null if the method is not found.
+      /// </returns>
+      static MethodInfo^ LoadMethodFrom( String^ assemblyName,
+        String^ typeName, String^ methodName);
+
+      /// <summary>
+      /// Utility method to get the calling thread's last system error code.
+      /// </summary>
+      static property int32_t LastError
+      {
+        int32_t get( );
+      }
+    };
+
+  }
+}

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.cpp b/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.cpp
new file mode 100644
index 0000000..d642f53
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.cpp
@@ -0,0 +1,345 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+//#include "gf_includesN.hpp"
+#include "AttributesFactoryMN.hpp"
+#include "RegionMN.hpp"
+#include "impl/ManagedCacheLoaderN.hpp"
+#include "impl/ManagedPersistenceManagerN.hpp"
+#include "impl/ManagedCacheWriterN.hpp"
+#include "impl/ManagedCacheListenerN.hpp"
+#include "impl/ManagedPartitionResolverN.hpp"
+#include "impl/ManagedFixedPartitionResolverN.hpp"
+#include "impl/CacheLoaderMN.hpp"
+#include "impl/CacheWriterMN.hpp"
+#include "impl/CacheListenerMN.hpp"
+#include "impl/PartitionResolverMN.hpp"
+#include "impl/PersistenceManagerProxyMN.hpp"
+#include "RegionAttributesMN.hpp"
+#include "ICacheLoaderN.hpp"
+#include "IPersistenceManagerN.hpp"
+#include "ICacheWriterN.hpp"
+#include "IPartitionResolverN.hpp"
+#include "IFixedPartitionResolverN.hpp"
+#include "impl/SafeConvertN.hpp"
+
+using namespace System;
+using namespace System::Collections::Generic;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+      generic<class TKey, class TValue>
+      AttributesFactory<TKey, TValue>::AttributesFactory( RegionAttributes<TKey, TValue>^ regionAttributes )
+        : UMWrap( )
+      {
+        gemfire::RegionAttributesPtr attribptr(
+          GetNativePtrFromSBWrapGeneric<gemfire::RegionAttributes>( regionAttributes ) );
+        SetPtr( new gemfire::AttributesFactory( attribptr ), true );
+      }
+
+      // CALLBACKS
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheLoader( ICacheLoader<TKey, TValue>^ cacheLoader )
+      {
+        gemfire::CacheLoaderPtr loaderptr;
+        if ( cacheLoader != nullptr ) {
+          CacheLoaderGeneric<TKey, TValue>^ clg = gcnew CacheLoaderGeneric<TKey, TValue>();
+          clg->SetCacheLoader(cacheLoader);
+          loaderptr = new gemfire::ManagedCacheLoaderGeneric( /*clg,*/ cacheLoader );
+          ((gemfire::ManagedCacheLoaderGeneric*)loaderptr.ptr())->setptr(clg);
+        }
+        NativePtr->setCacheLoader( loaderptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheWriter( ICacheWriter<TKey, TValue>^ cacheWriter )
+      {
+        gemfire::CacheWriterPtr writerptr;
+        if ( cacheWriter != nullptr ) {
+          CacheWriterGeneric<TKey, TValue>^ cwg = gcnew CacheWriterGeneric<TKey, TValue>();
+          cwg->SetCacheWriter(cacheWriter);
+          writerptr = new gemfire::ManagedCacheWriterGeneric( /*cwg,*/ cacheWriter );
+          ((gemfire::ManagedCacheWriterGeneric*)writerptr.ptr())->setptr(cwg);
+        }
+        NativePtr->setCacheWriter( writerptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheListener( ICacheListener<TKey, TValue>^ cacheListener )
+      {
+        gemfire::CacheListenerPtr listenerptr;
+        if ( cacheListener != nullptr ) {
+          CacheListenerGeneric<TKey, TValue>^ clg = gcnew CacheListenerGeneric<TKey, TValue>();
+          clg->SetCacheListener(cacheListener);
+          //listenerptr = new gemfire::ManagedCacheListenerGeneric( (ICacheListener<Object^, Object^>^)cacheListener );
+          listenerptr = new gemfire::ManagedCacheListenerGeneric( /*clg,*/ cacheListener );
+          ((gemfire::ManagedCacheListenerGeneric*)listenerptr.ptr())->setptr(clg);
+        }
+        NativePtr->setCacheListener( listenerptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPartitionResolver( IPartitionResolver<TKey, TValue>^ partitionresolver )
+      {
+        gemfire::PartitionResolverPtr resolverptr;
+        if ( partitionresolver != nullptr ) {
+          Generic::IFixedPartitionResolver<TKey, TValue>^ resolver = 
+            dynamic_cast<Generic::IFixedPartitionResolver<TKey, TValue>^>(partitionresolver);
+          if (resolver != nullptr) {            
+            FixedPartitionResolverGeneric<TKey, TValue>^ prg = gcnew FixedPartitionResolverGeneric<TKey, TValue>();
+            prg->SetPartitionResolver(partitionresolver);
+            resolverptr = new gemfire::ManagedFixedPartitionResolverGeneric( partitionresolver ); 
+            ((gemfire::ManagedFixedPartitionResolverGeneric*)resolverptr.ptr())->setptr(prg);
+          }
+          else {            
+            PartitionResolverGeneric<TKey, TValue>^ prg = gcnew PartitionResolverGeneric<TKey, TValue>();
+            prg->SetPartitionResolver(partitionresolver);
+            resolverptr = new gemfire::ManagedPartitionResolverGeneric( partitionresolver );
+            ((gemfire::ManagedPartitionResolverGeneric*)resolverptr.ptr())->setptr(prg);            
+          }         
+        }
+        NativePtr->setPartitionResolver( resolverptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheLoader( String^ libPath, String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheLoader( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheWriter( String^ libPath, String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheWriter( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCacheListener( String^ libPath, String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheListener( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPartitionResolver( String^ libPath, String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setPartitionResolver( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      // EXPIRATION ATTRIBUTES
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetEntryIdleTimeout( ExpirationAction action, uint32_t idleTimeout )
+      {
+        NativePtr->setEntryIdleTimeout(
+          static_cast<gemfire::ExpirationAction::Action>( action ), idleTimeout );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetEntryTimeToLive( ExpirationAction action, uint32_t timeToLive )
+      {
+        NativePtr->setEntryTimeToLive(
+          static_cast<gemfire::ExpirationAction::Action>( action ), timeToLive );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetRegionIdleTimeout( ExpirationAction action, uint32_t idleTimeout )
+      {
+        NativePtr->setRegionIdleTimeout(
+          static_cast<gemfire::ExpirationAction::Action>( action ), idleTimeout );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetRegionTimeToLive( ExpirationAction action, uint32_t timeToLive )
+      {
+        NativePtr->setRegionTimeToLive(
+          static_cast<gemfire::ExpirationAction::Action>( action ), timeToLive );
+      }
+
+      // PERSISTENCE
+       generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPersistenceManager(IPersistenceManager<TKey, TValue>^ persistenceManager, Properties<String^, String^>^ config )
+      {
+        gemfire::PersistenceManagerPtr persistenceManagerptr;
+        if ( persistenceManager != nullptr ) {
+          PersistenceManagerGeneric<TKey, TValue>^ clg = gcnew PersistenceManagerGeneric<TKey, TValue>();
+          clg->SetPersistenceManager(persistenceManager);
+          persistenceManagerptr = new gemfire::ManagedPersistenceManagerGeneric( /*clg,*/ persistenceManager );
+          ((gemfire::ManagedPersistenceManagerGeneric*)persistenceManagerptr.ptr())->setptr(clg);
+        }
+         gemfire::PropertiesPtr configptr(GetNativePtr<gemfire::Properties>( config ) );
+         NativePtr->setPersistenceManager( persistenceManagerptr, configptr );
+      }
+      
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPersistenceManager(IPersistenceManager<TKey, TValue>^ persistenceManager )
+      {
+        SetPersistenceManager(persistenceManager, nullptr);
+      }
+        
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPersistenceManager( String^ libPath,
+        String^ factoryFunctionName )
+      {        
+        SetPersistenceManager( libPath, factoryFunctionName, nullptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPersistenceManager( String^ libPath,
+        String^ factoryFunctionName, Properties<String^, String^>^ config )
+      {        
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+        // VJR: TODO:
+				//TODO::split
+        gemfire::PropertiesPtr configptr(
+          GetNativePtr<gemfire::Properties>( config ) );
+
+        NativePtr->setPersistenceManager( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr, configptr );
+          
+      }
+
+      // DISTRIBUTION ATTRIBUTES
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetScope( ScopeType scopeType )
+      {
+        NativePtr->setScope(
+          static_cast<gemfire::ScopeType::Scope>( scopeType ) );
+      }
+
+      // STORAGE ATTRIBUTES
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetClientNotificationEnabled(
+        bool clientNotificationEnabled )
+      {
+        NativePtr->setClientNotificationEnabled( clientNotificationEnabled );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetEndpoints( String^ endpoints )
+      {
+        ManagedString mg_endpoints( endpoints );
+
+        NativePtr->setEndpoints( mg_endpoints.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetPoolName( String^ poolName )
+      {
+        ManagedString mg_poolName( poolName );
+
+        NativePtr->setPoolName( mg_poolName.CharPtr );
+      }
+
+      // MAP ATTRIBUTES
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetInitialCapacity( int32_t initialCapacity )
+      {
+        _GF_MG_EXCEPTION_TRY/* due to auto replace */
+
+          NativePtr->setInitialCapacity( initialCapacity );
+
+        _GF_MG_EXCEPTION_CATCH_ALL/* due to auto replace */
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetLoadFactor( Single loadFactor )
+      {
+        _GF_MG_EXCEPTION_TRY/* due to auto replace */
+
+          NativePtr->setLoadFactor( loadFactor );
+
+        _GF_MG_EXCEPTION_CATCH_ALL/* due to auto replace */
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetConcurrencyLevel( int32_t concurrencyLevel )
+      {
+        _GF_MG_EXCEPTION_TRY/* due to auto replace */
+
+          NativePtr->setConcurrencyLevel( concurrencyLevel );
+
+        _GF_MG_EXCEPTION_CATCH_ALL/* due to auto replace */
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetLruEntriesLimit( uint32_t entriesLimit )
+      {
+        NativePtr->setLruEntriesLimit( entriesLimit );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetDiskPolicy( DiskPolicyType diskPolicy )
+      {
+        NativePtr->setDiskPolicy(
+          static_cast<gemfire::DiskPolicyType::PolicyType>( diskPolicy ) );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCachingEnabled( bool cachingEnabled )
+      {
+        NativePtr->setCachingEnabled( cachingEnabled );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesFactory<TKey, TValue>::SetCloningEnabled( bool cloningEnabled )
+      {
+        NativePtr->setCloningEnabled( cloningEnabled );
+      }
+
+      generic<class TKey, class TValue>
+      void  AttributesFactory<TKey, TValue>::SetConcurrencyChecksEnabled( bool concurrencyChecksEnabled )
+      {
+        NativePtr->setConcurrencyChecksEnabled( concurrencyChecksEnabled );
+      }
+      // FACTORY METHOD
+
+      generic<class TKey, class TValue>
+      RegionAttributes<TKey, TValue>^ AttributesFactory<TKey, TValue>::CreateRegionAttributes( )
+      {
+        _GF_MG_EXCEPTION_TRY/* due to auto replace */
+
+          gemfire::RegionAttributesPtr& nativeptr (
+            NativePtr->createRegionAttributes( ) );
+          return RegionAttributes<TKey, TValue>::Create( nativeptr.ptr( ) );
+
+        _GF_MG_EXCEPTION_CATCH_ALL/* due to auto replace */
+      }
+
+    }
+  }
+}
+} //namespace 

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.hpp b/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.hpp
new file mode 100644
index 0000000..f5cbf55
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/AttributesFactoryMN.hpp
@@ -0,0 +1,553 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+#pragma once
+
+#include "../../gf_defs.hpp"
+#include <cppcache/AttributesFactory.hpp>
+//#include "impl/NativeWrapperN.hpp"
+#include "ExpirationActionMN.hpp"
+#include "DiskPolicyTypeMN.hpp"
+#include "ScopeTypeMN.hpp"
+
+#include "ICacheLoaderN.hpp"
+#include "ICacheWriterN.hpp"
+#include "ICacheListenerN.hpp"
+#include "IPartitionResolverN.hpp"
+#include "IFixedPartitionResolverN.hpp"
+#include "IPersistenceManagerN.hpp"
+#include "RegionAttributesMN.hpp"
+
+using namespace System;
+using namespace System::Collections::Generic;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache {
+    
+    namespace Generic 
+    {
+
+      //ref class RegionAttributes;
+      //interface class ICacheLoader;
+      //interface class ICacheWriter;
+      //interface class ICacheListener;
+      //interface class IPartitionResolver;
+      //interface class IFixedPartitionResolver;
+
+
+      /// <summary>
+      /// Factory class to create instances of <see cref="RegionAttributes" />.
+      /// </summary>
+      /// <remarks>
+      /// An <see cref="AttributesFactory" />
+      /// instance maintains state for creating <see cref="RegionAttributes" /> instances.
+      /// The setter methods are used to change the settings that will be used for
+      /// creating the next attributes instance with the <see cref="CreateRegionAttributes" />
+      /// method. If you create a factory with the default constructor, then the
+      /// factory is set up to create attributes with all default settings. You can
+      /// also create a factory by providing a preset <see cref="RegionAttributes" />.
+      /// <para>
+      /// Once a <see cref="RegionAttributes" /> is created, it can only be modified
+      /// after it has been used to create a <see cref="Region" />, and then only by
+      /// using an <see cref="AttributesMutator" /> obtained from the region.
+      /// </para><para>
+      /// <h3>Attributes</h3>
+      /// <h4>Callbacks</h4>
+      /// <dl>
+      /// <dt><see cref="ICacheLoader" /> [<em>default:</em> null]</dt>
+      ///     <dd>User-implemented plug-in for loading data on cache misses.<br />
+      ///        see <see cref="SetCacheLoader" />,
+      ///            <see cref="RegionAttributes.CacheLoader" /></dd>
+      ///
+      /// <dt><see cref="ICacheWriter" /> [<em>default:</em> null]</dt>
+      ///     <dd>User-implemented plug-in for intercepting cache modifications, e.g.
+      ///         for writing to an external data source.<br />
+      ///         see <see cref="SetCacheWriter" />,
+      ///             <see cref="RegionAttributes.CacheWriter" /></dd>
+      ///
+      /// <dt><see cref="ICacheListener" /> [<em>default:</em> null]</dt>
+      ///     <dd>User-implemented plug-in for receiving and handling cache-related events.<br />
+      ///         see <see cref="SetCacheListener" />,
+      ///             <see cref="RegionAttributes.CacheListener" /></dd>
+      ///
+      /// <dt><see cref="IPartitionResolver" /> [<em>default:</em> null]</dt>
+      ///     <dd>User-implemented plug-in for custom partitioning.<br />
+      ///         see <see cref="SetPartitionResolver" />,
+      ///             <see cref="RegionAttributes.PartitionResolver" /></dd>
+      /// </dl>
+      /// <h4>Expiration</h4>
+      /// <dl>
+      /// <dt>RegionTimeToLive [<em>default:</em> no expiration]</dt>
+      ///     <dd>Expiration configuration for the entire region based on the
+      ///     lastModifiedTime ( <see cref="CacheStatistics.LastModifiedTime" /> ).<br />
+      ///         see <see cref="SetRegionTimeToLive" />,
+      ///             <see cref="RegionAttributes.RegionTimeToLive" />,
+      ///             <see cref="AttributesMutator.SetRegionTimeToLive" /></dd>
+      ///
+      /// <dt>RegionIdleTimeout [<em>default:</em> no expiration]</dt>
+      ///     <dd>Expiration configuration for the entire region based on the
+      ///         lastAccessedTime ( <see cref="CacheStatistics.LastAccessedTime" /> ).<br />
+      ///         see <see cref="SetRegionIdleTimeout" />,
+      ///             <see cref="RegionAttributes.RegionIdleTimeout" />,
+      ///             <see cref="AttributesMutator.SetRegionIdleTimeout" /></dd>
+      ///
+      /// <dt>EntryTimeToLive [<em>default:</em> no expiration]</dt>
+      ///     <dd>Expiration configuration for individual entries based on the
+      ///     lastModifiedTime ( <see cref="CacheStatistics.LastModifiedTime" /> ).<br />
+      ///         see <see cref="SetEntryTimeToLive" />,
+      ///             <see cref="RegionAttributes.EntryTimeToLive" />,
+      ///             <see cref="AttributesMutator.SetEntryTimeToLive" /></dd>
+      ///
+      /// <dt>EntryIdleTimeout [<em>default:</em> no expiration]</dt>
+      ///     <dd>Expiration configuration for individual entries based on the
+      ///         lastAccessedTime ( <see cref="CacheStatistics.LastAccessedTime" /> ).<br />
+      ///         see <see cref="SetEntryIdleTimeout" />,
+      ///             <see cref="RegionAttributes.EntryIdleTimeout" />,
+      ///             <see cref="AttributesMutator.SetEntryIdleTimeout" /></dd>
+      /// </dl>
+      /// <h4>Distribution</h4>
+      /// <dl>
+      /// <dt><see cref="ScopeType" /> [<em>default:</em> <tt>ScopeType.DistributedNoAck</tt>]</dt>
+      ///     <dd>The C++ cache can contain either local regions or distributed regions. 
+      ///         Distributed regions are configured with servers that they distribute 
+      ///         their operations to upto. Locally scoped regions do not have any 
+      ///         distribution behavior. GFE native client regions scoped as 
+      ///         ScopeType.DistributedNoAck and ScopeType.DistributedAck have identical
+      ///         distribution behavior.<br />
+      ///         see <see cref="SetScope" />,
+      ///             <see cref="RegionAttributes.Scope" /></dd>
+      /// </dl>
+      /// <h4>Storage</h4>
+      /// <dl>
+      /// <dt>InitialCapacity [<em>default:</em> <tt>16</tt>]</dt>
+      ///     <dd>The initial capacity of the map used for storing the entries.<br />
+      ///         see <see cref="SetInitialCapacity" />,
+      ///             <see cref="RegionAttributes.InitialCapacity" /></dd>
+      ///
+      /// <dt>LoadFactor [<em>default:</em> <tt>0.75</tt>]</dt>
+      ///     <dd>The load factor of the map used for storing the entries.<br />
+      ///         see <see cref="SetLoadFactor" />,
+      ///             <see cref="RegionAttributes.LoadFactor" /></dd>
+      ///
+      /// <dt>ConcurrencyLevel [<em>default:</em> <tt>16</tt>]</dt>
+      ///     <dd>The allowed concurrency among updates to values in the region
+      ///         is guided by the <tt>concurrencyLevel</tt>, which is used as a hint
+      ///         for internal sizing. The actual concurrency will vary.
+      ///         Ideally, you should choose a value to accommodate as many
+      ///         threads as will ever concurrently modify values in the region. Using a
+      ///         significantly higher value than you need can waste space and time,
+      ///         and a significantly lower value can lead to thread contention. But
+      ///         overestimates and underestimates within an order of magnitude do
+      ///         not usually have much noticeable impact. A value of one is
+      ///         appropriate when it is known that only one thread will modify
+      ///         and all others will only read.<br />
+      ///         see <see cref="SetConcurrencyLevel" />,
+      ///             <see cref="RegionAttributes.ConcurrencyLevel" /></dd>
+      ///
+      /// </dl>
+      /// </para>
+      /// </remarks>
+      /// <seealso cref="RegionAttributes" />
+      /// <seealso cref="AttributesMutator" />
+      /// <seealso cref="Region.CreateSubRegion" />
+      generic<class TKey, class TValue>
+      public ref class AttributesFactory sealed
+        : public Internal::UMWrap<gemfire::AttributesFactory>
+      {
+      public:
+
+        /// <summary>
+        /// Creates a new <c>AttributesFactory</c> ready to create
+        /// a <c>RegionAttributes</c> with default settings.
+        /// </summary>
+        inline AttributesFactory<TKey, TValue>( )
+          : UMWrap( new gemfire::AttributesFactory( ), true ) { }
+
+        /// <summary>
+        /// Creates a new instance of <c>AttributesFactory</c> ready to create
+        /// a <c>RegionAttributes</c> with the same settings as those in the
+        /// specified <c>RegionAttributes</c>.
+        /// </summary>
+        /// <param name="regionAttributes">
+        /// attributes used to initialize this AttributesFactory
+        /// </param>
+        AttributesFactory<TKey, TValue>(RegionAttributes<TKey, TValue>^ regionAttributes);
+
+        // CALLBACKS
+
+        /// <summary>
+        /// Sets the cache loader for the <c>RegionAttributes</c> being created.
+        /// </summary>
+        /// <param name="cacheLoader">
+        /// a user-defined cache loader, or null for no cache loader
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheLoader( ICacheLoader<TKey, TValue>^ cacheLoader );
+
+        /// <summary>
+        /// Sets the cache writer for the <c>RegionAttributes</c> being created.
+        /// </summary>
+        /// <param name="cacheWriter">
+        /// user-defined cache writer, or null for no cache writer
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheWriter( ICacheWriter<TKey, TValue>^ cacheWriter );
+
+        /// <summary>
+        /// Sets the CacheListener for the <c>RegionAttributes</c> being created.
+        /// </summary>
+        /// <param name="cacheListener">
+        /// user-defined cache listener, or null for no cache listener
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheListener( ICacheListener<TKey, TValue>^ cacheListener );
+
+        /// <summary>
+        /// Sets the PartitionResolver for the <c>RegionAttributes</c> being created.
+        /// </summary>
+        /// <param name="partitionresolver">
+        /// user-defined partition resolver, or null for no partition resolver
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetPartitionResolver( IPartitionResolver<TKey, TValue>^ partitionresolver );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the loader of the region.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheLoader</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheLoader</c> for a managed library.
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheLoader( String^ libPath, String^ factoryFunctionName );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the writer of the region.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheWriter</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheWriter</c> for a managed library.
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheWriter( String^ libPath, String^ factoryFunctionName );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the listener of the region.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheListener</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheListener</c> for a managed library.
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetCacheListener( String^ libPath, String^ factoryFunctionName );
+
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the partition resolver of the region.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>PartitionResolver</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>IPartitionResolver</c> for a managed library.
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetPartitionResolver( String^ libPath, String^ factoryFunctionName );
+
+
+        // EXPIRATION ATTRIBUTES
+
+        /// <summary>
+        /// Sets the idleTimeout expiration attributes for region entries for the next
+        /// <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="action">
+        /// The expiration action for which to set the timeout.
+        /// </param>
+        /// <param name="idleTimeout">
+        /// the idleTimeout in seconds for entries in this region.
+        /// </param>
+        void SetEntryIdleTimeout( ExpirationAction action, uint32_t idleTimeout );
+
+        /// <summary>
+        /// Sets the timeToLive expiration attributes for region entries for the next
+        /// <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="action">
+        /// The expiration action for which to set the timeout.
+        /// </param>
+        /// <param name="timeToLive">
+        /// the timeToLive in seconds for entries in this region.
+        /// </param>
+        void SetEntryTimeToLive( ExpirationAction action, uint32_t timeToLive );
+
+        /// <summary>
+        /// Sets the idleTimeout expiration attributes for the region itself for the
+        /// next <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="action">
+        /// The expiration action for which to set the timeout.
+        /// </param>
+        /// <param name="idleTimeout">
+        /// the idleTimeout in seconds for the region as a whole.
+        /// </param>
+        void SetRegionIdleTimeout( ExpirationAction action, uint32_t idleTimeout );
+
+        /// <summary>
+        /// Sets the timeToLive expiration attributes for the region itself for the
+        /// next <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="action">
+        /// The expiration action for which to set the timeout.
+        /// </param>
+        /// <param name="timeToLive">
+        /// the timeToLive in seconds for the region as a whole.
+        /// </param>
+        void SetRegionTimeToLive( ExpirationAction action, uint32_t timeToLive );
+
+
+        // PERSISTENCE
+
+        /// <summary>
+        /// Sets the PersistenceManager object that will be invoked for the persistence of the region.
+        /// </summary>
+        /// <param name="persistenceManager">
+        /// Persistence Manager object
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetPersistenceManager(IPersistenceManager<TKey, TValue>^ persistenceManager);
+
+        /// <summary>
+        /// Sets the PersistenceManager object that will be invoked for the persistence of the region.
+        /// </summary>
+        /// <param name="persistenceManager">
+        /// Persistence Manager object
+        /// </param>
+        /// <param name="config">
+        /// The configuration properties to use for the PersistenceManager.
+        /// </param>
+        //generic<class TKey, class TValue>
+        void SetPersistenceManager(IPersistenceManager<TKey, TValue>^ persistenceManager, Properties<String^, String^>^ config);
+        
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the persistence of the region.
+        /// If the region is being created from a client on a server, or on a server directly, then
+        /// This must be used to set the PersistenceManager.
+        /// </summary>
+        /// <param name="libPath">The path of the PersistenceManager shared library.</param>
+        /// <param name="factoryFunctionName">
+        /// The name of the factory function to create an instance of PersistenceManager object.
+        /// </param>
+        void SetPersistenceManager( String^ libPath, String^ factoryFunctionName );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the persistence of the region.
+        /// If the region is being created from a client on a server, or on a server directly, then
+        /// This must be used to set the PersistenceManager.
+        /// </summary>
+        /// <param name="libPath">The path of the PersistenceManager shared library.</param>
+        /// <param name="factoryFunctionName">
+        /// The name of the factory function to create an instance of PersistenceManager object.
+        /// </param>
+        /// <param name="config">
+        /// The configuration properties to use for the PersistenceManager.
+        /// </param>
+        void SetPersistenceManager( String^ libPath, String^ factoryFunctionName,
+          /*Dictionary<Object^, Object^>*/Properties<String^, String^>^ config );
+
+
+        // DISTRIBUTION ATTRIBUTES
+
+        /// <summary>
+        /// Sets the scope for the next <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="scopeType">
+        /// the type of scope to use for the region
+        /// </param>
+        [Obsolete("This method is obsolete since 3.5")]
+        void SetScope( ScopeType scopeType );
+
+
+        // STORAGE ATTRIBUTES
+
+        /// <summary>
+        /// Enables/disables client noficiations for a Thin client region.
+        /// </summary>
+        /// <param name="clientNotificationEnabled">
+        /// true if client notifications have to be enabled; false otherwise
+        /// </param>        
+        [Obsolete("This method is obsolete since 3.5; use PoolFactory.SetSubscriptionEnabled instead.")]
+        void SetClientNotificationEnabled(
+          bool clientNotificationEnabled );
+
+        /// <summary>
+        /// Set the endpoints for a Thin Client region.
+        /// </summary>
+        /// <remarks>
+        /// If the endpoints are set then the region is taken to be a Thin-client
+        /// region that interacts with the GemFire Java cacheserver.
+        /// </remarks>
+        /// <param name="endpoints">
+        /// The list of host:port pairs separated by commas.
+        /// </param>
+        [Obsolete("This method is obsolete since 3.5; use PoolFactory.AddServer or PoolFactory.AddLocator instead.")]
+        void SetEndpoints( String^ endpoints );
+
+        /// <summary>
+        /// Set the pool name for a Thin Client region.
+        /// </summary>
+        /// <remarks>
+        /// The pool with the name specified must be already created.
+        /// </remarks>
+        /// <param name="poolName">
+        /// The name of the pool to attach to this region.
+        /// </param>
+        void SetPoolName( String^ poolName );
+
+        // MAP ATTRIBUTES
+
+        /// <summary>
+        /// Sets the entry initial capacity for the <c>RegionAttributes</c>
+        /// being created. This value is used in initializing the map that
+        /// holds the entries.
+        /// </summary>
+        /// <param name="initialCapacity">the initial capacity of the entry map</param>
+        /// <exception cref="IllegalArgumentException">
+        /// if initialCapacity is nonpositive
+        /// </exception>
+        void SetInitialCapacity( int32_t initialCapacity );
+
+        /// <summary>
+        /// Sets the entry load factor for the next <c>RegionAttributes</c>
+        /// created. This value is
+        /// used in initializing the map that holds the entries.
+        /// </summary>
+        /// <param name="loadFactor">the load factor of the entry map</param>
+        /// <exception cref="IllegalArgumentException">
+        /// if loadFactor is nonpositive
+        /// </exception>
+        void SetLoadFactor( Single loadFactor );
+
+        /// <summary>
+        /// Sets the concurrency level of the next <c>RegionAttributes</c>
+        /// created. This value is used in initializing the map that holds the entries.
+        /// </summary>
+        /// <param name="concurrencyLevel">
+        /// the concurrency level of the entry map
+        /// </param>
+        /// <exception cref="IllegalArgumentException">
+        /// if concurrencyLevel is nonpositive
+        /// </exception>
+        void SetConcurrencyLevel( int32_t concurrencyLevel );
+
+        /// <summary>
+        /// Sets a limit on the number of entries that will be held in the cache.
+        /// If a new entry is added while at the limit, the cache will evict the
+        /// least recently used entry.
+        /// </summary>
+        /// <param name="entriesLimit">
+        /// The limit of the number of entries before eviction starts.
+        /// Defaults to 0, meaning no LRU actions will used.
+        /// </param>
+        void SetLruEntriesLimit( uint32_t entriesLimit );
+
+        /// <summary>
+        /// Sets the disk policy type for the next <c>RegionAttributes</c> created.
+        /// </summary>
+        /// <param name="diskPolicy">
+        /// the disk policy to use for the region
+        /// </param>
+        void SetDiskPolicy( DiskPolicyType diskPolicy );
+
+        /// <summary>
+        /// Set caching enabled flag for this region.
+        /// </summary>
+        /// <remarks>
+        /// <para>
+        /// If set to false, then no data is stored in the local process,
+        /// but events and distributions will still occur, and the region
+        /// can still be used to put and remove, etc...
+        /// </para><para>
+        /// The default if not set is 'true', 'false' is illegal for regions
+        /// of <c>ScopeType.Local</c> scope. 
+        /// </para>
+        /// </remarks>
+        /// <param name="cachingEnabled">
+        /// if true, cache data for this region in this process.
+        /// </param>
+        void SetCachingEnabled( bool cachingEnabled );
+        /// <summary>
+        /// Set cloning enabled flag for this region.
+        /// </summary>
+        /// <remarks>
+        /// <para>
+        /// If set to false, then there is no cloning will take place in case of delta.
+        /// Delta will be applied on the old value which will change old value in-place.
+        /// </para><para>
+        /// The default if not set is 'false'
+        /// of <c>ScopeType.Local</c> scope. 
+        /// </para>
+        /// </remarks>
+        /// <param name="cloningEnabled">
+        /// if true, clone old value before applying delta so that in-place change would not occour..
+        /// </param>
+        void SetCloningEnabled( bool cloningEnabled );
+
+        /// <summary>
+        /// Sets concurrency checks enabled flag for this region.
+        /// </summary>
+        /// <remarks>
+        /// <para>
+        /// If set to false, then the version checks will not occur.
+        /// </para><para>
+        /// The default if not set is 'true'
+        /// </para>
+        /// </remarks>
+        /// <param name="concurrencyChecksEnabled">
+        /// if true, version checks for region entries will occur.
+        /// </param>
+        void SetConcurrencyChecksEnabled( bool concurrencyChecksEnabled );
+        // FACTORY METHOD
+
+        /// <summary>
+        /// Creates a <c>RegionAttributes</c> with the current settings.
+        /// </summary>
+        /// <returns>the newly created <c>RegionAttributes</c></returns>
+        /// <exception cref="IllegalStateException">
+        /// if the current settings violate the <a href="compability.html">
+        /// compatibility</a> rules.
+        /// </exception>
+        RegionAttributes<TKey, TValue>^ CreateRegionAttributes( );
+      };
+
+    }
+  }
+}
+ } //namespace 

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.cpp b/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.cpp
new file mode 100644
index 0000000..ee9ef4d
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.cpp
@@ -0,0 +1,175 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+//#include "gf_includesN.hpp"
+#include "AttributesMutatorMN.hpp"
+//#include "RegionMN.hpp"
+#include "impl/ManagedCacheListenerN.hpp"
+#include "impl/ManagedCacheLoaderN.hpp"
+#include "impl/ManagedCacheWriterN.hpp"
+#include "impl/CacheLoaderMN.hpp"
+#include "impl/CacheWriterMN.hpp"
+#include "impl/CacheListenerMN.hpp"
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      generic<class TKey, class TValue>
+      int32_t AttributesMutator<TKey, TValue>::SetEntryIdleTimeout( int32_t idleTimeout )
+      {
+        return NativePtr->setEntryIdleTimeout( idleTimeout );
+      }
+
+      generic<class TKey, class TValue>
+      ExpirationAction AttributesMutator<TKey, TValue>::SetEntryIdleTimeoutAction(
+        ExpirationAction action )
+      {
+        return static_cast<ExpirationAction>(
+          NativePtr->setEntryIdleTimeoutAction(
+          static_cast<gemfire::ExpirationAction::Action>( action ) ) );
+      }
+
+      generic<class TKey, class TValue>
+      int32_t AttributesMutator<TKey, TValue>::SetEntryTimeToLive( int32_t timeToLive )
+      {
+        return NativePtr->setEntryTimeToLive( timeToLive );
+      }
+
+      generic<class TKey, class TValue>
+      ExpirationAction AttributesMutator<TKey, TValue>::SetEntryTimeToLiveAction(
+        ExpirationAction action )
+      {
+        return static_cast<ExpirationAction>(
+          NativePtr->setEntryTimeToLiveAction(
+          static_cast<gemfire::ExpirationAction::Action>( action ) ) );
+      }
+
+      generic<class TKey, class TValue>
+      int32_t AttributesMutator<TKey, TValue>::SetRegionIdleTimeout( int32_t idleTimeout )
+      {
+        return NativePtr->setRegionIdleTimeout( idleTimeout );
+      }
+
+      generic<class TKey, class TValue>
+      ExpirationAction AttributesMutator<TKey, TValue>::SetRegionIdleTimeoutAction(
+        ExpirationAction action )
+      {
+        return static_cast<ExpirationAction>(
+          NativePtr->setRegionIdleTimeoutAction(
+          static_cast<gemfire::ExpirationAction::Action>( action ) ) );
+      }
+
+      generic<class TKey, class TValue>
+      int32_t AttributesMutator<TKey, TValue>::SetRegionTimeToLive( int32_t timeToLive )
+      {
+        return NativePtr->setRegionTimeToLive( timeToLive );
+      }
+
+      generic<class TKey, class TValue>
+      ExpirationAction AttributesMutator<TKey, TValue>::SetRegionTimeToLiveAction(
+        ExpirationAction action )
+      {
+        return static_cast<ExpirationAction>(
+          NativePtr->setRegionTimeToLiveAction(
+          static_cast<gemfire::ExpirationAction::Action>( action ) ) );
+      }
+
+      generic<class TKey, class TValue>
+      uint32_t AttributesMutator<TKey, TValue>::SetLruEntriesLimit( uint32_t entriesLimit )
+      {
+        return NativePtr->setLruEntriesLimit( entriesLimit );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheListener( ICacheListener<TKey, TValue>^ cacheListener )
+      {
+        gemfire::CacheListenerPtr listenerptr;
+        if (cacheListener != nullptr)
+        {
+          CacheListenerGeneric<TKey, TValue>^ clg = gcnew CacheListenerGeneric<TKey, TValue>();
+          clg->SetCacheListener(cacheListener);
+          listenerptr = new gemfire::ManagedCacheListenerGeneric( /*clg,*/ cacheListener );
+          ((gemfire::ManagedCacheListenerGeneric*)listenerptr.ptr())->setptr(clg);
+        }
+        NativePtr->setCacheListener( listenerptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheListener( String^ libPath,
+        String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheListener( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheLoader( ICacheLoader<TKey, TValue>^ cacheLoader )
+      {
+        gemfire::CacheLoaderPtr loaderptr;
+        if (cacheLoader != nullptr)
+        {
+          CacheLoaderGeneric<TKey, TValue>^ clg = gcnew CacheLoaderGeneric<TKey, TValue>();
+          clg->SetCacheLoader(cacheLoader);
+          loaderptr = new gemfire::ManagedCacheLoaderGeneric( /*clg,*/ cacheLoader );
+          ((gemfire::ManagedCacheLoaderGeneric*)loaderptr.ptr())->setptr(clg);
+        }
+        NativePtr->setCacheLoader( loaderptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheLoader( String^ libPath,
+        String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheLoader( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheWriter( ICacheWriter<TKey, TValue>^ cacheWriter )
+      {
+        gemfire::CacheWriterPtr writerptr;
+        if (cacheWriter != nullptr)
+        {
+          CacheWriterGeneric<TKey, TValue>^ cwg = gcnew CacheWriterGeneric<TKey, TValue>();
+          cwg->SetCacheWriter(cacheWriter);
+          writerptr = new gemfire::ManagedCacheWriterGeneric( /*cwg,*/ cacheWriter );
+          ((gemfire::ManagedCacheWriterGeneric*)writerptr.ptr())->setptr(cwg);
+        }
+        NativePtr->setCacheWriter( writerptr );
+      }
+
+      generic<class TKey, class TValue>
+      void AttributesMutator<TKey, TValue>::SetCacheWriter( String^ libPath,
+        String^ factoryFunctionName )
+      {
+        throw gcnew System::NotSupportedException;
+        ManagedString mg_libpath( libPath );
+        ManagedString mg_factoryFunctionName( factoryFunctionName );
+
+        NativePtr->setCacheWriter( mg_libpath.CharPtr,
+          mg_factoryFunctionName.CharPtr );
+      }
+
+    }
+  }
+}
+ } //namespace 

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.hpp b/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.hpp
new file mode 100644
index 0000000..e535a7a
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/AttributesMutatorMN.hpp
@@ -0,0 +1,256 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+#pragma once
+
+#include "../../gf_defs.hpp"
+#include <cppcache/AttributesMutator.hpp>
+//#include "impl/NativeWrapperN.hpp"
+#include "ExpirationActionMN.hpp"
+#include "ICacheListenerN.hpp"
+#include "ICacheLoaderN.hpp"
+#include "ICacheWriterN.hpp"
+
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      /// <summary>
+      /// Supports modification of certain region attributes after the region
+      /// has been created.
+      /// </summary>
+      /// <remarks>
+      /// <para>
+      /// It is required that the attributes be completely initialized using an
+      /// <see cref="AttributesFactory" /> before creating the region.
+      /// AttributesMutator can be applied to adjusting and tuning a subset of
+      /// attributes that are modifiable at runtime.
+      /// </para><para>
+      /// The setter methods all return the previous value of the attribute.
+      /// </para>
+      /// </remarks>
+      /// <seealso cref="Region.AttributesMutator" />
+      /// <seealso cref="RegionAttributes" />
+      /// <seealso cref="AttributesFactory" />
+      generic<class TKey, class TValue>
+      public ref class AttributesMutator sealed
+        : public Internal::SBWrap<gemfire::AttributesMutator>
+      {
+      public:
+
+        /// <summary>
+        /// Sets the idleTimeout duration for region entries.
+        /// </summary>
+        /// <param name="idleTimeout">
+        /// the idleTimeout in seconds for entries in this region, or 0 for no idle timeout
+        /// </param>
+        /// <returns>the previous value</returns>
+        /// <exception cref="IllegalStateException">
+        /// if the new idleTimeout changes entry expiration from
+        /// disabled to enabled or enabled to disabled.
+        /// </exception>
+        int32_t SetEntryIdleTimeout( int32_t idleTimeout );
+
+        /// <summary>
+        /// Sets the idleTimeout action for region entries.
+        /// </summary>
+        /// <param name="action">
+        /// the idleTimeout action for entries in this region
+        /// </param>
+        /// <returns>the previous action</returns>
+        ExpirationAction SetEntryIdleTimeoutAction( ExpirationAction action );
+
+        /// <summary>
+        /// Sets the timeToLive duration for region entries.
+        /// </summary>
+        /// <param name="timeToLive">
+        /// the timeToLive in seconds for entries in this region, or 0 to disable time-to-live
+        /// </param>
+        /// <returns>the previous value</returns>
+        /// <exception cref="IllegalStateException">
+        /// if the new timeToLive changes entry expiration from
+        /// disabled to enabled or enabled to disabled
+        /// </exception>
+        int32_t SetEntryTimeToLive( int32_t timeToLive );
+
+        /// <summary>
+        /// Set the timeToLive action for region entries.
+        /// </summary>
+        /// <param name="action">
+        /// the timeToLive action for entries in this region
+        /// </param>
+        /// <returns>the previous action</returns>
+        ExpirationAction SetEntryTimeToLiveAction( ExpirationAction action );
+
+        /// <summary>
+        /// Sets the idleTimeout duration for the region itself.
+        /// </summary>
+        /// <param name="idleTimeout">
+        /// the idleTimeout for this region, in seconds, or 0 to disable idle timeout
+        /// </param>
+        /// <returns>the previous value</returns>
+        /// <exception cref="IllegalStateException">
+        /// if the new idleTimeout changes region expiration from
+        /// disabled to enabled or enabled to disabled.
+        /// </exception>
+        int32_t SetRegionIdleTimeout( int32_t idleTimeout );
+
+        /// <summary>
+        /// Sets the idleTimeout action for the region itself.
+        /// </summary>
+        /// <param name="action">
+        /// the idleTimeout action for this region
+        /// </param>
+        /// <returns>the previous action</returns>
+        ExpirationAction SetRegionIdleTimeoutAction( ExpirationAction action );
+
+        /// <summary>
+        /// Sets the timeToLive duration for the region itself.
+        /// </summary>
+        /// <param name="timeToLive">
+        /// the timeToLive for this region, in seconds, or 0 to disable time-to-live
+        /// </param>
+        /// <returns>the previous value</returns>
+        /// <exception cref="IllegalStateException">
+        /// if the new timeToLive changes region expiration from
+        /// disabled to enabled or enabled to disabled.
+        /// </exception>
+        int32_t SetRegionTimeToLive( int32_t timeToLive );
+
+        /// <summary>
+        /// Sets the timeToLive action for the region itself.
+        /// </summary>
+        /// <param name="action">
+        /// the timeToLiv eaction for this region
+        /// </param>
+        /// <returns>the previous action</returns>
+        ExpirationAction SetRegionTimeToLiveAction( ExpirationAction action );
+
+        /// <summary>
+        /// Sets the maximum entry count in the region before LRU eviction.
+        /// </summary>
+        /// <param name="entriesLimit">the number of entries to allow, or 0 to disable LRU</param>
+        /// <returns>the previous value</returns>
+        /// <exception cref="IllegalStateException">
+        /// if the new entriesLimit changes LRU from
+        /// disabled to enabled or enabled to disabled.
+        /// </exception>
+        uint32_t SetLruEntriesLimit( uint32_t entriesLimit );
+
+        /// <summary>
+        /// Sets the CacheListener for the region.
+        /// The previous cache listener (if any) will be replaced with the given <c>cacheListener</c>.
+        /// </summary>
+        /// <param name="cacheListener">
+        /// user-defined cache listener, or null for no cache listener
+        /// </param>
+        void SetCacheListener( ICacheListener<TKey, TValue>^ cacheListener );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the listener of the region.
+        /// The previous cache listener will be replaced with a listener created
+        /// using the factory function provided in the given library.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheListener</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheListener</c> for a managed library.
+        /// </param>
+        void SetCacheListener( String^ libPath, String^ factoryFunctionName );
+
+        /// <summary>
+        /// Sets the CacheLoader for the region.
+        /// The previous cache loader (if any) will be replaced with the given <c>cacheLoader</c>.
+        /// </summary>
+        /// <param name="cacheLoader">
+        /// user-defined cache loader, or null for no cache loader
+        /// </param>
+        void SetCacheLoader( ICacheLoader<TKey, TValue>^ cacheLoader );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the loader of the region.
+        /// The previous cache loader will be replaced with a loader created
+        /// using the factory function provided in the given library.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheLoader</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheLoader</c> for a managed library.
+        /// </param>
+        void SetCacheLoader( String^ libPath, String^ factoryFunctionName );
+
+        /// <summary>
+        /// Sets the CacheListener for the region.
+        /// The previous cache writer (if any) will be replaced with the given <c>cacheWriter</c>.
+        /// </summary>
+        /// <param name="cacheWriter">
+        /// user-defined cache writer, or null for no cache writer
+        /// </param>
+        void SetCacheWriter( ICacheWriter<TKey, TValue>^ cacheWriter );
+
+        /// <summary>
+        /// Sets the library path for the library that will be invoked for the writer of the region.
+        /// The previous cache writer will be replaced with a writer created
+        /// using the factory function provided in the given library.
+        /// </summary>
+        /// <param name="libPath">
+        /// library pathname containing the factory function.
+        /// </param>
+        /// <param name="factoryFunctionName">
+        /// Name of factory function that creates a <c>CacheWriter</c>
+        /// for a native library, or the name of the method in the form
+        /// {Namespace}.{Class Name}.{Method Name} that creates an
+        /// <c>ICacheWriter</c> for a managed library.
+        /// </param>
+        void SetCacheWriter( String^ libPath, String^ factoryFunctionName );
+
+
+      internal:
+        /// <summary>
+        /// Internal factory function to wrap a native object pointer inside
+        /// this managed class with null pointer check.
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        /// <returns>
+        /// The managed wrapper object; null if the native pointer is null.
+        /// </returns>
+        inline static AttributesMutator<TKey, TValue>^ Create( gemfire::AttributesMutator* nativeptr )
+        {
+          return ( nativeptr != nullptr ?
+            gcnew AttributesMutator<TKey, TValue>( nativeptr ) : nullptr );
+        }
+
+
+      private:
+
+        /// <summary>
+        /// Private constructor to wrap a native object pointer
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        inline AttributesMutator<TKey, TValue>( gemfire::AttributesMutator* nativeptr )
+          : SBWrap( nativeptr ) { }
+      };
+
+    }
+  }
+}
+ } //namespace 

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.cpp b/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.cpp
new file mode 100644
index 0000000..ae6f59c
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.cpp
@@ -0,0 +1,53 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+
+
+//#include "gf_includesN.hpp"
+#include "CacheAttributesFactoryMN.hpp"
+#include "CacheAttributesMN.hpp"
+#include "../../ExceptionTypesM.hpp"
+
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      void CacheAttributesFactory::SetRedundancyLevel( int32_t redundancyLevel )
+      {
+        NativePtr->setRedundancyLevel( redundancyLevel );
+      }
+
+      void CacheAttributesFactory::SetEndpoints( String^ endpoints )
+      {
+        ManagedString mg_endpoints( endpoints );
+        NativePtr->setEndpoints( mg_endpoints.CharPtr );
+      }
+
+      CacheAttributes^ CacheAttributesFactory::CreateCacheAttributes( )
+      {
+        _GF_MG_EXCEPTION_TRY/* due to auto replace */
+
+          gemfire::CacheAttributesPtr& nativeptr =
+            NativePtr->createCacheAttributes();
+
+          return CacheAttributes::Create(nativeptr.ptr());
+
+        _GF_MG_EXCEPTION_CATCH_ALL/* due to auto replace */
+      }
+
+    }
+  }
+}
+ } //namespace 
+

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.hpp b/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.hpp
new file mode 100644
index 0000000..35c3fb2
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/CacheAttributesFactoryMN.hpp
@@ -0,0 +1,76 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+
+
+#pragma once
+
+#include "../../gf_defs.hpp"
+#include <cppcache/CacheAttributesFactory.hpp>
+#include "impl/NativeWrapperN.hpp"
+
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      ref class CacheAttributes;
+
+      /// <summary>
+      /// Creates instances of <c>CacheAttributes</c>.
+      /// </summary>
+      /// <seealso cref="CacheAttributes" />
+      public ref class CacheAttributesFactory sealed
+        : public Internal::UMWrap<gemfire::CacheAttributesFactory>
+      {
+      public:
+
+        /// <summary>
+        /// Creates a new instance of <c>CacheAttributesFactory</c> ready
+        /// to create a <c>CacheAttributes</c> with default settings.
+        /// </summary>
+        inline CacheAttributesFactory( )
+          : UMWrap( new gemfire::CacheAttributesFactory( ), true )
+        { }
+
+        // ATTRIBUTES
+
+        /// <summary>
+        /// Sets redundancy level to use for regions in the cache.
+        /// </summary>
+        [Obsolete("This method is obsolete since 3.5; use PoolFactory.SetSubscriptionRedundancy instead.")]
+        void SetRedundancyLevel( int32_t redundancyLevel );
+
+        /// <summary>
+        /// Sets endpoints list to be used at the cache-level.
+        /// </summary>
+        [Obsolete("This method is obsolete since 3.5; use PoolFactory.AddServer or PoolFactory.AddLocator instead.")]
+        void SetEndpoints( String^ endpoints );
+
+        // FACTORY METHOD
+
+        /// <summary>
+        /// Creates a <c>CacheAttributes</c> with the current settings.
+        /// </summary>
+        /// <returns>The newly created <c>CacheAttributes</c></returns>
+        /// <exception cref="IllegalStateException">
+        /// if the current settings violate the <a href="compability.html">
+        /// compatibility</a> rules.
+        /// </exception>
+        CacheAttributes^ CreateCacheAttributes( );
+      };
+
+    }
+  }
+}
+ } //namespace 

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.cpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.cpp b/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.cpp
new file mode 100644
index 0000000..402b527
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.cpp
@@ -0,0 +1,38 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+
+
+//#include "gf_includesN.hpp"
+#include "CacheAttributesMN.hpp"
+#include "impl/ManagedStringN.hpp"
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      int32_t CacheAttributes::RedundancyLevel::get( )
+      {
+        return NativePtr->getRedundancyLevel( );
+      }
+
+      String^ CacheAttributes::Endpoints::get( )
+      {
+        return ManagedString::Get( NativePtr->getEndpoints( ) );
+      }
+
+    }
+  }
+}
+ } //namespace 
+

http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/ac967000/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.hpp
----------------------------------------------------------------------
diff --git a/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.hpp b/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.hpp
new file mode 100644
index 0000000..b399f89
--- /dev/null
+++ b/geode-client-native/src/clicache/com/vmware/CacheAttributesMN.hpp
@@ -0,0 +1,98 @@
+/*=========================================================================
+ * Copyright (c) 2002-2014 Pivotal Software, Inc. All Rights Reserved.
+ * This product is protected by U.S. and international copyright
+ * and intellectual property laws. Pivotal products are covered by
+ * more patents listed at http://www.pivotal.io/patents.
+ *=========================================================================
+ */
+
+
+
+#pragma once
+
+#include "../../gf_defs.hpp"
+#include <cppcache/CacheAttributes.hpp>
+#include "impl/NativeWrapperN.hpp"
+
+
+using namespace System;
+
+namespace GemStone
+{
+  namespace GemFire
+  {
+    namespace Cache { namespace Generic
+    {
+
+      /// <summary>
+      /// Defines attributes for configuring a cache.
+      /// </summary>
+      /// <remarks>
+      /// Currently the following attributes are defined:
+      /// <c>redundancyLevel</c>: Redundancy for HA client queues.
+      /// <c>endpoints</c>: Cache level endpoints list.
+      /// To create an instance of this interface, use
+      /// <see cref="CacheAttributesFactory.CreateCacheAttributes" />.
+      ///
+      /// For compatibility rules and default values, see
+      /// <see cref="CacheAttributesFactory" />.
+      ///
+      /// Note that the <c>CacheAttributes</c> are not distributed with
+      /// the region.
+      /// </remarks>
+      /// <seealso cref="CacheAttributesFactory" />
+      public ref class CacheAttributes sealed
+        : public Internal::SBWrap<gemfire::CacheAttributes>
+      {
+      public:
+
+        /// <summary>
+        /// Gets redundancy level for regions in the cache.
+        /// </summary>
+        property int32_t RedundancyLevel
+        {
+          int32_t get( );
+        }
+
+        /// <summary>
+        /// Gets cache level endpoints list.
+        /// </summary>
+        property String^ Endpoints
+        {
+          String^ get( );
+        }
+
+
+      internal:
+
+        /// <summary>
+        /// Internal factory function to wrap a native object pointer inside
+        /// this managed class with null pointer check.
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        /// <returns>
+        /// The managed wrapper object; null if the native pointer is null.
+        /// </returns>
+        inline static CacheAttributes^ Create(
+          gemfire::CacheAttributes* nativeptr )
+        {
+          return ( nativeptr != nullptr ?
+            gcnew CacheAttributes( nativeptr ) : nullptr );
+        }
+
+
+      private:
+
+        /// <summary>
+        /// Private constructor to wrap a native object pointer
+        /// </summary>
+        /// <param name="nativeptr">The native object pointer</param>
+        inline CacheAttributes( gemfire::CacheAttributes* nativeptr )
+          : SBWrap( nativeptr ) { }
+      };
+
+    }
+  }
+}
+ } //namespace 
+



Mime
View raw message