EXIDecoder.c 103 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175
  1. /*
  2. * Copyright (C) 2007-2010 Siemens AG
  3. *
  4. * This program is free software: you can redistribute it and/or modify
  5. * it under the terms of the GNU Lesser General Public License as published
  6. * by the Free Software Foundation, either version 3 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU Lesser General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU Lesser General Public License
  15. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  16. */
  17. /*******************************************************************
  18. *
  19. * @author Daniel.Peintner.EXT@siemens.com
  20. * @version 0.2
  21. * @contact Joerg.Heuer@siemens.com
  22. *
  23. * <p>NOTE: Code generated by EXIdizer v0.1</p>
  24. ********************************************************************/
  25. #ifndef EXI_DECODER_C
  26. #define EXI_DECODER_C
  27. #include <stdio.h>
  28. #include <stdint.h>
  29. #include <string.h>
  30. #include <stdlib.h>
  31. #include "EXITypes.h"
  32. #include "BitInputStream.h"
  33. #include "BitDecoderChannel.h"
  34. #include "EXICoder.h"
  35. #include "EXIHeaderDecoder.h"
  36. #include "StringTable.h"
  37. int exiInitDecoder(bitstream_t* stream, exi_state_t* state) {
  38. /* init grammar state */
  39. state->stackIndex = 0;
  40. state->grammarStack[0] = 0;
  41. /* decode header */
  42. return readEXIHeader(stream);
  43. }
  44. int exiDecodeNextEvent(bitstream_t* stream, exi_state_t* state,
  45. exi_event_t* nextEvent) {
  46. switch (state->grammarStack[state->stackIndex]) {
  47. case 0:
  48. /* Document[START_DOCUMENT] */
  49. *nextEvent = START_DOCUMENT;
  50. return 0;
  51. case 1:
  52. /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:MsgDef}V2G_Message), START_ELEMENT_GENERIC] */
  53. decodeNBitUnsignedInteger(stream, 5, &state->eventCode);
  54. if (state->eventCode == 0) {
  55. *nextEvent = START_ELEMENT;
  56. return 0;
  57. }
  58. else if (state->eventCode == 1) {
  59. *nextEvent = START_ELEMENT;
  60. return 0;
  61. }
  62. else if (state->eventCode == 2) {
  63. *nextEvent = START_ELEMENT;
  64. return 0;
  65. }
  66. else if (state->eventCode == 3) {
  67. *nextEvent = START_ELEMENT;
  68. return 0;
  69. }
  70. else if (state->eventCode == 4) {
  71. *nextEvent = START_ELEMENT;
  72. return 0;
  73. }
  74. else if (state->eventCode == 5) {
  75. *nextEvent = START_ELEMENT;
  76. return 0;
  77. }
  78. else if (state->eventCode == 6) {
  79. *nextEvent = START_ELEMENT;
  80. return 0;
  81. }
  82. else if (state->eventCode == 7) {
  83. *nextEvent = START_ELEMENT;
  84. return 0;
  85. }
  86. else if (state->eventCode == 8) {
  87. *nextEvent = START_ELEMENT;
  88. return 0;
  89. }
  90. else if (state->eventCode == 9) {
  91. *nextEvent = START_ELEMENT;
  92. return 0;
  93. }
  94. else if (state->eventCode == 10) {
  95. *nextEvent = START_ELEMENT;
  96. return 0;
  97. }
  98. else if (state->eventCode == 11) {
  99. *nextEvent = START_ELEMENT;
  100. return 0;
  101. }
  102. else if (state->eventCode == 12) {
  103. *nextEvent = START_ELEMENT;
  104. return 0;
  105. }
  106. else if (state->eventCode == 13) {
  107. *nextEvent = START_ELEMENT;
  108. return 0;
  109. }
  110. else if (state->eventCode == 14) {
  111. *nextEvent = START_ELEMENT;
  112. return 0;
  113. }
  114. else if (state->eventCode == 15) {
  115. *nextEvent = START_ELEMENT;
  116. return 0;
  117. }
  118. else if (state->eventCode == 16) {
  119. *nextEvent = START_ELEMENT;
  120. return 0;
  121. }
  122. else if (state->eventCode == 17) {
  123. *nextEvent = START_ELEMENT;
  124. return 0;
  125. }
  126. else if (state->eventCode == 18) {
  127. *nextEvent = START_ELEMENT;
  128. return 0;
  129. }
  130. else if (state->eventCode == 19) {
  131. *nextEvent = START_ELEMENT;
  132. return 0;
  133. }
  134. else if (state->eventCode == 20) {
  135. *nextEvent = START_ELEMENT_GENERIC;
  136. return 0;
  137. }
  138. case 2:
  139. /* DocEnd[END_DOCUMENT] */
  140. *nextEvent = END_DOCUMENT;
  141. return 0;
  142. case 3:
  143. /* FirstStartTag(xsi:type)StartTag[END_ELEMENT] */
  144. *nextEvent = END_ELEMENT;
  145. return 0;
  146. case 5:
  147. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  148. *nextEvent = START_ELEMENT;
  149. return 0;
  150. case 24:
  151. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ReqLockStatus)] */
  152. *nextEvent = START_ELEMENT;
  153. return 0;
  154. case 26:
  155. /* Element[END_ELEMENT] */
  156. *nextEvent = END_ELEMENT;
  157. return 0;
  158. case 25:
  159. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ConnectorLocked)] */
  160. *nextEvent = START_ELEMENT;
  161. return 0;
  162. case 28:
  163. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargerStandby)] */
  164. *nextEvent = START_ELEMENT;
  165. return 0;
  166. case 29:
  167. /* Element[END_ELEMENT] */
  168. *nextEvent = END_ELEMENT;
  169. return 0;
  170. case 27:
  171. /* FirstStartTagStartTag[CHARACTERS[BOOLEAN]] */
  172. *nextEvent = CHARACTERS;
  173. return 0;
  174. case 31:
  175. /* Element[END_ELEMENT] */
  176. *nextEvent = END_ELEMENT;
  177. return 0;
  178. case 30:
  179. /* FirstStartTagStartTag[CHARACTERS[BOOLEAN]] */
  180. *nextEvent = CHARACTERS;
  181. return 0;
  182. case 32:
  183. /* Element[END_ELEMENT] */
  184. *nextEvent = END_ELEMENT;
  185. return 0;
  186. case 6:
  187. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  188. *nextEvent = START_ELEMENT;
  189. return 0;
  190. case 33:
  191. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  192. *nextEvent = START_ELEMENT;
  193. return 0;
  194. case 35:
  195. /* Element[END_ELEMENT] */
  196. *nextEvent = END_ELEMENT;
  197. return 0;
  198. case 34:
  199. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  200. *nextEvent = CHARACTERS;
  201. return 0;
  202. case 37:
  203. /* Element[END_ELEMENT] */
  204. *nextEvent = END_ELEMENT;
  205. return 0;
  206. case 36:
  207. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FatalError)] */
  208. *nextEvent = START_ELEMENT;
  209. return 0;
  210. case 38:
  211. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EVSEStandby)] */
  212. *nextEvent = START_ELEMENT;
  213. return 0;
  214. case 40:
  215. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ConnectorLocked)] */
  216. *nextEvent = START_ELEMENT;
  217. return 0;
  218. case 41:
  219. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}PowerSwitchClosed)] */
  220. *nextEvent = START_ELEMENT;
  221. return 0;
  222. case 42:
  223. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}RCD)] */
  224. *nextEvent = START_ELEMENT;
  225. return 0;
  226. case 44:
  227. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ShutDownTime)] */
  228. *nextEvent = START_ELEMENT;
  229. return 0;
  230. case 46:
  231. /* Element[END_ELEMENT] */
  232. *nextEvent = END_ELEMENT;
  233. return 0;
  234. case 39:
  235. /* FirstStartTagStartTag[CHARACTERS[BOOLEAN]] */
  236. *nextEvent = CHARACTERS;
  237. return 0;
  238. case 48:
  239. /* Element[END_ELEMENT] */
  240. *nextEvent = END_ELEMENT;
  241. return 0;
  242. case 43:
  243. /* FirstStartTagStartTag[CHARACTERS[BOOLEAN]] */
  244. *nextEvent = CHARACTERS;
  245. return 0;
  246. case 49:
  247. /* Element[END_ELEMENT] */
  248. *nextEvent = END_ELEMENT;
  249. return 0;
  250. case 45:
  251. /* FirstStartTagStartTag[CHARACTERS[BOOLEAN]] */
  252. *nextEvent = CHARACTERS;
  253. return 0;
  254. case 50:
  255. /* Element[END_ELEMENT] */
  256. *nextEvent = END_ELEMENT;
  257. return 0;
  258. case 47:
  259. /* FirstStartTagStartTag[CHARACTERS[INTEGER_64]] */
  260. *nextEvent = CHARACTERS;
  261. return 0;
  262. case 51:
  263. /* Element[END_ELEMENT] */
  264. *nextEvent = END_ELEMENT;
  265. return 0;
  266. case 7:
  267. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  268. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  269. if (state->eventCode == 0) {
  270. *nextEvent = START_ELEMENT;
  271. return 0;
  272. }
  273. else if (state->eventCode == 1) {
  274. *nextEvent = START_ELEMENT;
  275. return 0;
  276. }
  277. case 52:
  278. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  279. *nextEvent = START_ELEMENT;
  280. return 0;
  281. case 54:
  282. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff)] */
  283. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  284. if (state->eventCode == 0) {
  285. *nextEvent = START_ELEMENT;
  286. return 0;
  287. }
  288. else if (state->eventCode == 1) {
  289. *nextEvent = START_ELEMENT;
  290. return 0;
  291. }
  292. case 55:
  293. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff)] */
  294. *nextEvent = START_ELEMENT;
  295. return 0;
  296. case 56:
  297. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo)] */
  298. *nextEvent = START_ELEMENT;
  299. return 0;
  300. case 58:
  301. /* Element[END_ELEMENT] */
  302. *nextEvent = END_ELEMENT;
  303. return 0;
  304. case 53:
  305. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  306. *nextEvent = CHARACTERS;
  307. return 0;
  308. case 60:
  309. /* Element[END_ELEMENT] */
  310. *nextEvent = END_ELEMENT;
  311. return 0;
  312. case 57:
  313. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  314. *nextEvent = CHARACTERS;
  315. return 0;
  316. case 61:
  317. /* Element[END_ELEMENT] */
  318. *nextEvent = END_ELEMENT;
  319. return 0;
  320. case 59:
  321. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterPubKey), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  322. decodeNBitUnsignedInteger(stream, 3, &state->eventCode);
  323. if (state->eventCode == 0) {
  324. *nextEvent = START_ELEMENT;
  325. return 0;
  326. }
  327. else if (state->eventCode == 1) {
  328. *nextEvent = START_ELEMENT;
  329. return 0;
  330. }
  331. else if (state->eventCode == 2) {
  332. *nextEvent = START_ELEMENT;
  333. return 0;
  334. }
  335. else if (state->eventCode == 3) {
  336. *nextEvent = START_ELEMENT;
  337. return 0;
  338. }
  339. else if (state->eventCode == 4) {
  340. *nextEvent = START_ELEMENT;
  341. return 0;
  342. }
  343. else if (state->eventCode == 5) {
  344. *nextEvent = END_ELEMENT;
  345. return 0;
  346. }
  347. case 62:
  348. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterPubKey), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  349. decodeNBitUnsignedInteger(stream, 3, &state->eventCode);
  350. if (state->eventCode == 0) {
  351. *nextEvent = START_ELEMENT;
  352. return 0;
  353. }
  354. else if (state->eventCode == 1) {
  355. *nextEvent = START_ELEMENT;
  356. return 0;
  357. }
  358. else if (state->eventCode == 2) {
  359. *nextEvent = START_ELEMENT;
  360. return 0;
  361. }
  362. else if (state->eventCode == 3) {
  363. *nextEvent = START_ELEMENT;
  364. return 0;
  365. }
  366. else if (state->eventCode == 4) {
  367. *nextEvent = END_ELEMENT;
  368. return 0;
  369. }
  370. case 64:
  371. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  372. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  373. if (state->eventCode == 0) {
  374. *nextEvent = START_ELEMENT;
  375. return 0;
  376. }
  377. else if (state->eventCode == 1) {
  378. *nextEvent = START_ELEMENT;
  379. return 0;
  380. }
  381. else if (state->eventCode == 2) {
  382. *nextEvent = START_ELEMENT;
  383. return 0;
  384. }
  385. else if (state->eventCode == 3) {
  386. *nextEvent = END_ELEMENT;
  387. return 0;
  388. }
  389. case 66:
  390. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  391. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  392. if (state->eventCode == 0) {
  393. *nextEvent = START_ELEMENT;
  394. return 0;
  395. }
  396. else if (state->eventCode == 1) {
  397. *nextEvent = START_ELEMENT;
  398. return 0;
  399. }
  400. else if (state->eventCode == 2) {
  401. *nextEvent = END_ELEMENT;
  402. return 0;
  403. }
  404. case 68:
  405. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  406. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  407. if (state->eventCode == 0) {
  408. *nextEvent = START_ELEMENT;
  409. return 0;
  410. }
  411. else if (state->eventCode == 1) {
  412. *nextEvent = END_ELEMENT;
  413. return 0;
  414. }
  415. case 70:
  416. /* Element[END_ELEMENT] */
  417. *nextEvent = END_ELEMENT;
  418. return 0;
  419. case 63:
  420. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  421. *nextEvent = CHARACTERS;
  422. return 0;
  423. case 71:
  424. /* Element[END_ELEMENT] */
  425. *nextEvent = END_ELEMENT;
  426. return 0;
  427. case 65:
  428. /* FirstStartTagStartTag[CHARACTERS[BINARY_HEX]] */
  429. *nextEvent = CHARACTERS;
  430. return 0;
  431. case 72:
  432. /* Element[END_ELEMENT] */
  433. *nextEvent = END_ELEMENT;
  434. return 0;
  435. case 67:
  436. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Multiplier)] */
  437. *nextEvent = START_ELEMENT;
  438. return 0;
  439. case 73:
  440. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Unit)] */
  441. *nextEvent = START_ELEMENT;
  442. return 0;
  443. case 75:
  444. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Value)] */
  445. *nextEvent = START_ELEMENT;
  446. return 0;
  447. case 76:
  448. /* Element[END_ELEMENT] */
  449. *nextEvent = END_ELEMENT;
  450. return 0;
  451. case 74:
  452. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  453. *nextEvent = CHARACTERS;
  454. return 0;
  455. case 78:
  456. /* Element[END_ELEMENT] */
  457. *nextEvent = END_ELEMENT;
  458. return 0;
  459. case 77:
  460. /* FirstStartTag(xsi:type)StartTag[CHARACTERS[INTEGER_64]] */
  461. *nextEvent = CHARACTERS;
  462. return 0;
  463. case 79:
  464. /* Element[END_ELEMENT] */
  465. *nextEvent = END_ELEMENT;
  466. return 0;
  467. case 69:
  468. /* FirstStartTagStartTag[CHARACTERS[INTEGER_16]] */
  469. *nextEvent = CHARACTERS;
  470. return 0;
  471. case 80:
  472. /* Element[END_ELEMENT] */
  473. *nextEvent = END_ELEMENT;
  474. return 0;
  475. case 8:
  476. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  477. *nextEvent = START_ELEMENT;
  478. return 0;
  479. case 81:
  480. /* Element[END_ELEMENT] */
  481. *nextEvent = END_ELEMENT;
  482. return 0;
  483. case 82:
  484. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  485. *nextEvent = CHARACTERS;
  486. return 0;
  487. case 83:
  488. /* Element[END_ELEMENT] */
  489. *nextEvent = END_ELEMENT;
  490. return 0;
  491. case 9:
  492. /* FirstStartTagStartTag[END_ELEMENT] */
  493. *nextEvent = END_ELEMENT;
  494. return 0;
  495. case 10:
  496. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  497. *nextEvent = START_ELEMENT;
  498. return 0;
  499. case 84:
  500. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEID)] */
  501. *nextEvent = START_ELEMENT;
  502. return 0;
  503. case 86:
  504. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  505. *nextEvent = START_ELEMENT;
  506. return 0;
  507. case 88:
  508. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent)] */
  509. *nextEvent = START_ELEMENT;
  510. return 0;
  511. case 89:
  512. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEMaxPower)] */
  513. *nextEvent = START_ELEMENT;
  514. return 0;
  515. case 90:
  516. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo), END_ELEMENT] */
  517. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  518. if (state->eventCode == 0) {
  519. *nextEvent = START_ELEMENT;
  520. return 0;
  521. }
  522. else if (state->eventCode == 1) {
  523. *nextEvent = START_ELEMENT;
  524. return 0;
  525. }
  526. else if (state->eventCode == 2) {
  527. *nextEvent = END_ELEMENT;
  528. return 0;
  529. }
  530. case 91:
  531. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo), END_ELEMENT] */
  532. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  533. if (state->eventCode == 0) {
  534. *nextEvent = START_ELEMENT;
  535. return 0;
  536. }
  537. else if (state->eventCode == 1) {
  538. *nextEvent = END_ELEMENT;
  539. return 0;
  540. }
  541. case 92:
  542. /* Element[END_ELEMENT] */
  543. *nextEvent = END_ELEMENT;
  544. return 0;
  545. case 85:
  546. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  547. *nextEvent = CHARACTERS;
  548. return 0;
  549. case 93:
  550. /* Element[END_ELEMENT] */
  551. *nextEvent = END_ELEMENT;
  552. return 0;
  553. case 87:
  554. /* FirstStartTagStartTag[CHARACTERS[BINARY_HEX]] */
  555. *nextEvent = CHARACTERS;
  556. return 0;
  557. case 94:
  558. /* Element[END_ELEMENT] */
  559. *nextEvent = END_ELEMENT;
  560. return 0;
  561. case 11:
  562. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ContractID)] */
  563. *nextEvent = START_ELEMENT;
  564. return 0;
  565. case 95:
  566. /* Element[END_ELEMENT] */
  567. *nextEvent = END_ELEMENT;
  568. return 0;
  569. case 96:
  570. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  571. *nextEvent = CHARACTERS;
  572. return 0;
  573. case 97:
  574. /* Element[END_ELEMENT] */
  575. *nextEvent = END_ELEMENT;
  576. return 0;
  577. case 12:
  578. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  579. *nextEvent = START_ELEMENT;
  580. return 0;
  581. case 98:
  582. /* Element[END_ELEMENT] */
  583. *nextEvent = END_ELEMENT;
  584. return 0;
  585. case 99:
  586. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  587. *nextEvent = CHARACTERS;
  588. return 0;
  589. case 100:
  590. /* Element[END_ELEMENT] */
  591. *nextEvent = END_ELEMENT;
  592. return 0;
  593. case 13:
  594. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  595. *nextEvent = START_ELEMENT;
  596. return 0;
  597. case 101:
  598. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ReqSwitchStatus)] */
  599. *nextEvent = START_ELEMENT;
  600. return 0;
  601. case 102:
  602. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ChargingProfile), END_ELEMENT] */
  603. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  604. if (state->eventCode == 0) {
  605. *nextEvent = START_ELEMENT;
  606. return 0;
  607. }
  608. else if (state->eventCode == 1) {
  609. *nextEvent = START_ELEMENT;
  610. return 0;
  611. }
  612. else if (state->eventCode == 2) {
  613. *nextEvent = END_ELEMENT;
  614. return 0;
  615. }
  616. case 103:
  617. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ChargingProfile), END_ELEMENT] */
  618. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  619. if (state->eventCode == 0) {
  620. *nextEvent = START_ELEMENT;
  621. return 0;
  622. }
  623. else if (state->eventCode == 1) {
  624. *nextEvent = END_ELEMENT;
  625. return 0;
  626. }
  627. case 104:
  628. /* Element[END_ELEMENT] */
  629. *nextEvent = END_ELEMENT;
  630. return 0;
  631. case 105:
  632. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargingProfileEntryStart)] */
  633. *nextEvent = START_ELEMENT;
  634. return 0;
  635. case 106:
  636. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargingProfileEntryMaxPower)] */
  637. *nextEvent = START_ELEMENT;
  638. return 0;
  639. case 107:
  640. /* Element[END_ELEMENT] */
  641. *nextEvent = END_ELEMENT;
  642. return 0;
  643. case 14:
  644. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  645. *nextEvent = START_ELEMENT;
  646. return 0;
  647. case 108:
  648. /* Element[END_ELEMENT] */
  649. *nextEvent = END_ELEMENT;
  650. return 0;
  651. case 109:
  652. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  653. *nextEvent = CHARACTERS;
  654. return 0;
  655. case 110:
  656. /* Element[END_ELEMENT] */
  657. *nextEvent = END_ELEMENT;
  658. return 0;
  659. case 15:
  660. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  661. *nextEvent = START_ELEMENT;
  662. return 0;
  663. case 111:
  664. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EoC)] */
  665. *nextEvent = START_ELEMENT;
  666. return 0;
  667. case 112:
  668. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EAmount)] */
  669. *nextEvent = START_ELEMENT;
  670. return 0;
  671. case 113:
  672. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxPower)] */
  673. *nextEvent = START_ELEMENT;
  674. return 0;
  675. case 114:
  676. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxPhases)] */
  677. *nextEvent = START_ELEMENT;
  678. return 0;
  679. case 115:
  680. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxVoltage)] */
  681. *nextEvent = START_ELEMENT;
  682. return 0;
  683. case 117:
  684. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMinVoltage)] */
  685. *nextEvent = START_ELEMENT;
  686. return 0;
  687. case 118:
  688. /* Element[END_ELEMENT] */
  689. *nextEvent = END_ELEMENT;
  690. return 0;
  691. case 116:
  692. /* FirstStartTagStartTag[CHARACTERS[INTEGER_16]] */
  693. *nextEvent = CHARACTERS;
  694. return 0;
  695. case 119:
  696. /* Element[END_ELEMENT] */
  697. *nextEvent = END_ELEMENT;
  698. return 0;
  699. case 16:
  700. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  701. *nextEvent = START_ELEMENT;
  702. return 0;
  703. case 120:
  704. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  705. *nextEvent = START_ELEMENT;
  706. return 0;
  707. case 122:
  708. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEVoltage)] */
  709. *nextEvent = START_ELEMENT;
  710. return 0;
  711. case 123:
  712. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEIMax)] */
  713. *nextEvent = START_ELEMENT;
  714. return 0;
  715. case 124:
  716. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEMaxPhases)] */
  717. *nextEvent = START_ELEMENT;
  718. return 0;
  719. case 125:
  720. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TariffTable), END_ELEMENT] */
  721. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  722. if (state->eventCode == 0) {
  723. *nextEvent = START_ELEMENT;
  724. return 0;
  725. }
  726. else if (state->eventCode == 1) {
  727. *nextEvent = START_ELEMENT;
  728. return 0;
  729. }
  730. else if (state->eventCode == 2) {
  731. *nextEvent = END_ELEMENT;
  732. return 0;
  733. }
  734. case 126:
  735. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TariffTable), END_ELEMENT] */
  736. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  737. if (state->eventCode == 0) {
  738. *nextEvent = START_ELEMENT;
  739. return 0;
  740. }
  741. else if (state->eventCode == 1) {
  742. *nextEvent = END_ELEMENT;
  743. return 0;
  744. }
  745. case 128:
  746. /* Element[END_ELEMENT] */
  747. *nextEvent = END_ELEMENT;
  748. return 0;
  749. case 121:
  750. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  751. *nextEvent = CHARACTERS;
  752. return 0;
  753. case 130:
  754. /* Element[END_ELEMENT] */
  755. *nextEvent = END_ELEMENT;
  756. return 0;
  757. case 127:
  758. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  759. *nextEvent = CHARACTERS;
  760. return 0;
  761. case 131:
  762. /* Element[END_ELEMENT] */
  763. *nextEvent = END_ELEMENT;
  764. return 0;
  765. case 129:
  766. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Currency)] */
  767. *nextEvent = START_ELEMENT;
  768. return 0;
  769. case 132:
  770. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Tariff)] */
  771. *nextEvent = START_ELEMENT;
  772. return 0;
  773. case 134:
  774. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Tariff), END_ELEMENT] */
  775. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  776. if (state->eventCode == 0) {
  777. *nextEvent = START_ELEMENT;
  778. return 0;
  779. }
  780. else if (state->eventCode == 1) {
  781. *nextEvent = END_ELEMENT;
  782. return 0;
  783. }
  784. case 133:
  785. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  786. *nextEvent = CHARACTERS;
  787. return 0;
  788. case 136:
  789. /* Element[END_ELEMENT] */
  790. *nextEvent = END_ELEMENT;
  791. return 0;
  792. case 135:
  793. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffID)] */
  794. *nextEvent = START_ELEMENT;
  795. return 0;
  796. case 137:
  797. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntries)] */
  798. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  799. if (state->eventCode == 0) {
  800. *nextEvent = START_ELEMENT;
  801. return 0;
  802. }
  803. else if (state->eventCode == 1) {
  804. *nextEvent = START_ELEMENT;
  805. return 0;
  806. }
  807. case 138:
  808. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntries)] */
  809. *nextEvent = START_ELEMENT;
  810. return 0;
  811. case 140:
  812. /* Element[END_ELEMENT] */
  813. *nextEvent = END_ELEMENT;
  814. return 0;
  815. case 139:
  816. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  817. *nextEvent = CHARACTERS;
  818. return 0;
  819. case 142:
  820. /* Element[END_ELEMENT] */
  821. *nextEvent = END_ELEMENT;
  822. return 0;
  823. case 141:
  824. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntry)] */
  825. *nextEvent = START_ELEMENT;
  826. return 0;
  827. case 143:
  828. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntry), END_ELEMENT] */
  829. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  830. if (state->eventCode == 0) {
  831. *nextEvent = START_ELEMENT;
  832. return 0;
  833. }
  834. else if (state->eventCode == 1) {
  835. *nextEvent = END_ELEMENT;
  836. return 0;
  837. }
  838. case 144:
  839. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffStart)] */
  840. *nextEvent = START_ELEMENT;
  841. return 0;
  842. case 145:
  843. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffPMax)] */
  844. *nextEvent = START_ELEMENT;
  845. return 0;
  846. case 147:
  847. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EPrice), END_ELEMENT] */
  848. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  849. if (state->eventCode == 0) {
  850. *nextEvent = START_ELEMENT;
  851. return 0;
  852. }
  853. else if (state->eventCode == 1) {
  854. *nextEvent = END_ELEMENT;
  855. return 0;
  856. }
  857. case 148:
  858. /* Element[END_ELEMENT] */
  859. *nextEvent = END_ELEMENT;
  860. return 0;
  861. case 146:
  862. /* FirstStartTagStartTag[CHARACTERS[UNSIGNED_INTEGER_32]] */
  863. *nextEvent = CHARACTERS;
  864. return 0;
  865. case 149:
  866. /* Element[END_ELEMENT] */
  867. *nextEvent = END_ELEMENT;
  868. return 0;
  869. case 17:
  870. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceScope), END_ELEMENT] */
  871. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  872. if (state->eventCode == 0) {
  873. *nextEvent = START_ELEMENT;
  874. return 0;
  875. }
  876. else if (state->eventCode == 1) {
  877. *nextEvent = START_ELEMENT;
  878. return 0;
  879. }
  880. else if (state->eventCode == 2) {
  881. *nextEvent = END_ELEMENT;
  882. return 0;
  883. }
  884. case 150:
  885. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceScope), END_ELEMENT] */
  886. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  887. if (state->eventCode == 0) {
  888. *nextEvent = START_ELEMENT;
  889. return 0;
  890. }
  891. else if (state->eventCode == 1) {
  892. *nextEvent = END_ELEMENT;
  893. return 0;
  894. }
  895. case 152:
  896. /* Element[END_ELEMENT] */
  897. *nextEvent = END_ELEMENT;
  898. return 0;
  899. case 151:
  900. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  901. *nextEvent = CHARACTERS;
  902. return 0;
  903. case 154:
  904. /* Element[END_ELEMENT] */
  905. *nextEvent = END_ELEMENT;
  906. return 0;
  907. case 153:
  908. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  909. *nextEvent = CHARACTERS;
  910. return 0;
  911. case 155:
  912. /* Element[END_ELEMENT] */
  913. *nextEvent = END_ELEMENT;
  914. return 0;
  915. case 18:
  916. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  917. *nextEvent = START_ELEMENT;
  918. return 0;
  919. case 156:
  920. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceList), END_ELEMENT] */
  921. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  922. if (state->eventCode == 0) {
  923. *nextEvent = START_ELEMENT;
  924. return 0;
  925. }
  926. else if (state->eventCode == 1) {
  927. *nextEvent = END_ELEMENT;
  928. return 0;
  929. }
  930. case 158:
  931. /* Element[END_ELEMENT] */
  932. *nextEvent = END_ELEMENT;
  933. return 0;
  934. case 157:
  935. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  936. *nextEvent = CHARACTERS;
  937. return 0;
  938. case 160:
  939. /* Element[END_ELEMENT] */
  940. *nextEvent = END_ELEMENT;
  941. return 0;
  942. case 159:
  943. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Service)] */
  944. *nextEvent = START_ELEMENT;
  945. return 0;
  946. case 161:
  947. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Service), END_ELEMENT] */
  948. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  949. if (state->eventCode == 0) {
  950. *nextEvent = START_ELEMENT;
  951. return 0;
  952. }
  953. else if (state->eventCode == 1) {
  954. *nextEvent = END_ELEMENT;
  955. return 0;
  956. }
  957. case 162:
  958. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceID)] */
  959. *nextEvent = START_ELEMENT;
  960. return 0;
  961. case 163:
  962. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  963. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  964. if (state->eventCode == 0) {
  965. *nextEvent = START_ELEMENT;
  966. return 0;
  967. }
  968. else if (state->eventCode == 1) {
  969. *nextEvent = START_ELEMENT;
  970. return 0;
  971. }
  972. else if (state->eventCode == 2) {
  973. *nextEvent = START_ELEMENT;
  974. return 0;
  975. }
  976. else if (state->eventCode == 3) {
  977. *nextEvent = END_ELEMENT;
  978. return 0;
  979. }
  980. case 165:
  981. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  982. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  983. if (state->eventCode == 0) {
  984. *nextEvent = START_ELEMENT;
  985. return 0;
  986. }
  987. else if (state->eventCode == 1) {
  988. *nextEvent = START_ELEMENT;
  989. return 0;
  990. }
  991. else if (state->eventCode == 2) {
  992. *nextEvent = END_ELEMENT;
  993. return 0;
  994. }
  995. case 167:
  996. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  997. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  998. if (state->eventCode == 0) {
  999. *nextEvent = START_ELEMENT;
  1000. return 0;
  1001. }
  1002. else if (state->eventCode == 1) {
  1003. *nextEvent = END_ELEMENT;
  1004. return 0;
  1005. }
  1006. case 168:
  1007. /* Element[END_ELEMENT] */
  1008. *nextEvent = END_ELEMENT;
  1009. return 0;
  1010. case 164:
  1011. /* FirstStartTagStartTag[CHARACTERS[BINARY_HEX]] */
  1012. *nextEvent = CHARACTERS;
  1013. return 0;
  1014. case 169:
  1015. /* Element[END_ELEMENT] */
  1016. *nextEvent = END_ELEMENT;
  1017. return 0;
  1018. case 166:
  1019. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  1020. *nextEvent = CHARACTERS;
  1021. return 0;
  1022. case 170:
  1023. /* Element[END_ELEMENT] */
  1024. *nextEvent = END_ELEMENT;
  1025. return 0;
  1026. case 19:
  1027. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceList)] */
  1028. *nextEvent = START_ELEMENT;
  1029. return 0;
  1030. case 171:
  1031. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVPubKey)] */
  1032. *nextEvent = START_ELEMENT;
  1033. return 0;
  1034. case 172:
  1035. /* Element[END_ELEMENT] */
  1036. *nextEvent = END_ELEMENT;
  1037. return 0;
  1038. case 20:
  1039. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1040. *nextEvent = START_ELEMENT;
  1041. return 0;
  1042. case 173:
  1043. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringAuthPubKey), END_ELEMENT] */
  1044. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  1045. if (state->eventCode == 0) {
  1046. *nextEvent = START_ELEMENT;
  1047. return 0;
  1048. }
  1049. else if (state->eventCode == 1) {
  1050. *nextEvent = END_ELEMENT;
  1051. return 0;
  1052. }
  1053. case 175:
  1054. /* Element[END_ELEMENT] */
  1055. *nextEvent = END_ELEMENT;
  1056. return 0;
  1057. case 174:
  1058. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  1059. *nextEvent = CHARACTERS;
  1060. return 0;
  1061. case 176:
  1062. /* Element[END_ELEMENT] */
  1063. *nextEvent = END_ELEMENT;
  1064. return 0;
  1065. case 21:
  1066. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1067. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  1068. if (state->eventCode == 0) {
  1069. *nextEvent = START_ELEMENT;
  1070. return 0;
  1071. }
  1072. else if (state->eventCode == 1) {
  1073. *nextEvent = START_ELEMENT;
  1074. return 0;
  1075. }
  1076. case 177:
  1077. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1078. *nextEvent = START_ELEMENT;
  1079. return 0;
  1080. case 178:
  1081. /* Element[END_ELEMENT] */
  1082. *nextEvent = END_ELEMENT;
  1083. return 0;
  1084. case 22:
  1085. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1086. *nextEvent = START_ELEMENT;
  1087. return 0;
  1088. case 179:
  1089. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEID)] */
  1090. *nextEvent = START_ELEMENT;
  1091. return 0;
  1092. case 181:
  1093. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  1094. *nextEvent = START_ELEMENT;
  1095. return 0;
  1096. case 182:
  1097. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent)] */
  1098. *nextEvent = START_ELEMENT;
  1099. return 0;
  1100. case 183:
  1101. /* Element[END_ELEMENT] */
  1102. *nextEvent = END_ELEMENT;
  1103. return 0;
  1104. case 180:
  1105. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  1106. *nextEvent = CHARACTERS;
  1107. return 0;
  1108. case 184:
  1109. /* Element[END_ELEMENT] */
  1110. *nextEvent = END_ELEMENT;
  1111. return 0;
  1112. case 23:
  1113. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Header)] */
  1114. *nextEvent = START_ELEMENT;
  1115. return 0;
  1116. case 185:
  1117. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Body)] */
  1118. *nextEvent = START_ELEMENT;
  1119. return 0;
  1120. case 187:
  1121. /* Element[END_ELEMENT] */
  1122. *nextEvent = END_ELEMENT;
  1123. return 0;
  1124. case 186:
  1125. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}SessionInformation)] */
  1126. *nextEvent = START_ELEMENT;
  1127. return 0;
  1128. case 189:
  1129. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Notification), END_ELEMENT] */
  1130. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  1131. if (state->eventCode == 0) {
  1132. *nextEvent = START_ELEMENT;
  1133. return 0;
  1134. }
  1135. else if (state->eventCode == 1) {
  1136. *nextEvent = END_ELEMENT;
  1137. return 0;
  1138. }
  1139. case 191:
  1140. /* Element[END_ELEMENT] */
  1141. *nextEvent = END_ELEMENT;
  1142. return 0;
  1143. case 190:
  1144. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}SessionID)] */
  1145. *nextEvent = START_ELEMENT;
  1146. return 0;
  1147. case 193:
  1148. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ProtocolVersion), END_ELEMENT] */
  1149. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  1150. if (state->eventCode == 0) {
  1151. *nextEvent = START_ELEMENT;
  1152. return 0;
  1153. }
  1154. else if (state->eventCode == 1) {
  1155. *nextEvent = START_ELEMENT;
  1156. return 0;
  1157. }
  1158. else if (state->eventCode == 2) {
  1159. *nextEvent = END_ELEMENT;
  1160. return 0;
  1161. }
  1162. case 195:
  1163. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ProtocolVersion), END_ELEMENT] */
  1164. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  1165. if (state->eventCode == 0) {
  1166. *nextEvent = START_ELEMENT;
  1167. return 0;
  1168. }
  1169. else if (state->eventCode == 1) {
  1170. *nextEvent = END_ELEMENT;
  1171. return 0;
  1172. }
  1173. case 196:
  1174. /* Element[END_ELEMENT] */
  1175. *nextEvent = END_ELEMENT;
  1176. return 0;
  1177. case 194:
  1178. /* FirstStartTagStartTag[CHARACTERS[BINARY_HEX]] */
  1179. *nextEvent = CHARACTERS;
  1180. return 0;
  1181. case 198:
  1182. /* Element[END_ELEMENT] */
  1183. *nextEvent = END_ELEMENT;
  1184. return 0;
  1185. case 197:
  1186. /* FirstStartTagStartTag[CHARACTERS[STRING]] */
  1187. *nextEvent = CHARACTERS;
  1188. return 0;
  1189. case 199:
  1190. /* Element[END_ELEMENT] */
  1191. *nextEvent = END_ELEMENT;
  1192. return 0;
  1193. case 192:
  1194. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  1195. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  1196. if (state->eventCode == 0) {
  1197. *nextEvent = START_ELEMENT;
  1198. return 0;
  1199. }
  1200. else if (state->eventCode == 1) {
  1201. *nextEvent = START_ELEMENT;
  1202. return 0;
  1203. }
  1204. else if (state->eventCode == 2) {
  1205. *nextEvent = START_ELEMENT;
  1206. return 0;
  1207. }
  1208. else if (state->eventCode == 3) {
  1209. *nextEvent = END_ELEMENT;
  1210. return 0;
  1211. }
  1212. case 200:
  1213. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  1214. decodeNBitUnsignedInteger(stream, 2, &state->eventCode);
  1215. if (state->eventCode == 0) {
  1216. *nextEvent = START_ELEMENT;
  1217. return 0;
  1218. }
  1219. else if (state->eventCode == 1) {
  1220. *nextEvent = START_ELEMENT;
  1221. return 0;
  1222. }
  1223. else if (state->eventCode == 2) {
  1224. *nextEvent = END_ELEMENT;
  1225. return 0;
  1226. }
  1227. case 202:
  1228. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  1229. decodeNBitUnsignedInteger(stream, 1, &state->eventCode);
  1230. if (state->eventCode == 0) {
  1231. *nextEvent = START_ELEMENT;
  1232. return 0;
  1233. }
  1234. else if (state->eventCode == 1) {
  1235. *nextEvent = END_ELEMENT;
  1236. return 0;
  1237. }
  1238. case 204:
  1239. /* Element[END_ELEMENT] */
  1240. *nextEvent = END_ELEMENT;
  1241. return 0;
  1242. case 201:
  1243. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  1244. *nextEvent = CHARACTERS;
  1245. return 0;
  1246. case 206:
  1247. /* Element[END_ELEMENT] */
  1248. *nextEvent = END_ELEMENT;
  1249. return 0;
  1250. case 203:
  1251. /* FirstStartTag(xsi:type)StartTag[CHARACTERS[STRING]] */
  1252. *nextEvent = CHARACTERS;
  1253. return 0;
  1254. case 207:
  1255. /* Element[END_ELEMENT] */
  1256. *nextEvent = END_ELEMENT;
  1257. return 0;
  1258. case 205:
  1259. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Event)] */
  1260. *nextEvent = START_ELEMENT;
  1261. return 0;
  1262. case 208:
  1263. /* Element[END_ELEMENT] */
  1264. *nextEvent = END_ELEMENT;
  1265. return 0;
  1266. case 209:
  1267. /* FirstStartTagStartTag[CHARACTERS[ENUMERATION]] */
  1268. *nextEvent = CHARACTERS;
  1269. return 0;
  1270. case 210:
  1271. /* Element[END_ELEMENT] */
  1272. *nextEvent = END_ELEMENT;
  1273. return 0;
  1274. case 188:
  1275. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupRes), END_ELEMENT] */
  1276. decodeNBitUnsignedInteger(stream, 5, &state->eventCode);
  1277. if (state->eventCode == 0) {
  1278. *nextEvent = START_ELEMENT;
  1279. return 0;
  1280. }
  1281. else if (state->eventCode == 1) {
  1282. *nextEvent = START_ELEMENT;
  1283. return 0;
  1284. }
  1285. else if (state->eventCode == 2) {
  1286. *nextEvent = START_ELEMENT;
  1287. return 0;
  1288. }
  1289. else if (state->eventCode == 3) {
  1290. *nextEvent = START_ELEMENT;
  1291. return 0;
  1292. }
  1293. else if (state->eventCode == 4) {
  1294. *nextEvent = START_ELEMENT;
  1295. return 0;
  1296. }
  1297. else if (state->eventCode == 5) {
  1298. *nextEvent = START_ELEMENT;
  1299. return 0;
  1300. }
  1301. else if (state->eventCode == 6) {
  1302. *nextEvent = START_ELEMENT;
  1303. return 0;
  1304. }
  1305. else if (state->eventCode == 7) {
  1306. *nextEvent = START_ELEMENT;
  1307. return 0;
  1308. }
  1309. else if (state->eventCode == 8) {
  1310. *nextEvent = START_ELEMENT;
  1311. return 0;
  1312. }
  1313. else if (state->eventCode == 9) {
  1314. *nextEvent = START_ELEMENT;
  1315. return 0;
  1316. }
  1317. else if (state->eventCode == 10) {
  1318. *nextEvent = START_ELEMENT;
  1319. return 0;
  1320. }
  1321. else if (state->eventCode == 11) {
  1322. *nextEvent = START_ELEMENT;
  1323. return 0;
  1324. }
  1325. else if (state->eventCode == 12) {
  1326. *nextEvent = START_ELEMENT;
  1327. return 0;
  1328. }
  1329. else if (state->eventCode == 13) {
  1330. *nextEvent = START_ELEMENT;
  1331. return 0;
  1332. }
  1333. else if (state->eventCode == 14) {
  1334. *nextEvent = START_ELEMENT;
  1335. return 0;
  1336. }
  1337. else if (state->eventCode == 15) {
  1338. *nextEvent = START_ELEMENT;
  1339. return 0;
  1340. }
  1341. else if (state->eventCode == 16) {
  1342. *nextEvent = START_ELEMENT;
  1343. return 0;
  1344. }
  1345. else if (state->eventCode == 17) {
  1346. *nextEvent = START_ELEMENT;
  1347. return 0;
  1348. }
  1349. else if (state->eventCode == 18) {
  1350. *nextEvent = START_ELEMENT;
  1351. return 0;
  1352. }
  1353. else if (state->eventCode == 19) {
  1354. *nextEvent = END_ELEMENT;
  1355. return 0;
  1356. }
  1357. case 211:
  1358. /* Element[END_ELEMENT] */
  1359. *nextEvent = END_ELEMENT;
  1360. return 0;
  1361. default:
  1362. *nextEvent = ERROR;
  1363. return -1;
  1364. }
  1365. return -1;
  1366. }
  1367. int exiDecodeStartDocument(bitstream_t* stream, exi_state_t* state) {
  1368. if ( state->grammarStack[state->stackIndex] == 0 ) {
  1369. /* move on */
  1370. state->grammarStack[state->stackIndex] = 1;
  1371. return 0;
  1372. }
  1373. return -1;
  1374. }
  1375. int exiDecodeEndDocument(bitstream_t* stream, exi_state_t* state) {
  1376. if ( state->grammarStack[state->stackIndex] == 2) {
  1377. return 0;
  1378. }
  1379. return -1;
  1380. }
  1381. int exiDecodeStartElement(bitstream_t* stream, exi_state_t* state,
  1382. eqname_t* se) {
  1383. switch (state->grammarStack[state->stackIndex]) {
  1384. case 1:
  1385. /* DocContent[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupRes), START_ELEMENT({urn:iso:15118:2:2010:MsgDef}V2G_Message), START_ELEMENT_GENERIC] */
  1386. if (state->eventCode == 0) {
  1387. se->localPart = 2; /* "BodyElement" */
  1388. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  1389. /* move on */
  1390. state->grammarStack[state->stackIndex] = 2;
  1391. /* push element on stack */
  1392. return exiPushStack(state, 3, se);
  1393. }
  1394. else if (state->eventCode == 1) {
  1395. se->localPart = 11; /* "LineLockReq" */
  1396. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1397. /* move on */
  1398. state->grammarStack[state->stackIndex] = 2;
  1399. /* push element on stack */
  1400. return exiPushStack(state, 5, se);
  1401. }
  1402. else if (state->eventCode == 2) {
  1403. se->localPart = 13; /* "LineLockRes" */
  1404. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1405. /* move on */
  1406. state->grammarStack[state->stackIndex] = 2;
  1407. /* push element on stack */
  1408. return exiPushStack(state, 6, se);
  1409. }
  1410. else if (state->eventCode == 3) {
  1411. se->localPart = 17; /* "MeteringReceiptReq" */
  1412. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1413. /* move on */
  1414. state->grammarStack[state->stackIndex] = 2;
  1415. /* push element on stack */
  1416. return exiPushStack(state, 7, se);
  1417. }
  1418. else if (state->eventCode == 4) {
  1419. se->localPart = 19; /* "MeteringReceiptRes" */
  1420. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1421. /* move on */
  1422. state->grammarStack[state->stackIndex] = 2;
  1423. /* push element on stack */
  1424. return exiPushStack(state, 8, se);
  1425. }
  1426. else if (state->eventCode == 5) {
  1427. se->localPart = 21; /* "MeteringStatusReq" */
  1428. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1429. /* move on */
  1430. state->grammarStack[state->stackIndex] = 2;
  1431. /* push element on stack */
  1432. return exiPushStack(state, 9, se);
  1433. }
  1434. else if (state->eventCode == 6) {
  1435. se->localPart = 23; /* "MeteringStatusRes" */
  1436. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1437. /* move on */
  1438. state->grammarStack[state->stackIndex] = 2;
  1439. /* push element on stack */
  1440. return exiPushStack(state, 10, se);
  1441. }
  1442. else if (state->eventCode == 7) {
  1443. se->localPart = 33; /* "PaymentDetailsReq" */
  1444. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1445. /* move on */
  1446. state->grammarStack[state->stackIndex] = 2;
  1447. /* push element on stack */
  1448. return exiPushStack(state, 11, se);
  1449. }
  1450. else if (state->eventCode == 8) {
  1451. se->localPart = 35; /* "PaymentDetailsRes" */
  1452. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1453. /* move on */
  1454. state->grammarStack[state->stackIndex] = 2;
  1455. /* push element on stack */
  1456. return exiPushStack(state, 12, se);
  1457. }
  1458. else if (state->eventCode == 9) {
  1459. se->localPart = 37; /* "PowerDeliveryReq" */
  1460. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1461. /* move on */
  1462. state->grammarStack[state->stackIndex] = 2;
  1463. /* push element on stack */
  1464. return exiPushStack(state, 13, se);
  1465. }
  1466. else if (state->eventCode == 10) {
  1467. se->localPart = 39; /* "PowerDeliveryRes" */
  1468. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1469. /* move on */
  1470. state->grammarStack[state->stackIndex] = 2;
  1471. /* push element on stack */
  1472. return exiPushStack(state, 14, se);
  1473. }
  1474. else if (state->eventCode == 11) {
  1475. se->localPart = 41; /* "PowerDiscoveryReq" */
  1476. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1477. /* move on */
  1478. state->grammarStack[state->stackIndex] = 2;
  1479. /* push element on stack */
  1480. return exiPushStack(state, 15, se);
  1481. }
  1482. else if (state->eventCode == 12) {
  1483. se->localPart = 43; /* "PowerDiscoveryRes" */
  1484. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1485. /* move on */
  1486. state->grammarStack[state->stackIndex] = 2;
  1487. /* push element on stack */
  1488. return exiPushStack(state, 16, se);
  1489. }
  1490. else if (state->eventCode == 13) {
  1491. se->localPart = 48; /* "ServiceDiscoveryReq" */
  1492. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1493. /* move on */
  1494. state->grammarStack[state->stackIndex] = 2;
  1495. /* push element on stack */
  1496. return exiPushStack(state, 17, se);
  1497. }
  1498. else if (state->eventCode == 14) {
  1499. se->localPart = 50; /* "ServiceDiscoveryRes" */
  1500. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1501. /* move on */
  1502. state->grammarStack[state->stackIndex] = 2;
  1503. /* push element on stack */
  1504. return exiPushStack(state, 18, se);
  1505. }
  1506. else if (state->eventCode == 15) {
  1507. se->localPart = 53; /* "ServicePaymentSelectionReq" */
  1508. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1509. /* move on */
  1510. state->grammarStack[state->stackIndex] = 2;
  1511. /* push element on stack */
  1512. return exiPushStack(state, 19, se);
  1513. }
  1514. else if (state->eventCode == 16) {
  1515. se->localPart = 55; /* "ServicePaymentSelectionRes" */
  1516. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1517. /* move on */
  1518. state->grammarStack[state->stackIndex] = 2;
  1519. /* push element on stack */
  1520. return exiPushStack(state, 20, se);
  1521. }
  1522. else if (state->eventCode == 17) {
  1523. se->localPart = 59; /* "SessionSetupReq" */
  1524. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1525. /* move on */
  1526. state->grammarStack[state->stackIndex] = 2;
  1527. /* push element on stack */
  1528. return exiPushStack(state, 21, se);
  1529. }
  1530. else if (state->eventCode == 18) {
  1531. se->localPart = 61; /* "SessionSetupRes" */
  1532. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1533. /* move on */
  1534. state->grammarStack[state->stackIndex] = 2;
  1535. /* push element on stack */
  1536. return exiPushStack(state, 22, se);
  1537. }
  1538. else if (state->eventCode == 19) {
  1539. se->localPart = 8; /* "V2G_Message" */
  1540. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  1541. /* move on */
  1542. state->grammarStack[state->stackIndex] = 2;
  1543. /* push element on stack */
  1544. return exiPushStack(state, 23, se);
  1545. }
  1546. break;
  1547. case 5:
  1548. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1549. se->localPart = 32; /* "PEVStatus" */
  1550. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1551. /* move on */
  1552. state->grammarStack[state->stackIndex] = 24;
  1553. /* push element on stack */
  1554. return exiPushStack(state, 25, se);
  1555. break;
  1556. case 6:
  1557. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1558. se->localPart = 47; /* "ResponseCode" */
  1559. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1560. /* move on */
  1561. state->grammarStack[state->stackIndex] = 33;
  1562. /* push element on stack */
  1563. return exiPushStack(state, 34, se);
  1564. break;
  1565. case 7:
  1566. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1567. if (state->eventCode == 0) {
  1568. se->localPart = 26; /* "PEVID" */
  1569. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1570. /* move on */
  1571. state->grammarStack[state->stackIndex] = 52;
  1572. /* push element on stack */
  1573. return exiPushStack(state, 53, se);
  1574. }
  1575. else if (state->eventCode == 1) {
  1576. se->localPart = 32; /* "PEVStatus" */
  1577. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1578. /* move on */
  1579. state->grammarStack[state->stackIndex] = 54;
  1580. /* push element on stack */
  1581. return exiPushStack(state, 25, se);
  1582. }
  1583. break;
  1584. case 8:
  1585. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1586. se->localPart = 47; /* "ResponseCode" */
  1587. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1588. /* move on */
  1589. state->grammarStack[state->stackIndex] = 81;
  1590. /* push element on stack */
  1591. return exiPushStack(state, 82, se);
  1592. break;
  1593. case 10:
  1594. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1595. se->localPart = 47; /* "ResponseCode" */
  1596. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1597. /* move on */
  1598. state->grammarStack[state->stackIndex] = 84;
  1599. /* push element on stack */
  1600. return exiPushStack(state, 85, se);
  1601. break;
  1602. case 11:
  1603. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ContractID)] */
  1604. se->localPart = 1; /* "ContractID" */
  1605. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1606. /* move on */
  1607. state->grammarStack[state->stackIndex] = 95;
  1608. /* push element on stack */
  1609. return exiPushStack(state, 96, se);
  1610. break;
  1611. case 12:
  1612. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1613. se->localPart = 47; /* "ResponseCode" */
  1614. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1615. /* move on */
  1616. state->grammarStack[state->stackIndex] = 98;
  1617. /* push element on stack */
  1618. return exiPushStack(state, 99, se);
  1619. break;
  1620. case 13:
  1621. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1622. se->localPart = 32; /* "PEVStatus" */
  1623. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1624. /* move on */
  1625. state->grammarStack[state->stackIndex] = 101;
  1626. /* push element on stack */
  1627. return exiPushStack(state, 25, se);
  1628. break;
  1629. case 14:
  1630. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1631. se->localPart = 47; /* "ResponseCode" */
  1632. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1633. /* move on */
  1634. state->grammarStack[state->stackIndex] = 108;
  1635. /* push element on stack */
  1636. return exiPushStack(state, 109, se);
  1637. break;
  1638. case 15:
  1639. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1640. se->localPart = 32; /* "PEVStatus" */
  1641. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1642. /* move on */
  1643. state->grammarStack[state->stackIndex] = 111;
  1644. /* push element on stack */
  1645. return exiPushStack(state, 25, se);
  1646. break;
  1647. case 16:
  1648. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1649. se->localPart = 47; /* "ResponseCode" */
  1650. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1651. /* move on */
  1652. state->grammarStack[state->stackIndex] = 120;
  1653. /* push element on stack */
  1654. return exiPushStack(state, 121, se);
  1655. break;
  1656. case 17:
  1657. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceScope), END_ELEMENT] */
  1658. if (state->eventCode == 0) {
  1659. se->localPart = 58; /* "ServiceType" */
  1660. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1661. /* move on */
  1662. state->grammarStack[state->stackIndex] = 150;
  1663. /* push element on stack */
  1664. return exiPushStack(state, 151, se);
  1665. }
  1666. else if (state->eventCode == 1) {
  1667. se->localPart = 57; /* "ServiceScope" */
  1668. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1669. /* move on */
  1670. state->grammarStack[state->stackIndex] = 152;
  1671. /* push element on stack */
  1672. return exiPushStack(state, 153, se);
  1673. }
  1674. break;
  1675. case 18:
  1676. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1677. se->localPart = 47; /* "ResponseCode" */
  1678. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1679. /* move on */
  1680. state->grammarStack[state->stackIndex] = 156;
  1681. /* push element on stack */
  1682. return exiPushStack(state, 157, se);
  1683. break;
  1684. case 19:
  1685. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceList)] */
  1686. se->localPart = 52; /* "ServiceList" */
  1687. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1688. /* move on */
  1689. state->grammarStack[state->stackIndex] = 171;
  1690. /* push element on stack */
  1691. return exiPushStack(state, 159, se);
  1692. break;
  1693. case 20:
  1694. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1695. se->localPart = 47; /* "ResponseCode" */
  1696. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1697. /* move on */
  1698. state->grammarStack[state->stackIndex] = 173;
  1699. /* push element on stack */
  1700. return exiPushStack(state, 174, se);
  1701. break;
  1702. case 21:
  1703. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVID), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1704. if (state->eventCode == 0) {
  1705. se->localPart = 26; /* "PEVID" */
  1706. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1707. /* move on */
  1708. state->grammarStack[state->stackIndex] = 177;
  1709. /* push element on stack */
  1710. return exiPushStack(state, 53, se);
  1711. }
  1712. else if (state->eventCode == 1) {
  1713. se->localPart = 32; /* "PEVStatus" */
  1714. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1715. /* move on */
  1716. state->grammarStack[state->stackIndex] = 178;
  1717. /* push element on stack */
  1718. return exiPushStack(state, 25, se);
  1719. }
  1720. break;
  1721. case 22:
  1722. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ResponseCode)] */
  1723. se->localPart = 47; /* "ResponseCode" */
  1724. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1725. /* move on */
  1726. state->grammarStack[state->stackIndex] = 179;
  1727. /* push element on stack */
  1728. return exiPushStack(state, 180, se);
  1729. break;
  1730. case 23:
  1731. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Header)] */
  1732. se->localPart = 4; /* "Header" */
  1733. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  1734. /* move on */
  1735. state->grammarStack[state->stackIndex] = 185;
  1736. /* push element on stack */
  1737. return exiPushStack(state, 186, se);
  1738. break;
  1739. case 24:
  1740. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ReqLockStatus)] */
  1741. se->localPart = 45; /* "ReqLockStatus" */
  1742. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1743. /* move on */
  1744. state->grammarStack[state->stackIndex] = 26;
  1745. /* push element on stack */
  1746. return exiPushStack(state, 27, se);
  1747. break;
  1748. case 25:
  1749. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ConnectorLocked)] */
  1750. se->localPart = 4; /* "ConnectorLocked" */
  1751. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1752. /* move on */
  1753. state->grammarStack[state->stackIndex] = 28;
  1754. /* push element on stack */
  1755. return exiPushStack(state, 27, se);
  1756. break;
  1757. case 28:
  1758. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargerStandby)] */
  1759. se->localPart = 0; /* "ChargerStandby" */
  1760. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1761. /* move on */
  1762. state->grammarStack[state->stackIndex] = 29;
  1763. /* push element on stack */
  1764. return exiPushStack(state, 30, se);
  1765. break;
  1766. case 33:
  1767. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  1768. se->localPart = 7; /* "EVSEStatus" */
  1769. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1770. /* move on */
  1771. state->grammarStack[state->stackIndex] = 35;
  1772. /* push element on stack */
  1773. return exiPushStack(state, 36, se);
  1774. break;
  1775. case 36:
  1776. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FatalError)] */
  1777. se->localPart = 12; /* "FatalError" */
  1778. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1779. /* move on */
  1780. state->grammarStack[state->stackIndex] = 38;
  1781. /* push element on stack */
  1782. return exiPushStack(state, 39, se);
  1783. break;
  1784. case 38:
  1785. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EVSEStandby)] */
  1786. se->localPart = 7; /* "EVSEStandby" */
  1787. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1788. /* move on */
  1789. state->grammarStack[state->stackIndex] = 40;
  1790. /* push element on stack */
  1791. return exiPushStack(state, 30, se);
  1792. break;
  1793. case 40:
  1794. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ConnectorLocked)] */
  1795. se->localPart = 4; /* "ConnectorLocked" */
  1796. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1797. /* move on */
  1798. state->grammarStack[state->stackIndex] = 41;
  1799. /* push element on stack */
  1800. return exiPushStack(state, 27, se);
  1801. break;
  1802. case 41:
  1803. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}PowerSwitchClosed)] */
  1804. se->localPart = 24; /* "PowerSwitchClosed" */
  1805. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1806. /* move on */
  1807. state->grammarStack[state->stackIndex] = 42;
  1808. /* push element on stack */
  1809. return exiPushStack(state, 43, se);
  1810. break;
  1811. case 42:
  1812. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}RCD)] */
  1813. se->localPart = 26; /* "RCD" */
  1814. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1815. /* move on */
  1816. state->grammarStack[state->stackIndex] = 44;
  1817. /* push element on stack */
  1818. return exiPushStack(state, 45, se);
  1819. break;
  1820. case 44:
  1821. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ShutDownTime)] */
  1822. se->localPart = 37; /* "ShutDownTime" */
  1823. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1824. /* move on */
  1825. state->grammarStack[state->stackIndex] = 46;
  1826. /* push element on stack */
  1827. return exiPushStack(state, 47, se);
  1828. break;
  1829. case 52:
  1830. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  1831. se->localPart = 32; /* "PEVStatus" */
  1832. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1833. /* move on */
  1834. state->grammarStack[state->stackIndex] = 54;
  1835. /* push element on stack */
  1836. return exiPushStack(state, 25, se);
  1837. break;
  1838. case 54:
  1839. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff)] */
  1840. if (state->eventCode == 0) {
  1841. se->localPart = 63; /* "TCurrent" */
  1842. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1843. /* move on */
  1844. state->grammarStack[state->stackIndex] = 55;
  1845. /* push element on stack */
  1846. return exiPushStack(state, 47, se);
  1847. }
  1848. else if (state->eventCode == 1) {
  1849. se->localPart = 64; /* "Tariff" */
  1850. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1851. /* move on */
  1852. state->grammarStack[state->stackIndex] = 56;
  1853. /* push element on stack */
  1854. return exiPushStack(state, 57, se);
  1855. }
  1856. break;
  1857. case 55:
  1858. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff)] */
  1859. se->localPart = 64; /* "Tariff" */
  1860. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1861. /* move on */
  1862. state->grammarStack[state->stackIndex] = 56;
  1863. /* push element on stack */
  1864. return exiPushStack(state, 57, se);
  1865. break;
  1866. case 56:
  1867. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo)] */
  1868. se->localPart = 15; /* "MeterInfo" */
  1869. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  1870. /* move on */
  1871. state->grammarStack[state->stackIndex] = 58;
  1872. /* push element on stack */
  1873. return exiPushStack(state, 59, se);
  1874. break;
  1875. case 59:
  1876. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterID), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterPubKey), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  1877. if (state->eventCode == 0) {
  1878. se->localPart = 16; /* "MeterID" */
  1879. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1880. /* move on */
  1881. state->grammarStack[state->stackIndex] = 62;
  1882. /* push element on stack */
  1883. return exiPushStack(state, 63, se);
  1884. }
  1885. else if (state->eventCode == 1) {
  1886. se->localPart = 18; /* "MeterPubKey" */
  1887. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1888. /* move on */
  1889. state->grammarStack[state->stackIndex] = 64;
  1890. /* push element on stack */
  1891. return exiPushStack(state, 65, se);
  1892. }
  1893. else if (state->eventCode == 2) {
  1894. se->localPart = 19; /* "MeterReading" */
  1895. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1896. /* move on */
  1897. state->grammarStack[state->stackIndex] = 66;
  1898. /* push element on stack */
  1899. return exiPushStack(state, 67, se);
  1900. }
  1901. else if (state->eventCode == 3) {
  1902. se->localPart = 20; /* "MeterStatus" */
  1903. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1904. /* move on */
  1905. state->grammarStack[state->stackIndex] = 68;
  1906. /* push element on stack */
  1907. return exiPushStack(state, 69, se);
  1908. }
  1909. else if (state->eventCode == 4) {
  1910. se->localPart = 38; /* "TMeter" */
  1911. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1912. /* move on */
  1913. state->grammarStack[state->stackIndex] = 70;
  1914. /* push element on stack */
  1915. return exiPushStack(state, 47, se);
  1916. }
  1917. break;
  1918. case 62:
  1919. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterPubKey), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  1920. if (state->eventCode == 0) {
  1921. se->localPart = 18; /* "MeterPubKey" */
  1922. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1923. /* move on */
  1924. state->grammarStack[state->stackIndex] = 64;
  1925. /* push element on stack */
  1926. return exiPushStack(state, 65, se);
  1927. }
  1928. else if (state->eventCode == 1) {
  1929. se->localPart = 19; /* "MeterReading" */
  1930. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1931. /* move on */
  1932. state->grammarStack[state->stackIndex] = 66;
  1933. /* push element on stack */
  1934. return exiPushStack(state, 67, se);
  1935. }
  1936. else if (state->eventCode == 2) {
  1937. se->localPart = 20; /* "MeterStatus" */
  1938. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1939. /* move on */
  1940. state->grammarStack[state->stackIndex] = 68;
  1941. /* push element on stack */
  1942. return exiPushStack(state, 69, se);
  1943. }
  1944. else if (state->eventCode == 3) {
  1945. se->localPart = 38; /* "TMeter" */
  1946. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1947. /* move on */
  1948. state->grammarStack[state->stackIndex] = 70;
  1949. /* push element on stack */
  1950. return exiPushStack(state, 47, se);
  1951. }
  1952. break;
  1953. case 64:
  1954. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterReading), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  1955. if (state->eventCode == 0) {
  1956. se->localPart = 19; /* "MeterReading" */
  1957. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1958. /* move on */
  1959. state->grammarStack[state->stackIndex] = 66;
  1960. /* push element on stack */
  1961. return exiPushStack(state, 67, se);
  1962. }
  1963. else if (state->eventCode == 1) {
  1964. se->localPart = 20; /* "MeterStatus" */
  1965. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1966. /* move on */
  1967. state->grammarStack[state->stackIndex] = 68;
  1968. /* push element on stack */
  1969. return exiPushStack(state, 69, se);
  1970. }
  1971. else if (state->eventCode == 2) {
  1972. se->localPart = 38; /* "TMeter" */
  1973. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1974. /* move on */
  1975. state->grammarStack[state->stackIndex] = 70;
  1976. /* push element on stack */
  1977. return exiPushStack(state, 47, se);
  1978. }
  1979. break;
  1980. case 66:
  1981. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}MeterStatus), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  1982. if (state->eventCode == 0) {
  1983. se->localPart = 20; /* "MeterStatus" */
  1984. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1985. /* move on */
  1986. state->grammarStack[state->stackIndex] = 68;
  1987. /* push element on stack */
  1988. return exiPushStack(state, 69, se);
  1989. }
  1990. else if (state->eventCode == 1) {
  1991. se->localPart = 38; /* "TMeter" */
  1992. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  1993. /* move on */
  1994. state->grammarStack[state->stackIndex] = 70;
  1995. /* push element on stack */
  1996. return exiPushStack(state, 47, se);
  1997. }
  1998. break;
  1999. case 67:
  2000. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Multiplier)] */
  2001. se->localPart = 21; /* "Multiplier" */
  2002. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2003. /* move on */
  2004. state->grammarStack[state->stackIndex] = 73;
  2005. /* push element on stack */
  2006. return exiPushStack(state, 74, se);
  2007. break;
  2008. case 68:
  2009. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TMeter), END_ELEMENT] */
  2010. if (state->eventCode == 0) {
  2011. se->localPart = 38; /* "TMeter" */
  2012. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2013. /* move on */
  2014. state->grammarStack[state->stackIndex] = 70;
  2015. /* push element on stack */
  2016. return exiPushStack(state, 47, se);
  2017. }
  2018. break;
  2019. case 73:
  2020. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Unit)] */
  2021. se->localPart = 50; /* "Unit" */
  2022. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2023. /* move on */
  2024. state->grammarStack[state->stackIndex] = 75;
  2025. /* push element on stack */
  2026. return exiPushStack(state, 74, se);
  2027. break;
  2028. case 75:
  2029. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Value)] */
  2030. se->localPart = 51; /* "Value" */
  2031. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2032. /* move on */
  2033. state->grammarStack[state->stackIndex] = 76;
  2034. /* push element on stack */
  2035. return exiPushStack(state, 77, se);
  2036. break;
  2037. case 84:
  2038. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEID)] */
  2039. se->localPart = 3; /* "EVSEID" */
  2040. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2041. /* move on */
  2042. state->grammarStack[state->stackIndex] = 86;
  2043. /* push element on stack */
  2044. return exiPushStack(state, 87, se);
  2045. break;
  2046. case 86:
  2047. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  2048. se->localPart = 7; /* "EVSEStatus" */
  2049. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2050. /* move on */
  2051. state->grammarStack[state->stackIndex] = 88;
  2052. /* push element on stack */
  2053. return exiPushStack(state, 36, se);
  2054. break;
  2055. case 88:
  2056. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent)] */
  2057. se->localPart = 63; /* "TCurrent" */
  2058. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2059. /* move on */
  2060. state->grammarStack[state->stackIndex] = 89;
  2061. /* push element on stack */
  2062. return exiPushStack(state, 47, se);
  2063. break;
  2064. case 89:
  2065. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEMaxPower)] */
  2066. se->localPart = 6; /* "EVSEMaxPower" */
  2067. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2068. /* move on */
  2069. state->grammarStack[state->stackIndex] = 90;
  2070. /* push element on stack */
  2071. return exiPushStack(state, 67, se);
  2072. break;
  2073. case 90:
  2074. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PCurrent), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo), END_ELEMENT] */
  2075. if (state->eventCode == 0) {
  2076. se->localPart = 25; /* "PCurrent" */
  2077. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2078. /* move on */
  2079. state->grammarStack[state->stackIndex] = 91;
  2080. /* push element on stack */
  2081. return exiPushStack(state, 67, se);
  2082. }
  2083. else if (state->eventCode == 1) {
  2084. se->localPart = 15; /* "MeterInfo" */
  2085. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2086. /* move on */
  2087. state->grammarStack[state->stackIndex] = 92;
  2088. /* push element on stack */
  2089. return exiPushStack(state, 59, se);
  2090. }
  2091. break;
  2092. case 91:
  2093. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeterInfo), END_ELEMENT] */
  2094. if (state->eventCode == 0) {
  2095. se->localPart = 15; /* "MeterInfo" */
  2096. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2097. /* move on */
  2098. state->grammarStack[state->stackIndex] = 92;
  2099. /* push element on stack */
  2100. return exiPushStack(state, 59, se);
  2101. }
  2102. break;
  2103. case 101:
  2104. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ReqSwitchStatus)] */
  2105. se->localPart = 46; /* "ReqSwitchStatus" */
  2106. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2107. /* move on */
  2108. state->grammarStack[state->stackIndex] = 102;
  2109. /* push element on stack */
  2110. return exiPushStack(state, 43, se);
  2111. break;
  2112. case 102:
  2113. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}Tariff), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ChargingProfile), END_ELEMENT] */
  2114. if (state->eventCode == 0) {
  2115. se->localPart = 64; /* "Tariff" */
  2116. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2117. /* move on */
  2118. state->grammarStack[state->stackIndex] = 103;
  2119. /* push element on stack */
  2120. return exiPushStack(state, 57, se);
  2121. }
  2122. else if (state->eventCode == 1) {
  2123. se->localPart = 0; /* "ChargingProfile" */
  2124. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2125. /* move on */
  2126. state->grammarStack[state->stackIndex] = 104;
  2127. /* push element on stack */
  2128. return exiPushStack(state, 105, se);
  2129. }
  2130. break;
  2131. case 103:
  2132. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ChargingProfile), END_ELEMENT] */
  2133. if (state->eventCode == 0) {
  2134. se->localPart = 0; /* "ChargingProfile" */
  2135. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2136. /* move on */
  2137. state->grammarStack[state->stackIndex] = 104;
  2138. /* push element on stack */
  2139. return exiPushStack(state, 105, se);
  2140. }
  2141. break;
  2142. case 105:
  2143. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargingProfileEntryStart)] */
  2144. se->localPart = 2; /* "ChargingProfileEntryStart" */
  2145. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2146. /* move on */
  2147. state->grammarStack[state->stackIndex] = 106;
  2148. /* push element on stack */
  2149. return exiPushStack(state, 47, se);
  2150. break;
  2151. case 106:
  2152. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ChargingProfileEntryMaxPower)] */
  2153. se->localPart = 1; /* "ChargingProfileEntryMaxPower" */
  2154. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2155. /* move on */
  2156. state->grammarStack[state->stackIndex] = 107;
  2157. /* push element on stack */
  2158. return exiPushStack(state, 67, se);
  2159. break;
  2160. case 111:
  2161. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EoC)] */
  2162. se->localPart = 10; /* "EoC" */
  2163. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2164. /* move on */
  2165. state->grammarStack[state->stackIndex] = 112;
  2166. /* push element on stack */
  2167. return exiPushStack(state, 47, se);
  2168. break;
  2169. case 112:
  2170. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EAmount)] */
  2171. se->localPart = 2; /* "EAmount" */
  2172. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2173. /* move on */
  2174. state->grammarStack[state->stackIndex] = 113;
  2175. /* push element on stack */
  2176. return exiPushStack(state, 67, se);
  2177. break;
  2178. case 113:
  2179. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxPower)] */
  2180. se->localPart = 28; /* "PEVMaxPower" */
  2181. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2182. /* move on */
  2183. state->grammarStack[state->stackIndex] = 114;
  2184. /* push element on stack */
  2185. return exiPushStack(state, 67, se);
  2186. break;
  2187. case 114:
  2188. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxPhases)] */
  2189. se->localPart = 27; /* "PEVMaxPhases" */
  2190. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2191. /* move on */
  2192. state->grammarStack[state->stackIndex] = 115;
  2193. /* push element on stack */
  2194. return exiPushStack(state, 116, se);
  2195. break;
  2196. case 115:
  2197. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMaxVoltage)] */
  2198. se->localPart = 29; /* "PEVMaxVoltage" */
  2199. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2200. /* move on */
  2201. state->grammarStack[state->stackIndex] = 117;
  2202. /* push element on stack */
  2203. return exiPushStack(state, 67, se);
  2204. break;
  2205. case 117:
  2206. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVMinVoltage)] */
  2207. se->localPart = 30; /* "PEVMinVoltage" */
  2208. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2209. /* move on */
  2210. state->grammarStack[state->stackIndex] = 118;
  2211. /* push element on stack */
  2212. return exiPushStack(state, 67, se);
  2213. break;
  2214. case 120:
  2215. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  2216. se->localPart = 7; /* "EVSEStatus" */
  2217. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2218. /* move on */
  2219. state->grammarStack[state->stackIndex] = 122;
  2220. /* push element on stack */
  2221. return exiPushStack(state, 36, se);
  2222. break;
  2223. case 122:
  2224. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEVoltage)] */
  2225. se->localPart = 8; /* "EVSEVoltage" */
  2226. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2227. /* move on */
  2228. state->grammarStack[state->stackIndex] = 123;
  2229. /* push element on stack */
  2230. return exiPushStack(state, 67, se);
  2231. break;
  2232. case 123:
  2233. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEIMax)] */
  2234. se->localPart = 4; /* "EVSEIMax" */
  2235. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2236. /* move on */
  2237. state->grammarStack[state->stackIndex] = 124;
  2238. /* push element on stack */
  2239. return exiPushStack(state, 67, se);
  2240. break;
  2241. case 124:
  2242. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEMaxPhases)] */
  2243. se->localPart = 5; /* "EVSEMaxPhases" */
  2244. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2245. /* move on */
  2246. state->grammarStack[state->stackIndex] = 125;
  2247. /* push element on stack */
  2248. return exiPushStack(state, 116, se);
  2249. break;
  2250. case 125:
  2251. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EnergyProvider), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TariffTable), END_ELEMENT] */
  2252. if (state->eventCode == 0) {
  2253. se->localPart = 9; /* "EnergyProvider" */
  2254. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2255. /* move on */
  2256. state->grammarStack[state->stackIndex] = 126;
  2257. /* push element on stack */
  2258. return exiPushStack(state, 127, se);
  2259. }
  2260. else if (state->eventCode == 1) {
  2261. se->localPart = 65; /* "TariffTable" */
  2262. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2263. /* move on */
  2264. state->grammarStack[state->stackIndex] = 128;
  2265. /* push element on stack */
  2266. return exiPushStack(state, 129, se);
  2267. }
  2268. break;
  2269. case 126:
  2270. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TariffTable), END_ELEMENT] */
  2271. if (state->eventCode == 0) {
  2272. se->localPart = 65; /* "TariffTable" */
  2273. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2274. /* move on */
  2275. state->grammarStack[state->stackIndex] = 128;
  2276. /* push element on stack */
  2277. return exiPushStack(state, 129, se);
  2278. }
  2279. break;
  2280. case 129:
  2281. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Currency)] */
  2282. se->localPart = 5; /* "Currency" */
  2283. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2284. /* move on */
  2285. state->grammarStack[state->stackIndex] = 132;
  2286. /* push element on stack */
  2287. return exiPushStack(state, 133, se);
  2288. break;
  2289. case 132:
  2290. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Tariff)] */
  2291. se->localPart = 39; /* "Tariff" */
  2292. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2293. /* move on */
  2294. state->grammarStack[state->stackIndex] = 134;
  2295. /* push element on stack */
  2296. return exiPushStack(state, 135, se);
  2297. break;
  2298. case 134:
  2299. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Tariff), END_ELEMENT] */
  2300. if (state->eventCode == 0) {
  2301. se->localPart = 39; /* "Tariff" */
  2302. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2303. /* move on */
  2304. state->grammarStack[state->stackIndex] = 134;
  2305. /* push element on stack */
  2306. return exiPushStack(state, 135, se);
  2307. }
  2308. break;
  2309. case 135:
  2310. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffID)] */
  2311. se->localPart = 46; /* "TariffID" */
  2312. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2313. /* move on */
  2314. state->grammarStack[state->stackIndex] = 137;
  2315. /* push element on stack */
  2316. return exiPushStack(state, 57, se);
  2317. break;
  2318. case 137:
  2319. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffDescription), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntries)] */
  2320. if (state->eventCode == 0) {
  2321. se->localPart = 41; /* "TariffDescription" */
  2322. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2323. /* move on */
  2324. state->grammarStack[state->stackIndex] = 138;
  2325. /* push element on stack */
  2326. return exiPushStack(state, 139, se);
  2327. }
  2328. else if (state->eventCode == 1) {
  2329. se->localPart = 42; /* "TariffEntries" */
  2330. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2331. /* move on */
  2332. state->grammarStack[state->stackIndex] = 140;
  2333. /* push element on stack */
  2334. return exiPushStack(state, 141, se);
  2335. }
  2336. break;
  2337. case 138:
  2338. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntries)] */
  2339. se->localPart = 42; /* "TariffEntries" */
  2340. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2341. /* move on */
  2342. state->grammarStack[state->stackIndex] = 140;
  2343. /* push element on stack */
  2344. return exiPushStack(state, 141, se);
  2345. break;
  2346. case 141:
  2347. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntry)] */
  2348. se->localPart = 44; /* "TariffEntry" */
  2349. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2350. /* move on */
  2351. state->grammarStack[state->stackIndex] = 143;
  2352. /* push element on stack */
  2353. return exiPushStack(state, 144, se);
  2354. break;
  2355. case 143:
  2356. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffEntry), END_ELEMENT] */
  2357. if (state->eventCode == 0) {
  2358. se->localPart = 44; /* "TariffEntry" */
  2359. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2360. /* move on */
  2361. state->grammarStack[state->stackIndex] = 143;
  2362. /* push element on stack */
  2363. return exiPushStack(state, 144, se);
  2364. }
  2365. break;
  2366. case 144:
  2367. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffStart)] */
  2368. se->localPart = 48; /* "TariffStart" */
  2369. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2370. /* move on */
  2371. state->grammarStack[state->stackIndex] = 145;
  2372. /* push element on stack */
  2373. return exiPushStack(state, 146, se);
  2374. break;
  2375. case 145:
  2376. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}TariffPMax)] */
  2377. se->localPart = 47; /* "TariffPMax" */
  2378. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2379. /* move on */
  2380. state->grammarStack[state->stackIndex] = 147;
  2381. /* push element on stack */
  2382. return exiPushStack(state, 67, se);
  2383. break;
  2384. case 147:
  2385. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EPrice), END_ELEMENT] */
  2386. if (state->eventCode == 0) {
  2387. se->localPart = 6; /* "EPrice" */
  2388. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2389. /* move on */
  2390. state->grammarStack[state->stackIndex] = 148;
  2391. /* push element on stack */
  2392. return exiPushStack(state, 67, se);
  2393. }
  2394. break;
  2395. case 150:
  2396. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceScope), END_ELEMENT] */
  2397. if (state->eventCode == 0) {
  2398. se->localPart = 57; /* "ServiceScope" */
  2399. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2400. /* move on */
  2401. state->grammarStack[state->stackIndex] = 152;
  2402. /* push element on stack */
  2403. return exiPushStack(state, 153, se);
  2404. }
  2405. break;
  2406. case 156:
  2407. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceList), END_ELEMENT] */
  2408. if (state->eventCode == 0) {
  2409. se->localPart = 52; /* "ServiceList" */
  2410. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2411. /* move on */
  2412. state->grammarStack[state->stackIndex] = 158;
  2413. /* push element on stack */
  2414. return exiPushStack(state, 159, se);
  2415. }
  2416. break;
  2417. case 159:
  2418. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Service)] */
  2419. se->localPart = 27; /* "Service" */
  2420. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2421. /* move on */
  2422. state->grammarStack[state->stackIndex] = 161;
  2423. /* push element on stack */
  2424. return exiPushStack(state, 162, se);
  2425. break;
  2426. case 161:
  2427. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Service), END_ELEMENT] */
  2428. if (state->eventCode == 0) {
  2429. se->localPart = 27; /* "Service" */
  2430. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2431. /* move on */
  2432. state->grammarStack[state->stackIndex] = 161;
  2433. /* push element on stack */
  2434. return exiPushStack(state, 162, se);
  2435. }
  2436. break;
  2437. case 162:
  2438. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceID)] */
  2439. se->localPart = 29; /* "ServiceID" */
  2440. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2441. /* move on */
  2442. state->grammarStack[state->stackIndex] = 163;
  2443. /* push element on stack */
  2444. return exiPushStack(state, 164, se);
  2445. break;
  2446. case 163:
  2447. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceName), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  2448. if (state->eventCode == 0) {
  2449. se->localPart = 31; /* "ServiceName" */
  2450. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2451. /* move on */
  2452. state->grammarStack[state->stackIndex] = 165;
  2453. /* push element on stack */
  2454. return exiPushStack(state, 166, se);
  2455. }
  2456. else if (state->eventCode == 1) {
  2457. se->localPart = 34; /* "ServiceType" */
  2458. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2459. /* move on */
  2460. state->grammarStack[state->stackIndex] = 167;
  2461. /* push element on stack */
  2462. return exiPushStack(state, 151, se);
  2463. }
  2464. else if (state->eventCode == 2) {
  2465. se->localPart = 32; /* "ServiceScope" */
  2466. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2467. /* move on */
  2468. state->grammarStack[state->stackIndex] = 168;
  2469. /* push element on stack */
  2470. return exiPushStack(state, 153, se);
  2471. }
  2472. break;
  2473. case 165:
  2474. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceType), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  2475. if (state->eventCode == 0) {
  2476. se->localPart = 34; /* "ServiceType" */
  2477. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2478. /* move on */
  2479. state->grammarStack[state->stackIndex] = 167;
  2480. /* push element on stack */
  2481. return exiPushStack(state, 151, se);
  2482. }
  2483. else if (state->eventCode == 1) {
  2484. se->localPart = 32; /* "ServiceScope" */
  2485. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2486. /* move on */
  2487. state->grammarStack[state->stackIndex] = 168;
  2488. /* push element on stack */
  2489. return exiPushStack(state, 153, se);
  2490. }
  2491. break;
  2492. case 167:
  2493. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceScope), END_ELEMENT] */
  2494. if (state->eventCode == 0) {
  2495. se->localPart = 32; /* "ServiceScope" */
  2496. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2497. /* move on */
  2498. state->grammarStack[state->stackIndex] = 168;
  2499. /* push element on stack */
  2500. return exiPushStack(state, 153, se);
  2501. }
  2502. break;
  2503. case 171:
  2504. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVPubKey)] */
  2505. se->localPart = 31; /* "PEVPubKey" */
  2506. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2507. /* move on */
  2508. state->grammarStack[state->stackIndex] = 172;
  2509. /* push element on stack */
  2510. return exiPushStack(state, 65, se);
  2511. break;
  2512. case 173:
  2513. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringAuthPubKey), END_ELEMENT] */
  2514. if (state->eventCode == 0) {
  2515. se->localPart = 16; /* "MeteringAuthPubKey" */
  2516. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2517. /* move on */
  2518. state->grammarStack[state->stackIndex] = 175;
  2519. /* push element on stack */
  2520. return exiPushStack(state, 65, se);
  2521. }
  2522. break;
  2523. case 177:
  2524. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PEVStatus)] */
  2525. se->localPart = 32; /* "PEVStatus" */
  2526. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2527. /* move on */
  2528. state->grammarStack[state->stackIndex] = 178;
  2529. /* push element on stack */
  2530. return exiPushStack(state, 25, se);
  2531. break;
  2532. case 179:
  2533. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEID)] */
  2534. se->localPart = 3; /* "EVSEID" */
  2535. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2536. /* move on */
  2537. state->grammarStack[state->stackIndex] = 181;
  2538. /* push element on stack */
  2539. return exiPushStack(state, 87, se);
  2540. break;
  2541. case 181:
  2542. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}EVSEStatus)] */
  2543. se->localPart = 7; /* "EVSEStatus" */
  2544. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2545. /* move on */
  2546. state->grammarStack[state->stackIndex] = 182;
  2547. /* push element on stack */
  2548. return exiPushStack(state, 36, se);
  2549. break;
  2550. case 182:
  2551. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgBody}TCurrent)] */
  2552. se->localPart = 63; /* "TCurrent" */
  2553. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2554. /* move on */
  2555. state->grammarStack[state->stackIndex] = 183;
  2556. /* push element on stack */
  2557. return exiPushStack(state, 47, se);
  2558. break;
  2559. case 185:
  2560. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Body)] */
  2561. se->localPart = 0; /* "Body" */
  2562. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  2563. /* move on */
  2564. state->grammarStack[state->stackIndex] = 187;
  2565. /* push element on stack */
  2566. return exiPushStack(state, 188, se);
  2567. break;
  2568. case 186:
  2569. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}SessionInformation)] */
  2570. se->localPart = 7; /* "SessionInformation" */
  2571. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  2572. /* move on */
  2573. state->grammarStack[state->stackIndex] = 189;
  2574. /* push element on stack */
  2575. return exiPushStack(state, 190, se);
  2576. break;
  2577. case 188:
  2578. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}BodyElement), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}LineLockRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringReceiptRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}MeteringStatusRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PaymentDetailsRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDeliveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}PowerDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServiceDiscoveryRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}ServicePaymentSelectionRes), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupReq), START_ELEMENT({urn:iso:15118:2:2010:MsgBody}SessionSetupRes), END_ELEMENT] */
  2579. if (state->eventCode == 0) {
  2580. se->localPart = 2; /* "BodyElement" */
  2581. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  2582. /* move on */
  2583. state->grammarStack[state->stackIndex] = 211;
  2584. /* push element on stack */
  2585. return exiPushStack(state, 3, se);
  2586. }
  2587. else if (state->eventCode == 1) {
  2588. se->localPart = 11; /* "LineLockReq" */
  2589. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2590. /* move on */
  2591. state->grammarStack[state->stackIndex] = 211;
  2592. /* push element on stack */
  2593. return exiPushStack(state, 5, se);
  2594. }
  2595. else if (state->eventCode == 2) {
  2596. se->localPart = 13; /* "LineLockRes" */
  2597. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2598. /* move on */
  2599. state->grammarStack[state->stackIndex] = 211;
  2600. /* push element on stack */
  2601. return exiPushStack(state, 6, se);
  2602. }
  2603. else if (state->eventCode == 3) {
  2604. se->localPart = 17; /* "MeteringReceiptReq" */
  2605. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2606. /* move on */
  2607. state->grammarStack[state->stackIndex] = 211;
  2608. /* push element on stack */
  2609. return exiPushStack(state, 7, se);
  2610. }
  2611. else if (state->eventCode == 4) {
  2612. se->localPart = 19; /* "MeteringReceiptRes" */
  2613. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2614. /* move on */
  2615. state->grammarStack[state->stackIndex] = 211;
  2616. /* push element on stack */
  2617. return exiPushStack(state, 8, se);
  2618. }
  2619. else if (state->eventCode == 5) {
  2620. se->localPart = 21; /* "MeteringStatusReq" */
  2621. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2622. /* move on */
  2623. state->grammarStack[state->stackIndex] = 211;
  2624. /* push element on stack */
  2625. return exiPushStack(state, 9, se);
  2626. }
  2627. else if (state->eventCode == 6) {
  2628. se->localPart = 23; /* "MeteringStatusRes" */
  2629. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2630. /* move on */
  2631. state->grammarStack[state->stackIndex] = 211;
  2632. /* push element on stack */
  2633. return exiPushStack(state, 10, se);
  2634. }
  2635. else if (state->eventCode == 7) {
  2636. se->localPart = 33; /* "PaymentDetailsReq" */
  2637. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2638. /* move on */
  2639. state->grammarStack[state->stackIndex] = 211;
  2640. /* push element on stack */
  2641. return exiPushStack(state, 11, se);
  2642. }
  2643. else if (state->eventCode == 8) {
  2644. se->localPart = 35; /* "PaymentDetailsRes" */
  2645. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2646. /* move on */
  2647. state->grammarStack[state->stackIndex] = 211;
  2648. /* push element on stack */
  2649. return exiPushStack(state, 12, se);
  2650. }
  2651. else if (state->eventCode == 9) {
  2652. se->localPart = 37; /* "PowerDeliveryReq" */
  2653. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2654. /* move on */
  2655. state->grammarStack[state->stackIndex] = 211;
  2656. /* push element on stack */
  2657. return exiPushStack(state, 13, se);
  2658. }
  2659. else if (state->eventCode == 10) {
  2660. se->localPart = 39; /* "PowerDeliveryRes" */
  2661. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2662. /* move on */
  2663. state->grammarStack[state->stackIndex] = 211;
  2664. /* push element on stack */
  2665. return exiPushStack(state, 14, se);
  2666. }
  2667. else if (state->eventCode == 11) {
  2668. se->localPart = 41; /* "PowerDiscoveryReq" */
  2669. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2670. /* move on */
  2671. state->grammarStack[state->stackIndex] = 211;
  2672. /* push element on stack */
  2673. return exiPushStack(state, 15, se);
  2674. }
  2675. else if (state->eventCode == 12) {
  2676. se->localPart = 43; /* "PowerDiscoveryRes" */
  2677. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2678. /* move on */
  2679. state->grammarStack[state->stackIndex] = 211;
  2680. /* push element on stack */
  2681. return exiPushStack(state, 16, se);
  2682. }
  2683. else if (state->eventCode == 13) {
  2684. se->localPart = 48; /* "ServiceDiscoveryReq" */
  2685. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2686. /* move on */
  2687. state->grammarStack[state->stackIndex] = 211;
  2688. /* push element on stack */
  2689. return exiPushStack(state, 17, se);
  2690. }
  2691. else if (state->eventCode == 14) {
  2692. se->localPart = 50; /* "ServiceDiscoveryRes" */
  2693. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2694. /* move on */
  2695. state->grammarStack[state->stackIndex] = 211;
  2696. /* push element on stack */
  2697. return exiPushStack(state, 18, se);
  2698. }
  2699. else if (state->eventCode == 15) {
  2700. se->localPart = 53; /* "ServicePaymentSelectionReq" */
  2701. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2702. /* move on */
  2703. state->grammarStack[state->stackIndex] = 211;
  2704. /* push element on stack */
  2705. return exiPushStack(state, 19, se);
  2706. }
  2707. else if (state->eventCode == 16) {
  2708. se->localPart = 55; /* "ServicePaymentSelectionRes" */
  2709. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2710. /* move on */
  2711. state->grammarStack[state->stackIndex] = 211;
  2712. /* push element on stack */
  2713. return exiPushStack(state, 20, se);
  2714. }
  2715. else if (state->eventCode == 17) {
  2716. se->localPart = 59; /* "SessionSetupReq" */
  2717. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2718. /* move on */
  2719. state->grammarStack[state->stackIndex] = 211;
  2720. /* push element on stack */
  2721. return exiPushStack(state, 21, se);
  2722. }
  2723. else if (state->eventCode == 18) {
  2724. se->localPart = 61; /* "SessionSetupRes" */
  2725. se->namespaceURI = 4; /* "urn:iso:15118:2:2010:MsgBody" */
  2726. /* move on */
  2727. state->grammarStack[state->stackIndex] = 211;
  2728. /* push element on stack */
  2729. return exiPushStack(state, 22, se);
  2730. }
  2731. break;
  2732. case 189:
  2733. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDef}Notification), END_ELEMENT] */
  2734. if (state->eventCode == 0) {
  2735. se->localPart = 6; /* "Notification" */
  2736. se->namespaceURI = 6; /* "urn:iso:15118:2:2010:MsgDef" */
  2737. /* move on */
  2738. state->grammarStack[state->stackIndex] = 191;
  2739. /* push element on stack */
  2740. return exiPushStack(state, 192, se);
  2741. }
  2742. break;
  2743. case 190:
  2744. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}SessionID)] */
  2745. se->localPart = 35; /* "SessionID" */
  2746. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2747. /* move on */
  2748. state->grammarStack[state->stackIndex] = 193;
  2749. /* push element on stack */
  2750. return exiPushStack(state, 194, se);
  2751. break;
  2752. case 192:
  2753. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultCode), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  2754. if (state->eventCode == 0) {
  2755. se->localPart = 13; /* "FaultCode" */
  2756. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2757. /* move on */
  2758. state->grammarStack[state->stackIndex] = 200;
  2759. /* push element on stack */
  2760. return exiPushStack(state, 201, se);
  2761. }
  2762. else if (state->eventCode == 1) {
  2763. se->localPart = 14; /* "FaultMsg" */
  2764. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2765. /* move on */
  2766. state->grammarStack[state->stackIndex] = 202;
  2767. /* push element on stack */
  2768. return exiPushStack(state, 203, se);
  2769. }
  2770. else if (state->eventCode == 2) {
  2771. se->localPart = 10; /* "EventList" */
  2772. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2773. /* move on */
  2774. state->grammarStack[state->stackIndex] = 204;
  2775. /* push element on stack */
  2776. return exiPushStack(state, 205, se);
  2777. }
  2778. break;
  2779. case 193:
  2780. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ServiceSessionID), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ProtocolVersion), END_ELEMENT] */
  2781. if (state->eventCode == 0) {
  2782. se->localPart = 33; /* "ServiceSessionID" */
  2783. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2784. /* move on */
  2785. state->grammarStack[state->stackIndex] = 195;
  2786. /* push element on stack */
  2787. return exiPushStack(state, 194, se);
  2788. }
  2789. else if (state->eventCode == 1) {
  2790. se->localPart = 25; /* "ProtocolVersion" */
  2791. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2792. /* move on */
  2793. state->grammarStack[state->stackIndex] = 196;
  2794. /* push element on stack */
  2795. return exiPushStack(state, 197, se);
  2796. }
  2797. break;
  2798. case 195:
  2799. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}ProtocolVersion), END_ELEMENT] */
  2800. if (state->eventCode == 0) {
  2801. se->localPart = 25; /* "ProtocolVersion" */
  2802. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2803. /* move on */
  2804. state->grammarStack[state->stackIndex] = 196;
  2805. /* push element on stack */
  2806. return exiPushStack(state, 197, se);
  2807. }
  2808. break;
  2809. case 200:
  2810. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}FaultMsg), START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  2811. if (state->eventCode == 0) {
  2812. se->localPart = 14; /* "FaultMsg" */
  2813. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2814. /* move on */
  2815. state->grammarStack[state->stackIndex] = 202;
  2816. /* push element on stack */
  2817. return exiPushStack(state, 203, se);
  2818. }
  2819. else if (state->eventCode == 1) {
  2820. se->localPart = 10; /* "EventList" */
  2821. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2822. /* move on */
  2823. state->grammarStack[state->stackIndex] = 204;
  2824. /* push element on stack */
  2825. return exiPushStack(state, 205, se);
  2826. }
  2827. break;
  2828. case 202:
  2829. /* Element[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}EventList), END_ELEMENT] */
  2830. if (state->eventCode == 0) {
  2831. se->localPart = 10; /* "EventList" */
  2832. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2833. /* move on */
  2834. state->grammarStack[state->stackIndex] = 204;
  2835. /* push element on stack */
  2836. return exiPushStack(state, 205, se);
  2837. }
  2838. break;
  2839. case 205:
  2840. /* FirstStartTagStartTag[START_ELEMENT({urn:iso:15118:2:2010:MsgDataTypes}Event)] */
  2841. se->localPart = 9; /* "Event" */
  2842. se->namespaceURI = 5; /* "urn:iso:15118:2:2010:MsgDataTypes" */
  2843. /* move on */
  2844. state->grammarStack[state->stackIndex] = 208;
  2845. /* push element on stack */
  2846. return exiPushStack(state, 209, se);
  2847. break;
  2848. default:
  2849. return -1;
  2850. }
  2851. return -1;
  2852. }
  2853. int exiDecodeEndElement(bitstream_t* stream, exi_state_t* state,
  2854. eqname_t* ee) {
  2855. /* pop item and update ahead of time element qname */
  2856. ee->localPart = state->elementStack[state->stackIndex].localPart;
  2857. ee->namespaceURI = state->elementStack[state->stackIndex].namespaceURI;
  2858. return exiPopStack(state);
  2859. }
  2860. int exiDecodeCharacters(bitstream_t* stream, exi_state_t* state,
  2861. exi_value_t* val) {
  2862. uint8_t xsi;
  2863. switch (state->grammarStack[state->stackIndex]) {
  2864. case 27:
  2865. /* CHARACTERS[BOOLEAN] */
  2866. val->type = BOOLEAN;
  2867. decodeBoolean(stream, &val->boolean);
  2868. /* move on */
  2869. state->grammarStack[state->stackIndex] = 31;
  2870. return 0;
  2871. case 30:
  2872. /* CHARACTERS[BOOLEAN] */
  2873. val->type = BOOLEAN;
  2874. decodeBoolean(stream, &val->boolean);
  2875. /* move on */
  2876. state->grammarStack[state->stackIndex] = 32;
  2877. return 0;
  2878. case 34:
  2879. /* CHARACTERS[ENUMERATION] */
  2880. val->type = ENUMERATION;
  2881. decodeNBitUnsignedInteger(stream, 2, &val->enumeration);
  2882. /* move on */
  2883. state->grammarStack[state->stackIndex] = 37;
  2884. return 0;
  2885. case 39:
  2886. /* CHARACTERS[BOOLEAN] */
  2887. val->type = BOOLEAN;
  2888. decodeBoolean(stream, &val->boolean);
  2889. /* move on */
  2890. state->grammarStack[state->stackIndex] = 48;
  2891. return 0;
  2892. case 43:
  2893. /* CHARACTERS[BOOLEAN] */
  2894. val->type = BOOLEAN;
  2895. decodeBoolean(stream, &val->boolean);
  2896. /* move on */
  2897. state->grammarStack[state->stackIndex] = 49;
  2898. return 0;
  2899. case 45:
  2900. /* CHARACTERS[BOOLEAN] */
  2901. val->type = BOOLEAN;
  2902. decodeBoolean(stream, &val->boolean);
  2903. /* move on */
  2904. state->grammarStack[state->stackIndex] = 50;
  2905. return 0;
  2906. case 47:
  2907. /* CHARACTERS[INTEGER_64] */
  2908. val->type = INTEGER_64;
  2909. decodeInteger64(stream, &val->int64);
  2910. /* move on */
  2911. state->grammarStack[state->stackIndex] = 51;
  2912. return 0;
  2913. case 53:
  2914. /* CHARACTERS[STRING] */
  2915. val->type = STRING;
  2916. decodeStringValue(stream, &val->string);
  2917. /* move on */
  2918. state->grammarStack[state->stackIndex] = 60;
  2919. return 0;
  2920. case 57:
  2921. /* CHARACTERS[ENUMERATION] */
  2922. val->type = ENUMERATION;
  2923. decodeNBitUnsignedInteger(stream, 3, &val->enumeration);
  2924. /* move on */
  2925. state->grammarStack[state->stackIndex] = 61;
  2926. return 0;
  2927. case 63:
  2928. /* CHARACTERS[STRING] */
  2929. val->type = STRING;
  2930. decodeStringValue(stream, &val->string);
  2931. /* move on */
  2932. state->grammarStack[state->stackIndex] = 71;
  2933. return 0;
  2934. case 65:
  2935. /* CHARACTERS[BINARY_HEX] */
  2936. val->type = BINARY_HEX;
  2937. decodeBinary(stream, &val->binary);
  2938. /* move on */
  2939. state->grammarStack[state->stackIndex] = 72;
  2940. return 0;
  2941. case 74:
  2942. /* CHARACTERS[ENUMERATION] */
  2943. val->type = ENUMERATION;
  2944. decodeNBitUnsignedInteger(stream, 4, &val->enumeration);
  2945. /* move on */
  2946. state->grammarStack[state->stackIndex] = 78;
  2947. return 0;
  2948. case 77:
  2949. /* CHARACTERS[INTEGER_64] */
  2950. /* xsi:type OR xsi:nil */
  2951. decodeNBitUnsignedInteger(stream, 1, &xsi);
  2952. val->type = INTEGER_64;
  2953. decodeInteger64(stream, &val->int64);
  2954. /* move on */
  2955. state->grammarStack[state->stackIndex] = 79;
  2956. return 0;
  2957. case 69:
  2958. /* CHARACTERS[INTEGER_16] */
  2959. val->type = INTEGER_16;
  2960. decodeInteger32(stream, &val->int32);
  2961. /* move on */
  2962. state->grammarStack[state->stackIndex] = 80;
  2963. return 0;
  2964. case 82:
  2965. /* CHARACTERS[ENUMERATION] */
  2966. val->type = ENUMERATION;
  2967. decodeNBitUnsignedInteger(stream, 1, &val->enumeration);
  2968. /* move on */
  2969. state->grammarStack[state->stackIndex] = 83;
  2970. return 0;
  2971. case 85:
  2972. /* CHARACTERS[ENUMERATION] */
  2973. val->type = ENUMERATION;
  2974. decodeNBitUnsignedInteger(stream, 1, &val->enumeration);
  2975. /* move on */
  2976. state->grammarStack[state->stackIndex] = 93;
  2977. return 0;
  2978. case 87:
  2979. /* CHARACTERS[BINARY_HEX] */
  2980. val->type = BINARY_HEX;
  2981. decodeBinary(stream, &val->binary);
  2982. /* move on */
  2983. state->grammarStack[state->stackIndex] = 94;
  2984. return 0;
  2985. case 96:
  2986. /* CHARACTERS[STRING] */
  2987. val->type = STRING;
  2988. decodeStringValue(stream, &val->string);
  2989. /* move on */
  2990. state->grammarStack[state->stackIndex] = 97;
  2991. return 0;
  2992. case 99:
  2993. /* CHARACTERS[ENUMERATION] */
  2994. val->type = ENUMERATION;
  2995. decodeNBitUnsignedInteger(stream, 2, &val->enumeration);
  2996. /* move on */
  2997. state->grammarStack[state->stackIndex] = 100;
  2998. return 0;
  2999. case 109:
  3000. /* CHARACTERS[ENUMERATION] */
  3001. val->type = ENUMERATION;
  3002. decodeNBitUnsignedInteger(stream, 3, &val->enumeration);
  3003. /* move on */
  3004. state->grammarStack[state->stackIndex] = 110;
  3005. return 0;
  3006. case 116:
  3007. /* CHARACTERS[INTEGER_16] */
  3008. val->type = INTEGER_16;
  3009. decodeInteger32(stream, &val->int32);
  3010. /* move on */
  3011. state->grammarStack[state->stackIndex] = 119;
  3012. return 0;
  3013. case 121:
  3014. /* CHARACTERS[ENUMERATION] */
  3015. val->type = ENUMERATION;
  3016. decodeNBitUnsignedInteger(stream, 1, &val->enumeration);
  3017. /* move on */
  3018. state->grammarStack[state->stackIndex] = 130;
  3019. return 0;
  3020. case 127:
  3021. /* CHARACTERS[STRING] */
  3022. val->type = STRING;
  3023. decodeStringValue(stream, &val->string);
  3024. /* move on */
  3025. state->grammarStack[state->stackIndex] = 131;
  3026. return 0;
  3027. case 133:
  3028. /* CHARACTERS[STRING] */
  3029. val->type = STRING;
  3030. decodeStringValue(stream, &val->string);
  3031. /* move on */
  3032. state->grammarStack[state->stackIndex] = 136;
  3033. return 0;
  3034. case 139:
  3035. /* CHARACTERS[STRING] */
  3036. val->type = STRING;
  3037. decodeStringValue(stream, &val->string);
  3038. /* move on */
  3039. state->grammarStack[state->stackIndex] = 142;
  3040. return 0;
  3041. case 146:
  3042. /* CHARACTERS[UNSIGNED_INTEGER_32] */
  3043. val->type = UNSIGNED_INTEGER_32;
  3044. decodeUnsignedInteger32(stream, &val->uint32);
  3045. /* move on */
  3046. state->grammarStack[state->stackIndex] = 149;
  3047. return 0;
  3048. case 151:
  3049. /* CHARACTERS[ENUMERATION] */
  3050. val->type = ENUMERATION;
  3051. decodeNBitUnsignedInteger(stream, 2, &val->enumeration);
  3052. /* move on */
  3053. state->grammarStack[state->stackIndex] = 154;
  3054. return 0;
  3055. case 153:
  3056. /* CHARACTERS[STRING] */
  3057. val->type = STRING;
  3058. decodeStringValue(stream, &val->string);
  3059. /* move on */
  3060. state->grammarStack[state->stackIndex] = 155;
  3061. return 0;
  3062. case 157:
  3063. /* CHARACTERS[ENUMERATION] */
  3064. val->type = ENUMERATION;
  3065. decodeNBitUnsignedInteger(stream, 3, &val->enumeration);
  3066. /* move on */
  3067. state->grammarStack[state->stackIndex] = 160;
  3068. return 0;
  3069. case 164:
  3070. /* CHARACTERS[BINARY_HEX] */
  3071. val->type = BINARY_HEX;
  3072. decodeBinary(stream, &val->binary);
  3073. /* move on */
  3074. state->grammarStack[state->stackIndex] = 169;
  3075. return 0;
  3076. case 166:
  3077. /* CHARACTERS[STRING] */
  3078. val->type = STRING;
  3079. decodeStringValue(stream, &val->string);
  3080. /* move on */
  3081. state->grammarStack[state->stackIndex] = 170;
  3082. return 0;
  3083. case 174:
  3084. /* CHARACTERS[ENUMERATION] */
  3085. val->type = ENUMERATION;
  3086. decodeNBitUnsignedInteger(stream, 2, &val->enumeration);
  3087. /* move on */
  3088. state->grammarStack[state->stackIndex] = 176;
  3089. return 0;
  3090. case 180:
  3091. /* CHARACTERS[ENUMERATION] */
  3092. val->type = ENUMERATION;
  3093. decodeNBitUnsignedInteger(stream, 3, &val->enumeration);
  3094. /* move on */
  3095. state->grammarStack[state->stackIndex] = 184;
  3096. return 0;
  3097. case 194:
  3098. /* CHARACTERS[BINARY_HEX] */
  3099. val->type = BINARY_HEX;
  3100. decodeBinary(stream, &val->binary);
  3101. /* move on */
  3102. state->grammarStack[state->stackIndex] = 198;
  3103. return 0;
  3104. case 197:
  3105. /* CHARACTERS[STRING] */
  3106. val->type = STRING;
  3107. decodeStringValue(stream, &val->string);
  3108. /* move on */
  3109. state->grammarStack[state->stackIndex] = 199;
  3110. return 0;
  3111. case 201:
  3112. /* CHARACTERS[ENUMERATION] */
  3113. val->type = ENUMERATION;
  3114. decodeNBitUnsignedInteger(stream, 2, &val->enumeration);
  3115. /* move on */
  3116. state->grammarStack[state->stackIndex] = 206;
  3117. return 0;
  3118. case 203:
  3119. /* CHARACTERS[STRING] */
  3120. /* xsi:type OR xsi:nil */
  3121. decodeNBitUnsignedInteger(stream, 1, &xsi);
  3122. val->type = STRING;
  3123. decodeStringValue(stream, &val->string);
  3124. /* move on */
  3125. state->grammarStack[state->stackIndex] = 207;
  3126. return 0;
  3127. case 209:
  3128. /* CHARACTERS[ENUMERATION] */
  3129. val->type = ENUMERATION;
  3130. decodeNBitUnsignedInteger(stream, 3, &val->enumeration);
  3131. /* move on */
  3132. state->grammarStack[state->stackIndex] = 210;
  3133. return 0;
  3134. default:
  3135. return -1;
  3136. }
  3137. return 0;
  3138. }
  3139. int exiDecodeAttribute(bitstream_t* stream, exi_state_t* state,
  3140. eqname_t* at, exi_value_t* val) {
  3141. switch (state->grammarStack[state->stackIndex]) {
  3142. default:
  3143. return -1;
  3144. }
  3145. return -1;
  3146. }
  3147. #endif