Package com.bradmcevoy.http.webdav

Examples of com.bradmcevoy.http.webdav.PropPatchHandler$SetField


        final ClassOrInterfaceTypeDetails simpleInterfaceDetails = typeParsingService
                .getTypeFromString(fileContents, SIMPLE_CLASS3_DECLARED_BY_MID,
                        SIMPLE_CLASS3_TYPE);

        final SetField fieldDetails = new SetField(
                SIMPLE_CLASS3_DECLARED_BY_MID, new JavaType(
                        SET.getFullyQualifiedTypeName(), 0, DataType.TYPE,
                        null, Arrays.asList(SIMPLE_CLASS3_TYPE)),
                new JavaSymbolName("children"), SIMPLE_CLASS3_TYPE,
                Cardinality.ONE_TO_MANY);

        final FieldMetadataBuilder fieldBuilder = new FieldMetadataBuilder(
                fieldDetails.getPhysicalTypeIdentifier(), Modifier.PRIVATE,
                new ArrayList<AnnotationMetadataBuilder>(),
                fieldDetails.getFieldName(), fieldDetails.getFieldType());
        fieldBuilder.setFieldInitializer("new HashSet<SimpleClass3>()");

        final ClassOrInterfaceTypeDetails newClassDetails = addField(
                simpleInterfaceDetails, fieldBuilder.build());
View Full Code Here


        Validate.notNull(javaTypeDetails,
                "The type specified, '%s', doesn't exist", typeName);

        final String physicalTypeIdentifier = javaTypeDetails
                .getDeclaredByMetadataId();
        final SetField fieldDetails = new SetField(physicalTypeIdentifier,
                new JavaType(SET.getFullyQualifiedTypeName(), 0, DataType.TYPE,
                        null, Arrays.asList(fieldType)), fieldName, fieldType,
                cardinality);
        fieldDetails.setNotNull(notNull);
        fieldDetails.setNullRequired(nullRequired);
        if (sizeMin != null) {
            fieldDetails.setSizeMin(sizeMin);
        }
        if (sizeMax != null) {
            fieldDetails.setSizeMax(sizeMax);
        }
        if (mappedBy != null) {
            fieldDetails.setMappedBy(mappedBy);
        }
        if (fetch != null) {
            fieldDetails.setFetch(fetch);
        }
        if (comment != null) {
            fieldDetails.setComment(comment);
        }

        insertField(fieldDetails, permitReservedWords, transientModifier);
    }
View Full Code Here

        final ClassOrInterfaceTypeDetails simpleInterfaceDetails = typeParsingService
                .getTypeFromString(fileContents, SIMPLE_CLASS3_DECLARED_BY_MID,
                        SIMPLE_CLASS3_TYPE);

        final SetField fieldDetails = new SetField(
                SIMPLE_CLASS3_DECLARED_BY_MID, new JavaType(
                        SET.getFullyQualifiedTypeName(), 0, DataType.TYPE,
                        null, Arrays.asList(SIMPLE_CLASS3_TYPE)),
                new JavaSymbolName("children"), SIMPLE_CLASS3_TYPE,
                Cardinality.ONE_TO_MANY);

        final FieldMetadataBuilder fieldBuilder = new FieldMetadataBuilder(
                fieldDetails.getPhysicalTypeIdentifier(), Modifier.PRIVATE,
                new ArrayList<AnnotationMetadataBuilder>(),
                fieldDetails.getFieldName(), fieldDetails.getFieldType());
        fieldBuilder.setFieldInitializer("new HashSet<SimpleClass3>()");

        ClassOrInterfaceTypeDetails newClassDetails = addField(
                simpleInterfaceDetails, fieldBuilder.build());
View Full Code Here

TOP

Related Classes of com.bradmcevoy.http.webdav.PropPatchHandler$SetField

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.