B
Ben Jessel
I'm looking for a name for my class that reflects what it does. Its a
class with functions that converts data.
For example, my current class is called ArticleValueObjectCreator. It
has a method that converts resultsets to an article value object bean.
I now need to create a method which converts an article related
resultset to xml. In the future I may need one that converts a value
object "bean" to xml.
I'm thinking of refactoring the class now that I need to grow it.
What is the best way of acomplishing good design here?
Would renaming the class to something like ArticleDataCovertor, or
ArticleAdaptor tie in with good programming practice, or would it be
better to split these methods up into different classes ( thus making
each class dependent on a fine range particular technologies ) eg, one
which is xml and jdbc only, another that is xml only.
Are there any design patterns like this that emphasise clean
seperation between technologies. Or am I over-engineering?
Thanks
Ben
class with functions that converts data.
For example, my current class is called ArticleValueObjectCreator. It
has a method that converts resultsets to an article value object bean.
I now need to create a method which converts an article related
resultset to xml. In the future I may need one that converts a value
object "bean" to xml.
I'm thinking of refactoring the class now that I need to grow it.
What is the best way of acomplishing good design here?
Would renaming the class to something like ArticleDataCovertor, or
ArticleAdaptor tie in with good programming practice, or would it be
better to split these methods up into different classes ( thus making
each class dependent on a fine range particular technologies ) eg, one
which is xml and jdbc only, another that is xml only.
Are there any design patterns like this that emphasise clean
seperation between technologies. Or am I over-engineering?
Thanks
Ben