rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
setModified(true); | public void setWidth(int width) { if (width != _width) { _width = width; setModified(true); } } | |
java.lang.String companyId, java.lang.String parentOrganizationId, | java.lang.String userId, java.lang.String parentOrganizationId, | public static com.liferay.portal.model.Organization addOrganization( java.lang.String companyId, java.lang.String parentOrganizationId, java.lang.String name, java.lang.String regionId, java.lang.String countryId, java.lang.String statusId, boolean location) throws com.liferay.portal.PortalException, com.lifera... |
return organizationLocalService.addOrganization(companyId, | return organizationLocalService.addOrganization(userId, | public static com.liferay.portal.model.Organization addOrganization( java.lang.String companyId, java.lang.String parentOrganizationId, java.lang.String name, java.lang.String regionId, java.lang.String countryId, java.lang.String statusId, boolean location) throws com.liferay.portal.PortalException, com.lifera... |
_pathInfo = pathInfo != null ? pathInfo : StringPool.BLANK; _queryString = queryString != null ? queryString : StringPool.BLANK; _requestURI = requestURI != null ? requestURI : StringPool.BLANK; _servletPath = servletPath != null ? servletPath : StringPool.BLANK; | _pathInfo = GetterUtil.getString(pathInfo); _queryString = GetterUtil.getString(queryString); _requestURI = GetterUtil.getString(requestURI); _servletPath = GetterUtil.getString(servletPath); | public PortletServletRequest(HttpServletRequest req, PortletRequest portletRequest, String pathInfo, String queryString, String requestURI, String servletPath, Map sharedHttpSessionAttributes) { super(req); _req = req; _portletRequest = portletRequest; _pathInfo = pathInfo != null ?... |
_validate( | validate( | public EmailAddress addEmailAddress( String userId, String className, String classPK, String address, String typeId, boolean primary) throws PortalException, SystemException { User user = UserUtil.findByPrimaryKey(userId); _validate( null, user.getCompanyId(), className, classPK, address, typeId, primary); ... |
Date now = new Date(); | public EmailAddress addEmailAddress( String userId, String className, String classPK, String address, String typeId, boolean primary) throws PortalException, SystemException { User user = UserUtil.findByPrimaryKey(userId); _validate( null, user.getCompanyId(), className, classPK, address, typeId, primary); ... | |
_validate(emailAddressId, null, null, null, address, typeId, primary); | validate(emailAddressId, null, null, null, address, typeId, primary); | public EmailAddress updateEmailAddress( String emailAddressId, String address, String typeId, boolean primary) throws PortalException, SystemException { _validate(emailAddressId, null, null, null, address, typeId, primary); EmailAddress emailAddress = EmailAddressUtil.findByPrimaryKey(emailAddressId); emailA... |
CommonPermission.checkPermission( getPermissionChecker(), className, classPK, ActionKeys.UPDATE); | public Address addAddress( String className, String classPK, String street1, String street2, String street3, String city, String zip, String regionId, String countryId, String typeId, boolean mailing, boolean primary) throws PortalException, SystemException { return AddressLocalServiceUtil.addAddress( getUse... | |
Address address = AddressUtil.findByPrimaryKey(addressId); CommonPermission.checkPermission( getPermissionChecker(), address.getClassName(), address.getClassPK(), ActionKeys.UPDATE); | public void deleteAddress(String addressId) throws PortalException, SystemException { AddressLocalServiceUtil.deleteAddress(addressId); } | |
return AddressUtil.findByPrimaryKey(addressId); | Address address = AddressUtil.findByPrimaryKey(addressId); CommonPermission.checkPermission( getPermissionChecker(), address.getClassName(), address.getClassPK(), ActionKeys.VIEW); return address; | public Address getAddress(String addressId) throws PortalException, SystemException { return AddressUtil.findByPrimaryKey(addressId); } |
CommonPermission.checkPermission( getPermissionChecker(), className, classPK, ActionKeys.VIEW); | public List getAddresses(String className, String classPK) throws PortalException, SystemException { return AddressLocalServiceUtil.getAddresses( getUser().getCompanyId(), className, classPK); } | |
Address address = AddressUtil.findByPrimaryKey(addressId); CommonPermission.checkPermission( getPermissionChecker(), address.getClassName(), address.getClassPK(), ActionKeys.UPDATE); | public Address updateAddress( String addressId, String street1, String street2, String street3, String city, String zip, String regionId, String countryId, String typeId, boolean mailing, boolean primary) throws PortalException, SystemException { return AddressLocalServiceUtil.updateAddress( addressId, stree... | |
Folder folder = (Folder)_folder.get(userId); | IMAPFolder folder = (IMAPFolder)_folder.get(userId); | private static void _closeFolder(String userId) { Folder folder = (Folder)_folder.get(userId); if (folder != null && folder.isOpen()) { try { folder.close(false); } catch (MessagingException me) { _log.error("Unknown error while closing current folder"); } _folder.remove(userId); } } |
private static Folder _getCurrentFolder(String userId) | private static IMAPFolder _getCurrentFolder(String userId) | private static Folder _getCurrentFolder(String userId) throws Exception { Folder folder = (Folder)_folder.get(userId); if (folder != null) { return folder; } throw new Exception("A folder must first be selected"); } |
Folder folder = (Folder)_folder.get(userId); | IMAPFolder folder = (IMAPFolder)_folder.get(userId); | private static Folder _getCurrentFolder(String userId) throws Exception { Folder folder = (Folder)_folder.get(userId); if (folder != null) { return folder; } throw new Exception("A folder must first be selected"); } |
private static Folder _getFolder( | private static IMAPFolder _getFolder( | private static Folder _getFolder( String userId, String password, String folderName) throws Exception { if (Validator.isNull(folderName)) { folderName = MAIL_INBOX_NAME; } Folder folder = (Folder)_folder.get(userId); if (folder != null) { if (!folder.getName().equals(folderName)) { _closeFolder(userId... |
Folder folder = (Folder)_folder.get(userId); | IMAPFolder folder = (IMAPFolder)_folder.get(userId); | private static Folder _getFolder( String userId, String password, String folderName) throws Exception { if (Validator.isNull(folderName)) { folderName = MAIL_INBOX_NAME; } Folder folder = (Folder)_folder.get(userId); if (folder != null) { if (!folder.getName().equals(folderName)) { _closeFolder(userId... |
folder = _getStore(userId, password).getFolder(folderName); folder.open(Folder.READ_WRITE); | folder = (IMAPFolder)_getStore(userId, password).getFolder(folderName); folder.open(IMAPFolder.READ_WRITE); | private static Folder _getFolder( String userId, String password, String folderName) throws Exception { if (Validator.isNull(folderName)) { folderName = MAIL_INBOX_NAME; } Folder folder = (Folder)_folder.get(userId); if (folder != null) { if (!folder.getName().equals(folderName)) { _closeFolder(userId... |
return _plainBody; | return GetterUtil.getString(_plainBody); | public String getPlainBody() { return _plainBody; } |
return _subject; | return GetterUtil.getString(_subject); | public String getSubject() { return _subject; } |
String topicId = ParamUtil.getString(req, "topicId"); | public void processAction( ActionMapping mapping, ActionForm form, PortletConfig config, ActionRequest req, ActionResponse res) throws Exception { try { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); String fileName = ParamUtil.getString(req,... | |
MBMessage message = MBMessageServiceUtil.getMessage( topicId, messageId); | MBMessage message = MBMessageServiceUtil.getMessage(messageId); | public void processAction( ActionMapping mapping, ActionForm form, PortletConfig config, ActionRequest req, ActionResponse res) throws Exception { try { String topicId = ParamUtil.getString(req, "topicId"); String messageId = ParamUtil.getString(req, "messageId"); String fileName = ParamUtil.getString(req,... |
java.lang.String topicId, java.lang.String messageId) | java.lang.String messageId) | public static com.liferay.portlet.messageboards.model.MBMessage getMessage( java.lang.String topicId, java.lang.String messageId) throws com.liferay.portal.PortalException, com.liferay.portal.SystemException { try { MBMessageService mbMessageService = MBMessageServiceFactory.getService(); return mbMessageSer... |
return mbMessageService.getMessage(topicId, messageId); | return mbMessageService.getMessage(messageId); | public static com.liferay.portlet.messageboards.model.MBMessage getMessage( java.lang.String topicId, java.lang.String messageId) throws com.liferay.portal.PortalException, com.liferay.portal.SystemException { try { MBMessageService mbMessageService = MBMessageServiceFactory.getService(); return mbMessageSer... |
value = getCreateDate().compareTo(phone.getCreateDate()); | value = DateUtil.compareTo(getCreateDate(), phone.getCreateDate()); | public int compareTo(Object obj) { if (obj == null) { return -1; } Phone phone = (Phone)obj; int value = 0; value = getCreateDate().compareTo(phone.getCreateDate()); if (value != 0) { return value; } return 0; } |
return model(abListHBM, true); | return (com.liferay.portlet.addressbook.model.ABList)abListHBM; | public static com.liferay.portlet.addressbook.model.ABList model( ABListHBM abListHBM) { return model(abListHBM, true); } |
java.lang.String folderId, java.lang.String name, java.lang.String title, java.lang.String description) | java.lang.String folderId, 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( 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.SystemException { DLFileEntryServic... |
return dlFileEntryService.updateFileEntry(folderId, name, title, description); | return dlFileEntryService.updateFileEntry(folderId, newFolderId, name, sourceFileName, title, description, byteArray); | public static com.liferay.portlet.documentlibrary.model.DLFileEntry updateFileEntry( 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.SystemException { DLFileEntryServic... |
public static String formatXML(Document doc) | public static String formatXML(String xml) | public static String formatXML(Document doc) throws DocumentException, IOException { return XMLFormatter.toString(doc, XML_INDENT); } |
return XMLFormatter.toString(doc, XML_INDENT); | xml = StringUtil.replace(xml, "&#", "[$SPECIAL_CHARACTER$]"); xml = XMLFormatter.toString(xml, XML_INDENT); xml = StringUtil.replace(xml, "[$SPECIAL_CHARACTER$]", "&#"); return xml; | public static String formatXML(Document doc) throws DocumentException, IOException { return XMLFormatter.toString(doc, XML_INDENT); } |
image = ImageServiceUtil.getImage(id); | image = ImageLocalServiceUtil.getImage(id); | public static Image get(String id) { Image image = null; try { image = ImageServiceUtil.getImage(id); } catch (Exception e) { _log.warn(e); } return image; } |
qPos.add(approved); qPos.add(approved); qPos.add(expired); qPos.add(expired); | if (approved != null) { qPos.add(approved); } if (expired != null) { qPos.add(expired); } | public static List findByC_A_V_G_T_C_T_S_T_D_A_E_R( String companyId, String articleId, Double version, String groupId, String title, String content, String type, String structureId, String templateId, Date displayDateGT, Date displayDateLT, Boolean approved, Boolean expired, Date reviewDate, boolean andOper... |
qPos.add(approved); qPos.add(approved); qPos.add(expired); qPos.add(expired); | if (approved != null) { qPos.add(approved); } if (expired != null) { qPos.add(expired); } | public static int countByC_A_V_G_T_C_T_S_T_D_A_E_R( String companyId, String articleId, Double version, String groupId, String title, String content, String type, String structureId, String templateId, Date displayDateGT, Date displayDateLT, Boolean approved, Boolean expired, Date reviewDate, boolean andOper... |
DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.create(pk); | DLFileEntry fileEntry = DLFileEntryUtil.create( new DLFileEntryPK(folderId, name)); | public DLFileEntry addFileEntry( String userId, String folderId, String name, String title, String description, byte[] byteArray, boolean addCommunityPermissions, boolean addGuestPermissions) throws PortalException, SystemException { // File entry User user = UserUtil.findByPrimaryKey(userId); folderId = get... |
DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); return fileEntry; | return DLFileEntryUtil.findByPrimaryKey( new DLFileEntryPK(folderId, name)); | public DLFileEntry getFileEntry(String folderId, String name) throws PortalException, SystemException { DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); return fileEntry; } |
String folderId, String name, String title, String description) | String userId, String folderId, String newFolderId, String name, String sourceFileName, String title, String description, byte[] byteArray) | public DLFileEntry updateFileEntry( String folderId, String name, String title, String description) throws PortalException, SystemException { if (Validator.isNull(title)) { title = name; } DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); file... |
DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); | DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey( new DLFileEntryPK(folderId, name)); | public DLFileEntry updateFileEntry( String folderId, String name, String title, String description) throws PortalException, SystemException { if (Validator.isNull(title)) { title = name; } DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); file... |
if (Validator.isNotNull(newFolderId) && !folderId.equals(newFolderId)) { DLFolder newFolder = DLFolderUtil.findByPrimaryKey(newFolderId); if (!folder.getGroupId().equals(newFolder.getGroupId())) { throw new NoSuchFolderException(); } try { DLLocalServiceUtil.getFileContentNode( user.getCompanyId(), newFolderId, name,... | public DLFileEntry updateFileEntry( String folderId, String name, String title, String description) throws PortalException, SystemException { if (Validator.isNull(title)) { title = name; } DLFileEntryPK pk = new DLFileEntryPK(folderId, name); DLFileEntry fileEntry = DLFileEntryUtil.findByPrimaryKey(pk); file... | |
String fileName, double versionNumber) | String fileName) | public static void deleteFile( String companyId, String portletId, String repositoryId, String fileName, double versionNumber) throws PortalException, RemoteException, SystemException { DLService dlService = DLServiceFactory.getService(); dlService.deleteFile( companyId, portletId, repositoryId, fileName, ver... |
dlService.deleteFile( companyId, portletId, repositoryId, fileName, versionNumber); | dlService.deleteFile(companyId, portletId, repositoryId, fileName); | public static void deleteFile( String companyId, String portletId, String repositoryId, String fileName, double versionNumber) throws PortalException, RemoteException, SystemException { DLService dlService = DLServiceFactory.getService(); dlService.deleteFile( companyId, portletId, repositoryId, fileName, ver... |
query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); | public DLFolder fetchByP_N(String parentFolderId, String name) throws SystemException { Session session = null; try { session = openSession(); StringBuffer query = new StringBuffer(); query.append( "FROM com.liferay.portlet.documentlibrary.model.DLFolder WHERE "); if (parentFolderId == null) { query.a... | |
query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); | public List findAll() throws SystemException { Session session = null; try { session = openSession(); StringBuffer query = new StringBuffer(); query.append( "FROM com.liferay.portlet.documentlibrary.model.DLFolder "); Query q = session.createQuery(query.toString()); q.setCacheable(true); return q.list... | |
query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); | public List findByCompanyId(String companyId) throws SystemException { Session session = null; try { session = openSession(); StringBuffer query = new StringBuffer(); query.append( "FROM com.liferay.portlet.documentlibrary.model.DLFolder WHERE "); if (companyId == null) { query.append("companyId IS NUL... | |
else { query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); } | public DLFolder[] findByCompanyId_PrevAndNext(String folderId, String companyId, OrderByComparator obc) throws NoSuchFolderException, SystemException { DLFolder dlFolder = findByPrimaryKey(folderId); int count = countByCompanyId(companyId); Session session = null; try { session = openSession(); StringBuffer ... | |
query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); | public List findByG_P(String groupId, String parentFolderId) throws SystemException { Session session = null; try { session = openSession(); StringBuffer query = new StringBuffer(); query.append( "FROM com.liferay.portlet.documentlibrary.model.DLFolder WHERE "); if (groupId == null) { query.append("gr... | |
else { query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); } | public DLFolder[] findByG_P_PrevAndNext(String folderId, String groupId, String parentFolderId, OrderByComparator obc) throws NoSuchFolderException, SystemException { DLFolder dlFolder = findByPrimaryKey(folderId); int count = countByG_P(groupId, parentFolderId); Session session = null; try { session = openSes... | |
query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); | public List findByGroupId(String groupId) throws SystemException { Session session = null; try { session = openSession(); StringBuffer query = new StringBuffer(); query.append( "FROM com.liferay.portlet.documentlibrary.model.DLFolder WHERE "); if (groupId == null) { query.append("groupId IS NULL"); }... | |
else { query.append("ORDER BY "); query.append("parentFolderId ASC").append(", "); query.append("name ASC"); } | public DLFolder[] findByGroupId_PrevAndNext(String folderId, String groupId, OrderByComparator obc) throws NoSuchFolderException, SystemException { DLFolder dlFolder = findByPrimaryKey(folderId); int count = countByGroupId(groupId); Session session = null; try { session = openSession(); StringBuffer query = ... | |
public static void getMessage(RenderRequest req) throws Exception { | public static void getMessage(ActionRequest req) throws Exception { | public static void getMessage(RenderRequest req) throws Exception { HttpServletRequest httpReq = ((RenderRequestImpl)req).getHttpServletRequest(); getMessage(httpReq); } |
((RenderRequestImpl)req).getHttpServletRequest(); | ((ActionRequestImpl)req).getHttpServletRequest(); | public static void getMessage(RenderRequest req) throws Exception { HttpServletRequest httpReq = ((RenderRequestImpl)req).getHttpServletRequest(); getMessage(httpReq); } |
String companyId, String themeId, String colorSchemeId) { | String companyId, String themeId, String colorSchemeId) throws PortalException, SystemException { | public static ColorScheme getColorScheme( String companyId, String themeId, String colorSchemeId) { colorSchemeId = GetterUtil.getString(colorSchemeId); Theme theme = getTheme(companyId, themeId); Map colorSchemesMap = theme.getColorSchemesMap(); ColorScheme colorScheme = (ColorScheme)colorSchemesMap.get( color... |
CompanyPropsUtil.get( | PrefsPropsUtil.getString( | public static ColorScheme getColorScheme( String companyId, String themeId, String colorSchemeId) { colorSchemeId = GetterUtil.getString(colorSchemeId); Theme theme = getTheme(companyId, themeId); Map colorSchemesMap = theme.getColorSchemesMap(); ColorScheme colorScheme = (ColorScheme)colorSchemesMap.get( color... |
public static Theme getTheme(String companyId, String themeId) { | public static Theme getTheme(String companyId, String themeId) throws PortalException, SystemException { | public static Theme getTheme(String companyId, String themeId) { themeId = GetterUtil.getString(themeId); Theme theme = (Theme)_getThemes(companyId).get(themeId); if (theme == null) { theme = (Theme)_themes.get( CompanyPropsUtil.get(companyId, PropsUtil.DEFAULT_THEME_ID)); } return theme; } |
CompanyPropsUtil.get(companyId, PropsUtil.DEFAULT_THEME_ID)); | PrefsPropsUtil.getString( companyId, PropsUtil.DEFAULT_THEME_ID)); | public static Theme getTheme(String companyId, String themeId) { themeId = GetterUtil.getString(themeId); Theme theme = (Theme)_getThemes(companyId).get(themeId); if (theme == null) { theme = (Theme)_themes.get( CompanyPropsUtil.get(companyId, PropsUtil.DEFAULT_THEME_ID)); } return theme; } |
StringPool.COMMA + StringPool.SPACE + tf.format(me.getDate()); | StringPool.SPACE + tf.format(me.getDate()); | private String _getPreviewHeaders(HttpServletRequest req) throws Exception { JSONObject jsonObj = new JSONObject(); String folderId = ParamUtil.getString(req, "folderId"); String sortBy = ParamUtil.getString(req, "sortBy"); boolean asc = ParamUtil.getBoolean(req, "asc"); SortedSet set; MailUtil.setCurrentFolder(... |
if (!folder.getName().equals(MAIL_TRASH_NAME)) { | String folderName = _getResolvedFolderName(folder.getName()); if (!folderName.equals(MAIL_TRASH_NAME)) { | public static void deleteMessages(HttpSession ses, long[] messageIds) throws FolderException, StoreException { try { MailSessionLock.lock(ses.getId()); IMAPFolder folder = _getFolder(ses); if (!folder.getName().equals(MAIL_TRASH_NAME)) { moveMessages(ses, messageIds, MAIL_TRASH_NAME); } else { Messag... |
if (MAIL_SENT_NAME.equals(folder.getName()) || MAIL_DRAFTS_NAME.equals(folder.getName())) { | if (MAIL_SENT_NAME.equals(folderName) || MAIL_DRAFTS_NAME.equals(folderName)) { | 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(); ... |
if (!toFolderName.equals(MAIL_INBOX_NAME) && !toFolderName.startsWith(MAIL_BOX_STYLE)) { toFolderName = MAIL_BOX_STYLE + toFolderName; } | toFolderName = _getResolvedFolderName(toFolderName); | public static void moveMessages( HttpSession ses, long[] messageIds, String toFolderName) throws FolderException, StoreException { IMAPFolder toFolder = null; if (!toFolderName.equals(MAIL_INBOX_NAME) && !toFolderName.startsWith(MAIL_BOX_STYLE)) { toFolderName = MAIL_BOX_STYLE + toFolderName; } try { Mail... |
if (folder.getName().equals(toFolderName)) { | String folderName = _getResolvedFolderName(folder.getName()); if (folderName.equals(toFolderName)) { | public static void moveMessages( HttpSession ses, long[] messageIds, String toFolderName) throws FolderException, StoreException { IMAPFolder toFolder = null; if (!toFolderName.equals(MAIL_INBOX_NAME) && !toFolderName.startsWith(MAIL_BOX_STYLE)) { toFolderName = MAIL_BOX_STYLE + toFolderName; } try { Mail... |
if ((folder.getName().equals(MAIL_DRAFTS_NAME) || | if ((folderName.equals(MAIL_DRAFTS_NAME) || | public static void moveMessages( HttpSession ses, long[] messageIds, String toFolderName) throws FolderException, StoreException { IMAPFolder toFolder = null; if (!toFolderName.equals(MAIL_INBOX_NAME) && !toFolderName.startsWith(MAIL_BOX_STYLE)) { toFolderName = MAIL_BOX_STYLE + toFolderName; } try { Mail... |
String baseProviderURL = ParamUtil.getString(req, "base_provider_url"); String baseDN = ParamUtil.getString(req, "base_dn"); | String baseProviderURL = ParamUtil.getString(req, "baseProviderURL"); String baseDN = ParamUtil.getString(req, "baseDN"); | protected void updateLdap(ActionRequest req, PortletPreferences prefs) throws Exception { boolean enabled = ParamUtil.getBoolean(req, "enabled"); boolean required = ParamUtil.getBoolean(req, "required"); String baseProviderURL = ParamUtil.getString(req, "base_provider_url"); String baseDN = ParamUtil.getString(re... |
String folderId, String name, String title, String description) | String folderId, String newFolderId, String name, String sourceFileName, String title, String description, byte[] byteArray) | public DLFileEntry updateFileEntry( String folderId, String name, String title, String description) throws PortalException, RemoteException, SystemException { User user = getUser(); DLFileEntryPermission.check( getPermissionChecker(), folderId, name, ActionKeys.UPDATE); DLFileEntryPK pk = new DLFileEntryPK(fol... |
folderId, name, title, description); | getUserId(), folderId, newFolderId, name, sourceFileName, title, description, byteArray); | public DLFileEntry updateFileEntry( String folderId, String name, String title, String description) throws PortalException, RemoteException, SystemException { User user = getUser(); DLFileEntryPermission.check( getPermissionChecker(), folderId, name, ActionKeys.UPDATE); DLFileEntryPK pk = new DLFileEntryPK(fol... |
Iterator itr = list.iterator(); | for (int j = 0; j < list.size(); j++) { MailFolder mailFolder = (MailFolder)list.get(j); | private static Store _getStore(HttpSession ses) throws FolderException, StoreException { try { Store store = (Store)ses.getAttribute(WebKeys.MAIL_STORE); if (store != null && !store.isConnected()) { if (_log.isInfoEnabled()) { _log.info("The store needs to be reconnected"); } cleanUp(ses); store ... |
while (itr.hasNext()) { MailFolder mailFolder = (MailFolder)itr.next(); | String folderName = _getResolvedFolderName(mailFolder.getName()); | private static Store _getStore(HttpSession ses) throws FolderException, StoreException { try { Store store = (Store)ses.getAttribute(WebKeys.MAIL_STORE); if (store != null && !store.isConnected()) { if (_log.isInfoEnabled()) { _log.info("The store needs to be reconnected"); } cleanUp(ses); store ... |
if (DEFAULT_FOLDERS[i].equals(mailFolder.getName())) { | if (DEFAULT_FOLDERS[i].equals(folderName)) { | private static Store _getStore(HttpSession ses) throws FolderException, StoreException { try { Store store = (Store)ses.getAttribute(WebKeys.MAIL_STORE); if (store != null && !store.isConnected()) { if (_log.isInfoEnabled()) { _log.info("The store needs to be reconnected"); } cleanUp(ses); store ... |
if (_log.isInfoEnabled()) { _log.info( "Created default folder " + DEFAULT_FOLDERS[i]); } | private static Store _getStore(HttpSession ses) throws FolderException, StoreException { try { Store store = (Store)ses.getAttribute(WebKeys.MAIL_STORE); if (store != null && !store.isConnected()) { if (_log.isInfoEnabled()) { _log.info("The store needs to be reconnected"); } cleanUp(ses); store ... | |
String pk = dlFolder.getPrimaryKey(); | int value = 0; value = getParentFolderId().compareTo(dlFolder.getParentFolderId()); | public int compareTo(Object obj) { if (obj == null) { return -1; } DLFolder dlFolder = (DLFolder)obj; String pk = dlFolder.getPrimaryKey(); return getPrimaryKey().compareTo(pk); } |
return getPrimaryKey().compareTo(pk); | if (value != 0) { return value; } value = getName().toLowerCase().compareTo(dlFolder.getName() .toLowerCase()); if (value != 0) { return value; } return 0; | public int compareTo(Object obj) { if (obj == null) { return -1; } DLFolder dlFolder = (DLFolder)obj; String pk = dlFolder.getPrimaryKey(); return getPrimaryKey().compareTo(pk); } |
if (Validator.isNotNull(_servletMapping) && strutsAction.startsWith(_servletMapping)) { strutsAction = strutsAction.substring( _servletMapping.length() - 1, strutsAction.length()); | if (strutsAction.startsWith("c/")) { strutsAction = strutsAction.substring(1); | public String encodeURL(String path) { if (_log.isDebugEnabled()) { _log.debug("Path " + path); _log.debug("Context path " + _contextPath); _log.debug("Servlet mapping " + _servletMapping); } String encodedURL = path; if (path.startsWith("//") || path.startsWith(_contextPath + _servletMapping)) { // Stru... |
else if (strutsAction.startsWith("/c/")) { strutsAction = strutsAction.substring(2); } | public String encodeURL(String path) { if (_log.isDebugEnabled()) { _log.debug("Path " + path); _log.debug("Context path " + _contextPath); _log.debug("Servlet mapping " + _servletMapping); } String encodedURL = path; if (path.startsWith("//") || path.startsWith(_contextPath + _servletMapping)) { // Stru... | |
} else if (ServerDetector.isPramati()) { sd._serverId = "pramati"; | public static String getServerId() { ServerDetector sd = _instance; if (sd._serverId == null) { if (ServerDetector.isGeronimo()) { sd._serverId = "geronimo"; } else if (ServerDetector.isJBoss()) { sd._serverId = "jboss"; } else if (ServerDetector.isJOnAS()) { sd._serverId = "jonas"; } else if ... | |
private Set _readPortletXML(String xml, Map portletsPool) throws DocumentException, IOException { | private Set _readPortletXML(String xml, Map portletsPool, List servletURLPatterns) throws DocumentException, IOException { | private Set _readPortletXML(String xml, Map portletsPool) throws DocumentException, IOException { return _readPortletXML(null, xml, portletsPool); } |
return _readPortletXML(null, xml, portletsPool); | return _readPortletXML(null, xml, portletsPool, servletURLPatterns); | private Set _readPortletXML(String xml, Map portletsPool) throws DocumentException, IOException { return _readPortletXML(null, xml, portletsPool); } |
Set portletIds = _readPortletXML(xmls[0], portletsPool); | List servletURLPatterns = _readWebXML(xmls[4]); | public void initEAR(String[] xmls) { String scpId = PortletServiceImpl.class.getName() + "." + _SHARED_KEY; Map portletsPool = (Map)SimpleCachePool.get(scpId); if (portletsPool == null) { portletsPool = CollectionFactory.getSyncHashMap(); SimpleCachePool.put(scpId, portletsPool); } try { Set portletIds = _r... |
portletIds.addAll(_readPortletXML(xmls[1], portletsPool)); | Set portletIds = _readPortletXML(xmls[0], portletsPool, servletURLPatterns); portletIds.addAll(_readPortletXML(xmls[1], portletsPool, servletURLPatterns)); | public void initEAR(String[] xmls) { String scpId = PortletServiceImpl.class.getName() + "." + _SHARED_KEY; Map portletsPool = (Map)SimpleCachePool.get(scpId); if (portletsPool == null) { portletsPool = CollectionFactory.getSyncHashMap(); SimpleCachePool.put(scpId, portletsPool); } try { Set portletIds = _r... |
servletContextName, xmls[0], portletsPool); | servletContextName, xmls[0], portletsPool, servletPatterns); | public List initWAR(String servletContextName, String[] xmls) { List portlets = new ArrayList(); String scpId = PortletServiceImpl.class.getName() + "." + _SHARED_KEY; Map portletsPool = (Map)SimpleCachePool.get(scpId); if (portletsPool == null) { portletsPool = CollectionFactory.getSyncHashMap(); SimpleCacheP... |
isWARFile()); | isWARFile(), getServletURLPatterns()); | public Object clone() { return new Portlet( getPortletId(), getCompanyId(), getStrutsPath(), getConfigurationPath(), getPortletClass(), getIndexerClass(), getSchedulerClass(), getPortletURLClass(), getFriendlyURLPluginClass(), getDefaultPreferences(), getPreferencesValidator(), isPreferencesCompanyWide(), ... |
setModified(true); | public void setNarrow(boolean narrow) { if (narrow != _narrow) { _narrow = narrow; setModified(true); } } | |
public Portlet(PortletPK pk) { setPrimaryKey(pk); setStrutsPath(pk.portletId); setActive(true); _unlinkedRoles = new HashSet(); _roleMappers = new LinkedHashMap(); _initParams = new HashMap(); _portletModes = new HashMap(); _supportedLocales = new HashSet(); _userAttributes = new LinkedHashSet(); _customUserAttributes... | public Portlet() { | public Portlet(PortletPK pk) { setPrimaryKey(pk); setStrutsPath(pk.portletId); setActive(true); _unlinkedRoles = new HashSet(); _roleMappers = new LinkedHashMap(); _initParams = new HashMap(); _portletModes = new HashMap(); _supportedLocales = new HashSet(); _userAttributes = new LinkedHashSet(); _customUser... |
public static String digest(String algorithm, String text) { MessageDigest mDigest = null; try{ mDigest = MessageDigest.getInstance(algorithm); mDigest.update(text.getBytes(ENCODING)); } catch (NoSuchAlgorithmException nsae) { nsae.printStackTrace(); } catch (UnsupportedEncodingException uee) { uee.printStackTrace();... | public static String digest(String text) { return digest(DIGEST_ALGORITHM, text); | public static String digest(String algorithm, String text) { MessageDigest mDigest = null; try{ mDigest = MessageDigest.getInstance(algorithm); mDigest.update(text.getBytes(ENCODING)); } catch (NoSuchAlgorithmException nsae) { nsae.printStackTrace(); } catch (UnsupportedEncodingException uee) { uee.print... |
public void init(ServletConfig sc) throws ServletException { | public void init(ServletConfig config) throws ServletException { | public void init(ServletConfig sc) throws ServletException { synchronized (CMSServlet.class) { super.init(sc); ServletContext ctx = getServletContext(); _companyId = ctx.getInitParameter("company_id"); String redirectsConf = sc.getInitParameter("redirects_conf"); if (redirectsConf != null) { _redirectPro... |
super.init(sc); | super.init(config); | public void init(ServletConfig sc) throws ServletException { synchronized (CMSServlet.class) { super.init(sc); ServletContext ctx = getServletContext(); _companyId = ctx.getInitParameter("company_id"); String redirectsConf = sc.getInitParameter("redirects_conf"); if (redirectsConf != null) { _redirectPro... |
String redirectsConf = sc.getInitParameter("redirects_conf"); | String redirectsConf = config.getInitParameter("redirects_conf"); | public void init(ServletConfig sc) throws ServletException { synchronized (CMSServlet.class) { super.init(sc); ServletContext ctx = getServletContext(); _companyId = ctx.getInitParameter("company_id"); String redirectsConf = sc.getInitParameter("redirects_conf"); if (redirectsConf != null) { _redirectPro... |
sc.getInitParameter("redirects_enabled")); | config.getInitParameter("redirects_enabled")); | public void init(ServletConfig sc) throws ServletException { synchronized (CMSServlet.class) { super.init(sc); ServletContext ctx = getServletContext(); _companyId = ctx.getInitParameter("company_id"); String redirectsConf = sc.getInitParameter("redirects_conf"); if (redirectsConf != null) { _redirectPro... |
clearUsers.clear(userGroupId); | public UserGroup remove(String userGroupId) throws NoSuchUserGroupException, SystemException { Session session = null; try { session = openSession(); UserGroup userGroup = (UserGroup)session.get(UserGroup.class, userGroupId); if (userGroup == null) { _log.warn("No UserGroup exists with the primary key ... | |
setModified(true); | public void setGroupId(String groupId) { if (((groupId == null) && (_groupId != null)) || ((groupId != null) && (_groupId == null)) || ((groupId != null) && (_groupId != null) && !groupId.equals(_groupId))) { if (!XSS_ALLOW_GROUPID) { groupId = XSSUtil.strip(groupId); } _groupId = groupId; setModi... | |
setModified(true); | public void setParentCategoryId(String parentCategoryId) { if (((parentCategoryId == null) && (_parentCategoryId != null)) || ((parentCategoryId != null) && (_parentCategoryId == null)) || ((parentCategoryId != null) && (_parentCategoryId != null) && !parentCategoryId.equals(_parentCategoryId))) { if (!XSS... | |
_log.error(e); | _log.error(StackTraceUtil.getStackTrace(e)); | public void service(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException { ThemeDisplay themeDisplay = null; try { HttpSession ses = req.getSession(); // The servlet accepts commands sent in the format: // connector?Command=&Type=&CurrentFolder=. The servlet then // executes... |
if (dlFolder.isNew() || dlFolder.isModified()) { session = openSession(); if (dlFolder.isNew()) { DLFolder dlFolderModel = new DLFolder(); dlFolderModel.setFolderId(dlFolder.getFolderId()); dlFolderModel.setGroupId(dlFolder.getGroupId()); dlFolderModel.setCompanyId(dlFolder.getCompanyId()); dlFolderModel.setUserId(dlF... | session = openSession(); session.saveOrUpdate(dlFolder); session.flush(); dlFolder.setNew(false); | public com.liferay.portlet.documentlibrary.model.DLFolder update( com.liferay.portlet.documentlibrary.model.DLFolder dlFolder) throws SystemException { Session session = null; try { if (dlFolder.isNew() || dlFolder.isModified()) { session = openSession(); if (dlFolder.isNew()) { DLFolder dlFolderModel ... |
public static MailMessage getMessage(HttpServletRequest req, long messageId) | public static MailMessage getMessage(HttpServletRequest req) | public static MailMessage getMessage(HttpServletRequest req, long messageId) throws ContentException, FolderException, StoreException { HttpSession ses = req.getSession(); MailMessage mailMessage = new MailMessage(); try { MailSessionLock.lock(ses.getId()); IMAPFolder folder = _getFolder(ses); Message messag... |
MailMessage mailMessage = new MailMessage(); | public static MailMessage getMessage(HttpServletRequest req, long messageId) throws ContentException, FolderException, StoreException { HttpSession ses = req.getSession(); MailMessage mailMessage = new MailMessage(); try { MailSessionLock.lock(ses.getId()); IMAPFolder folder = _getFolder(ses); Message messag... | |
IMAPFolder folder = _getFolder(ses); Message message = folder.getMessageByUID(messageId); mailMessage.setMessageId(messageId); mailMessage.setFrom(message.getFrom()[0]); mailMessage.setTo(message.getRecipients(RecipientType.TO)); mailMessage.setCc(message.getRecipients(RecipientType.CC)); mailMessage.setBcc(message.g... | long messageId = getMessageId(ses); if (messageId != -1L) { return getMessage(req, messageId); } else { return null; } | public static MailMessage getMessage(HttpServletRequest req, long messageId) throws ContentException, FolderException, StoreException { HttpSession ses = req.getSession(); MailMessage mailMessage = new MailMessage(); try { MailSessionLock.lock(ses.getId()); IMAPFolder folder = _getFolder(ses); Message messag... |
if (ajaxId != null) { res.setHeader("Ajax-ID", ajaxId); } | public ActionForward execute( ActionMapping mapping, ActionForm form, HttpServletRequest req, HttpServletResponse res) throws Exception { String xml = null; try { xml = getXML(mapping, form, req, res); } catch (Exception e) { res.sendError( HttpServletResponse.SC_INTERNAL_SERVER_ERROR, e.getMessage(... | |
_log.debug("Encode " + path); | if (_log.isDebugEnabled()) { _log.debug("Path " + path); _log.debug("Context path " + _contextPath); _log.debug("Servlet mapping " + _servletMapping); } | public String encodeURL(String path) { _log.debug("Encode " + path); String encodedURL = path; if (path.startsWith(_contextPath + _servletMapping)) { // Struts uses & instead of & to delimit parameter key value // pairs when you set the "name" attribute for html:link. path = StringUtil.replace(path, "&... |
if (path.startsWith(_contextPath + _servletMapping)) { | if (path.startsWith(" path.startsWith(_contextPath + _servletMapping)) { path = StringUtil.replace(path, " | public String encodeURL(String path) { _log.debug("Encode " + path); String encodedURL = path; if (path.startsWith(_contextPath + _servletMapping)) { // Struts uses & instead of & to delimit parameter key value // pairs when you set the "name" attribute for html:link. path = StringUtil.replace(path, "&... |
validateName(null, user.getCompanyId(), name); | validateName(null, user.getActualCompanyId(), name); | public Group addGroup( String userId, String className, String classPK, String name, String friendlyURL) throws PortalException, SystemException { // Group User user = UserUtil.findByPrimaryKey(userId); if (Validator.isNull(className) || Validator.isNull(classPK)) { validateName(null, user.getCompanyId(), na... |
validateFriendlyURL(null, user.getCompanyId(), friendlyURL); | validateFriendlyURL(null, user.getActualCompanyId(), friendlyURL); | public Group addGroup( String userId, String className, String classPK, String name, String friendlyURL) throws PortalException, SystemException { // Group User user = UserUtil.findByPrimaryKey(userId); if (Validator.isNull(className) || Validator.isNull(classPK)) { validateName(null, user.getCompanyId(), na... |
group.setCompanyId(user.getCompanyId()); | group.setCompanyId(user.getActualCompanyId()); | public Group addGroup( String userId, String className, String classPK, String name, String friendlyURL) throws PortalException, SystemException { // Group User user = UserUtil.findByPrimaryKey(userId); if (Validator.isNull(className) || Validator.isNull(classPK)) { validateName(null, user.getCompanyId(), na... |
Layout.PRIVATE + groupId, user.getCompanyId()); | Layout.PRIVATE + groupId, user.getActualCompanyId()); | public Group addGroup( String userId, String className, String classPK, String name, String friendlyURL) throws PortalException, SystemException { // Group User user = UserUtil.findByPrimaryKey(userId); if (Validator.isNull(className) || Validator.isNull(classPK)) { validateName(null, user.getCompanyId(), na... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.