-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from izumin5210/combined-store
New API
- Loading branch information
Showing
64 changed files
with
1,534 additions
and
1,375 deletions.
There are no files selected for viewing
40 changes: 0 additions & 40 deletions
40
...or/src/main/java/info/izumin/android/droidux/processor/CombinedReducerProcessingStep.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
...ux-processor/src/main/java/info/izumin/android/droidux/processor/StoreProcessingStep.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package info.izumin.android.droidux.processor; | ||
|
||
import com.google.common.collect.ImmutableSet; | ||
import com.google.common.collect.SetMultimap; | ||
|
||
import java.lang.annotation.Annotation; | ||
import java.util.HashSet; | ||
import java.util.Set; | ||
|
||
import javax.annotation.processing.Filer; | ||
import javax.lang.model.element.Element; | ||
import javax.lang.model.element.TypeElement; | ||
|
||
import info.izumin.android.droidux.annotation.Store; | ||
import info.izumin.android.droidux.processor.generator.StoreClassGenerator; | ||
import info.izumin.android.droidux.processor.generator.StoreImplClassGenerator; | ||
import info.izumin.android.droidux.processor.model.StoreImplModel; | ||
import info.izumin.android.droidux.processor.model.StoreModel; | ||
|
||
/** | ||
* Created by izumin on 11/26/15. | ||
*/ | ||
public class StoreProcessingStep extends AbstractProcessingStep { | ||
public static final String TAG = StoreProcessingStep.class.getSimpleName(); | ||
|
||
public StoreProcessingStep(Filer filer) { | ||
super(filer); | ||
} | ||
|
||
@Override | ||
public Set<? extends Class<? extends Annotation>> annotations() { | ||
return ImmutableSet.<Class<? extends Annotation>>of(Store.class); | ||
} | ||
|
||
@Override | ||
public Set<Element> process(SetMultimap<Class<? extends Annotation>, Element> elementsByAnnotation) { | ||
for (Element element : elementsByAnnotation.get(Store.class)) { | ||
StoreModel model = new StoreModel((TypeElement) element); | ||
for (StoreImplModel storeImplModel : model.getStoreImplModels()) { | ||
write(new StoreImplClassGenerator(storeImplModel).createJavaFile()); | ||
} | ||
write(new StoreClassGenerator(model).createJavaFile()); | ||
} | ||
return new HashSet<>(); | ||
} | ||
} |
10 changes: 0 additions & 10 deletions
10
.../main/java/info/izumin/android/droidux/processor/exception/InvalidClassNameException.java
This file was deleted.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
...o/izumin/android/droidux/processor/exception/InvalidDispatchableDeclarationException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package info.izumin.android.droidux.processor.exception; | ||
|
||
/** | ||
* Created by izumin on 11/7/15. | ||
*/ | ||
public class InvalidDispatchableDeclarationException extends RuntimeException { | ||
public InvalidDispatchableDeclarationException(String message) { | ||
super(message); | ||
} | ||
} |
10 changes: 0 additions & 10 deletions
10
...java/info/izumin/android/droidux/processor/exception/InvalidMethodArgumentsException.java
This file was deleted.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
...a/info/izumin/android/droidux/processor/exception/InvalidReducerDeclarationException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package info.izumin.android.droidux.processor.exception; | ||
|
||
/** | ||
* Created by izumin on 11/8/15. | ||
*/ | ||
public class InvalidReducerDeclarationException extends RuntimeException { | ||
public InvalidReducerDeclarationException(String message) { | ||
super(message); | ||
} | ||
} |
10 changes: 0 additions & 10 deletions
10
...main/java/info/izumin/android/droidux/processor/exception/InvalidStateClassException.java
This file was deleted.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
...ava/info/izumin/android/droidux/processor/exception/InvalidStoreDelcarationException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package info.izumin.android.droidux.processor.exception; | ||
|
||
/** | ||
* Created by izumin on 11/24/15. | ||
*/ | ||
public class InvalidStoreDelcarationException extends RuntimeException { | ||
public InvalidStoreDelcarationException(String message) { | ||
super(message); | ||
} | ||
} |
104 changes: 0 additions & 104 deletions
104
...ain/java/info/izumin/android/droidux/processor/generator/CombinedStoreClassGenerator.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.