/* Network-Integrated Multimedia Middleware (NMM)
 * http://www.motama.com/nmm.html
 *  
 * Copyright (C) 2006-2007
 * Motama GmbH, Saarbruecken, Germany
 * http://www.motama.com
 *  
 * This file is part of NMM. 
 * 
 * NMM is free software; you can redistribute it and/or modify it    
 * under the terms of the GNU General Public License as published by 
 * the Free Software Foundation; only version 2 of the License.      
 * 
 * NMM is distributed in the hope that it will be useful, but WITHOUT 
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 
 * License for more details.  
 * 
 * You should have received a copy of the GNU General Public License 
 * along with NMM; if not, write to the Free Software Foundation,    
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 */

#ifndef SERIALIZE_UTILS_TIME_HPP
#define SERIALIZE_UTILS_TIME_HPP SERIALIZE_UTILS_TIME_HPP

#include "nmm/nmm_prefix.hpp"

#include "visibility.hpp"

namespace NMM {

  class Time;
  class Interval;
  class Rational;
  class UserTime;

  class IValueStream;
  class OValueStream;

  /** Output serialization operator for Time.
   * This method writes a Time object to an output value stream.
   *
   * @param ov An output value stream
   * @param value Reference to serialized variable
   * @return ov
   */
  DLLEXPORT OValueStream& operator<<(OValueStream& ov, const Time& value);

  /** Input serialization operator for Time.
   * This method reads a Time object from an input value stream.
   *
   * @param iv An input value stream
   * @param value Reference to serialized variable
   * @return iv
   */
  DLLEXPORT IValueStream& operator>>(IValueStream& iv, Time& value);


  /** Output serialization operator for Interval.
   * This method writes a Interval object to an output value stream.
   *
   * @param ov An output value stream
   * @param value Reference to serialized variable
   * @return ov
   */
  DLLEXPORT OValueStream& operator<<(OValueStream& ov, const Interval& value);

  /** Input serialization operator for Interval.
   * This method reads a Interval object from an input value stream.
   *
   * @param iv An input value stream
   * @param value Reference to serialized variable
   * @return iv
   */
  DLLEXPORT IValueStream& operator>>(IValueStream& iv, Interval& value);

  /** Output serialization operator for Rational.
   * This method writes a Rational object to an output value stream.
   *
   * @param ov An output value stream
   * @param value Reference to serialized variable
   * @return ov
   */
  DLLEXPORT OValueStream& operator<<(OValueStream& ov, const Rational& value);

  /** Input serialization operator for Rational.
   * This method reads a Rational object from an input value stream.
   *
   * @param iv An input value stream
   * @param value Reference to serialized variable
   * @return iv
   */
  DLLEXPORT IValueStream& operator>>(IValueStream& iv, Rational& value);

  /** Output serialization operator for UserTime.
   * This method writes a UserTime object to an output value stream.
   *
   * @param ov An output value stream
   * @param value Reference to serialized variable
   * @return ov
   */
  DLLEXPORT OValueStream& operator<<(OValueStream& ov, const UserTime& value);

  /** Input serialization operator for UserTime.
   * This method reads a UserTime object from an input value stream.
   *
   * @param iv An input value stream
   * @param value Reference to serialized variable
   * @return iv
   */
  DLLEXPORT IValueStream& operator>>(IValueStream& iv, UserTime& value);

}

#include "nmm/nmm_suffix.hpp"

#endif
