1
22
23 package com.liferay.portal.service.http;
24
25 import com.liferay.portal.kernel.log.Log;
26 import com.liferay.portal.kernel.log.LogFactoryUtil;
27 import com.liferay.portal.service.AddressServiceUtil;
28
29 import java.rmi.RemoteException;
30
31
81 public class AddressServiceSoap {
82 public static com.liferay.portal.model.AddressSoap addAddress(
83 java.lang.String className, long classPK, java.lang.String street1,
84 java.lang.String street2, java.lang.String street3,
85 java.lang.String city, java.lang.String zip, long regionId,
86 long countryId, int typeId, boolean mailing, boolean primary)
87 throws RemoteException {
88 try {
89 com.liferay.portal.model.Address returnValue = AddressServiceUtil.addAddress(className,
90 classPK, street1, street2, street3, city, zip, regionId,
91 countryId, typeId, mailing, primary);
92
93 return com.liferay.portal.model.AddressSoap.toSoapModel(returnValue);
94 }
95 catch (Exception e) {
96 _log.error(e, e);
97
98 throw new RemoteException(e.getMessage());
99 }
100 }
101
102 public static void deleteAddress(long addressId) throws RemoteException {
103 try {
104 AddressServiceUtil.deleteAddress(addressId);
105 }
106 catch (Exception e) {
107 _log.error(e, e);
108
109 throw new RemoteException(e.getMessage());
110 }
111 }
112
113 public static com.liferay.portal.model.AddressSoap getAddress(
114 long addressId) throws RemoteException {
115 try {
116 com.liferay.portal.model.Address returnValue = AddressServiceUtil.getAddress(addressId);
117
118 return com.liferay.portal.model.AddressSoap.toSoapModel(returnValue);
119 }
120 catch (Exception e) {
121 _log.error(e, e);
122
123 throw new RemoteException(e.getMessage());
124 }
125 }
126
127 public static com.liferay.portal.model.AddressSoap[] getAddresses(
128 java.lang.String className, long classPK) throws RemoteException {
129 try {
130 java.util.List<com.liferay.portal.model.Address> returnValue = AddressServiceUtil.getAddresses(className,
131 classPK);
132
133 return com.liferay.portal.model.AddressSoap.toSoapModels(returnValue);
134 }
135 catch (Exception e) {
136 _log.error(e, e);
137
138 throw new RemoteException(e.getMessage());
139 }
140 }
141
142 public static com.liferay.portal.model.AddressSoap updateAddress(
143 long addressId, java.lang.String street1, java.lang.String street2,
144 java.lang.String street3, java.lang.String city, java.lang.String zip,
145 long regionId, long countryId, int typeId, boolean mailing,
146 boolean primary) throws RemoteException {
147 try {
148 com.liferay.portal.model.Address returnValue = AddressServiceUtil.updateAddress(addressId,
149 street1, street2, street3, city, zip, regionId, countryId,
150 typeId, mailing, primary);
151
152 return com.liferay.portal.model.AddressSoap.toSoapModel(returnValue);
153 }
154 catch (Exception e) {
155 _log.error(e, e);
156
157 throw new RemoteException(e.getMessage());
158 }
159 }
160
161 private static Log _log = LogFactoryUtil.getLog(AddressServiceSoap.class);
162 }