From 9d942a520617d32ac2038f2ab1aef09b60765551 Mon Sep 17 00:00:00 2001 From: Marcos Trujillo Date: Wed, 25 Jul 2018 11:59:41 +0200 Subject: [PATCH] Fix checkstyle errors --- .../com/karumi/rosie/domain/usecase/UseCaseHandler.java | 2 +- .../rosie/domain/usecase/jobqueue/UseCaseWrapperJob.java | 2 +- .../karumi/rosie/domain/usecase/UseCaseHandlerTest.java | 8 ++++---- .../java/com/karumi/rosie/view/RosiePresenterTest.java | 2 +- .../characters/repository/CharacterDataSourceFactory.java | 2 +- .../comics/repository/ComicSeriesDataSourceFactory.java | 2 +- .../rosie/sample/main/view/adapter/FragmentAdapter.java | 4 ++-- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/rosie/src/main/java/com/karumi/rosie/domain/usecase/UseCaseHandler.java b/rosie/src/main/java/com/karumi/rosie/domain/usecase/UseCaseHandler.java index 46387aad..eb001818 100644 --- a/rosie/src/main/java/com/karumi/rosie/domain/usecase/UseCaseHandler.java +++ b/rosie/src/main/java/com/karumi/rosie/domain/usecase/UseCaseHandler.java @@ -78,7 +78,7 @@ private static class OnErrorCallbackToErrorHandlerAdapter implements OnErrorCall private final WeakReference errorHandler; private final WeakReference useCaseOnErrorCallback; - public OnErrorCallbackToErrorHandlerAdapter(ErrorHandler errorHandler, + private OnErrorCallbackToErrorHandlerAdapter(ErrorHandler errorHandler, OnErrorCallback useCaseOnErrorCallback) { this.errorHandler = new WeakReference<>(errorHandler); this.useCaseOnErrorCallback = new WeakReference<>(useCaseOnErrorCallback); diff --git a/rosie/src/main/java/com/karumi/rosie/domain/usecase/jobqueue/UseCaseWrapperJob.java b/rosie/src/main/java/com/karumi/rosie/domain/usecase/jobqueue/UseCaseWrapperJob.java index 52673fe2..7ef6ece7 100644 --- a/rosie/src/main/java/com/karumi/rosie/domain/usecase/jobqueue/UseCaseWrapperJob.java +++ b/rosie/src/main/java/com/karumi/rosie/domain/usecase/jobqueue/UseCaseWrapperJob.java @@ -28,7 +28,7 @@ class UseCaseWrapperJob extends Job { private static final int PRIORITY_NORMAL = 3; private final UseCaseWrapper useCaseWrapper; - public UseCaseWrapperJob(UseCaseWrapper useCaseWrapper) { + UseCaseWrapperJob(UseCaseWrapper useCaseWrapper) { super(new Params(PRIORITY_NORMAL)); this.useCaseWrapper = useCaseWrapper; } diff --git a/rosie/src/test/java/com/karumi/rosie/domain/usecase/UseCaseHandlerTest.java b/rosie/src/test/java/com/karumi/rosie/domain/usecase/UseCaseHandlerTest.java index 2999911c..e28a413e 100644 --- a/rosie/src/test/java/com/karumi/rosie/domain/usecase/UseCaseHandlerTest.java +++ b/rosie/src/test/java/com/karumi/rosie/domain/usecase/UseCaseHandlerTest.java @@ -405,7 +405,7 @@ private class NoUseCase extends RosieUseCase { private class EmptyResponseUseCase extends RosieUseCase { - public EmptyResponseUseCase() { + private EmptyResponseUseCase() { setCallbackScheduler(new FakeCallbackScheduler()); } @@ -416,7 +416,7 @@ public EmptyResponseUseCase() { private class ErrorUseCase extends RosieUseCase { - public ErrorUseCase() { + private ErrorUseCase() { setCallbackScheduler(new FakeCallbackScheduler()); } @@ -431,7 +431,7 @@ public ErrorUseCase() { private class SuccessUseCase extends RosieUseCase { - public SuccessUseCase() { + private SuccessUseCase() { setCallbackScheduler(new FakeCallbackScheduler()); } @@ -439,4 +439,4 @@ public SuccessUseCase() { notifySuccess(); } } -} \ No newline at end of file +} diff --git a/rosie/src/test/java/com/karumi/rosie/view/RosiePresenterTest.java b/rosie/src/test/java/com/karumi/rosie/view/RosiePresenterTest.java index 5154ac68..4b46ded1 100644 --- a/rosie/src/test/java/com/karumi/rosie/view/RosiePresenterTest.java +++ b/rosie/src/test/java/com/karumi/rosie/view/RosiePresenterTest.java @@ -55,7 +55,7 @@ private RosiePresenter givenARosiePresenterWithRegisteredCallback() { private static class RosiePresenterWithRegisteredCallback extends RosiePresenter implements OnErrorCallback { - public RosiePresenterWithRegisteredCallback(UseCaseHandler useCaseHandler) { + private RosiePresenterWithRegisteredCallback(UseCaseHandler useCaseHandler) { super(useCaseHandler); registerOnErrorCallback(this); } diff --git a/sample/src/main/java/com/karumi/rosie/sample/characters/repository/CharacterDataSourceFactory.java b/sample/src/main/java/com/karumi/rosie/sample/characters/repository/CharacterDataSourceFactory.java index 6de8ed5b..dcd361ba 100644 --- a/sample/src/main/java/com/karumi/rosie/sample/characters/repository/CharacterDataSourceFactory.java +++ b/sample/src/main/java/com/karumi/rosie/sample/characters/repository/CharacterDataSourceFactory.java @@ -27,7 +27,7 @@ class CharacterDataSourceFactory { - @Inject public CharacterDataSourceFactory() { + @Inject CharacterDataSourceFactory() { } PaginatedReadableDataSource createDataSource() { diff --git a/sample/src/main/java/com/karumi/rosie/sample/comics/repository/ComicSeriesDataSourceFactory.java b/sample/src/main/java/com/karumi/rosie/sample/comics/repository/ComicSeriesDataSourceFactory.java index 41f8aab0..d554856b 100644 --- a/sample/src/main/java/com/karumi/rosie/sample/comics/repository/ComicSeriesDataSourceFactory.java +++ b/sample/src/main/java/com/karumi/rosie/sample/comics/repository/ComicSeriesDataSourceFactory.java @@ -26,7 +26,7 @@ class ComicSeriesDataSourceFactory { - @Inject public ComicSeriesDataSourceFactory() { + @Inject ComicSeriesDataSourceFactory() { } ComicSeriesDataSource createDataSource() { diff --git a/sample/src/main/java/com/karumi/rosie/sample/main/view/adapter/FragmentAdapter.java b/sample/src/main/java/com/karumi/rosie/sample/main/view/adapter/FragmentAdapter.java index 81da066d..7956ce58 100644 --- a/sample/src/main/java/com/karumi/rosie/sample/main/view/adapter/FragmentAdapter.java +++ b/sample/src/main/java/com/karumi/rosie/sample/main/view/adapter/FragmentAdapter.java @@ -50,9 +50,9 @@ public void addFragment(Fragment fragment, String pageTitle) { private static class ViewPagerFragmentHolder { public final Fragment fragment; - public final String pageTitle; + private final String pageTitle; - public ViewPagerFragmentHolder(Fragment fragment, String pageTitle) { + private ViewPagerFragmentHolder(Fragment fragment, String pageTitle) { this.fragment = fragment; this.pageTitle = pageTitle; }