-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
64 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
# Hibiscus | ||
Hibiscus, simplified mobile blog application. [GooglePlay](https://play.google.com/store/apps/details?id=com.tonyjs.hibiscus) | ||
|
||
This repo is using MVVM(without Databinding), Rxjava2, Requery(orm), Retrofit2, Dagger2, Glide, anko and etc. | ||
|
||
 | ||
 | ||
 | ||
 | ||
 | ||
|
||
### Designing the app. MVVM | ||
|
||
##### ViewModel - communication between Ui and Data layer. | ||
* UserViewModel : deal with User data.(nickname and token. the token will be taken into [Telegraph Api](http://telegra.ph/api)) | ||
* PostViewModel : deal with Post data.(title, created time and any texts, images) | ||
|
||
##### Repository - Create, Read, Update, Delete the Model(representative the Application). | ||
* LocalRepository : deal with Data which provided by Database, ContentProvider, Preferences and etc without networking. | ||
* RemoteRepository : deal with Data which provided by Networking. | ||
|
||
##### Dependency Injection - using Dagger 2 | ||
* AppModule : provide classes from Application(Context, Resources, ContentResolver). | ||
* DatabaseModule : provide Database(using [Requery](https://github.com/requery/requery)) | ||
* NetworkModule : provide the class which can networking(using [Retrofit2](https://github.com/square/retrofit)). | ||
* MapperModule : provide mapper classes. the Model has the source from. | ||
* ~Entity : from the Local(Database, ContentProvider, Preferences). eg. PostEntity | ||
* ~DTO : from the Remote. eg. UserDTO | ||
* RepositoryModule : provide Repository classes. eg. PostLocalRepository | ||
* DataComponent : wrap all classes from Modules. and used for injecting. | ||
|
||
###### Application structure | ||
* MainActivity : the one and only activity for this application. | ||
* PostListFragment : show the posts. | ||
* CreatePostFragment : show users to create posts. | ||
* PhotoListFragment : show users photo list from ContentProvider. | ||
|
||
###### Flow | ||
if not the application contains any data, shows the guide(like ChatBot). | ||
When the User input the nickname and confirm, try to retrieve token from `Telegraph` using nickname. | ||
and then guide to create post. User can create the post and shows the posts. | ||
|
||
##### Todo features | ||
* update the post. | ||
* export the post into `Telegraph` and user can share the link. | ||
* filter by date, tags and etc. | ||
* zoom the image. | ||
|
||
|
||
License | ||
-------- | ||
|
||
|
||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License 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. |