Package edu.wpi.grip.core.serialization
Class SocketConverter
- java.lang.Object
-
- edu.wpi.grip.core.serialization.SocketConverter
-
- All Implemented Interfaces:
com.thoughtworks.xstream.converters.Converter,com.thoughtworks.xstream.converters.ConverterMatcher
public class SocketConverter extends java.lang.Object implements com.thoughtworks.xstream.converters.ConverterAn XStream converter for serializing and deserializing sockets. Socket elements include indexes to indicate where in the pipeline they are. Input sockets can include values if specified, and output sockets can include boolean attributes indicating if they are previewed. Deserializing a socket doesn't create the socket itself - this is done when the step is created. Instead, this converter is used to reference particular sockets when defining values, previewed flags, and connections.
-
-
Constructor Summary
Constructors Constructor Description SocketConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancanConvert(java.lang.Class type)voidmarshal(java.lang.Object obj, com.thoughtworks.xstream.io.HierarchicalStreamWriter writer, com.thoughtworks.xstream.converters.MarshallingContext context)java.lang.Objectunmarshal(com.thoughtworks.xstream.io.HierarchicalStreamReader reader, com.thoughtworks.xstream.converters.UnmarshallingContext context)
-
-
-
Method Detail
-
marshal
public void marshal(java.lang.Object obj, com.thoughtworks.xstream.io.HierarchicalStreamWriter writer, com.thoughtworks.xstream.converters.MarshallingContext context)- Specified by:
marshalin interfacecom.thoughtworks.xstream.converters.Converter
-
unmarshal
public java.lang.Object unmarshal(com.thoughtworks.xstream.io.HierarchicalStreamReader reader, com.thoughtworks.xstream.converters.UnmarshallingContext context)- Specified by:
unmarshalin interfacecom.thoughtworks.xstream.converters.Converter
-
canConvert
public boolean canConvert(java.lang.Class type)
- Specified by:
canConvertin interfacecom.thoughtworks.xstream.converters.ConverterMatcher
-
-