// Code generated by test DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***

package urnid

import (
	"context"
	"reflect"

	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"urn-id-properties/urnid/internal"
)

// It's fine to use urn and id as input properties
type Res struct {
	pulumi.CustomResourceState

	Output InnerTypePtrOutput `pulumi:"output"`
}

// NewRes registers a new resource with the given unique name, arguments, and options.
func NewRes(ctx *pulumi.Context,
	name string, args *ResArgs, opts ...pulumi.ResourceOption) (*Res, error) {
	if args == nil {
		args = &ResArgs{}
	}

	opts = internal.PkgResourceDefaultOpts(opts)
	var resource Res
	err := ctx.RegisterResource("urnid:index:Res", name, args, &resource, opts...)
	if err != nil {
		return nil, err
	}
	return &resource, nil
}

// GetRes gets an existing Res resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetRes(ctx *pulumi.Context,
	name string, id pulumi.IDInput, state *ResState, opts ...pulumi.ResourceOption) (*Res, error) {
	var resource Res
	err := ctx.ReadResource("urnid:index:Res", name, id, state, &resource, opts...)
	if err != nil {
		return nil, err
	}
	return &resource, nil
}

// Input properties used for looking up and filtering Res resources.
type resState struct {
}

type ResState struct {
}

func (ResState) ElementType() reflect.Type {
	return reflect.TypeOf((*resState)(nil)).Elem()
}

type resArgs struct {
	Id  *string `pulumi:"id"`
	Urn *string `pulumi:"urn"`
}

// The set of arguments for constructing a Res resource.
type ResArgs struct {
	Id  pulumi.StringPtrInput
	Urn pulumi.StringPtrInput
}

func (ResArgs) ElementType() reflect.Type {
	return reflect.TypeOf((*resArgs)(nil)).Elem()
}

type ResInput interface {
	pulumi.Input

	ToResOutput() ResOutput
	ToResOutputWithContext(ctx context.Context) ResOutput
}

func (*Res) ElementType() reflect.Type {
	return reflect.TypeOf((**Res)(nil)).Elem()
}

func (i *Res) ToResOutput() ResOutput {
	return i.ToResOutputWithContext(context.Background())
}

func (i *Res) ToResOutputWithContext(ctx context.Context) ResOutput {
	return pulumi.ToOutputWithContext(ctx, i).(ResOutput)
}

type ResOutput struct{ *pulumi.OutputState }

func (ResOutput) ElementType() reflect.Type {
	return reflect.TypeOf((**Res)(nil)).Elem()
}

func (o ResOutput) ToResOutput() ResOutput {
	return o
}

func (o ResOutput) ToResOutputWithContext(ctx context.Context) ResOutput {
	return o
}

func (o ResOutput) Output() InnerTypePtrOutput {
	return o.ApplyT(func(v *Res) InnerTypePtrOutput { return v.Output }).(InnerTypePtrOutput)
}

func init() {
	pulumi.RegisterInputType(reflect.TypeOf((*ResInput)(nil)).Elem(), &Res{})
	pulumi.RegisterOutputType(ResOutput{})
}