1
19
20 package com.liferay.portal.service.http;
21
22 import com.liferay.portal.kernel.log.Log;
23 import com.liferay.portal.kernel.log.LogFactoryUtil;
24 import com.liferay.portal.service.RegionServiceUtil;
25
26 import java.rmi.RemoteException;
27
28
79 public class RegionServiceSoap {
80 public static com.liferay.portal.model.RegionSoap addRegion(
81 long countryId, java.lang.String regionCode, java.lang.String name,
82 boolean active) throws RemoteException {
83 try {
84 com.liferay.portal.model.Region returnValue = RegionServiceUtil.addRegion(countryId,
85 regionCode, name, active);
86
87 return com.liferay.portal.model.RegionSoap.toSoapModel(returnValue);
88 }
89 catch (Exception e) {
90 _log.error(e, e);
91
92 throw new RemoteException(e.getMessage());
93 }
94 }
95
96 public static com.liferay.portal.model.RegionSoap[] getRegions()
97 throws RemoteException {
98 try {
99 java.util.List<com.liferay.portal.model.Region> returnValue = RegionServiceUtil.getRegions();
100
101 return com.liferay.portal.model.RegionSoap.toSoapModels(returnValue);
102 }
103 catch (Exception e) {
104 _log.error(e, e);
105
106 throw new RemoteException(e.getMessage());
107 }
108 }
109
110 public static com.liferay.portal.model.RegionSoap[] getRegions(
111 long countryId) throws RemoteException {
112 try {
113 java.util.List<com.liferay.portal.model.Region> returnValue = RegionServiceUtil.getRegions(countryId);
114
115 return com.liferay.portal.model.RegionSoap.toSoapModels(returnValue);
116 }
117 catch (Exception e) {
118 _log.error(e, e);
119
120 throw new RemoteException(e.getMessage());
121 }
122 }
123
124 public static com.liferay.portal.model.RegionSoap[] getRegions(
125 boolean active) throws RemoteException {
126 try {
127 java.util.List<com.liferay.portal.model.Region> returnValue = RegionServiceUtil.getRegions(active);
128
129 return com.liferay.portal.model.RegionSoap.toSoapModels(returnValue);
130 }
131 catch (Exception e) {
132 _log.error(e, e);
133
134 throw new RemoteException(e.getMessage());
135 }
136 }
137
138 public static com.liferay.portal.model.RegionSoap[] getRegions(
139 long countryId, boolean active) throws RemoteException {
140 try {
141 java.util.List<com.liferay.portal.model.Region> returnValue = RegionServiceUtil.getRegions(countryId,
142 active);
143
144 return com.liferay.portal.model.RegionSoap.toSoapModels(returnValue);
145 }
146 catch (Exception e) {
147 _log.error(e, e);
148
149 throw new RemoteException(e.getMessage());
150 }
151 }
152
153 public static com.liferay.portal.model.RegionSoap getRegion(long regionId)
154 throws RemoteException {
155 try {
156 com.liferay.portal.model.Region returnValue = RegionServiceUtil.getRegion(regionId);
157
158 return com.liferay.portal.model.RegionSoap.toSoapModel(returnValue);
159 }
160 catch (Exception e) {
161 _log.error(e, e);
162
163 throw new RemoteException(e.getMessage());
164 }
165 }
166
167 private static Log _log = LogFactoryUtil.getLog(RegionServiceSoap.class);
168 }