Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package frogermcs.io.githubclient.inject;

import frogermcs.io.githubclient.AppComponent;
import frogermcs.io.githubclient.AppModule;
import frogermcs.io.githubclient.dependencyinjection.components.AppComponent;
import frogermcs.io.githubclient.dependencyinjection.modules.AppModule;
import frogermcs.io.githubclient.DaggerAppComponent;
import frogermcs.io.githubclient.GithubClientApplication;
import frogermcs.io.githubclient.data.api.GithubApiModule;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,14 @@

import android.app.Application;
import android.content.Context;
import android.support.annotation.VisibleForTesting;

import com.frogermcs.dagger2metrics.Dagger2Metrics;

import frogermcs.io.githubclient.data.UserComponent;
import frogermcs.io.githubclient.data.api.UserModule;
import frogermcs.io.githubclient.dependencyinjection.components.AppComponent;
import frogermcs.io.githubclient.dependencyinjection.components.DaggerAppComponent;
import frogermcs.io.githubclient.dependencyinjection.components.UserComponent;
import frogermcs.io.githubclient.dependencyinjection.modules.AppModule;
import frogermcs.io.githubclient.dependencyinjection.modules.UserModule;
import frogermcs.io.githubclient.data.model.User;
import timber.log.Timber;

Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
package frogermcs.io.githubclient;
package frogermcs.io.githubclient.dependencyinjection.components;

import javax.inject.Singleton;

import dagger.Component;
import frogermcs.io.githubclient.dependencyinjection.modules.AppModule;
import frogermcs.io.githubclient.data.api.GithubApiModule;
import frogermcs.io.githubclient.data.UserComponent;
import frogermcs.io.githubclient.data.api.UserModule;
import frogermcs.io.githubclient.ui.activity.component.SplashActivityComponent;
import frogermcs.io.githubclient.ui.activity.module.SplashActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.UserModule;
import frogermcs.io.githubclient.dependencyinjection.modules.SplashActivityModule;

/**
* Created by Miroslaw Stanek on 22.04.15.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
package frogermcs.io.githubclient.ui.activity.component;
package frogermcs.io.githubclient.dependencyinjection.components;

import dagger.Subcomponent;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.RepositoriesListActivity;
import frogermcs.io.githubclient.ui.activity.module.RepositoriesListActivityModule;
import frogermcs.io.githubclient.ui.activity.presenter.RepositoriesListActivityPresenter;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoriesListActivityModule;

/**
* Created by Miroslaw Stanek on 23.04.15.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package frogermcs.io.githubclient.ui.activity.component;
package frogermcs.io.githubclient.dependencyinjection.components;

import dagger.Subcomponent;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.RepositoryDetailsActivity;
import frogermcs.io.githubclient.ui.activity.module.RepositoryDetailsActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoryDetailsActivityModule;

/**
* Created by Miroslaw Stanek on 23.04.15.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
package frogermcs.io.githubclient.ui.activity.component;
package frogermcs.io.githubclient.dependencyinjection.components;

import dagger.Subcomponent;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.SplashActivity;
import frogermcs.io.githubclient.ui.activity.module.SplashActivityModule;
import frogermcs.io.githubclient.ui.activity.presenter.SplashActivityPresenter;
import frogermcs.io.githubclient.dependencyinjection.modules.SplashActivityModule;

/**
* Created by Miroslaw Stanek on 23.04.15.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package frogermcs.io.githubclient.dependencyinjection.components;

import dagger.Subcomponent;
import frogermcs.io.githubclient.dependencyinjection.scopes.UserScope;
import frogermcs.io.githubclient.dependencyinjection.modules.UserModule;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoriesListActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoryDetailsActivityModule;

/**
* Created by Miroslaw Stanek on 23.06.15.
*/
@UserScope
@Subcomponent(
modules = {
UserModule.class
}
)
public interface UserComponent {

RepositoriesListActivityComponent plus(RepositoriesListActivityModule module);

RepositoryDetailsActivityComponent plus(RepositoryDetailsActivityModule module);
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
package frogermcs.io.githubclient;
package frogermcs.io.githubclient.dependencyinjection.modules;

import android.app.Application;

import javax.inject.Singleton;

import dagger.Module;
import dagger.Provides;
import frogermcs.io.githubclient.HeavyExternalLibrary;
import frogermcs.io.githubclient.HeavyLibraryWrapper;
import frogermcs.io.githubclient.utils.AnalyticsManager;
import frogermcs.io.githubclient.utils.Validator;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
package frogermcs.io.githubclient.ui.activity.module;
package frogermcs.io.githubclient.dependencyinjection.modules;

import dagger.Module;
import dagger.Provides;
import frogermcs.io.githubclient.data.api.RepositoriesManager;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.RepositoriesListActivity;
import frogermcs.io.githubclient.ui.activity.presenter.RepositoriesListActivityPresenter;
import frogermcs.io.githubclient.utils.AnalyticsManager;

/**
* Created by Miroslaw Stanek on 23.04.15.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package frogermcs.io.githubclient.ui.activity.module;
package frogermcs.io.githubclient.dependencyinjection.modules;

import dagger.Module;
import dagger.Provides;
import frogermcs.io.githubclient.data.model.User;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.RepositoryDetailsActivity;
import frogermcs.io.githubclient.ui.activity.presenter.RepositoryDetailsActivityPresenter;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
package frogermcs.io.githubclient.ui.activity.module;
package frogermcs.io.githubclient.dependencyinjection.modules;

import dagger.Module;
import dagger.Provides;
import frogermcs.io.githubclient.HeavyExternalLibrary;
import frogermcs.io.githubclient.HeavyLibraryWrapper;
import frogermcs.io.githubclient.data.api.UserManager;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.ActivityScope;
import frogermcs.io.githubclient.ui.activity.SplashActivity;
import frogermcs.io.githubclient.ui.activity.presenter.SplashActivityPresenter;
import frogermcs.io.githubclient.utils.Validator;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
package frogermcs.io.githubclient.data.api;
package frogermcs.io.githubclient.dependencyinjection.modules;

import dagger.Module;
import dagger.Provides;
import frogermcs.io.githubclient.data.UserScope;
import frogermcs.io.githubclient.dependencyinjection.scopes.UserScope;
import frogermcs.io.githubclient.data.api.GithubApiService;
import frogermcs.io.githubclient.data.api.RepositoriesManager;
import frogermcs.io.githubclient.data.model.User;

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package frogermcs.io.githubclient.ui.activity;
package frogermcs.io.githubclient.dependencyinjection.scopes;

import javax.inject.Scope;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package frogermcs.io.githubclient.data;
package frogermcs.io.githubclient.dependencyinjection.scopes;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;

import frogermcs.io.githubclient.AppComponent;
import frogermcs.io.githubclient.GithubClientApplication;

/**
* Created by Miroslaw Stanek on 23.04.15.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import frogermcs.io.githubclient.GithubClientApplication;
import frogermcs.io.githubclient.R;
import frogermcs.io.githubclient.data.model.Repository;
import frogermcs.io.githubclient.ui.activity.module.RepositoriesListActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoriesListActivityModule;
import frogermcs.io.githubclient.ui.activity.presenter.RepositoriesListActivityPresenter;
import frogermcs.io.githubclient.ui.adapter.RepositoriesListAdapter;
import frogermcs.io.githubclient.utils.AnalyticsManager;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import frogermcs.io.githubclient.GithubClientApplication;
import frogermcs.io.githubclient.R;
import frogermcs.io.githubclient.data.model.Repository;
import frogermcs.io.githubclient.ui.activity.module.RepositoryDetailsActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.RepositoryDetailsActivityModule;
import frogermcs.io.githubclient.ui.activity.presenter.RepositoryDetailsActivityPresenter;
import frogermcs.io.githubclient.utils.AnalyticsManager;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import android.content.Intent;
import android.os.Bundle;
import android.os.Debug;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
Expand All @@ -19,7 +18,7 @@
import frogermcs.io.githubclient.GithubClientApplication;
import frogermcs.io.githubclient.R;
import frogermcs.io.githubclient.data.model.User;
import frogermcs.io.githubclient.ui.activity.module.SplashActivityModule;
import frogermcs.io.githubclient.dependencyinjection.modules.SplashActivityModule;
import frogermcs.io.githubclient.ui.activity.presenter.SplashActivityPresenter;
import frogermcs.io.githubclient.utils.AnalyticsManager;
import rx.Subscription;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

import android.app.Application;

import javax.inject.Inject;
import javax.inject.Singleton;

import frogermcs.io.githubclient.data.UserScope;
import frogermcs.io.githubclient.ui.activity.ActivityScope;
import timber.log.Timber;

/**
Expand Down