remove

Available in a dev version: 0․11․0-grpc-186

How to configure

expect fun GrpcMetadata.remove(key: String, value: String): Boolean(source)

Removes the first occurrence of the specified value for the given key.

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the name of the metadata entry (case-insensitive). Must contain only digits (0-9), lowercase letters (a-z), and special characters (-, _, .). Must not end with -bin.

value

the value to remove

Throws

if the key ends with -bin or contains invalid characters


expect fun <T> GrpcMetadata.remove(key: GrpcMetadataKey<T>, value: T): Boolean(source)

Removes the first occurrence of the specified value for the given typed key.

The value is compared using the decoded form (after decoding with the key's marshaller). The marshaller must encode values as ASCII strings (not raw bytes).

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the typed metadata key. The key name must not end with -bin.

value

the value to remove

Type Parameters

T

the type of value associated with the key

Throws

if the key name ends with -bin or contains invalid characters

actual fun GrpcMetadata.remove(key: String, value: String): Boolean(source)

Removes the first occurrence of the specified value for the given key.

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the name of the metadata entry (case-insensitive). Must contain only digits (0-9), lowercase letters (a-z), and special characters (-, _, .). Must not end with -bin.

value

the value to remove

Throws

if the key ends with -bin or contains invalid characters


actual fun <T> GrpcMetadata.remove(key: GrpcMetadataKey<T>, value: T): Boolean(source)

Removes the first occurrence of the specified value for the given typed key.

The value is compared using the decoded form (after decoding with the key's marshaller). The marshaller must encode values as ASCII strings (not raw bytes).

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the typed metadata key. The key name must not end with -bin.

value

the value to remove

Type Parameters

T

the type of value associated with the key

Throws

if the key name ends with -bin or contains invalid characters

actual fun GrpcMetadata.remove(key: String, value: String): Boolean(source)

Removes the first occurrence of the specified value for the given key.

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the name of the metadata entry (case-insensitive). Must contain only digits (0-9), lowercase letters (a-z), and special characters (-, _, .). Must not end with -bin.

value

the value to remove

Throws

if the key ends with -bin or contains invalid characters


actual fun <T> GrpcMetadata.remove(key: GrpcMetadataKey<T>, value: T): Boolean(source)

Removes the first occurrence of the specified value for the given typed key.

The value is compared using the decoded form (after decoding with the key's marshaller). The marshaller must encode values as ASCII strings (not raw bytes).

Return

true if the value was found and removed, false if the value was not present

Parameters

key

the typed metadata key. The key name must not end with -bin.

value

the value to remove

Type Parameters

T

the type of value associated with the key

Throws

if the key name ends with -bin or contains invalid characters