fr.cnes.sitools.plugins.applications
Class ApplicationPluginApplication

java.lang.Object
  extended by ExtendedWadlApplication
      extended by fr.cnes.sitools.common.application.SitoolsApplication
          extended by fr.cnes.sitools.plugins.applications.ApplicationPluginApplication

public final class ApplicationPluginApplication
extends SitoolsApplication

Application to handle ApplicationPluginModel. It offers a CRUD on ApplicationPluginModel and instantiate and attach new Applications

Author:
m.gond (AKKA Technologies)

Constructor Summary
ApplicationPluginApplication(org.restlet.routing.Router parentRouter, org.restlet.Context context)
          Constructor
 
Method Summary
 void attachApplication(ApplicationPluginModel model, boolean start)
          Create and attach a DataSetApplication according to the given DataSet object
 org.restlet.Restlet createInboundRoot()
           
 void detachApplication(ApplicationPluginModel model)
          Detach the application according to the given ApplicationPluginModel object
 void detachApplicationDefinively(ApplicationPluginModel appOutput)
          Detach definitively the application according to the given ApplicationPluginModel object
 org.restlet.ext.wadl.ApplicationInfo getApplicationInfo(org.restlet.Request request, org.restlet.Response response)
           
 ApplicationPluginStore getStore()
          Gets the store value
 void sitoolsDescribe()
          Abstract method for thinking about implementing it for each concrete application describe is the RESTlet method, but overriding, prevents the self-describing functionality.
 
Methods inherited from class fr.cnes.sitools.common.application.SitoolsApplication
addSecurity, addSecurity, addSecurityFilter, defaultDescribe, getAttachementRef, getAuthenticationRealm, getAuthorizer, getAuthorizer, getAuthorizer, getCategory, getId, getPublicBaseRef, getRepresentationInfoReferences, getSecure, getSettings, getSitoolsApplicationInfo, getType, getUserAuthorizer, isAuthorizationSecure, isUserAuthenticationNeeded, register, setAutoRegistration, setCategory, setId, setSitoolsApplicationInfo, setType, setUserAuthenticationNeeded, start, stop, unregister, wrapToResource
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ApplicationPluginApplication

public ApplicationPluginApplication(org.restlet.routing.Router parentRouter,
                                    org.restlet.Context context)
Constructor

Parameters:
parentRouter - the parent Router
context - Restlet Host Context
Method Detail

sitoolsDescribe

public void sitoolsDescribe()
Description copied from class: SitoolsApplication
Abstract method for thinking about implementing it for each concrete application describe is the RESTlet method, but overriding, prevents the self-describing functionality.

Specified by:
sitoolsDescribe in class SitoolsApplication

createInboundRoot

public org.restlet.Restlet createInboundRoot()

getStore

public ApplicationPluginStore getStore()
Gets the store value

Returns:
the store

attachApplication

public void attachApplication(ApplicationPluginModel model,
                              boolean start)
                       throws java.lang.Exception
Create and attach a DataSetApplication according to the given DataSet object

Parameters:
model - the model
start - indicates if the application has to be started
Throws:
java.lang.Exception - when attach fails

detachApplication

public void detachApplication(ApplicationPluginModel model)
Detach the application according to the given ApplicationPluginModel object

Parameters:
model - ApplicationPluginModel object

detachApplicationDefinively

public void detachApplicationDefinively(ApplicationPluginModel appOutput)
Detach definitively the application according to the given ApplicationPluginModel object

Parameters:
appOutput - the ApplicationPluginModel

getApplicationInfo

public org.restlet.ext.wadl.ApplicationInfo getApplicationInfo(org.restlet.Request request,
                                                               org.restlet.Response response)
Overrides:
getApplicationInfo in class SitoolsApplication


Copyright © 2010-2013 CNES. All Rights Reserved.