From 169f02be66b8ac23fb3db406d62baa001d2038de Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Mon, 13 Dec 2010 20:16:50 +0100 Subject: [PATCH] Add notifications for locking and unlocking Sones. --- .../java/net/pterodactylus/sone/core/CoreListener.java | 16 ++++++++++++++++ .../java/net/pterodactylus/sone/web/WebInterface.java | 16 ++++++++++++++++ 2 files changed, 32 insertions(+) diff --git a/src/main/java/net/pterodactylus/sone/core/CoreListener.java b/src/main/java/net/pterodactylus/sone/core/CoreListener.java index 950e890..5d5e715 100644 --- a/src/main/java/net/pterodactylus/sone/core/CoreListener.java +++ b/src/main/java/net/pterodactylus/sone/core/CoreListener.java @@ -111,4 +111,20 @@ public interface CoreListener extends EventListener { */ public void replyRemoved(Reply reply); + /** + * Notifies a listener when a Sone was locked. + * + * @param sone + * The Sone that was locked + */ + public void soneLocked(Sone sone); + + /** + * Notifies a listener that a Sone was unlocked. + * + * @param sone + * The Sone that was unlocked + */ + public void soneUnlocked(Sone sone); + } diff --git a/src/main/java/net/pterodactylus/sone/web/WebInterface.java b/src/main/java/net/pterodactylus/sone/web/WebInterface.java index d17c2d5..a5376af 100644 --- a/src/main/java/net/pterodactylus/sone/web/WebInterface.java +++ b/src/main/java/net/pterodactylus/sone/web/WebInterface.java @@ -647,6 +647,22 @@ public class WebInterface implements CoreListener { } /** + * {@inheritDoc} + */ + @Override + public void soneLocked(Sone sone) { + /* TODO */ + } + + /** + * {@inheritDoc} + */ + @Override + public void soneUnlocked(Sone sone) { + /* TODO */ + } + + /** * Template provider implementation that uses * {@link WebInterface#createReader(String)} to load templates for * inclusion. -- 2.7.4