Class ServerPrepareResult
java.lang.Object
org.mariadb.jdbc.internal.util.dao.ServerPrepareResult
- All Implemented Interfaces:
PrepareResult
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ColumnDefinition[]
private boolean
private boolean
private final ColumnDefinition[]
private ColumnType[]
private int
private final String
private int
private Protocol
-
Constructor Summary
ConstructorsConstructorDescriptionServerPrepareResult
(String sql, int statementId, ColumnDefinition[] columns, ColumnDefinition[] parameters, Protocol unProxiedProtocol) PrepareStatement Result object. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Asked if can be deallocate (is not shared in other statement and not in cache) Set deallocate flag to true if so.void
void
Update information after a failover.int
int
getSql()
int
boolean
Increment share counter.void
void
void
-
Field Details
-
columns
-
parameters
-
sql
-
statementId
private int statementId -
parameterTypeHeader
-
unProxiedProtocol
-
isBeingDeallocate
private volatile boolean isBeingDeallocate -
inCache
private volatile boolean inCache
-
-
Constructor Details
-
ServerPrepareResult
public ServerPrepareResult(String sql, int statementId, ColumnDefinition[] columns, ColumnDefinition[] parameters, Protocol unProxiedProtocol) PrepareStatement Result object.- Parameters:
sql
- querystatementId
- server statement Id.columns
- columns informationparameters
- parameters informationunProxiedProtocol
- indicate the protocol on which the prepare has been done
-
-
Method Details
-
resetParameterTypeHeader
public void resetParameterTypeHeader() -
failover
Update information after a failover.- Parameters:
statementId
- new statement IdunProxiedProtocol
- the protocol on which the prepare has been done
-
setAddToCache
public void setAddToCache() -
setRemoveFromCache
public void setRemoveFromCache() -
canBeDeallocate
public boolean canBeDeallocate()Asked if can be deallocate (is not shared in other statement and not in cache) Set deallocate flag to true if so.- Returns:
- true if can be deallocate
-
getParamCount
public int getParamCount()- Specified by:
getParamCount
in interfacePrepareResult
-
getStatementId
public int getStatementId() -
getColumns
-
getParameters
-
getUnProxiedProtocol
-
getSql
- Specified by:
getSql
in interfacePrepareResult
-
getParameterTypeHeader
-