model

package
v0.9.2 Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2026 License: Apache-2.0 Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const StateFileVersion = "v1"

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceState

type ResourceState struct {
	APIVersion string          `json:"apiVersion"`
	Kind       string          `json:"kind"`
	Metadata   *map[string]any `json:"metadata"`
}

func NewResourceState

func NewResourceState(res resource.Resource) ResourceState

func (*ResourceState) Equal

func (r *ResourceState) Equal(other *ResourceState) bool

func (*ResourceState) ToResource

func (r *ResourceState) ToResource() resource.Resource

type State

type State struct {
	Version     string          `json:"version"`
	LastUpdated string          `json:"lastUpdated"`
	Resources   []ResourceState `json:"resources"`
}

func NewState

func NewState() *State

func (*State) AddManagedResource

func (s *State) AddManagedResource(res resource.Resource)

func (*State) GetRemovedResources

func (s *State) GetRemovedResources(activeResources []resource.Resource) []resource.Resource

func (*State) IsResourceManaged

func (s *State) IsResourceManaged(ressource resource.Resource) bool

func (*State) RemoveManagedResource

func (s *State) RemoveManagedResource(res resource.Resource)

func (*State) RemoveManagedResourceKindName

func (s *State) RemoveManagedResourceKindName(kind schema.Kind, name string)

func (*State) RemoveManagedResourceVKM

func (s *State) RemoveManagedResourceVKM(apiVersion, kind string, metadata *map[string]any)

Jump to

Keyboard shortcuts

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