|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openswing.swing.util.server.CayenneUtils
Title: OpenSwing Framework
Description: Helper class containing some utility methods useful when retrieving data for a grid.
Copyright: Copyright (C) 2006 Mauro Carniel
This file is part of OpenSwing Framework. This library is free software; you can redistribute it and/or modify it under the terms of the (LGPL) Lesser General Public License as published by the Free Software Foundation; GNU LESSER GENERAL PUBLIC LICENSE Version 2.1, February 1999 This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. The author may be contacted at: maurocarniel@tin.it
Constructor Summary | |
CayenneUtils()
|
Method Summary | |
static org.apache.cayenne.query.SelectQuery |
applyFiltersAndSorter(java.util.Map filteredColumns,
java.util.ArrayList currentSortedColumns,
java.util.ArrayList currentSortedVersusColumns,
org.apache.cayenne.query.SelectQuery query,
java.util.Map additionalConditions,
org.apache.cayenne.access.DataContext context)
Apply filtering and sorting conditions to the specified base select query and return a new query that contains those conditions too. |
static Response |
getAllFromQuery(java.util.Map filteredColumns,
java.util.ArrayList currentSortedColumns,
java.util.ArrayList currentSortedVersusColumns,
java.lang.Class valueObjectType,
org.apache.cayenne.query.SelectQuery query,
java.util.Map additionalConditions,
org.apache.cayenne.access.DataContext context)
Read the whole result set, by applying filtering and sorting conditions + query parameters. |
static Response |
getBlockFromQuery(int action,
int startIndex,
int blockSize,
java.util.Map filteredColumns,
java.util.ArrayList currentSortedColumns,
java.util.ArrayList currentSortedVersusColumns,
org.apache.cayenne.query.SelectQuery query,
java.util.Map additionalConditions,
org.apache.cayenne.access.DataContext context)
Read a block of records from the result set, by applying filtering and sorting conditions + query parameters. |
static Response |
getBlockFromQuery(int action,
int startIndex,
int blockSize,
org.apache.cayenne.query.SelectQuery query,
org.apache.cayenne.access.DataContext context)
Read a block of records from the result set, starting from a Query object. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CayenneUtils()
Method Detail |
public static org.apache.cayenne.query.SelectQuery applyFiltersAndSorter(java.util.Map filteredColumns, java.util.ArrayList currentSortedColumns, java.util.ArrayList currentSortedVersusColumns, org.apache.cayenne.query.SelectQuery query, java.util.Map additionalConditions, org.apache.cayenne.access.DataContext context) throws java.lang.Exception
filteredColumns
- filtering conditionscurrentSortedColumns
- sorting conditions (attribute names)currentSortedVersusColumns
- sorting conditions (order versus)query
- Cayenne SelectQuery objectadditionalConditions
- conditions expressed as context
- Cayenne data context
java.lang.Exception
public static Response getAllFromQuery(java.util.Map filteredColumns, java.util.ArrayList currentSortedColumns, java.util.ArrayList currentSortedVersusColumns, java.lang.Class valueObjectType, org.apache.cayenne.query.SelectQuery query, java.util.Map additionalConditions, org.apache.cayenne.access.DataContext context) throws java.lang.Exception
filteredColumns
- filtering conditionscurrentSortedColumns
- sorting conditions (attribute names)currentSortedVersusColumns
- sorting conditions (order versus)valueObjectType
- value object typequery
- Cayenne SelectQuery objectadditionalConditions
- conditions expressed as context
- Cayenne data context
java.lang.Exception
public static Response getBlockFromQuery(int action, int startIndex, int blockSize, java.util.Map filteredColumns, java.util.ArrayList currentSortedColumns, java.util.ArrayList currentSortedVersusColumns, org.apache.cayenne.query.SelectQuery query, java.util.Map additionalConditions, org.apache.cayenne.access.DataContext context) throws java.lang.Exception
action
- fetching versus: PREVIOUS_BLOCK_ACTION, NEXT_BLOCK_ACTION or LAST_BLOCK_ACTIONblockSize
- number of records to readfilteredColumns
- filtering conditionscurrentSortedColumns
- sorting conditions (attribute names)currentSortedVersusColumns
- sorting conditions (order versus)query
- Cayenne SelectQuery objectadditionalConditions
- conditions expressed as context
- Cayenne data context
java.lang.Exception
public static Response getBlockFromQuery(int action, int startIndex, int blockSize, org.apache.cayenne.query.SelectQuery query, org.apache.cayenne.access.DataContext context) throws java.lang.Exception
action
- fetching versus: PREVIOUS_BLOCK_ACTION, NEXT_BLOCK_ACTION or LAST_BLOCK_ACTIONblockSize
- number of records to readquery
- Query objectcontext
- Cayenne data context
java.lang.Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |