...

Source file src/google.golang.org/genproto/googleapis/actions/sdk/v2/conversation/image.pb.go

Documentation: google.golang.org/genproto/googleapis/actions/sdk/v2/conversation

     1  // Copyright 2024 Google LLC
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //     http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  // Code generated by protoc-gen-go. DO NOT EDIT.
    16  // versions:
    17  // 	protoc-gen-go v1.26.0
    18  // 	protoc        v4.24.4
    19  // source: google/actions/sdk/v2/conversation/prompt/content/image.proto
    20  
    21  package conversation
    22  
    23  import (
    24  	reflect "reflect"
    25  	sync "sync"
    26  
    27  	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
    28  	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
    29  )
    30  
    31  const (
    32  	// Verify that this generated code is sufficiently up-to-date.
    33  	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
    34  	// Verify that runtime/protoimpl is sufficiently up-to-date.
    35  	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
    36  )
    37  
    38  // Possible image display options for affecting the presentation of the image.
    39  // This should be used for when the image's aspect ratio does not match the
    40  // image container's aspect ratio.
    41  type Image_ImageFill int32
    42  
    43  const (
    44  	// Unspecified image fill.
    45  	Image_UNSPECIFIED Image_ImageFill = 0
    46  	// Fill the gaps between the image and the image container with gray bars.
    47  	Image_GRAY Image_ImageFill = 1
    48  	// Fill the gaps between the image and the image container with white bars.
    49  	Image_WHITE Image_ImageFill = 2
    50  	// Image is scaled such that the image width and height match or exceed the
    51  	// container dimensions. This may crop the top and bottom of the image if
    52  	// the scaled image height is greater than the container height, or crop the
    53  	// left and right of the image if the scaled image width is greater than the
    54  	// container width. This is similar to "Zoom Mode" on a widescreen TV when
    55  	// playing a 4:3 video.
    56  	Image_CROPPED Image_ImageFill = 3
    57  )
    58  
    59  // Enum value maps for Image_ImageFill.
    60  var (
    61  	Image_ImageFill_name = map[int32]string{
    62  		0: "UNSPECIFIED",
    63  		1: "GRAY",
    64  		2: "WHITE",
    65  		3: "CROPPED",
    66  	}
    67  	Image_ImageFill_value = map[string]int32{
    68  		"UNSPECIFIED": 0,
    69  		"GRAY":        1,
    70  		"WHITE":       2,
    71  		"CROPPED":     3,
    72  	}
    73  )
    74  
    75  func (x Image_ImageFill) Enum() *Image_ImageFill {
    76  	p := new(Image_ImageFill)
    77  	*p = x
    78  	return p
    79  }
    80  
    81  func (x Image_ImageFill) String() string {
    82  	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
    83  }
    84  
    85  func (Image_ImageFill) Descriptor() protoreflect.EnumDescriptor {
    86  	return file_google_actions_sdk_v2_conversation_prompt_content_image_proto_enumTypes[0].Descriptor()
    87  }
    88  
    89  func (Image_ImageFill) Type() protoreflect.EnumType {
    90  	return &file_google_actions_sdk_v2_conversation_prompt_content_image_proto_enumTypes[0]
    91  }
    92  
    93  func (x Image_ImageFill) Number() protoreflect.EnumNumber {
    94  	return protoreflect.EnumNumber(x)
    95  }
    96  
    97  // Deprecated: Use Image_ImageFill.Descriptor instead.
    98  func (Image_ImageFill) EnumDescriptor() ([]byte, []int) {
    99  	return file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescGZIP(), []int{0, 0}
   100  }
   101  
   102  // An image displayed in the card.
   103  type Image struct {
   104  	state         protoimpl.MessageState
   105  	sizeCache     protoimpl.SizeCache
   106  	unknownFields protoimpl.UnknownFields
   107  
   108  	// The source url of the image. Images can be JPG, PNG and GIF (animated and
   109  	// non-animated). For example,`https://www.agentx.com/logo.png`. Required.
   110  	Url string `protobuf:"bytes,1,opt,name=url,proto3" json:"url,omitempty"`
   111  	// A text description of the image to be used for accessibility, e.g. screen
   112  	// readers.
   113  	// Required.
   114  	Alt string `protobuf:"bytes,2,opt,name=alt,proto3" json:"alt,omitempty"`
   115  	// The height of the image in pixels.
   116  	// Optional.
   117  	Height int32 `protobuf:"varint,3,opt,name=height,proto3" json:"height,omitempty"`
   118  	// The width of the image in pixels.
   119  	// Optional.
   120  	Width int32 `protobuf:"varint,4,opt,name=width,proto3" json:"width,omitempty"`
   121  }
   122  
   123  func (x *Image) Reset() {
   124  	*x = Image{}
   125  	if protoimpl.UnsafeEnabled {
   126  		mi := &file_google_actions_sdk_v2_conversation_prompt_content_image_proto_msgTypes[0]
   127  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   128  		ms.StoreMessageInfo(mi)
   129  	}
   130  }
   131  
   132  func (x *Image) String() string {
   133  	return protoimpl.X.MessageStringOf(x)
   134  }
   135  
   136  func (*Image) ProtoMessage() {}
   137  
   138  func (x *Image) ProtoReflect() protoreflect.Message {
   139  	mi := &file_google_actions_sdk_v2_conversation_prompt_content_image_proto_msgTypes[0]
   140  	if protoimpl.UnsafeEnabled && x != nil {
   141  		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
   142  		if ms.LoadMessageInfo() == nil {
   143  			ms.StoreMessageInfo(mi)
   144  		}
   145  		return ms
   146  	}
   147  	return mi.MessageOf(x)
   148  }
   149  
   150  // Deprecated: Use Image.ProtoReflect.Descriptor instead.
   151  func (*Image) Descriptor() ([]byte, []int) {
   152  	return file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescGZIP(), []int{0}
   153  }
   154  
   155  func (x *Image) GetUrl() string {
   156  	if x != nil {
   157  		return x.Url
   158  	}
   159  	return ""
   160  }
   161  
   162  func (x *Image) GetAlt() string {
   163  	if x != nil {
   164  		return x.Alt
   165  	}
   166  	return ""
   167  }
   168  
   169  func (x *Image) GetHeight() int32 {
   170  	if x != nil {
   171  		return x.Height
   172  	}
   173  	return 0
   174  }
   175  
   176  func (x *Image) GetWidth() int32 {
   177  	if x != nil {
   178  		return x.Width
   179  	}
   180  	return 0
   181  }
   182  
   183  var File_google_actions_sdk_v2_conversation_prompt_content_image_proto protoreflect.FileDescriptor
   184  
   185  var file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDesc = []byte{
   186  	0x0a, 0x3d, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73,
   187  	0x2f, 0x73, 0x64, 0x6b, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x61,
   188  	0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x70, 0x72, 0x6f, 0x6d, 0x70, 0x74, 0x2f, 0x63, 0x6f, 0x6e, 0x74,
   189  	0x65, 0x6e, 0x74, 0x2f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
   190  	0x22, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e,
   191  	0x73, 0x64, 0x6b, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x61, 0x74,
   192  	0x69, 0x6f, 0x6e, 0x22, 0x99, 0x01, 0x0a, 0x05, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a,
   193  	0x03, 0x75, 0x72, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x72, 0x6c, 0x12,
   194  	0x10, 0x0a, 0x03, 0x61, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x61, 0x6c,
   195  	0x74, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28,
   196  	0x05, 0x52, 0x06, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x77, 0x69, 0x64,
   197  	0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x77, 0x69, 0x64, 0x74, 0x68, 0x22,
   198  	0x3e, 0x0a, 0x09, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x46, 0x69, 0x6c, 0x6c, 0x12, 0x0f, 0x0a, 0x0b,
   199  	0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x08, 0x0a,
   200  	0x04, 0x47, 0x52, 0x41, 0x59, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x57, 0x48, 0x49, 0x54, 0x45,
   201  	0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x43, 0x52, 0x4f, 0x50, 0x50, 0x45, 0x44, 0x10, 0x03, 0x42,
   202  	0x86, 0x01, 0x0a, 0x26, 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x61,
   203  	0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x73, 0x64, 0x6b, 0x2e, 0x76, 0x32, 0x2e, 0x63, 0x6f,
   204  	0x6e, 0x76, 0x65, 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0a, 0x49, 0x6d, 0x61, 0x67,
   205  	0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x4e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
   206  	0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67, 0x65, 0x6e, 0x70,
   207  	0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70, 0x69, 0x73, 0x2f,
   208  	0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x73, 0x64, 0x6b, 0x2f, 0x76, 0x32, 0x2f, 0x63,
   209  	0x6f, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x3b, 0x63, 0x6f, 0x6e, 0x76,
   210  	0x65, 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
   211  }
   212  
   213  var (
   214  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescOnce sync.Once
   215  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescData = file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDesc
   216  )
   217  
   218  func file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescGZIP() []byte {
   219  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescOnce.Do(func() {
   220  		file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescData)
   221  	})
   222  	return file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDescData
   223  }
   224  
   225  var file_google_actions_sdk_v2_conversation_prompt_content_image_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
   226  var file_google_actions_sdk_v2_conversation_prompt_content_image_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
   227  var file_google_actions_sdk_v2_conversation_prompt_content_image_proto_goTypes = []interface{}{
   228  	(Image_ImageFill)(0), // 0: google.actions.sdk.v2.conversation.Image.ImageFill
   229  	(*Image)(nil),        // 1: google.actions.sdk.v2.conversation.Image
   230  }
   231  var file_google_actions_sdk_v2_conversation_prompt_content_image_proto_depIdxs = []int32{
   232  	0, // [0:0] is the sub-list for method output_type
   233  	0, // [0:0] is the sub-list for method input_type
   234  	0, // [0:0] is the sub-list for extension type_name
   235  	0, // [0:0] is the sub-list for extension extendee
   236  	0, // [0:0] is the sub-list for field type_name
   237  }
   238  
   239  func init() { file_google_actions_sdk_v2_conversation_prompt_content_image_proto_init() }
   240  func file_google_actions_sdk_v2_conversation_prompt_content_image_proto_init() {
   241  	if File_google_actions_sdk_v2_conversation_prompt_content_image_proto != nil {
   242  		return
   243  	}
   244  	if !protoimpl.UnsafeEnabled {
   245  		file_google_actions_sdk_v2_conversation_prompt_content_image_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
   246  			switch v := v.(*Image); i {
   247  			case 0:
   248  				return &v.state
   249  			case 1:
   250  				return &v.sizeCache
   251  			case 2:
   252  				return &v.unknownFields
   253  			default:
   254  				return nil
   255  			}
   256  		}
   257  	}
   258  	type x struct{}
   259  	out := protoimpl.TypeBuilder{
   260  		File: protoimpl.DescBuilder{
   261  			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
   262  			RawDescriptor: file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDesc,
   263  			NumEnums:      1,
   264  			NumMessages:   1,
   265  			NumExtensions: 0,
   266  			NumServices:   0,
   267  		},
   268  		GoTypes:           file_google_actions_sdk_v2_conversation_prompt_content_image_proto_goTypes,
   269  		DependencyIndexes: file_google_actions_sdk_v2_conversation_prompt_content_image_proto_depIdxs,
   270  		EnumInfos:         file_google_actions_sdk_v2_conversation_prompt_content_image_proto_enumTypes,
   271  		MessageInfos:      file_google_actions_sdk_v2_conversation_prompt_content_image_proto_msgTypes,
   272  	}.Build()
   273  	File_google_actions_sdk_v2_conversation_prompt_content_image_proto = out.File
   274  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_rawDesc = nil
   275  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_goTypes = nil
   276  	file_google_actions_sdk_v2_conversation_prompt_content_image_proto_depIdxs = nil
   277  }
   278  

View as plain text