[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [sca-policy] Can we use appliesTo="sca:binding" or appliesTo="sca:implementation"to select all bindings or implementations?
Hi Raymond: In XPath 1.0 the expression "sca:binding.ws" will select all nodes called sca:binding that are children of the context node. Look in the section 2.5 of the spec. The first bullet says: * |para| selects the |para| element children of the context node All the best, Ashok Raymond Feng wrote: > There is a statement in the SCA Policy Framework Version 1.1, > Committee Draft 02/Public Review 01 – rev4 spec as quoted below: > > 337 • @appliesTo (0..1) - a string which is an XPath 1.0 expression > identifying one or more SCA constructs > 338 this policySet can configure. The contents of @appliesTo MUST > match the XPath 1.0 [XPATH] > 339 production /Expr. /[POL30018] > > We have the following samples as we expect them would select the > concrete bindings or implementations such as binding.ws or > implementation.java: > appliesTo="sca:binding" > appliesTo="sca:implementation" > > Unfortunately such capability is only available in XPath 2.0 where > schema-element() function can be used to test the substitutionGroup. > See section 2.5.4.4 Schema Element Test of > http://www.w3.org/TR/xpath20/. I'm not sure if there are XPath > implementations that support 2.0. At lease the one from JDK only > supports 1.0. > > Are these usages valid? Do we always have to give the concrete > elements such as appliesTo="//sca:binding.ws | //sca:binding.jms"? > > Thanks, > Raymond > ------------------------------------------------------------------------ > *Raymond Feng* > Senior Software Engineer, Apache Tuscany PMC Member & Committer > /IBM Bay Area Lab, 1001 E Hillsdale Blvd, Suite 400, Foster City, CA > 94404, USA* > E-mail*//: //_rfeng@us.ibm.com_/ <mailto:rfeng@us.ibm.com>/, > *Notes*//: Raymond Feng/Burlingame/IBM, *Tel*//: 650-645-8117, > *T/L*//: 367-8117* > Apache Tuscany*//: //_http://tuscany.apache.org_/ > <http://tuscany.apache.org/>/ > Co-author of Tuscany In Action: //_http://www.manning.com/laws_// / > ------------------------------------------------------------------------
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]