generated from pulumi/pulumi-tf-provider-boilerplate
/
getCatalogPrivateEndpoints.go
157 lines (137 loc) · 6.56 KB
/
getCatalogPrivateEndpoints.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package datacatalog
import (
"context"
"reflect"
"github.com/pulumi/pulumi-oci/sdk/go/oci/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// This data source provides the list of Catalog Private Endpoints in Oracle Cloud Infrastructure Data Catalog service.
//
// Returns a list of all the catalog private endpoints in the specified compartment.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-oci/sdk/go/oci/DataCatalog"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := DataCatalog.GetCatalogPrivateEndpoints(ctx, &datacatalog.GetCatalogPrivateEndpointsArgs{
// CompartmentId: compartmentId,
// DisplayName: pulumi.StringRef(catalogPrivateEndpointDisplayName),
// State: pulumi.StringRef(catalogPrivateEndpointState),
// }, nil)
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
func GetCatalogPrivateEndpoints(ctx *pulumi.Context, args *GetCatalogPrivateEndpointsArgs, opts ...pulumi.InvokeOption) (*GetCatalogPrivateEndpointsResult, error) {
opts = internal.PkgInvokeDefaultOpts(opts)
var rv GetCatalogPrivateEndpointsResult
err := ctx.Invoke("oci:DataCatalog/getCatalogPrivateEndpoints:getCatalogPrivateEndpoints", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
// A collection of arguments for invoking getCatalogPrivateEndpoints.
type GetCatalogPrivateEndpointsArgs struct {
// The OCID of the compartment where you want to list resources.
CompartmentId string `pulumi:"compartmentId"`
// A filter to return only resources that match the entire display name given. The match is not case sensitive.
DisplayName *string `pulumi:"displayName"`
Filters []GetCatalogPrivateEndpointsFilter `pulumi:"filters"`
// A filter to return only resources that match the specified lifecycle state. The value is case insensitive.
State *string `pulumi:"state"`
}
// A collection of values returned by getCatalogPrivateEndpoints.
type GetCatalogPrivateEndpointsResult struct {
// The list of catalog_private_endpoints.
CatalogPrivateEndpoints []GetCatalogPrivateEndpointsCatalogPrivateEndpoint `pulumi:"catalogPrivateEndpoints"`
// Identifier of the compartment this private endpoint belongs to
CompartmentId string `pulumi:"compartmentId"`
// Mutable name of the Private Reverse Connection Endpoint
DisplayName *string `pulumi:"displayName"`
Filters []GetCatalogPrivateEndpointsFilter `pulumi:"filters"`
// The provider-assigned unique ID for this managed resource.
Id string `pulumi:"id"`
// The current state of the private endpoint resource.
State *string `pulumi:"state"`
}
func GetCatalogPrivateEndpointsOutput(ctx *pulumi.Context, args GetCatalogPrivateEndpointsOutputArgs, opts ...pulumi.InvokeOption) GetCatalogPrivateEndpointsResultOutput {
return pulumi.ToOutputWithContext(context.Background(), args).
ApplyT(func(v interface{}) (GetCatalogPrivateEndpointsResult, error) {
args := v.(GetCatalogPrivateEndpointsArgs)
r, err := GetCatalogPrivateEndpoints(ctx, &args, opts...)
var s GetCatalogPrivateEndpointsResult
if r != nil {
s = *r
}
return s, err
}).(GetCatalogPrivateEndpointsResultOutput)
}
// A collection of arguments for invoking getCatalogPrivateEndpoints.
type GetCatalogPrivateEndpointsOutputArgs struct {
// The OCID of the compartment where you want to list resources.
CompartmentId pulumi.StringInput `pulumi:"compartmentId"`
// A filter to return only resources that match the entire display name given. The match is not case sensitive.
DisplayName pulumi.StringPtrInput `pulumi:"displayName"`
Filters GetCatalogPrivateEndpointsFilterArrayInput `pulumi:"filters"`
// A filter to return only resources that match the specified lifecycle state. The value is case insensitive.
State pulumi.StringPtrInput `pulumi:"state"`
}
func (GetCatalogPrivateEndpointsOutputArgs) ElementType() reflect.Type {
return reflect.TypeOf((*GetCatalogPrivateEndpointsArgs)(nil)).Elem()
}
// A collection of values returned by getCatalogPrivateEndpoints.
type GetCatalogPrivateEndpointsResultOutput struct{ *pulumi.OutputState }
func (GetCatalogPrivateEndpointsResultOutput) ElementType() reflect.Type {
return reflect.TypeOf((*GetCatalogPrivateEndpointsResult)(nil)).Elem()
}
func (o GetCatalogPrivateEndpointsResultOutput) ToGetCatalogPrivateEndpointsResultOutput() GetCatalogPrivateEndpointsResultOutput {
return o
}
func (o GetCatalogPrivateEndpointsResultOutput) ToGetCatalogPrivateEndpointsResultOutputWithContext(ctx context.Context) GetCatalogPrivateEndpointsResultOutput {
return o
}
// The list of catalog_private_endpoints.
func (o GetCatalogPrivateEndpointsResultOutput) CatalogPrivateEndpoints() GetCatalogPrivateEndpointsCatalogPrivateEndpointArrayOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) []GetCatalogPrivateEndpointsCatalogPrivateEndpoint {
return v.CatalogPrivateEndpoints
}).(GetCatalogPrivateEndpointsCatalogPrivateEndpointArrayOutput)
}
// Identifier of the compartment this private endpoint belongs to
func (o GetCatalogPrivateEndpointsResultOutput) CompartmentId() pulumi.StringOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) string { return v.CompartmentId }).(pulumi.StringOutput)
}
// Mutable name of the Private Reverse Connection Endpoint
func (o GetCatalogPrivateEndpointsResultOutput) DisplayName() pulumi.StringPtrOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) *string { return v.DisplayName }).(pulumi.StringPtrOutput)
}
func (o GetCatalogPrivateEndpointsResultOutput) Filters() GetCatalogPrivateEndpointsFilterArrayOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) []GetCatalogPrivateEndpointsFilter { return v.Filters }).(GetCatalogPrivateEndpointsFilterArrayOutput)
}
// The provider-assigned unique ID for this managed resource.
func (o GetCatalogPrivateEndpointsResultOutput) Id() pulumi.StringOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) string { return v.Id }).(pulumi.StringOutput)
}
// The current state of the private endpoint resource.
func (o GetCatalogPrivateEndpointsResultOutput) State() pulumi.StringPtrOutput {
return o.ApplyT(func(v GetCatalogPrivateEndpointsResult) *string { return v.State }).(pulumi.StringPtrOutput)
}
func init() {
pulumi.RegisterOutputType(GetCatalogPrivateEndpointsResultOutput{})
}