@@ -179,7 +179,7 @@ class Serializer(
179179 put(0x51 .toByte()) // Header
180180 put(0x01 .toByte()) // Type Length ("U" is 1 byte)
181181 put(urlPayload.size.toByte()) // Payload Length (SR=1)
182- put(' U' .toByte()) // Type
182+ put(' U' .code. toByte()) // Type
183183 put(urlPayload) // Payload (Prefix + URL)
184184 }.array()
185185
@@ -551,7 +551,7 @@ class Serializer(
551551 val firstNode: JsonNode = mapper.readTree(parser) ? : return null
552552
553553 if (isMetaRegion(firstNode)) {
554- val metaEndPosition = parser.currentLocation.byteOffset.toInt()
554+ val metaEndPosition = parser.currentLocation() .byteOffset.toInt()
555555 val explicitMainOffset = if (firstNode.has(" 0" )) firstNode.get(" 0" ).asInt() else null
556556 val explicitMainSize = if (firstNode.has(" 1" )) firstNode.get(" 1" ).asInt() else null
557557 val explicitAuxOffset = if (firstNode.has(" 2" )) firstNode.get(" 2" ).asInt() else null
@@ -584,13 +584,13 @@ class Serializer(
584584 } else {
585585 // No meta region - sequential CBOR parsing
586586 model.main = decodeMainRegionFromNode(firstNode)
587- val mainEndPos = parser.currentLocation.byteOffset.toInt()
587+ val mainEndPos = parser.currentLocation() .byteOffset.toInt()
588588
589589 val secondNode: JsonNode ? = mapper.readTree(parser)
590590 if (secondNode != null ) {
591591 auxOffset = mainEndPos
592592 model.aux = decodeAuxRegionFromNode(secondNode)
593- auxSize = parser.currentLocation.byteOffset.toInt() - mainEndPos
593+ auxSize = parser.currentLocation() .byteOffset.toInt() - mainEndPos
594594 }
595595 }
596596 } catch (e: Exception ) {
@@ -615,7 +615,7 @@ class Serializer(
615615 // Main region uses keys 0-5+ for UUIDs, GTIN, etc.
616616 if (isMetaRegion(firstNode)) {
617617 // Get position where meta region ends (where main would start if offset not specified)
618- val metaEndPosition = parser.currentLocation.byteOffset.toInt()
618+ val metaEndPosition = parser.currentLocation() .byteOffset.toInt()
619619
620620 // Get explicit values (null if missing)
621621 val explicitMainOffset = if (firstNode.has(" 0" )) firstNode.get(" 0" ).asInt() else null
0 commit comments