Daniel Fagerstrom wrote:
If we compare the situation with concepts from Java, my view was:
Java: You download a class with unique combination of name and namespace. Blocks: You download a block with a unique URI.
Java: You call the constuctor of the class possibly with parameters and get an object with an unique object id.
Blocks: You deploy the block and get a block instance with a unique (in your Cocoon) block instance id. During deployment you give it parameter values and connect it to other block instances.
This depends on whether the Java class is a singleton, in which case the constructor is called only when the class is instantiated the first time. The same could be true for blocks as well, if that is desirable. It probably would be more manaageable if the first release required that blocks be singletons and then expand that later if needed. Isn't that basically the way servlets work?
--- o0o ---
I guess that in your view there is no istantiation, you subclass and have everything "static" instead.
Being a singleton doesn't mean that you can't have some initialization.
Both views will solve the same problem but in different ways. With your view we might want to have tool support for automatic subclassing ;)
/Daniel