public static class DataTrackOptions.Builder extends Object
DataTrackOptions
.
All methods are optional.
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
DataTrackOptions |
build()
Builds the data track options.
|
DataTrackOptions.Builder |
maxPacketLifeTime(int maxPacketLifeTime)
Maximum retransmit time in milliseconds.
|
DataTrackOptions.Builder |
maxRetransmits(int maxRetransmits)
Maximum number of retransmitted messages.
|
DataTrackOptions.Builder |
name(String name)
Data track name.
|
DataTrackOptions.Builder |
ordered(boolean ordered)
Ordered transmission of messages.
|
public DataTrackOptions.Builder ordered(boolean ordered)
true
.public DataTrackOptions.Builder maxPacketLifeTime(int maxPacketLifeTime)
public DataTrackOptions.Builder maxRetransmits(int maxRetransmits)
public DataTrackOptions.Builder name(String name)
public DataTrackOptions build()
Max packet life time and max retransmits are mutually exclusive. This means
that only one of these values can be set to a non default value at a time otherwise
a IllegalStateException
occurs.