package net.yslibrary.licenseadapter.example;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import java.util.ArrayList;
import java.util.List;
import net.yslibrary.licenseadapter.LicenseAdapter;
import net.yslibrary.licenseadapter.LicenseEntry;
import net.yslibrary.licenseadapter.Licenses;

public class MainActivity extends AppCompatActivity {

  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    List<LicenseEntry> licenses = new ArrayList<>();

    licenses.add(Licenses.noContent("Android SDK", "Google Inc.",
        "https://developer.android.com/sdk/terms.html"));
    licenses.add(Licenses.noContent("Fabric", "Twitter", "https://fabric.io/terms"));
    licenses.add(Licenses.fromGitHub("jakewharton/butterknife"));
    licenses.add(Licenses.fromGitHub("gabrielemariotti/changeloglib"));
    licenses.add(Licenses.fromGitHub("hdodenhof/CircleImageView"));
    licenses.add(Licenses.fromGitHub("google/dagger"));
    licenses.add(Licenses.fromGitHub("bumptech/glide", Licenses.LICENSE_NAME_BSD,
        Licenses.LICENSE_NO_EXTENSION));
    licenses.add(Licenses.fromGitHub("evant/gradle-retrolambda"));
    licenses.add(Licenses.fromGitHub("google/gson"));
    licenses.add(Licenses.fromGitHub("immutables/immutables"));
    licenses.add(
        Licenses.fromGitHub("jhy/jsoup", Licenses.LICENSE_NAME_MIT, Licenses.LICENSE_NO_EXTENSION));
    licenses.add(Licenses.fromGitHub("square/leakcanary"));
    licenses.add(Licenses.fromGitHub("square/okhttp"));
    licenses.add(Licenses.fromGitHub("realm/realm-java"));
    licenses.add(Licenses.fromGitHub("yqritc/RecyclerView-MultipleViewTypesAdapter"));
    licenses.add(Licenses.fromGitHub("ReactiveX/RxAndroid"));
    licenses.add(Licenses.fromGitHub("ReactiveX/RxJava"));
    licenses.add(Licenses.fromGitHub("facebook/stetho", Licenses.LICENSE_NAME_BSD,
        Licenses.LICENSE_NO_EXTENSION));
    licenses.add(Licenses.fromGitHub("jakewharton/threetenabp"));
    licenses.add(Licenses.fromGitHub("jakewharton/timber"));
    licenses.add(Licenses.fromGitHub("grandcentrix/tray"));
    licenses.add(Licenses.fromGitHub("twitter/twitter-text"));

    LicenseAdapter adapter = new LicenseAdapter(licenses);
    RecyclerView list = (RecyclerView) findViewById(R.id.list);
    list.setLayoutManager(new LinearLayoutManager(this, LinearLayoutManager.VERTICAL, false));
    list.setAdapter(adapter);

    Licenses.load(licenses);
  }
}

@@ -979,28 +979,96 @@
 icenses.
-fromGitHub(%22
+noContent(%22ChangeLog Library%22, %22Gabriele Mariotti%22,%0A        %22https://github.com/
 gabriele
@@ -1457,16 +1457,47 @@
 le/gson%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A    
@@ -1552,16 +1552,47 @@
 utables%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A    
@@ -1873,24 +1873,55 @@
 /realm-java%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A    lice
@@ -1995,16 +1995,151 @@
 Adapter%22
+,%0A        Licenses.LICENSE_NO_EXTENSION));%0A    licenses.add(Licenses.fromGitHub(%22yshrsmz/LicenseAdapter%22, Licenses.LICENSE_NO_EXTENSION
 ));%0A    
@@ -2192,16 +2192,47 @@
 Android%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A    
@@ -2282,16 +2282,47 @@
 /RxJava%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A    
@@ -2624,24 +2624,24 @@
 ix/tray%22));%0A
-
     licenses
@@ -2687,16 +2687,47 @@
 er-text%22
+, Licenses.LICENSE_NO_EXTENSION
 ));%0A%0A   

update example