예제 #1
0
        public static OutPackageMemberScope LoadOutPackageMemberScope(BinaryReader reader, CSWCSerizlizer serizlizer, IDictionary <int, object> serizlized, int key)
        {
            OutPackageMemberScope scope = new OutPackageMemberScope(null); serizlized.Add(key, scope);

            rtti.Class mainclass = serizlizer.DeserializeObject <rtti.Class>(reader, rtti.Class.LoadClass);
            scope.mainclass = mainclass;
            scope.LoadScopeBase(reader, serizlizer);
            return(scope);
        }
예제 #2
0
파일: ScopeBase.cs 프로젝트: ikvm/ASTool
        public static ScopeBase Deserialize(BinaryReader reader, CSWCSerizlizer serizlizer, IDictionary <int, object> serizlized, int key)
        {
            string type = reader.ReadString();

            if (type == "FunctionScope")
            {
                return(FunctionScope.LoadFunctionScope(reader, serizlizer, serizlized, key));
            }
            else if (type == "ObjectInstanceScope")
            {
                return(ObjectInstanceScope.LoadObjectInstanceScope(reader, serizlizer, serizlized, key));
            }
            else if (type == "OutPackageMemberScope")
            {
                return(OutPackageMemberScope.LoadOutPackageMemberScope(reader, serizlizer, serizlized, key));
            }
            else
            {
                throw new IOException("异常的Scope类型");
            }
        }