Interface MarshalListener


  • public interface MarshalListener
    An interface to allow external "listening" to objects when they are being marshalled for various tracking purposes and potential modification, and to prevent an object from being marshalled if necessary. An implementation of this interface may be registered with the Marshaller.
    Version:
    $Revision: 8653 $ $Date: 2003-03-03 00:05:44 -0700 (Mon, 03 Mar 2003) $
    Author:
    Keith Visco, Jeff Norris
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void postMarshal​(java.lang.Object object)
      This method is called after an object has been marshalled.
      boolean preMarshal​(java.lang.Object object)
      This method is called before an object is to be marshalled.
    • Method Detail

      • preMarshal

        boolean preMarshal​(java.lang.Object object)
        This method is called before an object is to be marshalled. In case of unchecked exceptions being thrown, those will be caught and logged, but the marshalling process will not be interrupted.
        Parameters:
        object - the Object about to be marshalled.
        Returns:
        false if the object should not be marshalled.
      • postMarshal

        void postMarshal​(java.lang.Object object)
        This method is called after an object has been marshalled. If #preMarshal returned false for a given Object, this method will not be called for that Object as marshalling will not take place. In case of unchecked exceptions being thrown, those will be caught and logged, but the marshalling process will not be interrupted.
        Parameters:
        object - the Object that was marshalled.