com.liferay.portlet.dynamicdatalists.util
Class DDLUtil
java.lang.Object
com.liferay.portlet.dynamicdatalists.util.DDLUtil
public class DDLUtil
- extends Object
Method Summary |
static void |
addAllReservedEls(Element rootElement,
Map<String,String> tokens,
DDLRecordSet recordSet)
|
static DDL |
getDDL()
|
static void |
getRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
DDLRecord record,
String fieldName)
|
static JSONObject |
getRecordJSONObject(DDLRecord record)
|
static JSONObject |
getRecordJSONObject(DDLRecord record,
boolean latestRecordVersion)
|
static JSONArray |
getRecordSetJSONArray(DDLRecordSet recordSet)
|
static JSONArray |
getRecordsJSONArray(List<DDLRecord> records)
|
static JSONArray |
getRecordsJSONArray(List<DDLRecord> records,
boolean latestRecordVersion)
|
static String |
getTemplateContent(long ddmTemplateId,
DDLRecordSet recordSet,
ThemeDisplay themeDisplay,
RenderRequest renderRequest,
RenderResponse renderResponse)
|
static boolean |
isEditable(javax.servlet.http.HttpServletRequest request,
String portletId,
long groupId)
|
static boolean |
isEditable(PortletPreferences preferences,
String portletId,
long groupId)
|
static void |
sendRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
DDLRecord record,
String fieldName)
|
static void |
sendRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
long recordId,
String fieldName)
|
void |
setDDL(DDL ddl)
|
static DDLRecord |
updateRecord(long recordId,
long recordSetId,
boolean mergeFields,
boolean checkPermission,
ServiceContext serviceContext)
|
static DDLRecord |
updateRecord(long recordId,
long recordSetId,
boolean mergeFields,
ServiceContext serviceContext)
|
static String |
uploadRecordFieldFile(DDLRecord record,
String fieldName,
ServiceContext serviceContext)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DDLUtil
public DDLUtil()
addAllReservedEls
public static void addAllReservedEls(Element rootElement,
Map<String,String> tokens,
DDLRecordSet recordSet)
getDDL
public static DDL getDDL()
getRecordFileUpload
public static void getRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
DDLRecord record,
String fieldName)
throws Exception
- Throws:
Exception
getRecordJSONObject
public static JSONObject getRecordJSONObject(DDLRecord record)
throws Exception
- Throws:
Exception
getRecordJSONObject
public static JSONObject getRecordJSONObject(DDLRecord record,
boolean latestRecordVersion)
throws Exception
- Throws:
Exception
getRecordSetJSONArray
public static JSONArray getRecordSetJSONArray(DDLRecordSet recordSet)
throws Exception
- Throws:
Exception
getRecordsJSONArray
public static JSONArray getRecordsJSONArray(List<DDLRecord> records)
throws Exception
- Throws:
Exception
getRecordsJSONArray
public static JSONArray getRecordsJSONArray(List<DDLRecord> records,
boolean latestRecordVersion)
throws Exception
- Throws:
Exception
getTemplateContent
public static String getTemplateContent(long ddmTemplateId,
DDLRecordSet recordSet,
ThemeDisplay themeDisplay,
RenderRequest renderRequest,
RenderResponse renderResponse)
throws Exception
- Throws:
Exception
isEditable
public static boolean isEditable(javax.servlet.http.HttpServletRequest request,
String portletId,
long groupId)
throws Exception
- Throws:
Exception
isEditable
public static boolean isEditable(PortletPreferences preferences,
String portletId,
long groupId)
throws Exception
- Throws:
Exception
sendRecordFileUpload
public static void sendRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
DDLRecord record,
String fieldName)
throws Exception
- Throws:
Exception
sendRecordFileUpload
public static void sendRecordFileUpload(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
long recordId,
String fieldName)
throws Exception
- Throws:
Exception
updateRecord
public static DDLRecord updateRecord(long recordId,
long recordSetId,
boolean mergeFields,
boolean checkPermission,
ServiceContext serviceContext)
throws Exception
- Throws:
Exception
updateRecord
public static DDLRecord updateRecord(long recordId,
long recordSetId,
boolean mergeFields,
ServiceContext serviceContext)
throws Exception
- Throws:
Exception
uploadRecordFieldFile
public static String uploadRecordFieldFile(DDLRecord record,
String fieldName,
ServiceContext serviceContext)
throws Exception
- Throws:
Exception
setDDL
public void setDDL(DDL ddl)