SWIXML
1.6 (#161)

org.swixml
Class LayoutConverterLibrary

java.lang.Object
  extended by org.swixml.LayoutConverterLibrary

public class LayoutConverterLibrary
extends Object

The LayoutConverterLibrary contains all available LayoutConverters.

Author:
Karl Tauber
See Also:
LayoutConverter

Method Summary
static LayoutConverterLibrary getInstance()
          Returns the single instacne of the LayoutConverterLibrary.
 LayoutConverter getLayoutConverter(Class layoutClass)
          Returns a LayoutConverter instance, able to produce objects for the given layout manager class.
 LayoutConverter getLayoutConverterByID(String id)
          Returns a LayoutConverter instance, able to produce objects for the given layout manager id (see LayoutConverter.getID()).
 Map getLayoutConverters()
          Returns all registered layout converters.
 void register(Class layoutClass, LayoutConverter layoutConverter)
          Registers a LayoutConverter with the LayoutConverterLibrary.
 void register(String layoutClassName, LayoutConverter layoutConverter)
          Registers a LayoutConverter with the LayoutConverterLibrary.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static LayoutConverterLibrary getInstance()
Returns the single instacne of the LayoutConverterLibrary.


getLayoutConverters

public Map getLayoutConverters()
Returns all registered layout converters.


register

public void register(Class layoutClass,
                     LayoutConverter layoutConverter)
Registers a LayoutConverter with the LayoutConverterLibrary.

Parameters:
layoutClass - Type of the layout manager the LayoutConverter creates.
layoutConverter - Instance of LayoutConverter able to convert Strings into layout managers or layout constraints.

register

public void register(String layoutClassName,
                     LayoutConverter layoutConverter)
Registers a LayoutConverter with the LayoutConverterLibrary.

Parameters:
layoutClassName - Type name of the layout manager the LayoutConverter creates.
layoutConverter - Instance of LayoutConverter able to convert Strings into layout managers or layout constraints.

getLayoutConverter

public LayoutConverter getLayoutConverter(Class layoutClass)
Returns a LayoutConverter instance, able to produce objects for the given layout manager class.

Parameters:
layoutClass - Class of the object the LayoutConverter needs to produce.
Returns:
Instance of the LayoutConverter class.

getLayoutConverterByID

public LayoutConverter getLayoutConverterByID(String id)
Returns a LayoutConverter instance, able to produce objects for the given layout manager id (see LayoutConverter.getID()).

Parameters:
id - Identifier of the layout manager the LayoutConverter needs to produce.
Returns:
Instance of the LayoutConverter class.

SWIXML
1.6 (#161)

Copyright 2002 - 2011 - Wolf Paulus - wolfpaulus.com. All rights reserved.