v0.8.2c: added reviews to the structure of update services
This commit is contained in:
@@ -21,6 +21,8 @@
|
||||
|
||||
package com.shatteredpixel.shatteredpixeldungeon.services.updates;
|
||||
|
||||
//TODO with install and review functionality, this service is less and less just about updates
|
||||
// perhaps rename to PlatformService, StoreService, DistributionService, etc?
|
||||
public abstract class UpdateService {
|
||||
|
||||
public static abstract class UpdateResultCallback {
|
||||
@@ -41,4 +43,10 @@ public abstract class UpdateService {
|
||||
|
||||
public abstract void initializeInstall();
|
||||
|
||||
public static abstract class ReviewResultCallback {
|
||||
public abstract void onComplete();
|
||||
}
|
||||
|
||||
public abstract void initializeReview( ReviewResultCallback callback );
|
||||
|
||||
}
|
||||
|
||||
@@ -65,4 +65,10 @@ public class DebugUpdates extends UpdateService {
|
||||
//does nothing
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initializeReview(ReviewResultCallback callback) {
|
||||
//does nothing
|
||||
callback.onComplete();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -135,4 +135,9 @@ public class GitHubUpdates extends UpdateService {
|
||||
//does nothing, always installed
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initializeReview(ReviewResultCallback callback) {
|
||||
//does nothing, no review functionality here
|
||||
callback.onComplete();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user