Andy Clark wrote:
> > Method: I don't see a need for this class. If all it's doing > is holding string constants, then I would say get rid of it > completely. Otherwise, make it a Java "enumeration", like so: > > I'm having the exact thoughts but I didn't articulate them well in my last email. In addition, the current designe of Method is a final class which does not allow for future extensions. > > But I think that we could do without it altogether and just > make it possible to register new methods with the serializer > factory. But I'll get to that in a minute. > > And the type of the method could be the mime type which would > avoid the need of a set/getMediaType on the OutputFormat object. > And if this thing is really representing the mime type, perhaps > it should be called such instead of "Method". It would tie in > better with existing standards. I feel "MimeType" is a better choice. "Media" would include "screen", "braille", "aural" etc. from the CSS2 specs. In this case, serialisation only support "print".
