package com.github.jackparisi.droidbox.architecture.model

import android.arch.lifecycle.ViewModel
import android.databinding.ObservableBoolean
import android.databinding.ObservableField

/**
 * Created by Giacomo Parisi on 30/06/2017.
 * https://github.com/JackParisi
 */

abstract class DroidViewModel : ViewModel() {
    var error = ObservableBoolean()

    var lastError: Class<Throwable>? = null

    var errorMessage = ObservableField<String>()

    var retryButtonMessage = ObservableField<String>()

    var loading = ObservableBoolean()
}

package com.github.jackparisi.droidbox.architecture.model

import android.arch.lifecycle.ViewModel
import android.databinding.ObservableBoolean
import android.databinding.ObservableField
import android.databinding.ObservableInt

/**
 * Created by Giacomo Parisi on 30/06/2017.
 * https://github.com/JackParisi
 */

abstract class DroidViewModel : ViewModel() {
    var error = ObservableBoolean()

    var lastError: Class<Throwable>? = null

    var errorMessage = ObservableField<String>()

    var retryButtonMessage = ObservableField<String>()

    var loading = ObservableBoolean()

    var title = ObservableInt()
}

Update view model for page title
Update view model for page title

JackParisi/DroidBox