Ask is moving to Stack Overflow and Serverfault.com! Please use the "opendaylight" tag on either of these sites. This site is now in Read-Only mode

Revision history [back]

click to hide/show revision 1
initial version

How to return list value in Yang?

Hi,

I am writing one module to expose REST API using ODL helium stable version. I want to expose REST API which should return list of values.

rpc getList{ output{ leaf id{ type uint32; } leaf name{ type string; } leaf SETTIME { type string; } } }

But yang generated service class with Future<rpcresult<getlistoutput>> as return type. Here i want to return list of values. How can i achieve this in yang. Any pointer or sample would be helpful for us. I followed as like Toaster example.

Thanks, rmohamed

How to return list value in Yang?

Hi,

I am writing one module to expose REST API using ODL helium stable version. I want to expose REST API which should return list of values.

values. rpc getList{ output{ leaf id{ type uint32; } } leaf name{ type string; } } leaf SETTIME { type string; } } } }

} But yang generated service class with Future<rpcresult<getlistoutput>> Future<RpcResult<GetListOutput>> as return type. Here i want to return list of values. How can i achieve this in yang. Any pointer or sample would be helpful for us. I followed as like Toaster example.

example.

Thanks, rmohamed