Section 5 - Naming sections with Named

If we’d like, we can name parts of our rope:

import ropes.core._

type Area   = Repeated.Exactly[3, Digit] Named "Area"
type Group  = Repeated.Exactly[2, Digit] Named "Group"
type Serial = Repeated.Exactly[4, Digit] Named "Serial"

This makes sections easy to acess:

parsed.section["Area"].write
// res0: String = "078"
parsed.section["Group"].write
// res1: String = "05"
parsed.section["Serial"].write
// res2: String = "1120"