KDIS  2-8-x
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Repair_Complete_PDU.h
Go to the documentation of this file.
1 /*********************************************************************
2 Copyright 2013 Karl Jones
3 All rights reserved.
4 
5 Redistribution and use in source and binary forms, with or without
6 modification, are permitted provided that the following conditions are met:
7 
8 1. Redistributions of source code must retain the above copyright notice, this
9  list of conditions and the following disclaimer.
10 2. Redistributions in binary form must reproduce the above copyright notice,
11  this list of conditions and the following disclaimer in the documentation
12  and/or other materials provided with the distribution.
13 
14 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
15 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
16 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
17 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
18 ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
19 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
20 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
21 ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
23 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24 
25 For Further Information Please Contact me at
26 Karljj1@yahoo.com
27 http://p.sf.net/kdis/UserGuide
28 *********************************************************************/
29 
30 /********************************************************************
31  class: Repair_Complete_PDU
32  DIS: (5) 1278.1 - 1995
33  created: 2008/09/22
34  author: Karl Jones
35 
36  purpose: Repair Complete PDU
37  Size: 224 bits / 28 octets
38 *********************************************************************/
39 
40 #pragma once
41 
42 #include "./Logistics_Header.h"
43 
44 namespace KDIS {
45 namespace PDU {
46 
48 {
49 protected:
50 
52 
54 
55 public:
56 
57  static const KUINT16 REPAIR_COMPLETE_PDU_SIZE = 28;
58 
60 
61  Repair_Complete_PDU( KDataStream & stream ) throw( KException );
62 
63  Repair_Complete_PDU( const Header & H, KDataStream & stream ) throw( KException );
64 
65  Repair_Complete_PDU( const KDIS::DATA_TYPE::EntityIdentifier & ReceivingEntityID, const KDIS::DATA_TYPE::EntityIdentifier & SupplyingEntityID,
67 
68  virtual ~Repair_Complete_PDU();
69 
70  //************************************
71  // FullName: KDIS::PDU::Repair_Complete_PDU::SetRepairTypePerformed
72  // KDIS::PDU::Repair_Complete_PDU::GetRepairTypePerformed
73  //!Description: Enumeration to describe the type of repair provided
74  // Parameter: RepairTypePerformed RTP, void
75  //************************************
76  void SetRepairTypePerformed( KDIS::DATA_TYPE::ENUMS::RepairTypePerformed RTP );
77  KDIS::DATA_TYPE::ENUMS::RepairTypePerformed GetRepairTypePerformed() const;
78 
79  //************************************
80  // FullName: KDIS::PDU::Repair_Complete_PDU::GetAsString
81  //!Description: Returns a string representation of the PDU.
82  //************************************
83  virtual KString GetAsString() const;
84 
85  //************************************
86  // FullName: KDIS::PDU::Repair_Complete_PDU::Decode
87  //!Description: Convert From Network Data.
88  // Parameter: KDataStream & stream
89  // Parameter: bool ignoreHeader = false - Decode the header from the stream?
90  //************************************
91  virtual void Decode( KDataStream & stream, bool ignoreHeader = false ) throw( KException );
92 
93  //************************************
94  // FullName: KDIS::PDU::Repair_Complete_PDU::Encode
95  //!Description: Convert To Network Data.
96  // Parameter: KDataStream & stream
97  //************************************
98  virtual KDataStream Encode() const;
99  virtual void Encode( KDataStream & stream ) const;
100 
101  KBOOL operator == ( const Repair_Complete_PDU & Value ) const;
102  KBOOL operator != ( const Repair_Complete_PDU & Value ) const;
103 };
104 
105 } // END namespace PDU
106 } // END namespace KDIS
KUINT16 m_ui16Repair
Definition: Repair_Complete_PDU.h:51
unsigned short int KUINT16
Definition: KDefines.h:101
KUINT16 m_ui16Padding
Definition: Repair_Complete_PDU.h:53
Definition: KDefines.h:182
Definition: KDataStream.h:48
bool KBOOL
Definition: KDefines.h:119
std::string KString
Definition: KDefines.h:116
Definition: EntityIdentifier.h:49
Definition: Header7.h:142
Definition: Logistics_Header.h:48
#define KDIS_EXPORT
Definition: KDefines.h:82
Definition: Repair_Complete_PDU.h:47
RepairTypePerformed
Definition: EnumSupply.h:70