// Path: app/src/main/java/io/github/kobakei/anago/di/FragmentComponent.java
// @Subcomponent(modules = {FragmentModule.class})
// public interface FragmentComponent {
//     void inject(MyRepoListFragment fragment);
//     void inject(StarredRepoListFragment fragment);
//     void inject(RepoInfoFragment fragment);
//     void inject(IssueListFragment fragment);
//     void inject(PullRequestListFragment fragment);
//     void inject(ContentListFragment fragment);
// 
//     RepoListItemViewModel repoListItemViewModel();
//     IssueListItemViewModel issueListItemViewModel();
//     PullRequestListItemViewModel pullRequestListItemViewModel();
//     ContentListItemViewModel contentListItemViewModel();
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/entity/Issue.java
// public class Issue {
//     public String state;
//     public String title;
//     public String body;
//     public int number;
//     public User user;
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/entity/PullRequest.java
// public class PullRequest {
//     public String state;
//     public String title;
//     public String body;
//     public int number;
//     public User user;
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/viewmodel/PullRequestListItemViewModel.java
// public class PullRequestListItemViewModel extends FragmentViewModel {
// 
//     public ObservableField<PullRequest> pullRequest;
// 
//     @Inject
//     public PullRequestListItemViewModel(BaseFragment fragment) {
//         super(fragment);
//         pullRequest = new ObservableField<>();
//     }
// 
//     @Override
//     public void onStart() {
// 
//     }
// 
//     @Override
//     public void onResume() {
// 
//     }
// 
//     @Override
//     public void onPause() {
// 
//     }
// 
//     @Override
//     public void onStop() {
// 
//     }
// }


import android.content.Context;
import android.databinding.DataBindingUtil;
import android.databinding.ObservableArrayList;
import android.databinding.ObservableList;
import android.support.annotation.NonNull;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import io.github.kobakei.anago.R;
import io.github.kobakei.anago.databinding.PullRequestListItemBinding;
import io.github.kobakei.anago.di.FragmentComponent;
import io.github.kobakei.anago.entity.Issue;
import io.github.kobakei.anago.entity.PullRequest;
import io.github.kobakei.anago.viewmodel.PullRequestListItemViewModel;
package io.github.kobakei.anago.adapter;



/**
 * プルリクリストのアダプター
 * Created by keisuke on 2016/10/13.
 */

public class PullRequestAdapter extends ArrayAdapter<PullRequest> {

    private final FragmentComponent injector;

    /**
     * コンストラクタ
     * @param context
     * @param injector
     * @param items
     */
    public PullRequestAdapter(Context context, FragmentComponent injector, ObservableArrayList<PullRequest> items) {
        super(context, 0, items);

        this.injector = injector;

        items.addOnListChangedCallback(new ObservableList.OnListChangedCallback<ObservableList<PullRequest>>() {
            @Override
// Path: app/src/main/java/io/github/kobakei/anago/di/FragmentComponent.java
// @Subcomponent(modules = {FragmentModule.class})
// public interface FragmentComponent {
//     void inject(MyRepoListFragment fragment);
//     void inject(StarredRepoListFragment fragment);
//     void inject(RepoInfoFragment fragment);
//     void inject(IssueListFragment fragment);
//     void inject(PullRequestListFragment fragment);
//     void inject(ContentListFragment fragment);
// 
//     RepoListItemViewModel repoListItemViewModel();
//     IssueListItemViewModel issueListItemViewModel();
//     PullRequestListItemViewModel pullRequestListItemViewModel();
//     ContentListItemViewModel contentListItemViewModel();
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/entity/Issue.java
// public class Issue {
//     public String state;
//     public String title;
//     public String body;
//     public int number;
//     public User user;
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/entity/PullRequest.java
// public class PullRequest {
//     public String state;
//     public String title;
//     public String body;
//     public int number;
//     public User user;
// }
// 
// Path: app/src/main/java/io/github/kobakei/anago/viewmodel/PullRequestListItemViewModel.java
// public class PullRequestListItemViewModel extends FragmentViewModel {
// 
//     public ObservableField<PullRequest> pullRequest;
// 
//     @Inject
//     public PullRequestListItemViewModel(BaseFragment fragment) {
//         super(fragment);
//         pullRequest = new ObservableField<>();
//     }
// 
//     @Override
//     public void onStart() {
// 
//     }
// 
//     @Override
//     public void onResume() {
// 
//     }
// 
//     @Override
//     public void onPause() {
// 
//     }
// 
//     @Override
//     public void onStop() {
// 
//     }
// }


// Path: app/src/main/java/io/github/kobakei/anago/adapter/PullRequestAdapter.java
import android.content.Context;
import android.databinding.DataBindingUtil;
import android.databinding.ObservableArrayList;
import android.databinding.ObservableList;
import android.support.annotation.NonNull;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import io.github.kobakei.anago.R;
import io.github.kobakei.anago.databinding.PullRequestListItemBinding;
import io.github.kobakei.anago.di.FragmentComponent;
import io.github.kobakei.anago.entity.Issue;
import io.github.kobakei.anago.entity.PullRequest;
import io.github.kobakei.anago.viewmodel.PullRequestListItemViewModel;

package io.github.kobakei.anago.adapter;



/**
 * プルリクリストのアダプター
 * Created by keisuke on 2016/10/13.
 */

public class PullRequestAdapter extends ArrayAdapter<PullRequest> {

    private final FragmentComponent injector;

    /**
     * コンストラクタ
     * @param context
     * @param injector
     * @param items
     */
    public PullRequestAdapter(Context context, FragmentComponent injector, ObservableArrayList<PullRequest> items) {
        super(context, 0, items);

        this.injector = injector;

        items.addOnListChangedCallback(new ObservableList.OnListChangedCallback<ObservableList<PullRequest>>() {
            @Override
            public void onChanged(ObservableList<PullRequest> pullRequests) {