00001 // -*- C++ -*- 00002 // 00003 // $Id: FTP_Request.inl 90891 2010-06-28 09:55:39Z mcorino $ 00004 00005 ACE_BEGIN_VERSIONED_NAMESPACE_DECL 00006 00007 namespace ACE 00008 { 00009 namespace FTP 00010 { 00011 00012 ACE_INLINE 00013 void Request::reset () 00014 { 00015 this->command_.clear (); 00016 this->args_.clear (); 00017 } 00018 00019 ACE_INLINE 00020 Request& Request::operator ()(const ACE_CString& cmd) 00021 { 00022 this->reset (); 00023 this->command (cmd); 00024 return *this; 00025 } 00026 00027 ACE_INLINE 00028 void Request::command (const ACE_CString& cmd) 00029 { 00030 this->command_ = cmd; 00031 } 00032 00033 ACE_INLINE 00034 const ACE_CString& Request::command () const 00035 { 00036 return this->command_; 00037 } 00038 00039 ACE_INLINE 00040 Request& Request::operator <<(const ACE_CString& arg) 00041 { 00042 if (!arg.empty ()) 00043 { 00044 if (!this->args_.empty ()) this->args_ += ' ' ; 00045 this->args_ += arg; 00046 } 00047 return *this; 00048 } 00049 00050 ACE_INLINE 00051 const ACE_CString& Request::arguments () const 00052 { 00053 return this->args_; 00054 } 00055 } 00056 } 00057 00058 ACE_END_VERSIONED_NAMESPACE_DECL