Package eu.admire.dispel.parser.types

Examples of eu.admire.dispel.parser.types.DomainType


                "}";
        mRegistry.register("MyDType",
                new DispelObject(
                        "MyDType",
                        DispelObjectType.DOMAIN_TYPE,
                        new DomainType(new SimpleDType())));
        mRegistry.register("MySType",
                new DispelObject(
                        "MySType",
                        DispelObjectType.STRUCTURAL_TYPE,
                        new StructuralType(new PrimitiveSType("Integer"))));
View Full Code Here


                "with f(g(h(x))), " +
                "@description=\"This is X!\";");
        TestCase.assertNull(mGraphBuilder.getError());
        Type type = builder.getDispelExecutionState().getUsedProcessingElements().getType("X");
        TestCase.assertTrue(type instanceof DomainType);
        DomainType dtype = (DomainType)type;
        TestCase.assertEquals("This is X!", dtype.getAnnotation("description"));
        Object assertion = dtype.getAnnotation(AnnotationKeys.ASSERTION_EXPRESSIONS);
        TestCase.assertTrue(assertion instanceof List<?>);
        List<?> expressions = (List<?>)assertion;
        TestCase.assertEquals(1, expressions.size());
    }
View Full Code Here

        return mName;
    }
   
    public DomainType getType()
    {
        DomainType domainType = new DomainType(mDomainType);
        List<Object> expressions = new ArrayList<Object>();
        domainType.addAnnotation(
                AnnotationKeys.ASSERTION_EXPRESSIONS, expressions);
        for (WithAssertionStrategy assertion : mAssertions)
        {
            if (assertion.getAnnotationKey() != null)
            {
                domainType.addAnnotation(
                        assertion.getAnnotationKey(),
                        assertion.getAnnotationValue());
            }
            if (assertion.getExpressionAssertion() != null)
            {
View Full Code Here

        SimpleDType dtype = new SimpleDType();
        dtype.setRepresents(represents);
        DispelObject dtypeObj = new DispelObject(
                dispelName,
                DispelObjectType.DOMAIN_TYPE,
                new DomainType(dtype));
        mRegistry.register(dispelName, dtypeObj);
    }
View Full Code Here

TOP

Related Classes of eu.admire.dispel.parser.types.DomainType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.