org.mashupbots.socko.routes
Matches HTTP requests that have a query string matching the specified regular expression.
For example, to match ?name1=value1, first define your regular expression as an object:
?name1=value1
object MyQueryStringRegex extends QueryStringRegex("""name1=([a-z0-9]+)""".r)
Then, when defining your Route:
val r = Routes({ case MyQueryStringRegex(m) => { assert(m.group(1) == "value1") ... } })
Matches HTTP requests that have a query string matching the specified regular expression.
For example, to match
?name1=value1, first define your regular expression as an object:object MyQueryStringRegex extends QueryStringRegex("""name1=([a-z0-9]+)""".r)Then, when defining your Route:
val r = Routes({ case MyQueryStringRegex(m) => { assert(m.group(1) == "value1") ... } })