@Override
        public <O extends OutputShim> void write(final KryoShim<?, O> kryo, final O output, final Vertex vertex) {
            kryo.writeClassAndObject(output, vertex.id());
            output.writeString(vertex.label());

            final Iterator<? extends VertexProperty> properties = vertex.properties();
            output.writeBoolean(properties.hasNext());
            while (properties.hasNext()) {
                final VertexProperty vp = properties.next();
                kryo.writeClassAndObject(output, vp.id());
                output.writeString(vp.label());
                kryo.writeClassAndObject(output, vp.value());

                if (vp instanceof DetachedVertexProperty || (vertex.graph().features().vertex().supportsMetaProperties())) {
                    writeElementProperties(kryo, output, vp);
                } else {
                    output.writeBoolean(false);
                }

                output.writeBoolean(properties.hasNext());
            }
        }
Serializes any {@link Vertex} implementation encountered to an {@link DetachedVertex}.
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/structure/io/gryo/GryoSerializersV3.java