Apache JDO Project - [jira] Commented: (JDO-282) Add convenience methods to get

This is Interesting: Free IT Magazines  
Home > Archive > Apache JDO Project > January 2006 > [jira] Commented: (JDO-282) Add convenience methods to get





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author [jira] Commented: (JDO-282) Add convenience methods to get
Matthew T. Adams (JIRA)

2006-01-20, 5:45 pm

[ http://issues.apache.org/jira/brows...action_12363452 ]

Matthew T. Adams commented on JDO-282:
--------------------------------------

In case anyone were wondering, the reason for the "boolean isPreCallback" argument on the getPersistentInstance and getDetachedInstance is that the event enums do not indicate whether the event is a preDetach/preAttach or postDetach/postAttach. The event
enums for everything are only CREATE, LOAD, STORE, etc. instead of POST_CREATE, POST_LOAD, PRE_STORE, etc.

* Should the enums be refactored to include PRE & POST prefixes, or
* should we add a boolean field to the object indicating whether it's a pre- or post-event object, or
* just do nothing and preserve the boolean isPreCallback arguments on the convenience methods?


> Add convenience methods to get persistent instance and detached instance from InstanceLifecycleEvent
> ----------------------------------------------------------------------------------------------------
>
> Key: JDO-282
> URL: http://issues.apache.org/jira/browse/JDO-282
> Project: JDO
> Type: Improvement
> Components: api20
> Reporter: Matthew T. Adams
> Assignee: Matthew T. Adams
> Attachments: InstanceLifecycleEvent.patch
>
> The source and target object differ as to whether they are the persistent or detached instance in class InstanceLifecycleEvent depending upon whether the event object is given in the preDetach, postDetach, preAttach, or postAttach callbacks. I propose

adding two convenience methods that makes it obvious from the API which object the user is getting.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secur...nistrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com