com.sap.netweaver.coll.wiki.api

Interface IWikiCommentManager


public interface IWikiCommentManager

Entry point for managing comments in the wiki application.


Method Summary
 IWikiComment createComment(long id, boolean isParentDocument, String body)
          Creates comment
 void deleteComment(long pageID, long commentID)
          Deletes comment
 IWikiComment getComment(long pageID, long commentID)
          Returns specific comment attached to page.
 Iterable<IWikiComment> getComments(long pageID)
          Returns comments attached to specific page.
 Iterable<String[]> getProperties(long commentID)
          Returns extended properties of comment
 String getProperty(long commentID, String name)
          Returns value of extended property of comment
 void setBody(long pageID, long commentID, String body)
          Sets body of comment
 Iterable<String[]> setProperties(long commentID, String[] names, String[] values)
          Sets extended properties of comment
 Iterable<String[]> setProperty(long commentID, String name, String value)
          Sets extended property of comment
 

Method Detail

getComments

Iterable<IWikiComment> getComments(long pageID)
                                   throws com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException
Returns comments attached to specific page.

Parameters:
pageID - unique identifier of page
Returns:
iterable of comments
Throws:
com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException

getComment

IWikiComment getComment(long pageID,
                        long commentID)
                        throws com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException,
                               com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Returns specific comment attached to page.

Parameters:
pageID - unique identifier of page
commentID - unique identifier of comment
Returns:
comment
Throws:
com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

getProperties

Iterable<String[]> getProperties(long commentID)
                                 throws com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Returns extended properties of comment

Parameters:
commentID - unique identifier of comment
Returns:
iterable of strings
Throws:
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

getProperty

String getProperty(long commentID,
                   String name)
                   throws com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Returns value of extended property of comment

Parameters:
commentID - unique identifier of comment
name - name of extended property
Returns:
value of extended property
Throws:
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

setProperties

Iterable<String[]> setProperties(long commentID,
                                 String[] names,
                                 String[] values)
                                 throws com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Sets extended properties of comment

Parameters:
commentID - unique identifier of comment
names - array of names of extended properties
values - array of corresponding values of extended properties
Returns:
set extended properties
Throws:
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

setProperty

Iterable<String[]> setProperty(long commentID,
                               String name,
                               String value)
                               throws com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Sets extended property of comment

Parameters:
commentID - unique identifier of comment
name - name of extended property
value - value of extended property
Returns:
property
Throws:
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

createComment

IWikiComment createComment(long id,
                           boolean isParentDocument,
                           String body)
                           throws com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException,
                                  com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException,
                                  com.sap.netweaver.coll.wiki.exception.WikiSpaceNotFoundException,
                                  com.sap.netweaver.coll.wiki.exception.RejectedException
Creates comment

Parameters:
id - unique identifier of page or comment
isParentDocument - if the comment is attached directly to page or to comment
body - the body of the comment
Returns:
the created comment
Throws:
com.sap.netweaver.coll.wiki.exception.WikiPageNotFoundException
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
com.sap.netweaver.coll.wiki.exception.WikiSpaceNotFoundException
com.sap.netweaver.coll.wiki.exception.RejectedException

deleteComment

void deleteComment(long pageID,
                   long commentID)
                   throws com.sap.netweaver.coll.wiki.exception.UnauthorizedException,
                          com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Deletes comment

Parameters:
pageID - unique identifier of page
commentID - unique identifier of comment
Throws:
com.sap.netweaver.coll.wiki.exception.UnauthorizedException
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException

setBody

void setBody(long pageID,
             long commentID,
             String body)
             throws com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Sets body of comment

Parameters:
pageID - unique identifier of page
commentID - unique identifier of comment
body -
Throws:
com.sap.netweaver.coll.wiki.exception.WikiCommentNotFoundException
Access Rights

This class can be accessed from:


SC DC Public Part ACH
[com.sap] KMC-WIKI [com.sap] com.sap.netweaver.coll.wiki.api api BC-COM-WIK


Copyright 2014 SAP AG Complete Copyright Notice