001
014
015 package com.liferay.portal.service.http;
016
017 import com.liferay.portal.kernel.log.Log;
018 import com.liferay.portal.kernel.log.LogFactoryUtil;
019 import com.liferay.portal.service.CountryServiceUtil;
020
021 import java.rmi.RemoteException;
022
023
063 public class CountryServiceSoap {
064 public static com.liferay.portal.model.CountrySoap addCountry(
065 java.lang.String name, java.lang.String a2, java.lang.String a3,
066 java.lang.String number, java.lang.String idd, boolean active)
067 throws RemoteException {
068 try {
069 com.liferay.portal.model.Country returnValue = CountryServiceUtil.addCountry(name,
070 a2, a3, number, idd, active);
071
072 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
073 }
074 catch (Exception e) {
075 _log.error(e, e);
076
077 throw new RemoteException(e.getMessage());
078 }
079 }
080
081 public static com.liferay.portal.model.CountrySoap fetchCountry(
082 long countryId) throws RemoteException {
083 try {
084 com.liferay.portal.model.Country returnValue = CountryServiceUtil.fetchCountry(countryId);
085
086 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
087 }
088 catch (Exception e) {
089 _log.error(e, e);
090
091 throw new RemoteException(e.getMessage());
092 }
093 }
094
095 public static com.liferay.portal.model.CountrySoap fetchCountryByA2(
096 java.lang.String a2) throws RemoteException {
097 try {
098 com.liferay.portal.model.Country returnValue = CountryServiceUtil.fetchCountryByA2(a2);
099
100 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
101 }
102 catch (Exception e) {
103 _log.error(e, e);
104
105 throw new RemoteException(e.getMessage());
106 }
107 }
108
109 public static com.liferay.portal.model.CountrySoap fetchCountryByA3(
110 java.lang.String a3) throws RemoteException {
111 try {
112 com.liferay.portal.model.Country returnValue = CountryServiceUtil.fetchCountryByA3(a3);
113
114 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
115 }
116 catch (Exception e) {
117 _log.error(e, e);
118
119 throw new RemoteException(e.getMessage());
120 }
121 }
122
123 public static com.liferay.portal.model.CountrySoap[] getCountries()
124 throws RemoteException {
125 try {
126 java.util.List<com.liferay.portal.model.Country> returnValue = CountryServiceUtil.getCountries();
127
128 return com.liferay.portal.model.CountrySoap.toSoapModels(returnValue);
129 }
130 catch (Exception e) {
131 _log.error(e, e);
132
133 throw new RemoteException(e.getMessage());
134 }
135 }
136
137 public static com.liferay.portal.model.CountrySoap[] getCountries(
138 boolean active) throws RemoteException {
139 try {
140 java.util.List<com.liferay.portal.model.Country> returnValue = CountryServiceUtil.getCountries(active);
141
142 return com.liferay.portal.model.CountrySoap.toSoapModels(returnValue);
143 }
144 catch (Exception e) {
145 _log.error(e, e);
146
147 throw new RemoteException(e.getMessage());
148 }
149 }
150
151 public static com.liferay.portal.model.CountrySoap getCountry(
152 long countryId) throws RemoteException {
153 try {
154 com.liferay.portal.model.Country returnValue = CountryServiceUtil.getCountry(countryId);
155
156 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
157 }
158 catch (Exception e) {
159 _log.error(e, e);
160
161 throw new RemoteException(e.getMessage());
162 }
163 }
164
165 public static com.liferay.portal.model.CountrySoap getCountryByA2(
166 java.lang.String a2) throws RemoteException {
167 try {
168 com.liferay.portal.model.Country returnValue = CountryServiceUtil.getCountryByA2(a2);
169
170 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
171 }
172 catch (Exception e) {
173 _log.error(e, e);
174
175 throw new RemoteException(e.getMessage());
176 }
177 }
178
179 public static com.liferay.portal.model.CountrySoap getCountryByA3(
180 java.lang.String a3) throws RemoteException {
181 try {
182 com.liferay.portal.model.Country returnValue = CountryServiceUtil.getCountryByA3(a3);
183
184 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
185 }
186 catch (Exception e) {
187 _log.error(e, e);
188
189 throw new RemoteException(e.getMessage());
190 }
191 }
192
193 public static com.liferay.portal.model.CountrySoap getCountryByName(
194 java.lang.String name) throws RemoteException {
195 try {
196 com.liferay.portal.model.Country returnValue = CountryServiceUtil.getCountryByName(name);
197
198 return com.liferay.portal.model.CountrySoap.toSoapModel(returnValue);
199 }
200 catch (Exception e) {
201 _log.error(e, e);
202
203 throw new RemoteException(e.getMessage());
204 }
205 }
206
207 private static Log _log = LogFactoryUtil.getLog(CountryServiceSoap.class);
208 }