Documentation ¶
Index ¶
- func Create(params CreateParams) (*models.TrafficFilterRulesetResponse, error)
- func CreateAssociation(params CreateAssociationParams) error
- func Delete(params DeleteParams) error
- func DeleteAssociation(params DeleteAssociationParams) error
- func Get(params GetParams) (*models.TrafficFilterRulesetInfo, error)
- func List(params ListParams) (*models.TrafficFilterRulesets, error)
- func NewUpdateRequestFromGet(res *models.TrafficFilterRulesetInfo) *models.TrafficFilterRulesetRequest
- func Update(params UpdateParams) (*models.TrafficFilterRulesetResponse, error)
- type CreateAssociationParams
- type CreateParams
- type DeleteAssociationParams
- type DeleteParams
- type GetParams
- type ListParams
- type UpdateParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create(params CreateParams) (*models.TrafficFilterRulesetResponse, error)
Create creates a new traffic filter matching the specified request.
func CreateAssociation ¶
func CreateAssociation(params CreateAssociationParams) error
CreateAssociation creates a new traffic filter association to the specified entity.
func Delete ¶
func Delete(params DeleteParams) error
Delete removes an existing traffic filter rule.
func DeleteAssociation ¶
func DeleteAssociation(params DeleteAssociationParams) error
DeleteAssociation deletes a new traffic filter association to the specified entity.
func Get ¶
func Get(params GetParams) (*models.TrafficFilterRulesetInfo, error)
Get obtains an existing traffic filter.
func List ¶
func List(params ListParams) (*models.TrafficFilterRulesets, error)
List returns all the created traffic filters for a region.
func NewUpdateRequestFromGet ¶
func NewUpdateRequestFromGet(res *models.TrafficFilterRulesetInfo) *models.TrafficFilterRulesetRequest
NewUpdateRequestFromGet populates UpdateParams from models.Extension
func Update ¶
func Update(params UpdateParams) (*models.TrafficFilterRulesetResponse, error)
Update updates an existing traffic filter to match the specified request.
Types ¶
type CreateAssociationParams ¶
type CreateAssociationParams struct { // Required API instance. *api.API // Required ruleset identifier. ID string // Required entity identifier. EntityID string // Required ruleset type ("deployment" or "cluster"). EntityType string }
CreateAssociationParams is consumed by CreateAssociation.
func (CreateAssociationParams) Validate ¶
func (params CreateAssociationParams) Validate() error
Validate ensures the parameters are usable by CreateAssociation.
type CreateParams ¶
type CreateParams struct { // Required API instance. *api.API // Required create request. Req *models.TrafficFilterRulesetRequest }
CreateParams is consumed by Create.
func (CreateParams) Validate ¶
func (params CreateParams) Validate() error
Validate ensures the parameters are usable by Create.
type DeleteAssociationParams ¶
type DeleteAssociationParams struct { // Required API instance. *api.API // Required ruleset identifier. ID string // Required entity identifier. EntityID string // Required ruleset type ("deployment" or "cluster"). EntityType string }
DeleteAssociationParams is consumed by DeleteAssociation.
func (DeleteAssociationParams) Validate ¶
func (params DeleteAssociationParams) Validate() error
Validate ensures the parameters are usable by DeleteAssociation.
type DeleteParams ¶
type DeleteParams struct { // Required API instance. *api.API // Required rule identifier. ID string // Optionally ignore the existing rule associations. IgnoreAssociations bool }
DeleteParams is consumed by Delete.
func (DeleteParams) Validate ¶
func (params DeleteParams) Validate() error
Validate ensures the parameters are usable by Delete.
type GetParams ¶
type GetParams struct { // Required API instance. *api.API // Required rule identifier. ID string // Optionally include the rule associations. IncludeAssociations bool }
GetParams is consumed by Get.
type ListParams ¶
type ListParams struct { // Required API instance. *api.API // Optionally return only the traffic filters for a region. Region string // Optionally include the rule associations. IncludeAssociations bool }
ListParams is consumed by List.
func (ListParams) Validate ¶
func (params ListParams) Validate() error
Validate ensures the parameters are usable by List.
type UpdateParams ¶
type UpdateParams struct { // Required API instance. *api.API // Required rule identifier. ID string // Required Update request. Req *models.TrafficFilterRulesetRequest }
UpdateParams is consumed by Update.
func (UpdateParams) Validate ¶
func (params UpdateParams) Validate() error
Validate ensures the parameters are usable by Update.