No support for reusable resources #329
Labels
client
Impact LWM2M client
new feature
New feature from LWM2M specification
server
Impact LWM2M server
Leshan/LwM2mModel appears to have no support for reusable resources. See section 6.3.2 in the specification and http://www.openmobilealliance.org/wp/OMNA/LwM2M/LwM2MRegistry.html#resources and http://www.openmobilealliance.org/wp/OMNA/LwM2M/Common.xml
I suppose a starting point of an approach could be to use a special purpose DDF loader or mechanism for these files (special purpose because at least the above Common.xml has ObjectID 0 which would cause a clash with/overwrite of the Security object if just dumped into the LwM2mModel). Reusable resources could be represented as an object with null id in
LwM2mModel.objects
and Integer vs current int inObjectModel.id
, although this would cause quite a bit of changes needed for the code in the tree here and there. Or it could be put as a separate field in LwM2mModel, e.g.Map<Integer,ResourceModel> reusableResources
.Anyway, no matter where it is, it could be used for example so that when a resource is looked up for an object with id, if not found from within that specific object, the reusable resources Map could be used as a fallback to search from, with just the resource id used for the lookup.
The text was updated successfully, but these errors were encountered: