FileDocCategorySizeDatePackage
INetworkScoreService.javaAPI DocAndroid 5.1 API8829Sat Mar 14 05:48:02 GMT 2015android.net

INetworkScoreService

public interface INetworkScoreService implements android.os.IInterface
A service for updating network scores from a network scorer application.
hide

Fields Summary
Constructors Summary
Methods Summary
public booleanclearScores()
Clear all scores.

return
whether the clear was successful.
throws
SecurityException if the caller is neither the current active scorer nor the system.

public voiddisableScoring()
Disable the current active scorer and clear existing scores.

throws
SecurityException if the caller is not the current scorer or the system.

public voidregisterNetworkScoreCache(int networkType, android.net.INetworkScoreCache scoreCache)
Register a network subsystem for scoring.

param
networkType the type of network this cache can handle. See {@link NetworkKey#type}.
param
scoreCache implementation of {@link INetworkScoreCache} to store the scores.
throws
SecurityException if the caller is not the system.
throws
IllegalArgumentException if a score cache is already registed for this type.
hide

public booleansetActiveScorer(java.lang.String packageName)
Set the active scorer and clear existing scores.

param
packageName the package name of the new scorer to use.
return
true if the operation succeeded, or false if the new package is not a valid scorer.
throws
SecurityException if the caller is not the system.

public booleanupdateScores(android.net.ScoredNetwork[] networks)
Update scores.

return
whether the update was successful.
throws
SecurityException if the caller is not the current active scorer.