// Path: jetpack/src/main/java/com/engineer/jetpack/ui/DBActivity.java
// public class DBActivity extends AppCompatActivity {
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         ActivityDbBinding dbBinding = DataBindingUtil.setContentView(this, R.layout.activity_db);
//         User user = new User("mike","22");
//         dbBinding.setUser(user);
//     }
// }
// 
// Path: jetpack/src/main/java/com/engineer/jetpack/ui/VMActivity.java
// public class VMActivity extends AppCompatActivity {
//     private static final String TAG = "VMActivity";
//     private LiveDataTimerViewModel mLiveDataTimerViewModel;
//     private TextView mTimerText;
//     private TextView mClockText;
//     private Observer<Integer> mIntegerObserver;
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         setContentView(R.layout.activity_vm);
//         mTimerText = findViewById(R.id.timer_text);
//         mClockText = findViewById(R.id.clock_text);
//         mLiveDataTimerViewModel = ViewModelProviders.of(this).get(LiveDataTimerViewModel.class);
// 
//         mIntegerObserver = updateClock();
//         subscribe();
// 
//         findViewById(R.id.button).setOnClickListener(v -> mLiveDataTimerViewModel.startRealTime());
//         findViewById(R.id.finish).setOnClickListener(v -> finish());
//     }
// 
//     private void subscribe() {
//         mLiveDataTimerViewModel.getElapsedTime().observe(this, updateTime());
// //        mLiveDataTimerViewModel.getClockTime().observe(this, mIntegerObserver);
//     }
// 
//     private Observer<Long> updateTime() {
//         return aLong -> {
//             String value = String.valueOf(aLong);
//             mTimerText.setText(value);
//             Log.e(TAG, "onChanged: aLong==" + aLong);
//         };
//     }
// 
//     private Observer<Integer> updateClock() {
//         return result -> {
//             String value = String.valueOf(result);
//             mClockText.setText(value);
//             Log.e(TAG, "updateClock: result==" + result);
//         };
//     }
// 
//     @Override
//     protected void onStop() {
//         super.onStop();
//         Log.e(TAG, "onStop: ");
//     }
// 
//     @Override
//     protected void onDestroy() {
//         super.onDestroy();
//         Log.e(TAG, "onDestroy: ");
//     }
// }
// 
// Path: jetpack/src/main/java/com/engineer/jetpack/ui/VMFragmentActivity.java
// public class VMFragmentActivity extends AppCompatActivity {
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         setContentView(R.layout.activity_vmfragment);
//     }
// }


import android.content.Context;
import android.content.Intent;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import com.engineer.jetpack.ui.DBActivity;
import com.engineer.jetpack.ui.VMActivity;
import com.engineer.jetpack.ui.VMFragmentActivity;
package com.engineer.jetpack;



public class JetPackActivity extends AppCompatActivity implements View.OnClickListener {
    private Context mContext;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
// Path: jetpack/src/main/java/com/engineer/jetpack/ui/DBActivity.java
// public class DBActivity extends AppCompatActivity {
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         ActivityDbBinding dbBinding = DataBindingUtil.setContentView(this, R.layout.activity_db);
//         User user = new User("mike","22");
//         dbBinding.setUser(user);
//     }
// }
// 
// Path: jetpack/src/main/java/com/engineer/jetpack/ui/VMActivity.java
// public class VMActivity extends AppCompatActivity {
//     private static final String TAG = "VMActivity";
//     private LiveDataTimerViewModel mLiveDataTimerViewModel;
//     private TextView mTimerText;
//     private TextView mClockText;
//     private Observer<Integer> mIntegerObserver;
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         setContentView(R.layout.activity_vm);
//         mTimerText = findViewById(R.id.timer_text);
//         mClockText = findViewById(R.id.clock_text);
//         mLiveDataTimerViewModel = ViewModelProviders.of(this).get(LiveDataTimerViewModel.class);
// 
//         mIntegerObserver = updateClock();
//         subscribe();
// 
//         findViewById(R.id.button).setOnClickListener(v -> mLiveDataTimerViewModel.startRealTime());
//         findViewById(R.id.finish).setOnClickListener(v -> finish());
//     }
// 
//     private void subscribe() {
//         mLiveDataTimerViewModel.getElapsedTime().observe(this, updateTime());
// //        mLiveDataTimerViewModel.getClockTime().observe(this, mIntegerObserver);
//     }
// 
//     private Observer<Long> updateTime() {
//         return aLong -> {
//             String value = String.valueOf(aLong);
//             mTimerText.setText(value);
//             Log.e(TAG, "onChanged: aLong==" + aLong);
//         };
//     }
// 
//     private Observer<Integer> updateClock() {
//         return result -> {
//             String value = String.valueOf(result);
//             mClockText.setText(value);
//             Log.e(TAG, "updateClock: result==" + result);
//         };
//     }
// 
//     @Override
//     protected void onStop() {
//         super.onStop();
//         Log.e(TAG, "onStop: ");
//     }
// 
//     @Override
//     protected void onDestroy() {
//         super.onDestroy();
//         Log.e(TAG, "onDestroy: ");
//     }
// }
// 
// Path: jetpack/src/main/java/com/engineer/jetpack/ui/VMFragmentActivity.java
// public class VMFragmentActivity extends AppCompatActivity {
// 
//     @Override
//     protected void onCreate(Bundle savedInstanceState) {
//         super.onCreate(savedInstanceState);
//         setContentView(R.layout.activity_vmfragment);
//     }
// }


// Path: jetpack/src/main/java/com/engineer/jetpack/JetPackActivity.java
import android.content.Context;
import android.content.Intent;
import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import com.engineer.jetpack.ui.DBActivity;
import com.engineer.jetpack.ui.VMActivity;
import com.engineer.jetpack.ui.VMFragmentActivity;

package com.engineer.jetpack;



public class JetPackActivity extends AppCompatActivity implements View.OnClickListener {
    private Context mContext;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        mContext = this;