open-dis-cpp
RepairResponsePdu.h
1 #pragma once
2 
3 #include <dis6/EntityID.h>
4 #include <dis6/EntityID.h>
5 #include <dis6/LogisticsFamilyPdu.h>
6 #include <dis6/utils/DataStream.h>
7 #include <dis6/opendis6_export.h>
8 
9 
10 namespace DIS
11 {
12 // Section 5.2.5.6. Sent after repair complete PDU. COMPLETE
13 
14 // Copyright (c) 2007-2009, MOVES Institute, Naval Postgraduate School. All rights reserved.
15 //
16 // @author DMcG, jkg
17 
18 class OPENDIS6_EXPORT RepairResponsePdu : public LogisticsFamilyPdu
19 {
20 protected:
23 
26 
28  unsigned char _repairResult;
29 
31  short _padding1;
32 
34  char _padding2;
35 
36 
37  public:
39  virtual ~RepairResponsePdu();
40 
41  virtual void marshal(DataStream& dataStream) const;
42  virtual void unmarshal(DataStream& dataStream);
43 
44  EntityID& getReceivingEntityID();
45  const EntityID& getReceivingEntityID() const;
46  void setReceivingEntityID(const EntityID &pX);
47 
48  EntityID& getRepairingEntityID();
49  const EntityID& getRepairingEntityID() const;
50  void setRepairingEntityID(const EntityID &pX);
51 
52  unsigned char getRepairResult() const;
53  void setRepairResult(unsigned char pX);
54 
55  short getPadding1() const;
56  void setPadding1(short pX);
57 
58  char getPadding2() const;
59  void setPadding2(char pX);
60 
61 
62 virtual int getMarshalledSize() const;
63 
64  bool operator ==(const RepairResponsePdu& rhs) const;
65 };
66 }
67 
68 // Copyright (c) 1995-2009 held by the author(s). All rights reserved.
69 // Redistribution and use in source and binary forms, with or without
70 // modification, are permitted provided that the following conditions
71 // are met:
72 //
73 // * Redistributions of source code must retain the above copyright
74 // notice, this list of conditions and the following disclaimer.
75 // * Redistributions in binary form must reproduce the above copyright
76 // notice, this list of conditions and the following disclaimer
77 // in the documentation and/or other materials provided with the
78 // distribution.
79 // * Neither the names of the Naval Postgraduate School (NPS)
80 // Modeling Virtual Environments and Simulation (MOVES) Institute
81 // (http://www.nps.edu and http://www.MovesInstitute.org)
82 // nor the names of its contributors may be used to endorse or
83 // promote products derived from this software without specific
84 // prior written permission.
85 //
86 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
87 // AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
88 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
89 // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
90 // COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
91 // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
92 // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
93 // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
94 // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
95 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
96 // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
97 // POSSIBILITY OF SUCH DAMAGE.
short _padding1
padding
Definition: RepairResponsePdu.h:31
Symbolic names as defined in 5.1.4.
Definition: AcknowledgePdu.h:8
unsigned char _repairResult
Result of repair operation.
Definition: RepairResponsePdu.h:28
a class to support managing a network buffer.
Definition: DataStream.h:28
Definition: LogisticsFamilyPdu.h:16
Definition: RepairResponsePdu.h:18
Definition: EntityID.h:15
EntityID _repairingEntityID
Entity that is supplying.
Definition: RepairResponsePdu.h:25
EntityID _receivingEntityID
Entity that is receiving service.
Definition: RepairResponsePdu.h:22
char _padding2
padding
Definition: RepairResponsePdu.h:34