pkg/types: add IgnoreUnknown arg and logic

This commit adds a struct type CommonArgs that is to be embedded in
every plugin's argument struct. It contains a field named
"IgnoreUnknown" which will be parsed as a boolean and can be provided to
ignore unknown arguments passed to the plugin.
This commit is contained in:
Stefan Junker
2016-03-17 14:08:29 +01:00
parent 05c5aea77b
commit 5a39a168f7
2 changed files with 44 additions and 2 deletions

View File

@ -35,6 +35,7 @@ type IPAMConfig struct {
}
type IPAMArgs struct {
types.CommonArgs
IP net.IP `json:"ip,omitempty"`
}