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

            Expression.Parent = this;
        }
Ejemplo n.º 2
0
        public LetStatement(Identifier identifier, Type type, Expression expression)
        {
            Variable = identifier.Value;
            Type = type;
            Expression = expression;

            Type.Parent = this;
            Expression.Parent = this;
        }
Ejemplo n.º 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;
            }
        }
Ejemplo n.º 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;
            }
        }
Ejemplo n.º 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)));
        }
Ejemplo n.º 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;
            }
        }
Ejemplo n.º 8
0
 public Type(Identifier identifier, Type type)
 {
     Name = identifier.Value;
     GenericType = type;
     GenericType.Parent = this;
 }
Ejemplo n.º 9
0
 public Type(Identifier identifier)
 {
     Name = identifier.Value;
     GenericType = null;
 }
Ejemplo n.º 10
0
 public VariableExpression(Identifier identifier)
 {
     Variable = identifier.Value;
 }
Ejemplo n.º 11
0
 public PropertyAssignable(Identifier identifier)
 {
     Property = identifier.Value;
 }
Ejemplo n.º 12
0
 public Import(Identifier identifier)
 {
     Name = identifier.Value;
 }
Ejemplo n.º 13
0
 public PropertyExpression(Identifier identifier)
 {
     Property = identifier.Value;
 }
Ejemplo n.º 14
0
 public Argument(Identifier identifier, Type type)
 {
     Name = identifier.Value;
     Type = type;
     Type.Parent = this;
 }
Ejemplo n.º 15
0
 public Class(Identifier identifier, Sequence<Property> properties, Sequence<Method> methods)
     : this(identifier, new Identifier("Any"), properties, methods)
 {
 }