VcnManager.VcnStatusCallback


public static abstract class VcnManager.VcnStatusCallback
extends Object

java.lang.Object
   ↳ android.net.vcn.VcnManager.VcnStatusCallback


VcnStatusCallback is the interface for Carrier apps to receive updates for their VCNs.

VcnStatusCallbacks may be registered before VcnConfigs are provided for a subscription group.

Summary

Public constructors

VcnStatusCallback()

Public methods

abstract void onGatewayConnectionError(String gatewayConnectionName, int errorCode, Throwable detail)

Invoked when a VCN Gateway Connection corresponding to this callback's subscription group encounters an error.

abstract void onStatusChanged(int statusCode)

Invoked when status of the VCN for this callback's subscription group changes.

Inherited methods

Object clone()

Creates and returns a copy of this object.

boolean equals(Object obj)

Indicates whether some other object is "equal to" this one.

void finalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

final Class<?> getClass()

Returns the runtime class of this Object.

int hashCode()

Returns a hash code value for the object.

final void notify()

Wakes up a single thread that is waiting on this object's monitor.

final void notifyAll()

Wakes up all threads that are waiting on this object's monitor.

String toString()

Returns a string representation of the object.

final void wait(long timeoutMillis, int nanos)

Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

final void wait(long timeoutMillis)

Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

final void wait()

Causes the current thread to wait until it is awakened, typically by being notified or interrupted.

Public constructors

VcnStatusCallback

Added in API level 31
public VcnStatusCallback ()

Public methods

onGatewayConnectionError

Added in API level 31
public abstract void onGatewayConnectionError (String gatewayConnectionName, 
                int errorCode, 
                Throwable detail)

Invoked when a VCN Gateway Connection corresponding to this callback's subscription group encounters an error.

Parameters
gatewayConnectionName String: the String GatewayConnection name for the GatewayConnection encountering an error. This will match the name for exactly one VcnGatewayConnectionConfig for the VcnConfig configured for this callback's subscription group This value cannot be null.

errorCode int: the code to indicate the error that occurred. This value will be one of VCN_ERROR_CODE_*. Value is VcnManager.VCN_ERROR_CODE_INTERNAL_ERROR, VcnManager.VCN_ERROR_CODE_CONFIG_ERROR, or VcnManager.VCN_ERROR_CODE_NETWORK_ERROR

detail Throwable: Throwable to provide additional information about the error, or null if none

onStatusChanged

Added in API level 31
public abstract void onStatusChanged (int statusCode)

Invoked when status of the VCN for this callback's subscription group changes.

Parameters
statusCode int: the code for the status change encountered by this VcnStatusCallback's subscription group. This value will be one of VCN_STATUS_CODE_*. Value is VcnManager.VCN_STATUS_CODE_NOT_CONFIGURED, VcnManager.VCN_STATUS_CODE_INACTIVE, VcnManager.VCN_STATUS_CODE_ACTIVE, or VcnManager.VCN_STATUS_CODE_SAFE_MODE