Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

Swap.h

Go to the documentation of this file.
00001 /* -*- C++ -*- */
00002 /**
00003  *  @file Swap.h
00004  *
00005  *  $Id: Swap.h,v 1.1.1.1 2003/02/21 18:36:32 chad Exp $
00006  *
00007  * @author Carlos O'Ryan <coryan@uci.edu>
00008  */
00009 
00010 #ifndef ACE_SWAP_H
00011 #define ACE_SWAP_H
00012 #include "ace/pre.h"
00013 
00014 #include "ace/config-all.h"
00015 
00016 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00017 # pragma once
00018 #endif /* ACE_LACKS_PRAGMA_ONCE */
00019 
00020 /**
00021  * @class ACE_Swap
00022  *
00023  * @brief Defines a function to swap two variables.
00024  *
00025  */
00026 template<class T> class ACE_Swap
00027 {
00028 public:
00029   /// Swap two variables
00030   static void swap (T &lhs, T &rhs);
00031 };
00032 
00033 #if defined (__ACE_INLINE__)
00034 #include "ace/Swap.inl"
00035 #endif /* __ACE_INLINE__ */
00036 
00037 #if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
00038 #include "ace/Swap.cpp"
00039 #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
00040 
00041 #if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
00042 #pragma implementation ("Swap.cpp")
00043 #endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
00044 
00045 #include "ace/post.h"
00046 #endif /* ACE_FUNCTOR_H */

Generated on Mon Jun 16 11:21:36 2003 for ACE by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002