NewPolicy creates a new Policy instance with an ID associated with the YAML node.
(node *yaml.Node)
| 604 | |
| 605 | // NewPolicy creates a new Policy instance with an ID associated with the YAML node. |
| 606 | func (p *parserImpl) NewPolicy(node *yaml.Node) (*Policy, int64) { |
| 607 | policy := NewPolicy(p.src, p.info) |
| 608 | id := p.CollectMetadata(node) |
| 609 | return policy, id |
| 610 | } |
| 611 | |
| 612 | // NewRule creates a new Rule instance with an ID associated with the YAML node. |
| 613 | func (p *parserImpl) NewRule(node *yaml.Node) (*Rule, int64) { |
nothing calls this directly
no test coverage detected