org.hibernate.query.ParameterMetadata Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-core Show documentation
Show all versions of hibernate-core Show documentation
The core O/RM functionality as provided by Hibernate
The newest version!
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or .
*/
package org.hibernate.query;
import java.util.Set;
import javax.persistence.Parameter;
/**
* Access to known information about the parameters for a query.
*
* @author Steve Ebersole
*/
public interface ParameterMetadata {
/**
* Does this parameter set contain any named parameters?
*
* @return {@code true} if there are named parameters; {@code false} otherwise.
*/
boolean hasNamedParameters();
/**
* Does this parameter set contain any positional parameters?
*
* @return {@code true} if there are positional parameters; {@code false} otherwise.
*/
boolean hasPositionalParameters();
Set> collectAllParameters();
Set> collectAllParametersJpa();
/**
* Return the names of all named parameters of the query.
*
* @return the parameter names, in no particular order
*/
Set getNamedParameterNames();
/**
* Returns the number of positional parameters.
*
* @return The number of positional parameters.
*/
int getPositionalParameterCount();
QueryParameter getQueryParameter(String name);
QueryParameter getQueryParameter(Integer position);
QueryParameter resolve(Parameter param);
default boolean isOrdinalParametersZeroBased() {
return true;
}
default void setOrdinalParametersZeroBased(boolean isZeroBased) {
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy