Value PORT_CHANNEL (Po\d+)
Value PORT_CHANNEL_STATUS (\S+)
Value PROTOCOL (\w+)
Value PROTOCOL_STATE (\S+)
Value List PHYS_IFACE (Et\S+)
Value List PHYS_IFACE_STATUS (\S+)


Start
  ^\s*Flags
  ^-+
  ^\s+\S\s+-
  ^Number
  ^\s+Port-Channel\s+Protocol\s+Ports\s+$$ -> PCS
  ^\s*$$
  ^. -> Error



PCS
  ^\s*Po\d+ -> Continue.Record
  ^\s*${PORT_CHANNEL}\(${PORT_CHANNEL_STATUS}\)\s+${PROTOCOL}\(${PROTOCOL_STATE}\)\s+${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s*Po\d+.+(Et.+?\(.+?\)\s){1}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s*Po\d+.+(Et.+?\(.+?\)\s){2}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s*Po\d+.+(Et.+?\(.+?\)\s){3}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s*Po\d+.+(Et.+?\(.+?\)\s){4}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s+${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s+(Et.+?\(.+?\)\s){1}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s+(Et.+?\(.+?\)\s){2}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s+(Et.+?\(.+?\)\s){3}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue
  ^\s+(Et.+?\(.+?\)\s){4}${PHYS_IFACE}\(${PHYS_IFACE_STATUS}\)(\s|$$) -> Continue

