Class InferenceToXContentCompressor
java.lang.Object
org.elasticsearch.client.ml.inference.InferenceToXContentCompressor
Collection of helper methods. Similar to CompressedXContent, but this utilizes GZIP.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends org.elasticsearch.xcontent.ToXContentObject>
Stringdeflate
(T objectToCompress) static <T> T
inflate
(String compressedString, org.elasticsearch.core.CheckedFunction<org.elasticsearch.xcontent.XContentParser, T, IOException> parserFunction, org.elasticsearch.xcontent.NamedXContentRegistry xContentRegistry)
-
Method Details
-
deflate
public static <T extends org.elasticsearch.xcontent.ToXContentObject> String deflate(T objectToCompress) throws IOException - Throws:
IOException
-
inflate
public static <T> T inflate(String compressedString, org.elasticsearch.core.CheckedFunction<org.elasticsearch.xcontent.XContentParser, T, throws IOExceptionIOException> parserFunction, org.elasticsearch.xcontent.NamedXContentRegistry xContentRegistry) - Throws:
IOException
-