[sysrepo-devel] How to use operation data provider in this?

Jimmy Jin jjin62 at yahoo.com
Thu Oct 13 23:42:25 UTC 2016


Hi,when operation data and conf data are mixed in a sub tree, I can not make the data provide callback working.
here is the schema example:

module com-att-device{
  namespace "http://com/att/device";
  prefix "com-att-device";    list ports{      
      leaf port-id {
        type uint32;
      }
      container port {        leaf target-power {        
            type uint32;
        }        leaf current-power { 
           type uint32;           config false;
        }     }  }}

I like to implement a data provider for current-power, but had no luck so far. I am not sure what xpath I should use in this call:sr_dp_get_items_subscribe(session, xpath.....).seems xpath =" /com-att-device:ports" is not working. Because it is a list, so i can not specify the path all the way to current-power, is wildcard support? like:/com-att-device:ports[port-id='?']/port/current-power. 


thanks in advance.Jimmy



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sysrepo.org/archives/sysrepo-devel/attachments/20161013/03cb71ef/attachment.html>


More information about the sysrepo-devel mailing list