This repository has been archived by the owner on Apr 13, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
zchu
committed
Oct 11, 2017
1 parent
1cfe9d1
commit 5d64047
Showing
14 changed files
with
90 additions
and
63 deletions.
There are no files selected for viewing
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
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
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
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
22 changes: 22 additions & 0 deletions
22
rxcache/src/main/java/com/zchu/rxcache/stategy/IFlowableStrategy.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,22 @@ | ||
package com.zchu.rxcache.stategy; | ||
|
||
|
||
import com.zchu.rxcache.RxCache; | ||
import com.zchu.rxcache.data.CacheResult; | ||
|
||
import org.reactivestreams.Publisher; | ||
|
||
import java.lang.reflect.Type; | ||
|
||
import io.reactivex.Flowable; | ||
|
||
|
||
/** | ||
* author : zchu | ||
* date : 2017/10/11 | ||
* desc : | ||
*/ | ||
public interface IFlowableStrategy { | ||
|
||
<T> Publisher<CacheResult<T>> flow(RxCache rxCache, String key, Flowable<T> source, Type type); | ||
} |
20 changes: 20 additions & 0 deletions
20
rxcache/src/main/java/com/zchu/rxcache/stategy/IObservableStrategy.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,20 @@ | ||
package com.zchu.rxcache.stategy; | ||
|
||
|
||
import com.zchu.rxcache.RxCache; | ||
import com.zchu.rxcache.data.CacheResult; | ||
|
||
import java.lang.reflect.Type; | ||
|
||
import io.reactivex.Observable; | ||
|
||
|
||
/** | ||
* author : zchu | ||
* date : 2017/10/11 | ||
* desc : | ||
*/ | ||
public interface IObservableStrategy { | ||
|
||
<T> Observable<CacheResult<T>> execute(RxCache rxCache, String key, Observable<T> source, Type type); | ||
} |
16 changes: 1 addition & 15 deletions
16
rxcache/src/main/java/com/zchu/rxcache/stategy/IStrategy.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 |
---|---|---|
@@ -1,23 +1,9 @@ | ||
package com.zchu.rxcache.stategy; | ||
|
||
|
||
import com.zchu.rxcache.RxCache; | ||
import com.zchu.rxcache.data.CacheResult; | ||
|
||
import org.reactivestreams.Publisher; | ||
|
||
import java.lang.reflect.Type; | ||
|
||
import io.reactivex.Flowable; | ||
import io.reactivex.Observable; | ||
|
||
|
||
/** | ||
* 作者: 赵成柱 on 2016/9/12 0012. | ||
*/ | ||
public interface IStrategy { | ||
|
||
<T> Observable<CacheResult<T>> execute(RxCache rxCache, String key, Observable<T> source, Type type); | ||
public interface IStrategy extends IObservableStrategy,IFlowableStrategy { | ||
|
||
<T> Publisher<CacheResult<T>> flow(RxCache rxCache, String key, Flowable<T> source, Type type); | ||
} |
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
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