OPAL  Version 3.18.8
x224.h
Go to the documentation of this file.
1 /*
2  * x224.h
3  *
4  * X.224 protocol handler
5  *
6  * Open H323 Library
7  *
8  * Copyright (c) 1998-2001 Equivalence Pty. Ltd.
9  *
10  * The contents of this file are subject to the Mozilla Public License
11  * Version 1.0 (the "License"); you may not use this file except in
12  * compliance with the License. You may obtain a copy of the License at
13  * http://www.mozilla.org/MPL/
14  *
15  * Software distributed under the License is distributed on an "AS IS"
16  * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
17  * the License for the specific language governing rights and limitations
18  * under the License.
19  *
20  * The Original Code is Open H323 Library.
21  *
22  * The Initial Developer of the Original Code is Equivalence Pty. Ltd.
23  *
24  * Contributor(s): ______________________________________.
25  *
26  */
27 
28 #ifndef OPAL_T120_X224_H
29 #define OPAL_T120_X224_H
30 
31 #ifdef P_USE_PRAGMA
32 #pragma interface
33 #endif
34 
35 #include <opal_config.h>
36 
37 #include <ptlib/sockets.h>
38 
39 
40 
42 
45 class X224 : public PObject
46 {
47  PCLASSINFO(X224, PObject)
48 
49  public:
50  enum Codes {
53  DataPDU = 0xf0
54  };
55 
56  X224();
57 
58  void BuildConnectRequest();
59  void BuildConnectConfirm();
60  void BuildData(const PBYTEArray & data);
61 
62  void PrintOn(ostream & strm) const;
63  PBoolean Decode(const PBYTEArray & rawData);
64  PBoolean Encode(PBYTEArray & rawData) const;
65 
66  int GetCode() const { return header[0]; }
67  const PBYTEArray & GetData() const { return data; }
68 
69  private:
70  PBYTEArray header;
71  PBYTEArray data;
72 };
73 
74 
75 #endif // OPAL_T120_X224_H
76 
77 
void BuildConnectRequest()
const PBYTEArray & GetData() const
Definition: x224.h:67
PBoolean Encode(PBYTEArray &rawData) const
Definition: x224.h:51
Codes
Definition: x224.h:50
void BuildConnectConfirm()
Definition: x224.h:52
void BuildData(const PBYTEArray &data)
void PrintOn(ostream &strm) const
PBoolean Decode(const PBYTEArray &rawData)
Definition: x224.h:45
int GetCode() const
Definition: x224.h:66
Definition: x224.h:53