001
014
015 package com.liferay.portal.service;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020 import com.liferay.portal.kernel.util.ReferenceRegistry;
021
022
036 @ProviderType
037 public class AddressServiceUtil {
038
043
044
049 @Deprecated
050 public static com.liferay.portal.model.Address addAddress(
051 java.lang.String className, long classPK, java.lang.String street1,
052 java.lang.String street2, java.lang.String street3,
053 java.lang.String city, java.lang.String zip, long regionId,
054 long countryId, int typeId, boolean mailing, boolean primary)
055 throws com.liferay.portal.kernel.exception.PortalException {
056 return getService()
057 .addAddress(className, classPK, street1, street2, street3,
058 city, zip, regionId, countryId, typeId, mailing, primary);
059 }
060
061 public static com.liferay.portal.model.Address addAddress(
062 java.lang.String className, long classPK, java.lang.String street1,
063 java.lang.String street2, java.lang.String street3,
064 java.lang.String city, java.lang.String zip, long regionId,
065 long countryId, int typeId, boolean mailing, boolean primary,
066 com.liferay.portal.service.ServiceContext serviceContext)
067 throws com.liferay.portal.kernel.exception.PortalException {
068 return getService()
069 .addAddress(className, classPK, street1, street2, street3,
070 city, zip, regionId, countryId, typeId, mailing, primary,
071 serviceContext);
072 }
073
074 public static void deleteAddress(long addressId)
075 throws com.liferay.portal.kernel.exception.PortalException {
076 getService().deleteAddress(addressId);
077 }
078
079 public static com.liferay.portal.model.Address getAddress(long addressId)
080 throws com.liferay.portal.kernel.exception.PortalException {
081 return getService().getAddress(addressId);
082 }
083
084 public static java.util.List<com.liferay.portal.model.Address> getAddresses(
085 java.lang.String className, long classPK)
086 throws com.liferay.portal.kernel.exception.PortalException {
087 return getService().getAddresses(className, classPK);
088 }
089
090
095 public static java.lang.String getBeanIdentifier() {
096 return getService().getBeanIdentifier();
097 }
098
099
104 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
105 getService().setBeanIdentifier(beanIdentifier);
106 }
107
108 public static com.liferay.portal.model.Address updateAddress(
109 long addressId, java.lang.String street1, java.lang.String street2,
110 java.lang.String street3, java.lang.String city, java.lang.String zip,
111 long regionId, long countryId, int typeId, boolean mailing,
112 boolean primary)
113 throws com.liferay.portal.kernel.exception.PortalException {
114 return getService()
115 .updateAddress(addressId, street1, street2, street3, city,
116 zip, regionId, countryId, typeId, mailing, primary);
117 }
118
119 public static AddressService getService() {
120 if (_service == null) {
121 _service = (AddressService)PortalBeanLocatorUtil.locate(AddressService.class.getName());
122
123 ReferenceRegistry.registerReference(AddressServiceUtil.class,
124 "_service");
125 }
126
127 return _service;
128 }
129
130
133 @Deprecated
134 public void setService(AddressService service) {
135 }
136
137 private static AddressService _service;
138 }