Giter VIP home page Giter VIP logo

nano-rest's Introduction

##DISCLAIMER

This project has been deprecated, for web service on Android, please see Nano which has been updated to support SOAP/XML based web service directly.

nano-rest

A light-weight restful client for Android, using Nano binding framework

###Overview Can be used to issue synchronous or asynchronous requests toward your API. There is a service class that handles request execution by two kinds of thread pools(choice can be specified in the request implementation): either a single thread executor or a fixed size executor. Each of the executors is backed by a priority queue which means each individual request can have an execution priority set.
You can also provide your own service class which will handle the requests, extend from the current ones etc...

Custom request pre-process and reponse parsing logic can be added by extending existing ones, Nano binding framework is supported to automatically marshall request object into xml content or unmarshall xml content into response object, schema or wsdl driven development is also supported by leveraging mxjc binding compiler.

Pluggable authentication is supported, a default authentication provider is provided which setts an OAuth token in the header, you can plug in a custom implementation according to the specification of your services.
Note: The process of getting an oauth token from the server is not part of this library implementation and have to be set according to the specification for your webserivce.

###Steps to setup the library

  1. Add nano-rest-xxx-shaded.jar in the classpath of your project.
    Download latest 0.5.0 snapshot release
    Note: please use the shaded jar which includes Nano dependency, if not, you should add Nano jar reference by yourself.
  2. Look into the project manifest and add the definitions below.

###Required Manifest Declarations

  <uses-permission android:name="android.permission.INTERNET" />

  <uses-sdk android:minSdkVersion="7" />

  <application>
    <service android:name="com.leansoft.nanorest.service.HTTPRequestExecutorService" >
    </service>
  </application>

###Docs

  1. Schema Driven Web Serivce Client Development on Android, Part 1 : Hello eBay Finding
  2. Schema Driven Web Serivce Client Development on Android, Part 2 : eBay Search App

###Samples

  1. Hello eBay Finding
  2. Hello eBay Shopping
  3. Hello eBay Trading
  4. eBay Search App, seach using eBay Finding API.
  5. eBay Demo, combine eBay Finding/Shopping/Trading API calls in one App.

###Copyright and License Copyright 2012 LeanSoft, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this work except in compliance with the License. You may obtain a copy of the License in the LICENSE file, or at:

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

###Contribution The original source of Nano-rest is forked from this github project, many thanks to the original author.

nano-rest's People

Contributors

bulldog2011 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.