package io.grpc; import com.google.common.io.BaseEncoding; import io.grpc.Metadata; import java.nio.charset.Charset; import java.nio.charset.StandardCharsets; /* loaded from: classes6.dex */ public final class InternalMetadata { public static final Charset US_ASCII = StandardCharsets.US_ASCII; public static final BaseEncoding BASE64_ENCODING_OMIT_PADDING = Metadata.BASE64_ENCODING_OMIT_PADDING; /* loaded from: classes6.dex */ public interface TrustedAsciiMarshaller extends Metadata.TrustedAsciiMarshaller { } public static Metadata.Key keyOf(String str, TrustedAsciiMarshaller trustedAsciiMarshaller) { boolean z = false; if (str != null && !str.isEmpty() && str.charAt(0) == ':') { z = true; } return Metadata.Key.of(str, z, trustedAsciiMarshaller); } public static Metadata.Key keyOf(String str, Metadata.AsciiMarshaller asciiMarshaller) { boolean z = false; if (str != null && !str.isEmpty() && str.charAt(0) == ':') { z = true; } return Metadata.Key.of(str, z, asciiMarshaller); } public static Metadata newMetadata(byte[]... bArr) { return new Metadata(bArr); } public static Metadata newMetadata(int i, byte[]... bArr) { return new Metadata(i, bArr); } public static byte[][] serialize(Metadata metadata) { return metadata.serialize(); } public static int headerCount(Metadata metadata) { return metadata.headerCount(); } public static Object[] serializePartial(Metadata metadata) { return metadata.serializePartial(); } public static Object parsedValue(Metadata.BinaryStreamMarshaller binaryStreamMarshaller, T t) { return new Metadata.LazyValue(binaryStreamMarshaller, t); } public static Metadata newMetadataWithParsedValues(int i, Object[] objArr) { return new Metadata(i, objArr); } }