001
014
015 package com.liferay.portal.service;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.util.ReferenceRegistry;
019
020
033 public class AddressServiceUtil {
034
039
040
045 public static java.lang.String getBeanIdentifier() {
046 return getService().getBeanIdentifier();
047 }
048
049
054 public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055 getService().setBeanIdentifier(beanIdentifier);
056 }
057
058 public static com.liferay.portal.model.Address addAddress(
059 java.lang.String className, long classPK, java.lang.String street1,
060 java.lang.String street2, java.lang.String street3,
061 java.lang.String city, java.lang.String zip, long regionId,
062 long countryId, int typeId, boolean mailing, boolean primary)
063 throws com.liferay.portal.kernel.exception.PortalException,
064 com.liferay.portal.kernel.exception.SystemException {
065 return getService()
066 .addAddress(className, classPK, street1, street2, street3,
067 city, zip, regionId, countryId, typeId, mailing, primary);
068 }
069
070 public static void deleteAddress(long addressId)
071 throws com.liferay.portal.kernel.exception.PortalException,
072 com.liferay.portal.kernel.exception.SystemException {
073 getService().deleteAddress(addressId);
074 }
075
076 public static com.liferay.portal.model.Address getAddress(long addressId)
077 throws com.liferay.portal.kernel.exception.PortalException,
078 com.liferay.portal.kernel.exception.SystemException {
079 return getService().getAddress(addressId);
080 }
081
082 public static java.util.List<com.liferay.portal.model.Address> getAddresses(
083 java.lang.String className, long classPK)
084 throws com.liferay.portal.kernel.exception.PortalException,
085 com.liferay.portal.kernel.exception.SystemException {
086 return getService().getAddresses(className, classPK);
087 }
088
089 public static com.liferay.portal.model.Address updateAddress(
090 long addressId, java.lang.String street1, java.lang.String street2,
091 java.lang.String street3, java.lang.String city, java.lang.String zip,
092 long regionId, long countryId, int typeId, boolean mailing,
093 boolean primary)
094 throws com.liferay.portal.kernel.exception.PortalException,
095 com.liferay.portal.kernel.exception.SystemException {
096 return getService()
097 .updateAddress(addressId, street1, street2, street3, city,
098 zip, regionId, countryId, typeId, mailing, primary);
099 }
100
101 public static AddressService getService() {
102 if (_service == null) {
103 _service = (AddressService)PortalBeanLocatorUtil.locate(AddressService.class.getName());
104
105 ReferenceRegistry.registerReference(AddressServiceUtil.class,
106 "_service");
107 }
108
109 return _service;
110 }
111
112
115 public void setService(AddressService service) {
116 }
117
118 private static AddressService _service;
119 }