Package org.apache.padaf.xmpbox.schema

Examples of org.apache.padaf.xmpbox.schema.SchemaExtensionDefinition


    if (ext == null) {
      ext = metadata.createAndAddPDFAExtensionSchemaWithDefaultNS();
    }
    Field[] fields;
    fields = classSchem.getFields();
    SchemaExtensionDefinition schemDefAnnot;
    PropertyExtensionDefinition propExtDefAnnot;
    PropertyType propTypeAnnot;
    String propName = null;
    String propDesc;
    List<PropertyDescription> xmlPropDesc = null;
    if (classSchem.isAnnotationPresent(SchemaExtensionDefinition.class)) {
      schemDefAnnot = classSchem
          .getAnnotation(SchemaExtensionDefinition.class);
      // Try to find and load XML Properties Descriptions file path
      if (!schemDefAnnot.property_descriptions().equals("")) {
        XMLPropertiesDescriptionManager propManag = new XMLPropertiesDescriptionManager();
        propManag.loadListFromXML(classSchem, schemDefAnnot
            .property_descriptions());
        xmlPropDesc = propManag.getPropertiesDescriptionList();
      }
      SchemaDescription desc = ext.createSchemaDescription();
      desc.setSchemaValue(schemDefAnnot.schema());
      desc.setNameSpaceURIValue(schema.getNamespaceValue());
      desc.setPrefixValue(schema.getPrefix());
      ext.addSchemaDescription(desc);
      // Try to find and load XML ValueType Description file path
      if (!schemDefAnnot.valueType_description().equals("")) {
        XMLValueTypeDescriptionManager valTypesManag = new XMLValueTypeDescriptionManager();
        valTypesManag.loadListFromXML(classSchem, schemDefAnnot
            .valueType_description());
        addValueTypesToSchem(metadata, desc, valTypesManag
            .getValueTypesDescriptionList());
      }
      for (Field field : fields) {
View Full Code Here

TOP

Related Classes of org.apache.padaf.xmpbox.schema.SchemaExtensionDefinition

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.