v1alpha1

package
v0.0.0-...-5336895 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the iot v1alpha1 API group +kubebuilder:object:generate=true +groupName=iot.iot.dev

Index

Constants

View Source
const (
	AutomationStatusCreating  AutomationStatusFields = "Creating"
	AutomationStatusRunning   AutomationStatusFields = "Running"
	AutomationStatusError     AutomationStatusFields = "Error"
	AutomationStatusCompleted AutomationStatusFields = "Completed"

	AutomationInputTypeNumeric AutomationInputType = "Numeric"
	AutomationInputTypeState   AutomationInputType = "State"
	AutomationInputTypeTime    AutomationInputType = "Time"

	ActionTypeMessage ActionType = "Message"
	ActionTypeEvent   ActionType = "Event"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "iot.iot.dev", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type Action

type Action struct {
	// +kubebuilder:validation:Enum=Message;Event
	Type ActionType `json:"type"`
	// +kubebuilder:validation:MinItems=1
	Data []Data `json:"data,omitempty"`
}

action structure part of the Spec

func (*Action) DeepCopy

func (in *Action) DeepCopy() *Action

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Action.

func (*Action) DeepCopyInto

func (in *Action) DeepCopyInto(out *Action)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ActionType

type ActionType string

type Automation

type Automation struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   AutomationSpec   `json:"spec,omitempty"`
	Status AutomationStatus `json:"status,omitempty"`
}

Automation is the Schema for the automations API

func (*Automation) DeepCopy

func (in *Automation) DeepCopy() *Automation

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Automation.

func (*Automation) DeepCopyInto

func (in *Automation) DeepCopyInto(out *Automation)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Automation) DeepCopyObject

func (in *Automation) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type AutomationInputType

type AutomationInputType string

type AutomationList

type AutomationList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Automation `json:"items"`
}

AutomationList contains a list of Automation

func (*AutomationList) DeepCopy

func (in *AutomationList) DeepCopy() *AutomationList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutomationList.

func (*AutomationList) DeepCopyInto

func (in *AutomationList) DeepCopyInto(out *AutomationList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*AutomationList) DeepCopyObject

func (in *AutomationList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type AutomationSpec

type AutomationSpec struct {

	// Foo is an example field of Automation. Edit automation_types.go to remove/update
	Trigger Trigger `json:"trigger"`
	// +kubebuilder:validation:MinItems=1
	Action []Action `json:"action"`
	// +kubebuilder:validation:MinItems=1
	PostAction []Action `json:"postaction,omitempty"`
}

AutomationSpec defines the desired state of Automation

func (*AutomationSpec) DeepCopy

func (in *AutomationSpec) DeepCopy() *AutomationSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutomationSpec.

func (*AutomationSpec) DeepCopyInto

func (in *AutomationSpec) DeepCopyInto(out *AutomationSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type AutomationStatus

type AutomationStatus struct {
	// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	Status  AutomationStatusFields `json:"status,omitempty"`
	Message string                 `json:"message,omitempty"`
}

AutomationStatus defines the observed state of Automation

func (*AutomationStatus) DeepCopy

func (in *AutomationStatus) DeepCopy() *AutomationStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AutomationStatus.

func (*AutomationStatus) DeepCopyInto

func (in *AutomationStatus) DeepCopyInto(out *AutomationStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type AutomationStatusFields

type AutomationStatusFields string

type Data

type Data struct {
	TargetDevice   string `json:"targetdevice,omitempty"`
	TargetResource string `json:"targetresource,omitempty"`

	Value  *bool  `json:"value,omitempty"`
	Period Period `json:"period,omitempty"` // Period: how long to run the

	Message string `json:"message,omitempty"`
	Email   string `json:"email,omitempty"`
}

func (*Data) DeepCopy

func (in *Data) DeepCopy() *Data

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Data.

func (*Data) DeepCopyInto

func (in *Data) DeepCopyInto(out *Data)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MyStatus

type MyStatus string

type OCFDevice

type OCFDevice struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   OCFDeviceSpec   `json:"spec,omitempty"`
	Status OCFDeviceStatus `json:"status,omitempty"`
}

OCFDevice is the Schema for the ocfdevices API

func (*OCFDevice) DeepCopy

func (in *OCFDevice) DeepCopy() *OCFDevice

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDevice.

func (*OCFDevice) DeepCopyInto

func (in *OCFDevice) DeepCopyInto(out *OCFDevice)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDevice) DeepCopyObject

func (in *OCFDevice) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceBoarding

type OCFDeviceBoarding struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   OCFDeviceBoardingSpec   `json:"spec,omitempty"`
	Status OCFDeviceBoardingStatus `json:"status,omitempty"`
}

OCFDeviceBoarding is the Schema for the ocfdeviceboardings API

func (*OCFDeviceBoarding) DeepCopy

func (in *OCFDeviceBoarding) DeepCopy() *OCFDeviceBoarding

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceBoarding.

func (*OCFDeviceBoarding) DeepCopyInto

func (in *OCFDeviceBoarding) DeepCopyInto(out *OCFDeviceBoarding)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDeviceBoarding) DeepCopyObject

func (in *OCFDeviceBoarding) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceBoardingList

type OCFDeviceBoardingList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []OCFDeviceBoarding `json:"items"`
}

OCFDeviceBoardingList contains a list of OCFDeviceBoarding

func (*OCFDeviceBoardingList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceBoardingList.

func (*OCFDeviceBoardingList) DeepCopyInto

func (in *OCFDeviceBoardingList) DeepCopyInto(out *OCFDeviceBoardingList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDeviceBoardingList) DeepCopyObject

func (in *OCFDeviceBoardingList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceBoardingSpec

type OCFDeviceBoardingSpec struct {

	// This is the time taken in seconds to scan for OCF devices on the network
	DiscoveryTimeout int `json:"discoveryTimeout"` // Default 10

	// Whether to onboard an OCF device on the network automatically or not
	OnBoardMode string `json:"onboardMode"` // Either Auto or Manual Default Auto
}

OCFDeviceBoardingSpec defines the desired state of OCFDeviceBoarding

func (*OCFDeviceBoardingSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceBoardingSpec.

func (*OCFDeviceBoardingSpec) DeepCopyInto

func (in *OCFDeviceBoardingSpec) DeepCopyInto(out *OCFDeviceBoardingSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceBoardingStatus

type OCFDeviceBoardingStatus struct {
}

OCFDeviceBoardingStatus defines the observed state of OCFDeviceBoarding

func (*OCFDeviceBoardingStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceBoardingStatus.

func (*OCFDeviceBoardingStatus) DeepCopyInto

func (in *OCFDeviceBoardingStatus) DeepCopyInto(out *OCFDeviceBoardingStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceCurrentStatus

type OCFDeviceCurrentStatus string
const (
	OCFDeviceCreating   OCFDeviceCurrentStatus = "Creating"
	OCFDeviceOnBoarding OCFDeviceCurrentStatus = "OnBoarding"
	OCFDeviceDiscovery  OCFDeviceCurrentStatus = "Discovery"
	OCFDeviceRunning    OCFDeviceCurrentStatus = "Running"
	OCFDeviceError      OCFDeviceCurrentStatus = "Error"
	OCFDeviceNotFound   OCFDeviceCurrentStatus = "NotFound"
	OCFDeviceCompleted  OCFDeviceCurrentStatus = "Completed"
)

type OCFDeviceList

type OCFDeviceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []OCFDevice `json:"items"`
}

+kubebuilder:object:root=true +kubebuilder:resource:shortName=ocfdevice +kubebuilder:printcolumn:name="Age",type=date,JSONPath=`.metadata.creationTimestamp` +kubebuilder:printcolumn:name="Status",type=string,JSONPath=`.status.status` +kubebuilder:printcolumn:name="Message",type=string,JSONPath=`.status.message` +kubebuilder:printcolumn:name="Owned",type=string,JSONPath=`.status.owned` +kubebuilder:subresource:status OCFDeviceList contains a list of OCFDevice

func (*OCFDeviceList) DeepCopy

func (in *OCFDeviceList) DeepCopy() *OCFDeviceList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceList.

func (*OCFDeviceList) DeepCopyInto

func (in *OCFDeviceList) DeepCopyInto(out *OCFDeviceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDeviceList) DeepCopyObject

func (in *OCFDeviceList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceResource

type OCFDeviceResource struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   OCFDeviceResourceSpec   `json:"spec,omitempty"`
	Status OCFDeviceResourceStatus `json:"status,omitempty"`
}

OCFDeviceResources is the Schema for the ocfdeviceresources API

func (*OCFDeviceResource) DeepCopy

func (in *OCFDeviceResource) DeepCopy() *OCFDeviceResource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceResource.

func (*OCFDeviceResource) DeepCopyInto

func (in *OCFDeviceResource) DeepCopyInto(out *OCFDeviceResource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDeviceResource) DeepCopyObject

func (in *OCFDeviceResource) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceResourceList

type OCFDeviceResourceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []OCFDeviceResource `json:"items"`
}

+kubebuilder:object:root=true +kubebuilder:subresource:status +kubebuilder:resource:scope=Namespaced kubebuilder:printcolumn:name="deviceId",type=string,JSONPath=`.spec.deviceId` +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" OCFDeviceResourcesList contains a list of OCFDeviceResources

func (*OCFDeviceResourceList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceResourceList.

func (*OCFDeviceResourceList) DeepCopyInto

func (in *OCFDeviceResourceList) DeepCopyInto(out *OCFDeviceResourceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*OCFDeviceResourceList) DeepCopyObject

func (in *OCFDeviceResourceList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type OCFDeviceResourceProperties

type OCFDeviceResourceProperties struct {
	Link        string `json:"link,omitempty"` //this is the href for the resource
	Value       *bool  `json:"value,omitempty"`
	Units       string `json:"units,omitempty"`
	Measurement string `json:"measurement,omitempty"`
}

func (*OCFDeviceResourceProperties) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceResourceProperties.

func (*OCFDeviceResourceProperties) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceResourceSpec

type OCFDeviceResourceSpec struct {

	// DeviceID is the OCFDevice this resource belongs to
	DeviceID   string                        `json:"deviceId" protobuf:"bytes,1,opt,name=deviceId"  kubebuilder:"index"`
	Properties []OCFDeviceResourceProperties `json:"properties"`
}

OCFDeviceResourcesSpec defines the desired state of OCFDeviceResources

func (*OCFDeviceResourceSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceResourceSpec.

func (*OCFDeviceResourceSpec) DeepCopyInto

func (in *OCFDeviceResourceSpec) DeepCopyInto(out *OCFDeviceResourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceResourceStatus

type OCFDeviceResourceStatus struct {
}

OCFDeviceResourcesStatus defines the observed state of OCFDeviceResources

func (*OCFDeviceResourceStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceResourceStatus.

func (*OCFDeviceResourceStatus) DeepCopyInto

func (in *OCFDeviceResourceStatus) DeepCopyInto(out *OCFDeviceResourceStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceSpec

type OCFDeviceSpec struct {

	// Foo is an example field of OCFDevice. Edit ocfdevice_types.go to remove/update
	Id      string `json:"id,omitempty"`
	Name    string `json:"name,omitempty"`
	OwnerID string `json:"ownerId,omitempty"`

	PreferedResources []PreferedResources `json:"preferredResources"`
}

OCFDeviceSpec defines the desired state of OCFDevice

func (*OCFDeviceSpec) DeepCopy

func (in *OCFDeviceSpec) DeepCopy() *OCFDeviceSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceSpec.

func (*OCFDeviceSpec) DeepCopyInto

func (in *OCFDeviceSpec) DeepCopyInto(out *OCFDeviceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OCFDeviceStatus

type OCFDeviceStatus struct {
	// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	Options []Options              `json:"options,omitempty"`
	Status  OCFDeviceCurrentStatus `json:"status,omitempty"`
	Message string                 `json:"message,omitempty"`
	Owned   bool                   `json:"owned"`
}

OCFDeviceStatus defines the observed state of OCFDevice

func (*OCFDeviceStatus) DeepCopy

func (in *OCFDeviceStatus) DeepCopy() *OCFDeviceStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OCFDeviceStatus.

func (*OCFDeviceStatus) DeepCopyInto

func (in *OCFDeviceStatus) DeepCopyInto(out *OCFDeviceStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Options

type Options struct {
	CertIdentity     string        `json:"certIdentity,omitempty"`
	DiscoveryTimeout time.Duration `json:"discoveryTimeout,omitempty"`

	MfgCert       string `json:"mfgCert,omitempty"`
	MfgKey        string `json:"mfgKey,omitempty"`
	MfgTrustCA    string `json:"mfgTrustCA,omitempty"`
	MfgTrustCAKey string `json:"mfgTrustCAKey,omitempty"`

	IdentityCert              string `json:"identityCert,omitempty"`
	IdentityKey               string `json:"identityKey,omitempty"`
	IdentityIntermediateCA    string `json:"identityIntermediateCA,omitempty"`
	IdentityIntermediateCAKey string `json:"identityIntermediateCAKey,omitempty"`
	IdentityTrustCA           string `json:"identityTrustCA,omitempty"`
	IdentityTrustCAKey        string `json:"identityTrustCAKey,omitempty"`
}

func (*Options) DeepCopy

func (in *Options) DeepCopy() *Options

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Options.

func (*Options) DeepCopyInto

func (in *Options) DeepCopyInto(out *Options)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Period

type Period struct {
	Hours   *int64 `json:"hours,omitempty"`
	Minutes *int64 `json:"minutes,omitempty"`
	Seconds *int64 `json:"seconds,omitempty"`
}

func (*Period) DeepCopy

func (in *Period) DeepCopy() *Period

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Period.

func (*Period) DeepCopyInto

func (in *Period) DeepCopyInto(out *Period)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PreferedResources

type PreferedResources struct {
	Name string `json:"name"`
}

func (*PreferedResources) DeepCopy

func (in *PreferedResources) DeepCopy() *PreferedResources

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PreferedResources.

func (*PreferedResources) DeepCopyInto

func (in *PreferedResources) DeepCopyInto(out *PreferedResources)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Trigger

type Trigger struct {
	// +kubebuilder:validation:Enum=Numeric;Time;State
	InputType   AutomationInputType `json:"inputtype"`   // Inputtype: The trigger expects numeric data; could be sensor readings
	OnDevice    string              `json:"ondevice"`    //ondevice: Indicates the device which will be sending the values
	ForResource string              `json:"forresource"` // Forresource: Indicates which resource on the device is exposed with that data

	To         string   `json:"to,omitempty"`         //  To: indicates that a trigger is set if the state changes to a particular defined state
	From       string   `json:"from,omitempty"`       //  From: indicates that a trigger is set if the state changes
	At         string   `json:"at,omitempty"`         // specifies the time trigger an action
	TimeFormat string   `json:"timeformat,omitempty"` // whether to use 12hr or 24hr time format
	Max        *float64 `json:"max,omitempty"`        // max&min: are available for the numeric type. Determines threshold for an automation
	Min        *float64 `json:"min,omitempty"`
	Period     Period   `json:"period,omitempty"` // Period: If given, will trigger when the condition has been true for X time
}

trigger structure part of the Spec

func (*Trigger) DeepCopy

func (in *Trigger) DeepCopy() *Trigger

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Trigger.

func (*Trigger) DeepCopyInto

func (in *Trigger) DeepCopyInto(out *Trigger)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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