001
014
015 package com.liferay.portal.service.persistence;
016
017 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
019 import com.liferay.portal.kernel.exception.SystemException;
020 import com.liferay.portal.kernel.util.OrderByComparator;
021 import com.liferay.portal.model.ListType;
022 import com.liferay.portal.service.ServiceContext;
023
024 import java.util.List;
025
026
032 public class ListTypeUtil {
033
036 public static void clearCache() {
037 getPersistence().clearCache();
038 }
039
040
043 public static void clearCache(ListType listType) {
044 getPersistence().clearCache(listType);
045 }
046
047
050 public long countWithDynamicQuery(DynamicQuery dynamicQuery)
051 throws SystemException {
052 return getPersistence().countWithDynamicQuery(dynamicQuery);
053 }
054
055
058 public static List<ListType> findWithDynamicQuery(DynamicQuery dynamicQuery)
059 throws SystemException {
060 return getPersistence().findWithDynamicQuery(dynamicQuery);
061 }
062
063
066 public static List<ListType> findWithDynamicQuery(
067 DynamicQuery dynamicQuery, int start, int end)
068 throws SystemException {
069 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
070 }
071
072
075 public static List<ListType> findWithDynamicQuery(
076 DynamicQuery dynamicQuery, int start, int end,
077 OrderByComparator orderByComparator) throws SystemException {
078 return getPersistence()
079 .findWithDynamicQuery(dynamicQuery, start, end,
080 orderByComparator);
081 }
082
083
086 public static ListType remove(ListType listType) throws SystemException {
087 return getPersistence().remove(listType);
088 }
089
090
093 public static ListType update(ListType listType, boolean merge)
094 throws SystemException {
095 return getPersistence().update(listType, merge);
096 }
097
098
101 public static ListType update(ListType listType, boolean merge,
102 ServiceContext serviceContext) throws SystemException {
103 return getPersistence().update(listType, merge, serviceContext);
104 }
105
106 public static void cacheResult(com.liferay.portal.model.ListType listType) {
107 getPersistence().cacheResult(listType);
108 }
109
110 public static void cacheResult(
111 java.util.List<com.liferay.portal.model.ListType> listTypes) {
112 getPersistence().cacheResult(listTypes);
113 }
114
115 public static com.liferay.portal.model.ListType create(int listTypeId) {
116 return getPersistence().create(listTypeId);
117 }
118
119 public static com.liferay.portal.model.ListType remove(int listTypeId)
120 throws com.liferay.portal.NoSuchListTypeException,
121 com.liferay.portal.kernel.exception.SystemException {
122 return getPersistence().remove(listTypeId);
123 }
124
125 public static com.liferay.portal.model.ListType updateImpl(
126 com.liferay.portal.model.ListType listType, boolean merge)
127 throws com.liferay.portal.kernel.exception.SystemException {
128 return getPersistence().updateImpl(listType, merge);
129 }
130
131 public static com.liferay.portal.model.ListType findByPrimaryKey(
132 int listTypeId)
133 throws com.liferay.portal.NoSuchListTypeException,
134 com.liferay.portal.kernel.exception.SystemException {
135 return getPersistence().findByPrimaryKey(listTypeId);
136 }
137
138 public static com.liferay.portal.model.ListType fetchByPrimaryKey(
139 int listTypeId)
140 throws com.liferay.portal.kernel.exception.SystemException {
141 return getPersistence().fetchByPrimaryKey(listTypeId);
142 }
143
144 public static java.util.List<com.liferay.portal.model.ListType> findByType(
145 java.lang.String type)
146 throws com.liferay.portal.kernel.exception.SystemException {
147 return getPersistence().findByType(type);
148 }
149
150 public static java.util.List<com.liferay.portal.model.ListType> findByType(
151 java.lang.String type, int start, int end)
152 throws com.liferay.portal.kernel.exception.SystemException {
153 return getPersistence().findByType(type, start, end);
154 }
155
156 public static java.util.List<com.liferay.portal.model.ListType> findByType(
157 java.lang.String type, int start, int end,
158 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
159 throws com.liferay.portal.kernel.exception.SystemException {
160 return getPersistence().findByType(type, start, end, orderByComparator);
161 }
162
163 public static com.liferay.portal.model.ListType findByType_First(
164 java.lang.String type,
165 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
166 throws com.liferay.portal.NoSuchListTypeException,
167 com.liferay.portal.kernel.exception.SystemException {
168 return getPersistence().findByType_First(type, orderByComparator);
169 }
170
171 public static com.liferay.portal.model.ListType findByType_Last(
172 java.lang.String type,
173 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
174 throws com.liferay.portal.NoSuchListTypeException,
175 com.liferay.portal.kernel.exception.SystemException {
176 return getPersistence().findByType_Last(type, orderByComparator);
177 }
178
179 public static com.liferay.portal.model.ListType[] findByType_PrevAndNext(
180 int listTypeId, java.lang.String type,
181 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
182 throws com.liferay.portal.NoSuchListTypeException,
183 com.liferay.portal.kernel.exception.SystemException {
184 return getPersistence()
185 .findByType_PrevAndNext(listTypeId, type, orderByComparator);
186 }
187
188 public static java.util.List<com.liferay.portal.model.ListType> findAll()
189 throws com.liferay.portal.kernel.exception.SystemException {
190 return getPersistence().findAll();
191 }
192
193 public static java.util.List<com.liferay.portal.model.ListType> findAll(
194 int start, int end)
195 throws com.liferay.portal.kernel.exception.SystemException {
196 return getPersistence().findAll(start, end);
197 }
198
199 public static java.util.List<com.liferay.portal.model.ListType> findAll(
200 int start, int end,
201 com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
202 throws com.liferay.portal.kernel.exception.SystemException {
203 return getPersistence().findAll(start, end, orderByComparator);
204 }
205
206 public static void removeByType(java.lang.String type)
207 throws com.liferay.portal.kernel.exception.SystemException {
208 getPersistence().removeByType(type);
209 }
210
211 public static void removeAll()
212 throws com.liferay.portal.kernel.exception.SystemException {
213 getPersistence().removeAll();
214 }
215
216 public static int countByType(java.lang.String type)
217 throws com.liferay.portal.kernel.exception.SystemException {
218 return getPersistence().countByType(type);
219 }
220
221 public static int countAll()
222 throws com.liferay.portal.kernel.exception.SystemException {
223 return getPersistence().countAll();
224 }
225
226 public static ListTypePersistence getPersistence() {
227 if (_persistence == null) {
228 _persistence = (ListTypePersistence)PortalBeanLocatorUtil.locate(ListTypePersistence.class.getName());
229 }
230
231 return _persistence;
232 }
233
234 public void setPersistence(ListTypePersistence persistence) {
235 _persistence = persistence;
236 }
237
238 private static ListTypePersistence _persistence;
239 }