Skip to content

Commit 36b12f5

Browse files
committed
ClockEvent: remove @Customize
1 parent e1df857 commit 36b12f5

2 files changed

Lines changed: 12 additions & 35 deletions

File tree

src/inet/clock/common/ClockEvent.h

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -4,38 +4,4 @@
44
// SPDX-License-Identifier: LGPL-3.0-or-later
55
//
66

7-
8-
#ifndef __INET_COMMON_CLOCKEVENT_H
9-
#define __INET_COMMON_CLOCKEVENT_H
10-
117
#include "inet/clock/common/ClockEvent_m.h"
12-
13-
namespace inet {
14-
15-
class ClockBase;
16-
17-
class INET_API ClockEvent : public ClockEvent_Base
18-
{
19-
friend ClockBase;
20-
21-
protected:
22-
virtual void execute() override;
23-
24-
void callBaseExecute() { ClockEvent_Base::execute(); }
25-
26-
public:
27-
ClockEvent(const char *name = nullptr, short kind = 0) : ClockEvent_Base(name, kind) {}
28-
ClockEvent(const ClockEvent& other) : ClockEvent_Base(other) {}
29-
30-
ClockEvent& operator=(const ClockEvent& other) {
31-
if (this == &other) return *this;
32-
ClockEvent_Base::operator=(other);
33-
return *this;
34-
}
35-
virtual ClockEvent *dup() const override { return new ClockEvent(*this); }
36-
};
37-
38-
} // namespace inet
39-
40-
#endif
41-

src/inet/clock/common/ClockEvent.msg

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ import inet.clock.contract.IClock;
1010

1111
namespace inet;
1212

13+
cplusplus {{
14+
class ClockBase;
15+
}}
16+
1317
enum OverdueClockEventHandlingMode {
1418
UNSPECIFIED = -1;
1519
EXECUTE = 0;
@@ -19,9 +23,16 @@ enum OverdueClockEventHandlingMode {
1923

2024
message ClockEvent
2125
{
22-
@customize;
2326
IClock *clock;
2427
bool relative = false;
2528
clocktime_t arrivalClockTime = -1;
2629
OverdueClockEventHandlingMode overdueClockEventHandlingMode = UNSPECIFIED;
2730
}
31+
32+
cplusplus(ClockEvent) {{
33+
friend ClockBase;
34+
35+
protected:
36+
virtual void execute() override;
37+
void callBaseExecute() { cMessage::execute(); }
38+
}}

0 commit comments

Comments
 (0)