Use events to communicate changes to insertion delay configuration.
[Sone.git] / src / main / java / net / pterodactylus / sone / core / event / InsertionDelayChangedEvent.java
diff --git a/src/main/java/net/pterodactylus/sone/core/event/InsertionDelayChangedEvent.java b/src/main/java/net/pterodactylus/sone/core/event/InsertionDelayChangedEvent.java
new file mode 100644 (file)
index 0000000..a3dc2ce
--- /dev/null
@@ -0,0 +1,23 @@
+package net.pterodactylus.sone.core.event;
+
+import com.google.common.eventbus.EventBus;
+
+/**
+ * Notifies interested {@link EventBus} clients that the Sone insertion delay
+ * has changed.
+ *
+ * @author <a href="mailto:bombe@pterodactylus.net">David ‘Bombe’ Roden</a>
+ */
+public class InsertionDelayChangedEvent {
+
+       private final int insertionDelay;
+
+       public InsertionDelayChangedEvent(int insertionDelay) {
+               this.insertionDelay = insertionDelay;
+       }
+
+       public int getInsertionDelay() {
+               return insertionDelay;
+       }
+
+}