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

FIFO_Recv.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 //==========================================================================
00004 /**
00005  *  @file    FIFO_Recv.h
00006  *
00007  *  $Id: FIFO_Recv.h,v 1.1.1.4 2003/02/21 18:36:32 chad Exp $
00008  *
00009  *  @author Doug Schmidt
00010  */
00011 //==========================================================================
00012 
00013 
00014 #ifndef ACE_FIFO_RECV_H
00015 #define ACE_FIFO_RECV_H
00016 
00017 #include "ace/pre.h"
00018 
00019 #include "ace/FIFO.h"
00020 
00021 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00022 # pragma once
00023 #endif /* ACE_LACKS_PRAGMA_ONCE */
00024 
00025 #include "ace/ACE.h"
00026 
00027 /**
00028  * @class ACE_FIFO_Recv
00029  *
00030  * @brief Receiver side of the bytestream C++ wrapper for UNIX
00031  * FIFOs.
00032  */
00033 class ACE_Export ACE_FIFO_Recv : public ACE_FIFO
00034 {
00035 public:
00036   // = Initialization methods.
00037   /// Default constructor.
00038   ACE_FIFO_Recv (void);
00039 
00040   /// Open up a bytestream named pipe for reading.
00041   ACE_FIFO_Recv (const ACE_TCHAR *rendezvous,
00042                  int flags = O_CREAT | O_RDONLY,
00043                  int perms = ACE_DEFAULT_FILE_PERMS,
00044                  int persistent = 1,
00045                  LPSECURITY_ATTRIBUTES sa = 0);
00046 
00047   /// Open up a bytestream named pipe for reading.
00048   int open (const ACE_TCHAR *rendezvous,
00049             int flags = O_CREAT | O_RDONLY,
00050             int perms = ACE_DEFAULT_FILE_PERMS,
00051             int persistent = 1,
00052             LPSECURITY_ATTRIBUTES sa = 0);
00053 
00054   /// Close down the named pipe.
00055   int close (void);
00056 
00057   /// Recv <buf> of up to <len> bytes.
00058   ssize_t recv (void *buf, size_t len);
00059 
00060   /// Recv <buf> of exactly <len> bytes (block until done).
00061   ssize_t recv_n (void *buf, size_t len);
00062 
00063   /// Dump the state of an object.
00064   void dump (void) const;
00065 
00066   /// Declare the dynamic allocation hooks.
00067   ACE_ALLOC_HOOK_DECLARE;
00068 
00069 private:
00070   /// Auxiliary handle that is used to implement persistent FIFOs.
00071   ACE_HANDLE aux_handle_;
00072 };
00073 
00074 #if !defined (ACE_LACKS_INLINE_FUNCTIONS)
00075 #include "ace/FIFO_Recv.i"
00076 #endif
00077 
00078 #include "ace/post.h"
00079 
00080 #endif /* ACE_FIFO_RECV_H */

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