Top Description Fields Constructors Methods
com.mysql.cj.xdevapi

public abstract Class FilterableStatement<STMT_T, RES_T>

extends PreparableStatement<RES_T>
implements Statement<STMT_T, RES_T>
Class Inheritance
All Implemented Interfaces
com.mysql.cj.xdevapi.Statement
Known Direct Subclasses
com.mysql.cj.xdevapi.FindStatementImpl, com.mysql.cj.xdevapi.ModifyStatementImpl, com.mysql.cj.xdevapi.RemoveStatementImpl, com.mysql.cj.xdevapi.SelectStatementImpl, com.mysql.cj.xdevapi.UpdateStatementImpl, com.mysql.cj.xdevapi.DeleteStatementImpl
Type Parameters
<STMT_T>
statement interface
<RES_T>
result interface

Abstract class, common to several X DevAPI statement classes.

Field Summary

Modifier and TypeField and Description
protected FilterParams
Inherited from com.mysql.cj.xdevapi.PreparableStatement:
mysqlxSessionpreparedStatepreparedStatementId

Constructor Summary

AccessConstructor and Description
public
FilterableStatement(FilterParams
FilterParams object.
filterParams
)

Constructor.

Method Summary

Modifier and TypeMethod and Description
public STMT_T
bind(String
argument name
argName
,
Object
object to bind
value
)

Overrides default com.mysql.cj.xdevapi.Statement.bind.

Bind the named argument to the given value.

public STMT_T
clearBindings()

Overrides default com.mysql.cj.xdevapi.Statement.clearBindings.

Clear all bindings for this statement.

public boolean

Returns:

true if allowed
isRelational
()

Are relational columns identifiers allowed in this statement?

public STMT_T

Returns:

this statement
limit
(long
maximum rows to process
numberOfRows
)

Add row limit to this statement.

public STMT_T

Returns:

this statement
offset
(long
number of rows to skip
limitOffset
)

Add maximum number of rows to skip before find others.

public STMT_T

Returns:

this statement
orderBy
(String...
sort expressions
sortFields
)

Add sort expressions to this statement.

public STMT_T

Returns:

this statement
sort
(String...
sort expressions
sortFields
)

Add sort expressions to this statement.

public STMT_T

Returns:

this statement
where
(String
expression
searchCondition
)

Add search condition to this statement.

Inherited from com.mysql.cj.xdevapi.PreparableStatement:
deallocatePreparedexecuteexecutePreparedStatementexecuteStatementgetMessageBuildergetPrepareStatementXMessageresetPrepareStatesetReprepareState

Field Detail

filterParamsback to summary
protected FilterParams filterParams

Constructor Detail

FilterableStatementback to summary
public FilterableStatement(FilterParams filterParams)

Constructor.

Parameters
filterParams:FilterParams

FilterParams object.

Method Detail

bindback to summary
public STMT_T bind(String argName, Object value)

Overrides default com.mysql.cj.xdevapi.Statement.bind.

Doc from com.mysql.cj.xdevapi.Statement.bind.

Bind the named argument to the given value.

Parameters
argName:String

argument name

value:Object

object to bind

Returns:STMT_T

this statement

Annotations
@Override
@SuppressWarnings:unchecked
clearBindingsback to summary
public STMT_T clearBindings()

Overrides default com.mysql.cj.xdevapi.Statement.clearBindings.

Doc from com.mysql.cj.xdevapi.Statement.clearBindings.

Clear all bindings for this statement.

Returns:STMT_T

this statement

Annotations
@Override
@SuppressWarnings:unchecked
isRelationalback to summary
public boolean isRelational()

Are relational columns identifiers allowed in this statement?

Returns:boolean

true if allowed

limitback to summary
public STMT_T limit(long numberOfRows)

Add row limit to this statement.

For example, to find only 3 rows:

docs = this.collection.find().orderBy("$._id").limit(3).execute();
Parameters
numberOfRows:long

maximum rows to process

Returns:STMT_T

this statement

Annotations
@SuppressWarnings:unchecked
offsetback to summary
public STMT_T offset(long limitOffset)

Add maximum number of rows to skip before find others.

For example, to skip 2 rows:

docs = this.collection.find().orderBy("$._id").offset(2).execute();
Parameters
limitOffset:long

number of rows to skip

Returns:STMT_T

this statement

Annotations
@SuppressWarnings:unchecked
orderByback to summary
public STMT_T orderBy(String... sortFields)

Add sort expressions to this statement.

DocResult docs = this.collection.find().orderBy("$._id").execute();
docs = this.collection.find().sort("$.x", "$.y").execute();
Parameters
sortFields:String[]

sort expressions

Returns:STMT_T

this statement

Annotations
@SuppressWarnings:unchecked
sortback to summary
public STMT_T sort(String... sortFields)

Add sort expressions to this statement. Synonym to orderBy(String...).

DocResult docs = this.collection.find().orderBy("$._id").execute();
docs = this.collection.find().sort("$.x", "$.y").execute();
Parameters
sortFields:String[]

sort expressions

Returns:STMT_T

this statement

whereback to summary
public STMT_T where(String searchCondition)

Add search condition to this statement.

table.delete().where("age == 13").execute();
Parameters
searchCondition:String

expression

Returns:STMT_T

this statement

Annotations
@SuppressWarnings:unchecked