[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-3512) Registration of IdentifierGenerators (short naming)

Steve Ebersole (JIRA) noreply at atlassian.com
Wed Oct 22 10:37:05 EDT 2008


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-3512?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=31497#action_31497 ] 

Steve Ebersole commented on HHH-3512:
-------------------------------------

http://opensource.atlassian.com/projects/hibernate/browse/HHH-3512?page=com.atlassian.jira.ext.fisheye%3Afisheye-issuepanel

> Registration of IdentifierGenerators (short naming)
> ---------------------------------------------------
>
>                 Key: HHH-3512
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-3512
>             Project: Hibernate Core
>          Issue Type: New Feature
>          Components: core, metamodel
>            Reporter: Steve Ebersole
>            Assignee: Steve Ebersole
>             Fix For: 3.4, 4.x
>
>
> Another way to look  at this is to allow configuration of IdentifierGeneratorFactory.
> Either allow explicit registration under a short name in config:
> <identifier-generator name="sequence-style" class="org.hibernate.id.enhanced.SequenceStyleGenerator"/>
> or via an explicit contract:
> public interface Registerable {
>     public String getRegistrationName();
> }
> public class SequenceStyleGenerator implements IdentifierGenerator, Registerable {
>     ...
>     public String getRegistrationName() {
>         return "sequence-style";
>     }
> }
> The second, while certainly more verbose, can be used applied to other situations where we want to allow registration moving forward (types, property-accessor, etc).

-- 
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.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list