1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
17   * SOFTWARE.
18   */
19  
20  package com.liferay.portlet.expando.service.persistence;
21  
22  import com.liferay.portal.service.persistence.BasePersistence;
23  
24  /**
25   * <a href="ExpandoColumnPersistence.java.html"><b><i>View Source</i></b></a>
26   *
27   * @author Brian Wing Shun Chan
28   *
29   */
30  public interface ExpandoColumnPersistence extends BasePersistence {
31      public void cacheResult(
32          com.liferay.portlet.expando.model.ExpandoColumn expandoColumn);
33  
34      public void cacheResult(
35          java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> expandoColumns);
36  
37      public void clearCache();
38  
39      public com.liferay.portlet.expando.model.ExpandoColumn create(long columnId);
40  
41      public com.liferay.portlet.expando.model.ExpandoColumn remove(long columnId)
42          throws com.liferay.portal.SystemException,
43              com.liferay.portlet.expando.NoSuchColumnException;
44  
45      public com.liferay.portlet.expando.model.ExpandoColumn remove(
46          com.liferay.portlet.expando.model.ExpandoColumn expandoColumn)
47          throws com.liferay.portal.SystemException;
48  
49      /**
50       * @deprecated Use <code>update(ExpandoColumn expandoColumn, boolean merge)</code>.
51       */
52      public com.liferay.portlet.expando.model.ExpandoColumn update(
53          com.liferay.portlet.expando.model.ExpandoColumn expandoColumn)
54          throws com.liferay.portal.SystemException;
55  
56      /**
57       * Add, update, or merge, the entity. This method also calls the model
58       * listeners to trigger the proper events associated with adding, deleting,
59       * or updating an entity.
60       *
61       * @param        expandoColumn the entity to add, update, or merge
62       * @param        merge boolean value for whether to merge the entity. The
63       *                default value is false. Setting merge to true is more
64       *                expensive and should only be true when expandoColumn is
65       *                transient. See LEP-5473 for a detailed discussion of this
66       *                method.
67       * @return        true if the portlet can be displayed via Ajax
68       */
69      public com.liferay.portlet.expando.model.ExpandoColumn update(
70          com.liferay.portlet.expando.model.ExpandoColumn expandoColumn,
71          boolean merge) throws com.liferay.portal.SystemException;
72  
73      public com.liferay.portlet.expando.model.ExpandoColumn updateImpl(
74          com.liferay.portlet.expando.model.ExpandoColumn expandoColumn,
75          boolean merge) throws com.liferay.portal.SystemException;
76  
77      public com.liferay.portlet.expando.model.ExpandoColumn findByPrimaryKey(
78          long columnId)
79          throws com.liferay.portal.SystemException,
80              com.liferay.portlet.expando.NoSuchColumnException;
81  
82      public com.liferay.portlet.expando.model.ExpandoColumn fetchByPrimaryKey(
83          long columnId) throws com.liferay.portal.SystemException;
84  
85      public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findByTableId(
86          long tableId) throws com.liferay.portal.SystemException;
87  
88      public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findByTableId(
89          long tableId, int start, int end)
90          throws com.liferay.portal.SystemException;
91  
92      public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findByTableId(
93          long tableId, int start, int end,
94          com.liferay.portal.kernel.util.OrderByComparator obc)
95          throws com.liferay.portal.SystemException;
96  
97      public com.liferay.portlet.expando.model.ExpandoColumn findByTableId_First(
98          long tableId, com.liferay.portal.kernel.util.OrderByComparator obc)
99          throws com.liferay.portal.SystemException,
100             com.liferay.portlet.expando.NoSuchColumnException;
101 
102     public com.liferay.portlet.expando.model.ExpandoColumn findByTableId_Last(
103         long tableId, com.liferay.portal.kernel.util.OrderByComparator obc)
104         throws com.liferay.portal.SystemException,
105             com.liferay.portlet.expando.NoSuchColumnException;
106 
107     public com.liferay.portlet.expando.model.ExpandoColumn[] findByTableId_PrevAndNext(
108         long columnId, long tableId,
109         com.liferay.portal.kernel.util.OrderByComparator obc)
110         throws com.liferay.portal.SystemException,
111             com.liferay.portlet.expando.NoSuchColumnException;
112 
113     public com.liferay.portlet.expando.model.ExpandoColumn findByT_N(
114         long tableId, java.lang.String name)
115         throws com.liferay.portal.SystemException,
116             com.liferay.portlet.expando.NoSuchColumnException;
117 
118     public com.liferay.portlet.expando.model.ExpandoColumn fetchByT_N(
119         long tableId, java.lang.String name)
120         throws com.liferay.portal.SystemException;
121 
122     public com.liferay.portlet.expando.model.ExpandoColumn fetchByT_N(
123         long tableId, java.lang.String name, boolean retrieveFromCache)
124         throws com.liferay.portal.SystemException;
125 
126     public java.util.List<Object> findWithDynamicQuery(
127         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
128         throws com.liferay.portal.SystemException;
129 
130     public java.util.List<Object> findWithDynamicQuery(
131         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
132         int end) throws com.liferay.portal.SystemException;
133 
134     public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findAll()
135         throws com.liferay.portal.SystemException;
136 
137     public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findAll(
138         int start, int end) throws com.liferay.portal.SystemException;
139 
140     public java.util.List<com.liferay.portlet.expando.model.ExpandoColumn> findAll(
141         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
142         throws com.liferay.portal.SystemException;
143 
144     public void removeByTableId(long tableId)
145         throws com.liferay.portal.SystemException;
146 
147     public void removeByT_N(long tableId, java.lang.String name)
148         throws com.liferay.portal.SystemException,
149             com.liferay.portlet.expando.NoSuchColumnException;
150 
151     public void removeAll() throws com.liferay.portal.SystemException;
152 
153     public int countByTableId(long tableId)
154         throws com.liferay.portal.SystemException;
155 
156     public int countByT_N(long tableId, java.lang.String name)
157         throws com.liferay.portal.SystemException;
158 
159     public int countAll() throws com.liferay.portal.SystemException;
160 }