Package org.apache.padaf.xmpbox.type

Examples of org.apache.padaf.xmpbox.type.BooleanType


   * @throws Exception
   */
  @Test
  public void testObjectCreationWithNamespace() throws Exception {
    String ns = "http://www.test.org/pdfa/";
    BooleanType bool = new BooleanType(parent, ns, "test", "booleen", true);
    DateType date = new DateType(parent, ns, "test", "date", Calendar
        .getInstance());
    IntegerType integer = new IntegerType(parent, ns, "test", "integer", 1);
    RealType real = new RealType(parent, ns, "test", "real", (float) 1.6);
    TextType text = new TextType(parent, ns, "test", "text", "TEST");

    Assert.assertEquals(ns, bool.getNamespace());
    Assert.assertEquals(ns, date.getNamespace());
    Assert.assertEquals(ns, integer.getNamespace());
    Assert.assertEquals(ns, real.getNamespace());
    Assert.assertEquals(ns, text.getNamespace());

    Element e = parent.getFuturOwner().createElement("TEST");
    parent.getFuturOwner().appendChild(e);
    e.appendChild(bool.getElement());
    e.appendChild(date.getElement());
    e.appendChild(integer.getElement());
    e.appendChild(real.getElement());
    e.appendChild(text.getElement());

View Full Code Here


   *
   * @param marked
   *            value to add
   */
  public void setMarkedValue(Boolean marked) {
    addProperty(new BooleanType(metadata, localPrefix, MARKED, marked));
  }
View Full Code Here

   * Get Marked value
   *
   * @return marked value
   */
  public Boolean getMarkedValue() {
    BooleanType bt = ((BooleanType) getProperty(localPrefixSep + MARKED));
    return bt == null ? null : bt.getValue();
  }
View Full Code Here

      }
    }

    XMPRightsManagementSchema rights = metadata.getXMPRightsManagementSchema();
    if (rights != null) {
      BooleanType marked = rights.getMarked();
      if (marked != null && !marked.getValue()) {
        ve
        .add(new ValidationError(
            ValidationConstants.ERROR_METADATA_PROPERTY_MISSING,
        "the XMP information (xmpRights:Marked) is invalid for the Font File Stream."));
        return false;
View Full Code Here

TOP

Related Classes of org.apache.padaf.xmpbox.type.BooleanType

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.