db-jdo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Jdo Wiki] Update of "QueryTests" by MichaelWatzek
Date Fri, 23 Sep 2005 12:11:55 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Jdo Wiki" for change notification.

The following page has been changed by MichaelWatzek:
http://wiki.apache.org/jdo/QueryTests

------------------------------------------------------------------------------
  === New Supported Methods ===
  
  || '''Assertion''' || '''JDOQL''' || '''Testclass''' || '''Comment''' ||
- || '''A14.6.2-46:''' Supported Map methods:[[BR]] - `get(Object)`[[BR]] - `containsKey(Object)`[[BR]]
- `containsValue(Object)` || `...` || `jdoql.methods.`[[BR]]`SupportedMapMethods` || Positive
Test.[[BR]]New pc class required. ||
+ ||<|3> '''A14.6.2-46:''' Supported Map methods:[[BR]] - `get(Object)`[[BR]] - `containsKey(Object)`[[BR]]
- `containsValue(Object)` || '''´get:´'''[[BR]]`SELECT FROM Person` `WHERE phoneNumbers.get('home')
== '1111'` ||<|3> `jdoql.methods.`[[BR]]`SupportedMapMethods` ||<|3> Positive
Test. ||
+ || '''containsKey:´'''[[BR]]`SELECT FROM Person` `WHERE phoneNumbers.containsKey('home')
||
+ || '''´containsValue:´'''[[BR]]`SELECT FROM Person` `WHERE phoneNumbers.get('1111')` ||
  ||<|9> '''A14.6.2-47''': New supported String methods:[[BR]] - `toLowerCase()`[[BR]]
- `toUpperCase()`[[BR]] - `indexOf(String)`[[BR]] - `indexOf(String, int)`[[BR]] - `matches(String)`[[BR]]
- `substring(int)`[[BR]] - `substring(int, int)`[[BR]] - `startsWith()`[[BR]] - `endsWith()`[[BR]]
|| '''`toLowerCase:`'''[[BR]]`SELECT FROM company.Person` `WHERE firstname.toLowerCase() ==
'john'` ||<|9> `jdoql.methods.`[[BR]]`SupportedStringMethods` ||<|9> Positive
test. ||
  || '''`toUpperCase:`'''[[BR]]`SELECT FROM company.Person` `WHERE firstname.toUpperCase()
== 'EMP1FIRST'`||
  || '''`indexOf:`'''[[BR]]`SELECT FROM company.Person` `WHERE firstname.indexOf('First')
== 4` ||
@@ -145, +147 @@

  || '''Assertion''' || '''JDOQL''' || '''Testclass''' || '''Comment''' ||
  ||<|2> '''A14.6.2-42:''' There is no distinction made between character literals and
`String` literals. Single character `String` literals can be used wherever character literals
are permitted. `String` literals are allowed to be delimited by single quote marks or double
quote marks. This allows `String` literal filters to use single quote marks instead of escaped
double quote marks. || '''`valid:`'''[[BR]] `SELECT FROM mylib.PrimitiveTypes` `WHERE stringNull.startsWith('Even')
OR charNotNull == 'O'` ||<|2> `jdoql.`[[BR]]`CharacterAndStringLiterals` ||<|2>
Positive and negative test. ||
  || '''`invalid:`'''[[BR]] `SELECT FROM mylib.PrimitiveTypes` `WHERE stringNull.startsWith('Even')
OR charNotNull == 'O.'` ||
- ||<|2> '''A14.6.2-43:''' Identifiers that are persistent field names or `public final
static` field names are required to be supported by JDO implementations. || '''`field names:`'''[[BR]]
`SELECT FROM company.Person` `VARIABLES String firstname PARAMETERS long personid` ||<|2>
`jdoql.`[[BR]]`IdentifiersEqualFieldNames` ||<|2> Positive test.[[BR]]New static field
required.||
+ ||<|2> '''A14.6.2-43:''' Identifiers that are persistent field names or `public final
static` field names are required to be supported by JDO implementations. || '''`field names:`'''[[BR]]
`SELECT FROM company.Person` `VARIABLES String firstname PARAMETERS long personid` ||<|2>
`jdoql.`[[BR]]`IdentifiersEqualFieldNames` ||<|2> Positive test. ||
- || '''`static field names:`'''[[BR]] `...` ||
+ || '''`static field names:`'''[[BR]] `SELECT FROM fieldtypes.AllTypes WHERE NUM_VALUES ==
10` ||
  || '''A14.6.8-1:''' `setRange(long fromIncl, long toExcl)` || `SELECT lastname FROM company.Person
RANGE 1 TO 10` || `jdoql.`[[BR]]`PositiveRange` || Positive test. ||
  || '''A14.6.8-2:''' If `((toExcl - fromIncl) <= 0)` evaluates to `true`, if the result
of the query execution is a List, the returned List contains no instances, and an Iterator
obtained from the List returns `false` to `hasNext()`. If the result of the query execution
is a single instance `(setUnique(true))`, it will have a value of `null`. || `SELECT lastname
FROM company.Person RANGE 10 TO 1` || `jdoql.`[[BR]]`NegativeRange` || Positive test. ||
  || '''A14.6.8-3:''' `setRange(String range);` || `SELECT lastname FROM company.Person RANGE
1 TO 10` || `jdoql.`[[BR]]`RangeAsString` || Positive test. ||

Mime
View raw message