[API] What should happen if ...

If a "not making sense" (aspect, property) combination (being 'aspect' and 'property' two recognized elements of a vocabulary) is used for invoking the API, example

Service.getPropertyValue('http://www.w3.org/2008/01/ddr-core-vocabulary', 'webBrowser', 'inputDevices');

Possibilties:

a) NOT_KNOWN exception thrown
b) Aspect not recognized exception thrown, however the aspect actually is a valid aspect for that vocabulary
c) Property not recognized exception thrown, however the property actually is a valid property for that vocabulary

I'm more inclined to say a), however the point is that the combination of aspect & property is not a valid (legal), according to the DDR Core Vocabulary.

I think that an implementation should throw a NAME_EXCEPTION with an error code saying "Aspect, Property combination not valid"

What do others think?

Best Regards

Received on Monday, 2 June 2008 15:51:58 UTC