incubator-esme-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vdic...@apache.org
Subject svn commit: r795376 - in /incubator/esme/trunk/server/src/main: scala/org/apache/esme/lib/MsgParser.scala scala/org/apache/esme/model/Action.scala webapp/action_view/index.html
Date Sat, 18 Jul 2009 14:27:43 GMT
Author: vdichev
Date: Sat Jul 18 14:27:43 2009
New Revision: 795376

URL: http://svn.apache.org/viewvc?rev=795376&view=rev
Log:
ESME-74 Action filter for messages from any pool

Modified:
    incubator/esme/trunk/server/src/main/scala/org/apache/esme/lib/MsgParser.scala
    incubator/esme/trunk/server/src/main/scala/org/apache/esme/model/Action.scala
    incubator/esme/trunk/server/src/main/webapp/action_view/index.html

Modified: incubator/esme/trunk/server/src/main/scala/org/apache/esme/lib/MsgParser.scala
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/scala/org/apache/esme/lib/MsgParser.scala?rev=795376&r1=795375&r2=795376&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/scala/org/apache/esme/lib/MsgParser.scala (original)
+++ incubator/esme/trunk/server/src/main/scala/org/apache/esme/lib/MsgParser.scala Sat Jul
18 14:27:43 2009
@@ -332,11 +332,12 @@
     case x => ParenAction(x)
   }
 
-  lazy val testPool: Parser[PoolAction] =
+  lazy val testPool: Parser[TestAction] =
   (whiteSpace ~ acceptCI("pool:") ~> rep1(digit) <~ whiteSpace ^^ {case id => PoolAction(id.mkString.toLong)})
|
   (poolName ^^ {
       case PoolName(pool) => PoolAction(pool.id)
-    })
+    }) |
+  (whiteSpace ~ acceptCI("pool") ~ whiteSpace ^^^ PoolAction)
     
   lazy val testResent: Parser[TestAction] = 
   (whiteSpace ~ acceptCI("resent:") ~> rep1(digit) <~ whiteSpace ^^ {case id =>
ResentAction(id.mkString.toLong)}) |

Modified: incubator/esme/trunk/server/src/main/scala/org/apache/esme/model/Action.scala
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/scala/org/apache/esme/model/Action.scala?rev=795376&r1=795375&r2=795376&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/scala/org/apache/esme/model/Action.scala (original)
+++ incubator/esme/trunk/server/src/main/scala/org/apache/esme/model/Action.scala Sat Jul
18 14:27:43 2009
@@ -96,6 +96,9 @@
     case PoolAction(poolId) =>
       (m, u, c, r) => m.pool.is == poolId
       
+    case PoolAction =>
+      (m, u, c, r) => m.pool.defined_?
+    
     case ResentAction(userId) =>
       (m, u, c, r) => r match {
         case ResendReason(`userId`) => true
@@ -306,6 +309,10 @@
   def toStr = "@"+userId
 }
 
+case object PoolAction extends TestAction {
+  def toStr = "pool"
+}
+
 case class PoolAction(poolId: Long) extends TestAction {
   def toStr = "pool:" + poolId
 }

Modified: incubator/esme/trunk/server/src/main/webapp/action_view/index.html
URL: http://svn.apache.org/viewvc/incubator/esme/trunk/server/src/main/webapp/action_view/index.html?rev=795376&r1=795375&r2=795376&view=diff
==============================================================================
--- incubator/esme/trunk/server/src/main/webapp/action_view/index.html (original)
+++ incubator/esme/trunk/server/src/main/webapp/action_view/index.html Sat Jul 18 14:27:43
2009
@@ -53,7 +53,8 @@
           unfollowed -- user is being unfollowed<br/>
           profile -- user changed profile<br/>
           every N mins -- repeat action, N is an integer<br/>
-          pool:mypool -- message is in access pool mypool
+          pool[:mypool] -- message is in access pool mypool<br/>
+          resent[:user] -- message was resent by user
         </td>
       </tr>
 
@@ -66,8 +67,7 @@
           mailto:foo@bar.com -- sends the message to foo@bar.com<br/>
           http://foo.com/message/in -- HTTP post, %s expands to message<br/>
           atom:http://blog.com/feed.atom -- posts new messages from Atom feed<br/>
-          rss:http://blog.com/feed.rss -- posts new messages from RSS feed<br/>
-          scala -- proccess message text in Scala interpreter
+          rss:http://blog.com/feed.rss -- posts new messages from RSS feed
         </td>
       </tr>
       <input type="submit" value="Add" />



Mime
View raw message