org.hibernate.engine.query.sql

Class NativeSQLQueryRootReturn

Implemented Interfaces:
NativeSQLQueryReturn, Serializable

public class NativeSQLQueryRootReturn
extends NativeSQLQueryNonScalarReturn

Represents a return defined as part of a native sql query which names a "root" entity. A root entity means it is explicitly a "column" in the result, as opposed to a fetched relationship or role.
Author:
Steve Ebersole

Constructor Summary

NativeSQLQueryRootReturn(String alias, String entityName, Map propertyResults, LockMode lockMode)
NativeSQLQueryRootReturn(String alias, String entityName, LockMode lockMode)
Construct a return representing an entity returned at the root of the result.

Method Summary

String
getReturnEntityName()
The name of the entity to be returned.

Methods inherited from class org.hibernate.engine.query.sql.NativeSQLQueryNonScalarReturn

getAlias, getLockMode, getPropertyResultsMap

Constructor Details

NativeSQLQueryRootReturn

public NativeSQLQueryRootReturn(String alias,
                                String entityName,
                                Map propertyResults,
                                LockMode lockMode)
Parameters:
alias - The result alias
entityName - The entity name.
propertyResults - Any user-supplied column->property mappings
lockMode - The lock mode to apply

NativeSQLQueryRootReturn

public NativeSQLQueryRootReturn(String alias,
                                String entityName,
                                LockMode lockMode)
Construct a return representing an entity returned at the root of the result.
Parameters:
alias - The result alias
entityName - The entity name.
lockMode - The lock mode to apply

Method Details

getReturnEntityName

public String getReturnEntityName()
The name of the entity to be returned.
Returns:
The entity name