mirror of
https://github.com/goharbor/harbor
synced 2025-04-16 07:53:59 +00:00
39 lines
908 B
Go
39 lines
908 B
Go
package models
|
|
|
|
import (
|
|
"time"
|
|
)
|
|
|
|
//ReplicationPolicy defines the structure of a replication policy.
|
|
type ReplicationPolicy struct {
|
|
ID int64 //UUID of the policy
|
|
Name string
|
|
Description string
|
|
Filters []Filter
|
|
ReplicateDeletion bool
|
|
Trigger *Trigger //The trigger of the replication
|
|
ProjectIDs []int64 //Projects attached to this policy
|
|
TargetIDs []int64
|
|
Namespaces []string // The namespaces are used to set immediate trigger
|
|
CreationTime time.Time
|
|
UpdateTime time.Time
|
|
}
|
|
|
|
//QueryParameter defines the parameters used to do query selection.
|
|
type QueryParameter struct {
|
|
//Query by page, couple with pageSize
|
|
Page int64
|
|
|
|
//Size of each page, couple with page
|
|
PageSize int64
|
|
|
|
//Query by the type of trigger
|
|
TriggerType string
|
|
|
|
//Query by project ID
|
|
ProjectID int64
|
|
|
|
//Query by name
|
|
Name string
|
|
}
|