private String shrinkedToString() {
        int s = 0;
        // handle Collection and Map
        if (this.t instanceof Collection) {
            final Collection c = (Collection)t;
            s = c.size();
        } else if (this.t instanceof Map) {
            final Map m = (Map)t;
            s = m.size();
        }
        if (s > 0) {
            final StringBuilder sb = new StringBuilder();
            sb.append(this.t.getClass().toString()).append("@size=").append(s);
            return sb.toString();
        }
        // fallback
        return Objects.toString(this.t);
    }
Shrink the content to display for both Collection and Map
@return
hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/structure/io/ObjectWritable.java