types

package
v0.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 8, 2024 License: MIT Imports: 2 Imported by: 9

Documentation

Overview

Package types provides common types used by libnuke. Primarily it provides the Collection type which is used to represent a collection of strings. Additionally, it provides the Properties type which is used to add properties to a resource.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collection

type Collection []string

Collection is a collection of strings

func ResolveResourceTypes

func ResolveResourceTypes(
	base Collection,
	includes, excludes, alternatives []Collection,
	alternativeMappings map[string]string) Collection

ResolveResourceTypes resolves the resource types based on the provided includes, excludes, and alternatives. The alternatives are a list of resource types that are to be used instead of the default resource. The primary use case for this is AWS Cloud Control API resources. If a resource has been registered with the Cloud Control API. Includes, Excludes, and Alternatives are []Collection because they are a combination of runtime, global and account level configuration.

func (Collection) Intersect

func (c Collection) Intersect(o Collection) Collection

Intersect returns the intersection of two collections

func (Collection) Remove

func (c Collection) Remove(o Collection) Collection

Remove returns the difference of two collections

func (Collection) Union

func (c Collection) Union(o Collection) Collection

Union returns the union of two collections

type Properties

type Properties map[string]string

func NewProperties

func NewProperties() Properties

func (Properties) Equals

func (p Properties) Equals(o Properties) bool

func (Properties) Get

func (p Properties) Get(key string) string

func (Properties) Set

func (p Properties) Set(key string, value interface{}) Properties

func (Properties) SetTag

func (p Properties) SetTag(tagKey *string, tagValue interface{}) Properties

func (Properties) SetTagWithPrefix

func (p Properties) SetTagWithPrefix(prefix string, tagKey *string, tagValue interface{}) Properties

func (Properties) SetWithPrefix added in v0.11.0

func (p Properties) SetWithPrefix(prefix, key string, value interface{}) Properties

func (Properties) String

func (p Properties) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL