Exemple #1
0
        private OwType DefineType(string name)
        {
            var type = new OwType(name);

            definedTypes.Add(type);
            return(type);
        }
Exemple #2
0
        private string FlattenType(OwType type)
        {
            if (type.IsPrimitive)
            {
                return(type.Name);
            }

            return(string.Join(" ", Type.GetFields().Select(field => FlattenType(field.FieldType))));
        }
Exemple #3
0
 internal void AddMethod(OwMemberAccess access, string identifier, OwType resultType, OwParameterInfo[] parameters)
 {
     members.Add(new OwMethodInfo(this, access, identifier, resultType, parameters));
 }
Exemple #4
0
 internal void AddField(OwMemberAccess access, string identifier, OwType type)
 {
     members.Add(new OwFieldInfo(this, access, identifier, type));
 }
Exemple #5
0
 public ObjWastLocal(OwType type)
     : base(type)
 {
 }
Exemple #6
0
 public ObjWastLocal(string identifier, OwType type)
     : base(identifier, type)
 {
 }
Exemple #7
0
 internal void DefineMethod(OwMemberAccess access, string identifier, OwType resultType, OwParameterInfo[] parameters)
 {
     type.AddMethod(access, identifier, resultType, parameters);
 }
Exemple #8
0
 internal void DefineField(OwMemberAccess access, string identifier, OwType fieldType)
 {
     type.AddField(access, identifier, fieldType);
 }
Exemple #9
0
        internal override void Parse(ObjWastTranspiler transpiler)
        {
            string name = transpiler.ParseName();

            type = Module.DefineType(name);
        }