P is for Practical | |
PerlMonks |
Re^4: An Object Structural Design Pattern in Perlby hypochrismutreefuzz (Scribe) |
on Dec 10, 2007 at 19:54 UTC ( [id://656208]=note: print w/replies, xml ) | Need Help?? |
I feel embarrased to admit that I hadn't tested the code myself. After testing and debugging I decided to simplify the design and change the way the method calls are dispatched.
This snippet of client code instantiates a Serializer object with a method_map that maps "serialize" with "XMLout" and "deserialize" with "XMLin" using the options given to override the default options of XML::Simple.
This snippet of client code does the same thing using YAML as the serialization interface. Client code for either serializer object would be identical.
In Section
Meditations
|
|