org.gcube.portlets.user.homelibrary.home.workspace.basket
Interface Basket

All Superinterfaces:
WorkspaceAreaItem, WorkspaceFolder

public interface Basket
extends WorkspaceFolder

Author:
Federico De Faveri defaveri@isti.cnr.it

Method Summary
 Annotation createAnnotationItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.util.Map<java.lang.String,java.lang.String> data)
          Create a new annotation into this basket.
 Document createDocumentItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.lang.String mimeType, java.io.InputStream documentData, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName)
          Create a new document into this basket.
 DocumentLink createDocumentLinkItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName, java.lang.String mimeType)
          Create a new document link into this basket.
 ExternalFile createExternalFileItem(java.lang.String name, java.lang.String description, java.lang.String mimeType, java.io.InputStream fileData)
          Create an External File into this basket.
 ExternalImage createExternalImageItem(java.lang.String name, java.lang.String description, java.lang.String mimeType, java.io.InputStream imageData)
          Create a new External Image into this basket.
 ExternalPDFFile createExternalPDFFileItem(java.lang.String name, java.lang.String description, java.lang.String mimeType, java.io.InputStream fileData)
          Create a new External PDF file into this basket.
 ExternalUrl createExternalUrlItem(java.lang.String name, java.lang.String description, java.io.InputStream url)
          Create an External Url into this basket.
 ExternalUrl createExternalUrlItem(java.lang.String name, java.lang.String description, java.lang.String url)
          Create an External Url into this basket.
 ImageDocument createImageDocumentItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.lang.String mimeType, java.io.InputStream imageData, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName)
          Create a new image document into this basket.
 ImageDocumentLink createImageDocumentLinkItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName, java.lang.String mimeType)
          Create a new image document link into this basket.
 Metadata createMetadataItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.lang.String schema, java.lang.String language, java.lang.String metadata, java.lang.String collectionName)
          Create a new Metadata into this basket.
 PDFDocument createPDFDocumentItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.lang.String mimeType, java.io.InputStream data, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName)
          Create a new PDF document.
 PDFDocumentLink createPDFDocumentLinkItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName, java.lang.String mimeType)
          Create a new PDF document link.
 Query createQueryItem(java.lang.String name, java.lang.String description, java.io.InputStream query, QueryType queryType)
          Create a new Query into this basket.
 Query createQueryItem(java.lang.String name, java.lang.String description, java.lang.String query, QueryType queryType)
          Create a new Query into this basket.
 Report createReportItem(java.lang.String name, java.lang.String description, java.io.InputStream reportData)
          Create a Report into this basket.
 ReportTemplate createReportTemplateItem(java.lang.String name, java.lang.String description, java.io.InputStream templateData)
          Create a Report Template into this basket.
 UrlDocument createUrlDocumentItem(java.lang.String name, java.lang.String description, java.lang.String oid, java.lang.String mimeType, java.io.InputStream documentData, java.util.Map<java.lang.String,java.lang.String> metadata, java.util.Map<java.lang.String,java.lang.String> annotations, java.lang.String collectionName)
          Create a new url document into this basket.
 java.util.List<BasketItem> getChildren()
          Return this item children.
 BasketBulkCreator getNewBasketBulkCreator()
          Create a new BasketBulkCreator for this basket.
 
Methods inherited from interface org.gcube.portlets.user.homelibrary.home.workspace.WorkspaceFolder
exists, find, getParent, listFolders
 
Methods inherited from interface org.gcube.portlets.user.homelibrary.home.workspace.WorkspaceAreaItem
cloneItem, getCapabilities, getCreationTime, getDescription, getId, getLastAction, getLastModificationTime, getName, getOwner, getPath, getProperties, getType, isRoot, move, remove, removeChild, rename, setDescription
 

Method Detail

getChildren

java.util.List<BasketItem> getChildren()
                                       throws InternalErrorException
Return this item children.

Specified by:
getChildren in interface WorkspaceAreaItem
Returns:
the children.
Throws:
InternalErrorException - if an internal error occurs.

createExternalImageItem

ExternalImage createExternalImageItem(java.lang.String name,
                                      java.lang.String description,
                                      java.lang.String mimeType,
                                      java.io.InputStream imageData)
                                      throws InsufficientPrivilegesException,
                                             InternalErrorException,
                                             ItemAlreadyExistException
Create a new External Image into this basket.

Parameters:
name - the external image name.
description - the external image description.
mimeType - the external image mime type.
imageData - the external image data.
Returns:
the new external image.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createExternalFileItem

ExternalFile createExternalFileItem(java.lang.String name,
                                    java.lang.String description,
                                    java.lang.String mimeType,
                                    java.io.InputStream fileData)
                                    throws InsufficientPrivilegesException,
                                           InternalErrorException,
                                           ItemAlreadyExistException
Create an External File into this basket.

Parameters:
name - the external file name.
description - the external file description.
mimeType - the external file mime type.
fileData - the external file data.
Returns:
the new external file.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createExternalPDFFileItem

ExternalPDFFile createExternalPDFFileItem(java.lang.String name,
                                          java.lang.String description,
                                          java.lang.String mimeType,
                                          java.io.InputStream fileData)
                                          throws InsufficientPrivilegesException,
                                                 InternalErrorException,
                                                 ItemAlreadyExistException
Create a new External PDF file into this basket.

Parameters:
name - the external PDF name.
description - the external PDF description.
mimeType - the external PDF mime type.
fileData - the external PDF data.
Returns:
the new external PDF.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createExternalUrlItem

ExternalUrl createExternalUrlItem(java.lang.String name,
                                  java.lang.String description,
                                  java.lang.String url)
                                  throws InsufficientPrivilegesException,
                                         InternalErrorException,
                                         ItemAlreadyExistException
Create an External Url into this basket.

Parameters:
name - the external url name.
description - the external url description.
url - the url.
Returns:
the new url file.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createExternalUrlItem

ExternalUrl createExternalUrlItem(java.lang.String name,
                                  java.lang.String description,
                                  java.io.InputStream url)
                                  throws InsufficientPrivilegesException,
                                         InternalErrorException,
                                         ItemAlreadyExistException
Create an External Url into this basket.

Parameters:
name - the external url name.
description - the external url description.
url - the url.
Returns:
the new url file.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createReportTemplateItem

ReportTemplate createReportTemplateItem(java.lang.String name,
                                        java.lang.String description,
                                        java.io.InputStream templateData)
                                        throws InsufficientPrivilegesException,
                                               InternalErrorException,
                                               ItemAlreadyExistException
Create a Report Template into this basket.

Parameters:
name - the template name.
description - the template description.
templateData - the template data.
Returns:
the template.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createReportItem

Report createReportItem(java.lang.String name,
                        java.lang.String description,
                        java.io.InputStream reportData)
                        throws InsufficientPrivilegesException,
                               InternalErrorException,
                               ItemAlreadyExistException
Create a Report into this basket.

Parameters:
name - the report name.
description - the report description.
reportData - the report data.
Returns:
the report.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createQueryItem

Query createQueryItem(java.lang.String name,
                      java.lang.String description,
                      java.lang.String query,
                      QueryType queryType)
                      throws InsufficientPrivilegesException,
                             InternalErrorException,
                             ItemAlreadyExistException
Create a new Query into this basket.

Parameters:
name - the query name.
description - the query description.
query - the query.
queryType - the query type.
Returns:
the new query.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createQueryItem

Query createQueryItem(java.lang.String name,
                      java.lang.String description,
                      java.io.InputStream query,
                      QueryType queryType)
                      throws InsufficientPrivilegesException,
                             InternalErrorException,
                             ItemAlreadyExistException
Create a new Query into this basket.

Parameters:
name - the query name.
description - the query description.
query - the query.
queryType - the query type.
Returns:
the new query.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createAnnotationItem

Annotation createAnnotationItem(java.lang.String name,
                                java.lang.String description,
                                java.lang.String oid,
                                java.util.Map<java.lang.String,java.lang.String> data)
                                throws InsufficientPrivilegesException,
                                       InternalErrorException,
                                       ItemAlreadyExistException
Create a new annotation into this basket.

Parameters:
name - the annotation name.
description - the annotation description.
oid - the oid of the object where the annotation come from.
data - the annotation data.
Returns:
the new annotation.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createMetadataItem

Metadata createMetadataItem(java.lang.String name,
                            java.lang.String description,
                            java.lang.String oid,
                            java.lang.String schema,
                            java.lang.String language,
                            java.lang.String metadata,
                            java.lang.String collectionName)
                            throws InsufficientPrivilegesException,
                                   InternalErrorException,
                                   ItemAlreadyExistException
Create a new Metadata into this basket.

Parameters:
name - the metadata name.
description - the metadata description.
oid - the oid of the object where the metadata come from.
schema - the metadata schema.
language - the metadata language.
data - the metadata data.
collectionName - the metadata referred object collection name.
Returns:
the new metadata.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createDocumentItem

Document createDocumentItem(java.lang.String name,
                            java.lang.String description,
                            java.lang.String oid,
                            java.lang.String mimeType,
                            java.io.InputStream documentData,
                            java.util.Map<java.lang.String,java.lang.String> metadata,
                            java.util.Map<java.lang.String,java.lang.String> annotations,
                            java.lang.String collectionName)
                            throws InsufficientPrivilegesException,
                                   InternalErrorException,
                                   ItemAlreadyExistException
Create a new document into this basket.

Parameters:
name - the document name.
description - the document description.
oid - the document oid.
mimeType - the document mime type.
documentData - the document data.
metadata - the document metadata.
annotations - the document annotations.
collectionName - the document collection name.
Returns:
the new document.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createImageDocumentItem

ImageDocument createImageDocumentItem(java.lang.String name,
                                      java.lang.String description,
                                      java.lang.String oid,
                                      java.lang.String mimeType,
                                      java.io.InputStream imageData,
                                      java.util.Map<java.lang.String,java.lang.String> metadata,
                                      java.util.Map<java.lang.String,java.lang.String> annotations,
                                      java.lang.String collectionName)
                                      throws InsufficientPrivilegesException,
                                             InternalErrorException,
                                             ItemAlreadyExistException
Create a new image document into this basket.

Parameters:
name - the document image name.
description - the document image description.
oid - the document image oid.
mimeType - the image document mime type.
imageData - the document image data.
metadata - the document image metadata.
annotations - the document image annotations.
collectionName - the document image collection name.
Returns:
the new document image.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createPDFDocumentItem

PDFDocument createPDFDocumentItem(java.lang.String name,
                                  java.lang.String description,
                                  java.lang.String oid,
                                  java.lang.String mimeType,
                                  java.io.InputStream data,
                                  java.util.Map<java.lang.String,java.lang.String> metadata,
                                  java.util.Map<java.lang.String,java.lang.String> annotations,
                                  java.lang.String collectionName)
                                  throws InsufficientPrivilegesException,
                                         InternalErrorException,
                                         ItemAlreadyExistException
Create a new PDF document.

Parameters:
name - the PDF document name.
description - the document PDF description.
oid - the document PDF oid.
mimeType - the document PDF mime type.
data - the document PDF data.
metadata - the document PDF metadata.
annotations - the document PDF annotations.
collectionName - the document collection name.
Returns:
the new PDF document.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createUrlDocumentItem

UrlDocument createUrlDocumentItem(java.lang.String name,
                                  java.lang.String description,
                                  java.lang.String oid,
                                  java.lang.String mimeType,
                                  java.io.InputStream documentData,
                                  java.util.Map<java.lang.String,java.lang.String> metadata,
                                  java.util.Map<java.lang.String,java.lang.String> annotations,
                                  java.lang.String collectionName)
                                  throws InsufficientPrivilegesException,
                                         InternalErrorException,
                                         ItemAlreadyExistException
Create a new url document into this basket.

Parameters:
name - the document name.
description - the document description.
oid - the document oid.
mimeType - the document mimeType.
documentData - the document data.
metadata - the document metadata.
annotations - the document annotations.
collectionName - the document collection name.
Returns:
the new document.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createDocumentLinkItem

DocumentLink createDocumentLinkItem(java.lang.String name,
                                    java.lang.String description,
                                    java.lang.String oid,
                                    java.util.Map<java.lang.String,java.lang.String> metadata,
                                    java.util.Map<java.lang.String,java.lang.String> annotations,
                                    java.lang.String collectionName,
                                    java.lang.String mimeType)
                                    throws InsufficientPrivilegesException,
                                           InternalErrorException,
                                           ItemAlreadyExistException
Create a new document link into this basket.

Parameters:
name - the document name.
description - the document description.
oid - the document oid.
metadata - the document metadata.
annotations - the document annotations.
collectionName - the document collection name.
mimeType - the document mimeType.
Returns:
the new document.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createImageDocumentLinkItem

ImageDocumentLink createImageDocumentLinkItem(java.lang.String name,
                                              java.lang.String description,
                                              java.lang.String oid,
                                              java.util.Map<java.lang.String,java.lang.String> metadata,
                                              java.util.Map<java.lang.String,java.lang.String> annotations,
                                              java.lang.String collectionName,
                                              java.lang.String mimeType)
                                              throws InsufficientPrivilegesException,
                                                     InternalErrorException,
                                                     ItemAlreadyExistException
Create a new image document link into this basket.

Parameters:
name - the document image name.
description - the document image description.
oid - the document image oid.
metadata - the document image metadata.
annotations - the document image annotations.
collectionName - the document image collection name.
mimeType - the image document mimeType.
Returns:
the new document image.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

createPDFDocumentLinkItem

PDFDocumentLink createPDFDocumentLinkItem(java.lang.String name,
                                          java.lang.String description,
                                          java.lang.String oid,
                                          java.util.Map<java.lang.String,java.lang.String> metadata,
                                          java.util.Map<java.lang.String,java.lang.String> annotations,
                                          java.lang.String collectionName,
                                          java.lang.String mimeType)
                                          throws InsufficientPrivilegesException,
                                                 InternalErrorException,
                                                 ItemAlreadyExistException
Create a new PDF document link.

Parameters:
name - the pdf document name.
description - the document pdf description.
oid - the document pdf oid.
metadata - the document pdf metadata.
annotations - the document pdf annotations.
collectionName - the document collection name.
mimeType - the pdf document mimeType.
Returns:
the new pdf document.
Throws:
InsufficientPrivilegesException - if the user don't have sufficient privileges to perform this operation.
InternalErrorException - if an internal error occurs.
ItemAlreadyExistException - if an item with the specified name already exists.

getNewBasketBulkCreator

BasketBulkCreator getNewBasketBulkCreator()
                                          throws InternalErrorException
Create a new BasketBulkCreator for this basket.

Returns:
the new BasketBulkCreator.
Throws:
InternalErrorException - if an internal error occurs.