Documentation ¶
Index ¶
- Constants
- Variables
- func InitTemplates(otm map[string]*OutputTemplate)
- func Provider() *schema.Provider
- func RemoveIndex(hl []string, index int) []string
- func RenderTemplates(ots map[string]*OutputTemplate, key string, str interface{}) (string, error)
- func Subprovider(opts ...Option) akamai.Subprovider
- func VerifyContractGroupUnchanged(_ context.Context, d *schema.ResourceDiff, m interface{}) error
- type Option
- type OutputTemplate
- type OutputTemplates
Constants ¶
const ( Append = "APPEND" Replace = "REPLACE" Remove = "REMOVE" IP = "IP" Geo = "GEO" )
Append Replace Remove mode flags
const ( // ActivationPollMinimum is the minumum polling interval for activation creation ActivationPollMinimum = time.Minute )
const NetworkProviderVersion string = "v1.0.0"
NetworkProviderVersion update version string anytime provider adds new features
Variables ¶
var ( // ActivationPollInterval is the interval for polling an activation status on creation ActivationPollInterval = ActivationPollMinimum )
Functions ¶
func InitTemplates ¶
func InitTemplates(otm map[string]*OutputTemplate)
InitTemplates populates map of templates given as argument with output templates
func RemoveIndex ¶
RemoveIndex removes an element from the slice and returns it
func RenderTemplates ¶
func RenderTemplates(ots map[string]*OutputTemplate, key string, str interface{}) (string, error)
RenderTemplates renders template and returns it as a string
func Subprovider ¶
func Subprovider(opts ...Option) akamai.Subprovider
Subprovider returns a core sub provider
func VerifyContractGroupUnchanged ¶
func VerifyContractGroupUnchanged(_ context.Context, d *schema.ResourceDiff, m interface{}) error
VerifyContractGroupUnchanged compares the configuration's value for the contract_id and group_id with the resource's value specified in the resources's ID, to ensure that the user has not inadvertently modified the configuration's value; any such modifications indicate an incorrect understanding of the Update operation.
Types ¶
type Option ¶
type Option func(p *provider)
Option is a networklist provider option
func WithClient ¶
func WithClient(c networklists.NTWRKLISTS) Option
WithClient sets the client interface function, used for mocking and testing
type OutputTemplate ¶
type OutputTemplate struct { TemplateName string TemplateType string TableTitle string TemplateString string }
OutputTemplate contains template data
func GetTemplate ¶
func GetTemplate(ots map[string]*OutputTemplate, key string) (*OutputTemplate, error)
GetTemplate given map of templates and a key, returns template stored under this key
type OutputTemplates ¶
type OutputTemplates map[string]*OutputTemplate
OutputTemplates is a map of templates