
javax.persistence.Parameter Maven / Gradle / Ivy
The newest version!
/*
* Copyright 2010 Bull S.A.S.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package javax.persistence;
/**
* Type for query parameter objects.
* @param the type of the parameter
* @see JPA 2.0 specification
* @author Florent Benoit
* @since JPA 2.0 version.
*/
public interface Parameter {
/**
* Return the parameter name, or null if the parameter is not a named parameter or no name has been assigned.
* @return parameter name
*/
String getName();
/**
* Return the parameter position, or null if the parameter is not a positional parameter.
* @return position of parameter
*/
Integer getPosition();
/**
* Return the Java type of the parameter. Values bound to the parameter must be assignable to this type. This method is
* required to be supported for criteria queries only. Applications that use this method for Java Persistence query language
* queries and native queries will not be portable.
* @return the Java type of the parameter
* @throws IllegalStateException if invoked on a parameter obtained from a Java persistence query language query or native
* query when the implementation does not support this use
*/
Class getParameterType();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy