> This is definitely an interesting notion, and probably does belong in
> Commons Chain itself.  

Agreed.

> To avoid any backwards compatibility issues, it might be easiest to add a 
> getCommand() method to CatalogFactory that
> does this lookup (that kind of method doesn't really fit into a class
> named CatalogFactory very well ... but its at the correct
> architectural level).

What about a CatalogUtils class (or maybe CommandUtils)?  You could
have  a couple of static methods in there for doing this...

getCommand(String catalogName, String commandName)
getCommand(String catalogCommandPair)
...
etc.

> Regarding syntax, I like the ':' idea, but have only one reservation
> -- what if we later on wanted to implement some sort of URL-ish
> interpretation where the prefix was treated as an access scheme of
> some sort (like "http:" or "ftp:" in a typical URL), and a string like
> "foo:bar:baz" would mean "use access method 'foo' to access catalog
> 'bar', then load command 'baz'.  Perhaps we should reserve for future
> use any string that has more than one ':' in it.
> 

Maybe this wouldn't be an issue with a "Utils" class as mentioned above.  

getCommand(String accessMethod, String catalogName, String commandName)
getCommand(String catalogCommandPair)
getCommand(String catalogCommandPair, String accessMethod)

... or something like this ... you get the picture.


> Craig

sean

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to