Open-Network-Models-and-Interfaces-ONMI / onmi-iisomi-xhaul-uml-yang

5G xHaul PoC Applications
Apache License 2.0
30 stars 39 forks source link

LogicalTerminationPoint::_(!)physicalPortReference need to be pruned #44

Open PrathibaJee opened 2 years ago

PrathibaJee commented 2 years ago

For the proposal in the issue https://github.com/openBackhaul/core/issues/10 , need to prune the attribute LogicalTerminationPoint:physicalPortRefernce[*] from the CoreModel ,

Solution : In the UML2YANG tool in the experimental branch ,

<!-- To change the datatype of physical-port-reference from string to leafref to point to a instance in the equipment list -->
  <xsl:template match="ownedAttribute[@xmi:id = '_RLDi4BieEeSh8KVgZCMyDw' ]" >
    <xsl:copy>
      <xsl:apply-templates select="@*"/>
      <xsl:attribute name="type">_8SXNej-HEeaRI-H69PghuA</xsl:attribute>
      <xsl:attribute name="aggregation">shared</xsl:attribute>
      <xsl:attribute name="association">_X1qQMD-QEeaRI-H69PghuA</xsl:attribute>
      <xsl:apply-templates select="node()  | text()"/>
    </xsl:copy>
  </xsl:template>
<property id="_RLDi4BieEeSh8KVgZCMyDw" name="physicalPortReference" prune="true"/>