com.realtime.crossfire.jxclient.skin.io
Class GuiElementParser

java.lang.Object
  extended by com.realtime.crossfire.jxclient.skin.io.GuiElementParser

public class GuiElementParser
extends java.lang.Object

Creates gui element instances from string representations.


Field Summary
private  JXCSkinCache<GUIElement> definedGUIElements
          The defined GUIElements.
 
Constructor Summary
GuiElementParser(JXCSkinCache<GUIElement> definedGUIElements)
          Creates a new instance.
 
Method Summary
 AbstractLabel lookupLabelElement(java.lang.String name)
          Returns a AbstractLabel by element name.
 GUIText lookupTextElement(java.lang.String name)
          Returns a GUIText by element name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

definedGUIElements

@NotNull
private final JXCSkinCache<GUIElement> definedGUIElements
The defined GUIElements.

Constructor Detail

GuiElementParser

public GuiElementParser(@NotNull
                        JXCSkinCache<GUIElement> definedGUIElements)
Creates a new instance.

Parameters:
definedGUIElements - the defined gui elements
Method Detail

lookupLabelElement

@NotNull
public AbstractLabel lookupLabelElement(@NotNull
                                                java.lang.String name)
                                 throws JXCSkinException
Returns a AbstractLabel by element name.

Parameters:
name - the element name
Returns:
the AbstractLabel element
Throws:
JXCSkinException - if the element name is undefined

lookupTextElement

@NotNull
public GUIText lookupTextElement(@NotNull
                                         java.lang.String name)
                          throws JXCSkinException
Returns a GUIText by element name.

Parameters:
name - the element name
Returns:
the GUIText element
Throws:
JXCSkinException - if the element name is undefined