Class GraphMLIo
- java.lang.Object
- 
- org.apache.tinkerpop.gremlin.structure.io.graphml.GraphMLIo
 
- 
- All Implemented Interfaces:
- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
 
 public final class GraphMLIo extends Object implements Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder> Constructs GraphML IO implementations given aGraphandIoRegistry. Implementers of theGraphinterfaces do not have to register any special serializers to theIoRegistryas GraphML does not support such things.- Author:
- Stephen Mallette (http://stephen.genoprime.com)
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classGraphMLIo.Builder- 
Nested classes/interfaces inherited from interface org.apache.tinkerpop.gremlin.structure.io.IoIo.Exceptions
 
- 
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static Io.Builder<GraphMLIo>build()GraphMLMapper.Buildermapper()Constructs aMapper.Builderwhich is responsible for constructing the abstraction over different serialization methods.GraphMLReader.Builderreader()Creates aGraphReader.ReaderBuilderimplementation .voidreadGraph(String file)Read aGraphfrom file using the default configuration of theIo.reader()and its suppliedIo.mapper().voidwriteGraph(String file)Write aGraphto file using the default configuration of theIo.writer()and its suppliedIo.mapper().GraphMLWriter.Builderwriter()Creates aGraphWriter.WriterBuilderimplementation .
 
- 
- 
- 
Method Detail- 
readerpublic GraphMLReader.Builder reader() Creates aGraphReader.ReaderBuilderimplementation . Implementers should call theIo.mapper()function to feed its result to the builder. In this way, custom class serializers registered to theMapper.BuilderbyGraphimplementations will end up being used for the serialization process.- Specified by:
- readerin interface- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
 
 - 
writerpublic GraphMLWriter.Builder writer() Creates aGraphWriter.WriterBuilderimplementation . Implementers should call theIo.mapper()function to feed its result to the builder. In this way, custom class serializers registered to theMapper.BuilderbyGraphimplementations will end up being used for the serialization process.- Specified by:
- writerin interface- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
 
 - 
mapperpublic GraphMLMapper.Builder mapper() Constructs aMapper.Builderwhich is responsible for constructing the abstraction over different serialization methods. Implementations should set defaults as required, but most importantly need to make the appropriate call toMapper.Builder.addRegistry(IoRegistry)which will provide the builder with any required custom serializers of theGraph.- Specified by:
- mapperin interface- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
 
 - 
writeGraphpublic void writeGraph(String file) throws IOException Write aGraphto file using the default configuration of theIo.writer()and its suppliedIo.mapper().- Specified by:
- writeGraphin interface- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
- Throws:
- IOException
 
 - 
readGraphpublic void readGraph(String file) throws IOException Read aGraphfrom file using the default configuration of theIo.reader()and its suppliedIo.mapper().- Specified by:
- readGraphin interface- Io<GraphMLReader.Builder,GraphMLWriter.Builder,GraphMLMapper.Builder>
- Throws:
- IOException
 
 - 
buildpublic static Io.Builder<GraphMLIo> build() 
 
- 
 
-