roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From snoopd...@apache.org
Subject svn commit: r593907 - in /roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel: ./ build.xml src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java
Date Sun, 11 Nov 2007 15:28:22 GMT
Author: snoopdave
Date: Sun Nov 11 07:28:21 2007
New Revision: 593907

URL: http://svn.apache.org/viewvc?rev=593907&view=rev
Log:
Updating example plugin for 4.0

Modified:
    roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/   (props changed)
    roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/build.xml
    roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java

Propchange: roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sun Nov 11 07:28:21 2007
@@ -1,2 +1,3 @@
 build
 dist
+.crap.swp

Modified: roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/build.xml
URL: http://svn.apache.org/viewvc/roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/build.xml?rev=593907&r1=593906&r2=593907&view=diff
==============================================================================
--- roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/build.xml (original)
+++ roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/build.xml Sun Nov 11 07:28:21
2007
@@ -1,17 +1,19 @@
 
 <project name="pluginmodel" default="dist">
     
-    <property name="rollerdir" value="../../../.." />
+    <property name="tools" value="../../../../../../tools" />
+    <property name="buildlib" value="../../../../build/lib" />
     
     <target name="dist">
         <mkdir dir="build" />
         <mkdir dir="dist" />
         <javac srcdir="src" destdir="build">
             <classpath>
-                <pathelement path="${rollerdir}/build/lib/roller-business.jar" />
-                <pathelement path="${rollerdir}/build/lib/roller-web.jar" />
-                <pathelement path="${rollerdir}/tools/lib/commons-logging-1.0.4.jar" />
-                <pathelement path="${rollerdir}/tools/buildtime/tomcat-5.0.28/servlet-api.jar"
/>
+                <pathelement path="${buildlib}/roller-business.jar" />
+                <pathelement path="${buildlib}/roller-web.jar" />
+                <pathelement path="${tools}/roller-core/roller-core.jar" />
+                <pathelement path="${tools}/lib/commons-logging-1.0.4.jar" />
+                <pathelement path="${tools}/buildtime/tomcat-5.0.28/servlet-api.jar" />
             </classpath>
         </javac>
         <jar basedir="build" destfile="dist/authusermodel.jar" />

Modified: roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java
URL: http://svn.apache.org/viewvc/roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java?rev=593907&r1=593906&r2=593907&view=diff
==============================================================================
--- roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java
(original)
+++ roller/trunk/apps/weblogger/docs/examples/plugins/pluginmodel/src/org/apache/roller/examples/plugins/pagemodel/AuthenticatedUserModel.java
Sun Nov 11 07:28:21 2007
@@ -5,10 +5,10 @@
 import javax.servlet.http.HttpServletRequest;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
-import org.apache.roller.RollerException;
-import org.apache.roller.pojos.wrapper.UserDataWrapper;
-import org.apache.roller.ui.core.RollerSession;
-import org.apache.roller.ui.rendering.model.Model;
+import org.apache.roller.weblogger.ui.core.RollerSession;
+import org.apache.roller.weblogger.WebloggerException;
+import org.apache.roller.weblogger.pojos.wrapper.UserWrapper;
+import org.apache.roller.weblogger.ui.rendering.model.Model;
 
 
 public class AuthenticatedUserModel implements Model {
@@ -19,15 +19,15 @@
         return "authenticated";
     }
 
-    public void init(Map params) throws RollerException {
+    public void init(Map params) throws WebloggerException {
         this.request = (HttpServletRequest)params.get("request");
     }
     
-    public UserDataWrapper getUser() {
+    public UserWrapper getUser() {
         try {
             RollerSession rses = RollerSession.getRollerSession(request);
             if (rses != null && rses.getAuthenticatedUser() != null) {
-                return UserDataWrapper.wrap(rses.getAuthenticatedUser());
+                return UserWrapper.wrap(rses.getAuthenticatedUser());
             }
         } catch (Exception e) {
             log.warn("ERROR: checking user authorization", e);



Mime
View raw message