NAME

Google::Cloud::Retail::V2::Safety - Compiled Protocol Buffers messages for google/cloud/retail/v2/safety.proto

SYNOPSIS

use Google::Cloud::Retail::V2::Safety;

my $msg = Google::Cloud::Retail::V2::Safety::SafetySetting->new({
    category => $category,
    threshold => $threshold,
    method => $method,
});

# Read or update a field
my $val = $msg->category();

# Binary wire-format roundtrip
my $bytes   = $msg->serialize();
my $decoded = Google::Cloud::Retail::V2::Safety::SafetySetting->parse($bytes);

# Canonical ProtoJSON
my $json = $msg->to_json();

DESCRIPTION

Auto-generated Protobuf message classes compiled from google/cloud/retail/v2/safety.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().

MESSAGES

Google::Cloud::Retail::V2::Safety::SafetySetting

Safety settings.

Inherits from Protobuf::Message.

Accessors

Enum: SafetySetting::HarmBlockThreshold

  • HARM_BLOCK_THRESHOLD_UNSPECIFIED => 0

  • BLOCK_LOW_AND_ABOVE => 1

  • BLOCK_MEDIUM_AND_ABOVE => 2

  • BLOCK_ONLY_HIGH => 3

  • BLOCK_NONE => 4

  • OFF => 5

Enum: SafetySetting::HarmBlockMethod

  • HARM_BLOCK_METHOD_UNSPECIFIED => 0

  • SEVERITY => 1

  • PROBABILITY => 2

SEE ALSO

Protobuf, Protobuf::Message, Google::Cloud::Retail::V2::Safety::Types, https://protobuf.dev/

LICENSE AND COPYRIGHT

Copyright (C) 2026 Google LLC

This program is released under the Apache 2.0 license.