Class SearchHashesResponse.ThreatHash.Builder

    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<SearchHashesResponse.ThreatHash.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<SearchHashesResponse.ThreatHash.Builder>
      • getDefaultInstanceForType

        public SearchHashesResponse.ThreatHash getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public SearchHashesResponse.ThreatHash build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public SearchHashesResponse.ThreatHash buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<SearchHashesResponse.ThreatHash.Builder>
      • getThreatTypesCount

        public int getThreatTypesCount()
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Specified by:
        getThreatTypesCount in interface SearchHashesResponse.ThreatHashOrBuilder
        Returns:
        The count of threatTypes.
      • getThreatTypes

        public ThreatType getThreatTypes​(int index)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Specified by:
        getThreatTypes in interface SearchHashesResponse.ThreatHashOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The threatTypes at the given index.
      • setThreatTypes

        public SearchHashesResponse.ThreatHash.Builder setThreatTypes​(int index,
                                                                      ThreatType value)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        index - The index to set the value at.
        value - The threatTypes to set.
        Returns:
        This builder for chaining.
      • addThreatTypes

        public SearchHashesResponse.ThreatHash.Builder addThreatTypes​(ThreatType value)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        value - The threatTypes to add.
        Returns:
        This builder for chaining.
      • addAllThreatTypes

        public SearchHashesResponse.ThreatHash.Builder addAllThreatTypes​(Iterable<? extends ThreatType> values)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        values - The threatTypes to add.
        Returns:
        This builder for chaining.
      • clearThreatTypes

        public SearchHashesResponse.ThreatHash.Builder clearThreatTypes()
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Returns:
        This builder for chaining.
      • getThreatTypesValueList

        public List<Integer> getThreatTypesValueList()
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Specified by:
        getThreatTypesValueList in interface SearchHashesResponse.ThreatHashOrBuilder
        Returns:
        A list containing the enum numeric values on the wire for threatTypes.
      • getThreatTypesValue

        public int getThreatTypesValue​(int index)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Specified by:
        getThreatTypesValue in interface SearchHashesResponse.ThreatHashOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The enum numeric value on the wire of threatTypes at the given index.
      • setThreatTypesValue

        public SearchHashesResponse.ThreatHash.Builder setThreatTypesValue​(int index,
                                                                           int value)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        index - The index to set the value at.
        value - The enum numeric value on the wire for threatTypes to set.
        Returns:
        This builder for chaining.
      • addThreatTypesValue

        public SearchHashesResponse.ThreatHash.Builder addThreatTypesValue​(int value)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        value - The enum numeric value on the wire for threatTypes to add.
        Returns:
        This builder for chaining.
      • addAllThreatTypesValue

        public SearchHashesResponse.ThreatHash.Builder addAllThreatTypesValue​(Iterable<Integer> values)
         The ThreatList this threat belongs to.
         This must contain at least one entry.
         
        repeated .google.cloud.webrisk.v1beta1.ThreatType threat_types = 1;
        Parameters:
        values - The enum numeric values on the wire for threatTypes to add.
        Returns:
        This builder for chaining.
      • getHash

        public com.google.protobuf.ByteString getHash()
         A 32 byte SHA256 hash. This field is in binary format. For JSON
         requests, hashes are base64-encoded.
         
        bytes hash = 2;
        Specified by:
        getHash in interface SearchHashesResponse.ThreatHashOrBuilder
        Returns:
        The hash.
      • setHash

        public SearchHashesResponse.ThreatHash.Builder setHash​(com.google.protobuf.ByteString value)
         A 32 byte SHA256 hash. This field is in binary format. For JSON
         requests, hashes are base64-encoded.
         
        bytes hash = 2;
        Parameters:
        value - The hash to set.
        Returns:
        This builder for chaining.
      • clearHash

        public SearchHashesResponse.ThreatHash.Builder clearHash()
         A 32 byte SHA256 hash. This field is in binary format. For JSON
         requests, hashes are base64-encoded.
         
        bytes hash = 2;
        Returns:
        This builder for chaining.
      • hasExpireTime

        public boolean hasExpireTime()
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
        Specified by:
        hasExpireTime in interface SearchHashesResponse.ThreatHashOrBuilder
        Returns:
        Whether the expireTime field is set.
      • getExpireTime

        public com.google.protobuf.Timestamp getExpireTime()
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
        Specified by:
        getExpireTime in interface SearchHashesResponse.ThreatHashOrBuilder
        Returns:
        The expireTime.
      • setExpireTime

        public SearchHashesResponse.ThreatHash.Builder setExpireTime​(com.google.protobuf.Timestamp value)
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
      • setExpireTime

        public SearchHashesResponse.ThreatHash.Builder setExpireTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
      • mergeExpireTime

        public SearchHashesResponse.ThreatHash.Builder mergeExpireTime​(com.google.protobuf.Timestamp value)
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
      • clearExpireTime

        public SearchHashesResponse.ThreatHash.Builder clearExpireTime()
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
      • getExpireTimeBuilder

        public com.google.protobuf.Timestamp.Builder getExpireTimeBuilder()
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
      • getExpireTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getExpireTimeOrBuilder()
         The cache lifetime for the returned match. Clients must not cache this
         response past this timestamp to avoid false positives.
         
        .google.protobuf.Timestamp expire_time = 3;
        Specified by:
        getExpireTimeOrBuilder in interface SearchHashesResponse.ThreatHashOrBuilder