open-dis-cpp
LinearSegmentParameter.h
1 #pragma once
2 
3 #include <dis6/SixByteChunk.h>
4 #include <dis6/Vector3Double.h>
5 #include <dis6/Orientation.h>
6 #include <dis6/utils/DataStream.h>
7 #include <dis6/opendis6_export.h>
8 
9 
10 namespace DIS
11 {
12 // 5.2.48: Linear segment parameters
13 
14 // Copyright (c) 2007-2009, MOVES Institute, Naval Postgraduate School. All rights reserved.
15 //
16 // @author DMcG, jkg
17 
18 class OPENDIS6_EXPORT LinearSegmentParameter
19 {
20 protected:
22  unsigned char _segmentNumber;
23 
26 
29 
32 
34  unsigned short _segmentLength;
35 
37  unsigned short _segmentWidth;
38 
40  unsigned short _segmentHeight;
41 
43  unsigned short _segmentDepth;
44 
46  unsigned int _pad1;
47 
48 
49  public:
51  virtual ~LinearSegmentParameter();
52 
53  virtual void marshal(DataStream& dataStream) const;
54  virtual void unmarshal(DataStream& dataStream);
55 
56  unsigned char getSegmentNumber() const;
57  void setSegmentNumber(unsigned char pX);
58 
59  SixByteChunk& getSegmentAppearance();
60  const SixByteChunk& getSegmentAppearance() const;
61  void setSegmentAppearance(const SixByteChunk &pX);
62 
63  Vector3Double& getLocation();
64  const Vector3Double& getLocation() const;
65  void setLocation(const Vector3Double &pX);
66 
67  Orientation& getOrientation();
68  const Orientation& getOrientation() const;
69  void setOrientation(const Orientation &pX);
70 
71  unsigned short getSegmentLength() const;
72  void setSegmentLength(unsigned short pX);
73 
74  unsigned short getSegmentWidth() const;
75  void setSegmentWidth(unsigned short pX);
76 
77  unsigned short getSegmentHeight() const;
78  void setSegmentHeight(unsigned short pX);
79 
80  unsigned short getSegmentDepth() const;
81  void setSegmentDepth(unsigned short pX);
82 
83  unsigned int getPad1() const;
84  void setPad1(unsigned int pX);
85 
86 
87 virtual int getMarshalledSize() const;
88 
89  bool operator ==(const LinearSegmentParameter& rhs) const;
90 };
91 }
92 
93 // Copyright (c) 1995-2009 held by the author(s). All rights reserved.
94 // Redistribution and use in source and binary forms, with or without
95 // modification, are permitted provided that the following conditions
96 // are met:
97 //
98 // * Redistributions of source code must retain the above copyright
99 // notice, this list of conditions and the following disclaimer.
100 // * Redistributions in binary form must reproduce the above copyright
101 // notice, this list of conditions and the following disclaimer
102 // in the documentation and/or other materials provided with the
103 // distribution.
104 // * Neither the names of the Naval Postgraduate School (NPS)
105 // Modeling Virtual Environments and Simulation (MOVES) Institute
106 // (http://www.nps.edu and http://www.MovesInstitute.org)
107 // nor the names of its contributors may be used to endorse or
108 // promote products derived from this software without specific
109 // prior written permission.
110 //
111 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
112 // AS IS AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
113 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
114 // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
115 // COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
116 // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
117 // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
118 // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
119 // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
120 // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
121 // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
122 // POSSIBILITY OF SUCH DAMAGE.
unsigned short _segmentLength
segmentLength
Definition: LinearSegmentParameter.h:34
Symbolic names as defined in 5.1.4.
Definition: AcknowledgePdu.h:8
a class to support managing a network buffer.
Definition: DataStream.h:28
unsigned int _pad1
segment Depth
Definition: LinearSegmentParameter.h:46
unsigned short _segmentHeight
segmentHeight
Definition: LinearSegmentParameter.h:40
Definition: Vector3Double.h:15
Definition: Orientation.h:15
unsigned char _segmentNumber
number of segments
Definition: LinearSegmentParameter.h:22
Definition: LinearSegmentParameter.h:18
SixByteChunk _segmentAppearance
segment appearance
Definition: LinearSegmentParameter.h:25
Vector3Double _location
location
Definition: LinearSegmentParameter.h:28
unsigned short _segmentWidth
segmentWidth
Definition: LinearSegmentParameter.h:37
unsigned short _segmentDepth
segment Depth
Definition: LinearSegmentParameter.h:43
Orientation _orientation
orientation
Definition: LinearSegmentParameter.h:31
Definition: SixByteChunk.h:15