Package com.adobe.xmp.properties

Examples of com.adobe.xmp.properties.XMPProperty


    int match = ((Integer) result[0]).intValue();
    final XMPNode itemNode = (XMPNode) result[1];

    if (match != XMPNodeUtils.CLT_NO_VALUES)
    {
      return new XMPProperty()
      {
        public String getValue()
        {
          return itemNode.getValue();
        }
View Full Code Here


            XMPError.BADXPATH);
      }

      final Object value = evaluateNodeValue(valueType, propNode);

      return new XMPProperty()
      {
        public String getValue()
        {
          return value != null ? value.toString() : null;
        }
View Full Code Here

        xmpMeta.process( tikaMetadata, GENERIC_MIMETYPE );

        XMPMeta xmp = xmpMeta.getXMPData();

        // check simple property
        XMPProperty prop = xmp.getProperty( XMPConst.NS_DC, "format" );
        assertNotNull( prop );
        assertEquals( GENERIC_MIMETYPE, prop.getValue() );

        // check lang alt
        prop = xmp.getLocalizedText( XMPConst.NS_DC, "title", null, XMPConst.X_DEFAULT );
        assertNotNull( prop );
        assertEquals( "title", prop.getValue() );

        // check array
        prop = xmp.getArrayItem( XMPConst.NS_DC, "subject", 1 );
        assertNotNull( prop );
        assertEquals( "keyword1", prop.getValue() );
        prop = xmp.getArrayItem( XMPConst.NS_DC, "subject", 2 );
        assertNotNull( prop );
        assertEquals( "keyword2", prop.getValue() );
    }
View Full Code Here

  public String getXMP(String[] xmppath) {
    try {
      if (xmp==null) return "";
      //System.err.println(xmp.dumpObject());
      XMPProperty xp = xmp.getProperty(xmppath[0], xmppath[1]);
      if (xp==null) return "";
      return xp.toString();
    } catch (XMPException e) {
      e.printStackTrace();
      return "";
    }
  }
View Full Code Here

TOP

Related Classes of com.adobe.xmp.properties.XMPProperty

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.