fr.cnes.sitools.service.storage
Class StorageApplication

java.lang.Object
  extended by ExtendedWadlApplication
      extended by fr.cnes.sitools.common.application.SitoolsApplication
          extended by fr.cnes.sitools.service.storage.StorageApplication

public final class StorageApplication
extends SitoolsApplication

Application for managing directories for data storage in SITools.

Author:
jp.boignard (AKKA Technologies)

Constructor Summary
StorageApplication(org.restlet.Context context)
          Constructor
 
Method Summary
 org.restlet.Restlet createInboundRoot()
           
 void detachDirectory(StorageDirectory storageDirectory)
          Detach directory from application
 org.restlet.ext.wadl.ApplicationInfo getApplicationInfo(org.restlet.Request request, org.restlet.Response response)
           
 DataStorageStore getStore()
          Get the store associated to the application
 void initDirectory(StorageDirectory storageDirectory)
          Attach a directory in the application at start
 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.
 void startDirectory(StorageDirectory storageDirectory)
          Start a directory by attaching it to the route
 void stopDirectory(StorageDirectory storageDirectory)
          Stop a directory resource
 
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

StorageApplication

public StorageApplication(org.restlet.Context context)
Constructor

Parameters:
context - the RESTlet context must contain a DataStorageStore attribute for APP_STORE key
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()

initDirectory

public void initDirectory(StorageDirectory storageDirectory)
Attach a directory in the application at start

Parameters:
storageDirectory - the directory to attach

detachDirectory

public void detachDirectory(StorageDirectory storageDirectory)
Detach directory from application

Parameters:
storageDirectory - the directory to detach

startDirectory

public void startDirectory(StorageDirectory storageDirectory)
Start a directory by attaching it to the route

Parameters:
storageDirectory - the initial StorageDirectory

stopDirectory

public void stopDirectory(StorageDirectory storageDirectory)
Stop a directory resource

Parameters:
storageDirectory - the directory to stop

getStore

public DataStorageStore getStore()
Get the store associated to the application

Returns:
the store

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.