I vote -1 to folding the SerializationContext and DeserializationContext
interfaces into their implementation classes since these interfaces seem to
be part of the interface to the encoding subsystem.

Building subsystem interfaces using java interfaces rather than java
classes helps to reduce the coupling between subsystems. For instance, a
class which implements a subsystem interface may have a method which is of
no concern to other subsystems. If the subsystem spans more than one java
package, the method needs to be public. Then having a separate interface
means that the method need not be exposed to other subsystems. (Granted, if
the subsystem equates to a java package, you can use package scope to
achieve the same ends, but package scope isn't obvious due to the lack of a
keyword to denote it and packages are not ideal for constructing subsystems
since they don't nest.)

Glyn

Reply via email to