|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfr.cnes.sitools.resources.order.utils.ListReferencesAPI
public class ListReferencesAPI
Util class to manage Reference Lists for Order Resource.
It manages 2 lists, one for source file to order the other for the destination Reference. It can also generate index files into the admin storage for source list or into any storage for destination list
Constructor Summary | |
---|---|
ListReferencesAPI(java.lang.String rootPath)
Default constructor |
Method Summary | |
---|---|
void |
addNoDuplicateSourceRef(java.util.Set<java.lang.String> noDuplicateUrlSet)
addNoDuplicateSourceRef |
void |
addNoDuplicateSourceRef(java.util.Set<java.lang.String> noDuplicateUrlSet,
java.lang.String selectionId)
addNoDuplicateSourceRef |
void |
addReferenceDest(org.restlet.data.Reference reference)
Add a reference to the index |
void |
addReferenceSource(org.restlet.data.Reference reference)
Add a reference to the index |
void |
clearReferencesDest()
Clear the reference destination list |
void |
clearReferencesSource()
Clear the reference source list |
org.restlet.data.Reference |
copyToAdminStorage(org.restlet.Context context,
java.lang.String folderName,
java.lang.String fileName,
org.restlet.data.ClientInfo clientInfo)
Copy the list of Reference Source to the admin storage ( root url is given by the function OrderResourceUtils.getResourceOrderStorageUrl(context)) with the specified. |
org.restlet.data.Reference |
copyToUserStorage(org.restlet.data.Reference rootRef,
org.restlet.Context context,
org.restlet.data.ClientInfo clientInfo)
Copy the list of Reference destination to the given rootRef Reference |
java.util.List<org.restlet.data.Reference> |
getReferencesDest()
Get the list of Reference in the index |
java.util.List<org.restlet.data.Reference> |
getReferencesSource()
Get the list of Reference in the index |
java.util.Map<org.restlet.data.Reference,java.lang.String> |
getRefSourceTarget()
Get the source reference target map |
void |
setRefSourceTarget(java.util.Map<org.restlet.data.Reference,java.lang.String> refSourceTarget)
Set the reference sourcre target map |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ListReferencesAPI(java.lang.String rootPath)
rootPath
- the root URL String added before each Reference in the index file. If the URLs are absolute set it to nullMethod Detail |
---|
public void clearReferencesSource()
public void clearReferencesDest()
public void addReferenceSource(org.restlet.data.Reference reference)
reference
- the reference to addpublic java.util.List<org.restlet.data.Reference> getReferencesSource()
public void addReferenceDest(org.restlet.data.Reference reference)
reference
- the reference to addpublic java.util.List<org.restlet.data.Reference> getReferencesDest()
public java.util.Map<org.restlet.data.Reference,java.lang.String> getRefSourceTarget()
public void setRefSourceTarget(java.util.Map<org.restlet.data.Reference,java.lang.String> refSourceTarget)
refSourceTarget
- public org.restlet.data.Reference copyToUserStorage(org.restlet.data.Reference rootRef, org.restlet.Context context, org.restlet.data.ClientInfo clientInfo) throws SitoolsException, java.io.IOException
Reference
rootRef
- the destination Reference
context
- the Context
clientInfo
- the ClientInfo
Reference
to the newly created file
SitoolsException
- if there is an error while copying the file to the file system
java.io.IOException
- if there is an error while creating the filepublic org.restlet.data.Reference copyToAdminStorage(org.restlet.Context context, java.lang.String folderName, java.lang.String fileName, org.restlet.data.ClientInfo clientInfo) throws SitoolsException, java.io.IOException
context
- the ContextfolderName
- the name of the folder where to create the filefileName
- the name of the fileclientInfo
- the clientInfo
Reference
to the newly created file
SitoolsException
- if there is an error while add the file to the file system
java.io.IOException
- if there is an error while creating the filepublic void addNoDuplicateSourceRef(java.util.Set<java.lang.String> noDuplicateUrlSet)
noDuplicateUrlSet
- public void addNoDuplicateSourceRef(java.util.Set<java.lang.String> noDuplicateUrlSet, java.lang.String selectionId)
noDuplicateUrlSet
- selectionId
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |