package chat.rocket.android.layouthelper.oauth;

import chat.rocket.android.R;
import chat.rocket.android.fragment.oauth.AbstractOAuthFragment;
import chat.rocket.android.fragment.oauth.FacebookOAuthFragment;
import chat.rocket.android.fragment.oauth.GitHubOAuthFragment;
import chat.rocket.android.fragment.oauth.GoogleOAuthFragment;
import chat.rocket.android.fragment.oauth.TwitterOAuthFragment;
import java.util.ArrayList;

public class OAuthProviderInfo {
  public String serviceName;
  public int buttonId;
  public Class<? extends AbstractOAuthFragment> fragmentClass;

  public OAuthProviderInfo(String serviceName, int buttonId,
      Class<? extends AbstractOAuthFragment> fragmentClass) {
    this.serviceName = serviceName;
    this.buttonId = buttonId;
    this.fragmentClass = fragmentClass;
  }

  public static final ArrayList<OAuthProviderInfo> LIST = new ArrayList<OAuthProviderInfo>() {
    {
      add(new OAuthProviderInfo(
          "twitter", R.id.btn_login_with_twitter, TwitterOAuthFragment.class));
      add(new OAuthProviderInfo(
          "github", R.id.btn_login_with_github, GitHubOAuthFragment.class));
      add(new OAuthProviderInfo(
          "google", R.id.btn_login_with_google, GoogleOAuthFragment.class));
      add(new OAuthProviderInfo(
          "facebook", R.id.btn_login_with_facebook, FacebookOAuthFragment.class));
    }
  };
}

@@ -420,16 +420,115 @@
 ayList;%0A
+import java.util.Collections;%0Aimport java.util.List;%0A%0A/**%0A * View model for OAuth login button.%0A */
 %0Apublic 
@@ -671,22 +671,78 @@
 ass;%0A%0A  
-public
+/**%0A   * Constructor with required parameters.%0A   */%0A  private
  OAuthPr
@@ -962,21 +962,22 @@
   %7D%0A%0A  p
-ublic
+rivate
  static 
@@ -1011,16 +1011,17 @@
 erInfo%3E 
+_
 LIST = n
@@ -1522,10 +1522,103 @@
  %7D%0A  %7D;%0A
+  %0A  public static final List%3COAuthProviderInfo%3E LIST = Collections.unmodifiableList(_LIST);%0A
 %7D%0A

fix findbugs issue.