Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Room Booker Project
##Project structure
###MVP gradle module
# Room Booker Project
## Project structure
### MVP gradle module
Java module with no Android dependencies. It contains following packages:

- `.mvp` - a package that contains all classes directly related to Model-View-Presenter architecture.
Expand All @@ -10,7 +10,7 @@ Java module with no Android dependencies. It contains following packages:
- `.domain` - contains use cases that are used to operate on Model objects. Each use case implements `Usecase` interface that contains `execute()` that returns rxJava `Observable` object.
- `.repository` - contains `Repository` interface used by use cases to operate on model. Implementation for this interface is provided by Android module using Retrofit.

###App gradle module
### App gradle module
Android gradle module.

- `.activity` - Android activities, they can be treated as MVP Views by implementing corresponding `View` interfaces from `mvp` gradle module.
Expand All @@ -23,26 +23,26 @@ Android gradle module.
- `.module` - `ApplicationModule` and `NetworkModule` are `PerApplication` defined modules. `NetworkModule` provides implementation for `Repository` interface. The rest of modules have `PerActivity` scope. `EventModule` and `CalendarsModule` provides injections for presenters and use cases defined in `mvp` gradle module.
- `.component` - contains `dagger` components. `ApplicationComponent` provides `PerApplication` scoped dependencies. Rest of components provide `PerActivity` scoped dependencies.

##Launching stub backend service
## Launching stub backend service
1. Install `ruby` on your machine
2. Install [Sinatra](http://www.sinatrarb.com/) framework gem using `sudo gem install sinatra`
3. Launch backend service from `backend` folder `ruby sinatra.rb`

##Limitations of mocked API
## Limitations of mocked API
Responses from sinatra framework service are based on static JSON files which are located in `\backend` folder. There is no implementation for storing data.
POST request operation for events have mocked response with static event in body - it has no influence on events list. Also POST request has no error handling for operation, so adding events operation is always successful. Sinatra service implementation is added only to show the general structure of API interface.


##Used libraries
## Used libraries

- [Dagger2](https://github.com/google/dagger)
- [Retrofit2 (beta2)](https://github.com/square/retrofit)
- [RxJava](https://github.com/ReactiveX/RxJava)
- [Butterknife](https://github.com/JakeWharton/butterknife)

##Copyright
## Copyright

Published under the [MIT License](LICENSE).
Copyright (c) 2015 [Macoscope][] sp. z o.o.

[Macoscope]: http://macoscope.com
[Macoscope]: http://macoscope.com