Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Updated readme
  • Loading branch information
paolo-rossi committed May 22, 2017
1 parent 9aeff31 commit d87c52e
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 3 deletions.
3 changes: 1 addition & 2 deletions LICENSE
Expand Up @@ -359,5 +359,4 @@ Exhibit B - "Incompatible With Secondary Licenses" Notice

This Source Code Form is "Incompatible
With Secondary Licenses", as defined by
the Mozilla Public License, v. 2.0.

the Mozilla Public License, v. 2.0.
25 changes: 24 additions & 1 deletion README.md
@@ -1,4 +1,27 @@
# WiRL
## Delphi RESTful Library

<a href="http://wirl.delphiblocks.com/">![WiRL Restful Library](http://wirl.delphiblocks.com/assets/images/wirl-300.png)</a>
<a href="http://wirl.delphiblocks.com/">
<img src="http://wirl.delphiblocks.com/assets/images/wirl-300.png" alt="Delphi RESTful Library" width="200" align="center" /></a>

**WiRL** was created to simplify RESTful service implementation in Delphi, but more importantly, to enable maximum interoperability with REST client written in other languages and tools.

WiRL is designed after Java JAX-RS specifications, and tries to be compliant with the 6 REST constraints

WiRL is a high-level REST framework that exposes plain Delphi objects (PODO) as RESTful web resources by applying [attributes](http://docwiki.embarcadero.com/RADStudio/Seattle/en/Overview_of_Attributes) to these classes.

```Delphi
[Path('customers')]
TCustomerResource = class
public
[GET]
[Produces('TMediaType.APPLICATION_JSON')]
function SelectCustomers: TCustomerList;
[POST]
[Consumes('TMediaType.APPLICATION_JSON')]
[Produces('TMediaType.APPLICATION_JSON')]
function InsertCustomer(ACustomer: TCustomer): TCustomer;
end;
```
WiRL has a strong HTTP content negotiation and defines attributes to bind specific URI patterns and HTTP operations to individual methods of your Delphi class. It has parameter injection attributes so that you can easily pull in information from the HTTP request. It has message body readers and writers that allow you to decouple data format marshalling and unmarshalling from your Delphi objects. It has exception mappers that can map an exception to an HTTP response code and message.

0 comments on commit d87c52e

Please sign in to comment.