Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding attrbutes to leshan-client #6

Closed
abinash193 opened this issue Mar 10, 2015 · 1 comment
Closed

adding attrbutes to leshan-client #6

abinash193 opened this issue Mar 10, 2015 · 1 comment
Labels
question Any question about leshan

Comments

@abinash193
Copy link

how to add attributes to each resources of leshan client ??
attributes like interface type,content-type,observable etc .
so ,While registering the attributes will also get passed along with the resource path .

@jschloman
Copy link

Hello,

So right now the Leshan Client only supports TLV encoding but that should be transparent to the developer using it (so if you build a StringLwM2mResource, or TimeLwM2mResource you simply override the handleRead() and handleWrite() methods like in the Client Example and the encoding is done for you). There are *LwM2mResource classes provided for all for all of the specified LWM2M data types (String, Integer, Float/Decimal, Opaque, Time) so you would only need to build those and pass them into your Object Definition (there is a near-term change to the client that will change this behavior however). The Object Definition is then used when you issue a Register to a server. In the future the Client should be configurable to allow a user to specify what encoding they wish to send.

As for observations, the Leshan client currently allows for all readable Resources to be observed so there is no way for a client to say "this Resource is/is not Observable" (I can't remember if the specification allows for a valid readable Resource to not be observable...).

I hope this helps! Also this seems to be less of an issue and more of a question appropriate for the developer mailing list. Sign up is available here: https://dev.eclipse.org/mailman/listinfo/leshan-dev and the archive is available here: http://dev.eclipse.org/mhonarc/lists/leshan-dev/

Cheers,

-JF

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Any question about leshan
Projects
None yet
Development

No branches or pull requests

3 participants