コード例 #1
0
ファイル: Ref.cs プロジェクト: zloom/Orleankka
        public static Ref Deserialize(string path, Type type)
        {
            if (type == typeof(ClientRef))
            {
                return(ClientRef.Deserialize(path));
            }

            if (type == typeof(ActorRef))
            {
                return(ActorRef.Deserialize(path));
            }

            if (type == typeof(StreamRef))
            {
                return(StreamRef.Deserialize(path));
            }

            var deserializer = deserializers.Find(type);

            if (deserializer != null)
            {
                return(deserializer(path));
            }

            throw new InvalidOperationException("Unknown ref type: " + type);
        }
コード例 #2
0
        ClientEndpoint Initialize(IClientEndpoint proxy)
        {
            this.proxy = proxy;

            Self = new ClientRef(proxy);

            return(this);
        }
コード例 #3
0
ファイル: Ref.cs プロジェクト: supwar/Orleankka
        public static Ref Deserialize(string path)
        {
            if (ClientRef.Satisfies(path))
            {
                return(ClientRef.Deserialize(path));
            }

            return(ActorRef.Deserialize(ActorPath.Deserialize(path)));
        }
コード例 #4
0
 ClientObservable(ClientRef @ref)
 {
     Ref = @ref;
 }