Tom Anderson <twic@urchin.earth.li> writes:
That seems awfully basic and generic.
I agree. I have defined such general interfaces in the ram.jar,
but you are right that such interfaces are especially useful
when defined in the standard library. I have defined, for example:
public interface Acceptor /* de.dclj.ram.Acceptor */ < Type >
{ public void accept( final Type datum ); }
public interface Add /* de.dclj.ram.Add */< Domain >
{ public void add( final Domain value ); }
public interface Advanceable /* de.dclj.ram.Advanceable */
{ /* Advance to the next state.
The initial state is the state before the first call to this. */
void advance(); }
public interface Calculation /* de.dclj.ram.Calculation */<R,T>
{ R of( T t ); }
public interface Contains /* de.dclj.ram.Contains */
< Domain >
{ boolean contains( Domain value ); }
and so on ...
Sun did not seem to get this idea.
Indeed. I think this is a path which you can go too far down, but there
painful thing to retrofit.