|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object info.magnolia.cms.util.QueryUtil
public class QueryUtil
Util to execute queries as simple as possible.
Constructor Summary | |
---|---|
QueryUtil()
|
Method Summary | |
---|---|
static String |
createDateExpression(Calendar calendar)
Expression representing a date. |
static String |
createDateExpression(int year,
int month,
int day)
|
static String |
createDateTimeExpression(Calendar calendar)
Expression representing a date and time. |
static String |
createDateTimeExpression(int year,
int month,
int day,
int hour,
int minutes,
int seconds)
|
static String |
createDateTimeExpressionIgnoreTimeZone(Calendar calendar)
Do not consider the timezone. |
static String |
createDateTimeExpressionIgnoreTimeZone(int year,
int month,
int day,
int hour,
int minutes,
int seconds)
|
static Collection<Content> |
exceptionThrowingQuery(String repository,
String statement,
String language,
String returnItemType)
|
static Collection<Content> |
exceptionThrowingQuery(String repository,
String statement,
String language,
String returnItemType,
long maxResultSize)
Executes a query, throwing any exceptions that arise as a result. |
static Collection<Content> |
query(String repository,
String statement)
Executes a query. |
static Collection<Content> |
query(String repository,
String statement,
String language)
Executes a query. |
static Collection<Content> |
query(String repository,
String statement,
String language,
String returnItemType)
|
static Collection<Content> |
query(String repository,
String statement,
String language,
String returnItemType,
long maxResultSize)
Executes a query - if an exception is thrown, it is logged and an empty collection is returned. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public QueryUtil()
Method Detail |
---|
public static Collection<Content> query(String repository, String statement)
public static Collection<Content> query(String repository, String statement, String language)
public static Collection<Content> exceptionThrowingQuery(String repository, String statement, String language, String returnItemType) throws javax.jcr.RepositoryException
javax.jcr.RepositoryException
public static Collection<Content> exceptionThrowingQuery(String repository, String statement, String language, String returnItemType, long maxResultSize) throws javax.jcr.RepositoryException
javax.jcr.RepositoryException
public static Collection<Content> query(String repository, String statement, String language, String returnItemType)
public static Collection<Content> query(String repository, String statement, String language, String returnItemType, long maxResultSize)
public static String createDateExpression(int year, int month, int day)
month
- 1-12 (as opposed to java.util.Calendar 0-11 notation)public static String createDateExpression(Calendar calendar)
public static String createDateTimeExpression(int year, int month, int day, int hour, int minutes, int seconds)
month
- 1-12 (as opposed to java.util.Calendar 0-11 notation)public static String createDateTimeExpression(Calendar calendar)
public static String createDateTimeExpressionIgnoreTimeZone(int year, int month, int day, int hour, int minutes, int seconds)
month
- 1-12 (as opposed to java.util.Calendar 0-11 notation)public static String createDateTimeExpressionIgnoreTimeZone(Calendar calendar)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |