feat(iso): add PosCapability for DE-027 encoding#688
Merged
Conversation
PosCapability in org.jpos.iso provides structured pack/unpack for the ISO 8583 DE-027 (POS Capability) field. Key features: - Sub-fields 27-1 and 27-2 reuse PosDataCode.ReadingMethod and PosDataCode.VerificationMethod enums (same bit tables as DE-022) - Sub-fields 27-3 through 27-8: N1/N3 ASCII capacity values (approval code length, receipt/display/ICC script lengths) - Sub-fields 27-9 and 27-10: Y/N card capture and track 3 rewrite - Sub-field 27-11: binary PIN input length (0-255) - Fluent builder with toBuilder() for selective modification - pack() / unpack() contract identical to LifeCycleId - 35 unit tests covering all sub-fields, round-trip, toBuilder independence, boundary validation, and ISOMsg integration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Introduces
PosCapabilityinorg.jpos.isofor structured encode/decode of DE-027 (POS Capability).Relationship to DE-022
DE-022 (
PosDataCode) records what actually happened. DE-027 (PosCapability) records what the terminal is capable of. Sub-fields 27-1 and 27-2 share the same bit tables — soPosDataCode.ReadingMethodandPosDataCode.VerificationMethodare reused directly.Wire layout (27 bytes fixed)
Usage
Tests
35 tests — all passing.