- All Implemented Interfaces:
Query
, org.cactoos.Text
public final class MaxRows
extends Object
implements Query
Max rows per query.
- Since:
- 0.1
-
Constructor Summary
Constructors
-
Method Summary
Create a PreparedStatement.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
MaxRows
public MaxRows(Query query,
int max)
Ctor.
- Parameters:
query
- The SQL query
max
- The max number of rows
-
Method Details
-
prepared
Description copied from interface: Query
Create a PreparedStatement.
- Specified by:
prepared
in interface Query
- Parameters:
connection
- A connection to the DataSource
- Returns:
- A PreparedStatement
- Throws:
Exception
- If fails
-
asString
- Specified by:
asString
in interface org.cactoos.Text
- Throws:
Exception