Software and Services, Portable Libraries  2019.Mar.01
A library for managing digital certificates
821.hpp
1 //
2 // BEGIN_DOUGLAS_MARK_ROYER_COPYRIGHT
3 //
4 // Copyright (C) 1993-2014 Douglas Mark Royer, All Rights Reserved.
5 //
6 // NOTICE:
7 //
8 // THIS SOURCE CODE BELONGS TO DOUGLAS MARK ROYER
9 // CORPORATION, A NEVADA CORPORATION. THIS CODE IS PROPERTY
10 // OF THE COPYRIGHT HOLDER AND IS NOT TO BE DIVULGED OR USED BY
11 // PARTIES WHO HAVE NOT RECEIVED WRITTEN AUTHORIZATION FROM THE OWNER.
12 //
13 // THIS SOFTWARE AND MANUAL ARE BOTH PROTECTED BY UNITED STATES
14 // COPYRIGHT LAW (TITLE 17 UNITED STATES CODE). UNAUTHORIZED REPRODUCTION
15 // AND/OR SALE MAY RESULT IN IMPRISONMENT OF UP TO ONE YEAR AND FINES
16 // OF UP TO $100,000 (17 USC 506). COPYRIGHT INFRINGERS MAY ALSO
17 // BE SUBJECT TO CIVIL LIABILITY.
18 //
19 // THIS NOTICE AND THE ABOVE COPYRIGHT NOTICE MUST REMAIN IN ALL
20 // COPIES AND ANY DERIVED WORK.
21 //
22 // ALL OF THIS CODE IS ORIGINAL WORK BY THE COPYRIGHT HOLDER.
23 //
24 // THIS DOCUMENT AND THE INFORMATION CONTAINED HEREIN IS
25 // PROVIDED ON AN "AS IS" BASIS AND INET-CONSULTING.COM, INC.
26 // DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT
27 // NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
28 // HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
29 // WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR
30 // PURPOSE. ANY SERVICE CONTRACT WILL BE UNDER A SEPARATE
31 // LICENSE.
32 //
33 // END_DOUGLAS_MARK_ROYER_COPYRIGHT
34 //
35 
36 #ifndef PROJECT_CONTRACTING_LIBRARY_RFCBASIC_821_HPP
37 #define PROJECT_CONTRACTING_LIBRARY_RFCBASIC_821_HPP
38 
39 #ifndef EXPORT_RFC
40 #ifdef BUILDING_LIBRARY_RFC
41 #define EXPORT_RFC EXPORT_OUT
42 #else
43 #define EXPORT_RFC EXPORT_IN
44 #endif
45 #endif
46 
47 #ifdef WIN32
48 #pragma warning (disable : 4251)
49 #endif
50 
51 #include <SaS/Common/winWrappers.hpp>
52 #ifdef BUILDING_LIBRARY_RFC
53 #include "Uri.hpp"
54 #include "822.hpp"
55 #else
56 #include <SaS/RfcBasic/Uri.hpp>
57 #include <SaS/RfcBasic/822.hpp>
58 #endif
59 #include <SaS/host.hpp>
60 
62 
63 namespace SoftwareAndServices
64 {
65  namespace Library
66  {
67  namespace EXPORT_RFC RfcBasic
68  {
69 
73  enum rfc821_v {
74  RcptTo,
75  MailFrom,
76  Helo,
77  Noop,
78  Quit,
79  Help,
80  Data,
81  Vrfy,
82  Rset,
83  Expn
85  };
86 
92  class EXPORT_RFC rfc821
93  : public Base,
94  private VBase,
95  virtual public instance<rfc821>
96  {
97 
98  public:
99 
103  rfc821();
104 
108  virtual ~rfc821();
109 
114  class connect {
115  public:
116 
127  connect * connectToHost(const char * hostOrIp,
128  const int port = 25);
129 
140  connect * connectToHost(const host * hostOrIp,
141  const int port = 25);
142 
143  private:
144  host * _hostData;
145  int _port;
146  };
147 
153  bool testHost(rfc822Address * address);
154 
160  char * verifytUser(const char * hostOrIp);
161 
162 #ifdef FOO
163 
168  char * expandAddress(rfc822Address * address);
169 
175  char * getHelp();
176 #endif
177 
178  };
179 
180  }
181  }
182 }
183 
184 #endif //PROJECT_CONTRACTING_LIBRARY_RFCBASIC_821_HPP
A portable I/O library for reading and writing binary data.
Definition: Base.hpp:125
Just about everything you need to do with an email connections.
Definition: 821.hpp:92
Instance counting and tracking.
Definition: instance.hpp:90
Copyright Douglas Mark Royer DouglasRoyer@gmail.com.
Definition: Base.hpp:98
A connection to another host object.
Definition: 821.hpp:114
A pure virtual Base class for reading and writing object.
Definition: VBase.hpp:81