Builder
open classBuilder
| kotlin.Any | |
| ↳ | android.net.sip.SipProfile.Builder |
Helper class for creating a SipProfile.
Summary
| Public constructors | |
|---|---|
Builder(profile: SipProfile!)Creates a builder based on the given profile. |
|
|
Constructor. |
|
|
Constructor. |
|
| Public methods | |
|---|---|
| open SipProfile! |
build()Builds and returns the SIP profile object. |
| open SipProfile.Builder! |
setAuthUserName(name: String!)Sets the username used for authentication. |
| open SipProfile.Builder! |
setAutoRegistration(flag: Boolean)Sets the auto. |
| open SipProfile.Builder! |
setDisplayName(displayName: String!)Sets the display name of the user. |
| open SipProfile.Builder! |
setOutboundProxy(outboundProxy: String!)Sets the outbound proxy of the SIP server. |
| open SipProfile.Builder! |
setPassword(password: String!)Sets the password of the SIP account |
| open SipProfile.Builder! |
Sets the port number of the server. |
| open SipProfile.Builder! |
setProfileName(name: String!)Sets the name of the profile. |
| open SipProfile.Builder! |
setProtocol(protocol: String!)Sets the protocol used to connect to the SIP server. |
| open SipProfile.Builder! |
setSendKeepAlive(flag: Boolean)Sets the send keep-alive flag. |
Public constructors
Builder
Builder(profile: SipProfile!)
Creates a builder based on the given profile.
Builder
Builder(uriString: String!)
Constructor.
| Parameters | |
|---|---|
uriString |
String!: the URI string as "sip:@" |
| Exceptions | |
|---|---|
java.text.ParseException |
if the string is not a valid URI |
Builder
Builder(
username: String!,
serverDomain: String!)
Constructor.
| Parameters | |
|---|---|
username |
String!: username of the SIP account |
serverDomain |
String!: the SIP server domain; if the network address is different from the domain, use setOutboundProxy to set server address |
| Exceptions | |
|---|---|
java.text.ParseException |
if the parameters are not valid |
Public methods
build
open funbuild(): SipProfile!
Deprecated: Deprecated in Java.
Builds and returns the SIP profile object.
| Return | |
|---|---|
SipProfile! |
the profile object created |
setAuthUserName
open funsetAuthUserName(name: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the username used for authentication.
| Parameters | |
|---|---|
name |
String!: authentication username of the profile |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setAutoRegistration
open funsetAutoRegistration(flag: Boolean): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the auto. registration flag.
| Parameters | |
|---|---|
flag |
Boolean: true if the profile will be registered automatically, false otherwise |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setDisplayName
open funsetDisplayName(displayName: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the display name of the user.
| Parameters | |
|---|---|
displayName |
String!: display name of the user |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setOutboundProxy
open funsetOutboundProxy(outboundProxy: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the outbound proxy of the SIP server.
| Parameters | |
|---|---|
outboundProxy |
String!: the network address of the outbound proxy |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setPassword
open funsetPassword(password: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the password of the SIP account
| Parameters | |
|---|---|
password |
String!: password of the SIP account |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setPort
open funsetPort(port: Int): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the port number of the server. By default, it is 5060.
| Parameters | |
|---|---|
port |
Int: port number of the server |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
| Exceptions | |
|---|---|
java.lang.IllegalArgumentException |
if the port number is out of range |
setProfileName
open funsetProfileName(name: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the name of the profile. This name is given by user.
| Parameters | |
|---|---|
name |
String!: name of the profile |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
setProtocol
open funsetProtocol(protocol: String!): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the protocol used to connect to the SIP server. Currently, only "UDP" and "TCP" are supported.
| Parameters | |
|---|---|
protocol |
String!: the protocol string |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |
| Exceptions | |
|---|---|
java.lang.IllegalArgumentException |
if the protocol is not recognized |
setSendKeepAlive
open funsetSendKeepAlive(flag: Boolean): SipProfile.Builder!
Deprecated: Deprecated in Java.
Sets the send keep-alive flag.
| Parameters | |
|---|---|
flag |
Boolean: true if sending keep-alive message is required, false otherwise |
| Return | |
|---|---|
SipProfile.Builder! |
this builder object |