PK T>![ build.propertiesplay.path=../play
PK T>So build.xml
PK =m>y8 8 commands.py# Here you can create play commands that are specific to the module, and extend existing commands
MODULE = 'router'
# Commands that are specific to your module
COMMANDS = ['router:hello']
def execute(**kargs):
command = kargs.get("command")
app = kargs.get("app")
args = kargs.get("args")
env = kargs.get("env")
if command == "router:hello":
print "~ Hello"
# This will be executed before any command (new, run...)
def before(**kargs):
command = kargs.get("command")
app = kargs.get("app")
args = kargs.get("args")
env = kargs.get("env")
# This will be executed after any command (new, run...)
def after(**kargs):
command = kargs.get("command")
app = kargs.get("app")
args = kargs.get("args")
env = kargs.get("env")
if command == "new":
pass
PK mm>=Ys" " manifestversion=1.1
frameworkVersions=1.1
PK T>! README.textileh1. Router Annotations
Written by Nicolas Leroux.
Improved by Leon Radley (digiPlant AB)
h2. Supported annotations
The router module allows you to embed your "routes":http://www.playframework.org/documentation/1.2/routes inside the controller. It provides a set of annotations to declare your "routes":http://www.playframework.org/documentation/1.2/routes next to your controller methods.
The following annotations are supported at method level:
* **@Post**
* **@Put**
* **@Get**
* **@Delete**
* **@Head**
* **@WS**
* **@Any**
These annotations have the following attributes:
* **value**: the path to access your controller's method
* **priority** (optional): the priority of the route (lower number is higher priority)
* **accept** (optional)
* **format** (optional)
**@Any** matches all the above HTTP methods.
p(note). Note that the path uses the same format described in "HTTP routing":http://www.playframework.org/documentation/1.2/routes
Examples:
bc. @Get("/emails/{<.*>folderNames}/{messageId}")
public static void email(@Bind(separator = "/")String[] folderNames, int messageId) throws Exception {
...
}
bc. @Post("/login")
public static void authenticate(String username, String password) throws Exception {
...
}
The following annotations are supported at class level:
* **@ServeStatic**
* **@StaticRoutes**
@ServeStatic indicates content that need to be served statically. It has the following attributes:
* **value**: The path to access the content
* **directory**: the directory you want to access inside the Play! application
* **priority** (optional): the priority of the route (lower number is higher priority)
@StaticRoutes allows to define multiple @ServeStatic routes.
Examples:
bc. @ServeStatic(value = "/public/", directory = "public")
public class Application extends Controller {
...
}
bc. @StaticRoutes({
@ServeStatic(value = "/public/", directory = "public"),
@ServeStatic(value = "/images/", directory = "images")
})
public class Application extends Controller {
...
}
p(note). Be sure to empty the "routes" file to avoid any conflicting routes.
h2. Enable the router module for the application
In the **/conf/dependencies.yml** file, enable the router module by adding this line:
bc. # The router module
- play -> router head
h2. Issue tracking
If you wish to report a bug or wish for a new feature, please use the "issue tracker":https://github.com/digiPlant/play-router-annotations/issuesPK m>>a- - conf/dependencies.ymlself: play -> router 1.1
require:
- playPK T>Yw w ! documentation/manual/home.textileh1. Router Annotations
h2. Supported annotations
The router module allows you to embed your "routes":http://www.playframework.org/documentation/1.2/routes inside the controller. It provides a set of annotations to declare your "routes":http://www.playframework.org/documentation/1.2/routes next to your controller methods.
The following annotations are supported at method level:
* **@Post**
* **@Put**
* **@Get**
* **@Delete**
* **@Head**
* **@WS**
* **@Any**
These annotations have the following attributes:
* **value**: the path to access your controller's method
* **priority** (optional): the priority of the route (lower number is higher priority)
* **accept** (optional)
* **format** (optional)
**@Any** matches all the above HTTP methods.
p(note). Note that the path uses the same format described in "HTTP routing":http://www.playframework.org/documentation/1.2/routes
Examples:
bc. @Get("/emails/{<.*>folderNames}/{messageId}")
public static void email(@Bind(separator = "/")String[] folderNames, int messageId) throws Exception {
...
}
bc. @Post("/login")
public static void authenticate(String username, String password) throws Exception {
...
}
The following annotations are supported at class level:
* **@ServeStatic**
* **@StaticRoutes**
@ServeStatic indicates content that need to be served statically. It has the following attributes:
* **value**: The path to access the content
* **directory**: the directory you want to access inside the Play! application
* **priority** (optional): the priority of the route (lower number is higher priority)
@StaticRoutes allows to define multiple @ServeStatic routes.
Examples:
bc. @ServeStatic(value = "/public/", directory = "public")
public class Application extends Controller {
...
}
bc. @StaticRoutes({
@ServeStatic(value = "/public/", directory = "public"),
@ServeStatic(value = "/images/", directory = "images")
})
public class Application extends Controller {
...
}
p(note). Be sure to empty the "routes" file to avoid any conflicting routes.
h2. Enable the router module for the application
In the **/conf/dependencies.yml** file, enable the router module by adding this line:
bc. # The router module
- play -> router head
h2. Issue tracking
If you wish to report a bug or wish for a new feature, please use the "issue tracker":https://github.com/digiPlant/play-router-annotations/issues
PK mm>@X lib/router-annotations.jarPK
nm> META-INF/ PK
mm>. META-INF/MANIFEST.MFM EwQGhiN5FAP -R'sm= ^86\PQQYfYyIyBӺ5ﲂ8N]{J(vsz1tCJ)&{XN·PK
mm> play/PK
mm>
play/modules/PK
mm> play/modules/router/PK
mm>, . play.plugins34*IO)I-+/-I-Syy%%y9y PK
mm>=GPA play/modules/router/Any.classQ]KA=㮭ٗeQ sOFBfKO6̲;+_ЏY 403;
G2Pk|}D5C)NIVPhm,讘LY$ PĄc%J::\`h2me$d*'J2S_} +QW,F0'7z+OfbS" 6veNJ~d^2%R?1O1TV1\gkW37=YC. pPK
mm>lC play/modules/router/Delete.classQN@=CE4FƵ+0n\
BmNIk. ?JD#8dNιǼ@}) Ԛ۩KW`Mɥ@1U+ XVWzFA2#PL0O0Lc6i2t(#PQ3zTiZ&Z?;`?!V~Ɓ:ǫS<Opjiƞ^z8YjJ8L
ׄS4%Wq|9vCr|-#g0[dbD26`&=bTa&T| PK
mm>Q`]@ play/modules/router/Get.classQ]KA=㮭ٗeQ sOVBfKOvvgk=Q"9s{g?^ \A@q.uFVn&2#pz)P%V^adQQء̴>y M$F S̸<ħkD@cFR5ִLN!wH⮚X"ǫx2aj)L/Mkw;c-s7^2MD*˘xF>S'+37?Yſc6fKZ=3QfHC>UX Ubo!5PK
mm>A play/modules/router/Head.classQ]KA=㮭ڗQ sOBfKOzYC?U݅a9ޙ7 ר;8vp&_J@ٺ˥tg$*DE2+ Tn02Ҩ(lTXQH# )f\Eiӝ\%9ʊԇihT@jƚ֡_0CVcb3|zz+LfdyYh
8[Ħ~X˕DTMPf 9|~-my\fLX&fb!s>,ۄ
pBG_PK
mm>UA play/modules/router/Post.classQ]KA=㮮ڗQ sOFBKO6β;+_ЏBd0sΜ{+98vd(JCӽ_w2\\3XXt0ԆÞTCi/"թNc_JE%*c˼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