code: private static S2DotaMatchMetadata.CDOTAMatchMetadataFile metadataForStream(InputStream stream) throws IOException {
          return Packet.parse(S2DotaMatchMetadata.CDOTAMatchMetadataFile.class, ByteString.readFrom(stream));
      }
docs: reads a metadata stream and returns it's contents
  
  @param stream an {@code InputStream}, containing replay data, positioned at the beginning
  @return the {@code CDOTAMatchMetadataFile} protobuf message
  @throws IOException if the given stream is invalid