Skip to content
Browse files

Added documentation validation task

  • Loading branch information...
1 parent 7d3349b commit 80b6ccc16c6e2ea11b45683a2227d55b24c7541f @jroper jroper committed
Showing with 412 additions and 591 deletions.
  1. +3 −0 documentation/build
  2. +2 −2 documentation/manual/Highlights.md
  3. +11 −6 documentation/manual/Home.md
  4. +6 −6 documentation/manual/_Sidebar.md
  5. +1 −1 documentation/manual/about/Philosophy.md
  6. 0 documentation/manual/{User-Groups-around-the-World.md → about/PlayUserGroups.md}
  7. +2 −3 documentation/manual/book/BookDetailledTopics.md
  8. +2 −2 documentation/manual/detailledTopics/assets/AssetsCoffeeScript.md
  9. +2 −2 documentation/manual/detailledTopics/assets/AssetsLess.md
  10. +5 −5 documentation/manual/detailledTopics/assets/_Sidebar.md
  11. +1 −1 documentation/manual/detailledTopics/build/Build.md
  12. +1 −1 documentation/manual/detailledTopics/build/SBTDependencies.md
  13. +1 −1 documentation/manual/detailledTopics/build/SBTSettings.md
  14. +5 −5 documentation/manual/detailledTopics/build/_Sidebar.md
  15. +1 −1 documentation/manual/detailledTopics/configuration/Configuration.md
  16. +2 −2 documentation/manual/detailledTopics/configuration/SettingsJDBC.md
  17. +1 −1 documentation/manual/detailledTopics/configuration/SettingsLogger.md
  18. +5 −5 documentation/manual/detailledTopics/configuration/_Sidebar.md
  19. +3 −3 documentation/manual/detailledTopics/production/HTTPServer.md
  20. +2 −2 documentation/manual/detailledTopics/production/ProductionHeroku.md
  21. +5 −5 documentation/manual/detailledTopics/production/_Sidebar.md
  22. +2 −2 documentation/manual/gettingStarted/Anatomy.md
  23. +2 −2 documentation/manual/gettingStarted/Installing.md
  24. +2 −2 documentation/manual/gettingStarted/NewApplication.md
  25. +2 −2 documentation/manual/gettingStarted/Samples.md
  26. +2 −2 documentation/manual/hacking/BuildingFromSource.md
  27. +10 −0 documentation/manual/hacking/Documentation.md
  28. +1 −1 documentation/manual/hacking/Issues.md
  29. +2 −2 documentation/manual/hacking/Repositories.md
  30. +3 −3 documentation/manual/hacking/ThirdPartyTools.md
  31. +6 −1 documentation/manual/javaGuide/JavaHome.md
  32. +4 −0 documentation/manual/javaGuide/_Sidebar.md
  33. +34 −0 documentation/manual/javaGuide/advanced/extending/JavaPlugins.md
  34. +2 −2 documentation/manual/javaGuide/main/akka/JavaAkka.md
  35. +2 −2 documentation/manual/javaGuide/main/async/JavaAsync.md
  36. +2 −2 documentation/manual/javaGuide/main/async/JavaStream.md
  37. +3 −3 documentation/manual/javaGuide/main/async/JavaWebSockets.md
  38. +1 −1 documentation/manual/javaGuide/main/cache/JavaCache.md
  39. +1 −1 documentation/manual/javaGuide/main/forms/JavaFormHelpers.md
  40. +1 −1 documentation/manual/javaGuide/main/forms/JavaForms.md
  41. +2 −2 documentation/manual/javaGuide/main/http/JavaContentNegotiation.md
  42. +2 −2 documentation/manual/javaGuide/main/sql/JavaEbean.md
  43. +1 −1 documentation/manual/javaGuide/main/tests/JavaFunctionalTest.md
  44. +2 −2 documentation/manual/javaGuide/main/tests/JavaTest.md
  45. +2 −2 documentation/manual/javaGuide/main/ws/JavaOpenID.md
  46. +3 −3 documentation/manual/javaGuide/tutorials/todolist/JavaTodoList.md
  47. +1 −1 documentation/manual/javaGuide/tutorials/zentasks/JavaGuide6.md
  48. +0 −9 documentation/manual/sandbox/Declare-anonymous-function-in-templates.md
  49. +0 −14 documentation/manual/sandbox/Javacaching.md
  50. +0 −42 documentation/manual/sandbox/Javacookies.md
  51. +0 −49 documentation/manual/sandbox/Javahttp.md
  52. +0 −44 documentation/manual/sandbox/Javajson.md
  53. +0 −13 documentation/manual/sandbox/Javaplayaslibrary.md
  54. +0 −32 documentation/manual/sandbox/Javaplugin.md
  55. +0 −3 documentation/manual/sandbox/Missing.md
  56. +0 −73 documentation/manual/sandbox/Scalacache.md
  57. +0 −13 documentation/manual/sandbox/Scalaextend.md
  58. +0 −38 documentation/manual/sandbox/Scalahttp.md
  59. +0 −24 documentation/manual/sandbox/Scalaplugin.md
  60. +0 −39 documentation/manual/sandbox/Status.md
  61. +0 −72 documentation/manual/sandbox/Tips.md
  62. +2 −1 documentation/manual/scalaGuide/ScalaHome.md
  63. +1 −0 documentation/manual/scalaGuide/_Sidebar.md
  64. +25 −0 documentation/manual/scalaGuide/advanced/extending/ScalaPlugins.md
  65. +1 −1 documentation/manual/scalaGuide/main/akka/ScalaAkka.md
  66. +2 −2 documentation/manual/scalaGuide/main/async/ScalaStream.md
  67. +2 −2 documentation/manual/scalaGuide/main/async/ScalaWebSockets.md
  68. +1 −1 documentation/manual/scalaGuide/main/cache/ScalaCache.md
  69. +1 −1 documentation/manual/scalaGuide/main/forms/ScalaFormHelpers.md
  70. +2 −2 documentation/manual/scalaGuide/main/http/ScalaContentNegotiation.md
  71. +1 −1 documentation/manual/scalaGuide/main/sql/ScalaAnorm.md
  72. +3 −3 documentation/manual/scalaGuide/main/sql/ScalaDatabase.md
  73. +2 −2 documentation/manual/scalaGuide/main/sql/ScalaDatabaseOthers.md
  74. +1 −1 documentation/manual/scalaGuide/main/tests/ScalaFunctionalTest.md
  75. +1 −1 documentation/manual/scalaGuide/main/tests/ScalaTest.md
  76. +3 −3 documentation/manual/scalaGuide/main/ws/ScalaOAuth.md
  77. +2 −2 documentation/manual/scalaGuide/main/ws/ScalaOpenID.md
  78. +4 −4 documentation/manual/scalaGuide/tutorials/todolist/ScalaTodoList.md
  79. +5 −2 documentation/project/Build.scala
  80. +196 −0 documentation/project/DocValidation.scala
  81. +1 −1 framework/src/sbt-plugin/src/main/java/play/markdown/CodeReferenceParser.java
View
3 documentation/build
@@ -0,0 +1,3 @@
+#! /bin/sh
+
+../framework/build $@
View
4 documentation/manual/Highlights.md
@@ -128,7 +128,7 @@ GET / @controllers.Application.index()
Play will invoke the `getControllerInstance` method which in return will provide an instance of `controllers.Application` (by default this is happening via the default constructor). Therefore, if you want to manage controller class instantiation either via a dependency injection framework or manually you can do so by overriding getControllerInstance in your application’s Global class.
-As this example [[demonstrates it|https://github.com/guillaumebort/play20-spring-demo]], it allows to wire any dependency injection framework such as __Spring__ into your Play application.
+As this example [demonstrates it](https://github.com/guillaumebort/play20-spring-demo), it allows to wire any dependency injection framework such as __Spring__ into your Play application.
## New Scala JSON API
@@ -156,7 +156,7 @@ The `filters` project that is part of the standard Play distribution contain a s
## RequireJS
-In play 2.0 the default behavior for Javascript was to use google closure's commonJS module support. In 2.1 this was changed to use [[requireJS|http://requirejs.org/]] instead.
+In play 2.0 the default behavior for Javascript was to use google closure's commonJS module support. In 2.1 this was changed to use [requireJS](http://requirejs.org/) instead.
What this means in practice is that by default Play will only minify and combine files in stage, dist, start modes only. In dev mode Play will resolve dependencies client side.
View
17 documentation/manual/Home.md
@@ -15,7 +15,7 @@
1. [[Using the Play console | PlayConsole ]]
1. [[Setting up your preferred IDE | IDE]]
1. [[Sample applications | Samples]]
-1. [[Security policy | http://www.playframework.com/code/security]]
+1. [Security policy](http://www.playframework.com/code/security)
## Working with Play
@@ -49,11 +49,11 @@
## Additional documentation
-1. [[Scala|http://docs.scala-lang.org/]]
-1. [[Akka|http://akka.io/docs/]]
-1. [[sbt|http://www.scala-sbt.org/learn.html]]
-1. [[Configuration|https://github.com/typesafehub/config]]
-1. [[Logback|http://logback.qos.ch/documentation.html]]
+1. [Scala](http://docs.scala-lang.org/)
+1. [Akka](http://akka.io/docs/)
+1. [sbt](http://www.scala-sbt.org/learn.html)
+1. [Configuration](https://github.com/typesafehub/config)
+1. [Logback](http://logback.qos.ch/documentation.html)
## Hacking Play
@@ -63,6 +63,11 @@
1. [[Issue tracker | Issues]]
1. [[Contributor guidelines | Guidelines]]
+## About Play
+
+1. [[Play Philosophy|Philosophy]]
+1. [[Play User Groups|PlayUserGroups]]
+
## Modules and plugins
1. [[Temporary modules directory | Modules]]
View
12 documentation/manual/_Sidebar.md
@@ -6,7 +6,7 @@
- [[Using the Play console | PlayConsole ]]
- [[Setting-up your preferred IDE | IDE]]
- [[Sample applications | Samples]]
-- [[Security policy | http://www.playframework.com/code/security]]
+- [Security policy](http://www.playframework.com/code/security)
### Working with Play
@@ -23,8 +23,8 @@
### Additional documentation
-- [[Scala|http://docs.scala-lang.org/]]
-- [[Akka|http://akka.io/docs/]]
-- [[sbt|http://www.scala-sbt.org/learn.html]]
-- [[Configuration|https://github.com/typesafehub/config]]
-- [[Logback|http://logback.qos.ch/documentation.html]]
+- [Scala](http://docs.scala-lang.org/)
+- [Akka](http://akka.io/docs/)
+- [sbt](http://www.scala-sbt.org/learn.html)
+- [Configuration](https://github.com/typesafehub/config)
+- [Logback](http://logback.qos.ch/documentation.html)
View
2 documentation/manual/about/Philosophy.md
@@ -1,6 +1,6 @@
# Introducing Play 2.0
-Since 2007, we have been working on making Java web application development easier. Play started as an internal project at [[Zenexity|http://www.zenexity.com]] and was heavily influenced by our way of doing web projects: focusing on developer productivity, respecting web architecture, and using a fresh approach to packaging conventions from the start - breaking so-called JEE best practices where it made sense.
+Since 2007, we have been working on making Java web application development easier. Play started as an internal project at [Zenexity](http://www.zenexity.com) and was heavily influenced by our way of doing web projects: focusing on developer productivity, respecting web architecture, and using a fresh approach to packaging conventions from the start - breaking so-called JEE best practices where it made sense.
In 2009, we decided to share these ideas with the community as an open source project. The immediate feedback was extremely positive and the project gained a lot of traction. Today - after two years of active development - Play has several versions, an active community of 4,000 people, with a growing number of applications running in production all over the globe.
View
0 ...on/manual/User-Groups-around-the-World.md → documentation/manual/about/PlayUserGroups.md
File renamed without changes.
View
5 documentation/manual/book/BookDetailledTopics.md
@@ -11,7 +11,7 @@
1. [[Managing database evolutions | Evolutions]]
1. [[Configuration file syntax and features | Configuration]]
1. [[Configuring the JDBC connection pool | SettingsJDBC]]
- 1. [[Configuring the internal Akka system | AkkaCore]]
+ 1. [[Configuring the thread pools | ThreadPools]]
1. [[Configuring logging | SettingsLogger]]
1. [[Deploying your application | Production]]
1. [[Creating a standalone version of your application | ProductionDist]]
@@ -23,5 +23,4 @@
1. [[CI server at Cloudbees | CIServer]]
1. [[Repositories | Repositories]]
1. [[Issue tracker | Issues]]
- 1. [[Pull requests | PullRequests]]
- 1. [[Contributor guidelines | Guidelines]]
+ 1. [[Contributor guidelines | Guidelines]]
View
4 documentation/manual/detailledTopics/assets/AssetsCoffeeScript.md
@@ -1,6 +1,6 @@
# Using CoffeeScript
-[[CoffeeScript | http://jashkenas.github.com/coffee-script/]] is a small and elegant language that compiles into JavaScript. It provides a nicer syntax for writing JavaScript code.
+[CoffeeScript](http://jashkenas.github.com/coffee-script/) is a small and elegant language that compiles into JavaScript. It provides a nicer syntax for writing JavaScript code.
Compiled assets in Play must be defined in the `app/assets` directory. They are handled by the build process, and CoffeeScript sources are compiled into standard JavaScript files. The generated JavaScript files are distributed as standard resources into the same `public/` folder as other unmanaged assets, meaning that there is no difference in the way you use them once compiled.
@@ -49,4 +49,4 @@ coffeescriptOptions := Seq("native", "/usr/local/bin/coffee -p")
By default, the JavaScript code is generated inside a top-level function safety wrapper, preventing it from polluting the global scope. The `bare` option removes this function wrapper.
-> **Next:** [[Using LESS CSS | AssetsLess]]
+> **Next:** [[Using LESS CSS | AssetsLess]]
View
4 documentation/manual/detailledTopics/assets/AssetsLess.md
@@ -1,6 +1,6 @@
# Using LESS CSS
-[[LESS CSS | http://lesscss.org/]] is a dynamic stylesheet language. It allows greater flexibility in the way you write CSS files: including support for variables, mixins and more.
+[LESS CSS](http://lesscss.org/) is a dynamic stylesheet language. It allows greater flexibility in the way you write CSS files: including support for variables, mixins and more.
Compilable assets in Play must be defined in the `app/assets` directory. They are handled by the build process, and LESS sources are compiled into standard CSS files. The generated CSS files are distributed as standard resources into the same `public/` folder as the unmanaged assets, meaning that there is no difference in the way you use them once compiled.
@@ -67,4 +67,4 @@ For example, to compile `app/assets/stylesheets/main.less` and nothing else:
)
```
-> **Next:** [[Using Google Closure Compiler | AssetsGoogleClosureCompiler]]
+> **Next:** [[Using Google Closure Compiler | AssetsGoogleClosureCompiler]]
View
10 documentation/manual/detailledTopics/assets/_Sidebar.md
@@ -29,8 +29,8 @@
### Additional documentation
-- [[Scala|http://docs.scala-lang.org/]]
-- [[Akka|http://akka.io/docs/]]
-- [[sbt|http://www.scala-sbt.org/learn.html]]
-- [[Configuration|https://github.com/typesafehub/config]]
-- [[Logback|http://logback.qos.ch/documentation.html]]
+- [Scala](http://docs.scala-lang.org/)
+- [Akka](http://akka.io/docs/)
+- [sbt](http://www.scala-sbt.org/learn.html)
+- [Configuration](https://github.com/typesafehub/config)
+- [Logback](http://logback.qos.ch/documentation.html)
View
2 documentation/manual/detailledTopics/build/Build.md
@@ -1,6 +1,6 @@
# The Build System
-The Play build system is based on [[sbt|http://www.scala-sbt.org/]], a minimally non-intrusive build tool for Scala and Java projects.
+The Play build system is based on [sbt](http://www.scala-sbt.org/), a minimally non-intrusive build tool for Scala and Java projects.
## The `/project` directory
View
2 documentation/manual/detailledTopics/build/SBTDependencies.md
@@ -54,7 +54,7 @@ val appDependencies = Seq(
### Resolvers
-Not all packages live on the same server; sbt uses the standard Maven2 repository and the Scala Tools Releases ([[http://scala-tools.org/repo-releases]]) repositories by default. If your dependency isn’t on one of the default repositories, you’ll have to add a resolver to help Ivy find it.
+Not all packages live on the same server; sbt uses the standard Maven2 repository and the Scala Tools Releases (<http://scala-tools.org/repo-releases>) repositories by default. If your dependency isn’t on one of the default repositories, you’ll have to add a resolver to help Ivy find it.
Use the `resolvers` setting key to add your own resolver.
View
2 documentation/manual/detailledTopics/build/SBTSettings.md
@@ -2,7 +2,7 @@
## About sbt settings
-The sbt build script defines settings for your project. You can also define your own custom settings for your project, as described in the [[sbt documentation | http://www.scala-sbt.org]]. In particular, it helps to be familiar with the [[settings | http://www.scala-sbt.org/release/docs/Getting-Started/More-About-Settings]] in sbt.
+The sbt build script defines settings for your project. You can also define your own custom settings for your project, as described in the [sbt documentation](http://www.scala-sbt.org). In particular, it helps to be familiar with the [settings](http://www.scala-sbt.org/release/docs/Getting-Started/More-About-Settings) in sbt.
To set a basic setting, use the `:=` operator:
View
10 documentation/manual/detailledTopics/build/_Sidebar.md
@@ -28,8 +28,8 @@
### Additional documentations
-- [[Scala|http://docs.scala-lang.org/]]
-- [[Akka|http://akka.io/docs/]]
-- [[sbt|http://www.scala-sbt.org/learn.html]]
-- [[Configuration|https://github.com/typesafehub/config]]
-- [[Logback|http://logback.qos.ch/documentation.html]]
+- [Scala](http://docs.scala-lang.org/)
+- [Akka](http://akka.io/docs/)
+- [sbt](http://www.scala-sbt.org/learn.html)
+- [Configuration](https://github.com/typesafehub/config)
+- [Logback](http://logback.qos.ch/documentation.html)
View
2 documentation/manual/detailledTopics/configuration/Configuration.md
@@ -1,6 +1,6 @@
# Configuration file syntax and features
-> The configuration file used by Play is based on the [[Typesafe config library | https://github.com/typesafehub/config]].
+> The configuration file used by Play is based on the [Typesafe config library](https://github.com/typesafehub/config).
The default configuration file of a Play 2.0 application must be defined in `conf/application.conf`. It uses the HOCON format ( "Human-Optimized Config Object Notation").
View
4 documentation/manual/detailledTopics/configuration/SettingsJDBC.md
@@ -1,6 +1,6 @@
# Configuring the JDBC pool.
-The Play JDBC datasource is managed by [[BoneCP | http://jolbox.com/]].
+The Play JDBC datasource is managed by [BoneCP](http://jolbox.com/).
## Special URLs
@@ -91,4 +91,4 @@ db.default.logStatements=false
# The maximum connection age.
db.default.maxConnectionAge=1 hour
-```
+```
View
2 documentation/manual/detailledTopics/configuration/SettingsLogger.md
@@ -1,6 +1,6 @@
# Configuring logging
-Play 2.0 uses [[logback | http://logback.qos.ch/]] as its logging engine.
+Play 2.0 uses [logback](http://logback.qos.ch/) as its logging engine.
## Configuration logging level in application.conf
View
10 documentation/manual/detailledTopics/configuration/_Sidebar.md
@@ -28,8 +28,8 @@
### Additional documentations
-- [[Scala|http://docs.scala-lang.org/]]
-- [[Akka|http://akka.io/docs/]]
-- [[sbt|http://www.scala-sbt.org/learn.html]]
-- [[Configuration|https://github.com/typesafehub/config]]
-- [[Logback|http://logback.qos.ch/documentation.html]]
+- [Scala](http://docs.scala-lang.org/)
+- [Akka](http://akka.io/docs/)
+- [sbt](http://www.scala-sbt.org/learn.html)
+- [Configuration](https://github.com/typesafehub/config)
+- [Logback](http://logback.qos.ch/documentation.html)
View
6 documentation/manual/detailledTopics/production/HTTPServer.md
@@ -14,7 +14,7 @@ Note that using a front-end HTTP server will rarely give you better performance
## Set-up with lighttpd
-This example shows you how to configure [[lighttpd | http://www.lighttpd.net/]] as a front-end web server. Note that you can do the same with Apache, but if you only need virtual hosting or load balancing, lighttpd is a very good choice and much easier to configure!
+This example shows you how to configure [lighttpd](http://www.lighttpd.net/) as a front-end web server. Note that you can do the same with Apache, but if you only need virtual hosting or load balancing, lighttpd is a very good choice and much easier to configure!
The `/etc/lighttpd/lighttpd.conf` file should define things like this:
@@ -40,7 +40,7 @@ $HTTP["host"] =~ "www.loadbalancedapp.com" {
## Set-up with nginx
-This example shows you how to configure [[nginx| http://wiki.nginx.org/Main]] as a front-end web server. Note that you can do the same with Apache, but if you only need virtual hosting or load balancing, nginx is a very good choice and much easier to configure!
+This example shows you how to configure [nginx](http://wiki.nginx.org/Main) as a front-end web server. Note that you can do the same with Apache, but if you only need virtual hosting or load balancing, nginx is a very good choice and much easier to configure!
The `/etc/nginx/nginx.conf` file should define things like this:
@@ -80,7 +80,7 @@ http {
## Set-up with Apache
-The example below shows a simple set-up with [[Apache httpd server | http://httpd.apache.org/]] running in front of a standard Play configuration.
+The example below shows a simple set-up with [Apache httpd server](http://httpd.apache.org/) running in front of a standard Play configuration.
```
LoadModule proxy_module modules/mod_proxy.so
View
4 documentation/manual/detailledTopics/production/ProductionHeroku.md
@@ -1,6 +1,6 @@
# Deploying to Heroku
-[[Heroku | http://www.heroku.com/]] is a cloud application platform – a new way of building and deploying web apps.
+[Heroku](http://www.heroku.com/) is a cloud application platform – a new way of building and deploying web apps.
To get started:
@@ -113,4 +113,4 @@ This instructs Heroku that for the process named `web` it will run Play and over
* [Optimizing Play 2 for Database-Driven Apps](http://www.jamesward.com/2012/06/25/optimizing-play-2-for-database-driven-apps)
* [Play 2 Scala Console on Heroku](http://www.jamesward.com/2012/06/11/play-2-scala-console-on-heroku)
* [Play 2 App with a Scheduled Job on Heroku](https://github.com/jamesward/play2-scheduled-job-demo)
-* [Using Amazon S3 for File Uploads with Java and Play 2](https://devcenter.heroku.com/articles/using-amazon-s3-for-file-uploads-with-java-and-play-2)
+* [Using Amazon S3 for File Uploads with Java and Play 2](https://devcenter.heroku.com/articles/using-amazon-s3-for-file-uploads-with-java-and-play-2)
View
10 documentation/manual/detailledTopics/production/_Sidebar.md
@@ -31,8 +31,8 @@
### Additional documentations
-- [[Scala|http://docs.scala-lang.org/]]
-- [[Akka|http://akka.io/docs/]]
-- [[sbt|http://www.scala-sbt.org/learn.html]]
-- [[Configuration|https://github.com/typesafehub/config]]
-- [[Logback|http://logback.qos.ch/documentation.html]]
+- [Scala](http://docs.scala-lang.org/)
+- [Akka](http://akka.io/docs/)
+- [sbt](http://www.scala-sbt.org/learn.html)
+- [Configuration](https://github.com/typesafehub/config)
+- [Logback](http://logback.qos.ch/documentation.html)
View
4 documentation/manual/gettingStarted/Anatomy.md
@@ -50,7 +50,7 @@ You can of course add your own packages, for example an `app/utils` package.
> Note that in Play, the controllers, models and views package name conventions are now just that and can be changed if needed (such as prefixing everything with `com.yourcompany`).
-There is also an optional directory called `app/assets` for compiled assets such as [[LESS sources | http://lesscss.org/]] and [[CoffeeScript sources | http://jashkenas.github.com/coffee-script/]].
+There is also an optional directory called `app/assets` for compiled assets such as [LESS sources](http://lesscss.org/) and [CoffeeScript sources](http://jashkenas.github.com/coffee-script/).
## The public/ directory
@@ -106,4 +106,4 @@ dist
.cache
```
-> **Next:** [[Using the Play console | PlayConsole ]]
+> **Next:** [[Using the Play console | PlayConsole ]]
View
4 documentation/manual/gettingStarted/Installing.md
@@ -2,7 +2,7 @@
## Prerequisites
-To run the Play framework, you need [[JDK 6 or later| http://www.oracle.com/technetwork/java/javase/downloads/index.html]].
+To run the Play framework, you need [JDK 6 or later](http://www.oracle.com/technetwork/java/javase/downloads/index.html).
> If you are using MacOS, Java is built-in. If you are using Linux, make sure to use either the Sun JDK or OpenJDK (and not gcj, which is the default Java command on many Linux distros). If you are using Windows, just download and install the latest JDK package.
@@ -12,7 +12,7 @@ Be sure to have the `java` and `javac` commands in the current path (you can che
## Download the binary package
-Download the latest [[Play binary package | http://www.playframework.com/download]] (take the latest official version) and extract the archive to a location where you have both read **and write** access. (Running `play` writes some files to directories within the archive, so don't install to `/opt`, `/usr/local` or anywhere else you’d need special permission to write to.)
+Download the latest [Play binary package](http://www.playframework.com/download) (take the latest official version) and extract the archive to a location where you have both read **and write** access. (Running `play` writes some files to directories within the archive, so don't install to `/opt`, `/usr/local` or anywhere else you’d need special permission to write to.)
## Add the play script to your PATH
View
4 documentation/manual/gettingStarted/NewApplication.md
@@ -28,7 +28,7 @@ $ play
You can also create a new Play application without installing Play, by using sbt.
-> First install [[sbt| http://www.scala-sbt.org/]] if needed.
+> First install [sbt](http://www.scala-sbt.org/) if needed.
Just create a new directory for your new application and configure your sbt build script with two additions.
@@ -79,4 +79,4 @@ $ sbt
sbt will load your project and fetch the dependencies.
-> **Next:** [[Anatomy of a Play application | Anatomy]]
+> **Next:** [[Anatomy of a Play application | Anatomy]]
View
4 documentation/manual/gettingStarted/Samples.md
@@ -24,7 +24,7 @@ This is a classic CRUD application, backed by a JDBC database. It demonstrates:
- accessing a JDBC database, using Ebean in Java and Anorm in Scala
- table pagination and CRUD forms
-- integrating with a CSS framework ([[Twitter Bootstrap | http://twitter.github.com/bootstrap/]]).
+- integrating with a CSS framework ([Twitter Bootstrap](http://twitter.github.com/bootstrap/)).
Twitter Bootstrap requires a different form layout to the default layout provided by the Play 2.0 form helper, so this application also provides an example of integrating a custom form input constructor.
@@ -79,4 +79,4 @@ This mobile web application monitors Play server performance. It demonstrates:
> **Next:**
>
> – [[Play for Scala developers | ScalaHome]]
-> – [[Play for Java developers | JavaHome]]
+> – [[Play for Java developers | JavaHome]]
View
4 documentation/manual/hacking/BuildingFromSource.md
@@ -1,6 +1,6 @@
# Building Play from sources
-To benefit from the latest improvements and bug fixes after the initial beta release, you may want to compile Play from sources. You’ll need a [[Git client | http://git-scm.com/]] to fetch the sources.
+To benefit from the latest improvements and bug fixes after the initial beta release, you may want to compile Play from sources. You’ll need a [Git client](http://git-scm.com/) to fetch the sources.
##Grab the source
From the shell, first checkout the Play sources:
@@ -71,4 +71,4 @@ addSbtPlugin("play" % "sbt-plugin" % "2.1-SNAPSHOT")
to project/plugins.sbt. If you switch from 2.0.x to trunk you must change `build.properties` to contain `sbt.version=0.12.0`
## Using Code in eclipse.
-You can find at [Stackoverflow](http://stackoverflow.com/questions/10053201/how-to-setup-eclipse-ide-work-on-the-playframework-2-0/10055419#10055419) some information how to setup eclipse to work on the code.
+You can find at [Stackoverflow](http://stackoverflow.com/questions/10053201/how-to-setup-eclipse-ide-work-on-the-playframework-2-0/10055419#10055419) some information how to setup eclipse to work on the code.
View
10 documentation/manual/hacking/Documentation.md
@@ -18,6 +18,8 @@ Links to other pages in the documentation should be created using wiki markup sy
Images should also use the above syntax.
+> External links should not use the above syntax, but rather, should use the standard Markdown link syntax.
+
## Code samples
All supported code samples should be imported from external compiled files. The syntax for doing this is:
@@ -98,3 +100,11 @@ At current, SBT code samples cannot be pulled out of the documentation, since co
### Other code
Other code may or may not be testable. It may make sense to test Javascript code by running an integration test using HTMLUnit. It may make sense to test configuration by loading it. Common sense should be used here.
+
+## Testing the docs
+
+To ensure that the docs render correctly, run `./build run` from within the documentation directory. This will start a small Play server that does nothing but serve the documentation.
+
+To ensure that the code samples compile, run and tests pass, run `./build test`.
+
+To validate that the documentation is structurely sound, run `./build validate-docs`. This checks that there are no broken wiki links, code references or resource links, ensures that all documentation markdown filenames are unique, and ensures that there are no orphaned pages.
View
2 documentation/manual/hacking/Issues.md
@@ -2,7 +2,7 @@
We use GitHub as our issue tracker, at:
-[[https://github.com/playframework/Play20/issues]].
+<https://github.com/playframework/Play20/issues>.
## Reporting bugs
View
4 documentation/manual/hacking/Repositories.md
@@ -2,7 +2,7 @@
## Typesafe repository
-All Play artifacts are published to the Typesafe repository at [[http://repo.typesafe.com/typesafe/releases/]].
+All Play artifacts are published to the Typesafe repository at <http://repo.typesafe.com/typesafe/releases/>.
> **Note:** it's a Maven2 compatible repository.
@@ -15,7 +15,7 @@ resolvers += "Typesafe Releases" at "http://repo.typesafe.com/typesafe/releases/
## Accessing snapshots
-Snapshots are published daily from our [[Continuous Server|CIServer]] to the Typesafe snapshots repository at [[http://repo.typesafe.com/typesafe/snapshots/]].
+Snapshots are published daily from our [[Continuous Server|CIServer]] to the Typesafe snapshots repository at <http://repo.typesafe.com/typesafe/snapshots/>.
```
// The Typesafe snapshots repository
View
6 documentation/manual/hacking/ThirdPartyTools.md
@@ -4,12 +4,12 @@ A big THANK YOU! to these sponsors for their support of open source projects.
[[images/cloudbees.png]]
-Our continuous integration runs on [[Cloudbees|http://www.cloudbees.com/]]. We not only run CI on major release and master branches, but we also perform github pull request validation using CloudBees functionality.
+Our continuous integration runs on [Cloudbees](http://www.cloudbees.com/). We not only run CI on major release and master branches, but we also perform github pull request validation using CloudBees functionality.
-[[https://playframework2.ci.cloudbees.com/]]
+<https://playframework2.ci.cloudbees.com/>
# Profiling
[[images/yourkit.png]]
-We are using [[YourKit|http://www.yourkit.com/overview/index.jsp]] for profiling our Java and Scala code. YourKit really helps us keep Play's resource usage to the minimum that you'd expect.
+We are using [YourKit](http://www.yourkit.com/overview/index.jsp) for profiling our Java and Scala code. YourKit really helps us keep Play's resource usage to the minimum that you'd expect.
View
7 documentation/manual/javaGuide/JavaHome.md
@@ -52,7 +52,12 @@ The Java API for the Play application developers is available in the `play` pack
1. [[Writing tests | JavaTest]]
1. [[Writing functional tests | JavaFunctionalTest]]
+## Advanced topics
+
+1. [[Extending Play|JavaPlugins]]
+ 1. [[Writing Plugins|JavaPlugins]]
+
## Tutorials
1. [[Your first application | JavaTodoList]]
-1. [[Zentask | JavaGuide1]]
+1. [[Zentask | JavaGuide1]]
View
4 documentation/manual/javaGuide/_Sidebar.md
@@ -15,6 +15,10 @@
- [[The application Global object | JavaGlobal]]
- [[Testing your application | JavaTest]]
+### Advanced Topics
+
+- [[Extending Play|JavaPlugins]]
+
### Tutorials
- [[Your first application | JavaTodoList]]
View
34 documentation/manual/javaGuide/advanced/extending/JavaPlugins.md
@@ -0,0 +1,34 @@
+# Writing Plugins
+
+Play 2 comes with a few plugins predefined for all applications, these plugins are the following:
+
+* `DBPlugin` -> providing a JDBC datasource
+* `EvolutionPlugin` -> provides migration _(only available if db was configured)_
+* `EbeanPlugin` -> provides Ebean support_ (only available if db was configured)_
+* `MessagesPlugin` - > provides i18n support
+* `BasicCachePlugin` -> provides in-memory caching
+* `GlobalPlugin` -> executes application's settings
+
+However, one can easily add a new plugin to an application by following these steps:
+
+* implement `play.Plugin` (see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/db/ebean/EbeanPlugin.java) for an example)
+* this plugin should be available in the application either through pulling in it from a maven repository and referencing it
+as an app dependency or the plugin code can be part of a play application
+* you can access it like
+
+```java
+import static play.api.Play.*;
+import static play.libs.Scala.*;
+
+public Myplugin plugin() {
+ return orNull(unsafeApplication().plugin(MyPlugin.class)).api();
+}
+```
+
+which will return an instance or subclass of `MyPlugin` fully initialized or `null`.
+
+* in your app create a file: `conf/play.plugins` and add a reference to your plugin:
+
+ 5000:com.example.MyPlugin
+
+The number represents the plugin loading order, by setting it to > 10000 we can make sure it's loaded after the global plugins.
View
4 documentation/manual/javaGuide/main/akka/JavaAkka.md
@@ -1,6 +1,6 @@
# Integrating with Akka
-[[Akka| http://akka.io/]] uses the Actor Model to raise the abstraction level and provide a better platform to build correct concurrent and scalable applications. For fault-tolerance it adopts the ‘Let it crash’ model, which has been used with great success in the telecoms industry to build applications that self-heal - systems that never stop. Actors also provide the abstraction for transparent distribution and the basis for truly scalable and fault-tolerant applications.
+[Akka](http://akka.io/) uses the Actor Model to raise the abstraction level and provide a better platform to build correct concurrent and scalable applications. For fault-tolerance it adopts the ‘Let it crash’ model, which has been used with great success in the telecoms industry to build applications that self-heal - systems that never stop. Actors also provide the abstraction for transparent distribution and the basis for truly scalable and fault-tolerant applications.
## The application actor system
@@ -106,4 +106,4 @@ Akka.system().scheduler().scheduleOnce(
);
```
-> **Next:** [[Internationalization | JavaI18N]]
+> **Next:** [[Internationalization | JavaI18N]]
View
4 documentation/manual/javaGuide/main/async/JavaAsync.md
@@ -25,7 +25,7 @@ Promise<Result> promiseOfResult = promiseOfPIValue.map(
);
```
-> **Note:** Writing functional composition in Java is really verbose for the moment, but it should be better when Java supports [[lambda notation| http://mail.openjdk.java.net/pipermail/lambda-dev/2011-September/003936.html]].
+> **Note:** Writing functional composition in Java is really verbose for the moment, but it should be better when Java supports [lambda notation](http://mail.openjdk.java.net/pipermail/lambda-dev/2011-September/003936.html).
Play 2.0 asynchronous API methods give you a `Promise`. This is the case when you are calling an external web service using the `play.libs.WS` API, or if you are using Akka to schedule asynchronous tasks or to communicate with Actors using `play.libs.Akka`.
@@ -70,4 +70,4 @@ public static Result index() {
> **Note:** `async()` is an helper method building an `AsyncResult` from a `Promise<Result>`.
-> **Next:** [[Streaming HTTP responses | JavaStream]]
+> **Next:** [[Streaming HTTP responses | JavaStream]]
View
4 documentation/manual/javaGuide/main/async/JavaStream.md
@@ -42,7 +42,7 @@ For this kind of response we have to use **Chunked transfer encoding**.
>
> The size of each chunk is sent right before the chunk itself so that a client can tell when it has finished receiving data for that chunk. The data transfer is terminated by a final chunk of length zero.
>
-> [[http://en.wikipedia.org/wiki/Chunked_transfer_encoding]]
+> <http://en.wikipedia.org/wiki/Chunked_transfer_encoding>
The advantage is that we can serve data **live**, meaning that we send chunks of data as soon as they are available. The drawback is that since the web browser doesn’t know the content size, it is not able to display a proper download progress bar.
@@ -106,4 +106,4 @@ bar
We get three chunks and one final empty chunk that closes the response.
-> **Next:** [[Comet sockets | JavaComet]]
+> **Next:** [[Comet sockets | JavaComet]]
View
6 documentation/manual/javaGuide/main/async/JavaWebSockets.md
@@ -10,7 +10,7 @@ Modern web browsers natively support two-way live communication via WebSockets.
>
>WebSocket is designed to be implemented in web browsers and web servers, but it can be used by any client or server application. Because ordinary TCP connections to port numbers other than 80 are frequently blocked by administrators outside of home environments, it can be used as a way to circumvent these restrictions and provide similar functionality with some additional protocol overhead while multiplexing several WebSocket services over a single TCP port. Additionally, it serves a purpose for web applications that require real-time bi-directional communication. Before the implementation of WebSocket, such bi-directional communication was only possible using comet channels; however, a comet is not trivial to implement reliably, and due to the TCP Handshake and HTTP header overhead, it may be inefficient for small messages. The WebSocket protocol aims to solve these problems without compromising security assumptions of the web.
>
-> [[http://en.wikipedia.org/wiki/WebSocket]]
+> <http://en.wikipedia.org/wiki/WebSocket>
## Handling WebSockets
@@ -59,7 +59,7 @@ When the `WebSocket` is ready, you get both `in` and `out` channels.
It this example, we print each message to console and we send a single **Hello!** message.
-> **Tip:** You can test your WebSocket controller on [[http://websocket.org/echo.html]]. Just set the location to `ws://localhost:9000`.
+> **Tip:** You can test your WebSocket controller on <http://websocket.org/echo.html>. Just set the location to `ws://localhost:9000`.
Let’s write another example that totally discards the input data and closes the socket just after sending the **Hello!** message:
@@ -76,4 +76,4 @@ public static WebSocket<String> index() {
}
```
-> **Next:** [[The template engine | JavaTemplates]]
+> **Next:** [[The template engine | JavaTemplates]]
View
2 documentation/manual/javaGuide/main/cache/JavaCache.md
@@ -4,7 +4,7 @@ Caching data is a typical optimization in modern applications, and so Play provi
For any data stored in the cache, a regeneration strategy needs to be put in place in case the data goes missing. This philosophy is one of the fundamentals behind Play, and is different from Java EE, where the session is expected to retain values throughout its lifetime.
-The default implementation of the cache API uses [[EHCache| http://www.ehcache.org/]] and it's enabled by default. You can also provide your own implementation via a plugin.
+The default implementation of the cache API uses [EHCache](http://www.ehcache.org/) and it's enabled by default. You can also provide your own implementation via a plugin.
## Accessing the Cache API
View
2 documentation/manual/javaGuide/main/forms/JavaFormHelpers.md
@@ -84,7 +84,7 @@ This default field constructor supports additional options you can pass in the i
## Twitter bootstrap field constructor
-There is another built-in field constructor that can be used with [[Twitter Bootstrap | http://twitter.github.com/bootstrap/]].
+There is another built-in field constructor that can be used with [Twitter Bootstrap](http://twitter.github.com/bootstrap/).
To use it, just import it in the current scope:
View
2 documentation/manual/javaGuide/main/forms/JavaForms.md
@@ -15,7 +15,7 @@ public class User {
Form<User> userForm = form(User.class);
```
-> **Note:** The underlying binding is done using [[Spring data binder| http://static.springsource.org/spring/docs/3.0.7.RELEASE/reference/validation.html]].
+> **Note:** The underlying binding is done using [Spring data binder](http://static.springsource.org/spring/docs/3.0.7.RELEASE/reference/validation.html).
This form can generate a `User` result value from `HashMap<String,String>` data:
View
4 documentation/manual/javaGuide/main/http/JavaContentNegotiation.md
@@ -1,6 +1,6 @@
# Content negotiation
-Content negotiation is a mechanism that makes it possible to serve different representation of a same resource (URI). It is useful *e.g.* for writing Web Services supporting several output formats (XML, JSON, etc.). Server-driven negotiation is essentially performed using the `Accept*` requests headers. You can find more information on content negotiation in the [[HTTP specification|http://www.w3.org/Protocols/rfc2616/rfc2616-sec12.html]].
+Content negotiation is a mechanism that makes it possible to serve different representation of a same resource (URI). It is useful *e.g.* for writing Web Services supporting several output formats (XML, JSON, etc.). Server-driven negotiation is essentially performed using the `Accept*` requests headers. You can find more information on content negotiation in the [HTTP specification](http://www.w3.org/Protocols/rfc2616/rfc2616-sec12.html).
## Language
@@ -25,4 +25,4 @@ public static Result list() {
}
```
-> **Next:** [[Asynchronous HTTP programming | JavaAsync]]
+> **Next:** [[Asynchronous HTTP programming | JavaAsync]]
View
4 documentation/manual/javaGuide/main/sql/JavaEbean.md
@@ -2,7 +2,7 @@
## Configuring Ebean
-Play 2.0 comes with the [[Ebean| http://www.avaje.org/]] ORM. To enable it, add javaEbean to your
+Play 2.0 comes with the [Ebean](http://www.avaje.org/) ORM. To enable it, add javaEbean to your
dependencies :
```scala
@@ -48,7 +48,7 @@ public class MyServerConfigStartup implements ServerConfigStartup {
Note that Ebean will also make use of a `conf/orm.xml` file (if present), to configure `<entity-mappings>`.
-> For more information about Ebean, see the [[Ebean documentation | http://www.avaje.org/ebean/documentation.html]].
+> For more information about Ebean, see the [Ebean documentation](http://www.avaje.org/ebean/documentation.html).
## Using the play.db.ebean.Model superclass
View
2 documentation/manual/javaGuide/main/tests/JavaFunctionalTest.md
@@ -63,7 +63,7 @@ public void testInServer() {
## Testing from within a web browser
-If you want to test your application from with a Web browser, you can use [[Selenium WebDriver| http://code.google.com/p/selenium/?redir=1]]. Play will start the WebDriver for your, and wrap it in the convenient API provided by [[FluentLenium|https://github.com/FluentLenium/FluentLenium]].
+If you want to test your application from with a Web browser, you can use [Selenium WebDriver](http://code.google.com/p/selenium/?redir=1). Play will start the WebDriver for your, and wrap it in the convenient API provided by [FluentLenium](https://github.com/FluentLenium/FluentLenium).
```
@Test
View
4 documentation/manual/javaGuide/main/tests/JavaTest.md
@@ -4,7 +4,7 @@ Test source files must be placed in your application’s `test` folder. You can
## Using JUnit
-The default way to test a Play 2 application is with [[JUnit| http://www.junit.org/]].
+The default way to test a Play 2 application is with [JUnit](http://www.junit.org/).
```
package test;
@@ -66,4 +66,4 @@ fakeApplication(inMemoryDatabase())
> compile in Test <<= PostCompile(Test)
> ```
-> **Next:** [[Writing functional tests | JavaFunctionalTest]]
+> **Next:** [[Writing functional tests | JavaFunctionalTest]]
View
4 documentation/manual/javaGuide/main/ws/JavaOpenID.md
@@ -1,6 +1,6 @@
# OpenID Support in Play
-OpenID is a protocol for users to access several services with a single account. As a web developer, you can use OpenID to offer users a way to login with an account they already have (their [[Google account | http://code.google.com/apis/accounts/docs/OpenID.html]] for example). In the enterprise, you can use OpenID to connect to a company's SSO server if it supports it.
+OpenID is a protocol for users to access several services with a single account. As a web developer, you can use OpenID to offer users a way to login with an account they already have (their [Google account](http://code.google.com/apis/accounts/docs/OpenID.html) for example). In the enterprise, you can use OpenID to connect to a company's SSO server if it supports it.
## The OpenID flow in a nutshell
@@ -24,7 +24,7 @@ In any case, you should catch exceptions and if one is thrown redirect back the
## Extended Attributes
-The OpenID of a user gives you his identity. The protocol also support getting [[extended attributes | http://openid.net/specs/openid-attribute-exchange-1_0.html]] such as the email address, the first name, the last name...
+The OpenID of a user gives you his identity. The protocol also support getting [extended attributes](http://openid.net/specs/openid-attribute-exchange-1_0.html) such as the email address, the first name, the last name...
You may request from the OpenID server *optional* attributes and/or *required* attributes. Asking for required attributes means the user can not login to your service if he doesn't provides them.
View
6 documentation/manual/javaGuide/tutorials/todolist/JavaTodoList.md
@@ -50,7 +50,7 @@ This launches the Play console. There are several things you can do from the Pla
[[images/run.png]]
-Now the application is running in development mode. Open a browser at [[http://localhost:9000/]]:
+Now the application is running in development mode. Open a browser at <http://localhost:9000/>:
[[images/welcome.png]]
@@ -185,7 +185,7 @@ public class Application extends Controller {
As you see we use `TODO` as result in our actions implementation. Because we don’t want to write the actions implementation yet, we can use the built-in `TODO` result that will return a `501 Not Implemented` response.
-You can try to access the [[http://localhost:9000/tasks]] to see that:
+You can try to access the <http://localhost:9000/tasks> to see that:
[[images/todo.png]]
@@ -323,7 +323,7 @@ public static Result tasks() {
It renders a **200 OK** result filled with the HTML rendered by the `index.scala.html` template called with the tasks list and the task form.
-You can now try to access [[http://localhost:9000/tasks]] in your browser:
+You can now try to access <http://localhost:9000/tasks> in your browser:
[[images/blank.png]]
View
2 documentation/manual/javaGuide/tutorials/zentasks/JavaGuide6.md
@@ -514,4 +514,4 @@ So now we have a working and tested navigation drawer. We've seen how to impleme
Commit your work to git.
-> Go to the [next part](JavaGuide7)
+> Go to the [[next part|JavaGuide7]]
View
9 documentation/manual/sandbox/Declare-anonymous-function-in-templates.md
@@ -1,9 +0,0 @@
-Sometimes you need to declare a variable in your template, but since we're more in a functional environnement we will prefer to declare an anonymous function thanks to `@using(){}` :
-
- <ul>
- @using( Map(...) ){ values =>
- @for( toto <- values ){
- <li>toto</li>
- }
- }
- </ul>
View
14 documentation/manual/sandbox/Javacaching.md
@@ -1,14 +0,0 @@
-# Caching
-
-an in-memory cache with expiry support is provided by Play.
-
-_Note: By default, this implementation is used for Play's internal caching as well_
-
-The Java API with information about the usage can be found [here](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/cache/Cache.java)
-
-# Plugging in your own
-The following simple steps need to be taken if one would like to implement a different caching solution
-
-1. set ```cache.default=disabled``` in ```application.conf```
-2. implement ```play.api.CacheAPI``` interface
-3. implement ```play.api.Plugin``` and enable your plugin
View
42 documentation/manual/sandbox/Javacookies.md
@@ -1,42 +0,0 @@
-# Using cookies
-
-## Request’s cookies
-
-You can retrieve the request’s cookies using the `cookies()` method of a `Http.Request` object:
-
-```java
-public class Application extends Controller {
-
- public static Result index() {
- Http.Cookie cookie = request().cookies().get("foo");
- if (cookie.value().equals("bar")) {
- // ...
- }
- }
-}
-```
-
-The `get(String name)` method returns the cookie or `null` if there was no such cookie. See the [API documentation](http://playframework.github.com/api/java/play/mvc/Http.html) of the `Http.Cookie` class to know what information is available on cookies.
-
-## Response’s cookies
-
-Setting cookies and discarding them is performed through the `setCookie` and `discardCookies` methods of the `Http.Response` object:
-
-```java
-public class Application extends Controller {
-
- public static Result index() {
-
- // Set cookies
- response().setCookie("bar", "baz");
- response().setCookie("bar", "baz", 3600);
-
- // Discard cookies
- response().discardCookies("foo", "bar");
-
- // ...
- }
-}
-```
-
-See the various overloaded versions of the `setCookie` method in the [API documentation](http://playframework.github.com/api/java/play/mvc/Http.Response.html) to know all the possible combinations of parameters.
View
49 documentation/manual/sandbox/Javahttp.md
@@ -1,49 +0,0 @@
-# Making HTTP Requests
-
-Sometimes we would like to call other HTTP services from within a play application. Play supports this task via its ```play.libs.WS``` library which provides a way to make asynchronous HTTP calls.
-
-Any calls made by ```play.libs.WS``` should return a ``` play.libs.F.Promise<play.libs.WS.Response>``` which we can later handle with play's asynchronous mechanisms.
-
-# A short introduction
-
-## Hello Get
-```java
-import play.libs.*;
-
-F.Promise<WS.Response> promise = WS.url("http://mysite.com").get();
-
-WS.Response res = promise.get();
-
-String body = res.getBody();
-
-int status = res.getStatus();
-
-String contentType = res.getHeader("Content-Type");
-
-org.w3c.dom.Document doc = res.asXml();
-
-com.fasterxml.jackson.databind.JsonNode json = res.asJson();
-
-```
-
-_Note: in this example we used ```play.libs.F.Promise#get``` to retrieve the result of the promise in a blocking fashion, however, since this is an async call, one might want to avoid blocking by handling the promise via ```play.libs.F.Promise#onRedeem``` callback or ```play.libs.F.Promise#map``` or even ```play.libs.F.Promise#flatMap```._
-
-_[Please consult the javadoc for more information](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/libs/F.java)_
-
-
-## Hello Post
-```java
-import play.libs.*;
-import com.ning.http.client.Realm;
-
-F.Promise<WS.Response> jpromise = WS.url("http://mysite.com/post")
- .setHeader("Content-Type","application/x-www-form-urlencoded")
- .setAuth("peter","superSecret",Realm.AuthScheme.SPNEGO)
- .setQueryParam("myqparam","1")
- .post("param1=foo");
-String body = jpromise.get().getBody();
-//and body should contain AnyContentAsUrlFormEncoded
-
-```
-
-For more information please see the api doc [here](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/libs/WS.java)
View
44 documentation/manual/sandbox/Javajson.md
@@ -1,44 +0,0 @@
-# JSON support
-
-Play includes the [Jackson](http://jackson.codehaus.org/) library as a dependency _(A good tutorial of Jackson can be found [here](http://wiki.fasterxml.com/JacksonInFiveMinutes))_. What this means in practice is that one can serialize from and to JSON format.
-
-# Render JSON
-As for rendering JSON, there is a helper method ```play.json.Render.toJson``` that can be used to send JSON as a response. For example:
-
-```
-import play.*;
-import play.mvc.*;
-import static play.libs.Json.toJson;
-
-import java.util.Map;
-import java.util.HashMap;
-
-public class MyController extends Controller {
-
- public static Result index() {
- Map<String,String> d = new HashMap<String,String>();
- d.put("peter","foo");
- d.put("yay","value");
- return ok(toJson(d));
- }
-}
-```
-
-# Google Guava
-The code above can be rewritten for brevity using the Google Guava collections library:
-
-```
-import com.google.common.collect.ImmutableMap;
-import play.*;
-import play.mvc.*;
-import static play.libs.Json.toJson;
-
-public class MyController extends Controller {
-
- public static Result index() {
- return ok(toJson(ImmutableMap.of(
- "peter", "foo",
- "yay", "value")));
- }
-}
-```
View
13 documentation/manual/sandbox/Javaplayaslibrary.md
@@ -1,13 +0,0 @@
-# Building on top of Play
-
-_Note: this is a somewhat advanced topic, most users safely can ignore this_
-
-While one can really take advantage of most play features while building a full application from scratch using play, it's very easy to drop play into existing sbt/maven projects and with just a little work use it as a REST/HTTP library. Below you can see how to do that.
-
-# Rolling your own
-
-Because play2's core is written in scala, the easiest way to provide a Java API is by creating the required API in scala.
-
-In practice it means that one needs to extend ```GobalSettings``` as ```Global``` in the global name space. ```GobalSettings``` has a method ``` def onRouteRequest(request: RequestHeader): Option[Handler] ``` that's handling play's routing. Once an alternative implementation is in place, play can be used as a REST/HTTP library!
-
-an annotation based basic implementation can be found [here](https://github.com/typesafehub/play2-mini/blob/master/src/main/scala/com/typesafe/play/mini/Setup.scala#L58) for an example.
View
32 documentation/manual/sandbox/Javaplugin.md
@@ -1,32 +0,0 @@
-# Writing Plugins
-
-Play 2.0 comes with a few plugins predefined for all applications, these plugins are the following:
-
-* ```DBPlugin``` -> providing a JDBC datasource
-* ```EvolutionPlugin``` -> provides migration _(only available if db was configured)_
-* ```EbeanPlugin``` -> provides Ebean support_ (only available if db was configured)_
-* ```MessagesPlugin``` - > provides i18n support
-* ```BasicCachePlugin``` -> provides in-memory caching
-* ```GlobalPlugin``` -> executes application's settings
-
-However, one can easily add a new plugin to an application by following these steps:
-
-* implement ```play.Plugin``` (see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/db/ebean/EbeanPlugin.java) for an example)
-* this plugin should be available in the application either through pulling in it from a maven repository and referencing it
-as an app dependency or the plugin code can be part of a play application
-* you can access it like
-
-```java
-import static play.api.Play.*;
-import static play.libs.Scala.*;
-
-public Myplugin plugin() {
- return orNull(unsafeApplication().plugin(MyPlugin.class)).api();
-}
-```
-
-which will return an instance or subclass of ```MyPlugin``` fully initialized or ```null```.
-
-* in your app create a file: ```conf/play.plugins``` and add a reference to your plugin, just like this ```5000:com.example.MyPlugin```
-
-_the number represents the plugin loading order, by setting it to > 10000 we can make sure it's loaded after the global plugins_
View
3 documentation/manual/sandbox/Missing.md
@@ -1,3 +0,0 @@
-# Missing parts
-
-Model Syntax
View
73 documentation/manual/sandbox/Scalacache.md
@@ -1,73 +0,0 @@
-# The Play cache API
-
-The default implementation of the Cache API uses EHCache and it's enabled by default. You can also provide your own implementation via a plug-in.
-
-# Accessing the Cache API
-The cache API is provided by the play.api.cache.Cache object. It requires a registered cache plug-in.
-
-> **Note:** The API is intentionally minimal to allow several implementation to be plugged. If you need a more specific API, use the one provided by your Cache plugin.
-
-Using this simple API you can either store data in cache:
-
-```
-Cache.set("item.key", connectedUser)
-```
-
-And then retrieve it later:
-
-```
-val maybeUser: Option[User] = Cache.getAs[User]("item.key")
-```
-
-There is also a convenient helper to retrieve from cache or set the value in cache if it was missing:
-
-```scala
-val user: User = Cache.getOrElse[User]("item.key") {
- User.findById(connectedUser)
-}
-```
-
-How to remove the key is as follows. (Note: the Play 2.0 removal method is from the [Google Groups Conversation](https://groups.google.com/d/msg/play-framework/pHb1Dq1wiic/TTOXVzsa7VkJ) given that Ehcache allows nulls internally).
-
-```
-// 2.0 final
-import play.api.cache.{EhCachePlugin, Cache}
-import play.api.Play
-Play.current.plugin[EhCachePlugin].map {
- ehcache =>
- ehcache.cache.remove(key)
-}.getOrElse(false)
-// later
-Cache.remove("item.key")
-
-```
-
-# Caching HTTP responses
-
-You can easily create smart cached actions using standard Action composition.
-
-> **Note:** Play HTTP Result instances are safe to cache and reuse later.
-
-Play provides a default built-in helper for standard cases:
-
-```scala
-def index = Cached("homePage") {
- Action {
- Ok("Hello world")
- }
-}
-```
-
-Or even:
-
-```scala
-def userProfile = Authenticated { user =>
- Cached(req => "profile." + user) {
- Action {
- Ok(views.html.profile(User.find(user)))
- }
- }
-}
-```
-
-> **Next:** [[Calling WebServices | ScalaWS]]
View
13 documentation/manual/sandbox/Scalaextend.md
@@ -1,13 +0,0 @@
-# Building on top of Play
-
-_Note: this is a somewhat advanced topic, most users safely can ignore this_
-
-While one can really take advantage of most play features while building a full application from scratch using play, it's very easy to drop play into existing sbt/maven projects and with just a little work use it as a REST/HTTP library. Below you can see how to do that.
-
-# Rolling your own
-
-A ```Global``` object extending ```GlobalSettings``` in the global name space is the key wiring point. GlobalSettings has a method ``` def onRouteRequest(request: RequestHeader): Option[Handler] ``` that's handling play's routing.
-
-One could easily provide an alternative implementation and start using play as a REST library!
-
-See [this](https://github.com/typesafehub/play2-mini/blob/master/src/main/scala/com/typesafe/play/mini/Setup.scala) for an example.
View
38 documentation/manual/sandbox/Scalahttp.md
@@ -1,38 +0,0 @@
-# Making HTTP Requests
-
-Sometimes we would like to call other HTTP services from within a play application. Play supports this task via its ```play.api.libs.ws.WS``` library which provides a way to make asynchronous HTTP calls.
-
-Any calls made by ```play.api.libs.ws.WS``` should return a ```play.api.libs.concurrent.Promise[play.api.libs.ws.Request]``` which we can later handle with play's asynchronous mechanisms.
-
-# A short introduction
-
-## Hello Get
-```scala
-import play.api.libs.ws._
-//let's try to retrive the value from the promise within 5sec
-val myfeed: Promise[Response] = WS.url("http://mysite.com").get()
-
-val content: String = myfeed.await(5000).get.body
-
-val content: xml.Elem = myfeed.await(5000).get.xml
-
-val content: JsValue = myfeed.await(5000).get.json
-
-val code = myfeed.await(5000).get.status
-```
-
-## Hello Post
-```scala
-
-//send data as text
-val content: String = WS.url("http://localhost:9001/post").post("content").await(5000).get.body
-content must contain ("content")
-content must contain("AnyContentAsText")
-
-//or as x-www-application/form-urlencoded
-val contentForm: String = WS.url("http://localhost:9001/post").post(Map("param1"->Seq("foo"))).await(5000).get.body
-contentForm must contain ("AnyContentAsUrlFormEncoded")
-contentForm must contain ("foo")
-```
-
-one also can add custom request and authentication headers and even a signature. For more information please see the api doc [here](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/libs/ws/WS.scala)
View
24 documentation/manual/sandbox/Scalaplugin.md
@@ -1,24 +0,0 @@
-# Writing Plugins
-
-Play 2.0 comes with a few plugins predefined for all applications, these plugins are the following:
-
-* ```DBPlugin``` -> providing a JDBC datasource
-* ```EvolutionPlugin``` -> provides migration _(only available if db was configured)_
-* ```EbeanPlugin``` -> provides Ebean support _(only available if db was configured)_
-* ```MessagesPlugin``` - > provides i18n support
-* ```BasicCachePlugin``` -> provides in-memory caching
-* ```GlobalPlugin``` -> executes application's settings
-
-However, one can easily add a new plugin to an application.
-
-1. first step is to implement play.api.Plugin trait which has three methods: onStart, onStop and enabled - [for example](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala))
-2. this plugin should be available in the application either through pulling in it from a maven repository and referencing it
-as an app dependency or the plugin code can be part of a play application
-3. you can use it directly like ```app.plugin[MyPlugin].map(_.api.mymethod).getOrElse(throwMyerror)``` (where ```app``` is a reference to the current application which can be obtain by importing play.api.Play.current) however, it's recommended to wrap it for convenience (for example, see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala))
-4. in your app create a file: ``conf/play.plugins``` and add a reference to your plugin, just like this ```5000:com.example.MyPlugin```
-
-
-_the number represents the plugin loading order, by setting it to > 10000 we can make sure it's loaded after the global plugins_
-
-_Tip: If you are a scala developer but you want to share your plugin with java developers, you will need make sure your API is wrapped for Java users (see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala) and [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/cache/Cache.java) for an example)_
-
View
39 documentation/manual/sandbox/Status.md
@@ -1,39 +0,0 @@
-# Play 2.0 current status
-
-Play 2.0 beta is a preview of the next major version of the Play framework, which integrates a brand new build system and an awesome asynchronous architecture, all with native Java and Scala support.
-
-You can start writing Play 2.0 applications right now with the beta version. It will give you an almost complete preview of the Play 2.0 experience: including the native Scala support, the new possibilities provided by the sbt integration, and the new controller/action API.
-
-Play 2.0 beta is not, however, ready to run production applications.
-
-## What’s missing?
-
-We have worked hard to reach this beta version and are halfway to the final 2.0 version. The following features are the most important items we will be working on now.
-
-### Support for more content types out of the box
-
-Currently we only support parsing classical URL form-encoded HTTP requests. We will add out-of-the-box support for major content types like JSON, XML and file uploads.
-
-### Asynchronous support
-
-Play 2.0 is built from the ground up with reactiveness and optimised resource consumption in mind. We will add a public API for these features to make asynchronous reactive responses, streaming and WebSocket programming really simple.
-
-### Testing
-
-We have basic [[specs | http://code.google.com/p/specs/]] and [[JUnit | http://www.junit.org/]] integration for now. We will add a better API for testing your web applications, either with unit tests or integration tests based on the [[Selenium WebDriver | http://seleniumhq.org/projects/webdriver/]].
-
-### External HTTP libraries
-
-As in Play 1.x, Play 2.0 will provide out of the box integration with a powerful Web Service client, as well as OpenID and OAuth support.
-
-### IDE integration
-
-Currently there is no simple way to integrate your Play 2.0 project in your favorite IDE - you must configure it yourself (or install an sbt plugin like [[sbt-idea | https://github.com/mpeltonen/sbt-idea]]). But we will be adding the cool 'eclipsify', 'netbeansify' and 'idealize' tasks to the Play console.
-
-### WAR support
-
-We also plan to add WAR deployment support via Servlet 3.0.
-
-### And of course, everything that makes a great release
-
-… including more validators, binders, better documentation, tutorials and awesome sample applications.
View
72 documentation/manual/sandbox/Tips.md
@@ -1,72 +0,0 @@
-# Play 2.0 tips and tricks
-
-## To use Play Framework 2 with Twitter Bootstrap 2:
-
-### Renaming the Bootstrap include files
-* Build Play from trunk (2.1-SNAPSHOT) (Since less version has been updated to 1.3)
-* Copy bootstrap's less files into `app/assets/stylesheets/bootstrap`
-* Add `bootstrap/_` before each `bootstrap.less` import declaration and rename each file the same way ( This is the convention to not compile theses files while packaging compiled assets )
-* Move `bootstrap.less` file into `app/assets/stylesheets`
-
-This can be done with a script like this (run in `app/assets/stylesheets/bootstrap`)
-
-```bash
- for a in *.less; do mv $a _$a; done
- sed -i 's|@import "|@import "bootstrap/_|' _bootstrap.less
- mv _bootstrap.less ../bootstrap.less
- sed -i 's|@import "|@import "bootstrap/_|' _responsive.less
- mv _responsive.less ../bootstrap-responsive.less
-```
-
-### Alternative: using the `Build.scala` configuration file
-* Copy bootstrap's less files into `app/assets/stylesheets/bootstrap`
-* Modify the `project/Build.scala` file to filter out the Bootstrap LESS files we *don't* want to compile:
-
-* Define a new [BuildPath](http://www.scala-sbt.org/release/docs/Detailed-Topics/Paths) resolver function:
-
-```scala
- // Only compile the bootstrap bootstrap.less file and any other *.less file in the stylesheets directory
- def customLessEntryPoints(base: File): PathFinder = (
- (base / "app" / "assets" / "stylesheets" / "bootstrap" * "bootstrap.less") +++
- (base / "app" / "assets" / "stylesheets" * "*.less")
- )
-```
-
-*Note:* this will only compile `stylesheets/bootstrap/bootstrap.less` and `stylesheets/*.less` files. If you have any other LESS files in other subdirectories under `stylesheets`; adjust the function accordingly.
-
-* Override the default `lessEntryPoints` setting key with the new function:
-
-```scala
- val main = play.Project(appName, appVersion, appDependencies).settings(
- lessEntryPoints <<= baseDirectory(customLessEntryPoints)
- )
-```
-
-## In both cases...
-
-* Include the `bootstrap.min.css` file in your view(s):
-
-```html
-<link rel="stylesheet" media="screen" href="@routes.Assets.at("stylesheets/bootstrap/bootstrap.min.css")" />
-```
-
-* Move the bootstrap 'img/' directory to somewhere in $PROJECT_ROOT/public/images/ and change `@iconSpritePath` and `@iconWhiteSpritePath` in variables.less (or _variables.less) to point there.
- * For example, if you move the images to $PROJECT_ROOT/public/images/bootstrap/, the variables become:
-
-```css
-@iconSpritePath: "/assets/images/bootstrap/glyphicons-halflings.png";
-@iconWhiteSpritePath: "/assets/images/bootstrap/glyphicons-halflings-white.png";
-```
-
-* Include all the JavaScript files. Run this from your assets directory to get the code necessary to include all of the JavaScript files. Add the output of this command to the bottom of your template, before the `</body>` tag:
-
-```shell
-for i in `ls javascripts/*`; do echo '<script src="@routes.Assets.at("'$i'")"></script>' | sed 's/\.js/.min.js/g'; done
-```
-
-* Be aware that Less 1.3 has a bug in it that means that if you have a subdirectory reference in a LESS file, you may get
-"charAt" errors (see https://github.com/cloudhead/less.js/issues/723 for more details).
-
-## MongoDB
-
-When using [Salat](https://github.com/novus/salat), make sure to disable SQL evolutions in your `application.conf` via `evolutionplugin=disabled` or you will run into inexplicable ClassCastExceptions.
View
3 documentation/manual/scalaGuide/ScalaHome.md
@@ -52,7 +52,6 @@ The Scala API for Play application developers is available in the `play.api` pac
1. [[The application Global object | ScalaGlobal]]
1. [[Application global settings | ScalaGlobal]]
1. [[Intercepting requests | ScalaInterceptors]]
- 1. [[Dependency injection of controllers | ScalaDependencyInjection]]
1. [[Testing your application | ScalaTest]]
1. [[Writing tests | ScalaTest]]
1. [[Writing functional tests | ScalaFunctionalTest]]
@@ -68,6 +67,8 @@ The Scala API for Play application developers is available in the `play.api` pac
1. [[HTTP Filters | ScalaHttpFilters]]
1. [[Reverse routing | ScalaJavascriptRouting]]
1. [[Javascript Routing | ScalaJavascriptRouting]]
+1. [[Extending Play|ScalaPlugins]]
+ 1. [[Writing Plugins|ScalaPlugins]]
## Tutorials
View
1 documentation/manual/scalaGuide/_Sidebar.md
@@ -20,6 +20,7 @@
- [[Handling data streams reactively | Iteratees]]
- [[HTTP API | HttpApi]]
- [[HTTP Filters | ScalaHttpFilters]]
+- [[Extending Play|ScalaPlugins]]
### Tutorials
View
25 documentation/manual/scalaGuide/advanced/extending/ScalaPlugins.md
@@ -0,0 +1,25 @@
+# Writing Plugins
+
+Play 2.0 comes with a few plugins predefined for all applications, these plugins are the following:
+
+* `DBPlugin` -> providing a JDBC datasource
+* `EvolutionPlugin` -> provides migration _(only available if db was configured)_
+* `EbeanPlugin` -> provides Ebean support _(only available if db was configured)_
+* `MessagesPlugin` - > provides i18n support
+* `BasicCachePlugin` -> provides in-memory caching
+* `GlobalPlugin` -> executes application's settings
+
+However, one can easily add a new plugin to an application.
+
+1. first step is to implement play.api.Plugin trait which has three methods: onStart, onStop and enabled - [for example](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala))
+2. this plugin should be available in the application either through pulling in it from a maven repository and referencing it
+as an app dependency or the plugin code can be part of a play application
+3. you can use it directly like `app.plugin[MyPlugin].map(_.api.mymethod).getOrElse(throwMyerror)` (where `app` is a reference to the current application which can be obtain by importing play.api.Play.current) however, it's recommended to wrap it for convenience (for example, see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala))
+4. in your app create a file: `conf/play.plugins` and add a reference to your plugin:
+
+ 5000:com.example.MyPlugin
+
+The number represents the plugin loading order, by setting it to > 10000 we can make sure it's loaded after the global plugins.
+
+_Tip: If you are a scala developer but you want to share your plugin with java developers, you will need make sure your API is wrapped for Java users (see [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/scala/play/api/cache/Cache.scala) and [this](https://github.com/playframework/Play20/blob/master/framework/src/play/src/main/java/play/cache/Cache.java) for an example)_
+
View
2 documentation/manual/scalaGuide/main/akka/ScalaAkka.md
@@ -1,6 +1,6 @@
# Integrating with Akka
-[[Akka| http://akka.io/]] uses the Actor Model to raise the abstraction level and provide a better platform to build correct concurrent and scalable applications. For fault-tolerance it adopts the ‘Let it crash’ model, which has been used with great success in the telecoms industry to build applications that self-heal - systems that never stop. Actors also provide the abstraction for transparent distribution and the basis for truly scalable and fault-tolerant applications.
+[Akka](http://akka.io/) uses the Actor Model to raise the abstraction level and provide a better platform to build correct concurrent and scalable applications. For fault-tolerance it adopts the ‘Let it crash’ model, which has been used with great success in the telecoms industry to build applications that self-heal - systems that never stop. Actors also provide the abstraction for transparent distribution and the basis for truly scalable and fault-tolerant applications.
## The application actor system
View
4 documentation/manual/scalaGuide/main/async/ScalaStream.md
@@ -120,7 +120,7 @@ For this kind of response we have to use **Chunked transfer encoding**.
>
> The size of each chunk is sent right before the chunk itself, so that a client can tell when it has finished receiving data for that chunk. Data transfer is terminated by a final chunk of length zero.
>
-> [[http://en.wikipedia.org/wiki/Chunked_transfer_encoding]]
+> <http://en.wikipedia.org/wiki/Chunked_transfer_encoding>
The advantage is that we can serve the data **live**, meaning that we send chunks of data as soon as they are available. The drawback is that since the web browser doesn’t know the content size, it is not able to display a proper download progress bar.
@@ -187,4 +187,4 @@ bar
We get three chunks followed by one final empty chunk that closes the response.
-> **Next:** [[Comet sockets | ScalaComet]]
+> **Next:** [[Comet sockets | ScalaComet]]
View
4 documentation/manual/scalaGuide/main/async/ScalaWebSockets.md
@@ -14,7 +14,7 @@ Modern web browsers natively support two-way live communication via WebSockets.
>
>WebSocket is also useful for web applications that require real-time bi-directional communication. Before the implementation of WebSocket, such bi-directional communication was only possible using Comet channels; however, Comet is not trivial to implement reliably, and due to the TCP handshaking and HTTP header overhead, it may be inefficient for small messages. The WebSocket protocol aims to solve these problems without compromising the web’s security assumptions.
>
-> [[http://en.wikipedia.org/wiki/WebSocket]]
+> <http://en.wikipedia.org/wiki/WebSocket>
## Handling WebSockets
@@ -46,7 +46,7 @@ When constructing a `WebSocket` this way, we must return both `in` and `out` cha
It this example we are creating a simple iteratee that prints each message to console. To send messages, we create a simple dummy enumerator that will send a single **Hello!** message.
-> **Tip:** You can test WebSockets on [[http://websocket.org/echo.html]]. Just set the location to `ws://localhost:9000`.
+> **Tip:** You can test WebSockets on <http://websocket.org/echo.html>. Just set the location to `ws://localhost:9000`.
Let’s write another example that discards the input data and closes the socket just after sending the **Hello!** message:
View
2 documentation/manual/scalaGuide/main/cache/ScalaCache.md
@@ -1,6 +1,6 @@
# The Play cache API
-The default implementation of the Cache API uses [[EHCache| http://ehcache.org/]]. You can also provide your own implementation via a plug-in.
+The default implementation of the Cache API uses [EHCache](http://ehcache.org/). You can also provide your own implementation via a plug-in.
## Accessing the Cache API
View
2 documentation/manual/scalaGuide/main/forms/ScalaFormHelpers.md
@@ -84,7 +84,7 @@ This default field constructor supports additional options you can pass in the i
## Twitter bootstrap field constructor
-There is also another built-in field constructor that can be used with [[TwitterBootstrap | http://twitter.github.com/bootstrap/]] 1.4. (Note: 2.0.2 will support LESS 1.3 and Bootstrap 2.0.)
+There is also another built-in field constructor that can be used with [TwitterBootstrap](http://twitter.github.com/bootstrap/) 1.4. (Note: 2.0.2 will support LESS 1.3 and Bootstrap 2.0.)
To use it, just import it in the current scope:
View
4 documentation/manual/scalaGuide/main/http/ScalaContentNegotiation.md
@@ -1,6 +1,6 @@
# Content negotiation
-Content negotiation is a mechanism that makes it possible to serve different representation of a same resource (URI). It is useful *e.g.* for writing Web Services supporting several output formats (XML, JSON, etc.). Server-driven negotiation is essentially performed using the `Accept*` requests headers. You can find more information on content negotiation in the [[HTTP specification|http://www.w3.org/Protocols/rfc2616/rfc2616-sec12.html]].
+Content negotiation is a mechanism that makes it possible to serve different representation of a same resource (URI). It is useful *e.g.* for writing Web Services supporting several output formats (XML, JSON, etc.). Server-driven negotiation is essentially performed using the `Accept*` requests headers. You can find more information on content negotiation in the [HTTP specification](http://www.w3.org/Protocols/rfc2616/rfc2616-sec12.html).
# Language
@@ -38,4 +38,4 @@ render {
}
```
-> **Next:** [[Asynchronous HTTP programming | ScalaAsync]]
+> **Next:** [[Asynchronous HTTP programming | ScalaAsync]]
View
2 documentation/manual/scalaGuide/main/sql/ScalaAnorm.md
@@ -4,7 +4,7 @@ Play includes a simple data access layer called Anorm that uses plain SQL to int
**Anorm is Not an Object Relational Mapper**
-> In the following documentation, we will use the [[MySQL world sample database | http://dev.mysql.com/doc/index-other.html]].
+> In the following documentation, we will use the [MySQL world sample database](http://dev.mysql.com/doc/index-other.html).
>
> If you want to enable it for your application, follow the MySQL website instructions, and configure it as explained [[on the Scala database page | ScalaDatabase]].
View
6 documentation/manual/scalaGuide/main/sql/ScalaDatabase.md
@@ -35,7 +35,7 @@ db.default.driver=org.h2.Driver
db.default.url="jdbc:h2:/path/to/db-file"
```
-The details of the H2 database URLs are found from [[H2 Database Engine Cheat Sheet |http://www.h2database.com/html/cheatSheet.html]].
+The details of the H2 database URLs are found from [H2 Database Engine Cheat Sheet](http://www.h2database.com/html/cheatSheet.html).
### SQLite database engine connection properties
@@ -85,7 +85,7 @@ db.customers.url="jdbc:h2:mem:customers"
## Configuring the JDBC Driver
-Play 2.0 is bundled only with an [[H2 | http://www.h2database.com]] database driver. Consequently, to deploy in production you will need to add your database driver as a dependency.
+Play 2.0 is bundled only with an [H2](http://www.h2database.com) database driver. Consequently, to deploy in production you will need to add your database driver as a dependency.
For example, if you use MySQL5, you need to add a [[dependency | SBTDependencies]] for the connector:
@@ -145,4 +145,4 @@ DB.withTransaction { conn =>
}
```
-> **Next:** [[Using Anorm to access your database | ScalaAnorm]]
+> **Next:** [[Using Anorm to access your database | ScalaAnorm]]
View
4 documentation/manual/scalaGuide/main/sql/ScalaDatabaseOthers.md
@@ -4,7 +4,7 @@ You can use any **SQL** database access library you like with Play, and easily r
## Integrating with ScalaQuery
-From here you can integrate any JDBC access layer that needs a JDBC data source. For example, to integrate with [[ScalaQuery | https://github.com/szeiger/scala-query]]:
+From here you can integrate any JDBC access layer that needs a JDBC data source. For example, to integrate with [ScalaQuery](https://github.com/szeiger/scala-query):
```scala
import play.api.db._
@@ -45,4 +45,4 @@ db.default.url="jdbc:h2:mem:play"
db.default.jndiName=DefaultDS
```
-> **Next:** [[Using the Cache | ScalaCache]]
+> **Next:** [[Using the Cache | ScalaCache]]
View
2 documentation/manual/scalaGuide/main/tests/ScalaFunctionalTest.md
@@ -68,7 +68,7 @@ A custom `FakeApplication` can also be passed to the test server, for example:
## Testing from within a Web browser.
-If you want to test your application using a browser, you can use [[Selenium WebDriver| http://code.google.com/p/selenium/?redir=1]]. Play will start the WebDriver for your, and wrap it in the convenient API provided by [[FluentLenium|https://github.com/FluentLenium/FluentLenium]].
+If you want to test your application using a browser, you can use [Selenium WebDriver](http://code.google.com/p/selenium/?redir=1). Play will start the WebDriver for your, and wrap it in the convenient API provided by [FluentLenium](https://github.com/FluentLenium/FluentLenium).
```scala
"run in a browser" in new WithBrowser {
View
2 documentation/manual/scalaGuide/main/tests/ScalaTest.md
@@ -4,7 +4,7 @@ Test source files must be placed in your application’s `test` folder. You can
## Using specs2
-The default way to test a Play 2 application is by using [[specs2| http://etorreborre.github.com/specs2/]].
+The default way to test a Play 2 application is by using [specs2](http://etorreborre.github.com/specs2/).
Unit specifications extend the `org.specs2.mutable.Specification` trait and are using the should/in format:
View
6 documentation/manual/scalaGuide/main/ws/ScalaOAuth.md
@@ -1,8 +1,8 @@
# OAuth
-[[OAuth|http://oauth.net/]] is a simple way to publish and interact with protected data. It's also a safer and more secure way for people to give you access. For example, it can be used to access your users' data on [[Twitter|https://dev.twitter.com/docs/auth/using-oauth]].
+[OAuth](http://oauth.net/) is a simple way to publish and interact with protected data. It's also a safer and more secure way for people to give you access. For example, it can be used to access your users' data on [Twitter](https://dev.twitter.com/docs/auth/using-oauth).
-There are 2 very different versions of OAuth: [[OAuth 1.0|http://tools.ietf.org/html/rfc5849]] and [[OAuth 2.0|http://oauth.net/2/]]. Version 2 is simple enough to be implemented easily without library or helpers, so Play only provides support for OAuth 1.0.
+There are 2 very different versions of OAuth: [OAuth 1.0](http://tools.ietf.org/html/rfc5849) and [OAuth 2.0](http://oauth.net/2/). Version 2 is simple enough to be implemented easily without library or helpers, so Play only provides support for OAuth 1.0.
## Required Information