com.liferay.portlet.wiki.util
Class WikiUtil
java.lang.Object
com.liferay.portlet.wiki.util.WikiUtil
public class WikiUtil
- extends Object
|
Method Summary |
static String |
convert(WikiPage page,
PortletURL viewPageURL,
PortletURL editPageURL,
String attachmentURLPrefix)
|
static String |
diffHtml(WikiPage sourcePage,
WikiPage targetPage,
PortletURL viewPageURL,
PortletURL editPageURL,
String attachmentURLPrefix)
|
static String |
escapeName(String name)
|
static List<WikiPage> |
filterOrphans(List<WikiPage> pages)
|
static String |
getAttachmentURLPrefix(String mainPath,
long plid,
long nodeId,
String title)
|
static DiffVersionsInfo |
getDiffVersionsInfo(long nodeId,
String title,
double sourceVersion,
double targetVersion,
javax.servlet.http.HttpServletRequest request)
|
static String |
getEditPage(String format)
|
static Map<String,String> |
getEmailFromDefinitionTerms(RenderRequest request)
|
static Map<String,String> |
getEmailNotificationDefinitionTerms(RenderRequest request,
String emailFromAddress,
String emailFromName)
|
static List<Object> |
getEntries(Hits hits)
|
static WikiNode |
getFirstNode(PortletRequest portletRequest)
|
static String |
getFormattedContent(RenderRequest renderRequest,
RenderResponse renderResponse,
WikiPage wikiPage,
PortletURL viewPageURL,
PortletURL editPageURL,
String title,
boolean preview)
|
static String |
getHelpPage(String format)
|
static String |
getHelpURL(String format)
|
static Map<String,Boolean> |
getLinks(WikiPage page)
|
static List<String> |
getNodeNames(List<WikiNode> nodes)
|
static List<WikiNode> |
getNodes(List<WikiNode> nodes,
String[] hiddenNodes,
PermissionChecker permissionChecker)
|
static OrderByComparator<WikiPage> |
getPageOrderByComparator(String orderByCol,
String orderByType)
|
static List<WikiNode> |
orderNodes(List<WikiNode> nodes,
String[] visibleNodeNames)
|
static String |
processContent(String content)
|
static String |
unescapeName(String name)
|
static boolean |
validate(long nodeId,
String content,
String format)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WikiUtil
public WikiUtil()
convert
public static String convert(WikiPage page,
PortletURL viewPageURL,
PortletURL editPageURL,
String attachmentURLPrefix)
throws PageContentException,
WikiFormatException
- Throws:
PageContentException
WikiFormatException
diffHtml
public static String diffHtml(WikiPage sourcePage,
WikiPage targetPage,
PortletURL viewPageURL,
PortletURL editPageURL,
String attachmentURLPrefix)
throws Exception
- Throws:
Exception
escapeName
public static String escapeName(String name)
filterOrphans
public static List<WikiPage> filterOrphans(List<WikiPage> pages)
throws PortalException
- Throws:
PortalException
getAttachmentURLPrefix
public static String getAttachmentURLPrefix(String mainPath,
long plid,
long nodeId,
String title)
getDiffVersionsInfo
public static DiffVersionsInfo getDiffVersionsInfo(long nodeId,
String title,
double sourceVersion,
double targetVersion,
javax.servlet.http.HttpServletRequest request)
getEditPage
public static String getEditPage(String format)
getEmailFromDefinitionTerms
public static Map<String,String> getEmailFromDefinitionTerms(RenderRequest request)
getEmailNotificationDefinitionTerms
public static Map<String,String> getEmailNotificationDefinitionTerms(RenderRequest request,
String emailFromAddress,
String emailFromName)
getEntries
public static List<Object> getEntries(Hits hits)
getFirstNode
public static WikiNode getFirstNode(PortletRequest portletRequest)
throws PortalException
- Throws:
PortalException
getFormattedContent
public static String getFormattedContent(RenderRequest renderRequest,
RenderResponse renderResponse,
WikiPage wikiPage,
PortletURL viewPageURL,
PortletURL editPageURL,
String title,
boolean preview)
throws Exception
- Throws:
Exception
getHelpPage
public static String getHelpPage(String format)
getHelpURL
public static String getHelpURL(String format)
getLinks
public static Map<String,Boolean> getLinks(WikiPage page)
throws PageContentException
- Throws:
PageContentException
getNodeNames
public static List<String> getNodeNames(List<WikiNode> nodes)
getNodes
public static List<WikiNode> getNodes(List<WikiNode> nodes,
String[] hiddenNodes,
PermissionChecker permissionChecker)
getPageOrderByComparator
public static OrderByComparator<WikiPage> getPageOrderByComparator(String orderByCol,
String orderByType)
orderNodes
public static List<WikiNode> orderNodes(List<WikiNode> nodes,
String[] visibleNodeNames)
processContent
public static String processContent(String content)
unescapeName
public static String unescapeName(String name)
validate
public static boolean validate(long nodeId,
String content,
String format)
throws WikiFormatException
- Throws:
WikiFormatException