コード例 #1
0
    public static void GenerateTypeAccessRepository(ACSContext Context)
    {
        var tA1 = new TypeAccess()
        {
            Name       = "Просмотр",
            s_AuthorID = 1,
            s_EditorID = 1,
        };
        var tA2 = new TypeAccess()
        {
            Name       = "Редактирование",
            s_AuthorID = 1,
            s_EditorID = 1,
        };
        var tA3 = new TypeAccess()
        {
            Name       = "Удаление",
            s_AuthorID = 1,
            s_EditorID = 1,
        };

        Context.TypeAccesses.AddRange(new List <TypeAccess>()
        {
            tA1, tA2, tA3
        });
        Context.SaveChanges();
    }
コード例 #2
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.CLASSINSTANCECREATION_METHOD:
                method = (AbstractMethodDeclaration)newValue;
                return;

            case Java_PackageImpl.CLASSINSTANCECREATION_ARGUMENTS:
                arguments.Clear();
                arguments.AddRange(((List <EObject>)newValue)?.Cast <Expression>());
                return;

            case Java_PackageImpl.CLASSINSTANCECREATION_TYPEARGUMENTS:
                typeArguments.Clear();
                typeArguments.AddRange(((List <EObject>)newValue)?.Cast <TypeAccess>());
                return;

            case Java_PackageImpl.CLASSINSTANCECREATION_ANONYMOUSCLASSDECLARATION:
                anonymousClassDeclaration = (AnonymousClassDeclaration)newValue;
                return;

            case Java_PackageImpl.CLASSINSTANCECREATION_EXPRESSION:
                expression = (Expression)newValue;
                return;

            case Java_PackageImpl.CLASSINSTANCECREATION_TYPE:
                type = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #3
0
 public override void eSet(int featureID, object newValue)
 {
     switch (featureID)
     {
     case Java_PackageImpl.CLASSDECLARATION_SUPERCLASS:
         superClass = (TypeAccess)newValue;
         return;
     }
     base.eSet(featureID, newValue);
 }
コード例 #4
0
 public override void eSet(int featureID, object newValue)
 {
     switch (featureID)
     {
     case Java_PackageImpl.TYPELITERAL_TYPE:
         type = (TypeAccess)newValue;
         return;
     }
     base.eSet(featureID, newValue);
 }
コード例 #5
0
 public override void eSet(int featureID, object newValue)
 {
     switch (featureID)
     {
     case Java_PackageImpl.ABSTRACTTYPEQUALIFIEDEXPRESSION_QUALIFIER:
         qualifier = (TypeAccess)newValue;
         return;
     }
     base.eSet(featureID, newValue);
 }
コード例 #6
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.WILDCARDTYPE_UPPERBOUND:
                upperBound = (bool)newValue;
                return;

            case Java_PackageImpl.WILDCARDTYPE_BOUND:
                bound = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #7
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.ARRAYTYPE_DIMENSIONS:
                dimensions = (int)newValue;
                return;

            case Java_PackageImpl.ARRAYTYPE_ELEMENTTYPE:
                elementType = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #8
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.MEMBERREF_MEMBER:
                member = (NamedElement)newValue;
                return;

            case Java_PackageImpl.MEMBERREF_QUALIFIER:
                qualifier = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #9
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.CASTEXPRESSION_EXPRESSION:
                expression = (Expression)newValue;
                return;

            case Java_PackageImpl.CASTEXPRESSION_TYPE:
                type = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #10
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.METHODREFPARAMETER_NAME:
                name = (string)newValue;
                return;

            case Java_PackageImpl.METHODREFPARAMETER_VARARGS:
                varargs = (bool)newValue;
                return;

            case Java_PackageImpl.METHODREFPARAMETER_TYPE:
                type = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #11
0
        public NotificationChain basicSetElementType(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _elementType;

            _elementType = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.ARRAYTYPE_ELEMENTTYPE, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #12
0
        public NotificationChain basicSetType(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _type;

            _type = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.CLASSINSTANCECREATION_TYPE, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #13
0
        public NotificationChain basicSetRightOperand(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _rightOperand;

            _rightOperand = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.INSTANCEOFEXPRESSION_RIGHTOPERAND, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #14
0
        public NotificationChain basicSetReturnType(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _returnType;

            _returnType = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.METHODDECLARATION_RETURNTYPE, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #15
0
        public NotificationChain basicSetType(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _type;

            _type = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.ABSTRACTVARIABLESCONTAINER_TYPE, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #16
0
        public NotificationChain basicSetBound(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _bound;

            _bound = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.WILDCARDTYPE_BOUND, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #17
0
        public NotificationChain basicSetQualifier(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _qualifier;

            _qualifier = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.METHODREF_QUALIFIER, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #18
0
        public NotificationChain basicSetSuperClass(TypeAccess newobj, NotificationChain msgs)
        {
            var oldobj = _superClass;

            _superClass = newobj;
            if (eNotificationRequired())
            {
                var notification = new ENotificationImpl(this, NotificationImpl.SET, Java_PackageImpl.CLASSDECLARATION_SUPERCLASS, oldobj, newobj);
                if (msgs == null)
                {
                    msgs = notification;
                }
                else
                {
                    msgs.add(notification);
                }
            }
            return(msgs);
        }
コード例 #19
0
        public override void eSet(int featureID, object newValue)
        {
            switch (featureID)
            {
            case Java_PackageImpl.ARRAYCREATION_DIMENSIONS:
                dimensions.Clear();
                dimensions.AddRange(((List <EObject>)newValue)?.Cast <Expression>());
                return;

            case Java_PackageImpl.ARRAYCREATION_INITIALIZER:
                initializer = (ArrayInitializer)newValue;
                return;

            case Java_PackageImpl.ARRAYCREATION_TYPE:
                type = (TypeAccess)newValue;
                return;
            }
            base.eSet(featureID, newValue);
        }
コード例 #20
0
ファイル: Compiler.cs プロジェクト: dpiatkowski/Expressions
 public void TypeAccess(TypeAccess typeAccess)
 {
     throw new ExpressionsException("Syntax error", ExpressionsExceptionType.TypeMismatch);
 }
コード例 #21
0
 private void PrintResolvedTypeAccess(TypeAccess node, int indent)
 {
     AppendLine(indent, "Type = " + node.Type);
 }
コード例 #22
0
ファイル: Compiler.cs プロジェクト: parsnips/Expressions
 public void TypeAccess(TypeAccess typeAccess)
 {
     throw new ExpressionsException("Syntax error", ExpressionsExceptionType.TypeMismatch);
 }
コード例 #23
0
 private void PrintResolvedTypeAccess(TypeAccess node, int indent)
 {
     AppendLine(indent, "Type = " + node.Type);
 }
コード例 #24
0
 public IExpression TypeAccess(TypeAccess typeAccess)
 {
     return(typeAccess);
 }