Class SIPResponse
Class for a SIP Response message
Inherited Members
Namespace: SipLib.Core
Assembly: SipLib.dll
Syntax
public class SIPResponse : SIPMessage
Constructors
| Edit this page View SourceSIPResponse(SIPResponseStatusCodesEnum, string?, SIPEndPoint)
Constructor to use when building a new SIP response message.
Declaration
public SIPResponse(SIPResponseStatusCodesEnum responseType, string? reasonPhrase, SIPEndPoint localSIPEndPoint)
Parameters
Type | Name | Description |
---|---|---|
SIPResponseStatusCodesEnum | responseType | Status code. |
string | reasonPhrase | Reason phrase. |
SIPEndPoint | localSIPEndPoint | Local endpoint that is sending or receiving the SIP response message. |
Fields
| Edit this page View SourceReasonPhrase
Response reason phrase
Declaration
public string? ReasonPhrase
Field Value
Type | Description |
---|---|
string |
SIPVersion
SIP version number
Declaration
public string? SIPVersion
Field Value
Type | Description |
---|---|
string |
Status
Response status enumeration
Declaration
public SIPResponseStatusCodesEnum Status
Field Value
Type | Description |
---|---|
SIPResponseStatusCodesEnum |
StatusCode
SIP response status code integer
Declaration
public int StatusCode
Field Value
Type | Description |
---|---|
int |
Methods
| Edit this page View SourceCopy()
Creates an identical copy of the SIP Response for the caller. This is a deep copy.
Declaration
public SIPResponse Copy()
Returns
Type | Description |
---|---|
SIPResponse | New copy of the SIPResponse. |
ParseSIPResponse(SIPMessage)
Parses a SIPMessage object into a SIPResponse object
Declaration
public static SIPResponse ParseSIPResponse(SIPMessage sipMessage)
Parameters
Type | Name | Description |
---|---|---|
SIPMessage | sipMessage | Must contain a valid SIPMessage object |
Returns
Type | Description |
---|---|
SIPResponse | Returns a new SIPResponse object |
ParseSIPResponse(string)
Parses a string containing a SIPMessage object into a SIPResponse object
Declaration
public static SIPResponse ParseSIPResponse(string sipMessageStr)
Parameters
Type | Name | Description |
---|---|---|
string | sipMessageStr |
Returns
Type | Description |
---|---|
SIPResponse | Returns a new SIPResponse message |
ToByteArray()
Converts this SIP response message to a byte array.
Declaration
public byte[] ToByteArray()
Returns
Type | Description |
---|---|
byte[] |
ToString()
Converts this SIPResponse message to a string.
Declaration
public string ToString()
Returns
Type | Description |
---|---|
string | Returns the string version of this object. |