Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.jempeg.empeg.emptool
Class NodeTags  view NodeTags download NodeTags.java

java.lang.Object
  extended byorg.jempeg.empeg.emptool.NodeTags
All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable

public class NodeTags
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable

NodeTags is the datastructure that keeps track of a set of key-value pairs of MP3 tags (like title, album, etc.) There is one NodeTags for each FID that is loaded.

Version:
$Revision: 1.8 $

Field Summary
private  DatabaseTags myDBTags
           
private  java.util.Hashtable myTagToName
           
 
Constructor Summary
NodeTags(DatabaseTags _dbTags)
           
 
Method Summary
 void addEntries(byte[] _entries)
           
 void addEntries(byte[] _entries, int _pos)
           
 java.lang.Object clone()
          This method may be called to create a new copy of the Object.
 NodeTags cloneInto(PlayerDatabase _db)
           
 void copyFrom(NodeTags _fromTags)
           
 java.lang.String getGFID()
           
 int getTableLength()
           
 java.lang.String getTitle()
           
 java.lang.String getType()
           
 java.lang.String getValue(int _tag)
           
 java.lang.String getValue(java.lang.String _tagName)
           
 void setGFID(java.lang.String _gfid)
           
 void setTitle(java.lang.String _title)
           
 void setValue(int _tag, java.lang.String _name)
           
 java.lang.String toString()
          Convert this Object to a human-readable String.
 int[] whichTags()
           
 byte[] writeTable()
           
 void writeTable(java.io.OutputStream _os)
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

myTagToName

private java.util.Hashtable myTagToName

myDBTags

private DatabaseTags myDBTags
Constructor Detail

NodeTags

public NodeTags(DatabaseTags _dbTags)
Method Detail

clone

public java.lang.Object clone()
Description copied from class: java.lang.Object
This method may be called to create a new copy of the Object. The typical behavior is as follows:
  • o == o.clone() is false
  • o.getClass() == o.clone().getClass() is true
  • o.equals(o) is true

However, these are not strict requirements, and may be violated if necessary. Of the three requirements, the last is the most commonly violated, particularly if the subclass does not override Object.equals(Object)>Object.equals(Object) 55 .

If the Object you call clone() on does not implement java.lang.Cloneable (which is a placeholder interface), then a CloneNotSupportedException is thrown. Notice that Object does not implement Cloneable; this method exists as a convenience for subclasses that do.

Object's implementation of clone allocates space for the new Object using the correct class, without calling any constructors, and then fills in all of the new field values with the old field values. Thus, it is a shallow copy. However, subclasses are permitted to make a deep copy.

All array types implement Cloneable, and override this method as follows (it should never fail):

 public Object clone()
 {
   try
     {
       super.clone();
     }
   catch (CloneNotSupportedException e)
     {
       throw new InternalError(e.getMessage());
     }
 }
 


cloneInto

public NodeTags cloneInto(PlayerDatabase _db)

copyFrom

public void copyFrom(NodeTags _fromTags)

getValue

public java.lang.String getValue(java.lang.String _tagName)

getValue

public java.lang.String getValue(int _tag)

setValue

public void setValue(int _tag,
                     java.lang.String _name)

addEntries

public void addEntries(byte[] _entries)

addEntries

public void addEntries(byte[] _entries,
                       int _pos)

getTableLength

public int getTableLength()

writeTable

public byte[] writeTable()

writeTable

public void writeTable(java.io.OutputStream _os)

getType

public java.lang.String getType()

getTitle

public java.lang.String getTitle()

setTitle

public void setTitle(java.lang.String _title)

getGFID

public java.lang.String getGFID()

setGFID

public void setGFID(java.lang.String _gfid)

whichTags

public int[] whichTags()

toString

public java.lang.String toString()
Description copied from class: java.lang.Object
Convert this Object to a human-readable String. There are no limits placed on how long this String should be or what it should contain. We suggest you make it as intuitive as possible to be able to place it into System.out.println() 55 and such.

It is typical, but not required, to ensure that this method never completes abruptly with a java.lang.RuntimeException.

This method will be called when performing string concatenation with this object. If the result is null, string concatenation will instead use "null".

The default implementation returns getClass().getName() + "@" + Integer.toHexString(hashCode()).