Skip to content

Commit

Permalink
Merge pull request #83 from gregv12/develop
Browse files Browse the repository at this point in the history
Release 0.2.8
  • Loading branch information
gregv12 authored May 29, 2024
2 parents 0fc87a1 + 1668a38 commit acfe458
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 9 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<properties>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<fluxtion.version>9.2.15</fluxtion.version>
<fluxtion.version>9.3.13</fluxtion.version>
<logback.version>1.5.0</logback.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<nexus.url>https://oss.sonatype.org</nexus.url>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/*
* Copyright (C) 2024 gregory higgins
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the Server Side Public License, version 1,
Expand Down Expand Up @@ -67,8 +66,8 @@
*
* <pre>
* generation time : Not available
* eventProcessorGenerator version : 9.2.15
* api version : 9.2.15
* eventProcessorGenerator version : 9.3.13
* api version : 9.3.13
* </pre>
*
* Event classes supported:
Expand Down Expand Up @@ -97,11 +96,13 @@
@SuppressWarnings({"unchecked", "rawtypes"})
public class ProcessorTestLoad
implements EventProcessor<ProcessorTestLoad>,
/*--- @ExportService start ---*/
ServiceQuery,
/*--- @ExportService end ---*/
StaticEventProcessor,
InternalEventProcessor,
BatchHandler,
Lifecycle,
ServiceQuery {
Lifecycle {

//Node declarations
private final CallbackDispatcherImpl callbackDispatcher = new CallbackDispatcherImpl();
Expand Down Expand Up @@ -137,12 +138,18 @@ public class ProcessorTestLoad
private boolean isDirty_B_start = false;
private boolean isDirty_B_stop = false;
private boolean isDirty_clock = false;

//Forked declarations

//Filter constants

//unknown event handler
private Consumer unKnownEventHandler = (e) -> {};

public ProcessorTestLoad(Map<Object, Object> contextMap) {
context.replaceMappings(contextMap);
if (context != null) {
context.replaceMappings(contextMap);
}
A_start.setDependents(Arrays.asList(B_start));
A_start.setStartTask(LoadAotCompiledTest::startA);
B_start.setDependents(Arrays.asList());
Expand All @@ -160,8 +167,12 @@ public ProcessorTestLoad(Map<Object, Object> contextMap) {
initialiseAuditor(clock);
initialiseAuditor(eventLogger);
initialiseAuditor(nodeNameLookup);
subscriptionManager.setSubscribingEventProcessor(this);
context.setEventProcessorCallback(this);
if (subscriptionManager != null) {
subscriptionManager.setSubscribingEventProcessor(this);
}
if (context != null) {
context.setEventProcessorCallback(this);
}
}

public ProcessorTestLoad() {
Expand Down Expand Up @@ -306,6 +317,8 @@ public void onEventInternal(Object event) {
} else if (event instanceof com.fluxtion.runtime.time.ClockStrategy.ClockStrategyEvent) {
ClockStrategyEvent typedEvent = (ClockStrategyEvent) event;
handleEvent(typedEvent);
} else {
unKnownEventHandler(event);
}
}

Expand Down Expand Up @@ -1000,4 +1013,13 @@ public String getLastAuditLogRecord() {
return "";
}
}

public void unKnownEventHandler(Object object) {
unKnownEventHandler.accept(object);
}

@Override
public <T> void setUnKnownEventHandler(Consumer<T> consumer) {
unKnownEventHandler = consumer;
}
}

0 comments on commit acfe458

Please sign in to comment.