Uploaded image for project: 'Apache Taverna'
  1. Apache Taverna
  2. TAVERNA-942

Implementing MVP Framework in the code structure

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Done
    • Major
    • Resolution: Done
    • parent 1
    • None
    • Taverna Mobile
    • Android Studio 1.5.1
    • Patch, Important

    Description

      Currently everything is written at same place like initiating view , Calling API for data, saving data for offline. there are fully dependent to each other. so if any developer want to change or add the feature, he have to read, configure the whole code. that is not a good practice to write the code and it make very hard to contribute.
      After long time current project will be depreciated. if no one will contribute to project.

      Implementing The MVP framework in the project so that every work will be run in the different layer architecture. and every layer have its own work and fully independent to other layer. Layers call to other layer for data ,for loading data, for calling REST API etc.

      The layers are :

      1. View (UI Layer) : this is where Activities, Fragments and other standard Android components live. It's responsible
      for displaying the data received from the presenters to the user.

      2. Presenter: Presenters subscribe to RxJava Observables provided by the DataManager. They are in charge of handling the subscription lifecycle, analysing/modifying the data returned by the DataManager and calling the appropriate methods in the View in order to display the data.

      3. Model (Data Layer): this is responsible for retrieving, saving, caching and messaging data. It can communicate with local databases and other data stores as well as with restful APIs or third party SDKs. It is divided in two parts: a group of helpers and a DataManager.

      These are some basic layers that will be in the project architecture:

      Source: https://github.com/ribot/android-boilerplate and https://msdn.microsoft.com/en-us/library/ff649571.aspx

      Attachments

        Activity

          People

            Unassigned Unassigned
            therajanmaurya Rajan Maurya
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 168h
                168h
                Remaining:
                Remaining Estimate - 168h
                168h
                Logged:
                Time Spent - Not Specified
                Not Specified