WCF part
The WCF part is composed of three files, the service contract, the service implementation and the app.config.
The service contract
The service contract defines the webservice methods.
To expose the service via REST, the WegGet attribute is required. It specifies the URL of each method, the serialization format (JSON or XML, use JSON for fast processing). If the method has parameters they can either be provided using POST (requires another attribute) or they can be provided by specifying them in the URL as shown in the example. The implementation of this method is straight forward and requires no attributes.
0 Comments