<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">java.lang.Object</A>
<IMGSRC="../../../resources/inherit.gif"ALT="extended by "><B>com.mxgraph.io.mxCodecRegistry</B>
</PRE>
<HR>
<DL>
<DT><PRE>public class <B>mxCodecRegistry</B><DT>extends <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A></DL>
</PRE>
<P>
Singleton class that acts as a global registry for codecs. See
<AHREF="../../../com/mxgraph/io/mxCodec.html"title="class in com.mxgraph.io"><CODE>mxCodec</CODE></A> for an example.
<CODE>protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/Hashtable.html?is-external=true"title="class or interface in java.util">Hashtable</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>,<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>></CODE></FONT></TD>
<CODE>protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/Hashtable.html?is-external=true"title="class or interface in java.util">Hashtable</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>,<AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A>></CODE></FONT></TD>
<CODE>protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/List.html?is-external=true"title="class or interface in java.util">List</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#addAlias(java.lang.String, java.lang.String)">addAlias</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> classname,
<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> codecname)</CODE>
<BR>
Adds an alias for mapping a classname to a codecname.</TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#addPackage(java.lang.String)">addPackage</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> packagename)</CODE>
<BR>
Adds the given package name to the list of known package names.</TD>
<CODE>static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true"title="class or interface in java.lang">Class</A><?></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#getClassForName(java.lang.String)">getClassForName</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</CODE>
<BR>
Returns a class that corresponds to the given name.</TD>
<CODE>static <AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#getCodec(java.lang.String)">getCodec</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</CODE>
<BR>
Returns a codec that handles the given object, which can be an object
<CODE>static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#getInstanceForName(java.lang.String)">getInstanceForName</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</CODE>
<BR>
Creates and returns a new instance for the given class name.</TD>
<CODE>static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#getName(java.lang.Object)">getName</A></B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A> instance)</CODE>
<BR>
Returns the name that identifies the codec associated
<CODE>static <AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A></CODE></FONT></TD>
<TD><CODE><B><AHREF="../../../com/mxgraph/io/mxCodecRegistry.html#register(com.mxgraph.io.mxObjectCodec)">register</A></B>(<AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A> codec)</CODE>
<BR>
Registers a new codec and associates the name of the template constructor
<THALIGN="left"><B>Methods inherited from class java.lang.<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A></B></TH>
</TR>
<TRBGCOLOR="white"CLASS="TableRowColor">
<TD><CODE><AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#clone()"title="class or interface in java.lang">clone</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)"title="class or interface in java.lang">equals</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#finalize()"title="class or interface in java.lang">finalize</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()"title="class or interface in java.lang">getClass</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()"title="class or interface in java.lang">hashCode</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify()"title="class or interface in java.lang">notify</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll()"title="class or interface in java.lang">notifyAll</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()"title="class or interface in java.lang">toString</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait()"title="class or interface in java.lang">wait</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long)"title="class or interface in java.lang">wait</A>, <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)"title="class or interface in java.lang">wait</A></CODE></TD>
protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/Hashtable.html?is-external=true"title="class or interface in java.util">Hashtable</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>,<AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A>><B>codecs</B></PRE>
<DL>
<DD>Maps from constructor names to codecs.
<P>
<DL>
</DL>
</DL>
<HR>
<ANAME="aliases"><!----></A><H3>
aliases</H3>
<PRE>
protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/Hashtable.html?is-external=true"title="class or interface in java.util">Hashtable</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>,<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>><B>aliases</B></PRE>
<DL>
<DD>Maps from classnames to codecnames.
<P>
<DL>
</DL>
</DL>
<HR>
<ANAME="packages"><!----></A><H3>
packages</H3>
<PRE>
protected static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/util/List.html?is-external=true"title="class or interface in java.util">List</A><<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A>><B>packages</B></PRE>
<DL>
<DD>Holds the list of known packages. Packages are used to prefix short
public static <AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A><B>register</B>(<AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A> codec)</PRE>
<DL>
<DD>Registers a new codec and associates the name of the template constructor
in the codec with the codec object. Automatically creates an alias if the
public static void <B>addAlias</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> classname,
<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> codecname)</PRE>
<DL>
<DD>Adds an alias for mapping a classname to a codecname.
public static <AHREF="../../../com/mxgraph/io/mxObjectCodec.html"title="class in com.mxgraph.io">mxObjectCodec</A><B>getCodec</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</PRE>
<DL>
<DD>Returns a codec that handles the given object, which can be an object
instance or an XML node.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>name</CODE> - Java class name.</DL>
public static void <B>addPackage</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> packagename)</PRE>
<DL>
<DD>Adds the given package name to the list of known package names.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>packagename</CODE> - Name of the package to be added.</DL>
public static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A><B>getInstanceForName</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</PRE>
<DL>
<DD>Creates and returns a new instance for the given class name.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>name</CODE> - Name of the class to be instantiated.
<DT><B>Returns:</B><DD>Returns a new instance of the given class.</DL>
public static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true"title="class or interface in java.lang">Class</A><?><B>getClassForName</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A> name)</PRE>
<DL>
<DD>Returns a class that corresponds to the given name.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>name</CODE> -
<DT><B>Returns:</B><DD>Returns the class for the given name.</DL>
public static <AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true"title="class or interface in java.lang">String</A><B>getName</B>(<AHREF="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true"title="class or interface in java.lang">Object</A> instance)</PRE>
<DL>
<DD>Returns the name that identifies the codec associated
with the given instance..
The I/O system uses unqualified classnames, eg. for a
<code>com.mxgraph.model.mxCell</code> this returns
<code>mxCell</code>.
<P>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>instance</CODE> - Instance whose node name should be returned.
<DT><B>Returns:</B><DD>Returns a string that identifies the codec.</DL>