package org.gcube.portlets.user.workspace.client.rpc; import java.util.ArrayList; import java.util.Date; import java.util.List; import org.gcube.portlets.user.workspace.client.model.BulkCreatorModel; import org.gcube.portlets.user.workspace.client.model.FileDetailsModel; import org.gcube.portlets.user.workspace.client.model.FileGridModel; import org.gcube.portlets.user.workspace.client.model.FileModel; import org.gcube.portlets.user.workspace.client.model.FolderModel; import org.gcube.portlets.user.workspace.client.model.InfoContactModel; import org.gcube.portlets.user.workspace.client.model.MessageModel; import org.gcube.portlets.user.workspace.client.model.ScopeModel; import org.gcube.portlets.user.workspace.client.model.SmartFolderModel; import org.gcube.portlets.user.workspace.client.model.SubTree; import org.gcube.portlets.user.workspace.client.workspace.GWTWorkspaceItem; import org.gcube.portlets.user.workspace.shared.SessionExpiredException; import org.gcube.portlets.user.workspace.shared.WorkspaceACL; import org.gcube.portlets.user.workspace.shared.accounting.GxtAccountingField; import com.google.gwt.user.client.rpc.RemoteService; import com.google.gwt.user.client.rpc.RemoteServiceRelativePath; @RemoteServiceRelativePath("WorkspaceService") public interface GWTWorkspaceService extends RemoteService{ /** SendToRequest **/ public FolderModel getRootForTree() throws Exception; public FolderModel getRootForTree(String scopeId) throws Exception; public List getAllScope() throws Exception; public List getFolderChildren(FolderModel folder) throws Exception, SessionExpiredException; public List getFolderChildrenForFileGrid(FileModel folder) throws Exception, SessionExpiredException; public FileDetailsModel getDetailsFile(FileModel item) throws Exception; public FolderModel createFolder(String nameFolder, String description, FileModel parent) throws Exception; public ArrayList getChildrenSubTreeToRootByIdentifier(String itemIdentifier) throws Exception; public List getSmartFolderResultsByCategory(String category) throws Exception; public SmartFolderModel createSmartFolder(String name, String description, String query) throws Exception; public List getSmartFolderResultsById(String folderId) throws Exception; public List getAllSmartFolders() throws Exception; public GWTWorkspaceItem getImageById(String identifier, boolean isInteralImage, boolean fullDetails) throws Exception; public GWTWorkspaceItem getUrlById(String identifier, boolean isInternalUrl, boolean fullDetails) throws Exception; public FileModel createExternalUrl(FileModel parentFileModel, String name, String description, String url) throws Exception; public void setValueInSession(String name, String value) throws Exception; public List getItemsBySearchName(String text) throws Exception; public Boolean moveItem(String itemId, String destinationId) throws Exception; public Boolean removeItem(String itemId) throws Exception; public Boolean renameItem(String itemId, String newName, String oldName) throws Exception; public Boolean removeSmartFolder(String itemId, String name) throws Exception; public List getAllContacts() throws Exception; public String getUrlWebDav(String itemId) throws Exception; // public boolean sendTo(List listContacts, List listAttachments, String subject, String text) throws Exception; public boolean sentToByMessageModel(MessageModel message) throws Exception; public boolean sendToById(List listContactsId, List listAttachmentsId, String subject, String text) throws Exception; public List getAllMessagesReceived() throws Exception; public List getNewMessagesReceived() throws Exception; public List getAllMessagesSent() throws Exception; public List searchInSentMessagesByText(String text) throws Exception; public List searchInReceivedMessagesByText(String text) throws Exception; public MessageModel getMessageById(String messageIdentifier, String messageType) throws Exception; public boolean saveAttachments(String messageIdentifier, String messageType) throws Exception; public boolean saveAttach(String attachId) throws Exception; public boolean markMessage(String messageIdentifier, String messageType, boolean boolMark, String markType) throws Exception; public boolean deleteMessage(String messageIdentifier, String messageType) throws Exception; public boolean copyItem(String itemId, String destinationFolderId) throws Exception; public List getListFolderBulkCreator() throws Exception; public boolean deleteBulk(String bulkId) throws Exception; public GWTWorkspaceItem getTimeSeriesById(String identifier) throws Exception; boolean shareFolder(FileModel folder, List listContacts, boolean isNewFolder) throws Exception; public List getListUserSharedByFolderSharedId(String itemId) throws Exception; public boolean unSharedFolderByFolderSharedId(String folderSharedId) throws Exception; public List getListParentsByItemIdentifier(String itemIdentifier, boolean includeItemAsParent) throws Exception; public String getURLFromApplicationProfile(String oid) throws Exception; public InfoContactModel getOwnerByItemId(String itemId) throws Exception; public String itemExistsInWorkpaceFolder(String parentId, String itemName) throws Exception; public List getListUserSharedBySharedItem(String sharedItemId) throws Exception; public Date getItemCreationDateById(String itemId) throws Exception; public Long loadSizeByItemId(String itemId) throws Exception; public Date loadLastModificationDateById(String itemId) throws Exception; public FileModel getParentByItemId(String identifier) throws Exception; /** * @param identifier * @return * @throws Exception */ public List getAccountingReaders(String identifier) throws Exception; /** * @param identifier * @return * @throws Exception */ public List getAccountingHistory(String identifier) throws Exception; /** * @param itemId * @return * @throws Exception */ public FileGridModel getItemForFileGrid(String itemId) throws Exception; /** * @param folderId * @return * @throws Exception */ List getFolderChildrenForFileGridById(String folderId) throws Exception, SessionExpiredException; String getShortUrl(String longUrl) throws Exception; /** * @param itemId * @param shortenUrl * @return * @throws Exception */ String getPublicLinkForFolderItemId(String itemId, boolean shortenUrl) throws Exception; boolean isSessionExpired() throws Exception; void deleteListItemsForIds(List ids) throws Exception; /** * @param idsItem * @param destinationFolderId * @return * @throws Exception */ boolean copyItems(List idsItem, String destinationFolderId) throws Exception; /** * @param ids * @param destinationId * @return * @throws Exception */ Boolean moveItems(List ids, String destinationId) throws Exception; List getACLs() throws Exception; void setACLs(String folderId, List listLogins, String aclType) throws Exception; }