ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [36/50] ignite git commit: Rename LockInfo
Date Thu, 08 Sep 2016 14:46:18 GMT
Rename LockInfo


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

Branch: refs/heads/ignite-3199-1
Commit: 70fa4e996ba9ba61c1643fd7229494fdd9ba8100
Parents: 52d8e62
Author: Pavel Tupitsyn <ptupitsyn@apache.org>
Authored: Thu Sep 8 12:35:16 2016 +0300
Committer: Pavel Tupitsyn <ptupitsyn@apache.org>
Committed: Thu Sep 8 12:35:16 2016 +0300

----------------------------------------------------------------------
 .../ignite/internal/binary/BinaryContext.java   |   4 +-
 .../platform/cache/PlatformCache.java           |   6 +-
 .../platform/websession/LockEntryProcessor.java |   2 +-
 .../platform/websession/SessionStateData.java   |   2 +-
 .../websession/UnlockEntryProcessor.java        |   2 +-
 .../IgniteSessionStateStoreProvider.cs          |   4 +-
 .../AspNet/LockInfoTest.cs                      |  10 +-
 .../Apache.Ignite.Core.csproj                   |   2 +-
 .../Apache.Ignite.Core/Impl/AspNet/LockInfo.cs  | 166 -------------------
 .../Impl/AspNet/SessionStateLockInfo.cs         | 166 +++++++++++++++++++
 .../Impl/Binary/Marshaller.cs                   |   2 +-
 11 files changed, 183 insertions(+), 183 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
b/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
index ffd9699..49f1867 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/binary/BinaryContext.java
@@ -77,7 +77,7 @@ import org.apache.ignite.internal.processors.igfs.meta.IgfsMetaUpdatePropertiesP
 import org.apache.ignite.internal.processors.igfs.meta.IgfsMetaUpdateTimesProcessor;
 import org.apache.ignite.internal.processors.platform.PlatformJavaObjectFactoryProxy;
 import org.apache.ignite.internal.processors.platform.websession.KeyValueDirtyTrackedCollection;
-import org.apache.ignite.internal.processors.platform.websession.LockInfo;
+import org.apache.ignite.internal.processors.platform.websession.SessionStateLockInfo;
 import org.apache.ignite.internal.processors.platform.websession.SessionStateData;
 import org.apache.ignite.internal.util.lang.GridMapEntry;
 import org.apache.ignite.internal.util.typedef.F;
@@ -322,7 +322,7 @@ public class BinaryContext {
         registerPredefinedType(BinaryEnumObjectImpl.class, 0);
 
         registerPredefinedType(SessionStateData.class, 0);
-        registerPredefinedType(LockInfo.class, 0);
+        registerPredefinedType(SessionStateLockInfo.class, 0);
         registerPredefinedType(KeyValueDirtyTrackedCollection.class, 0);
 
         // IDs range [200..1000] is used by Ignite internal APIs.

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/cache/PlatformCache.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/cache/PlatformCache.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/cache/PlatformCache.java
index 93c2436..f45f458 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/cache/PlatformCache.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/cache/PlatformCache.java
@@ -50,7 +50,7 @@ import org.apache.ignite.internal.processors.platform.utils.PlatformListenable;
 import org.apache.ignite.internal.processors.platform.utils.PlatformUtils;
 import org.apache.ignite.internal.processors.platform.utils.PlatformWriterClosure;
 import org.apache.ignite.internal.processors.platform.websession.LockEntryProcessor;
-import org.apache.ignite.internal.processors.platform.websession.LockInfo;
+import org.apache.ignite.internal.processors.platform.websession.SessionStateLockInfo;
 import org.apache.ignite.internal.processors.platform.websession.SessionStateData;
 import org.apache.ignite.internal.processors.platform.websession.SetAndUnlockEntryProcessor;
 import org.apache.ignite.internal.processors.platform.websession.UnlockEntryProcessor;
@@ -477,7 +477,7 @@ public class PlatformCache extends PlatformAbstractTarget {
 
                     switch (opCode) {
                         case OP_INVOKE_INTERNAL_SESSION_LOCK: {
-                            LockInfo lockInfo = (LockInfo)args[1];
+                            SessionStateLockInfo lockInfo = (SessionStateLockInfo)args[1];
 
                             Object res = cacheRaw.invoke(key, new LockEntryProcessor(), lockInfo);
 
@@ -485,7 +485,7 @@ public class PlatformCache extends PlatformAbstractTarget {
                         }
 
                         case OP_INVOKE_INTERNAL_SESSION_UNLOCK: {
-                            LockInfo lockInfo = (LockInfo)args[1];
+                            SessionStateLockInfo lockInfo = (SessionStateLockInfo)args[1];
 
                             cacheRaw.invoke(key, new UnlockEntryProcessor(), lockInfo);
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/LockEntryProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/LockEntryProcessor.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/LockEntryProcessor.java
index 72aa183..ff5107a 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/LockEntryProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/LockEntryProcessor.java
@@ -46,7 +46,7 @@ public class LockEntryProcessor implements CacheEntryProcessor<String,
SessionSt
         if (data.isLocked())
             return data.lockTime();
 
-        LockInfo lockInfo = (LockInfo)args[0];
+        SessionStateLockInfo lockInfo = (SessionStateLockInfo)args[0];
 
         // Not locked: lock and return result
         data.lock(lockInfo);

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/SessionStateData.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/SessionStateData.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/SessionStateData.java
index 2c4a62f..5ccdada 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/SessionStateData.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/SessionStateData.java
@@ -86,7 +86,7 @@ public class SessionStateData implements Binarylizable {
      *
      * @param lock Lock.
      */
-    public void lock(LockInfo lock) {
+    public void lock(SessionStateLockInfo lock) {
         assert !isLocked();
 
         lockId = lock.id();

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/UnlockEntryProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/UnlockEntryProcessor.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/UnlockEntryProcessor.java
index 1075958..655b314 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/UnlockEntryProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/platform/websession/UnlockEntryProcessor.java
@@ -40,7 +40,7 @@ public class UnlockEntryProcessor implements CacheEntryProcessor<String,
Session
         assert data != null;
         assert data.lockNodeId() != null;
 
-        LockInfo lockInfo = (LockInfo)args[0];
+        SessionStateLockInfo lockInfo = (SessionStateLockInfo)args[0];
 
         if (!data.lockNodeId().equals(lockInfo.nodeId()))
             throw new IllegalStateException("Can not unlock session data: lock node id check
failed.");

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.AspNet/IgniteSessionStateStoreProvider.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.AspNet/IgniteSessionStateStoreProvider.cs
b/modules/platforms/dotnet/Apache.Ignite.AspNet/IgniteSessionStateStoreProvider.cs
index 2aa4e70..fdbd528 100644
--- a/modules/platforms/dotnet/Apache.Ignite.AspNet/IgniteSessionStateStoreProvider.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.AspNet/IgniteSessionStateStoreProvider.cs
@@ -398,9 +398,9 @@ namespace Apache.Ignite.AspNet
         /// <summary>
         /// Gets the lock info.
         /// </summary>
-        private LockInfo GetLockInfo(long lockId)
+        private SessionStateLockInfo GetLockInfo(long lockId)
         {
-            return new LockInfo(lockId, Cache.Ignite.GetCluster().GetLocalNode().Id, DateTime.UtcNow);
+            return new SessionStateLockInfo(lockId, Cache.Ignite.GetCluster().GetLocalNode().Id,
DateTime.UtcNow);
         }
 
         /// <summary>

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.Core.Tests/AspNet/LockInfoTest.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/AspNet/LockInfoTest.cs b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/AspNet/LockInfoTest.cs
index dada98d..a65109f 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/AspNet/LockInfoTest.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/AspNet/LockInfoTest.cs
@@ -22,7 +22,7 @@ namespace Apache.Ignite.Core.Tests.AspNet
     using NUnit.Framework;
 
     /// <summary>
-    /// Tests for <see cref="LockInfo"/>.
+    /// Tests for <see cref="SessionStateLockInfo"/>.
     /// </summary>
     public class LockInfoTest
     {
@@ -32,9 +32,9 @@ namespace Apache.Ignite.Core.Tests.AspNet
         [Test]
         public void TestEquality()
         {
-            var lock1 = new LockInfo(1, Guid.NewGuid(), DateTime.UtcNow);
-            var lock2 = new LockInfo(2, Guid.NewGuid(), DateTime.UtcNow.AddDays(1));
-            var lock3 = new LockInfo(lock1.LockId, lock1.LockNodeId, lock1.LockTime);
+            var lock1 = new SessionStateLockInfo(1, Guid.NewGuid(), DateTime.UtcNow);
+            var lock2 = new SessionStateLockInfo(2, Guid.NewGuid(), DateTime.UtcNow.AddDays(1));
+            var lock3 = new SessionStateLockInfo(lock1.LockId, lock1.LockNodeId, lock1.LockTime);
 
             Assert.AreEqual(lock1, lock3);
             Assert.AreEqual(lock1.GetHashCode(), lock3.GetHashCode());
@@ -55,7 +55,7 @@ namespace Apache.Ignite.Core.Tests.AspNet
         [Test]
         public void TestSerialization()
         {
-            var lock1 = new LockInfo(2, Guid.NewGuid(), DateTime.UtcNow.AddDays(1));
+            var lock1 = new SessionStateLockInfo(2, Guid.NewGuid(), DateTime.UtcNow.AddDays(1));
             var lock2 = TestUtils.SerializeDeserialize(lock1);
 
             Assert.AreEqual(lock1, lock2);

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.Core/Apache.Ignite.Core.csproj
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Apache.Ignite.Core.csproj b/modules/platforms/dotnet/Apache.Ignite.Core/Apache.Ignite.Core.csproj
index 547ca55..e582996 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Apache.Ignite.Core.csproj
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Apache.Ignite.Core.csproj
@@ -91,7 +91,7 @@
     <Compile Include="Discovery\Tcp\Package-Info.cs" />
     <Compile Include="Discovery\Tcp\Static\Package-Info.cs" />
     <Compile Include="Impl\AspNet\SessionStateData.cs" />
-    <Compile Include="Impl\AspNet\LockInfo.cs" />
+    <Compile Include="Impl\AspNet\SessionStateLockInfo.cs" />
     <Compile Include="Impl\Binary\BinaryReflectiveSerializerInternal.cs" />
     <Compile Include="Impl\Binary\IBinarySerializerInternal.cs" />
     <Compile Include="Binary\Package-Info.cs" />

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/LockInfo.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/LockInfo.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/LockInfo.cs
deleted file mode 100644
index 9ac7806..0000000
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/LockInfo.cs
+++ /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.
- */
-
-namespace Apache.Ignite.Core.Impl.AspNet
-{
-    using System;
-    using System.Diagnostics;
-    using Apache.Ignite.Core.Binary;
-    using Apache.Ignite.Core.Impl.Binary;
-    
-    /// <summary>
-    /// Lock info.
-    /// </summary>
-    public struct LockInfo : IBinaryWriteAware, IEquatable<LockInfo>
-    {
-        /** */
-        private readonly long _lockId;
-        
-        /** */
-        private readonly Guid _lockNodeId;
-
-        /** */
-        private readonly DateTime _lockTime;
-
-        /// <summary>
-        /// Initializes a new instance of the <see cref="LockInfo"/> struct.
-        /// </summary>
-        /// <param name="lockId">The lock identifier.</param>
-        /// <param name="lockNodeId">The lock node identifier.</param>
-        /// <param name="lockTime">The lock time.</param>
-        public LockInfo(long lockId, Guid lockNodeId, DateTime lockTime)
-        {
-            _lockId = lockId;
-            _lockNodeId = lockNodeId;
-            _lockTime = lockTime;
-        }
-
-        /// <summary>
-        /// Initializes a new instance of the <see cref="LockInfo"/> struct.
-        /// </summary>
-        /// <param name="reader">The reader.</param>
-        public LockInfo(IBinaryRawReader reader)
-        {
-            _lockId = reader.ReadLong();
-
-            var guid = reader.ReadGuid();
-            Debug.Assert(guid != null);
-            _lockNodeId = guid.Value;
-
-            var time = reader.ReadTimestamp();
-            Debug.Assert(time != null);
-            _lockTime = time.Value;
-        }
-
-        /// <summary>
-        /// Gets or sets the lock node id. Null means not locked.
-        /// </summary>
-        public Guid LockNodeId
-        {
-            get { return _lockNodeId; }
-        }
-
-        /// <summary>
-        /// Gets or sets the lock id.
-        /// </summary>
-        public long LockId
-        {
-            get { return _lockId; }
-        }
-
-        /// <summary>
-        /// Gets or sets the lock time.
-        /// </summary>
-        public DateTime LockTime
-        {
-            get { return _lockTime; }
-        }
-
-        /// <summary>
-        /// Writes this object to the given writer.
-        /// </summary>
-        /// <param name="writer">Writer.</param>
-        public void WriteBinary(IBinaryWriter writer)
-        {
-            var raw = writer.GetRawWriter();
-
-            raw.WriteLong(_lockId);
-            raw.WriteGuid(_lockNodeId);
-            raw.WriteTimestamp(_lockTime);
-        }
-
-        /// <summary>
-        /// Indicates whether the current object is equal to another object of the same type.
-        /// </summary>
-        /// <param name="other">An object to compare with this object.</param>
-        /// <returns>
-        /// true if the current object is equal to the <paramref name="other" /> parameter;
otherwise, false.
-        /// </returns>
-        public bool Equals(LockInfo other)
-        {
-            return _lockTime.Equals(other._lockTime) && _lockId == other._lockId

-                && _lockNodeId.Equals(other._lockNodeId);
-        }
-
-        /// <summary>
-        /// Determines whether the specified <see cref="object" />, is equal to this
instance.
-        /// </summary>
-        /// <param name="obj">The <see cref="object" /> to compare with this
instance.</param>
-        /// <returns>
-        /// <c>true</c> if the specified <see cref="object" /> is equal
to this instance; otherwise, <c>false</c>.
-        /// </returns>
-        public override bool Equals(object obj)
-        {
-            if (ReferenceEquals(null, obj)) return false;
-            return obj is LockInfo && Equals((LockInfo) obj);
-        }
-
-        /// <summary>
-        /// Returns a hash code for this instance.
-        /// </summary>
-        /// <returns>
-        /// A hash code for this instance, suitable for use in hashing algorithms 
-        /// and data structures like a hash table. 
-        /// </returns>
-        public override int GetHashCode()
-        {
-            unchecked
-            {
-                var hashCode = _lockTime.GetHashCode();
-                hashCode = (hashCode*397) ^ _lockId.GetHashCode();
-                hashCode = (hashCode*397) ^ _lockNodeId.GetHashCode();
-                return hashCode;
-            }
-        }
-
-        /// <summary>
-        /// Implements the operator ==.
-        /// </summary>
-        public static bool operator ==(LockInfo left, LockInfo right)
-        {
-            return left.Equals(right);
-        }
-
-        /// <summary>
-        /// Implements the operator !=.
-        /// </summary>
-        public static bool operator !=(LockInfo left, LockInfo right)
-        {
-            return !left.Equals(right);
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockInfo.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockInfo.cs
b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockInfo.cs
new file mode 100644
index 0000000..194c0db
--- /dev/null
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/AspNet/SessionStateLockInfo.cs
@@ -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.
+ */
+
+namespace Apache.Ignite.Core.Impl.AspNet
+{
+    using System;
+    using System.Diagnostics;
+    using Apache.Ignite.Core.Binary;
+    using Apache.Ignite.Core.Impl.Binary;
+    
+    /// <summary>
+    /// Lock info.
+    /// </summary>
+    public struct SessionStateLockInfo : IBinaryWriteAware, IEquatable<SessionStateLockInfo>
+    {
+        /** */
+        private readonly long _lockId;
+        
+        /** */
+        private readonly Guid _lockNodeId;
+
+        /** */
+        private readonly DateTime _lockTime;
+
+        /// <summary>
+        /// Initializes a new instance of the <see cref="SessionStateLockInfo"/> struct.
+        /// </summary>
+        /// <param name="lockId">The lock identifier.</param>
+        /// <param name="lockNodeId">The lock node identifier.</param>
+        /// <param name="lockTime">The lock time.</param>
+        public SessionStateLockInfo(long lockId, Guid lockNodeId, DateTime lockTime)
+        {
+            _lockId = lockId;
+            _lockNodeId = lockNodeId;
+            _lockTime = lockTime;
+        }
+
+        /// <summary>
+        /// Initializes a new instance of the <see cref="SessionStateLockInfo"/> struct.
+        /// </summary>
+        /// <param name="reader">The reader.</param>
+        public SessionStateLockInfo(IBinaryRawReader reader)
+        {
+            _lockId = reader.ReadLong();
+
+            var guid = reader.ReadGuid();
+            Debug.Assert(guid != null);
+            _lockNodeId = guid.Value;
+
+            var time = reader.ReadTimestamp();
+            Debug.Assert(time != null);
+            _lockTime = time.Value;
+        }
+
+        /// <summary>
+        /// Gets or sets the lock node id. Null means not locked.
+        /// </summary>
+        public Guid LockNodeId
+        {
+            get { return _lockNodeId; }
+        }
+
+        /// <summary>
+        /// Gets or sets the lock id.
+        /// </summary>
+        public long LockId
+        {
+            get { return _lockId; }
+        }
+
+        /// <summary>
+        /// Gets or sets the lock time.
+        /// </summary>
+        public DateTime LockTime
+        {
+            get { return _lockTime; }
+        }
+
+        /// <summary>
+        /// Writes this object to the given writer.
+        /// </summary>
+        /// <param name="writer">Writer.</param>
+        public void WriteBinary(IBinaryWriter writer)
+        {
+            var raw = writer.GetRawWriter();
+
+            raw.WriteLong(_lockId);
+            raw.WriteGuid(_lockNodeId);
+            raw.WriteTimestamp(_lockTime);
+        }
+
+        /// <summary>
+        /// Indicates whether the current object is equal to another object of the same type.
+        /// </summary>
+        /// <param name="other">An object to compare with this object.</param>
+        /// <returns>
+        /// true if the current object is equal to the <paramref name="other" /> parameter;
otherwise, false.
+        /// </returns>
+        public bool Equals(SessionStateLockInfo other)
+        {
+            return _lockTime.Equals(other._lockTime) && _lockId == other._lockId

+                && _lockNodeId.Equals(other._lockNodeId);
+        }
+
+        /// <summary>
+        /// Determines whether the specified <see cref="object" />, is equal to this
instance.
+        /// </summary>
+        /// <param name="obj">The <see cref="object" /> to compare with this
instance.</param>
+        /// <returns>
+        /// <c>true</c> if the specified <see cref="object" /> is equal
to this instance; otherwise, <c>false</c>.
+        /// </returns>
+        public override bool Equals(object obj)
+        {
+            if (ReferenceEquals(null, obj)) return false;
+            return obj is SessionStateLockInfo && Equals((SessionStateLockInfo) obj);
+        }
+
+        /// <summary>
+        /// Returns a hash code for this instance.
+        /// </summary>
+        /// <returns>
+        /// A hash code for this instance, suitable for use in hashing algorithms 
+        /// and data structures like a hash table. 
+        /// </returns>
+        public override int GetHashCode()
+        {
+            unchecked
+            {
+                var hashCode = _lockTime.GetHashCode();
+                hashCode = (hashCode*397) ^ _lockId.GetHashCode();
+                hashCode = (hashCode*397) ^ _lockNodeId.GetHashCode();
+                return hashCode;
+            }
+        }
+
+        /// <summary>
+        /// Implements the operator ==.
+        /// </summary>
+        public static bool operator ==(SessionStateLockInfo left, SessionStateLockInfo right)
+        {
+            return left.Equals(right);
+        }
+
+        /// <summary>
+        /// Implements the operator !=.
+        /// </summary>
+        public static bool operator !=(SessionStateLockInfo left, SessionStateLockInfo right)
+        {
+            return !left.Equals(right);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/ignite/blob/70fa4e99/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
index 03a65a1..e7b345e 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Binary/Marshaller.cs
@@ -598,7 +598,7 @@ namespace Apache.Ignite.Core.Impl.Binary
             AddSystemType(0, r => new ObjectInfoHolder(r));
             AddSystemType(0, r => new KeyValueDirtyTrackedCollection(r));
             AddSystemType(0, r => new SessionStateData(r));
-            AddSystemType(0, r => new LockInfo(r));
+            AddSystemType(0, r => new SessionStateLockInfo(r));
         }
     }
 }


Mime
View raw message