Ejemplo n.º 1
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(SegmentHeader header, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
//JAVA TO C# CONVERTER NOTE: Members cannot have the same name as their enclosing type:
            public override void MarshalConflict(SegmentHeader header, WritableChannel channel)
            {
                channel.PutLong(header._prevFileLastIndex);
                channel.PutLong(header._version);
                channel.PutLong(header._prevIndex);
                channel.PutLong(header._prevTerm);
            }
Ejemplo n.º 2
0
        /// <summary>
        /// This this consumer ignores the content which is handles by its own serializer.
        /// </summary>
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshalMetaData(org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
        public virtual void MarshalMetaData(WritableChannel channel)
        {
            channel.PutLong(GlobalSession().sessionId().MostSignificantBits);
            channel.PutLong(GlobalSession().sessionId().LeastSignificantBits);
            (new MemberId.Marshal()).marshal(GlobalSession().owner(), channel);

            channel.PutLong(_operationId.localSessionId());
            channel.PutLong(_operationId.sequenceNumber());
        }
Ejemplo n.º 3
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(IdAllocationState state, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
//JAVA TO C# CONVERTER NOTE: Members cannot have the same name as their enclosing type:
            public override void MarshalConflict(IdAllocationState state, WritableChannel channel)
            {
                channel.PutLong(( long )state._firstUnallocated.Length);
                foreach (long l in state._firstUnallocated)
                {
                    channel.PutLong(l);
                }

                channel.PutLong(state._logIndex);
            }
Ejemplo n.º 4
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(org.neo4j.causalclustering.identity.StoreId storeId, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
        public override void Marshal(StoreId storeId, WritableChannel channel)
        {
            if (storeId == null)
            {
                channel.Put(( sbyte )0);
                return;
            }

            channel.Put(( sbyte )1);
            channel.PutLong(storeId.CreationTime);
            channel.PutLong(storeId.RandomId);
            channel.PutLong(storeId.UpgradeTime);
            channel.PutLong(storeId.UpgradeId);
        }
Ejemplo n.º 5
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(TermState termState, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
//JAVA TO C# CONVERTER NOTE: Members cannot have the same name as their enclosing type:
            public override void MarshalConflict(TermState termState, WritableChannel channel)
            {
                channel.PutLong(termState.CurrentTerm());
            }
Ejemplo n.º 6
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(System.Nullable<long> index, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
        public override void Marshal(long?index, WritableChannel channel)
        {
            channel.PutLong(index.Value);
        }
Ejemplo n.º 7
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(System.Nullable<long> aLong, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
            public override void Marshal(long?aLong, WritableChannel channel)
            {
                channel.PutLong(aLong.Value);
            }
Ejemplo n.º 8
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public static void write(org.neo4j.storageengine.api.WritableChannel channel, org.neo4j.causalclustering.messaging.marshalling.ChannelMarshal<org.neo4j.causalclustering.core.replication.ReplicatedContent> contentMarshal, long logIndex, long term, org.neo4j.causalclustering.core.replication.ReplicatedContent content) throws java.io.IOException
        public static void Write(WritableChannel channel, ChannelMarshal <ReplicatedContent> contentMarshal, long logIndex, long term, ReplicatedContent content)
        {
            channel.PutLong(logIndex);
            channel.PutLong(term);
            contentMarshal.Marshal(content, channel);
        }
Ejemplo n.º 9
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(ReplicatedLockTokenState state, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
//JAVA TO C# CONVERTER NOTE: Members cannot have the same name as their enclosing type:
            public override void MarshalConflict(ReplicatedLockTokenState state, WritableChannel channel)
            {
                channel.PutLong(state._ordinal);
                channel.PutInt(state.Get().id());
                MemberMarshal.marshal(state.Get().owner(), channel);
            }
Ejemplo n.º 10
0
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
//ORIGINAL LINE: public void marshal(VoteState state, org.neo4j.storageengine.api.WritableChannel channel) throws java.io.IOException
//JAVA TO C# CONVERTER NOTE: Members cannot have the same name as their enclosing type:
            public override void MarshalConflict(VoteState state, WritableChannel channel)
            {
                channel.PutLong(state._term);
                MemberMarshal.marshal(state.VotedFor(), channel);
            }