Examples of AnnotationHeader


Examples of org.openbel.framework.core.df.beldata.annotation.AnnotationHeader

                ANNOTATIONS, resourceLocation);

        AnnotationHeaderProcessor annotationHeaderProcessor =
                new AnnotationHeaderProcessor();

        AnnotationHeader annotationHeader;
        try {
            annotationHeader =
                    annotationHeaderProcessor
                            .processAnnotationHeader(resourceLocation,
                                    annotationCacheCopy,
                                    cacheResource
                                            .getLocalFile());
        } catch (IndexingFailure e) {
            throw new AnnotationDefinitionResolutionException(resourceLocation,
                    e.getMessage());
        }

        AnnotationDefinition annotationDefinition = CommonModelFactory
                .getInstance().createAnnotationDefinition(annotationHeader.
                        getAnnotationBlock().getKeyword());
        annotationDefinition.setDescription(annotationHeader
                .getAnnotationBlock().getDescriptionString());
        annotationDefinition.setUsage(annotationHeader.getAnnotationBlock()
                .getUsageString());
        annotationDefinition.setType(annotationHeader.getAnnotationBlock()
                .getAnnotationType());
        annotationDefinition.setURL(resourceLocation);

        long characterOffset = annotationHeaderProcessor
                .getCharacterStopOffset();

        try {
            switch (annotationDefinition.getType()) {
            case ENUMERATION:
                annotationDefinition.setEnums(parseEnumData(
                        annotationCacheCopy,
                        annotationHeader.getProcessingBlock()
                                .getDelimiterString(),
                        characterOffset));
                break;
            case REGULAR_EXPRESSION:
                annotationDefinition.setValue(parseRegularExpression(
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.