public ExpressionPropertyExpression(Expression expression, Identifier identifier)
        {
            Expression = expression;
            Property = identifier.Value;

            Expression.Parent = this;
        }
Пример #2
0
        public LetStatement(Identifier identifier, Type type, Expression expression)
        {
            Variable = identifier.Value;
            Type = type;
            Expression = expression;

            Type.Parent = this;
            Expression.Parent = this;
        }
Пример #3
0
        public MethodCallExpression(Identifier identifier, Sequence<Expression> parameters)
        {
            Method = identifier.Value;
            Parameters = parameters;

            foreach (var parameter in Parameters)
            {
                parameter.Parent = this;
            }
        }
        public ParentMethodCallExpression(Identifier parentIdentifier, Identifier methodIdentifier, Sequence<Expression> parameters)
        {
            ParentClass = parentIdentifier.Value;
            Method = methodIdentifier.Value;
            Parameters = parameters;

            foreach (var parameter in Parameters)
            {
                parameter.Parent = this;
            }
        }
Пример #5
0
        public Module(Identifier identifier, Sequence<Import> imports, Sequence<Class> classes)
        {
            Name = identifier.Value;
            Imports = imports;
            Classes = classes;

            foreach (var import in imports)
            {
                import.Parent = this;
            }

            foreach (var @class in classes)
            {
                @class.Parent = this;
            }
        }
Пример #6
0
        public Method(Identifier identifier, Sequence<Argument> arguments, Type type, Block block)
        {
            Name = identifier.Value;
            Arguments = arguments;
            Type = type;
            Block = block;

            foreach (var argument in arguments)
            {
                argument.Parent = this;
            }

            Type.Parent = this;
            Block.Parent = this;

            FullName = string.Format("{0}:{1}", Name, String.Join(":", Arguments.Select(a => a.Type)));
        }
Пример #7
0
        public Class(Identifier identifier, Identifier parentIdentifier, Sequence<Property> properties, Sequence<Method> methods)
        {
            Name = identifier.Value;
            Properties = properties;
            Methods = methods;
            ParentName = parentIdentifier.Value;

            foreach (var property in Properties)
            {
                property.Parent = this;
            }

            foreach (var method in Methods)
            {
                method.Parent = this;
            }
        }
Пример #8
0
 public Type(Identifier identifier, Type type)
 {
     Name = identifier.Value;
     GenericType = type;
     GenericType.Parent = this;
 }
Пример #9
0
 public Type(Identifier identifier)
 {
     Name = identifier.Value;
     GenericType = null;
 }
Пример #10
0
 public VariableExpression(Identifier identifier)
 {
     Variable = identifier.Value;
 }
Пример #11
0
 public PropertyAssignable(Identifier identifier)
 {
     Property = identifier.Value;
 }
Пример #12
0
 public Import(Identifier identifier)
 {
     Name = identifier.Value;
 }
Пример #13
0
 public PropertyExpression(Identifier identifier)
 {
     Property = identifier.Value;
 }
Пример #14
0
 public Argument(Identifier identifier, Type type)
 {
     Name = identifier.Value;
     Type = type;
     Type.Parent = this;
 }
Пример #15
0
 public Class(Identifier identifier, Sequence<Property> properties, Sequence<Method> methods)
     : this(identifier, new Identifier("Any"), properties, methods)
 {
 }