package org.vertexium;

import org.vertexium.property.StreamingPropertyValue;

import java.io.ByteArrayInputStream;
import java.io.InputStream;

public class StreamingPropertyValueData {
    private final StreamingPropertyValue streamingPropertyValue;
    private final byte[] data;
    private final int size;

    public StreamingPropertyValueData(StreamingPropertyValue streamingPropertyValue, byte[] data, int size) {
        this.streamingPropertyValue = streamingPropertyValue;
        this.data = data;
        this.size = size;
    }

    public StreamingPropertyValue getStreamingPropertyValue() {
        return streamingPropertyValue;
    }

    public byte[] getData() {
        return data;
    }

    public int getSize() {
        return size;
    }

    public InputStream getInputStream() {
        return new ByteArrayInputStream(getData(), 0, getSize());
    }
}

@@ -136,16 +136,58 @@
 tStream;
+%0Aimport java.nio.charset.StandardCharsets;
 %0A%0Apublic
@@ -570,32 +570,321 @@
  = size;%0A    %7D%0A%0A
+    /**%0A     * This property is here to get a reference to the %7B@link StreamingPropertyValue%7D that this data came from and%0A     * should not be read from using methods such as %7B@link StreamingPropertyValue#getInputStream()%7D or%0A     * %7B@link StreamingPropertyValue#readToString()%7D.%0A     */%0A
     public Strea
@@ -1003,24 +1003,24 @@
 getData() %7B%0A
-
         retu
@@ -1027,32 +1027,139 @@
 rn data;%0A    %7D%0A%0A
+    public String getDataAsString() %7B%0A        return new String(getData(), StandardCharsets.UTF_8);%0A    %7D%0A%0A
     public int g

add comment on how you should use StreamingPropertyValueData#getStreamingPropertyValue