NPersistence Reference Guide
Create an instance of TypedQuery for executing a Java Persistence query language statement. The select list of the query must contain only a single item, which must be assignable to the type specified by the resultClass argument.

Namespace: NPersistence
Assembly: NPersistence (in NPersistence.dll) Version: 2.0.0.0 (2.0.0.0)

Syntax

   
 C# 
TypedQuery<T> CreateQuery<T>(
	string qlString,
	Type resultClass
)

Parameters

qlString
String
a Java Persistence query string
resultClass
Type
the type of the query result

Type Parameters

T

Return Value

the new query instance

Exceptions

ExceptionCondition
System..::..ArgumentException if the query string is found to be invalid or if the query result is found to not be assignable to the specified type

See Also