// Code generated by applyconfiguration-gen. DO NOT EDIT.

package v1

// BuildConfigStatusApplyConfiguration represents a declarative configuration of the BuildConfigStatus type for use
// with apply.
//
// BuildConfigStatus contains current state of the build config object.
type BuildConfigStatusApplyConfiguration struct {
	// lastVersion is used to inform about number of last triggered build.
	LastVersion *int64 `json:"lastVersion,omitempty"`
	// imageChangeTriggers captures the runtime state of any ImageChangeTrigger specified in the BuildConfigSpec,
	// including the value reconciled by the OpenShift APIServer for the lastTriggeredImageID. There is a single entry
	// in this array for each image change trigger in spec. Each trigger status references the ImageStreamTag that acts as the source of the trigger.
	ImageChangeTriggers []ImageChangeTriggerStatusApplyConfiguration `json:"imageChangeTriggers,omitempty"`
}

// BuildConfigStatusApplyConfiguration constructs a declarative configuration of the BuildConfigStatus type for use with
// apply.
func BuildConfigStatus() *BuildConfigStatusApplyConfiguration {
	return &BuildConfigStatusApplyConfiguration{}
}

// WithLastVersion sets the LastVersion field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the LastVersion field is set to the value of the last call.
func (b *BuildConfigStatusApplyConfiguration) WithLastVersion(value int64) *BuildConfigStatusApplyConfiguration {
	b.LastVersion = &value
	return b
}

// WithImageChangeTriggers adds the given value to the ImageChangeTriggers field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the ImageChangeTriggers field.
func (b *BuildConfigStatusApplyConfiguration) WithImageChangeTriggers(values ...*ImageChangeTriggerStatusApplyConfiguration) *BuildConfigStatusApplyConfiguration {
	for i := range values {
		if values[i] == nil {
			panic("nil value passed to WithImageChangeTriggers")
		}
		b.ImageChangeTriggers = append(b.ImageChangeTriggers, *values[i])
	}
	return b
}
