Coverage Report

Created: 2025-10-12 06:40

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/opendnp3/cpp/lib/src/gen/objects/Group11.cpp
Line
Count
Source
1
//
2
//  _   _         ______    _ _ _   _             _ _ _
3
// | \ | |       |  ____|  | (_) | (_)           | | | |
4
// |  \| | ___   | |__   __| |_| |_ _ _ __   __ _| | | |
5
// | . ` |/ _ \  |  __| / _` | | __| | '_ \ / _` | | | |
6
// | |\  | (_) | | |___| (_| | | |_| | | | | (_| |_|_|_|
7
// |_| \_|\___/  |______\__,_|_|\__|_|_| |_|\__, (_|_|_)
8
//                                           __/ |
9
//                                          |___/
10
// 
11
// This file is auto-generated. Do not edit manually
12
// 
13
// Copyright 2013-2022 Step Function I/O, LLC
14
// 
15
// Licensed to Green Energy Corp (www.greenenergycorp.com) and Step Function I/O
16
// LLC (https://stepfunc.io) under one or more contributor license agreements.
17
// See the NOTICE file distributed with this work for additional information
18
// regarding copyright ownership. Green Energy Corp and Step Function I/O LLC license
19
// this file to you under the Apache License, Version 2.0 (the "License"); you
20
// may not use this file except in compliance with the License. You may obtain
21
// a copy of the License at:
22
// 
23
//   http://www.apache.org/licenses/LICENSE-2.0
24
// 
25
// Unless required by applicable law or agreed to in writing, software
26
// distributed under the License is distributed on an "AS IS" BASIS,
27
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
28
// See the License for the specific language governing permissions and
29
// limitations under the License.
30
//
31
32
#include "Group11.h"
33
34
#include "app/parsing/DNPTimeParsing.h"
35
#include <ser4cpp/serialization/LittleEndian.h>
36
#include "app/MeasurementFactory.h"
37
#include "app/WriteConversions.h"
38
39
using namespace ser4cpp;
40
41
namespace opendnp3 {
42
43
// ------- Group11Var1 -------
44
45
2.77k
Group11Var1::Group11Var1() : flags(0)
46
2.77k
{}
47
48
bool Group11Var1::Read(rseq_t& buffer, Group11Var1& output)
49
2.77k
{
50
2.77k
  return LittleEndian::read(buffer, output.flags);
51
2.77k
}
52
53
bool Group11Var1::Write(const Group11Var1& arg, ser4cpp::wseq_t& buffer)
54
0
{
55
0
  return LittleEndian::write(buffer, arg.flags);
56
0
}
57
58
bool Group11Var1::ReadTarget(rseq_t& buff, BinaryOutputStatus& output)
59
2.77k
{
60
2.77k
  Group11Var1 value;
61
2.77k
  if(Read(buff, value))
62
2.77k
  {
63
2.77k
    output = BinaryOutputStatusFactory::From(value.flags);
64
2.77k
    return true;
65
2.77k
  }
66
0
  else
67
0
  {
68
0
    return false;
69
0
  }
70
2.77k
}
71
72
bool Group11Var1::WriteTarget(const BinaryOutputStatus& value, ser4cpp::wseq_t& buff)
73
0
{
74
0
  return Group11Var1::Write(ConvertGroup11Var1::Apply(value), buff);
75
0
}
76
77
// ------- Group11Var2 -------
78
79
1.56k
Group11Var2::Group11Var2() : flags(0), time(0)
80
1.56k
{}
81
82
bool Group11Var2::Read(rseq_t& buffer, Group11Var2& output)
83
1.56k
{
84
1.56k
  return LittleEndian::read(buffer, output.flags, output.time);
85
1.56k
}
86
87
bool Group11Var2::Write(const Group11Var2& arg, ser4cpp::wseq_t& buffer)
88
0
{
89
0
  return LittleEndian::write(buffer, arg.flags, arg.time);
90
0
}
91
92
bool Group11Var2::ReadTarget(rseq_t& buff, BinaryOutputStatus& output)
93
1.56k
{
94
1.56k
  Group11Var2 value;
95
1.56k
  if(Read(buff, value))
96
1.56k
  {
97
1.56k
    output = BinaryOutputStatusFactory::From(value.flags, value.time);
98
1.56k
    return true;
99
1.56k
  }
100
0
  else
101
0
  {
102
0
    return false;
103
0
  }
104
1.56k
}
105
106
bool Group11Var2::WriteTarget(const BinaryOutputStatus& value, ser4cpp::wseq_t& buff)
107
0
{
108
0
  return Group11Var2::Write(ConvertGroup11Var2::Apply(value), buff);
109
0
}
110
111
112
}