NextID returns a monotonically increasing identifier for a source fragment. This ID is implicitly created and tracked within the CollectMetadata method.
()
| 640 | // NextID returns a monotonically increasing identifier for a source fragment. |
| 641 | // This ID is implicitly created and tracked within the CollectMetadata method. |
| 642 | func (p *parserImpl) NextID() int64 { |
| 643 | p.id++ |
| 644 | return p.id |
| 645 | } |
| 646 | |
| 647 | // NewPolicy creates a new Policy instance with an ID associated with the YAML node. |
| 648 | func (p *parserImpl) NewPolicy(node *yaml.Node) (*Policy, int64) { |