Package entagged.audioformats.generic

Examples of entagged.audioformats.generic.TagField


        if(l == null)
            continue;
       
        Iterator it = l.iterator();
        while(it.hasNext()) {
            TagField f = (TagField) it.next();
            ApicId3Frame pic = (ApicId3Frame) f;
            byte[] data = pic.getData();
              Image img = ImageIO.read(new ByteArrayInputStream(data));
              System.out.println(img);
             
View Full Code Here


  private static Id3v2Tag convert22to23(Id3v2Tag source) {
    assert source != null
        && source.getRepresentedVersion() == Id3v2Tag.ID3V22;
    Iterator fields = source.getFields();
    while (fields.hasNext()) {
      TagField current = (TagField) fields.next();
      String currentId = current.getId();
      String conv = (String) conversion22to23.get(currentId);
      if (currentId.equals(conv)) {
        fields.remove();
        if (current instanceof TextId3Frame) {
          source.add(new TextId3Frame(conv, ((TextId3Frame) current)
View Full Code Here

    assert source != null
        && source.getRepresentedVersion() == Id3v2Tag.ID3V22;
    Iterator fields = source.getFields();
    HashMap specialStore = new HashMap();
    while (fields.hasNext()) {
      TagField current = (TagField) fields.next();
      if (specialStore24.contains(current.getId())) {
        specialStore.put(current.getId(), current);
      }
      if (discard24.contains(current.getId())) {
        fields.remove();
      }
    }
    /*
     * Now convert some Special Fields.
View Full Code Here

      ExtendedContentDescription descriptor) {
    Iterator it = tag.getFields();
    ContentDescriptor tmp = null;
    while (it.hasNext()) {
      try {
        TagField currentField = (TagField) it.next();
        if (!currentField.isCommon()) {
          tmp = new ContentDescriptor(currentField.getId(),
              ContentDescriptor.TYPE_STRING);
          if (currentField.isBinary()) {
            tmp.setBinaryValue(currentField.getRawContent());
          } else {
            tmp.setStringValue(currentField.toString());
          }
          descriptor.addOrReplace(tmp);
        }
      } catch (UnsupportedEncodingException uee) {
        uee.printStackTrace();
View Full Code Here

   */
  public static TagTextField getCopyright(Tag tag) {
    TagTextField result = null;
    List list = tag.get(FIELD_ID);
    if (list != null && list.size() > 0) {
      TagField field = (TagField) list.get(0);
      if (field instanceof TagTextField) {
        result = (TagTextField) field;
      }
    }
    return result;
View Full Code Here

TOP

Related Classes of entagged.audioformats.generic.TagField

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.