@Override
  public StreamingAead getPrimitive(ByteString serializedKey) throws GeneralSecurityException {
    try {
      AesGcmHkdfStreamingKey keyProto =
          AesGcmHkdfStreamingKey.parseFrom(serializedKey, ExtensionRegistryLite.getEmptyRegistry());
      validateKey(keyProto);
      String hkdfAlgo;
      switch (keyProto.getParams().getHkdfHashType()) {
        case SHA1:
          hkdfAlgo = "HmacSha1";
          break;
        case SHA224:
          hkdfAlgo = "HmacSha224";
          break;
        case SHA256:
          hkdfAlgo = "HmacSha256";
          break;
        case SHA384:
          hkdfAlgo = "HmacSha384";
          break;
        case SHA512:
          hkdfAlgo = "HmacSha512";
          break;
        default:
          throw new GeneralSecurityException(
              "hash unsupported for HKDF/HMAC: " + keyProto.getParams().getHkdfHashType());
      }
      return new AesGcmHkdfStreaming(
          keyProto.getKeyValue().toByteArray(),
          hkdfAlgo,
          keyProto.getParams().getDerivedKeySize(),
          keyProto.getParams().getCiphertextSegmentSize(),
          /* firstSegmentOffset= */ 0);
    } catch (InvalidProtocolBufferException e) {
      throw new GeneralSecurityException("Expected serialized AesGcmHkdfStreamingKey proto", e);
    }
  }
Type url that this manager does support.
java_src/src/main/java/com/google/crypto/tink/streamingaead/internal/LegacyAesGcmHkdfStreamingTestKeyManager.java