Added in API level 31

Builder

class Builder
kotlin.Any
   ↳ android.telephony.data.NetworkSliceInfo.Builder

Provides a convenient way to set the fields of a NetworkSliceInfo when creating a new instance.

The example below shows how you might create a new SliceInfo:

<code>
 
  SliceInfo response = new SliceInfo.Builder()
      .setSliceServiceType(SLICE_SERVICE_TYPE_URLLC)
      .build();
  </code>

Summary

Public constructors

Default constructor for Builder.

Public methods
NetworkSliceInfo

Build the NetworkSliceInfo.

NetworkSliceInfo.Builder
setMappedHplmnSliceDifferentiator(mappedHplmnSliceDifferentiator: Int)

Set the HPLMN Slice Differentiator.

NetworkSliceInfo.Builder
setMappedHplmnSliceServiceType(mappedHplmnSliceServiceType: Int)

Set the HPLMN Slice Service Type.

NetworkSliceInfo.Builder
setSliceDifferentiator(sliceDifferentiator: Int)

Set the Slice Differentiator.

NetworkSliceInfo.Builder
setSliceServiceType(mSliceServiceType: Int)

Set the Slice Service Type.

NetworkSliceInfo.Builder
setStatus(status: Int)

Set the slice status.

Public constructors

Builder

Added in API level 31
Builder()

Default constructor for Builder.

Public methods

build

Added in API level 31
fun build(): NetworkSliceInfo

Build the NetworkSliceInfo.

Return
NetworkSliceInfo the NetworkSliceInfo object. This value cannot be null.

setMappedHplmnSliceDifferentiator

Added in API level 31
fun setMappedHplmnSliceDifferentiator(mappedHplmnSliceDifferentiator: Int): NetworkSliceInfo.Builder

Set the HPLMN Slice Differentiator.

A value of SLICE_DIFFERENTIATOR_NO_SLICE indicates that there is no corresponding Slice of the HPLMN.
Parameters
mappedHplmnSliceDifferentiator Int: Value is between MIN_SLICE_DIFFERENTIATOR and MAX_SLICE_DIFFERENTIATOR inclusive
Return
NetworkSliceInfo.Builder The same instance of the builder. This value cannot be null.
Exceptions
java.lang.IllegalArgumentException if the parameter is not in the expected range.

setMappedHplmnSliceServiceType

Added in API level 31
fun setMappedHplmnSliceServiceType(mappedHplmnSliceServiceType: Int): NetworkSliceInfo.Builder

Set the HPLMN Slice Service Type.

Parameters
mappedHplmnSliceServiceType Int: Value is android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_NONE, android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_EMBB, android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_URLLC, or android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_MIOT
Return
NetworkSliceInfo.Builder The same instance of the builder. This value cannot be null.

setSliceDifferentiator

Added in API level 31
fun setSliceDifferentiator(sliceDifferentiator: Int): NetworkSliceInfo.Builder

Set the Slice Differentiator.

A value of SLICE_DIFFERENTIATOR_NO_SLICE indicates that there is no corresponding Slice.
Parameters
sliceDifferentiator Int: Value is between MIN_SLICE_DIFFERENTIATOR and MAX_SLICE_DIFFERENTIATOR inclusive
Return
NetworkSliceInfo.Builder The same instance of the builder. This value cannot be null.
Exceptions
java.lang.IllegalArgumentException if the parameter is not in the expected range.

setSliceServiceType

Added in API level 31
fun setSliceServiceType(mSliceServiceType: Int): NetworkSliceInfo.Builder

Set the Slice Service Type.

Parameters
mSliceServiceType Int: Value is android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_NONE, android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_EMBB, android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_URLLC, or android.telephony.data.NetworkSliceInfo#SLICE_SERVICE_TYPE_MIOT
Return
NetworkSliceInfo.Builder The same instance of the builder. This value cannot be null.