1
22
23 package com.liferay.portal.service.persistence;
24
25
31 public class ResourceUtil {
32 public static com.liferay.portal.model.Resource create(long resourceId) {
33 return getPersistence().create(resourceId);
34 }
35
36 public static com.liferay.portal.model.Resource remove(long resourceId)
37 throws com.liferay.portal.NoSuchResourceException,
38 com.liferay.portal.SystemException {
39 return getPersistence().remove(resourceId);
40 }
41
42 public static com.liferay.portal.model.Resource remove(
43 com.liferay.portal.model.Resource resource)
44 throws com.liferay.portal.SystemException {
45 return getPersistence().remove(resource);
46 }
47
48
51 public static com.liferay.portal.model.Resource update(
52 com.liferay.portal.model.Resource resource)
53 throws com.liferay.portal.SystemException {
54 return getPersistence().update(resource);
55 }
56
57
70 public static com.liferay.portal.model.Resource update(
71 com.liferay.portal.model.Resource resource, boolean merge)
72 throws com.liferay.portal.SystemException {
73 return getPersistence().update(resource, merge);
74 }
75
76 public static com.liferay.portal.model.Resource updateImpl(
77 com.liferay.portal.model.Resource resource, boolean merge)
78 throws com.liferay.portal.SystemException {
79 return getPersistence().updateImpl(resource, merge);
80 }
81
82 public static com.liferay.portal.model.Resource findByPrimaryKey(
83 long resourceId)
84 throws com.liferay.portal.NoSuchResourceException,
85 com.liferay.portal.SystemException {
86 return getPersistence().findByPrimaryKey(resourceId);
87 }
88
89 public static com.liferay.portal.model.Resource fetchByPrimaryKey(
90 long resourceId) throws com.liferay.portal.SystemException {
91 return getPersistence().fetchByPrimaryKey(resourceId);
92 }
93
94 public static java.util.List<com.liferay.portal.model.Resource> findByCodeId(
95 long codeId) throws com.liferay.portal.SystemException {
96 return getPersistence().findByCodeId(codeId);
97 }
98
99 public static java.util.List<com.liferay.portal.model.Resource> findByCodeId(
100 long codeId, int start, int end)
101 throws com.liferay.portal.SystemException {
102 return getPersistence().findByCodeId(codeId, start, end);
103 }
104
105 public static java.util.List<com.liferay.portal.model.Resource> findByCodeId(
106 long codeId, int start, int end,
107 com.liferay.portal.kernel.util.OrderByComparator obc)
108 throws com.liferay.portal.SystemException {
109 return getPersistence().findByCodeId(codeId, start, end, obc);
110 }
111
112 public static com.liferay.portal.model.Resource findByCodeId_First(
113 long codeId, com.liferay.portal.kernel.util.OrderByComparator obc)
114 throws com.liferay.portal.NoSuchResourceException,
115 com.liferay.portal.SystemException {
116 return getPersistence().findByCodeId_First(codeId, obc);
117 }
118
119 public static com.liferay.portal.model.Resource findByCodeId_Last(
120 long codeId, com.liferay.portal.kernel.util.OrderByComparator obc)
121 throws com.liferay.portal.NoSuchResourceException,
122 com.liferay.portal.SystemException {
123 return getPersistence().findByCodeId_Last(codeId, obc);
124 }
125
126 public static com.liferay.portal.model.Resource[] findByCodeId_PrevAndNext(
127 long resourceId, long codeId,
128 com.liferay.portal.kernel.util.OrderByComparator obc)
129 throws com.liferay.portal.NoSuchResourceException,
130 com.liferay.portal.SystemException {
131 return getPersistence().findByCodeId_PrevAndNext(resourceId, codeId, obc);
132 }
133
134 public static com.liferay.portal.model.Resource findByC_P(long codeId,
135 java.lang.String primKey)
136 throws com.liferay.portal.NoSuchResourceException,
137 com.liferay.portal.SystemException {
138 return getPersistence().findByC_P(codeId, primKey);
139 }
140
141 public static com.liferay.portal.model.Resource fetchByC_P(long codeId,
142 java.lang.String primKey) throws com.liferay.portal.SystemException {
143 return getPersistence().fetchByC_P(codeId, primKey);
144 }
145
146 public static java.util.List<Object> findWithDynamicQuery(
147 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
148 throws com.liferay.portal.SystemException {
149 return getPersistence().findWithDynamicQuery(dynamicQuery);
150 }
151
152 public static java.util.List<Object> findWithDynamicQuery(
153 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
154 int end) throws com.liferay.portal.SystemException {
155 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
156 }
157
158 public static java.util.List<com.liferay.portal.model.Resource> findAll()
159 throws com.liferay.portal.SystemException {
160 return getPersistence().findAll();
161 }
162
163 public static java.util.List<com.liferay.portal.model.Resource> findAll(
164 int start, int end) throws com.liferay.portal.SystemException {
165 return getPersistence().findAll(start, end);
166 }
167
168 public static java.util.List<com.liferay.portal.model.Resource> findAll(
169 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
170 throws com.liferay.portal.SystemException {
171 return getPersistence().findAll(start, end, obc);
172 }
173
174 public static void removeByCodeId(long codeId)
175 throws com.liferay.portal.SystemException {
176 getPersistence().removeByCodeId(codeId);
177 }
178
179 public static void removeByC_P(long codeId, java.lang.String primKey)
180 throws com.liferay.portal.NoSuchResourceException,
181 com.liferay.portal.SystemException {
182 getPersistence().removeByC_P(codeId, primKey);
183 }
184
185 public static void removeAll() throws com.liferay.portal.SystemException {
186 getPersistence().removeAll();
187 }
188
189 public static int countByCodeId(long codeId)
190 throws com.liferay.portal.SystemException {
191 return getPersistence().countByCodeId(codeId);
192 }
193
194 public static int countByC_P(long codeId, java.lang.String primKey)
195 throws com.liferay.portal.SystemException {
196 return getPersistence().countByC_P(codeId, primKey);
197 }
198
199 public static int countAll() throws com.liferay.portal.SystemException {
200 return getPersistence().countAll();
201 }
202
203 public static ResourcePersistence getPersistence() {
204 return _persistence;
205 }
206
207 public void setPersistence(ResourcePersistence persistence) {
208 _persistence = persistence;
209 }
210
211 private static ResourcePersistence _persistence;
212 }