Class AbstractReflectionConverter

    • Constructor Detail

      • AbstractReflectionConverter

        public AbstractReflectionConverter​(Mapper mapper,
                                           ReflectionProvider reflectionProvider)
    • Method Detail

      • canAccess

        protected boolean canAccess​(java.lang.Class type)
      • marshal

        public void marshal​(java.lang.Object original,
                            HierarchicalStreamWriter writer,
                            MarshallingContext context)
        Description copied from interface: Converter
        Convert an object to textual data.
        Specified by:
        marshal in interface Converter
        Parameters:
        original - The object to be marshalled.
        writer - A stream to write to.
        context - A context that allows nested objects to be processed by XStream.
      • marshallField

        protected void marshallField​(MarshallingContext context,
                                     java.lang.Object newObj,
                                     java.lang.reflect.Field field)
      • unmarshallField

        protected java.lang.Object unmarshallField​(UnmarshallingContext context,
                                                   java.lang.Object result,
                                                   java.lang.Class type,
                                                   java.lang.reflect.Field field)
      • shouldUnmarshalTransientFields

        protected boolean shouldUnmarshalTransientFields()
      • shouldUnmarshalField

        protected boolean shouldUnmarshalField​(java.lang.reflect.Field field)
      • handleUnknownField

        private void handleUnknownField​(java.lang.Class classDefiningField,
                                        java.lang.String fieldName,
                                        java.lang.Class resultType,
                                        java.lang.String originalNodeName)
      • writeValueToImplicitCollection

        private void writeValueToImplicitCollection​(java.lang.Object value,
                                                    java.util.Map implicitCollections,
                                                    java.lang.Object result,
                                                    AbstractReflectionConverter.FieldLocation fieldLocation)
      • flushCache

        public void flushCache()
        Specified by:
        flushCache in interface Caching
      • readResolve

        protected java.lang.Object readResolve()