Package buri.ddmsence.ddms.extensible

Examples of buri.ddmsence.ddms.extensible.ExtensibleAttributes

The DDMS documentation does not provide sample HTML/Text output for extensible attributes, so the following approach is used. In general, the output of extensible attributes will be prefixed with the name of the element being marked. For example:

When output as JSON, properties will retain their namespace prefix. Because all values are stored as Strings, no casting is performed to Boolean or Number types.

Details about the XOM Attribute class can be found at: http://www.xom.nu/apidocs/index.html?nu/xom/Attribute.html

{@table.header History}

In DDMS 2.0, this attribute group can only decorate {@link buri.ddmsence.ddms.resource.Organization}, {@link buri.ddmsence.ddms.resource.Person}, {@link buri.ddmsence.ddms.resource.Service}, or the {@link Resource}.

In DDMS 3.0 and 3.1, this attribute group can decorate {@link buri.ddmsence.ddms.resource.Organization}, {@link buri.ddmsence.ddms.resource.Person}, {@link buri.ddmsence.ddms.resource.Service}, {@link buri.ddmsence.ddms.resource.Unknown}, {@link Keyword}, {@link Category}, or the {@link Resource} itself.

In DDMS 4.0.1 and 4.1, this attribute group was removed from {@link buri.ddmsence.ddms.resource.Person}.

In DDMS 5.0, this attribute group was also removed from {@link buri.ddmsence.ddms.resource.Organization} and{@link Resource}. It is anticipated that all remaining extension points will be deprecated in the next release.

{@table.footer}{@table.header Nested Elements}None. {@table.footer}{@table.header Attributes}{@child.info any:<extensibleAttributes>|0..*|11111}{@table.footer}{@table.header Validation Rules}Extensible attributes are not validated by DDMSence. {@table.footer} @author Brian Uri! @since 1.1.0

    DDMSVersion.setCurrentVersion("3.1");
    getInstance(builder, "Security attributes must not be applied");
   
    // No attributes in 2.0
    DDMSVersion.setCurrentVersion("2.0");
    ExtensibleAttributes attributes = ExtensibleAttributesTest.getFixture();
    builder = getBaseBuilder();
    builder.setExtensibleAttributes(new ExtensibleAttributes.Builder(attributes));
    getInstance(builder, "xs:anyAttribute must not be applied");
   
    DDMSVersion version = DDMSVersion.setCurrentVersion("3.0");
    Attribute attr = new Attribute("ddms:value", version.getNamespace(), "dog");

    // Using ddms:value as the extension (data)
    List<Attribute> extAttributes = new ArrayList<Attribute>();
    extAttributes.add(attr);
    attributes = new ExtensibleAttributes(extAttributes);
    builder = getBaseBuilder();
    builder.setExtensibleAttributes(new ExtensibleAttributes.Builder(attributes));
    getInstance(builder, "The extensible attribute with the name, ddms:value");
  }
View Full Code Here

TOP

Related Classes of buri.ddmsence.ddms.extensible.ExtensibleAttributes

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.