org.alfresco.repo.googledocs
Interface GoogleDocsService

All Known Implementing Classes:
GoogleDocsServiceImpl

public interface GoogleDocsService

Google docs integration service interface


Method Summary
 void createGoogleDoc(org.alfresco.service.cmr.repository.NodeRef nodeRef, GoogleDocsPermissionContext permissionContext)
          Create a google doc from a given node.
 void deleteGoogleResource(org.alfresco.service.cmr.repository.NodeRef nodeRef)
          Deletes the google resource associated with the node reference.
 java.io.InputStream getGoogleDocContent(org.alfresco.service.cmr.repository.NodeRef nodeRef)
          Gets the content as an input stream of google doc associated with the given node.
 void initialise()
          Initialises the googles doc service, checking the provided credentials are correct.
 

Method Detail

initialise

void initialise()
                throws GoogleDocsServiceInitException
Initialises the googles doc service, checking the provided credentials are correct. This need not be called manually since other service calls will initialise the service on demand, but it can be helpful to know the "health" of the service up front.

Throws:
GoogleDocsServiceInitException

createGoogleDoc

void createGoogleDoc(org.alfresco.service.cmr.repository.NodeRef nodeRef,
                     GoogleDocsPermissionContext permissionContext)
Create a google doc from a given node. The content of the node will be used as a basis of the associated google doc. If the node has no content a new, empty google doc of the correct type will be created. The permission context provides information about how google sharing permissions should be set on the created google doc.

Parameters:
nodeRef - node reference
permissionContext - permission context

deleteGoogleResource

void deleteGoogleResource(org.alfresco.service.cmr.repository.NodeRef nodeRef)
Deletes the google resource associated with the node reference. This could be a folder or document.

Parameters:
nodeRef - node reference

getGoogleDocContent

java.io.InputStream getGoogleDocContent(org.alfresco.service.cmr.repository.NodeRef nodeRef)
Gets the content as an input stream of google doc associated with the given node. The node must have the google resource aspect and the associated resource should not be a folder.

Parameters:
nodeRef - node reference
Returns:
InputStream the content of the associated google doc


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.