Add accessors for notifications and the notification manager.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sun, 14 Nov 2010 14:37:37 +0000 (15:37 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sun, 14 Nov 2010 14:37:37 +0000 (15:37 +0100)
src/main/java/net/pterodactylus/sone/web/WebInterface.java

index 1a1027d..01c1861 100644 (file)
@@ -40,6 +40,8 @@ import net.pterodactylus.sone.template.CollectionAccessor;
 import net.pterodactylus.sone.template.CssClassNameFilter;
 import net.pterodactylus.sone.template.GetPagePlugin;
 import net.pterodactylus.sone.template.IdentityAccessor;
+import net.pterodactylus.sone.template.NotificationAccessor;
+import net.pterodactylus.sone.template.NotificationManagerAccessor;
 import net.pterodactylus.sone.template.PostAccessor;
 import net.pterodactylus.sone.template.ReplyAccessor;
 import net.pterodactylus.sone.template.RequestChangeFilter;
@@ -60,6 +62,8 @@ import net.pterodactylus.sone.web.page.PageToadlet;
 import net.pterodactylus.sone.web.page.PageToadletFactory;
 import net.pterodactylus.sone.web.page.StaticPage;
 import net.pterodactylus.util.logging.Logging;
+import net.pterodactylus.util.notify.Notification;
+import net.pterodactylus.util.notify.NotificationManager;
 import net.pterodactylus.util.template.DateFilter;
 import net.pterodactylus.util.template.DefaultTemplateFactory;
 import net.pterodactylus.util.template.MatchFilter;
@@ -114,6 +118,8 @@ public class WebInterface {
                templateFactory.addAccessor(Post.class, new PostAccessor(getCore()));
                templateFactory.addAccessor(Reply.class, new ReplyAccessor(getCore()));
                templateFactory.addAccessor(Identity.class, new IdentityAccessor(getCore()));
+               templateFactory.addAccessor(Notification.class, new NotificationAccessor());
+               templateFactory.addAccessor(NotificationManager.class, new NotificationManagerAccessor());
                templateFactory.addFilter("date", new DateFilter());
                templateFactory.addFilter("l10n", new L10nFilter(getL10n()));
                templateFactory.addFilter("substring", new SubstringFilter());