Decode() 개인적인 메소드

private Decode ( ByteString value, Type type, IConnection client ) : object
value ByteString
type System.Type
client IConnection
리턴 object
예제 #1
0
        internal Object GetValue(UInt32 id)
        {
            Object result;

            lock (accessLock) {
                if (!streamTypes.ContainsKey(id))
                {
                    throw new InvalidOperationException("Stream does not exist or has been closed");
                }
                if (streamValues.ContainsKey(id))
                {
                    return(streamValues [id]);
                }
                streamValues [id] = Encoder.Decode(streamData [id], streamTypes [id], this.connection);
                result            = streamValues [id];
            }
            return(result);
        }
예제 #2
0
        public object GetValue(uint id)
        {
            CheckDisposed();
            object result;

            lock (accessLock) {
                if (!streamTypes.ContainsKey(id))
                {
                    throw new InvalidOperationException("Stream does not exist or has been closed");
                }
                if (streamValues.ContainsKey(id))
                {
                    return(streamValues [id]);
                }
                streamValues [id] = Encoder.Decode(streamData [id], streamTypes [id], connection);
                result            = streamValues [id];
            }
            return(result);
        }