[
http://opensource.atlassian.com/projects/hibernate/browse/HBX-881?page=co...
]
Joseph Marques commented on HBX-881:
------------------------------------
Originally posted at:
http://jira.jboss.com/jira/browse/JBIDE-440
Enable first-class support of Enum types in the Query Parameters
view
---------------------------------------------------------------------
Key: HBX-881
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HBX-881
Project: Hibernate Tools
Type: New Feature
Versions: 3.2beta8
Reporter: Joseph Marques
Granted, Enums are persisted as either ints or strings, but that doesn't mean that
the Query Parameters view can't support Enums as a first-class construct in the Type
column. I suppose there are a few different ways to support this, but let me explain the
semantics that I think would make the most sense for supreme usability:
Select "enum" for the "Type" column
Then you specify the class in the "Value" column (identical to how it works
when "class" is selected for the "Type" column)
Then, the tools should be able to be clever enough to read the mapping strategy for this
enum based on the context of where it is being used in the corresponding hql/jpql
statement. The tools would then map the Enum class to it's appropriate int or string
representation during query translation / execution. This allows the query writer to be
more effective because he/she wouldn't have to know the actual enum mapping strategy
to be able to mock up and test the query.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira