Re: [Simple-support] Using attribute as object ref?
Brought to you by:
niallg
|
From: Niall G. <gal...@ya...> - 2011-04-26 07:02:56
|
Hi, I would copy the cycle strategy and modify it for your own needs. The code is open source so you can just hack your own version in your own package. It should be easy to do. Niall --- On Fri, 22/4/11, Atkins, Brian <Bri...@ne...> wrote: From: Atkins, Brian <Bri...@ne...> Subject: [Simple-support] Using attribute as object ref? To: sim...@li... Received: Friday, 22 April, 2011, 8:45 AM I have a list of objects I declare in a config file that I need to reference elsewhere in the config file. I know I can use the CycleStrategy to do object references, but what I want is to be able to use an attribute as the identity and the reference. For example <config> <site> <site name=”SFO”> <elementA>value</elementA> … etc. </site> </sites> <system name=”hostA”> <site ref=”SFO”/> </system></config From what I can tell, the ID and REF values used in the CycleStrategy are not accessible after deserialization. Is there a way to do this, perhaps with a different strategy? My alternative is to use a different element, <SiteRef name=”SFO”/>, but I’m hoping to use the same element name for clarity. Thanks!Brian Atkins Rapid Response EngineeringNetApp 919-476-5845 Direct ab...@ne... www.netapp.com -----Inline Attachment Follows----- ------------------------------------------------------------------------------ Fulfilling the Lean Software Promise Lean software platforms are now widely adopted and the benefits have been demonstrated beyond question. Learn why your peers are replacing JEE containers with lightweight application servers - and what you can gain from the move. http://p.sf.net/sfu/vmware-sfemails -----Inline Attachment Follows----- _______________________________________________ Simple-support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simple-support |