А если в XML-е таких Нод несколько ?
Вот пример :
<?xml version="1.0" encoding="UTF-8"?>
<Etr290ExportData name="EtrData" hwId="0120-C967-412C-6A45-0714" crc="c88a7a8f" release="5.0.2-1">
<input name="Ethernet" type="Ethernet" id="100" numTs="3" numTsPri1Err="0" numTsPri2Err="3" numTsPri3Err="3" numTsOtherErr="0" numTsInterfaceErr="0">
<tuningSetup name="Inter" id="0" etrEngineNo="0" description="225.20.5.6:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="206" tsId="20003" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4208000" effectiveBitrate="4208000" minimumTotalBitrate="4200000" minimumEffectiveBitrate="4200000" maximumTotalBitrate="4224000" maximumEffectiveBitrate="4224000"/>
<tuningSetup name="Enter" id="4" etrEngineNo="0" description="225.20.5.5:9900" mode="DVB" tsSync="yes" timeSinceUpdate="136" tsId="20040" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="3984000" minimumEffectiveBitrate="3984000" maximumTotalBitrate="4064000" maximumEffectiveBitrate="4064000"/>
<tuningSetup name="Dacha" id="8" etrEngineNo="0" description="225.20.5.10:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20058" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1571504" effectiveBitrate="1571504" minimumTotalBitrate="1561888" minimumEffectiveBitrate="1561888" maximumTotalBitrate="1582672" maximumEffectiveBitrate="1582672"/>
<tuningSetup name="NTN" id="1" etrEngineNo="1" description="225.20.5.2:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="206" tsId="20032" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="4024000" minimumEffectiveBitrate="4024000" maximumTotalBitrate="4064000" maximumEffectiveBitrate="4064000"/>
<tuningSetup name="Mega" id="5" etrEngineNo="1" description="225.20.5.7:9900" mode="DVB" tsSync="yes" timeSinceUpdate="136" tsId="20036" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4064000" effectiveBitrate="4064000" minimumTotalBitrate="4016000" minimumEffectiveBitrate="4016000" maximumTotalBitrate="4080000" maximumEffectiveBitrate="4080000"/>
<tuningSetup name="Trofey" id="9" etrEngineNo="1" description="225.20.5.12:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20062" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1571008" effectiveBitrate="1571008" minimumTotalBitrate="1565088" minimumEffectiveBitrate="1565088" maximumTotalBitrate="1582192" maximumEffectiveBitrate="1582192"/>
<tuningSetup name="K1" id="2" etrEngineNo="2" description="225.20.5.3:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20034" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="3688000" minimumEffectiveBitrate="3688000" maximumTotalBitrate="4072000" maximumEffectiveBitrate="4072000"/>
<tuningSetup name="Pixel" id="6" etrEngineNo="2" description="225.20.5.8:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="136" tsId="20049" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4032000" effectiveBitrate="4032000" minimumTotalBitrate="3888000" minimumEffectiveBitrate="3888000" maximumTotalBitrate="4072000" maximumEffectiveBitrate="4072000"/>
<tuningSetup name="Zoom" id="3" etrEngineNo="3" description="225.20.5.1:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20038" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="3856000" effectiveBitrate="3856000" minimumTotalBitrate="3856000" minimumEffectiveBitrate="3856000" maximumTotalBitrate="4088000" maximumEffectiveBitrate="4088000"/>
<tuningSetup name="Eco" id="7" etrEngineNo="3" description="225.20.5.9:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="136" tsId="20055" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1615760" effectiveBitrate="1615760" minimumTotalBitrate="1601944" minimumEffectiveBitrate="1601944" maximumTotalBitrate="1631064" maximumEffectiveBitrate="1631064"/>
</input>
<input name="ASI" type="ASI" id="0" numTs="3" numTsPri1Err="0" numTsPri2Err="3" numTsPri3Err="3" numTsOtherErr="0" numTsInterfaceErr="0">
<tuningSetup name="ASI Input 1" id="1" etrEngineNo="0" description="ASI" mode="DVB" tsSync="no" currentlyMonitored="true" monitoringProgress="100" timeSinceUpdate="25" tsId="12600" alarmOverview="ADDDDD|DDDDDD|DDDDDDD|DDDDDDDD|DDD" totalBitrate="16312000" effectiveBitrate="15923944" minimumTotalBitrate="5728000" minimumEffectiveBitrate="4873952" maximumTotalBitrate="38024000" maximumEffectiveBitrate="37163216"/>
</input>
<input name="QAM" type="QAM" id="1" numTs="2" numTsPri1Err="0" numTsPri2Err="2" numTsPri3Err="2" numTsOtherErr="0" numTsInterfaceErr="0"/>
<input name="COFDM" type="VB252" id="3" numTs="2" numTsPri1Err="0" numTsPri2Err="2" numTsPri3Err="2" numTsOtherErr="0" numTsInterfaceErr="0"/>
</Etr290ExportData>
В этом случае как вытаскивать значения по индексу ? К примеру как вытащить значение effectiveBitrate из tuningSetup с name="Inter" id="0"
Пробовал вот так : ./Etr290ExportData/input[1]/tuningSetup[1]/effectiveBitrate
Не хочет
Добавлено:
Вопрос снят как дурной
./Etr290ExportData/input[1]/tuningSetup[1] effectiveBitrate
Вот пример :
<?xml version="1.0" encoding="UTF-8"?>
<Etr290ExportData name="EtrData" hwId="0120-C967-412C-6A45-0714" crc="c88a7a8f" release="5.0.2-1">
<input name="Ethernet" type="Ethernet" id="100" numTs="3" numTsPri1Err="0" numTsPri2Err="3" numTsPri3Err="3" numTsOtherErr="0" numTsInterfaceErr="0">
<tuningSetup name="Inter" id="0" etrEngineNo="0" description="225.20.5.6:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="206" tsId="20003" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4208000" effectiveBitrate="4208000" minimumTotalBitrate="4200000" minimumEffectiveBitrate="4200000" maximumTotalBitrate="4224000" maximumEffectiveBitrate="4224000"/>
<tuningSetup name="Enter" id="4" etrEngineNo="0" description="225.20.5.5:9900" mode="DVB" tsSync="yes" timeSinceUpdate="136" tsId="20040" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="3984000" minimumEffectiveBitrate="3984000" maximumTotalBitrate="4064000" maximumEffectiveBitrate="4064000"/>
<tuningSetup name="Dacha" id="8" etrEngineNo="0" description="225.20.5.10:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20058" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1571504" effectiveBitrate="1571504" minimumTotalBitrate="1561888" minimumEffectiveBitrate="1561888" maximumTotalBitrate="1582672" maximumEffectiveBitrate="1582672"/>
<tuningSetup name="NTN" id="1" etrEngineNo="1" description="225.20.5.2:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="206" tsId="20032" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="4024000" minimumEffectiveBitrate="4024000" maximumTotalBitrate="4064000" maximumEffectiveBitrate="4064000"/>
<tuningSetup name="Mega" id="5" etrEngineNo="1" description="225.20.5.7:9900" mode="DVB" tsSync="yes" timeSinceUpdate="136" tsId="20036" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4064000" effectiveBitrate="4064000" minimumTotalBitrate="4016000" minimumEffectiveBitrate="4016000" maximumTotalBitrate="4080000" maximumEffectiveBitrate="4080000"/>
<tuningSetup name="Trofey" id="9" etrEngineNo="1" description="225.20.5.12:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20062" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1571008" effectiveBitrate="1571008" minimumTotalBitrate="1565088" minimumEffectiveBitrate="1565088" maximumTotalBitrate="1582192" maximumEffectiveBitrate="1582192"/>
<tuningSetup name="K1" id="2" etrEngineNo="2" description="225.20.5.3:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20034" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4056000" effectiveBitrate="4056000" minimumTotalBitrate="3688000" minimumEffectiveBitrate="3688000" maximumTotalBitrate="4072000" maximumEffectiveBitrate="4072000"/>
<tuningSetup name="Pixel" id="6" etrEngineNo="2" description="225.20.5.8:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="136" tsId="20049" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="4032000" effectiveBitrate="4032000" minimumTotalBitrate="3888000" minimumEffectiveBitrate="3888000" maximumTotalBitrate="4072000" maximumEffectiveBitrate="4072000"/>
<tuningSetup name="Zoom" id="3" etrEngineNo="3" description="225.20.5.1:9900" mode="DVB" tsSync="yes" timeSinceUpdate="66" tsId="20038" alarmOverview="OOOOOO|OOOADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="3856000" effectiveBitrate="3856000" minimumTotalBitrate="3856000" minimumEffectiveBitrate="3856000" maximumTotalBitrate="4088000" maximumEffectiveBitrate="4088000"/>
<tuningSetup name="Eco" id="7" etrEngineNo="3" description="225.20.5.9:9900" mode="DVB" tsSync="yes" currentlyMonitored="true" monitoringProgress="94" timeSinceUpdate="136" tsId="20055" alarmOverview="OOOOOO|OOAADO|AOOAAOA|DOOOOOOD|DO" totalBitrate="1615760" effectiveBitrate="1615760" minimumTotalBitrate="1601944" minimumEffectiveBitrate="1601944" maximumTotalBitrate="1631064" maximumEffectiveBitrate="1631064"/>
</input>
<input name="ASI" type="ASI" id="0" numTs="3" numTsPri1Err="0" numTsPri2Err="3" numTsPri3Err="3" numTsOtherErr="0" numTsInterfaceErr="0">
<tuningSetup name="ASI Input 1" id="1" etrEngineNo="0" description="ASI" mode="DVB" tsSync="no" currentlyMonitored="true" monitoringProgress="100" timeSinceUpdate="25" tsId="12600" alarmOverview="ADDDDD|DDDDDD|DDDDDDD|DDDDDDDD|DDD" totalBitrate="16312000" effectiveBitrate="15923944" minimumTotalBitrate="5728000" minimumEffectiveBitrate="4873952" maximumTotalBitrate="38024000" maximumEffectiveBitrate="37163216"/>
</input>
<input name="QAM" type="QAM" id="1" numTs="2" numTsPri1Err="0" numTsPri2Err="2" numTsPri3Err="2" numTsOtherErr="0" numTsInterfaceErr="0"/>
<input name="COFDM" type="VB252" id="3" numTs="2" numTsPri1Err="0" numTsPri2Err="2" numTsPri3Err="2" numTsOtherErr="0" numTsInterfaceErr="0"/>
</Etr290ExportData>
В этом случае как вытаскивать значения по индексу ? К примеру как вытащить значение effectiveBitrate из tuningSetup с name="Inter" id="0"
Пробовал вот так : ./Etr290ExportData/input[1]/tuningSetup[1]/effectiveBitrate
Не хочет
Добавлено:
Вопрос снят как дурной
./Etr290ExportData/input[1]/tuningSetup[1] effectiveBitrate