org.exoplatform.web.application.gadget
Class GadgetApplication

java.lang.Object
  extended by org.exoplatform.container.component.BaseComponentPlugin
      extended by org.exoplatform.web.application.Application
          extended by org.exoplatform.web.application.gadget.GadgetApplication
All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin

public class GadgetApplication
extends Application

This class extends from Application, it represents an gadget application in eXo and used for registry Gadgets.


Field Summary
static java.lang.String EXO_GADGET_GROUP
           
 
Fields inherited from class org.exoplatform.web.application.Application
EXO_GAGGET_TYPE, EXO_PORTAL_TYPE, EXO_PORTLET_TYPE, EXO_WIDGET_TYPE, JSR168_APPLICATION_TYPE
 
Fields inherited from class org.exoplatform.container.component.BaseComponentPlugin
desc, name
 
Constructor Summary
GadgetApplication(java.lang.String name, java.lang.String url)
          Initializes a newly created GadgetApplication object
GadgetApplication(java.lang.String name, java.lang.String url, boolean isLocal)
           
 
Method Summary
 java.lang.String getApplicationGroup()
          Gets group of gadget application
 java.lang.String getApplicationId()
          Gets id of gadget application
 java.lang.String getApplicationName()
          Gets name of gadget application
 java.lang.String getApplicationType()
          Gets gadget application type
static org.apache.shindig.gadgets.spec.ModulePrefs getModulePreferences(org.apache.shindig.common.uri.Uri url, java.lang.String xml)
           
 java.util.ResourceBundle getOwnerResourceBundle(java.lang.String username, java.util.Locale locale)
          Gets owner resource bundle of gadget application
 java.util.ResourceBundle getResourceBundle(java.util.Locale locale)
          Gets resource bundle of gadget application
 java.lang.String getUrl()
          Gets url of gadget application
 boolean isLocal()
           
 
Methods inherited from class org.exoplatform.web.application.Application
getApplicationLifecycle, getApplicationServiceContainer, getAttribute, getResourceResolver, onDestroy, onInit, setApplicationLifecycle, setAttribute, setResourceResolver
 
Methods inherited from class org.exoplatform.container.component.BaseComponentPlugin
getDescription, getName, setDescription, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EXO_GADGET_GROUP

public static final java.lang.String EXO_GADGET_GROUP
See Also:
Constant Field Values
Constructor Detail

GadgetApplication

public GadgetApplication(java.lang.String name,
                         java.lang.String url)
Initializes a newly created GadgetApplication object

Parameters:
name - an String that is the application id of gadget application
url - an String that is the the url of gadget application such as "http://www.google.com/ig/modules/horoscope.xml"

GadgetApplication

public GadgetApplication(java.lang.String name,
                         java.lang.String url,
                         boolean isLocal)
Method Detail

getApplicationType

public java.lang.String getApplicationType()
Gets gadget application type

Specified by:
getApplicationType in class Application
Returns:
org.exoplatform.web.application.Application.EXO_GAGGET_TYPE
See Also:
Application

getApplicationGroup

public java.lang.String getApplicationGroup()
Gets group of gadget application

Specified by:
getApplicationGroup in class Application
Returns:
alway returns "eXoGadgets"

getUrl

public java.lang.String getUrl()
Gets url of gadget application

Returns:
string represents url of gadget application

getApplicationId

public java.lang.String getApplicationId()
Gets id of gadget application

Specified by:
getApplicationId in class Application
Returns:
the string represents id of gadget application

getApplicationName

public java.lang.String getApplicationName()
Gets name of gadget application

Specified by:
getApplicationName in class Application
Returns:
the string represents name of gadget application

isLocal

public boolean isLocal()

getModulePreferences

public static org.apache.shindig.gadgets.spec.ModulePrefs getModulePreferences(org.apache.shindig.common.uri.Uri url,
                                                                               java.lang.String xml)
                                                                        throws java.lang.Exception
Throws:
java.lang.Exception

getOwnerResourceBundle

public java.util.ResourceBundle getOwnerResourceBundle(java.lang.String username,
                                                       java.util.Locale locale)
                                                throws java.lang.Exception
Gets owner resource bundle of gadget application

Specified by:
getOwnerResourceBundle in class Application
Parameters:
username - remote username logged in portal
locale - the location of logged user
Returns:
always return null
Throws:
java.lang.Exception - if can't get the resource bundle by the ResouceBundleService

getResourceBundle

public java.util.ResourceBundle getResourceBundle(java.util.Locale locale)
                                           throws java.lang.Exception
Gets resource bundle of gadget application

Specified by:
getResourceBundle in class Application
Parameters:
locale - the location of logged user
Returns:
always return null
Throws:
java.lang.Exception - if can't get the resource bundle by the ResourceBundleService


Copyright © 2010 eXo Platform SAS. All Rights Reserved.