Show / Hide Table of Contents

Class FullHashResponseBuilder

Full Hash Response Builder.

Inheritance
System.Object
FullHashResponseBuilder
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Gee.External.Browsing.Clients
Assembly: Gee.External.Browsing.dll
Syntax
public sealed class FullHashResponseBuilder

Methods

AddUnsafeThreat(UnsafeThreat)

Add an Unsafe Threat.

Declaration
public FullHashResponseBuilder AddUnsafeThreat(UnsafeThreat value)
Parameters
Type Name Description
UnsafeThreat value

An UnsafeThreat.

Returns
Type Description
FullHashResponseBuilder

This full hash response builder.

Exceptions
Type Condition
System.ArgumentNullException

Thrown if value is a null reference.

AddUnsafeThreat(String, ThreatListDescriptor, DateTime)

Add an Unsafe Threat.

Declaration
public FullHashResponseBuilder AddUnsafeThreat(string sha256Hash, ThreatListDescriptor associatedThreatListDescriptor, DateTime expirationDate)
Parameters
Type Name Description
System.String sha256Hash

A full SHA256 hash, formatted as a hexadecimal encoded string, identifying the threat.

ThreatListDescriptor associatedThreatListDescriptor

A ThreatListDescriptor identifying the ThreatList the threat is associated with.

System.DateTime expirationDate

The date, in Coordinated Universal Time (UTC), the threat should be considered unsafe to. If the date is not in UTC, it is converted to it.

Returns
Type Description
FullHashResponseBuilder

This full hash response builder.

Exceptions
Type Condition
System.ArgumentNullException

Thrown if sha256Hash is a null reference, or if associatedThreatListDescriptor is a null reference.

System.FormatException

Thrown if sha256Hash is not hexadecimal encoded.

Build()

Build a Full Hash Response.

Declaration
public FullHashResponse Build()
Returns
Type Description
FullHashResponse

A FullHashResponse.

SetRequest(FullHashRequest)

Set Request.

Declaration
public FullHashResponseBuilder SetRequest(FullHashRequest value)
Parameters
Type Name Description
FullHashRequest value

The FullHashRequest made to the Google Safe Browsing API for which the full hash response has been returned.

Returns
Type Description
FullHashResponseBuilder

This full hash response builder.

Exceptions
Type Condition
System.ArgumentNullException

Thrown if value is a null reference.

SetSafeThreatsExpirationDate(DateTime)

Set Safe Threats Expiration Date.

Declaration
public FullHashResponseBuilder SetSafeThreatsExpirationDate(DateTime value)
Parameters
Type Name Description
System.DateTime value

The date, in Coordinated Universal Time (UTC), safe threats should be considered safe to. If the date is not in UTC, it is converted to it.

Returns
Type Description
FullHashResponseBuilder

This full hash response builder.

SetWaitToDate(Nullable<DateTime>)

Set Wait to Date.

Declaration
public FullHashResponseBuilder SetWaitToDate(DateTime? value)
Parameters
Type Name Description
System.Nullable<System.DateTime> value

The date, in Coordinated Universal Time (UTC), a client must wait to before issuing another FullHashRequest to the Google Safe Browsing API. If the date is not in UTC, it is converted to it. A null reference indicates a client does not have to wait.

Returns
Type Description
FullHashResponseBuilder

This full hash response builder.

Back to top Generated by DocFX