|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exoplatform.forum.common.CommonUtils
public class CommonUtils
| Field Summary | |
|---|---|
static String |
AMP
|
static String |
AMP_HEX
|
static String |
AMP_NUMBER
|
static String |
AMP_SPACE
|
static String |
COLON
|
static String |
COMMA
|
static String |
DOMAIN_KEY
|
static String |
EMPTY_STR
|
static String |
FROM_KEY
|
static String |
GREATER_THAN
|
static String |
LESS_THAN
|
static String |
QUOT
|
static String |
SEMICOLON
|
static String |
SLASH
|
static String |
SPACE
|
| Constructor Summary | |
|---|---|
CommonUtils()
|
|
| Method Summary | ||
|---|---|---|
static String |
convertCodeHTML(String s)
|
|
static org.exoplatform.services.jcr.ext.common.SessionProvider |
createSystemProvider()
|
|
static String |
decodeSpecialCharToHTMLnumber(String s)
|
|
static String |
decodeSpecialCharToHTMLnumber(String s,
List<String> lIgnore)
|
|
static String |
encodeSpecialCharInContent(String s)
Encode special character, use for input content of object (only apply for input by FCKEditer). |
|
static String |
encodeSpecialCharInSearchTerm(String s)
Encode special character, use for input search |
|
static String |
encodeSpecialCharInTitle(String s)
Encode special character, use for input title or name of the object. |
|
static String |
encodeSpecialCharToHTMLnumber(String s,
String charIgnore,
boolean isTitle)
Encode special character to html number. |
|
static String |
generateCheckSum(byte[] b)
|
|
static
|
getComponent(Class<T> type)
Get a Component from the current container context |
|
static String |
getDomainURL()
|
|
static org.exoplatform.container.ExoContainer |
getExoContainer(org.quartz.JobExecutionContext context)
|
|
static Calendar |
getGreenwichMeanTime()
Get current time GMT/Zulu or UTC,(zone time is 0+GMT) |
|
static String |
getImageUrl(String imagePath)
|
|
static String |
getRSSLink(String appType,
String portalName,
String objectId)
|
|
static String |
getUserRSSLink(String apptype,
String userId)
|
|
static File |
getXMLFile(ByteArrayOutputStream bos,
String appName,
String objectType,
Date createDate,
String fileName)
|
|
static boolean |
isEmpty(String s)
Check string is null or empty |
|
static boolean |
isEmpty(String[] array)
check string array is whether empty or not |
|
static String |
makeNotificationSender(String from)
This function will change email address in 'from' field by address of mail service which is configured as system property : gatein.email.smtp.from or
mail.from. |
|
static String |
processBBCode(String s)
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String COMMA
public static final String SLASH
public static final String EMPTY_STR
public static final String COLON
public static final String SEMICOLON
public static final String SPACE
public static final String AMP_NUMBER
public static final String LESS_THAN
public static final String GREATER_THAN
public static final String QUOT
public static final String AMP_SPACE
public static final String AMP_HEX
public static final String AMP
public static final String DOMAIN_KEY
public static final String FROM_KEY
| Constructor Detail |
|---|
public CommonUtils()
| Method Detail |
|---|
public static String generateCheckSum(byte[] b)
throws Exception
Exception
public static File getXMLFile(ByteArrayOutputStream bos,
String appName,
String objectType,
Date createDate,
String fileName)
throws Exception
Exception
public static String getImageUrl(String imagePath)
throws Exception
Exceptionpublic static String convertCodeHTML(String s)
public static String makeNotificationSender(String from)
gatein.email.smtp.from or
mail.from. from field of message from smtp authentication (for now, GMX, MS exchange deny, Gmail
efforts to modify the such value)
from -
public static String getDomainURL()
public static String processBBCode(String s)
public static <T> T getComponent(Class<T> type)
T - type of the expected componenttype - key for the component
public static org.exoplatform.container.ExoContainer getExoContainer(org.quartz.JobExecutionContext context)
public static String getRSSLink(String appType,
String portalName,
String objectId)
public static String getUserRSSLink(String apptype,
String userId)
public static boolean isEmpty(String s)
String - s
public static boolean isEmpty(String[] array)
array -
public static String encodeSpecialCharInSearchTerm(String s)
String - s, the string input
public static String encodeSpecialCharInTitle(String s)
String - s, the string input
public static String encodeSpecialCharInContent(String s)
String - s, the string input
public static String encodeSpecialCharToHTMLnumber(String s,
String charIgnore,
boolean isTitle)
String - s, the string inputString - charIgnore, the string content ignore some special character can not encode.boolean - isTitle, the boolean for check convert is title or not.
public static String decodeSpecialCharToHTMLnumber(String s,
List<String> lIgnore)
public static String decodeSpecialCharToHTMLnumber(String s)
public static Calendar getGreenwichMeanTime()
public static org.exoplatform.services.jcr.ext.common.SessionProvider createSystemProvider()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||