Interface IShareDocumentService

All Known Implementing Classes:
ShareDocumentService

public interface IShareDocumentService
Created by The eXo Platform SAS Author : eXoPlatform exo@exoplatform.com Nov 27, 2014
  • Method Details

    • publishDocumentToSpace

      String publishDocumentToSpace(String space, javax.jcr.Node node, String comment, String perm)
      Share a document to a space, permission of space's user also apply to this document.

      There is a symbolic link of origin document will create at Documents/Shared folder of destination space.

      Parameters:
      space - destination space will share file in
      node - file will be shared
      comment - message attach with share activity
      perm - permission of destination space's member on origin node
      Returns:
      return false if have issue
    • publishDocumentToSpace

      String publishDocumentToSpace(String space, javax.jcr.Node node, String comment, String perm, Boolean postActivity)
      Share a document to a space, permission of space's user also apply to this document.

      There is a symbolic link of origin document will create at Documents/Shared folder of destination space.

      Parameters:
      space - destination space will share file in
      node - file will be shared
      comment - message attach with share activity
      perm - permission of destination space's member on origin node
      postActivity - define post activity after sharing to a space or not
      Returns:
      return false if have issue
    • publishDocumentToUser

      void publishDocumentToUser(String user, javax.jcr.Node node, String comment, String perm)
      Share a document to a user

      There is a symbolic link of origin document will be created at Private/Documents/Shared folder of destination user.

      Parameters:
      user - destination user to share file with
      node - file will be shared
      comment - message attach with share activity
      perm - permission of destination space's member on origin node
    • unpublishDocumentToUser

      void unpublishDocumentToUser(String username, org.exoplatform.services.jcr.core.ExtendedNode node)
      Unshare a document to a user

      The symbolic link of origin document will be removed from Private/Documents/Shared folder of destination user.

      Parameters:
      username - destination user to share file with
      node - file will be shared
    • unpublishDocumentToSpace

      void unpublishDocumentToSpace(String space, org.exoplatform.services.jcr.core.ExtendedNode node)
      Unshare a document to a space

      The symbolic link of origin document will be removed from Documents/Shared folder of destination space.

      Parameters:
      space - destination user to share file with
      node - file will be shared
    • shareDocumentActivityToSpace

      void shareDocumentActivityToSpace(org.exoplatform.social.core.activity.model.ExoSocialActivity sharedActivity) throws Exception
      Share documents of an activity to a space
      Parameters:
      sharedActivity - shared activity
      Throws:
      Exception - when an error occurred while sharing document to space