diff options
author | William R. Otte <wotte@dre.vanderbilt.edu> | 2006-04-13 14:47:50 +0000 |
---|---|---|
committer | William R. Otte <wotte@dre.vanderbilt.edu> | 2006-04-13 14:47:50 +0000 |
commit | feb8e89d1f3932917e3068c9c23db15ce55286e4 (patch) | |
tree | 0d62c61c2e4151b7665392d162436ee7d1e6782d /TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h | |
parent | cbe8aa5d5be1d4679ae0c4e30baaea24fbae416c (diff) | |
download | ATCD-feb8e89d1f3932917e3068c9c23db15ce55286e4.tar.gz |
Thu Apr 13 13:43:19 UTC 2006 William R. Otte <wotte@dre.vanderbilt.edu>escher_x_4_9_integration_point
Diffstat (limited to 'TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h')
-rw-r--r-- | TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h b/TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h new file mode 100644 index 00000000000..aaaeab4960c --- /dev/null +++ b/TAO/CIAO/DAnCE/NodeApplicationManager/URL_Parser.h @@ -0,0 +1,68 @@ + +/* -*- C++ -*- */ + +//============================================================================= +/** + * @file URL_Parser.h + * + * $Id$ + * + * Parses a URL into its logical chunks + * + * + * @author Stoyan Paunov + */ +//============================================================================= + + +#ifndef URL_PARSER_H +#define URL_PARSER_H + +#include "ace/Get_Opt.h" +#include "ace/ARGV.h" +#include "ace/Singleton.h" //for ACE_Singleton +#include "ace/Null_Mutex.h" //for ACE_Null_Mutex + +//forward declaration +class URL_Parser; + +typedef ACE_Singleton <URL_Parser, ACE_Null_Mutex> TheURL_Parser; + + +class URL_Parser +{ +public: + + friend class ACE_Singleton <URL_Parser, ACE_Null_Mutex>; + + /// parses commandline arguments + bool parse_args (int argc, ACE_TCHAR *argv[]); + + //return false on failure + bool parseURL (char* url); + + void Error (void); + + /// Hostname to connect to + ACE_TCHAR *hostname_; + + /// Port number to use + u_short port_; + + /// Filename to upload/download + ACE_TCHAR *filename_; + + /// turns on verbosity + int debug_; + + //destructor + ~URL_Parser (void); + +protected: + URL_Parser (void); + // protected constructor, singleton +}; + + + +#endif /* URL_PARSER_H */ |