@@ -19,48 +19,50 @@ package loadbalancers
1919import (
2020 "context"
2121
22+ k8scloud "github.com/GoogleCloudPlatform/k8s-cloud-provider/pkg/cloud"
2223 "github.com/GoogleCloudPlatform/k8s-cloud-provider/pkg/cloud/filter"
2324 "github.com/GoogleCloudPlatform/k8s-cloud-provider/pkg/cloud/meta"
2425 "google.golang.org/api/compute/v1"
26+
2527 "sigs.k8s.io/cluster-api-provider-gcp/cloud"
2628)
2729
2830type addressesInterface interface {
29- Get (ctx context.Context , key * meta.Key ) (* compute.Address , error )
30- Insert (ctx context.Context , key * meta.Key , obj * compute.Address ) error
31- Delete (ctx context.Context , key * meta.Key ) error
31+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.Address , error )
32+ Insert (ctx context.Context , key * meta.Key , obj * compute.Address , options ... k8scloud. Option ) error
33+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
3234}
3335
3436type backendservicesInterface interface {
35- Get (ctx context.Context , key * meta.Key ) (* compute.BackendService , error )
36- Insert (ctx context.Context , key * meta.Key , obj * compute.BackendService ) error
37- Update (context.Context , * meta.Key , * compute.BackendService ) error
38- Delete (ctx context.Context , key * meta.Key ) error
37+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.BackendService , error )
38+ Insert (ctx context.Context , key * meta.Key , obj * compute.BackendService , options ... k8scloud. Option ) error
39+ Update (ctx context.Context , key * meta.Key , obj * compute.BackendService , options ... k8scloud. Option ) error
40+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
3941}
4042
4143type forwardingrulesInterface interface {
42- Get (ctx context.Context , key * meta.Key ) (* compute.ForwardingRule , error )
43- Insert (ctx context.Context , key * meta.Key , obj * compute.ForwardingRule ) error
44- Delete (ctx context.Context , key * meta.Key ) error
44+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.ForwardingRule , error )
45+ Insert (ctx context.Context , key * meta.Key , obj * compute.ForwardingRule , options ... k8scloud. Option ) error
46+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
4547}
4648
4749type healthchecksInterface interface {
48- Get (ctx context.Context , key * meta.Key ) (* compute.HealthCheck , error )
49- Insert (ctx context.Context , key * meta.Key , obj * compute.HealthCheck ) error
50- Delete (ctx context.Context , key * meta.Key ) error
50+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.HealthCheck , error )
51+ Insert (ctx context.Context , key * meta.Key , obj * compute.HealthCheck , options ... k8scloud. Option ) error
52+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
5153}
5254
5355type instancegroupsInterface interface {
54- Get (ctx context.Context , key * meta.Key ) (* compute.InstanceGroup , error )
55- List (ctx context.Context , zone string , fl * filter.F ) ([]* compute.InstanceGroup , error )
56- Insert (ctx context.Context , key * meta.Key , obj * compute.InstanceGroup ) error
57- Delete (ctx context.Context , key * meta.Key ) error
56+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.InstanceGroup , error )
57+ List (ctx context.Context , zone string , fl * filter.F , options ... k8scloud. Option ) ([]* compute.InstanceGroup , error )
58+ Insert (ctx context.Context , key * meta.Key , obj * compute.InstanceGroup , options ... k8scloud. Option ) error
59+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
5860}
5961
6062type targettcpproxiesInterface interface {
61- Get (ctx context.Context , key * meta.Key ) (* compute.TargetTcpProxy , error )
62- Insert (ctx context.Context , key * meta.Key , obj * compute.TargetTcpProxy ) error
63- Delete (ctx context.Context , key * meta.Key ) error
63+ Get (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) (* compute.TargetTcpProxy , error )
64+ Insert (ctx context.Context , key * meta.Key , obj * compute.TargetTcpProxy , options ... k8scloud. Option ) error
65+ Delete (ctx context.Context , key * meta.Key , options ... k8scloud. Option ) error
6466}
6567
6668// Scope is an interfaces that hold used methods.
0 commit comments