synergynetframework.appsystem.table.appregistry
Class ApplicationRegistry

java.lang.Object
  extended by synergynetframework.appsystem.table.appregistry.ApplicationRegistry

public class ApplicationRegistry
extends java.lang.Object

The Class ApplicationRegistry.


Method Summary
 java.util.Collection<ApplicationInfo> getAllInfo()
          Gets the all info.
 SynergyNetApp getAppInstance(ApplicationInfo ai)
          Gets the app instance.
 SynergyNetApp getAppInstance(java.util.Map<java.lang.String,SynergyNetApp> map, ApplicationInfo info)
          Gets the app instance.
 SynergyNetApp getClientAppInstance(ApplicationInfo info)
          Gets the client app instance.
 SynergyNetApp getControllerAppInstance(ApplicationInfo info)
          Gets the controller app instance.
 ApplicationInfo getDefaultApp()
          Gets the default app.
 SynergyNetApp getFreshAppInstance(ApplicationInfo ai)
          Gets the fresh app instance.
 ApplicationInfo getInfoForClassName(java.lang.String classname)
          Gets the info for class name.
 ApplicationInfo getInfoForName(java.lang.String appName, java.lang.String type)
          Gets the info for name.
static ApplicationRegistry getInstance()
          Gets the single instance of ApplicationRegistry.
 SynergyNetApp getProjectorAppInstance(ApplicationInfo info)
          Gets the projector app instance.
 void register(ApplicationInfo info)
          Register.
 void removeInstance(ApplicationInfo info)
          Removes the instance.
 void setDefault(java.lang.String classname)
          Sets the default.
 void setDefaultApp(ApplicationInfo defaultApp)
          Sets the default app.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getInstance

public static ApplicationRegistry getInstance()
Gets the single instance of ApplicationRegistry.

Returns:
single instance of ApplicationRegistry

getAllInfo

public java.util.Collection<ApplicationInfo> getAllInfo()
Gets the all info.

Returns:
the all info

getAppInstance

public SynergyNetApp getAppInstance(ApplicationInfo ai)
                             throws java.lang.InstantiationException,
                                    java.lang.IllegalAccessException,
                                    java.lang.ClassNotFoundException,
                                    java.lang.SecurityException,
                                    java.lang.IllegalArgumentException,
                                    java.lang.NoSuchMethodException,
                                    java.lang.reflect.InvocationTargetException
Gets the app instance.

Parameters:
ai - the ai
Returns:
the app instance
Throws:
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

getAppInstance

public SynergyNetApp getAppInstance(java.util.Map<java.lang.String,SynergyNetApp> map,
                                    ApplicationInfo info)
                             throws java.lang.SecurityException,
                                    java.lang.IllegalArgumentException,
                                    java.lang.InstantiationException,
                                    java.lang.IllegalAccessException,
                                    java.lang.ClassNotFoundException,
                                    java.lang.NoSuchMethodException,
                                    java.lang.reflect.InvocationTargetException
Gets the app instance.

Parameters:
map - the map
info - the info
Returns:
the app instance
Throws:
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

getClientAppInstance

public SynergyNetApp getClientAppInstance(ApplicationInfo info)
                                   throws java.lang.SecurityException,
                                          java.lang.IllegalArgumentException,
                                          java.lang.InstantiationException,
                                          java.lang.IllegalAccessException,
                                          java.lang.ClassNotFoundException,
                                          java.lang.NoSuchMethodException,
                                          java.lang.reflect.InvocationTargetException
Gets the client app instance.

Parameters:
info - the info
Returns:
the client app instance
Throws:
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

getControllerAppInstance

public SynergyNetApp getControllerAppInstance(ApplicationInfo info)
                                       throws java.lang.SecurityException,
                                              java.lang.IllegalArgumentException,
                                              java.lang.InstantiationException,
                                              java.lang.IllegalAccessException,
                                              java.lang.ClassNotFoundException,
                                              java.lang.NoSuchMethodException,
                                              java.lang.reflect.InvocationTargetException
Gets the controller app instance.

Parameters:
info - the info
Returns:
the controller app instance
Throws:
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

getDefaultApp

public ApplicationInfo getDefaultApp()
Gets the default app.

Returns:
the default app

getFreshAppInstance

public SynergyNetApp getFreshAppInstance(ApplicationInfo ai)
                                  throws java.lang.InstantiationException,
                                         java.lang.IllegalAccessException,
                                         java.lang.ClassNotFoundException,
                                         java.lang.SecurityException,
                                         java.lang.IllegalArgumentException,
                                         java.lang.NoSuchMethodException,
                                         java.lang.reflect.InvocationTargetException
Gets the fresh app instance.

Parameters:
ai - the ai
Returns:
the fresh app instance
Throws:
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

getInfoForClassName

public ApplicationInfo getInfoForClassName(java.lang.String classname)
Gets the info for class name.

Parameters:
classname - the classname
Returns:
the info for class name

getInfoForName

public ApplicationInfo getInfoForName(java.lang.String appName,
                                      java.lang.String type)
Gets the info for name.

Parameters:
appName - the app name
type - the type
Returns:
the info for name

getProjectorAppInstance

public SynergyNetApp getProjectorAppInstance(ApplicationInfo info)
                                      throws java.lang.SecurityException,
                                             java.lang.IllegalArgumentException,
                                             java.lang.InstantiationException,
                                             java.lang.IllegalAccessException,
                                             java.lang.ClassNotFoundException,
                                             java.lang.NoSuchMethodException,
                                             java.lang.reflect.InvocationTargetException
Gets the projector app instance.

Parameters:
info - the info
Returns:
the projector app instance
Throws:
java.lang.SecurityException - the security exception
java.lang.IllegalArgumentException - the illegal argument exception
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception
java.lang.NoSuchMethodException - the no such method exception
java.lang.reflect.InvocationTargetException - the invocation target exception

register

public void register(ApplicationInfo info)
              throws java.lang.InstantiationException,
                     java.lang.IllegalAccessException,
                     java.lang.ClassNotFoundException
Register.

Parameters:
info - the info
Throws:
java.lang.InstantiationException - the instantiation exception
java.lang.IllegalAccessException - the illegal access exception
java.lang.ClassNotFoundException - the class not found exception

removeInstance

public void removeInstance(ApplicationInfo info)
Removes the instance.

Parameters:
info - the info

setDefault

public void setDefault(java.lang.String classname)
Sets the default.

Parameters:
classname - the new default

setDefaultApp

public void setDefaultApp(ApplicationInfo defaultApp)
Sets the default app.

Parameters:
defaultApp - the new default app

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object