Class SafeSearchAnnotation (3.78.0)

publicfinalclass SafeSearchAnnotationextendsGeneratedMessageV3implementsSafeSearchAnnotationOrBuilder

Set of features pertaining to the image, computed by computer vision methods over safe-search verticals (for example, adult, spoof, medical, violence).

Protobuf type google.cloud.vision.v1p4beta1.SafeSearchAnnotation

Inherited Members

com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)

Static Fields

ADULT_FIELD_NUMBER

publicstaticfinalintADULT_FIELD_NUMBER
Field Value
Type Description
int

MEDICAL_FIELD_NUMBER

publicstaticfinalintMEDICAL_FIELD_NUMBER
Field Value
Type Description
int

RACY_FIELD_NUMBER

publicstaticfinalintRACY_FIELD_NUMBER
Field Value
Type Description
int

SPOOF_FIELD_NUMBER

publicstaticfinalintSPOOF_FIELD_NUMBER
Field Value
Type Description
int

VIOLENCE_FIELD_NUMBER

publicstaticfinalintVIOLENCE_FIELD_NUMBER
Field Value
Type Description
int

Static Methods

getDefaultInstance()

publicstaticSafeSearchAnnotationgetDefaultInstance()
Returns
Type Description
SafeSearchAnnotation

getDescriptor()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
Type Description
Descriptor

newBuilder()

publicstaticSafeSearchAnnotation.BuildernewBuilder()
Returns
Type Description
SafeSearchAnnotation.Builder

newBuilder(SafeSearchAnnotation prototype)

publicstaticSafeSearchAnnotation.BuildernewBuilder(SafeSearchAnnotationprototype)
Parameter
Name Description
prototype SafeSearchAnnotation
Returns
Type Description
SafeSearchAnnotation.Builder

parseDelimitedFrom(InputStream input)

publicstaticSafeSearchAnnotationparseDelimitedFrom(InputStreaminput)
Parameter
Name Description
input InputStream
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseDelimitedFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseFrom(byte[] data)

publicstaticSafeSearchAnnotationparseFrom(byte[]data)
Parameter
Name Description
data byte[]
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseFrom(byte[]data,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data byte[]
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data)

publicstaticSafeSearchAnnotationparseFrom(ByteStringdata)
Parameter
Name Description
data ByteString
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseFrom(ByteStringdata,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data ByteString
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

publicstaticSafeSearchAnnotationparseFrom(CodedInputStreaminput)
Parameter
Name Description
input CodedInputStream
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseFrom(InputStream input)

publicstaticSafeSearchAnnotationparseFrom(InputStreaminput)
Parameter
Name Description
input InputStream
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseFrom(InputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input InputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
IOException

parseFrom(ByteBuffer data)

publicstaticSafeSearchAnnotationparseFrom(ByteBufferdata)
Parameter
Name Description
data ByteBuffer
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

publicstaticSafeSearchAnnotationparseFrom(ByteBufferdata,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
data ByteBuffer
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafeSearchAnnotation
Exceptions
Type Description
InvalidProtocolBufferException

parser()

publicstaticParser<SafeSearchAnnotation>parser()
Returns
Type Description
Parser<SafeSearchAnnotation>

Methods

equals(Object obj)

publicbooleanequals(Objectobj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

getAdult()

publicLikelihoodgetAdult()

Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities.

.google.cloud.vision.v1p4beta1.Likelihood adult = 1;

Returns
Type Description
Likelihood

The adult.

getAdultValue()

publicintgetAdultValue()

Represents the adult content likelihood for the image. Adult content may contain elements such as nudity, pornographic images or cartoons, or sexual activities.

.google.cloud.vision.v1p4beta1.Likelihood adult = 1;

Returns
Type Description
int

The enum numeric value on the wire for adult.

getDefaultInstanceForType()

publicSafeSearchAnnotationgetDefaultInstanceForType()
Returns
Type Description
SafeSearchAnnotation

getMedical()

publicLikelihoodgetMedical()

Likelihood that this is a medical image.

.google.cloud.vision.v1p4beta1.Likelihood medical = 3;

Returns
Type Description
Likelihood

The medical.

getMedicalValue()

publicintgetMedicalValue()

Likelihood that this is a medical image.

.google.cloud.vision.v1p4beta1.Likelihood medical = 3;

Returns
Type Description
int

The enum numeric value on the wire for medical.

getParserForType()

publicParser<SafeSearchAnnotation>getParserForType()
Returns
Type Description
Parser<SafeSearchAnnotation>
Overrides

getRacy()

publicLikelihoodgetRacy()

Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas.

.google.cloud.vision.v1p4beta1.Likelihood racy = 9;

Returns
Type Description
Likelihood

The racy.

getRacyValue()

publicintgetRacyValue()

Likelihood that the request image contains racy content. Racy content may include (but is not limited to) skimpy or sheer clothing, strategically covered nudity, lewd or provocative poses, or close-ups of sensitive body areas.

.google.cloud.vision.v1p4beta1.Likelihood racy = 9;

Returns
Type Description
int

The enum numeric value on the wire for racy.

getSerializedSize()

publicintgetSerializedSize()
Returns
Type Description
int
Overrides

getSpoof()

publicLikelihoodgetSpoof()

Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive.

.google.cloud.vision.v1p4beta1.Likelihood spoof = 2;

Returns
Type Description
Likelihood

The spoof.

getSpoofValue()

publicintgetSpoofValue()

Spoof likelihood. The likelihood that an modification was made to the image's canonical version to make it appear funny or offensive.

.google.cloud.vision.v1p4beta1.Likelihood spoof = 2;

Returns
Type Description
int

The enum numeric value on the wire for spoof.

getViolence()

publicLikelihoodgetViolence()

Likelihood that this image contains violent content.

.google.cloud.vision.v1p4beta1.Likelihood violence = 4;

Returns
Type Description
Likelihood

The violence.

getViolenceValue()

publicintgetViolenceValue()

Likelihood that this image contains violent content.

.google.cloud.vision.v1p4beta1.Likelihood violence = 4;

Returns
Type Description
int

The enum numeric value on the wire for violence.

hashCode()

publicinthashCode()
Returns
Type Description
int
Overrides

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
Type Description
boolean
Overrides

newBuilderForType()

publicSafeSearchAnnotation.BuildernewBuilderForType()
Returns
Type Description
SafeSearchAnnotation.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protectedSafeSearchAnnotation.BuildernewBuilderForType(GeneratedMessageV3.BuilderParentparent)
Parameter
Name Description
parent BuilderParent
Returns
Type Description
SafeSearchAnnotation.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protectedObjectnewInstance(GeneratedMessageV3.UnusedPrivateParameterunused)
Parameter
Name Description
unused UnusedPrivateParameter
Returns
Type Description
Object
Overrides

toBuilder()

publicSafeSearchAnnotation.BuildertoBuilder()
Returns
Type Description
SafeSearchAnnotation.Builder

writeTo(CodedOutputStream output)

publicvoidwriteTo(CodedOutputStreamoutput)
Parameter
Name Description
output CodedOutputStream
Overrides
Exceptions
Type Description
IOException

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年11月19日 UTC.