1
14
15 package com.liferay.portal.service.http;
16
17 import com.liferay.portal.kernel.log.Log;
18 import com.liferay.portal.kernel.log.LogFactoryUtil;
19 import com.liferay.portal.service.EmailAddressServiceUtil;
20
21 import java.rmi.RemoteException;
22
23
73 public class EmailAddressServiceSoap {
74 public static com.liferay.portal.model.EmailAddressSoap addEmailAddress(
75 java.lang.String className, long classPK, java.lang.String address,
76 int typeId, boolean primary) throws RemoteException {
77 try {
78 com.liferay.portal.model.EmailAddress returnValue = EmailAddressServiceUtil.addEmailAddress(className,
79 classPK, address, typeId, primary);
80
81 return com.liferay.portal.model.EmailAddressSoap.toSoapModel(returnValue);
82 }
83 catch (Exception e) {
84 _log.error(e, e);
85
86 throw new RemoteException(e.getMessage());
87 }
88 }
89
90 public static void deleteEmailAddress(long emailAddressId)
91 throws RemoteException {
92 try {
93 EmailAddressServiceUtil.deleteEmailAddress(emailAddressId);
94 }
95 catch (Exception e) {
96 _log.error(e, e);
97
98 throw new RemoteException(e.getMessage());
99 }
100 }
101
102 public static com.liferay.portal.model.EmailAddressSoap getEmailAddress(
103 long emailAddressId) throws RemoteException {
104 try {
105 com.liferay.portal.model.EmailAddress returnValue = EmailAddressServiceUtil.getEmailAddress(emailAddressId);
106
107 return com.liferay.portal.model.EmailAddressSoap.toSoapModel(returnValue);
108 }
109 catch (Exception e) {
110 _log.error(e, e);
111
112 throw new RemoteException(e.getMessage());
113 }
114 }
115
116 public static com.liferay.portal.model.EmailAddressSoap[] getEmailAddresses(
117 java.lang.String className, long classPK) throws RemoteException {
118 try {
119 java.util.List<com.liferay.portal.model.EmailAddress> returnValue = EmailAddressServiceUtil.getEmailAddresses(className,
120 classPK);
121
122 return com.liferay.portal.model.EmailAddressSoap.toSoapModels(returnValue);
123 }
124 catch (Exception e) {
125 _log.error(e, e);
126
127 throw new RemoteException(e.getMessage());
128 }
129 }
130
131 public static com.liferay.portal.model.EmailAddressSoap updateEmailAddress(
132 long emailAddressId, java.lang.String address, int typeId,
133 boolean primary) throws RemoteException {
134 try {
135 com.liferay.portal.model.EmailAddress returnValue = EmailAddressServiceUtil.updateEmailAddress(emailAddressId,
136 address, typeId, primary);
137
138 return com.liferay.portal.model.EmailAddressSoap.toSoapModel(returnValue);
139 }
140 catch (Exception e) {
141 _log.error(e, e);
142
143 throw new RemoteException(e.getMessage());
144 }
145 }
146
147 private static Log _log = LogFactoryUtil.getLog(EmailAddressServiceSoap.class);
148 }