universAAL / middleware

The core software that uses semantic matchmaking for brokering messages among participants of an open distributed system.
10 stars 3 forks source link

isWellFormed() needs to properly manage multivalue properties, for core classes. #506

Open amedranogil opened 5 years ago

amedranogil commented 5 years ago

@soad03 has been working with the JSON-LD Deserializer, and stumbled on this issue. Becuase he did not considered the multivalue rules for universAAL.

So in classes such as ContextProvider, their isWellFormed() will assume the object has a monovaluated PROP_CONTEXT_PROVIDER_TYPE proterty, this might not be the case in case of unreasoned resources which this property is "multivalued" (e.g: the non standard universAAL 1 element list, for whatever reason) will throw a class missmatch exception.

@universAAL/core should review all core classes for this type of assumptions. This will make uAAL more robust in general, specially when considering interaction with other pieces of software through the serializers.