rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
long completedMessageUID; | long completedMessageUID = -1L; | public static long completeMessage( HttpSession ses, MailMessage mm, boolean send) throws Exception { String userId = (String)ses.getAttribute(WebKeys.USER_ID); String password = (String)ses.getAttribute(WebKeys.USER_PASSWORD); Email email = null; if (mm.isSimple()) { SimpleEmail se = new SimpleEmail(); se.... |
completedMessageUID = _getCurrentFolder(ses).getUID(sent[0]); | public static long completeMessage( HttpSession ses, MailMessage mm, boolean send) throws Exception { String userId = (String)ses.getAttribute(WebKeys.USER_ID); String password = (String)ses.getAttribute(WebKeys.USER_PASSWORD); Email email = null; if (mm.isSimple()) { SimpleEmail se = new SimpleEmail(); se.... | |
if (Validator.isNotNull(path)) { uuid = null; } else if (Validator.isNotNull(uuid)) { path = null; } else { return null; } | public static String getContent( String userId, String password, String uuid, String path) throws Exception { try { AuthenticationUtils.startSession(userId, password); ContentServiceSoapBindingStub contentService = WebServiceFactory.getContentService(); if (Validator.isNotNull(path)) { uuid = null; }... | |
"@localhost:8080/tunnel/secure/axis/" + serviceName; | "@localhost:8080/tunnel-web/secure/axis/" + serviceName; | public URL getURL(String serviceName) throws Exception { // Unathenticated url String url = "http://localhost:8080/tunnel/axis/" + serviceName; // Authenticated url if (true) { String userId = "liferay.com.1"; String password = "qUqP5cyxm6YcTAhz05Hph5gvu9M="; url = "http://" + userId + ":" + password +... |
if (user.isNew() || user.isModified()) { session = openSession(); if (user.isNew()) { User userModel = new User(); userModel.setUserId(user.getUserId()); userModel.setCompanyId(user.getCompanyId()); userModel.setCreateDate(user.getCreateDate()); userModel.setModifiedDate(user.getModifiedDate()); userModel.setContactId... | session = openSession(); session.saveOrUpdate(user); session.flush(); user.setNew(false); | public com.liferay.portal.model.User update( com.liferay.portal.model.User user) throws SystemException { Session session = null; try { if (user.isNew() || user.isModified()) { session = openSession(); if (user.isNew()) { User userModel = new User(); userModel.setUserId(user.getUserId()); userMo... |
if (layout.isNew() || layout.isModified()) { session = openSession(); if (layout.isNew()) { Layout layoutModel = new Layout(); layoutModel.setLayoutId(layout.getLayoutId()); layoutModel.setOwnerId(layout.getOwnerId()); layoutModel.setCompanyId(layout.getCompanyId()); layoutModel.setParentLayoutId(layout.getParentLayou... | session = openSession(); session.saveOrUpdate(layout); session.flush(); layout.setNew(false); | public com.liferay.portal.model.Layout update( com.liferay.portal.model.Layout layout) throws SystemException { Session session = null; try { if (layout.isNew() || layout.isModified()) { session = openSession(); if (layout.isNew()) { Layout layoutModel = new Layout(); layoutModel.setLayoutId(layout.... |
HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int displayDateMonth, int displayDateDay, int displayDateYear, int displayDateHour, int d... | HttpPrincipal httpPrincipal, java.lang.String companyId, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int displayDateMonth, int displayDateDay, int displayDateYear... | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj0 = articleId; | Object paramObj0 = companyId; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
if (articleId == null) { | if (companyId == null) { | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj1 = new DoubleWrapper(version); Object paramObj2 = new BooleanWrapper(incrementVersion); Object paramObj3 = title; | Object paramObj1 = articleId; if (articleId == null) { paramObj1 = new NullWrapper("java.lang.String"); } Object paramObj2 = new DoubleWrapper(version); Object paramObj3 = new BooleanWrapper(incrementVersion); Object paramObj4 = title; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
paramObj3 = new NullWrapper("java.lang.String"); } Object paramObj4 = content; if (content == null) { | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... | |
Object paramObj5 = type; | Object paramObj5 = content; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
if (type == null) { | if (content == null) { | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj6 = structureId; | Object paramObj6 = type; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
if (structureId == null) { | if (type == null) { | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj7 = templateId; | Object paramObj7 = structureId; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
if (templateId == null) { | if (structureId == null) { | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj8 = new IntegerWrapper(displayDateMonth); Object paramObj9 = new IntegerWrapper(displayDateDay); Object paramObj10 = new IntegerWrapper(displayDateYear); Object paramObj11 = new IntegerWrapper(displayDateHour); Object paramObj12 = new IntegerWrapper(displayDateMinute); Object paramObj13 = new IntegerWrap... | Object paramObj8 = templateId; if (templateId == null) { paramObj8 = new NullWrapper("java.lang.String"); } Object paramObj9 = new IntegerWrapper(displayDateMonth); Object paramObj10 = new IntegerWrapper(displayDateDay); Object paramObj11 = new IntegerWrapper(displayDateYear); Object paramObj12 = new IntegerWrapper(d... | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
paramObj25 = new NullWrapper("java.util.Map"); | paramObj26 = new NullWrapper("java.util.Map"); | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj26 = articleURL; | Object paramObj27 = articleURL; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
paramObj26 = new NullWrapper("java.lang.String"); | paramObj27 = new NullWrapper("java.lang.String"); | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
Object paramObj27 = prefs; | Object paramObj28 = prefs; | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
paramObj27 = new NullWrapper("javax.portlet.PortletPreferences"); | paramObj28 = new NullWrapper("javax.portlet.PortletPreferences"); | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
paramObj26, paramObj27 | paramObj26, paramObj27, paramObj28 | public static com.liferay.portlet.journal.model.JournalArticle updateArticle( HttpPrincipal httpPrincipal, java.lang.String articleId, double version, boolean incrementVersion, java.lang.String title, java.lang.String content, java.lang.String type, java.lang.String structureId, java.lang.String templateId, int d... |
public List getPermissions(String[] actionIds, String resourceId) | public List getPermissions( String companyId, String[] actionIds, String resourceId) | public List getPermissions(String[] actionIds, String resourceId) throws PortalException, SystemException { List permissions = new ArrayList(); for (int i = 0; i < actionIds.length; i++) { Permission permission = PermissionUtil.findByA_R(actionIds[i], resourceId); permissions.add(permission); } return perm... |
Permission permission = PermissionUtil.findByA_R(actionIds[i], resourceId); | Permission permission = null; try { permission = PermissionUtil.findByA_R(actionIds[i], resourceId); } catch (NoSuchPermissionException nspe) { permission = addPermission(companyId, actionIds[i], resourceId); } | public List getPermissions(String[] actionIds, String resourceId) throws PortalException, SystemException { List permissions = new ArrayList(); for (int i = 0; i < actionIds.length; i++) { Permission permission = PermissionUtil.findByA_R(actionIds[i], resourceId); permissions.add(permission); } return perm... |
List permissions = getPermissions(actionIds, resourceId); | List permissions = getPermissions( group.getCompanyId(), actionIds, resourceId); | public void setGroupPermissions( String groupId, String[] actionIds, String resourceId) throws PortalException, SystemException { Iterator itr = PermissionFinder.findByG_R( groupId, resourceId).iterator(); while (itr.hasNext()) { Permission permission = (Permission)itr.next(); GroupUtil.removePermission(gro... |
itr = getPermissions(actionIds, resourceId).iterator(); | itr = getPermissions( organization.getCompanyId(), actionIds, resourceId).iterator(); | public void setOrgGroupPermissions( String organizationId, String groupId, String[] actionIds, String resourceId) throws PortalException, SystemException { Organization organization = OrganizationUtil.findByPrimaryKey(organizationId); String orgGroupId = organization.getGroup().getGroupId(); Iterator itr = P... |
Iterator itr = PermissionFinder.findByU_R( userId, resourceId).iterator(); | User user = UserUtil.findByPrimaryKey(userId); | public void setUserPermissions( String userId, String[] actionIds, String resourceId) throws PortalException, SystemException { Iterator itr = PermissionFinder.findByU_R( userId, resourceId).iterator(); while (itr.hasNext()) { Permission permission = (Permission)itr.next(); UserUtil.removePermission(userId,... |
while (itr.hasNext()) { Permission permission = (Permission)itr.next(); | List permissions = PermissionFinder.findByU_R(userId, resourceId); | public void setUserPermissions( String userId, String[] actionIds, String resourceId) throws PortalException, SystemException { Iterator itr = PermissionFinder.findByU_R( userId, resourceId).iterator(); while (itr.hasNext()) { Permission permission = (Permission)itr.next(); UserUtil.removePermission(userId,... |
UserUtil.removePermission(userId, permission); } | UserUtil.removePermissions(userId, permissions); | public void setUserPermissions( String userId, String[] actionIds, String resourceId) throws PortalException, SystemException { Iterator itr = PermissionFinder.findByU_R( userId, resourceId).iterator(); while (itr.hasNext()) { Permission permission = (Permission)itr.next(); UserUtil.removePermission(userId,... |
List permissions = getPermissions(actionIds, resourceId); | permissions = getPermissions( user.getCompanyId(), actionIds, resourceId); | public void setUserPermissions( String userId, String[] actionIds, String resourceId) throws PortalException, SystemException { Iterator itr = PermissionFinder.findByU_R( userId, resourceId).iterator(); while (itr.hasNext()) { Permission permission = (Permission)itr.next(); UserUtil.removePermission(userId,... |
java.lang.String companyId, java.lang.String name) throws RemoteException { | java.lang.String groupId) throws RemoteException { | public static com.liferay.portal.model.GroupModel getGroup( java.lang.String companyId, java.lang.String name) throws RemoteException { try { com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(companyId, name); return returnValue; } catch (Exception e) { String stackTrace = StackTrac... |
com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(companyId, name); | com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(groupId); | public static com.liferay.portal.model.GroupModel getGroup( java.lang.String companyId, java.lang.String name) throws RemoteException { try { com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(companyId, name); return returnValue; } catch (Exception e) { String stackTrace = StackTrac... |
value = getCreateDate().compareTo(mailReceipt.getCreateDate()); | value = DateUtil.compareTo(getCreateDate(), mailReceipt.getCreateDate()); | public int compareTo(Object obj) { if (obj == null) { return -1; } MailReceipt mailReceipt = (MailReceipt)obj; int value = 0; value = getCreateDate().compareTo(mailReceipt.getCreateDate()); value = value * -1; if (value != 0) { return value; } return 0; } |
String topicId = ParamUtil.getString(req, "topicId"); | protected void deleteMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.deleteMessage(topicId, messageId); } | |
MBMessageServiceUtil.deleteMessage(topicId, messageId); | MBMessageServiceUtil.deleteMessage(messageId); | protected void deleteMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.deleteMessage(topicId, messageId); } |
String topicId = ParamUtil.getString(req, "topicId"); | protected void subscribeMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.subscribeMessage(topicId, messageId); } | |
MBMessageServiceUtil.subscribeMessage(topicId, messageId); | MBMessageServiceUtil.subscribeMessage(messageId); | protected void subscribeMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.subscribeMessage(topicId, messageId); } |
String topicId = ParamUtil.getString(req, "topicId"); | protected void unsubscribeMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.unsubscribeMessage(topicId, messageId); } | |
MBMessageServiceUtil.unsubscribeMessage(topicId, messageId); | MBMessageServiceUtil.unsubscribeMessage(messageId); | protected void unsubscribeMessage(ActionRequest req) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); MBMessageServiceUtil.unsubscribeMessage(topicId, messageId); } |
String topicId = ParamUtil.getString(req, "topicId"); | protected void updateMessage(ActionRequest req, ActionResponse res) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); String categoryId = ParamUtil.getString(req, "categoryId"); String threadId = ParamUtil.getString(req, "threadId");... | |
topicId, messageId, categoryId, subject, body, files, | messageId, categoryId, subject, body, files, | protected void updateMessage(ActionRequest req, ActionResponse res) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); String categoryId = ParamUtil.getString(req, "categoryId"); String threadId = ParamUtil.getString(req, "threadId");... |
portletURL.setParameter("topicId", message.getTopicId()); | protected void updateMessage(ActionRequest req, ActionResponse res) throws Exception { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); String categoryId = ParamUtil.getString(req, "categoryId"); String threadId = ParamUtil.getString(req, "threadId");... | |
sb.append("\t<deployment-properties app-versioning=\"true\" delete-previous-versions=\"false\" forced-deployment=\"false\">\n"); sb.append("\t\t<jsp-files pre-compilation=\"true\" />\n"); sb.append("\t\t<ejb-files retain-generated-code=\"false\" />\n"); sb.append("\t\t<validation>\n"); sb.append("\t\t\t<app-validation ... | private void _buildPramatiXML() throws Exception { // pramati-j2ee-server.xml StringBuffer sb = new StringBuffer(); sb.append("<?xml version=\"1.0\"?>\n"); sb.append("<!DOCTYPE pramati-j2ee-server PUBLIC \"-//Pramati Technologies //DTD Pramati J2ee Server 3.5 SP5//EN\" \"http://www.pramati.com/dtd/pramati-j2ee-ser... | |
Iterator itr = doc.getRootElement().elements("ejb-local-ref").iterator(); | Iterator itr = doc.getRootElement().elements("ejb-ref").iterator(); while (itr.hasNext()) { Element ejbLocalRef = (Element)itr.next(); sb.append("\t\t<ejb-ref>\n"); sb.append("\t\t\t<ejb-ref-name>").append(ejbLocalRef.elementText("ejb-ref-name")).append("</ejb-ref-name>\n"); sb.append("\t\t\t<ejb-link>").append(ejbLo... | private String _buildPramatiXMLWebModule(String path) throws DocumentException, IOException { String contextRoot = path.substring(2, path.length() - 4); String filePath = path + "/docroot/WEB-INF/web.xml"; if (path.endsWith("portal-web")) { contextRoot = "/"; } StringBuffer sb = new StringBuffer(); sb.append(... |
if (shoppingItemPrice.isNew() || shoppingItemPrice.isModified()) { session = openSession(); if (shoppingItemPrice.isNew()) { ShoppingItemPrice shoppingItemPriceModel = new ShoppingItemPrice(); shoppingItemPriceModel.setItemPriceId(shoppingItemPrice.getItemPriceId()); shoppingItemPriceModel.setItemId(shoppingItemPrice.... | session = openSession(); session.saveOrUpdate(shoppingItemPrice); session.flush(); shoppingItemPrice.setNew(false); | public com.liferay.portlet.shopping.model.ShoppingItemPrice update( com.liferay.portlet.shopping.model.ShoppingItemPrice shoppingItemPrice) throws SystemException { Session session = null; try { if (shoppingItemPrice.isNew() || shoppingItemPrice.isModified()) { session = openSession(); if (shoppingItemPric... |
java.lang.String name, java.lang.String title, java.lang.String description) | java.lang.String newFolderId, java.lang.String name, java.lang.String sourceFileName, java.lang.String title, java.lang.String description, byte[] byteArray) | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
Object paramObj1 = name; | Object paramObj1 = newFolderId; | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
if (name == null) { | if (newFolderId == null) { | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
Object paramObj2 = title; | Object paramObj2 = name; | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
if (title == null) { | if (name == null) { | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
Object paramObj3 = description; | Object paramObj3 = sourceFileName; if (sourceFileName == null) { paramObj3 = new NullWrapper("java.lang.String"); } Object paramObj4 = title; if (title == null) { paramObj4 = new NullWrapper("java.lang.String"); } Object paramObj5 = description; | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
paramObj3 = new NullWrapper("java.lang.String"); | paramObj5 = new NullWrapper("java.lang.String"); } Object paramObj6 = byteArray; if (byteArray == null) { paramObj6 = new NullWrapper("[B"); | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 }); | new Object[] { paramObj0, paramObj1, paramObj2, paramObj3, paramObj4, paramObj5, paramObj6 }); | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( HttpPrincipal httpPrincipal, java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) throws com.liferay.portal.PortalException, java.rmi.RemoteException, com.liferay.portal.System... |
for (int i = 0; i < _EMOTICONS.length; i++) { String imgTag = "<img src='" + _EMOTICONS[i][0] + "' />"; html = StringUtil.replace(html, _EMOTICONS[i][1], imgTag); | for (int i = 0; i < EMOTICONS.length; i++) { String imgTag = "<img src='" + EMOTICONS[i][0] + "' />"; html = StringUtil.replace(html, EMOTICONS[i][1], imgTag); | public static String getHTML(String bbcode) { String html = StringUtil.replace(bbcode, _BBCODE_TAGS, _HTML_TAGS); for (int i = 0; i < _EMOTICONS.length; i++) { String imgTag = "<img src='" + _EMOTICONS[i][0] + "' />"; html = StringUtil.replace(html, _EMOTICONS[i][1], imgTag); } BBCodeTag tag = null; StringBuf... |
deleteCoupon(req); | deleteCoupons(req); | public void processAction( ActionMapping mapping, ActionForm form, PortletConfig config, ActionRequest req, ActionResponse res) throws Exception { String cmd = ParamUtil.getString(req, Constants.CMD); try { if (cmd.equals(Constants.ADD) || cmd.equals(Constants.UPDATE)) { updateCoupon(req); } else if (c... |
if (organization.isNew() || organization.isModified()) { session = openSession(); if (organization.isNew()) { Organization organizationModel = new Organization(); organizationModel.setOrganizationId(organization.getOrganizationId()); organizationModel.setCompanyId(organization.getCompanyId()); organizationModel.setPar... | session = openSession(); session.saveOrUpdate(organization); session.flush(); organization.setNew(false); | public com.liferay.portal.model.Organization update( com.liferay.portal.model.Organization organization) throws SystemException { Session session = null; try { if (organization.isNew() || organization.isModified()) { session = openSession(); if (organization.isNew()) { Organization organizationModel = ... |
setModified(true); | public void setItemFieldId(String itemFieldId) { if (((itemFieldId == null) && (_itemFieldId != null)) || ((itemFieldId != null) && (_itemFieldId == null)) || ((itemFieldId != null) && (_itemFieldId != null) && !itemFieldId.equals(_itemFieldId))) { if (!XSS_ALLOW_ITEMFIELDID) { itemFieldId = XSSUtil.str... | |
setModified(true); | public void setValues(String values) { if (((values == null) && (_values != null)) || ((values != null) && (_values == null)) || ((values != null) && (_values != null) && !values.equals(_values))) { if (!XSS_ALLOW_VALUES) { values = XSSUtil.strip(values); } _values = values; setModified(true); } ... | |
String companyId, String groupId, String userId, String name, String primKey, boolean portletActions, boolean addCommunityPermissions, boolean addGuestPermissions) | String companyId, String groupId, String name, boolean portletActions) | public void addResources( String companyId, String groupId, String userId, String name, String primKey, boolean portletActions, boolean addCommunityPermissions, boolean addGuestPermissions) throws PortalException, SystemException { validate(companyId, name, portletActions); // Company addResource( companyI... |
validate(companyId, name, portletActions); addResource( companyId, name, Resource.TYPE_CLASS, Resource.SCOPE_COMPANY, companyId); Group guestGroup = GroupLocalServiceUtil.getGroup( companyId, Group.GUEST); addResource( companyId, name, Resource.TYPE_CLASS, Resource.SCOPE_GROUP, guestGroup.getGroupId()); if (g... | addResources( companyId, groupId, null, name, null, portletActions, false, false); | public void addResources( String companyId, String groupId, String userId, String name, String primKey, boolean portletActions, boolean addCommunityPermissions, boolean addGuestPermissions) throws PortalException, SystemException { validate(companyId, name, portletActions); // Company addResource( companyI... |
if( script == null || !script.exists() || metadata == null ) return; try { if( metadata.toHeader().equals( getScriptMetadata( script ).toHeader() ) ) { new WorkspaceJob( "Refreshing markers for script: " + script.getName() ) { @Override public IStatus runInWorkspace( final IProgressMonitor monitor ) throws CoreExceptio... | refreshScriptMetadata( script, metadata, false ); | public static void refreshScriptMetadata( final IFile script, final ScriptMetadata metadata ) { if( script == null || !script.exists() || metadata == null ) return; try { if( metadata.toHeader().equals( getScriptMetadata( scr... |
if( metadata.header().equals( getScriptMetadata( script ).header() ) ) | if( !force && metadata.header().equals( getScriptMetadata( script ).header() ) ) | public IStatus runInWorkspace( final IProgressMonitor monitor ) throws CoreException { try { if( metadata.header().equals( getScriptMetadata( script ).header() ) ) return Status.OK_STATUS; setCo... |
m.setAttribute( PLUGIN_ID, "marker" ); m.setAttribute( PLUGIN_ID + ".tag", marker.tag().toString() ); | public static void setMarkers( final IFile script ) throws CoreException { if( script == null || !script.exists() ) return; try { script.deleteMarkers( IMarker.PROBLEM, true, DEPTH_INFINITE ); final ScriptMetadata metadata = getScriptMetadata( script ); ... | |
catch (NoSuchGroupException nsge) { _log.error( "Upgrade failed because data does not have a valid group id. " + "Manually assign a group id in the database."); } | private void _upgradeNode() throws Exception { Connection con = null; PreparedStatement ps = null; ResultSet rs = null; try { con = DataAccess.getConnection(Constants.DATA_SOURCE); ps = con.prepareStatement(_UPGRADE_NODE); ps.setString(1, Group.DEFAULT_PARENT_GROUP_ID); rs = ps.executeQuery(); while (rs.... | |
content = replaceIsNull(content); | private void _read(ClassLoader classLoader, String source) throws Exception { String xml = null; try { xml = StringUtil.read(classLoader, source); } catch (Exception e) { _log.warn("Cannot load " + source); } if (xml == null) { return; } _log.debug("Loading " + source); SAXReader reader = new SAXReader... | |
sql = replaceIsNull(sql); | public static String replaceAndOperator(String sql, boolean andOperator) { String andOrConnector = "OR"; String andOrNullCheck = "AND ? IS NOT NULL"; if (andOperator) { andOrConnector = "AND"; andOrNullCheck = "OR ? IS NULL"; } sql = StringUtil.replace( sql, new String[] { "[$AND_OR_CONNECTOR$]", "[$AN... | |
return RoleLocalServiceUtil.addRole(getUser().getCompanyId(), name); | return RoleLocalServiceUtil.addRole( user.getUserId(), user.getCompanyId(), name); | public Role addRole(String name) throws PortalException, SystemException { PortalPermission.check(getPermissionChecker(), ActionKeys.ADD_ROLE); return RoleLocalServiceUtil.addRole(getUser().getCompanyId(), name); } |
RolePermission.check(getPermissionChecker(), roleId, ActionKeys.DELETE); | public void deleteRole(String roleId) throws PortalException, SystemException { RoleLocalServiceUtil.deleteRole(roleId); } | |
RolePermission.check(getPermissionChecker(), roleId, ActionKeys.VIEW); | public Role getRole(String roleId) throws PortalException, SystemException { return RoleLocalServiceUtil.getRole(roleId); } | |
RolePermission.check(getPermissionChecker(), roleId, ActionKeys.UPDATE); | public Role updateRole(String roleId, String name) throws PortalException, SystemException { return RoleLocalServiceUtil.updateRole(roleId, name); } | |
_buildSQL("indexes"); _buildSQL("sequences"); | public DBBuilder() { try { _buildSQL("portal"); _buildSQL("update-1.7.5-1.8.0"); _buildSQL("update-1.8.0-1.9.0"); _buildSQL("update-1.9.1-1.9.5"); _buildSQL("update-1.9.5-2.0.0"); _buildSQL("update-2.0.3-2.1.0"); _buildSQL("update-2.1.1-2.2.0"); _buildSQL("update-2.2.1-2.2.5"); _buildSQL("update-3.1... | |
sb.append(FileUtil.read("../sql/indexes.sql")); | sb.append(FileUtil.read("../sql/indexes/indexes-sybase.sql")); | private void _buildCreate() throws IOException { // DB2 File file = new File("../sql/create/create-db2.sql"); StringBuffer sb = new StringBuffer(); sb.append("drop database lportal\n"); sb.append("create database lportal\n"); sb.append("connect to lportal\n"); sb.append(_readSQL("../sql/portal/portal-db2.sql", ... |
sb.append(FileUtil.read("../sql/sequences.sql")); | sb.append(FileUtil.read("../sql/sequences/sequences-sybase.sql")); | private void _buildCreate() throws IOException { // DB2 File file = new File("../sql/create/create-db2.sql"); StringBuffer sb = new StringBuffer(); sb.append("drop database lportal\n"); sb.append("create database lportal\n"); sb.append("connect to lportal\n"); sb.append(_readSQL("../sql/portal/portal-db2.sql", ... |
if (fileName.equals("indexes")) { sybase = _removeBooleanIndexes(sybase); } | private void _buildSQL(String fileName) throws IOException { File file = new File("../sql/" + fileName + ".sql"); if (!file.exists()) { return; } // DB2 String db2 = _buildTemplate(fileName, _DB2, "db2"); db2 = _rewordDb2(db2); db2 = _removeLongInserts(db2); db2 = _removeNull(db2); db2 = StringUtil.replace(... | |
Random random = new Random(); int i = random.nextInt(_verses.size()); | int i = Randomizer.getInstance().nextInt(_verses.size()); | private Verse _getVerse(PortletPreferences prefs, Locale locale) { Bible bible = _getBible(prefs, locale); Random random = new Random(); int i = random.nextInt(_verses.size()); return _getVerse((String)_verses.get(i), bible.getVersionId()); } |
folder.getNewMessageCount()); | folder.getUnreadMessageCount()); | private static void _getFolders(List list, Folder[] folders) throws MessagingException { for (int i = 0; i < folders.length; i++) { Folder folder = folders[i]; int folderType = folder.getType(); if ((folderType & IMAPFolder.HOLDS_MESSAGES) != 0) { MailFolder mailFolder = new MailFolder( folder.getName()... |
message.setFlag(Flag.SEEN, true); | public static void completeMessage( HttpServletRequest req, MailMessage mailMessage, boolean send, long draftId) throws ContentException, ContentPathException, FolderException, RecipientException, StoreException { HttpSession ses = req.getSession(); try { if (send && Validator.isNull(mailMessage.getTo())... | |
mailEnvelope.setRecent(message.isSet(Flag.RECENT)); | mailEnvelope.setRead(message.isSet(Flag.SEEN)); | public static Set getEnvelopes(HttpSession ses, Comparator comparator) throws FolderException { Set envelopes = new TreeSet(comparator); try { MailSessionLock.lock(ses.getId()); IMAPFolder folder = _getFolder(ses); Message[] messages = folder.getMessages(); FetchProfile fetchProfile = new FetchProfile(); ... |
value = getCreateDate().compareTo(dlFileRank.getCreateDate()); | value = DateUtil.compareTo(getCreateDate(), dlFileRank.getCreateDate()); | public int compareTo(Object obj) { if (obj == null) { return -1; } DLFileRank dlFileRank = (DLFileRank)obj; int value = 0; value = getCreateDate().compareTo(dlFileRank.getCreateDate()); value = value * -1; if (value != 0) { return value; } return 0; } |
Thread.sleep(Time.SECOND * 30); | Thread.sleep(Time.SECOND * 10); | public void reIndex() { if (_log.isInfoEnabled()) { _log.info("Re-indexing Lucene started"); } if (ServerDetector.isOrion()) { // Wait 30 seconds because Orion 2.0.7 initiates LuceneServlet // before it initiates MainServlet. try { Thread.sleep(Time.SECOND * 30); } catch (InterruptedException ie) { ... |
long start = System.currentTimeMillis(); | long start1 = System.currentTimeMillis(); | public void reIndex() { if (_log.isInfoEnabled()) { _log.info("Re-indexing Lucene started"); } if (ServerDetector.isOrion()) { // Wait 30 seconds because Orion 2.0.7 initiates LuceneServlet // before it initiates MainServlet. try { Thread.sleep(Time.SECOND * 30); } catch (InterruptedException ie) { ... |
"Re-indexing with " + className + " completed"); | "Re-indexing with " + className + " completed in " + ((end2 - start2) / Time.SECOND) + " seconds"); | public void reIndex() { if (_log.isInfoEnabled()) { _log.info("Re-indexing Lucene started"); } if (ServerDetector.isOrion()) { // Wait 30 seconds because Orion 2.0.7 initiates LuceneServlet // before it initiates MainServlet. try { Thread.sleep(Time.SECOND * 30); } catch (InterruptedException ie) { ... |
long end = System.currentTimeMillis(); | long end1 = System.currentTimeMillis(); | public void reIndex() { if (_log.isInfoEnabled()) { _log.info("Re-indexing Lucene started"); } if (ServerDetector.isOrion()) { // Wait 30 seconds because Orion 2.0.7 initiates LuceneServlet // before it initiates MainServlet. try { Thread.sleep(Time.SECOND * 30); } catch (InterruptedException ie) { ... |
((end - start) / Time.SECOND) + " seconds"); | ((end1 - start1) / Time.SECOND) + " seconds"); | public void reIndex() { if (_log.isInfoEnabled()) { _log.info("Re-indexing Lucene started"); } if (ServerDetector.isOrion()) { // Wait 30 seconds because Orion 2.0.7 initiates LuceneServlet // before it initiates MainServlet. try { Thread.sleep(Time.SECOND * 30); } catch (InterruptedException ie) { ... |
String companyId, boolean autoUserId, String userId, boolean autoPassword, String password1, String password2, boolean passwordReset, String emailAddress, Locale locale, String firstName, String middleName, String lastName, | String creatorUserId, String companyId, boolean autoUserId, String userId, boolean autoPassword, String password1, String password2, boolean passwordReset, String emailAddress, Locale locale, String firstName, String middleName, String lastName, | public User addUser( String companyId, boolean autoUserId, String userId, boolean autoPassword, String password1, String password2, boolean passwordReset, String emailAddress, Locale locale, String firstName, String middleName, String lastName, String nickName, String prefixId, String suffixId, boolean male,... |
companyId, autoUserId, userId, autoPassword, password1, password2, passwordReset, emailAddress, locale, firstName, middleName, lastName, nickName, prefixId, suffixId, male, birthdayMonth, birthdayDay, birthdayYear, jobTitle, organizationId, locationId, true); | creatorUserId, companyId, autoUserId, userId, autoPassword, password1, password2, passwordReset, emailAddress, locale, firstName, middleName, lastName, nickName, prefixId, suffixId, male, birthdayMonth, birthdayDay, birthdayYear, jobTitle, organizationId, locationId, true); | public User addUser( String companyId, boolean autoUserId, String userId, boolean autoPassword, String password1, String password2, boolean passwordReset, String emailAddress, Locale locale, String firstName, String middleName, String lastName, String nickName, String prefixId, String suffixId, boolean male,... |
PasswordTrackerLocalServiceUtil.deleteAll(userId); | PasswordTrackerLocalServiceUtil.deletePasswordTrackers(userId); | public void deleteUser(String userId) throws PortalException, SystemException { userId = userId.trim().toLowerCase(); if (!GetterUtil.getBoolean(PropsUtil.get(PropsUtil.USERS_DELETE))) { throw new RequiredUserException(); } User user = UserUtil.findByPrimaryKey(userId); // Group Group group = user.getGroup();... |
UserIdMapperLocalServiceUtil.deleteAll(userId); AddressLocalServiceUtil.deleteAll( user.getCompanyId(), User.class.getName(), userId); | UserIdMapperLocalServiceUtil.deleteUserIdMappers(userId); | public void deleteUser(String userId) throws PortalException, SystemException { userId = userId.trim().toLowerCase(); if (!GetterUtil.getBoolean(PropsUtil.get(PropsUtil.USERS_DELETE))) { throw new RequiredUserException(); } User user = UserUtil.findByPrimaryKey(userId); // Group Group group = user.getGroup();... |
public com.liferay.portal.model.Role addRole(java.lang.String companyId, java.lang.String name) | public com.liferay.portal.model.Role addRole(java.lang.String userId, java.lang.String companyId, java.lang.String name) | public com.liferay.portal.model.Role addRole(java.lang.String companyId, java.lang.String name) throws com.liferay.portal.PortalException, com.liferay.portal.SystemException { return getService().addRole(companyId, name); } |
return getService().addRole(companyId, name); | return getService().addRole(userId, companyId, name); | public com.liferay.portal.model.Role addRole(java.lang.String companyId, java.lang.String name) throws com.liferay.portal.PortalException, com.liferay.portal.SystemException { return getService().addRole(companyId, name); } |
setModified(true); | public void setAimSn(String aimSn) { if (((aimSn == null) && (_aimSn != null)) || ((aimSn != null) && (_aimSn == null)) || ((aimSn != null) && (_aimSn != null) && !aimSn.equals(_aimSn))) { if (!XSS_ALLOW_AIMSN) { aimSn = XSSUtil.strip(aimSn); } _aimSn = aimSn; setModified(true); } } | |
setModified(true); | public void setBirthday(Date birthday) { if (((birthday == null) && (_birthday != null)) || ((birthday != null) && (_birthday == null)) || ((birthday != null) && (_birthday != null) && !birthday.equals(_birthday))) { _birthday = birthday; setModified(true); } } | |
setModified(true); | public void setEmployeeNumber(String employeeNumber) { if (((employeeNumber == null) && (_employeeNumber != null)) || ((employeeNumber != null) && (_employeeNumber == null)) || ((employeeNumber != null) && (_employeeNumber != null) && !employeeNumber.equals(_employeeNumber))) { if (!XSS_ALLOW_EMPLOYEENUMBE... | |
setModified(true); | public void setEmployeeStatusId(String employeeStatusId) { if (((employeeStatusId == null) && (_employeeStatusId != null)) || ((employeeStatusId != null) && (_employeeStatusId == null)) || ((employeeStatusId != null) && (_employeeStatusId != null) && !employeeStatusId.equals(_employeeStatusId))) { if (!XSS... | |
setModified(true); | public void setFirstName(String firstName) { if (((firstName == null) && (_firstName != null)) || ((firstName != null) && (_firstName == null)) || ((firstName != null) && (_firstName != null) && !firstName.equals(_firstName))) { if (!XSS_ALLOW_FIRSTNAME) { firstName = XSSUtil.strip(firstName); } _fi... | |
setModified(true); | public void setHoursOfOperation(String hoursOfOperation) { if (((hoursOfOperation == null) && (_hoursOfOperation != null)) || ((hoursOfOperation != null) && (_hoursOfOperation == null)) || ((hoursOfOperation != null) && (_hoursOfOperation != null) && !hoursOfOperation.equals(_hoursOfOperation))) { if (!XSS... | |
setModified(true); | public void setIcqSn(String icqSn) { if (((icqSn == null) && (_icqSn != null)) || ((icqSn != null) && (_icqSn == null)) || ((icqSn != null) && (_icqSn != null) && !icqSn.equals(_icqSn))) { if (!XSS_ALLOW_ICQSN) { icqSn = XSSUtil.strip(icqSn); } _icqSn = icqSn; setModified(true); } } | |
setModified(true); | public void setJabberSn(String jabberSn) { if (((jabberSn == null) && (_jabberSn != null)) || ((jabberSn != null) && (_jabberSn == null)) || ((jabberSn != null) && (_jabberSn != null) && !jabberSn.equals(_jabberSn))) { if (!XSS_ALLOW_JABBERSN) { jabberSn = XSSUtil.strip(jabberSn); } _jabberSn = jabb... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.