Documentation
¶
Index ¶
- Constants
- type Accept
- func (this *Accept) AllowsAllContentSubTypes() bool
- func (this *Accept) AllowsAllContentTypes() bool
- func (this *Accept) EncodeBody() string
- func (this *Accept) GetContentSubType() string
- func (this *Accept) GetContentType() string
- func (this *Accept) GetMediaRange() *MediaRange
- func (this *Accept) GetQValue() float32
- func (this *Accept) HasQValue() bool
- func (this *Accept) RemoveQValue()
- func (this *Accept) SetContentSubType(subtype string)
- func (this *Accept) SetContentType(mtype string)
- func (this *Accept) SetMediaRange(m *MediaRange)
- func (this *Accept) SetQValue(q float32) (InvalidArgumentException error)
- func (this *Accept) String() string
- type AcceptEncoding
- func (this *AcceptEncoding) EncodeBody() string
- func (this *AcceptEncoding) GetEncoding() string
- func (this *AcceptEncoding) GetQValue() float32
- func (this *AcceptEncoding) HasQValue() bool
- func (this *AcceptEncoding) RemoveQValue()
- func (this *AcceptEncoding) SetEncoding(encoding string) (ParseException error)
- func (this *AcceptEncoding) SetQValue(q float32) (InvalidArgumentException error)
- func (this *AcceptEncoding) String() string
- type AcceptEncodingHeader
- type AcceptEncodingList
- type AcceptHeader
- type AcceptLanguage
- func (this *AcceptLanguage) EncodeBody() string
- func (this *AcceptLanguage) GetAcceptLanguage() string
- func (this *AcceptLanguage) GetLanguageRange() string
- func (this *AcceptLanguage) GetQValue() float32
- func (this *AcceptLanguage) HasQValue() bool
- func (this *AcceptLanguage) RemoveQValue()
- func (this *AcceptLanguage) SetAcceptLanguage(language string)
- func (this *AcceptLanguage) SetLanguageRange(languageRange string)
- func (this *AcceptLanguage) SetQValue(q float32) (InvalidArgumentException error)
- func (this *AcceptLanguage) String() string
- type AcceptLanguageHeader
- type AcceptLanguageList
- type AcceptList
- type AddressHeader
- type AddressParameters
- type AddressParametersHeader
- type AlertInfo
- type AlertInfoHeader
- type AlertInfoList
- type Allow
- type AllowEvents
- type AllowEventsHeader
- type AllowEventsList
- type AllowHeader
- type AllowList
- type Authentication
- func (this *Authentication) EncodeBody() string
- func (this *Authentication) GetAlgorithm() string
- func (this *Authentication) GetCNonce() string
- func (this *Authentication) GetDomain() string
- func (this *Authentication) GetNonce() string
- func (this *Authentication) GetNonceCount() int
- func (this *Authentication) GetOpaque() string
- func (this *Authentication) GetQop() string
- func (this *Authentication) GetRealm() string
- func (this *Authentication) GetResponse() string
- func (this *Authentication) GetScheme() string
- func (this *Authentication) GetURI() address.URI
- func (this *Authentication) GetUsername() string
- func (this *Authentication) IsStale() bool
- func (this *Authentication) SetAlgorithm(algorithm string) (ParseException error)
- func (this *Authentication) SetCNonce(cnonce string) (ParseException error)
- func (this *Authentication) SetChallenge(challenge Challenge)
- func (this *Authentication) SetDomain(domain string) (ParseException error)
- func (this *Authentication) SetNonce(nonce string) (ParseException error)
- func (this *Authentication) SetNonceCount(nonceCount int) (ParseException error)
- func (this *Authentication) SetOpaque(opaque string) (ParseException error)
- func (this *Authentication) SetParameter(name, value string) error
- func (this *Authentication) SetQop(qop string) (ParseException error)
- func (this *Authentication) SetRealm(realm string) (ParseException error)
- func (this *Authentication) SetResponse(response string) (ParseException error)
- func (this *Authentication) SetScheme(scheme string)
- func (this *Authentication) SetStale(stale bool)
- func (this *Authentication) SetURI(uri address.URI) error
- func (this *Authentication) SetUsername(username string) (ParseException error)
- func (this *Authentication) String() string
- type AuthenticationHeader
- type AuthenticationInfo
- func (this *AuthenticationInfo) Add(nv *core.NameValue)
- func (this *AuthenticationInfo) EncodeBody() string
- func (this *AuthenticationInfo) GetAuthInfo(name string) *core.NameValue
- func (this *AuthenticationInfo) GetAuthenticationInfo() string
- func (this *AuthenticationInfo) GetCNonce() string
- func (this *AuthenticationInfo) GetNextNonce() string
- func (this *AuthenticationInfo) GetNonceCount() int
- func (this *AuthenticationInfo) GetQop() string
- func (this *AuthenticationInfo) GetResponse() string
- func (this *AuthenticationInfo) SetCNonce(cNonce string) (ParseException error)
- func (this *AuthenticationInfo) SetNextNonce(nextNonce string) (ParseException error)
- func (this *AuthenticationInfo) SetNonceCount(nonceCount int) (ParseException error)
- func (this *AuthenticationInfo) SetParameter(name, value string) error
- func (this *AuthenticationInfo) SetQop(qop string) (ParseException error)
- func (this *AuthenticationInfo) SetResponse(response string) (ParseException error)
- func (this *AuthenticationInfo) String() string
- type AuthenticationInfoHeader
- type Authorization
- type AuthorizationHeader
- type CSeq
- func (this *CSeq) EncodeBody() string
- func (this *CSeq) GetMethod() string
- func (this *CSeq) GetSequenceNumber() int
- func (this *CSeq) SetMethod(meth string) (ParseException error)
- func (this *CSeq) SetSequenceNumber(sequenceNumber int) (InvalidArgumentException error)
- func (this *CSeq) String() string
- type CSeqHeader
- type CallID
- type CallIdHeader
- type CallIdentifier
- func (this *CallIdentifier) GetHost() string
- func (this *CallIdentifier) GetLocalId() string
- func (this *CallIdentifier) SetCallID(cid string) (IllegalArgumentException error)
- func (this *CallIdentifier) SetHost(host string)
- func (this *CallIdentifier) SetLocalId(localId string)
- func (this *CallIdentifier) String() string
- type CallInfo
- type CallInfoHeader
- type CallInfoList
- type Challenge
- func (this *Challenge) GetAlgorithm() string
- func (this *Challenge) GetAuthParams() *core.NameValueList
- func (this *Challenge) GetDomain() string
- func (this *Challenge) GetOpaque() string
- func (this *Challenge) GetParameter(name string) string
- func (this *Challenge) GetQOP() string
- func (this *Challenge) GetRealm() string
- func (this *Challenge) GetResponse() string
- func (this *Challenge) GetScheme() string
- func (this *Challenge) GetSignature() string
- func (this *Challenge) GetSignedBy() string
- func (this *Challenge) GetStale() string
- func (this *Challenge) GetURI() string
- func (this *Challenge) HasParameter(name string) bool
- func (this *Challenge) HasParameters() bool
- func (this *Challenge) RemoveParameter(name string) bool
- func (this *Challenge) RemoveParameters()
- func (this *Challenge) SetAuthParams(a *core.NameValueList)
- func (this *Challenge) SetParameter(nv *core.NameValue)
- func (this *Challenge) SetScheme(s string)
- func (this *Challenge) String() string
- type Contact
- func (this *Contact) EncodeBody() string
- func (this *Contact) GetAddress() address.Address
- func (this *Contact) GetContactList() *ContactList
- func (this *Contact) GetContactParms() *core.NameValueList
- func (this *Contact) GetExpires() int
- func (this *Contact) GetQValue() float32
- func (this *Contact) GetWildCardFlag() bool
- func (this *Contact) HasQValue() bool
- func (this *Contact) RemoveQValue()
- func (this *Contact) SetAddress(addr address.Address)
- func (this *Contact) SetContactList(cl *ContactList)
- func (this *Contact) SetExpires(expiryDeltaSeconds int) (InvalidArgumentException error)
- func (this *Contact) SetQValue(q float32) (InvalidArgumentException error)
- func (this *Contact) SetWildCardFlag(w bool)
- func (this *Contact) String() string
- type ContactHeader
- type ContactList
- type ContentDisposition
- func (this *ContentDisposition) EncodeBody() string
- func (this *ContentDisposition) GetContentDisposition() string
- func (this *ContentDisposition) GetDispositionType() string
- func (this *ContentDisposition) GetHandling() string
- func (this *ContentDisposition) SetDispositionType(dispositionType string) (ParseException error)
- func (this *ContentDisposition) SetHandling(handling string) (ParseException error)
- func (this *ContentDisposition) String() string
- type ContentDispositionHeader
- type ContentEncoding
- type ContentEncodingHeader
- type ContentEncodingList
- type ContentLanguage
- func (this *ContentLanguage) EncodeBody() string
- func (this *ContentLanguage) GetContentLanguage() string
- func (this *ContentLanguage) GetLanguageTag() string
- func (this *ContentLanguage) SetContentLanguage(language string)
- func (this *ContentLanguage) SetLanguageTag(languageTag string)
- func (this *ContentLanguage) String() string
- type ContentLanguageHeader
- type ContentLanguageList
- type ContentLength
- type ContentLengthHeader
- type ContentType
- func (this *ContentType) CompareMediaRange(media string) bool
- func (this *ContentType) EncodeBody() string
- func (this *ContentType) GetCharSet() string
- func (this *ContentType) GetContentSubType() string
- func (this *ContentType) GetContentType() string
- func (this *ContentType) GetMediaRange() *MediaRange
- func (this *ContentType) GetMediaSubType() string
- func (this *ContentType) GetMediaType() string
- func (this *ContentType) SetContentSubType(contentType string) (ParseException error)
- func (this *ContentType) SetContentType(contentType string) (ParseException error)
- func (this *ContentType) SetContentTypeSubType(contentType, contentSubType string)
- func (this *ContentType) SetMediaRange(m *MediaRange)
- func (this *ContentType) String() string
- type ContentTypeHeader
- type Date
- type DateHeader
- type Encoding
- type ErrorInfo
- func (this *ErrorInfo) EncodeBody() string
- func (this *ErrorInfo) GetErrorInfo() address.URI
- func (this *ErrorInfo) GetErrorMessage() string
- func (this *ErrorInfo) SetErrorInfo(errorInfo address.URI)
- func (this *ErrorInfo) SetErrorMessage(message string) (ParseException error)
- func (this *ErrorInfo) String() string
- type ErrorInfoHeader
- type ErrorInfoList
- type Event
- func (this *Event) EncodeBody() string
- func (this *Event) GetEventId() string
- func (this *Event) GetEventType() string
- func (this *Event) Match(matchTarGet *Event) bool
- func (this *Event) SetEventId(eventId string) (ParseException error)
- func (this *Event) SetEventType(eventType string) (ParseException error)
- func (this *Event) String() string
- type EventHeader
- type Expires
- type ExpiresHeader
- type Extension
- type ExtensionHeader
- type ExtensionHeaderList
- type ExtensionHeaderLister
- type From
- func (this *From) CloneTo(to *To)
- func (this *From) EncodeBody() string
- func (this *From) GetDisplayName() string
- func (this *From) GetHostPort() (*core.HostPort, error)
- func (this *From) GetTag() string
- func (this *From) GetUserAtHostPort() string
- func (this *From) HasTag() bool
- func (this *From) RemoveTag()
- func (this *From) SetAddress(addr address.Address)
- func (this *From) SetTag(t string) (ParseException error)
- func (this *From) String() string
- type FromHeader
- type Header
- type InReplyTo
- type InReplyToHeader
- type InReplyToList
- type Lister
- type MaxForwards
- func (this *MaxForwards) DecrementMaxForwards() error
- func (this *MaxForwards) EncodeBody() string
- func (this *MaxForwards) GetMaxForwards() int
- func (this *MaxForwards) HasReachedZero() bool
- func (this *MaxForwards) SetMaxForwards(maxForwards int) (InvalidArgumentException error)
- func (this *MaxForwards) String() string
- type MaxForwardsHeader
- type MediaRange
- type MediaType
- type MimeVersion
- func (this *MimeVersion) EncodeBody() string
- func (this *MimeVersion) GetMajorVersion() int
- func (this *MimeVersion) GetMinorVersion() int
- func (this *MimeVersion) SetMajorVersion(majorVersion int) (InvalidArgumentException error)
- func (this *MimeVersion) SetMinorVersion(minorVersion int) (InvalidArgumentException error)
- func (this *MimeVersion) String() string
- type MimeVersionHeader
- type MinExpires
- type MinExpiresHeader
- type OptionTag
- type Organization
- type OrganizationHeader
- type Parameters
- func (this *Parameters) EncodeBody() string
- func (this *Parameters) GetNameValue(parameterName string) *core.NameValue
- func (this *Parameters) GetParameter(name string) string
- func (this *Parameters) GetParameterNames() *list.List
- func (this *Parameters) GetParameterValue(name string) string
- func (this *Parameters) GetParameters() *core.NameValueList
- func (this *Parameters) HasParameter(parameterName string) bool
- func (this *Parameters) HasParameters() bool
- func (this *Parameters) RemoveParameter(name string)
- func (this *Parameters) RemoveParameters()
- func (this *Parameters) SetParameter(name, value string) (ParseException error)
- func (this *Parameters) SetParameterFromNameValue(nameValue *core.NameValue)
- func (this *Parameters) SetParameters(parameters *core.NameValueList)
- func (this *Parameters) SetQuotedParameter(name, value string)
- func (this *Parameters) String() string
- type ParametersHeader
- type Priority
- type PriorityHeader
- type Protocol
- func (this *Protocol) GetProtocolName() string
- func (this *Protocol) GetProtocolVersion() string
- func (this *Protocol) GetTransport() string
- func (this *Protocol) SetProtocolName(p string)
- func (this *Protocol) SetProtocolVersion(p string)
- func (this *Protocol) SetTransport(t string)
- func (this *Protocol) String() string
- type ProxyAuthenticate
- type ProxyAuthenticateHeader
- type ProxyAuthenticateList
- type ProxyAuthorization
- type ProxyAuthorizationHeader
- type ProxyRequire
- type ProxyRequireHeader
- type ProxyRequireList
- type QValue
- type RAck
- func (this *RAck) EncodeBody() string
- func (this *RAck) GetCSeqNumber() int
- func (this *RAck) GetMethod() string
- func (this *RAck) GetRSeqNumber() int
- func (this *RAck) SetCSeqNumber(cSeqNumber int) (InvalidArgumentException error)
- func (this *RAck) SetMethod(method string) (ParseException error)
- func (this *RAck) SetRSeqNumber(rSeqNumber int) (InvalidArgumentException error)
- func (this *RAck) String() string
- type RAckHeader
- type RSeq
- type RSeqHeader
- type Reason
- func (this *Reason) EncodeBody() string
- func (this *Reason) GetCause() int
- func (this *Reason) GetName() string
- func (this *Reason) GetProtocol() string
- func (this *Reason) GetText() string
- func (this *Reason) SetCause(cause int) (InvalidArgumentException error)
- func (this *Reason) SetProtocol(protocol string) (ParseException error)
- func (this *Reason) SetText(text string) (ParseException error)
- func (this *Reason) String() string
- type ReasonHeader
- type ReasonList
- type RecordRoute
- type RecordRouteHeader
- type RecordRouteList
- type ReferTo
- type ReferToHeader
- type ReplyTo
- type ReplyToHeader
- type RequestLine
- func (this *RequestLine) GetMethod() string
- func (this *RequestLine) GetSipVersion() string
- func (this *RequestLine) GetUri() address.URI
- func (this *RequestLine) GetVersionMajor() string
- func (this *RequestLine) GetVersionMinor() string
- func (this *RequestLine) SetMethod(method string)
- func (this *RequestLine) SetSIPVersion(sipVersion string)
- func (this *RequestLine) SetSipVersion(s string)
- func (this *RequestLine) SetUri(uri address.URI)
- func (this *RequestLine) String() string
- type Require
- type RequireHeader
- type RequireList
- type RetryAfter
- func (this *RetryAfter) EncodeBody() string
- func (this *RetryAfter) GetComment() string
- func (this *RetryAfter) GetDuration() int
- func (this *RetryAfter) GetRetryAfter() int
- func (this *RetryAfter) HasComment() bool
- func (this *RetryAfter) RemoveComment()
- func (this *RetryAfter) RemoveDuration()
- func (this *RetryAfter) SetComment(comment string) (ParseException error)
- func (this *RetryAfter) SetDuration(duration int) (InvalidArgumentException error)
- func (this *RetryAfter) SetRetryAfter(retryAfter int) (InvalidArgumentException error)
- func (this *RetryAfter) String() string
- type RetryAfterHeader
- type Route
- type RouteHeader
- type RouteList
- type SIPHeader
- func (this *SIPHeader) Clone() interface{}
- func (this *SIPHeader) EncodeBody() string
- func (this *SIPHeader) GetHeaderName() string
- func (this *SIPHeader) GetHeaderValue() string
- func (this *SIPHeader) GetName() string
- func (this *SIPHeader) GetValue() string
- func (this *SIPHeader) IsHeaderList() bool
- func (this *SIPHeader) SetHeaderName(hdrname string)
- func (this *SIPHeader) String() string
- type SIPHeaderList
- func (this *SIPHeaderList) Clone() interface{}
- func (this *SIPHeaderList) Concatenate(shl SIPHeaderLister, topFlag bool)
- func (this *SIPHeaderList) EncodeBody() string
- func (this *SIPHeaderList) GetHeadersAsEncodedStrings() *list.List
- func (this *SIPHeaderList) IsHeaderList() bool
- func (this *SIPHeaderList) String() string
- type SIPHeaderLister
- type Server
- type ServerHeader
- type StatusLine
- func (this *StatusLine) GetReasonPhrase() string
- func (this *StatusLine) GetSipVersion() string
- func (this *StatusLine) GetStatusCode() int
- func (this *StatusLine) GetVersionMajor() string
- func (this *StatusLine) GetVersionMinor() string
- func (this *StatusLine) SetMatchStatusClass(flag bool)
- func (this *StatusLine) SetReasonPhrase(reasonPhrase string)
- func (this *StatusLine) SetSipVersion(s string)
- func (this *StatusLine) SetStatusCode(statusCode int)
- func (this *StatusLine) String() string
- type Subject
- type SubjectHeader
- type SubscriptionState
- func (this *SubscriptionState) EncodeBody() string
- func (this *SubscriptionState) GetExpires() int
- func (this *SubscriptionState) GetReasonCode() string
- func (this *SubscriptionState) GetRetryAfter() int
- func (this *SubscriptionState) GetState() string
- func (this *SubscriptionState) SetExpires(expires int) (InvalidArgumentException error)
- func (this *SubscriptionState) SetReasonCode(reasonCode string) (ParseException error)
- func (this *SubscriptionState) SetRetryAfter(retryAfter int) (InvalidArgumentException error)
- func (this *SubscriptionState) SetState(state string) (ParseException error)
- func (this *SubscriptionState) String() string
- type SubscriptionStateHeader
- type Supported
- type SupportedHeader
- type SupportedList
- type TimeStamp
- func (this *TimeStamp) EncodeBody() string
- func (this *TimeStamp) GetDelay() float32
- func (this *TimeStamp) GetTimeStamp() float32
- func (this *TimeStamp) HasDelay() bool
- func (this *TimeStamp) RemoveDelay()
- func (this *TimeStamp) SetDelay(delay float32) (InvalidArgumentException error)
- func (this *TimeStamp) SetTimeStamp(timeStamp float32) (InvalidArgumentException error)
- func (this *TimeStamp) String() string
- type TimeStampHeader
- type To
- func (this *To) CloneFrom(from *From)
- func (this *To) EncodeBody() string
- func (this *To) GetDisplayName() string
- func (this *To) GetHostPort() (*core.HostPort, error)
- func (this *To) GetTag() string
- func (this *To) GetUserAtHostPort() string
- func (this *To) HasTag() bool
- func (this *To) RemoveTag()
- func (this *To) SetTag(t string) (ParseException error)
- func (this *To) String() string
- type ToHeader
- type Unsupported
- type UnsupportedHeader
- type UnsupportedList
- type UserAgent
- func (this *UserAgent) AddProductToken(pt string)
- func (this *UserAgent) EncodeBody() string
- func (this *UserAgent) EncodeProduct() string
- func (this *UserAgent) GetProduct() *list.List
- func (this *UserAgent) SetProduct(product *list.List) (ParseException error)
- func (this *UserAgent) String() string
- type UserAgentHeader
- type Via
- func (this *Via) EncodeBody() string
- func (this *Via) GetBranch() string
- func (this *Via) GetComment() string
- func (this *Via) GetHost() string
- func (this *Via) GetMAddr() string
- func (this *Via) GetMaddr() *core.Host
- func (this *Via) GetPort() int
- func (this *Via) GetProtocol() string
- func (this *Via) GetProtocolVersion() string
- func (this *Via) GetReceived() string
- func (this *Via) GetSentBy() *core.HostPort
- func (this *Via) GetSentProtocol() *Protocol
- func (this *Via) GetTTL() int
- func (this *Via) GetTransport() string
- func (this *Via) GetViaParms() *core.NameValueList
- func (this *Via) HasComment() bool
- func (this *Via) HasPort() bool
- func (this *Via) RemoveComment()
- func (this *Via) RemovePort()
- func (this *Via) SetBranch(branch string) (ParseException error)
- func (this *Via) SetComment(c string)
- func (this *Via) SetHost(host *core.Host)
- func (this *Via) SetHostFromString(host string) (ParseException error)
- func (this *Via) SetMAddr(mAddr string) (ParseException error)
- func (this *Via) SetPort(port int)
- func (this *Via) SetProtocol(protocol string) (ParseException error)
- func (this *Via) SetProtocolVersion(protocolVersion string)
- func (this *Via) SetReceived(received string) (ParseException error)
- func (this *Via) SetSentBy(s *core.HostPort)
- func (this *Via) SetSentProtocol(s *Protocol)
- func (this *Via) SetTTL(ttl int) (InvalidArgumentException error)
- func (this *Via) String() string
- type ViaHeader
- type ViaList
- type WWWAuthenticate
- type WWWAuthenticateHeader
- type WWWAuthenticateList
- type Warning
- func (this *Warning) EncodeBody() string
- func (this *Warning) GetAgent() string
- func (this *Warning) GetCode() int
- func (this *Warning) GetText() string
- func (this *Warning) SetAgent(host string) (ParseException error)
- func (this *Warning) SetCode(code int) (InvalidArgumentException error)
- func (this *Warning) SetText(text string) (ParseException error)
- func (this *Warning) String() string
- type WarningHeader
- type WarningList
Constants ¶
const ( /** * One or more network protocols contained in the session description * are not available. */ INCOMPATIBLE_NETWORK_PROTOCOL = 300 /** * One or more network address formats contained in the session * description are not available. */ INCOMPATIBLE_NETWORK_ADDRESS_FORMATS = 301 /** * One or more transport protocols described in the session description * are not available. */ INCOMPATIBLE_TRANSPORT_PROTOCOL = 302 /** * One or more bandwidth measurement units contained in the session * description were not understood. */ INCOMPATIBLE_BANDWIDTH_UNITS = 303 /** * One or more media types contained in the session description are * not available. */ MEDIA_TYPE_NOT_AVAILABLE = 304 /** * One or more media formats contained in the session description are * not available. */ INCOMPATIBLE_MEDIA_FORMAT = 305 /** * One or more of the media attributes in the session description are * not supported. */ ATTRIBUTE_NOT_UNDERSTOOD = 306 /** * A parameter other than those listed above was not understood. */ SESSION_DESCRIPTION_PARAMETER_NOT_UNDERSTOOD = 307 /** * The site where the user is located does not support multicast. */ MULTICAST_NOT_AVAILABLE = 330 /** * The site where the user is located does not support unicast * communication (usually due to the presence of a firewall). */ UNICAST_NOT_AVAILABLE = 331 /** * The bandwidth specified in the session description or defined by the * media exceeds that known to be available. */ INSUFFICIENT_BANDWIDTH = 370 /** * The warning text can include arbitrary information to be presented to * a human user, or logged. A system receiving this warning MUST NOT * take any automated action. */ MISCELLANEOUS_WARNING = 399 )
const ParameterNames_ACTION = "action"
const ParameterNames_ALERT = "alert"
const ParameterNames_ALGORITHM = "algorithm"
const ParameterNames_BRANCH = "branch"
const ParameterNames_CARD = "card"
const ParameterNames_CAUSE = "cause"
const ParameterNames_CNONCE = "cnonce"
const ParameterNames_COOKIE = "cookie"
const ParameterNames_DIGEST = "Digest"
const ParameterNames_DOMAIN = "domain"
const ParameterNames_DURATION = "duration"
const ParameterNames_EMERGENCY = "emergency"
const ParameterNames_EXPIRES = "expires"
const ParameterNames_HANDLING = "handling"
const ParameterNames_HIDDEN = "hidden"
const ParameterNames_ICON = "icon"
const ParameterNames_ID = "id"
const ParameterNames_INFO = "info"
const ParameterNames_MADDR = "maddr"
const ParameterNames_NC = "nc"
const ParameterNames_NEXT_NONCE = "nextnonce"
const ParameterNames_NONCE = "nonce"
const ParameterNames_NONCE_COUNT = "nc"
const ParameterNames_NON_URGENT = "non-urgent"
const ParameterNames_NORMAL = "normal"
const ParameterNames_OPAQUE = "opaque"
const ParameterNames_OPTIONAL = "optional"
const ParameterNames_PASSWORD = "password"
const ParameterNames_PROXY = "proxy"
const ParameterNames_PUBKEY = "pubkey"
const ParameterNames_PURPOSE = "purpose"
const ParameterNames_Q = "q"
const ParameterNames_QOP = "qop"
const ParameterNames_REALM = "realm"
const ParameterNames_RECEIVED = "received"
const ParameterNames_REDIRECT = "redirect"
const ParameterNames_RENDER = "render"
const ParameterNames_REQUIRED = "required"
const ParameterNames_RESPONSE = "response"
const ParameterNames_RESPONSE_AUTH = "rspauth"
const ParameterNames_SESSION = "session"
const ParameterNames_SIGNATURE = "signature"
const ParameterNames_SIGNED_BY = "signed-by"
const ParameterNames_STALE = "stale"
const ParameterNames_TAG = "tag"
const ParameterNames_TEXT = "text"
const ParameterNames_TRANSPORT = "transport"
const ParameterNames_TTL = "ttl"
const ParameterNames_URGENT = "urgent"
const ParameterNames_URI = "uri"
const ParameterNames_USERNAME = "username"
const ParameterNames_VERSION = "version"
const SIPConstants_BRANCH_MAGIC_COOKIE = "z9hG4bK"
* Prefix for the branch parameter that identifies
- BIS 09 compatible branch strings. This indicates
- that the branch may be as a global identifier for
- identifying transactions.
const SIPConstants_DEFAULT_ENCODING = "UTF-8"
const SIPConstants_DEFAULT_PORT = 5060
const SIPConstants_SIP_VERSION_STRING = "SIP/2.0"
* constant SIP_VERSION_STRING
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Accept ¶
type Accept struct { Parameters // contains filtered or unexported fields }
* *Accept header : The top level header is actually AcceptList which is a list of *Accept headers.
func (*Accept) AllowsAllContentSubTypes ¶
*
- returns true if this header allows all ContentSubTypes,
- false otherwise.
- @return boolean
func (*Accept) AllowsAllContentTypes ¶
* returns true if this header allows all ContentTypes,
- false otherwise.
- @return Boolean
func (*Accept) EncodeBody ¶
* Encode the value of this header into cannonical form. *@return encoded value of the header as a string.
func (*Accept) GetMediaRange ¶
func (this *Accept) GetMediaRange() *MediaRange
* get the MediaRange field
- @return MediaRange
func (*Accept) GetQValue ¶
* get the QValue field. Return -1 if the parameter has not been
- set.
- @return float
func (*Accept) SetMediaRange ¶
func (this *Accept) SetMediaRange(m *MediaRange)
*
- Set the mediaRange member
- @param m MediaRange field
func (*Accept) SetQValue ¶
*
- Sets q-value for media-range. Q-values allow the *
- user to indicate the relative degree of preference for that media-range, *
- using the qvalue scale from 0 to 1. If no q-value is present, the *
- media-range should be treated as having a q-value of 1. * * *
- @param qValue - the new float value of the q-value *
- @throws InvalidArgumentException if the q parameter value is not between <code>0 and 1</code>. *
type AcceptEncoding ¶
type AcceptEncoding struct { Parameters // contains filtered or unexported fields }
* * Accept-Encoding SIP (HTTP) Header. * <pre> * From HTTP RFC 2616 * * * The Accept-Encoding request-header field is similar to Accept, but * restricts the content-codings (section 3.5) that are acceptable in * the response. * * * Accept-Encoding = "Accept-Encoding" ":" * * * 1#( codings [ ";" "q" "=" qvalue ] ) * codings = ( content-coding | "*" ) * * Examples of its use are: * * Accept-Encoding: compress, gzip * Accept-Encoding: * Accept-Encoding: * * Accept-Encoding: compress;q=0.5, gzip;q=1.0 * Accept-Encoding: gzip;q=1.0, identity; q=0.5, *;q=0 * </pre> *
func (*AcceptEncoding) EncodeBody ¶
func (this *AcceptEncoding) EncodeBody() string
* Encode the value of this header. *@return the value of this header encoded into a string.
func (*AcceptEncoding) GetEncoding ¶
func (this *AcceptEncoding) GetEncoding() string
* get ContentEncoding field
- @return String
func (*AcceptEncoding) GetQValue ¶
func (this *AcceptEncoding) GetQValue() float32
* get the QValue field. Return -1 if the parameter has not been
- set.
- @return float
func (*AcceptEncoding) HasQValue ¶
func (this *AcceptEncoding) HasQValue() bool
*
- Return true if the q value has been set.
- @return boolean
func (*AcceptEncoding) RemoveQValue ¶
func (this *AcceptEncoding) RemoveQValue()
*
- Remove the q value.
func (*AcceptEncoding) SetEncoding ¶
func (this *AcceptEncoding) SetEncoding(encoding string) (ParseException error)
*
- Sets the encoding of an EncodingHeader. *
- @param encoding - the new string value defining the encoding.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the encoding value.
func (*AcceptEncoding) SetQValue ¶
func (this *AcceptEncoding) SetQValue(q float32) (InvalidArgumentException error)
*
- Sets q-value for media-range. Q-values allow the *
- user to indicate the relative degree of preference for that media-range, *
- using the qvalue scale from 0 to 1. If no q-value is present, the *
- media-range should be treated as having a q-value of 1. * * *
- @param qValue - the new float value of the q-value *
- @throws InvalidArgumentException if the q parameter value is not between <code>0 and 1</code>. *
func (*AcceptEncoding) String ¶
func (this *AcceptEncoding) String() string
type AcceptEncodingHeader ¶
type AcceptEncodingHeader interface { ParametersHeader Encoding QValue }
*
- This interface represents the Accept-Encoding request-header.
- A client includes an AcceptEncodingHeader in a Request to tell the server
- what coding schemes are acceptable in the Response e.g. compress, gzip.
- <p>
- If an AcceptEncodingHeader is present, and if the server cannot send a
- Response which is acceptable according to the AcceptEncodingHeader, then
- the server should return a Response with a status code of NOT_ACCEPTABLE.
- <p>
- An empty Accept-Encoding header field is permissible, it is equivalent to
- <code>Accept-Encoding: identity</code>, meaning no encoding is permissible.
- <p>
- If no Accept-Encoding header field is present, the server SHOULD assume a
- default value of identity.
- <p>
- For Example:<br>
- <code>Accept-Encoding: gzip</code> *
type AcceptEncodingList ¶
type AcceptEncodingList struct {
SIPHeaderList
}
* * AcceptEncodingList of AccepEncoding headers.
type AcceptHeader ¶
type AcceptHeader interface { MediaType ParametersHeader QValue AllowsAllContentSubTypes() bool AllowsAllContentTypes() bool }
*
This interface represents an Accept request-header. It can be used in to
specify media-ranges which are acceptable for the response. AcceptHeaders
can be used to indicate that the request is specifically limited to a small
set of desired types. The specification of the acceptable media
is split into type and subtype.
<p>
An AcceptHeader may be followed by one or more parameters applicable to the
media-range. q-values allow the user to indicate the relative degree of
preference for that media-range, using the qvalue scale from 0 to 1. (If no
q-value is present, the media-range should be treated as having a q-value of
1.)
<p>
If no AcceptHeader is present in a Request, the server SHOULD assume a media
of type "application" and subType
"sdp". If an AcceptHeader is present, and if the server cannot send a
response which is acceptable according to the combined Accept field value,
then the server should send a Response message with a NOT_ACCEPTABLE
status code.
<p>
For example:<br>
<code>Accept: application/sdp;level=1, application/x-private, text/html</code> *
type AcceptLanguage ¶
type AcceptLanguage struct { Parameters // contains filtered or unexported fields }
*
- Accept Language body.
- <pre>
- HTTP RFC 2616 Section 14.4
- Accept-Language = "Accept-Language" ":"
- 1#( language-range [ ";" "q" "=" qvalue ] )
- language-range = ( ( 1*8ALPHA *( "-" 1*8ALPHA ) ) | "*" ) *
- </pre> *
- @see AcceptLanguageList
func (*AcceptLanguage) EncodeBody ¶
func (this *AcceptLanguage) EncodeBody() string
- Encode the value of this header to a string. *@return encoded header as a string.
func (*AcceptLanguage) GetAcceptLanguage ¶
func (this *AcceptLanguage) GetAcceptLanguage() string
*
- Gets the language value of the AcceptLanguageHeader. * * *
- @return the language Locale value of this AcceptLanguageHeader *
func (*AcceptLanguage) GetLanguageRange ¶
func (this *AcceptLanguage) GetLanguageRange() string
* get the LanguageRange field
- @return String
func (*AcceptLanguage) GetQValue ¶
func (this *AcceptLanguage) GetQValue() float32
* get the QValue field. Return -1 if the parameter has not been
- set.
- @return float
func (*AcceptLanguage) HasQValue ¶
func (this *AcceptLanguage) HasQValue() bool
*
- Return true if the q value has been set.
- @return boolean
func (*AcceptLanguage) RemoveQValue ¶
func (this *AcceptLanguage) RemoveQValue()
*
- Remove the q value.
func (*AcceptLanguage) SetAcceptLanguage ¶
func (this *AcceptLanguage) SetAcceptLanguage(language string)
*
- Sets the language parameter of this AcceptLanguageHeader. * * *
- @param language - the new Locale value of the language of *
- AcceptLanguageHeader * *
func (*AcceptLanguage) SetLanguageRange ¶
func (this *AcceptLanguage) SetLanguageRange(languageRange string)
*
- Set the languageRange. *
- @param languageRange is the language range to set. *
func (*AcceptLanguage) SetQValue ¶
func (this *AcceptLanguage) SetQValue(q float32) (InvalidArgumentException error)
*
- Sets q-value for media-range. Q-values allow the *
- user to indicate the relative degree of preference for that media-range, *
- using the qvalue scale from 0 to 1. If no q-value is present, the *
- media-range should be treated as having a q-value of 1. * * *
- @param qValue - the new float value of the q-value *
- @throws InvalidArgumentException if the q parameter value is not between <code>0 and 1</code>. *
func (*AcceptLanguage) String ¶
func (this *AcceptLanguage) String() string
type AcceptLanguageHeader ¶
type AcceptLanguageHeader interface { ParametersHeader QValue GetAcceptLanguage() string SetAcceptLanguage(language string) }
type AcceptLanguageList ¶
type AcceptLanguageList struct {
SIPHeaderList
}
* * AcceptLanguageList: Strings together a list of AcceptLanguage SIPHeaders.
func NewAcceptLanguageList ¶
func NewAcceptLanguageList() *AcceptLanguageList
func (*AcceptLanguageList) GetFirst ¶
func (this *AcceptLanguageList) GetFirst() Header
func (*AcceptLanguageList) GetLast ¶
func (this *AcceptLanguageList) GetLast() Header
type AcceptList ¶
type AcceptList struct {
SIPHeaderList
}
* * Accept List of SIP headers. *@see Accept
type AddressHeader ¶
type AddressHeader interface { /** * Sets the Address parameter of this Address. * * @param address - the Address object that represents the new * address of this Address. */ SetAddress(addr address.Address) /** * Gets the address parameter of this Address. * * @return the Address of this Address */ GetAddress() address.Address }
*
- This interface represents methods for manipulating Address object
- values for any header that contains a Address value.
- <p>
- When the header field value contains a display name encapsulated in the
- Address, the URI including all URI parameters is enclosed in "<" and ">".
- If no "<" and ">" are present, all parameters after the URI are header
- parameters, not URI parameters. The display name can be tokens, or a
- quoted string, if a larger character set is desired. *
- @see Address
- @see ContactHeader
- @see FromHeader
- @see RecordRouteHeader
- @see ReplyToHeader
- @see RouteHeader
- @see ToHeader
type AddressParameters ¶
type AddressParameters struct { Parameters // contains filtered or unexported fields }
* An abstract class for headers that take an address and parameters.
func NewAddressParameters ¶
func NewAddressParameters(name string) *AddressParameters
* Constructor given the name of the header.
func (*AddressParameters) GetAddress ¶
func (this *AddressParameters) GetAddress() address.Address
* get the Address field
- @return the imbedded Address
func (*AddressParameters) SetAddress ¶
func (this *AddressParameters) SetAddress(addr address.Address)
* set the Address field
- @param address Address to set
type AddressParametersHeader ¶
type AddressParametersHeader interface { ParametersHeader AddressHeader }
type AlertInfo ¶
type AlertInfo struct { Parameters // contains filtered or unexported fields }
* * AlertInfo SIP Header.
func (*AlertInfo) EncodeBody ¶
*
- Return value encoding in canonical form.
- @return The value of the header in canonical encoding.
func (*AlertInfo) GetAlertInfo ¶
*
- Returns the AlertInfo value of this AlertInfoHeader. * * *
- @return the URI representing the AlertInfo. *
type AlertInfoHeader ¶
type AlertInfoHeader interface { ParametersHeader /** * Sets the AlertInfo of the AlertInfoHeader to the <var>alertInfo</var> * parameter value. * * @param alertInfo the new Alert Info URI of this AlertInfoHeader. */ SetAlertInfo(alertInfo address.URI) /** * Returns the AlertInfo value of this AlertInfoHeader. * * @return the URI representing the AlertInfo. */ GetAlertInfo() address.URI }
type AlertInfoList ¶
type AlertInfoList struct {
SIPHeaderList
}
* * AlertInfo Header - there can be several AlertInfo headers.
type Allow ¶
type Allow struct { SIPHeader // contains filtered or unexported fields }
* * Allow Header.
func (*Allow) EncodeBody ¶
* Return body encoded in canonical form.
- @return body encoded as a string.
type AllowEvents ¶
type AllowEvents struct { SIPHeader // contains filtered or unexported fields }
* * AllowEvents Header.
func NewAllowEventsFromString ¶
func NewAllowEventsFromString(m string) *AllowEvents
* constructor
- @param m String to set
func (*AllowEvents) EncodeBody ¶
func (this *AllowEvents) EncodeBody() string
* Return body encoded in canonical form.
- @return body encoded as a string.
func (*AllowEvents) GetEventType ¶
func (this *AllowEvents) GetEventType() string
*
- Gets the eventType of the AllowEventsHeader. *
- @return the String object identifing the eventTypes of AllowEventsHeader.
func (*AllowEvents) SetEventType ¶
func (this *AllowEvents) SetEventType(eventType string) (ParseException error)
*
- Sets the eventType defined in this AllowEventsHeader. *
- @param eventType - the String defining the method supported
- in this AllowEventsHeader
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the Strings defining the eventType supported
func (*AllowEvents) String ¶
func (this *AllowEvents) String() string
type AllowEventsHeader ¶
type AllowEventsHeader interface { Header /** * Sets the eventType defined in this AllowEventsHeader. * * @param eventType - the String defining the method supported * in this AllowEventsHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Strings defining the eventType supported */ SetEventType(eventType string) (ParseException error) /** * Gets the eventType of the AllowEventsHeader. * * @return the String object identifing the eventTypes of AllowEventsHeader. */ GetEventType() string }
type AllowEventsList ¶
type AllowEventsList struct {
SIPHeaderList
}
* * List of AllowEvents headers. * The sip message can have multiple AllowEvents headers which are strung * together in a list.
func (*AllowEventsList) GetMethods ¶
func (this *AllowEventsList) GetMethods() *list.List
*
- Gets an Iterator of all the methods of the AllowEventsHeader. Returns an empty *
- Iterator if no methods are defined in this AllowEvents Header. * * *
- @return Iterator of String objects each identifing the methods of *
- AllowEventsHeader. *
func (*AllowEventsList) SetMethods ¶
func (this *AllowEventsList) SetMethods(methods *list.List) (ParseException error)
type AllowHeader ¶
type AllowHeader interface { Header /** * Sets the method supported by this AllowHeader. * * @param method - the String defining the method supported * in this AllowHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the method supported. */ SetMethod(method string) (ParseException error) /** * Gets the method of the AllowHeader. Returns null if no method is * defined in this Allow Header. * * @return the string identifing the method of AllowHeader. */ GetMethod() string }
*
- The Allow header field lists the set of methods supported by the User Agent
- generating the message. All methods, including ACK and CANCEL, understood
- by the User Agent MUST be included in the list of methods in the Allow header
- field, when present.
- The absence of an Allow header field MUST NOT be interpreted to mean that
- the User Agent sending the message supports no methods. Rather, it implies
- that the User Agent is not providing any information on what methods it
- supports. Supplying an Allow header field in responses to methods other than
- OPTIONS reduces the number of messages needed.
- <p>
- For Example:<br>
- <code>Allow: INVITE, ACK, OPTIONS, CANCEL, BYE</code>
type AllowList ¶
type AllowList struct {
SIPHeaderList
}
* * List of ALLOW headers. The sip message can have multiple Allow headers *
func (*AllowList) GetMethods ¶
type Authentication ¶
type Authentication struct { Parameters // contains filtered or unexported fields }
func NewAuthentication ¶
func NewAuthentication(name string) *Authentication
func (*Authentication) EncodeBody ¶
func (this *Authentication) EncodeBody() string
*
- Encode in canonical form.
- @return canonical string.
func (*Authentication) GetAlgorithm ¶
func (this *Authentication) GetAlgorithm() string
*
- Returns the Algorithm value of this WWWAuthenicateHeader. *
- @return the String representing the Algorithm information, null if the
- value is not Set. *
func (*Authentication) GetCNonce ¶
func (this *Authentication) GetCNonce() string
- Get the CNonce. * *@return the cnonce value.
func (*Authentication) GetDomain ¶
func (this *Authentication) GetDomain() string
*
- Returns the Domain value of this WWWAuthenicateHeader. *
- @return the String representing the Domain information, null if value is
- not Set. *
func (*Authentication) GetNonce ¶
func (this *Authentication) GetNonce() string
*
- Returns the Nonce value of this WWWAuthenicateHeader. *
- @return the String representing the nonce information, null if value is
- not Set. *
func (*Authentication) GetNonceCount ¶
func (this *Authentication) GetNonceCount() int
func (*Authentication) GetOpaque ¶
func (this *Authentication) GetOpaque() string
*
- Returns the Opaque value of this WWWAuthenicateHeader. *
- @return the String representing the Opaque information, null if the
- value is not Set. *
func (*Authentication) GetQop ¶
func (this *Authentication) GetQop() string
*
- Returns the Qop value of this WWWAuthenicateHeader. *
- @return the string representing the Qop information, null if the
- value is not Set. *
func (*Authentication) GetRealm ¶
func (this *Authentication) GetRealm() string
*
- Returns the Realm value of this WWWAuthenicateHeader. This convenience
- method returns only the realm of the complete Challenge. *
- @return the String representing the Realm information, null if value is
- not Set. *
func (*Authentication) GetResponse ¶
func (this *Authentication) GetResponse() string
*
- Get the RESPONSE value (or null if it does not exist). *
- @return String response parameter value.
func (*Authentication) GetScheme ¶
func (this *Authentication) GetScheme() string
*
- Returns the scheme of the challenge information for this
- AuthenticationHeaderHeader. *
- @return the string value of the challenge information. *
func (*Authentication) GetURI ¶
func (this *Authentication) GetURI() address.URI
*
- Returns the URI value of this WWWAuthenicateHeader,
- for example DigestURI. *
- @return the URI representing the URI information, null if value is
- not Set. *
func (*Authentication) GetUsername ¶
func (this *Authentication) GetUsername() string
*
- Returns the Username value of this AuthenticationHeader.
- This convenience method returns only the username of the
- complete Response. *
- @return the String representing the Username information,
- null if value is not Set. *
- @since JAIN SIP v1.1 *
func (*Authentication) IsStale ¶
func (this *Authentication) IsStale() bool
*
- Returns the boolean value of the state paramater of this
- WWWAuthenicateHeader. *
- @return the boolean representing if the challenge is stale. *
func (*Authentication) SetAlgorithm ¶
func (this *Authentication) SetAlgorithm(algorithm string) (ParseException error)
*
- Sets the Algorithm of the WWWAuthenicateHeader to the new
- <var>algorithm</var> parameter value. *
- @param algorithm - the new algorithm String of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the algorithm value. *
func (*Authentication) SetCNonce ¶
func (this *Authentication) SetCNonce(cnonce string) (ParseException error)
- Set the CNonce. *
- @param cnonce -- a nonce string.
func (*Authentication) SetChallenge ¶
func (this *Authentication) SetChallenge(challenge Challenge)
- This is only used for the parser interface. *@param challenge -- the challenge from which the parameters are
- extracted.
func (*Authentication) SetDomain ¶
func (this *Authentication) SetDomain(domain string) (ParseException error)
*
- Sets the Domain of the WWWAuthenicateHeader to the <var>domain</var>
- parameter value. *
- @param domain - the new Domain string of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the domain. *
func (*Authentication) SetNonce ¶
func (this *Authentication) SetNonce(nonce string) (ParseException error)
*
- Sets the Nonce of the WWWAuthenicateHeader to the <var>nonce</var>
- parameter value. *
- @param nonce - the new nonce String of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the nonce value. *
func (*Authentication) SetNonceCount ¶
func (this *Authentication) SetNonceCount(nonceCount int) (ParseException error)
func (*Authentication) SetOpaque ¶
func (this *Authentication) SetOpaque(opaque string) (ParseException error)
*
- Sets the Opaque value of the WWWAuthenicateHeader to the new
- <var>opaque</var> parameter value. *
- @param opaque - the new Opaque string of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the opaque value. *
func (*Authentication) SetParameter ¶
func (this *Authentication) SetParameter(name, value string) error
* Set the specified parameter.
- Bug reported by Dominic Sparks. *
- @param name -- name of the parameter
- @param value -- value of the parameter.
func (*Authentication) SetQop ¶
func (this *Authentication) SetQop(qop string) (ParseException error)
*
- Sets the Qop value of the WWWAuthenicateHeader to the new
- <var>qop</var> parameter value. *
- @param qop - the new Qop string of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the Qop value. *
func (*Authentication) SetRealm ¶
func (this *Authentication) SetRealm(realm string) (ParseException error)
*
- Sets the Realm of the WWWAuthenicateHeader to the <var>realm</var>
- parameter value. Realm strings MUST be globally unique. It is
- RECOMMENDED that a realm string contain a hostname or domain name.
- Realm strings SHOULD present a human-readable identifier that can be
- rendered to a user. *
- @param realm the new Realm String of this WWWAuthenicateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the realm. *
func (*Authentication) SetResponse ¶
func (this *Authentication) SetResponse(response string) (ParseException error)
- Set the Response. * *@param response to Set.
func (*Authentication) SetScheme ¶
func (this *Authentication) SetScheme(scheme string)
*
- Sets the scheme of the challenge information for this
- AuthenticationHeaderHeader. For example, Digest. *
- @param scheme - the new string value that identifies the challenge
- information scheme. *
func (*Authentication) SetStale ¶
func (this *Authentication) SetStale(stale bool)
*
- Sets the value of the stale parameter of the WWWAuthenicateHeader to the
- <var>stale</var> parameter value. *
- @param stale - the new boolean value of the stale parameter. *
func (*Authentication) SetURI ¶
func (this *Authentication) SetURI(uri address.URI) error
*
- Sets the URI of the WWWAuthenicateHeader to the <var>uri</var>
- parameter value. *
- @param uri - the new URI of this WWWAuthenicateHeader. *
func (*Authentication) SetUsername ¶
func (this *Authentication) SetUsername(username string) (ParseException error)
*
- Sets the Username of the AuthenticationHeader to
- the <var>username</var> parameter value. *
- @param username the new Username String of this AuthenticationHeader. *
- @throws ParseException which signals that an error has been reached *
- unexpectedly while parsing the username. *
- @since JAIN SIP v1.1 *
func (*Authentication) String ¶
func (this *Authentication) String() string
type AuthenticationHeader ¶
type AuthenticationHeader interface { ParametersHeader /** * Sets the scheme of the Response information for this AuthorizationHeader. * For example, Digest. * * @param scheme - the new string value that identifies the response * information scheme. */ SetScheme(scheme string) /** * Returns the scheme of the Response information for this AuthorizationHeader. * * @return the string value of the response information. */ GetScheme() string /** * Sets the Realm of the AuthorizationHeader to the <var>realm</var> * parameter value. Realm strings MUST be globally unique. It is * RECOMMENDED that a realm string contain a hostname or domain name. * Realm strings SHOULD present a human-readable identifier that can be * rendered to a user. * * @param realm the new Realm String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the realm. */ SetRealm(realm string) (ParseException error) /** * Returns the Realm value of this AuthorizationHeader. This convenience * method returns only the realm of the complete Response. * * @return the String representing the Realm information, null if value is * not Set. */ GetRealm() string /** * Sets the Username of the AuthorizationHeader to the <var>username</var> * parameter value. * * @param username the new Username String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the username. */ SetUsername(username string) (ParseException error) /** * Returns the Username value of this AuthorizationHeader. This convenience * method returns only the username of the complete Response. * * @return the String representing the Username information, null if value is * not Set. */ GetUsername() string /** * Sets the Nonce of the AuthorizationHeader to the <var>nonce</var> * parameter value. * * @param nonce - the new nonce String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the nonce value. */ SetNonce(nonce string) (ParseException error) /** * Returns the Nonce value of this AuthorizationHeader. * * @return the String representing the nonce information, null if value is * not Set. */ GetNonce() string /** * Sets the URI of the AuthorizationHeader to the <var>uri</var> * parameter value. * * @param uri - the new URI of this AuthorizationHeader. */ SetURI(uri address.URI) error /** * Returns the URI value of this AuthorizationHeader, for example DigestURI. * * @return the URI representing the URI information, null if value is * not Set. */ GetURI() address.URI /** * Sets the Response of the AuthorizationHeader to the new <var>response</var> * parameter value. * * @param response - the new response String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Response. * */ SetResponse(response string) (ParseException error) /** * Returns the Response value of this AuthorizationHeader. * * @return the String representing the Response information. * */ GetResponse() string /** * Sets the Algorithm of the AuthorizationHeader to the new * <var>algorithm</var> parameter value. * * @param algorithm - the new algorithm String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the algorithm value. * */ SetAlgorithm(algorithm string) (ParseException error) /** * Returns the Algorithm value of this AuthorizationHeader. * * @return the String representing the Algorithm information, null if the * value is not Set. * */ GetAlgorithm() string /** * Sets the CNonce of the AuthorizationHeader to the <var>cNonce</var> * parameter value. * * @param cNonce - the new cNonce String of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the cNonce value. * */ SetCNonce(cNonce string) (ParseException error) /** * Returns the CNonce value of this AuthorizationHeader. * * @return the String representing the cNonce information, null if value is * not Set. * */ GetCNonce() string /** * Sets the Opaque value of the AuthorizationHeader to the new * <var>opaque</var> parameter value. * * @param opaque - the new Opaque string of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the opaque value. * */ SetOpaque(opaque string) (ParseException error) /** * Returns the Opaque value of this AuthorizationHeader. * * @return the String representing the Opaque information, null if the * value is not Set. * */ GetOpaque() string /** * Sets the MessageQop value of the AuthorizationHeader to the new * <var>qop</var> parameter value. * * @param qop - the new Qop string of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Qop value. * */ SetQop(qop string) (ParseException error) /** * Returns the Qop value of this AuthorizationHeader. * * @return the string representing the Qop information, null if the * value is not Set. * */ GetQop() string /** * Sets the Nonce Count of the AuthorizationHeader to the <var>nonceCount</var> * parameter value. * * @param nonceCount - the new nonceCount integer of this AuthorizationHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the nonceCount value. * */ SetNonceCount(nonceCount int) (ParseException error) /** * Returns the Nonce Count value of this AuthorizationHeader. * * @return the integer representing the nonceCount information, -1 if value is * not Set. * */ GetNonceCount() int }
type AuthenticationInfo ¶
type AuthenticationInfo struct {
Parameters
}
- Authentication info SIP Header. *
func NewAuthenticationInfo ¶
func NewAuthenticationInfo() *AuthenticationInfo
* Default contstructor.
func (*AuthenticationInfo) Add ¶
func (this *AuthenticationInfo) Add(nv *core.NameValue)
func (*AuthenticationInfo) EncodeBody ¶
func (this *AuthenticationInfo) EncodeBody() string
func (*AuthenticationInfo) GetAuthInfo ¶
func (this *AuthenticationInfo) GetAuthInfo(name string) *core.NameValue
- Get the name value pair for a given authentication info parameter. * *@param name is the name for which we want to retrieve the name value
- list.
func (*AuthenticationInfo) GetAuthenticationInfo ¶
func (this *AuthenticationInfo) GetAuthenticationInfo() string
*
- Returns the AuthenticationInfo value of this AuthenticationInfoHeader. * * *
- @return the String representing the AuthenticationInfo *
func (*AuthenticationInfo) GetCNonce ¶
func (this *AuthenticationInfo) GetCNonce() string
- Returns the CNonce value of this AuthenticationInfoHeader. *
- @return the String representing the cNonce information, null if value is
- not set. *
func (*AuthenticationInfo) GetNextNonce ¶
func (this *AuthenticationInfo) GetNextNonce() string
- Returns the nextNonce value of this AuthenticationInfoHeader. *
- @return the String representing the nextNonce
- information, null if value is not set. *
func (*AuthenticationInfo) GetNonceCount ¶
func (this *AuthenticationInfo) GetNonceCount() int
- Returns the Nonce Count value of this AuthenticationInfoHeader. *
- @return the integer representing the nonceCount information, -1 if value is
- not set. *
func (*AuthenticationInfo) GetQop ¶
func (this *AuthenticationInfo) GetQop() string
- Returns the messageQop value of this AuthenticationInfoHeader. *
- @return the string representing the messageQop information, null if the
- value is not set. *
func (*AuthenticationInfo) GetResponse ¶
func (this *AuthenticationInfo) GetResponse() string
- Returns the Response value of this AuthenticationInfoHeader. *
- @return the String representing the Response information. *
func (*AuthenticationInfo) SetCNonce ¶
func (this *AuthenticationInfo) SetCNonce(cNonce string) (ParseException error)
* Sets the CNonce of the AuthenticationInfoHeader to the <var>cNonce</var>
- parameter value. *
- @param cNonce - the new cNonce String of this AuthenticationInfoHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the cNonce value. *
func (*AuthenticationInfo) SetNextNonce ¶
func (this *AuthenticationInfo) SetNextNonce(nextNonce string) (ParseException error)
* Sets the NextNonce of the AuthenticationInfoHeader to the <var>nextNonce</var>
- parameter value. *
- @param nextNonce - the new nextNonce String of this AuthenticationInfoHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the nextNonce value. *
func (*AuthenticationInfo) SetNonceCount ¶
func (this *AuthenticationInfo) SetNonceCount(nonceCount int) (ParseException error)
* Sets the Nonce Count of the AuthenticationInfoHeader to the <var>nonceCount</var>
- parameter value. *
- @param nonceCount - the new nonceCount integer of this AuthenticationInfoHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the nonceCount value. *
func (*AuthenticationInfo) SetParameter ¶
func (this *AuthenticationInfo) SetParameter(name, value string) error
func (*AuthenticationInfo) SetQop ¶
func (this *AuthenticationInfo) SetQop(qop string) (ParseException error)
* Sets the Qop value of the AuthenticationInfoHeader to the new
- <var>qop</var> parameter value. *
- @param qop - the new Qop string of this AuthenticationInfoHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the Qop value. *
func (*AuthenticationInfo) SetResponse ¶
func (this *AuthenticationInfo) SetResponse(response string) (ParseException error)
* Sets the Response of the
- AuthenticationInfoHeader to the new <var>response</var>
- parameter value. *
- @param response - the new response String of this
- AuthenticationInfoHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the Response. *
func (*AuthenticationInfo) String ¶
func (this *AuthenticationInfo) String() string
* Value of header encoded in canonical form.
type AuthenticationInfoHeader ¶
type AuthenticationInfoHeader interface { ParametersHeader /** * Sets the NextNonce of the AuthenticationInfoHeader to the <var>nextNonce</var> * parameter value. * * @param nextNonce - the new nextNonce String of this AuthenticationInfoHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the nextNonce value. * */ SetNextNonce(nextNonce string) (ParseException error) /** * Returns the nextNonce value of this AuthenticationInfoHeader. * * @return the String representing the nextNonce information, null if value is * not set. * */ GetNextNonce() string /** * Sets the Qop value of the AuthenticationInfoHeader to the new * <var>qop</var> parameter value. * * @param qop - the new Qop string of this AuthenticationInfoHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Qop value. * */ SetQop(qop string) (ParseException error) /** * Returns the messageQop value of this AuthenticationInfoHeader. * * @return the string representing the messageQop information, null if the * value is not set. * */ GetQop() string /** * Sets the CNonce of the AuthenticationInfoHeader to the <var>cNonce</var> * parameter value. * * @param cNonce - the new cNonce String of this AuthenticationInfoHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the cNonce value. * */ SetCNonce(cNonce string) (ParseException error) /** * Returns the CNonce value of this AuthenticationInfoHeader. * * @return the String representing the cNonce information, null if value is * not set. * */ GetCNonce() string /** * Sets the Nonce Count of the AuthenticationInfoHeader to the <var>nonceCount</var> * parameter value. * * @param nonceCount - the new nonceCount integer of this AuthenticationInfoHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the nonceCount value. * */ SetNonceCount(nonceCount int) (ParseException error) /** * Returns the Nonce Count value of this AuthenticationInfoHeader. * * @return the integer representing the nonceCount information, -1 if value is * not set. * */ GetNonceCount() int /** * Sets the Response of the AuthenticationInfoHeader to the new <var>response</var> * parameter value. * * @param response - the new response String of this AuthenticationInfoHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Response. * */ SetResponse(response string) (ParseException error) /** * Returns the Response value of this AuthenticationInfoHeader. * * @return the String representing the Response information. * */ GetResponse() string }
*
- The Authentication-Info header field provides for mutual
- authentication with HTTP Digest. A UAS MAY include this header field
- in a 2xx response to a request that was successfully authenticated
- using digest based on the Authorization header field.
- <p>
- For Example:<br>
- <code>Authentication-Info: nextnonce="47364c23432d2e131a5fb210812c"</code>
type Authorization ¶
type Authorization struct {
Authentication
}
* * Authorization SIP header. * * @see ProxyAuthorization
type AuthorizationHeader ¶
type AuthorizationHeader interface { AuthenticationHeader }
type CSeq ¶
type CSeq struct { SIPHeader // contains filtered or unexported fields }
*
- CSeq SIP Header.
func NewCSeq ¶
*
- Constructor given the sequence number and method. * *@param seqno is the sequence number to assign. *@param method is the method string.
func (*CSeq) EncodeBody ¶
*
- Return canonical header content. (encoded header except headerName:) *
- @return encoded string.
func (*CSeq) GetSequenceNumber ¶
- Gets the sequence number of this CSeqHeader. *
- @return sequence number of the CSeqHeader
func (*CSeq) SetSequenceNumber ¶
* Sets the sequence number of this CSeqHeader. The sequence number
- MUST be expressible as a 32-bit unsigned integer and MUST be less than
- 2**31. *
- @param sequenceNumber - the sequence number to set.
- @throws InvalidArgumentException -- if the seq number is <= 0
type CSeqHeader ¶
type CSeqHeader interface { Header /** * Sets the method of CSeqHeader * * @param method - the method of the Request of this CSeqHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the method value. */ SetMethod(method string) (ParseException error) /** * Gets the method of CSeqHeader * * @return method of CSeqHeader */ GetMethod() string /** * Sets the sequence number value of the CSeqHeader. The sequence number * MUST be expressible as a 32-bit unsigned integer and MUST be less than * 2**31. * * @param sequenceNumber - the new sequence number of this CSeqHeader * @throws InvalidArgumentException if supplied value is less than zero. * */ SetSequenceNumber(sequenceNumber int) (InvalidArgumentException error) /** * Gets the sequence number of this CSeqHeader. * * @return sequence number of the CSeqHeader * */ GetSequenceNumber() int }
type CallID ¶
type CallID struct { SIPHeader // contains filtered or unexported fields }
* * Call ID Header.
func NewCallID ¶
* Constructor given the call Identifier. *@param callId string call identifier (should be localid@host) *@throws IllegalArgumentException if call identifier is bad.
func (*CallID) EncodeBody ¶
* Encode the body part of this header (i.e. leave out the hdrName). *@return String encoded body part of the header.
func (*CallID) GetCallId ¶
* get the CallId field. This does the same thing as
- encodeBody
- @return String the encoded body part of the
func (*CallID) GetCallIdentifer ¶
func (this *CallID) GetCallIdentifer() *CallIdentifier
*
- get the call Identifer member.
- @return CallIdentifier
func (*CallID) SetCallId ¶
* set the CallId field
- @param cid String to set. This is the body part of the Call-Id
- header. It must have the form localId@host or localId.
- @throws IllegalArgumentException if cid is null, not a token, or is
- not a token@token.
func (*CallID) SetCallIdentifier ¶
func (this *CallID) SetCallIdentifier(cid *CallIdentifier)
*
- Set the callIdentifier member.
- @param cid CallIdentifier to set (localId@host).
type CallIdHeader ¶
type CallIdentifier ¶
type CallIdentifier struct {
// contains filtered or unexported fields
}
* * The call identifer that goes into a callID header and a in-reply-to header. * @see CallID * @see InReplyTo
func NewCallIdentifier ¶
func NewCallIdentifier(cid string) (*CallIdentifier, error)
* constructor
- @param cid String to set
- @throws IllegalArgumentException if cid is null or is not a token,
- or token@token
func (*CallIdentifier) GetHost ¶
func (this *CallIdentifier) GetHost() string
* get the host field
- @return host member String
func (*CallIdentifier) GetLocalId ¶
func (this *CallIdentifier) GetLocalId() string
* get the LocalId field
- @return String
func (*CallIdentifier) SetCallID ¶
func (this *CallIdentifier) SetCallID(cid string) (IllegalArgumentException error)
* set the callId field
- @param cid Strimg to set
- @throws IllegalArgumentException if cid is null or is not a token or
- token@token
func (*CallIdentifier) SetHost ¶
func (this *CallIdentifier) SetHost(host string)
*
- Set the host member
- @param host String to set
func (*CallIdentifier) SetLocalId ¶
func (this *CallIdentifier) SetLocalId(localId string)
*
- Set the localId member
- @param localId String to set
func (*CallIdentifier) String ¶
func (this *CallIdentifier) String() string
*
- Get the encoded version of this id.
- @return String to set
type CallInfo ¶
type CallInfo struct { Parameters // contains filtered or unexported fields }
type CallInfoHeader ¶
type CallInfoHeader interface { ParametersHeader /** * Sets the Information parameter of this CallInfoHeader. The Information * describes the caller or callee. * * @param icon - the new URI value of the location of the information. */ SetInfo(info address.URI) /** * Gets the URI that represents the location of the info of the caller * or callee. * * @return the location of the info of this CallInfoHeader, returns null * if no info is present. */ GetInfo() address.URI /** * Sets the purpose parameter of the info of this CallInfoHeader. * * @param purpose - the new string value of the purpose of this info. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the purpose value. */ SetPurpose(purpose string) (ParseException error) /** * Gets the purpose of the information supplied in this CallInfoHeader. * * @return the sting value of the purpose of the info, returns null * if no purpose is present. */ GetPurpose() string }
type CallInfoList ¶
type CallInfoList struct {
SIPHeaderList
}
* * A list of CallInfo headers (there can be multiple in a message).
type Challenge ¶
type Challenge struct {
// contains filtered or unexported fields
}
* * Challenge part of the Auth header. This is only used by the parser interface
func (*Challenge) GetAuthParams ¶
func (this *Challenge) GetAuthParams() *core.NameValueList
* Get AuthParms list.
- @return NameValueList
func (*Challenge) GetParameter ¶
* Get the specified parameter
- @param name String to Set
- @return String to Set
func (*Challenge) HasParameter ¶
* boolean function
- @param name String to Set
- @return true if this header has the specified parameter, false otherwise.
func (*Challenge) HasParameters ¶
* Boolean function
- @return true if this header has some parameters.
func (*Challenge) RemoveParameter ¶
* delete the specified parameter
- @param name String
- @return true if the specified parameter has been removed, false
- otherwise.
func (*Challenge) RemoveParameters ¶
func (this *Challenge) RemoveParameters()
* remove all parameters
func (*Challenge) SetAuthParams ¶
func (this *Challenge) SetAuthParams(a *core.NameValueList)
*
- Set the authParams member
- @param a NameValueList to Set
type Contact ¶
type Contact struct { AddressParameters // contains filtered or unexported fields }
* * Contact Item.
func (*Contact) EncodeBody ¶
*
- Encode body of the header into a cannonical String.
- @return string encoding of the header value.
func (*Contact) GetContactList ¶
func (this *Contact) GetContactList() *ContactList
* get the Contact list.
- @return ContactList
func (*Contact) GetContactParms ¶
func (this *Contact) GetContactParms() *core.NameValueList
* get the parameters List
- @return NameValueList
func (*Contact) GetQValue ¶
* get the QValue field. Return -1 if the parameter has not been
- set.
- @return float
func (*Contact) SetContactList ¶
func (this *Contact) SetContactList(cl *ContactList)
* set the Contact List
- @param cl ContactList to set
func (*Contact) SetExpires ¶
func (*Contact) SetQValue ¶
*
- Sets q-value for media-range. Q-values allow the *
- user to indicate the relative degree of preference for that media-range, *
- using the qvalue scale from 0 to 1. If no q-value is present, the *
- media-range should be treated as having a q-value of 1. * * *
- @param qValue - the new float value of the q-value *
- @throws InvalidArgumentException if the q parameter value is not between <code>0 and 1</code>. *
type ContactHeader ¶
type ContactHeader interface { AddressHeader ParametersHeader QValue SetExpires(expires int) (InvalidArgumentException error) GetExpires() int }
type ContactList ¶
type ContactList struct {
SIPHeaderList
}
* * List of contact headers.ContactLists are also maintained in a hashtable for quick lookup.
func (*ContactList) AddContact ¶
func (this *ContactList) AddContact(contact ContactHeader) (IllegalArgumentException error)
*
- add a new contact header. Store it in the hashtable also
- @param contact -- contact to add to this list.
- @throws IllegalArgumentException if Duplicate Contact for same addr
func (*ContactList) Clone ¶
func (this *ContactList) Clone() interface{}
*
- make a clone of this contact list.
- @return Object cloned list.
func (*ContactList) GetContacts ¶
func (this *ContactList) GetContacts() []ContactHeader
*
- Get an array of contact addresses. *
- @return array of contacts. *
type ContentDisposition ¶
type ContentDisposition struct { Parameters // contains filtered or unexported fields }
* * Content Dispositon SIP Header.
func NewContentDisposition ¶
func NewContentDisposition() *ContentDisposition
* Default constructor.
func (*ContentDisposition) EncodeBody ¶
func (this *ContentDisposition) EncodeBody() string
*
- Encode value of header into canonical string.
- @return encoded value of header. *
func (*ContentDisposition) GetContentDisposition ¶
func (this *ContentDisposition) GetContentDisposition() string
*
- Gets the interpretation of the message body or message body part of *
- this ContentDispositionHeader. *
- @return interpretation of the message body or message body part *
func (*ContentDisposition) GetDispositionType ¶
func (this *ContentDisposition) GetDispositionType() string
- Get the disposition type. *@param GetDispositionType
func (*ContentDisposition) GetHandling ¶
func (this *ContentDisposition) GetHandling() string
* Get the dispositionType field.
- @return String
func (*ContentDisposition) SetDispositionType ¶
func (this *ContentDisposition) SetDispositionType(dispositionType string) (ParseException error)
- Set the disposition type. *@param disposition type.
func (*ContentDisposition) SetHandling ¶
func (this *ContentDisposition) SetHandling(handling string) (ParseException error)
* Set the dispositionType field.
- @param type String to Set.
func (*ContentDisposition) String ¶
func (this *ContentDisposition) String() string
type ContentDispositionHeader ¶
type ContentDispositionHeader interface { ParametersHeader /** * Sets the interpretation value of the message body or message body part * for this ContentDispositionHeader. * * @param <var>dispositiontype</var> the new String value of the * disposition type. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the dispositionType parameter. */ SetDispositionType(dispositionType string) (ParseException error) /** * Gets the interpretation of the message body or message body part of * this ContentDispositionHeader. * * @return interpretation of the message body or message body part */ GetDispositionType() string /** * The handling parameter describes how the UAS should react if it * receives a message body whose content type or disposition type it * does not understand. The parameter has defined values of "optional" * and "required". If the handling parameter is missing, the value * "required" SHOULD be assumed. * * @param <var>handling</var> the new String value either "optional" * or "required". * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the handling parameter. */ SetHandling(handling string) (ParseException error) /** * Gets the handling information of the unknown content disposition of the * ContentDispositionHeader. * * @return handling information for unknown content dispositions. */ GetHandling() string }
type ContentEncoding ¶
type ContentEncoding struct { SIPHeader // contains filtered or unexported fields }
* * Content encoding part of a content encoding header list. *@see ContentEncodingList *<pre> * From HTTP RFC 2616 *14.11 Content-Encoding * * The Content-Encoding entity-header field is used as a modifier to the * media-type. When present, its value indicates what additional content * codings have been applied to the entity-body, and thus what decoding * mechanisms must be applied in order to obtain the media-type * referenced by the Content-Type header field. Content-Encoding is * primarily used to allow a document to be compressed without losing * the identity of its underlying media type. * * Content-Encoding = "Content-Encoding" ":" 1#content-coding * * Content codings are defined in section 3.5. An example of its use is * * Content-Encoding: gzip * * The content-coding is a characteristic of the entity identified by * the Request-URI. Typically, the entity-body is stored with this * encoding and is only decoded before rendering or analogous usage. * However, a non-transparent proxy MAY modify the content-coding if the * new coding is known to be acceptable to the recipient, unless the * "no-transform" cache-control directive is present in the message. * * If the content-coding of an entity is not "identity", then the * response MUST include a Content-Encoding entity-header (section * 14.11) that lists the non-identity content-coding(s) used. * * If the content-coding of an entity in a request message is not * acceptable to the origin server, the server SHOULD respond with a * status code of 415 (Unsupported Media Type). * * If multiple encodings have been applied to an entity, the content * codings MUST be listed in the order in which they were applied. * Additional information about the encoding parameters MAY be provided * by other entity-header fields not defined by this specification. *</pre>
func NewContentEncodingFromString ¶
func NewContentEncodingFromString(enc string) *ContentEncoding
* constructor.
- @param enc String to set.
func (*ContentEncoding) EncodeBody ¶
func (this *ContentEncoding) EncodeBody() string
*
- Canonical encoding of body of the header.
- @return encoded body of the header.
func (*ContentEncoding) GetEncoding ¶
func (this *ContentEncoding) GetEncoding() string
* get the ContentEncoding field.
- @return String
func (*ContentEncoding) SetEncoding ¶
func (this *ContentEncoding) SetEncoding(encoding string) (ParseException error)
* set the ConentEncoding field.
- @param encoding String to set
func (*ContentEncoding) String ¶
func (this *ContentEncoding) String() string
type ContentEncodingHeader ¶
type ContentEncodingList ¶
type ContentEncodingList struct {
SIPHeaderList
}
* * Content Encoding SIP header List. Keeps a list of ContentEncoding headers
func NewContentEncodingList ¶
func NewContentEncodingList() *ContentEncodingList
* Default constructor.
type ContentLanguage ¶
type ContentLanguage struct { SIPHeader // contains filtered or unexported fields }
* * ContentLanguage header * <pre> *Fielding, et al. Standards Track [Page 118] *RFC 2616 HTTP/1.1 June 1999 * * 14.12 Content-Language * * The Content-Language entity-header field describes the natural * language(s) of the intended audience for the enclosed entity. Note * that this might not be equivalent to all the languages used within * the entity-body. * * Content-Language = "Content-Language" ":" 1#language-tag * * Language tags are defined in section 3.10. The primary purpose of * Content-Language is to allow a user to identify and differentiate * entities according to the user's own preferred language. Thus, if the * body content is intended only for a Danish-literate audience, the * appropriate field is * * Content-Language: da * * If no Content-Language is specified, the default is that the content * is intended for all language audiences. This might mean that the * sender does not consider it to be specific to any natural language, * or that the sender does not know for which language it is intended. * * Multiple languages MAY be listed for content that is intended for * multiple audiences. For example, a rendition of the "Treaty of * Waitangi," presented simultaneously in the original Maori and English * versions, would call for * * Content-Language: mi, en * * However, just because multiple languages are present within an entity * does not mean that it is intended for multiple linguistic audiences. * An example would be a beginner's language primer, such as "A First * Lesson in Latin," which is clearly intended to be used by an * English-literate audience. In this case, the Content-Language would * properly only include "en". * * Content-Language MAY be applied to any media type -- it is not * limited to textual documents. *</pre>
func NewContentLanguage ¶
func NewContentLanguage() *ContentLanguage
func NewContentLanguageFromString ¶
func NewContentLanguageFromString(languageTag string) *ContentLanguage
* Default constructor.
- @param lang String to set
func (*ContentLanguage) EncodeBody ¶
func (this *ContentLanguage) EncodeBody() string
*
- Canonical encoding of the value of the header.
- @return encoded body of header.
func (*ContentLanguage) GetContentLanguage ¶
func (this *ContentLanguage) GetContentLanguage() string
*
- Gets the language value of the ContentLanguageHeader. * * *
- @return the Locale value of this ContentLanguageHeader *
func (*ContentLanguage) GetLanguageTag ¶
func (this *ContentLanguage) GetLanguageTag() string
* get the languageTag field.
- @return String
func (*ContentLanguage) SetContentLanguage ¶
func (this *ContentLanguage) SetContentLanguage(language string)
*
- Sets the language parameter of this ContentLanguageHeader. * * *
- @param language - the new Locale value of the language of *
- ContentLanguageHeader *
func (*ContentLanguage) SetLanguageTag ¶
func (this *ContentLanguage) SetLanguageTag(languageTag string)
* set the languageTag field
- @param languageTag -- language tag to set.
func (*ContentLanguage) String ¶
func (this *ContentLanguage) String() string
type ContentLanguageHeader ¶
type ContentLanguageHeader interface { Header /** * Gets the language value of the ContentLanguageHeader. * * @return the Locale value of this ContentLanguageHeader */ GetContentLanguage() string /** * Sets the language parameter of this ContentLanguageHeader. * * @param language - the new Locale value of the language of * ContentLanguageHeader */ SetContentLanguage(language string) }
*
- The Content-Language header field is used to indicate the language of the
- message body.
- <p>
- For Example:<br>
- <code>Content-Language: fr</code> *
- @see ContentDispositionHeader
- @see ContentLengthHeader
- @see ContentEncodingHeader
- @see ContentTypeHeader *
type ContentLanguageList ¶
type ContentLanguageList struct {
SIPHeaderList
}
* * ContentLanguage list of headers. (Should this be a list?)
func NewContentLanguageList ¶
func NewContentLanguageList() *ContentLanguageList
* Default constructor
type ContentLength ¶
type ContentLength struct { SIPHeader // contains filtered or unexported fields }
func NewContentLengthFromInt ¶
func NewContentLengthFromInt(length int) *ContentLength
*
*Constructor given a length.
func (*ContentLength) EncodeBody ¶
func (this *ContentLength) EncodeBody() string
*
- Encode into a canonical string.
- @return String
func (*ContentLength) GetContentLength ¶
func (this *ContentLength) GetContentLength() int
* Get the ContentLength field.
- @return int
func (*ContentLength) Match ¶
func (this *ContentLength) Match(other interface{}) bool
* Pattern matcher ignores content length.
func (*ContentLength) SetContentLength ¶
func (this *ContentLength) SetContentLength(contentLength int) error
*
- Set the contentLength member
- @param contentLength int to Set
func (*ContentLength) String ¶
func (this *ContentLength) String() string
type ContentLengthHeader ¶
type ContentType ¶
type ContentType struct { Parameters // contains filtered or unexported fields }
* * ContentType SIP Header * <pre> *14.17 Content-Type * * The Content-Type entity-header field indicates the media type of the * entity-body sent to the recipient or, in the case of the HEAD method, * the media type that would have been sent had the request been a Get. * * Content-Type = "Content-Type" ":" media-type * * Media types are defined in section 3.7. An example of the field is * * Content-Type: text/html; charSet=ISO-8859-4 * * Further discussion of methods for identifying the media type of an * entity is provided in section 7.2.1. * * From HTTP RFC 2616 * </pre> * *
func NewContentTypeFromString ¶
func NewContentTypeFromString(contentType, contentSubtype string) *ContentType
* Constructor given a content type and subtype. *@param contentType is the content type. *@param contentSubtype is the content subtype
func (*ContentType) CompareMediaRange ¶
func (this *ContentType) CompareMediaRange(media string) bool
* compare two MediaRange headers.
- @param media String to Set
- @return int.
func (*ContentType) EncodeBody ¶
func (this *ContentType) EncodeBody() string
*
- Encode into a canonical string.
- @return String.
func (*ContentType) GetCharSet ¶
func (this *ContentType) GetCharSet() string
* Get the charSet parameter.
func (*ContentType) GetContentSubType ¶
func (this *ContentType) GetContentSubType() string
* Get the content subtype. *@return the content subtype string (or null if not Set).
func (*ContentType) GetContentType ¶
func (this *ContentType) GetContentType() string
* Get the content subtype. *@return the content tyep string (or null if not Set).
func (*ContentType) GetMediaRange ¶
func (this *ContentType) GetMediaRange() *MediaRange
* Get the mediaRange field.
- @return MediaRange.
func (*ContentType) GetMediaSubType ¶
func (this *ContentType) GetMediaSubType() string
* Get the MediaSubType field.
- @return String.
func (*ContentType) GetMediaType ¶
func (this *ContentType) GetMediaType() string
* Get the Media Type.
- @return String.
func (*ContentType) SetContentSubType ¶
func (this *ContentType) SetContentSubType(contentType string) (ParseException error)
* Set the content subtype.
- @param contentType String to Set
func (*ContentType) SetContentType ¶
func (this *ContentType) SetContentType(contentType string) (ParseException error)
* * Set the content type. *@param contentType Content type string.
func (*ContentType) SetContentTypeSubType ¶
func (this *ContentType) SetContentTypeSubType(contentType, contentSubType string)
* * Set the content type and subtype. *@param contentType Content type string. *@param contentSubType content subtype string
func (*ContentType) SetMediaRange ¶
func (this *ContentType) SetMediaRange(m *MediaRange)
*
- Set the mediaRange member
- @param m mediaRange field.
func (*ContentType) String ¶
func (this *ContentType) String() string
type ContentTypeHeader ¶
type ContentTypeHeader interface { ParametersHeader MediaType }
type Date ¶
type Date struct { SIPHeader // contains filtered or unexported fields }
* * Date Header.
func (*Date) GetDate ¶
*
- Gets the date of DateHeader. The date is repesented by the Calender
- object. *
- @return the Calendar object representing the date of DateHeader
type DateHeader ¶
type Encoding ¶
type Encoding interface { SetEncoding(encoding string) (ParseException error) /** * Gets the encoding of an EncodingHeader. Returns null if no * encoding is defined in an EncodingHeader. * * @return the string value identifing the encoding */ GetEncoding() string }
*
- This interface represents encoding methods for any header that contains an
- encoding value. *
- @see AcceptEncodingHeader
- @see ContentEncodingHeader
type ErrorInfo ¶
type ErrorInfo struct { Parameters // contains filtered or unexported fields }
* * ErrorInfo SIP Header.
func NewErrorInfoFromURI ¶
* Constructor given the error info *@param errorInfo -- the error information to set.
func (*ErrorInfo) GetErrorInfo ¶
*
- Returns the ErrorInfo value of this ErrorInfoHeader. This message
- may return null if a String message identifies the ErrorInfo. *
- @return the URI representing the ErrorInfo.
func (*ErrorInfo) GetErrorMessage ¶
*
- Get the Error information message of this ErrorInfoHeader. *
- @return the stringified version of the ErrorInfo header.
func (*ErrorInfo) SetErrorInfo ¶
*
- Sets the ErrorInfo of the ErrorInfoHeader to the <var>errorInfo</var>
- parameter value. *
- @param errorInfo the new ErrorInfo of this ErrorInfoHeader.
func (*ErrorInfo) SetErrorMessage ¶
*
- Sets the Error information message to the new <var>message</var> value
- supplied to this method. *
- @param message - the new string value that represents the error message.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the error message.
type ErrorInfoHeader ¶
type ErrorInfoList ¶
type ErrorInfoList struct {
SIPHeaderList
}
* * Error Info sip header. *@see ErrorInfoList *<pre> * * 6.24 Error-Info * * The Error-Info response header provides a pointer to additional * information about the error status response. This header field is * only contained in 3xx, 4xx, 5xx and 6xx responses. * * * * Error-Info = "Error-Info" ":" # ( "<" URI ">" *( ";" generic-param )) *</pre> *
type Event ¶
type Event struct { Parameters // contains filtered or unexported fields }
* * Event SIP Header.
func (*Event) GetEventId ¶
*
- Gets the id of the EventHeader. This method may return null if the
- "eventId" is not Set.
- @return the string object identifing the eventId of EventHeader.
func (*Event) GetEventType ¶
*
- Gets the eventType of the EventHeader. *
- @return the string object identifing the eventType of EventHeader.
func (*Event) Match ¶
- Return true if the given event header matches the supplied one. *
- @param matchTarGet -- event header to match against.
func (*Event) SetEventId ¶
*
- Sets the id to the newly supplied <var>eventId</var> string. *
- @param eventId - the new string defining the eventId of this EventHeader
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the eventId value.
func (*Event) SetEventType ¶
*
- Sets the eventType to the newly supplied eventType string. *
- @param eventType - the new string defining the eventType supported
- in this EventHeader
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the eventType value.
type EventHeader ¶
type EventHeader interface { ParametersHeader /** * Sets the eventType to the newly supplied eventType string. * * @param eventType - the new string defining the eventType supported * in this EventHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the eventType value. */ SetEventType(eventType string) (ParseException error) /** * Gets the eventType of the EventHeader. * * @return the string object identifing the eventType of EventHeader. */ GetEventType() string /** * Sets the id to the newly supplied eventId string. * * @param eventId - the new string defining the eventId of this EventHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the eventId value. */ SetEventId(eventId string) (ParseException error) /** * Gets the id of the EventHeader. This method may return null if the * eventId is not set. * * @return the string object identifing the eventId of EventHeader. */ GetEventId() string }
type Expires ¶
type Expires struct { SIPHeader // contains filtered or unexported fields }
* * Expires SIP Header.
func (*Expires) GetExpires ¶
*
- Gets the expires value of the ExpiresHeader. This expires value is *
- relative time. * * *
- @return the expires value of the ExpiresHeader. *
func (*Expires) SetExpires ¶
*
- Sets the relative expires value of the ExpiresHeader.
- The expires value MUST be greater than zero and MUST be
- less than 2**31. *
- @param expires - the new expires value of this ExpiresHeader *
- @throws InvalidArgumentException if supplied value is less than zero. *
type ExpiresHeader ¶
type ExpiresHeader interface { Header /** * Sets the relative expires value of the ExpiresHeader. The expires value * MUST be between zero and (2**31)-1. * * @param expires - the new expires value of this ExpiresHeader * @throws InvalidArgumentException if supplied value is less than zero. * */ SetExpires(expires int) (InvalidArgumentException error) GetExpires() int }
type Extension ¶
type Extension struct { SIPHeader // contains filtered or unexported fields }
* * A generic extension header for the stack. * The input text of the header gets recorded here.
func NewExtension ¶
func (*Extension) EncodeBody ¶
* Return just the body of this header encoded (leaving out the * name and the CRLF at the end).
func (*Extension) GetHeaderValue ¶
* Get the value of the extension header. *@return the value of the extension header.
type ExtensionHeader ¶
type ExtensionHeader interface { Header /** * Sets the value parameter of the ExtensionHeader. * * @param value - the new value of the ExtensionHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the value parameter. */ SetValue(value string) (ParseException error) }
type ExtensionHeaderList ¶
type ExtensionHeaderList struct {
SIPHeaderList
}
func NewExtensionHeaderList ¶
func NewExtensionHeaderList(hName string) *ExtensionHeaderList
func (*ExtensionHeaderList) String ¶
func (this *ExtensionHeaderList) String() string
type ExtensionHeaderLister ¶
type ExtensionHeaderLister interface { SIPHeaderLister }
type From ¶
type From struct {
AddressParameters
}
*
*From SIP Header.
func (*From) GetHostPort ¶
*
- Conveniance accessor function to get the hostPort field from the address.
- Warning -- this assumes that the embedded URI is a SipURL. *
- @return hostport field
func (*From) GetUserAtHostPort ¶
* Get the user@host port string.
type FromHeader ¶
type FromHeader interface { ParametersHeader AddressHeader /** * Sets the tag parameter of the FromHeader. The tag in the From field of a * request identifies the peer of the dialog. When a UA sends a request * outside of a dialog, it contains a From tag only, providing "half" of * the dialog Identifier. * <p> * The From Header MUST contain a new "tag" parameter, chosen by the UAC * applicaton. Once the initial From "tag" is assigned it should not be * manipulated by the application. That is on the client side for outbound * requests the application is responsible for Tag assigmennment, after * dialog establishment the stack will take care of Tag assignment. * * @param tag - the new tag of the FromHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Tag value. */ SetTag(tag string) (ParseException error) GetTag() string }
*
The From header field indicates the logical identity of the initiator
of the request, possibly the user's address-of-record. This may be different
from the initiator of the dialog. Requests sent by the callee to the caller
use the callee's address in the From header field.
<p>
Like the To header field, it contains a URI and optionally a display name,
encapsulated in a {@link javax.sip.address.Address}. It is used by SIP
elements to determine which processing rules to apply to a request (for
example, automatic call rejection). As such, it is very important that the
From URI not contain IP addresses or the FQDN of the host on which the UA is
running, since these are not logical names.
<p>
The From header field allows for a display name. A UAC SHOULD use
the display name "Anonymous", along with a syntactically correct, but
otherwise meaningless URI (like sip:thisis@anonymous.invalid), if the
identity of the client is to remain hidden.
<p>
Usually, the value that populates the From header field in requests
generated by a particular UA is pre-provisioned by the user or by the
administrators of the user's local domain. If a particular UA is used by
multiple users, it might have switchable profiles that include a URI
corresponding to the identity of the profiled user. Recipients of requests
can authenticate the originator of a request in order to ascertain that
they are who their From header field claims they are.
<p>
Two From header fields are equivalent if their URIs match, and their
parameters match. Extension parameters in one header field, not present in
the other are ignored for the purposes of comparison. This means that the
display name and presence or absence of angle brackets do not affect
matching.
<ul>
<li> The "Tag" parameter - is used in the To and From header fields of SIP
messages. It serves as a general mechanism to identify a dialog, which is
the combination of the Call-ID along with two tags, one from each
participant in the dialog. When a User Agent sends a request outside of a dialog,
it contains a From tag only, providing "half" of the dialog ID. The dialog
is completed from the response(s), each of which contributes the second half
in the To header field. When a tag is generated by a User Agent for insertion into
a request or response, it MUST be globally unique and cryptographically
random with at least 32 bits of randomness. Besides the requirement for
global uniqueness, the algorithm for generating a tag is implementation
specific. Tags are helpful in fault tolerant systems, where a dialog is to
be recovered on an alternate server after a failure. A UAS can select the
tag in such a way that a backup can recognize a request as part of a dialog
on the failed server, and therefore determine that it should attempt to
recover the dialog and any other state associated with it.
</ul>
For Example:<br>
<code>From: "Bob" sips:bob@biloxi.com ;tag=a48s<br>
From: sip:+12125551212@phone2net.com;tag=887s<br>
From: Anonymous sip:c8oqz84zk7z@privacy.org;tag=hyh8</code>
type Header ¶
type Header interface { EncodeBody() string GetHeaderName() string GetHeaderValue() string IsHeaderList() bool SetHeaderName(hdrname string) GetValue() string /** * Gets the unique string name of this Header. A name constant is defined in * each individual Header identifying each Header. * * @return the name of this specific Header */ GetName() string /** * Creates and returns a deep copy of the Header. This methods must ensure a * deep copy of the Header, so that when a message is cloned the Header can * be modified without effecting the original Header in the message. This * provides useful functionality for proxying Requests and Responses, for * example: * <ul> * <li>Recieve a message. * <li>Create a deep clone of the message and headers. * <li>Modify necessary headers. * <li>Proxy the message using the send methods on the SipProvider. * </ul> * This method overrides the clone method in java.lang.Object. * * @return a deep copy of Header */ Clone() interface{} /** * Gets a string representation of the Header. This method overrides the * toString method in java.lang.Object. * * @return string representation of Header */ String() string }
type InReplyTo ¶
type InReplyTo struct { SIPHeader // contains filtered or unexported fields }
* * InReplyTo SIP Header.
func NewInReplyToFromCallIdentifier ¶
func NewInReplyToFromCallIdentifier(cid *CallIdentifier) *InReplyTo
* constructor
- @param cid CallIdentifier to Set
func (*InReplyTo) GetCallId ¶
*
- Returns the Call-Id of InReplyToHeader. The CallId parameter uniquely
- identifies a series of messages within a dialogue. *
- @return the String value of the Call-Id of this InReplyToHeader
func (*InReplyTo) SetCallId ¶
*
- Sets the Call-Id of the InReplyToHeader. The CallId parameter uniquely
- identifies a serious of messages within a dialogue. *
- @param callId - the string value of the Call-Id of this InReplyToHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the callId value.
type InReplyToHeader ¶
type InReplyToHeader interface { Header /** * Sets the Call-Id of the InReplyToHeader. The CallId parameter uniquely * identifies a serious of messages within a dialogue. * * @param callId - the string value of the Call-Id of this InReplyToHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the callId value. */ SetCallId(callId string) (ParseException error) /** * Returns the Call-Id of InReplyToHeader. The CallId parameter uniquely * identifies a series of messages within a dialogue. * * @return the String value of the Call-Id of this InReplyToHeader */ GetCallId() string }
*
- The In-Reply-To header field enumerates the Call-IDs that this call
- references or returns. These Call-IDs may have been cached by the client
- then included in this header field in a return call.
- <p>
- This allows automatic call distribution systems to route return calls to the
- originator of the first call. This also allows callees to filter calls, so
- that only return calls for calls they originated will be accepted. This
- field is not a substitute for request authentication.
- <p>
- For Example:<br>
- <code>In-Reply-To: 70710@saturn.jcp.org, 17320@saturn.jcp.org</code>
type InReplyToList ¶
type InReplyToList struct {
SIPHeaderList
}
* * In-Reply-To SIP header. Keeps a list of CallIdentifiers
type Lister ¶
type Lister interface { Back() *list.Element Front() *list.Element Init() *list.List InsertAfter(v interface{}, mark *list.Element) *list.Element InsertBefore(v interface{}, mark *list.Element) *list.Element Len() int MoveAfter(e, mark *list.Element) MoveBefore(e, mark *list.Element) MoveToBack(e *list.Element) MoveToFront(e *list.Element) PushBack(v interface{}) *list.Element PushBackList(other *list.List) PushFront(v interface{}) *list.Element PushFrontList(other *list.List) Remove(e *list.Element) interface{} }
type MaxForwards ¶
type MaxForwards struct { SIPHeader // contains filtered or unexported fields }
* * MaxForwards Header
func (*MaxForwards) DecrementMaxForwards ¶
func (this *MaxForwards) DecrementMaxForwards() error
* decrement MaxForwards field one by one.
func (*MaxForwards) EncodeBody ¶
func (this *MaxForwards) EncodeBody() string
*
- Encode into a string.
- @return encoded string. *
func (*MaxForwards) GetMaxForwards ¶
func (this *MaxForwards) GetMaxForwards() int
* get the MaxForwards field.
- @return the maxForwards member.
func (*MaxForwards) HasReachedZero ¶
func (this *MaxForwards) HasReachedZero() bool
* Boolean function
- @return true if MaxForwards field reached zero.
func (*MaxForwards) SetMaxForwards ¶
func (this *MaxForwards) SetMaxForwards(maxForwards int) (InvalidArgumentException error)
*
- Set the maxForwards member
- @param maxForwards maxForwards parameter to set
func (*MaxForwards) String ¶
func (this *MaxForwards) String() string
type MaxForwardsHeader ¶
type MediaRange ¶
type MediaRange struct {
// contains filtered or unexported fields
}
* * Media Range * @see Accept * <pre> * media-range = ( "STAR/STAR" * | ( type "/" STAR ) * | ( type "/" subtype ) * ) *( ";" parameter ) * * HTTP RFC 2616 Section 14.1 * </pre>
func (*MediaRange) GetSubtype ¶
func (this *MediaRange) GetSubtype() string
* get the subType field.
- @return String
func (*MediaRange) GetType ¶
func (this *MediaRange) GetType() string
* get type field
- @return String
func (*MediaRange) SetSubtype ¶
func (this *MediaRange) SetSubtype(s string)
*
- Set the subtype member
- @param s String to set
func (*MediaRange) SetType ¶
func (this *MediaRange) SetType(t string)
*
- Set the type member
- @param t String to set
func (*MediaRange) String ¶
func (this *MediaRange) String() string
*
- Encode the object.
- @return String
type MediaType ¶
type MediaType interface { /** * Sets value of media type of Header with Content Type. * * @param contentType - the new string value of the content type * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the contentType value. */ SetContentType(contentType string) (ParseException error) /** * Gets media type of Header with Content type. * * @return media type of Header with Content type. */ GetContentType() string /** * Sets value of media subtype of Header with Content sub-type. * * @param contentSubType - the new string value of the content sub-type. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the contentSubType value. */ SetContentSubType(contentSubType string) (ParseException error) /** * Gets media sub-type of Header with Content sub-type. * * @return media sub-type of Header with Content sub-type. */ GetContentSubType() string }
type MimeVersion ¶
type MimeVersion struct { SIPHeader // contains filtered or unexported fields }
* * MimeVersion SIP Header.
func (*MimeVersion) EncodeBody ¶
func (this *MimeVersion) EncodeBody() string
*
- Return canonical form.
- @return String
func (*MimeVersion) GetMajorVersion ¶
func (this *MimeVersion) GetMajorVersion() int
*
- Gets the Major version value of this MimeVersionHeader. *
- @return the Major version of this MimeVersionHeader
func (*MimeVersion) GetMinorVersion ¶
func (this *MimeVersion) GetMinorVersion() int
*
- Gets the Minor version value of this MimeVersionHeader. *
- @return the Minor version of this MimeVersionHeader
func (*MimeVersion) SetMajorVersion ¶
func (this *MimeVersion) SetMajorVersion(majorVersion int) (InvalidArgumentException error)
*
- Sets the Major-Version argument of this MimeVersionHeader to the supplied
- <var>majorVersion</var> value. *
- @param majorVersion - the new integer Major version
- @throws InvalidArgumentException
func (*MimeVersion) SetMinorVersion ¶
func (this *MimeVersion) SetMinorVersion(minorVersion int) (InvalidArgumentException error)
*
- Sets the Minor-Version argument of this MimeVersionHeader to the supplied
- <var>minorVersion</var> value. *
- @param minorVersion - the new integer Minor version
- @throws InvalidArgumentException
func (*MimeVersion) String ¶
func (this *MimeVersion) String() string
type MimeVersionHeader ¶
type MimeVersionHeader interface { Header /** * Gets the Minor version value of this MimeVersionHeader. * * @return the Minor version of this MimeVersionHeader */ GetMinorVersion() int /** * Sets the Minor-Version argument of this MimeVersionHeader to the supplied * minorVersion value. * * @param minorVersion - the new minor MIME version * @throws InvalidArgumentException if the supplied value is less than zero. */ SetMinorVersion(minorVersion int) (InvalidArgumentException error) /** * Gets the Major version value of this MimeVersionHeader. * * @return the Major version of this MimeVersionHeader */ GetMajorVersion() int /** * Sets the Major-Version argument of this MimeVersionHeader to the supplied * majorVersion value. * * @param majorVersion - the new major MIME version * @throws InvalidArgumentException if the supplied version is less than zero. */ SetMajorVersion(majorVersion int) (InvalidArgumentException error) }
*
- SIP messages MAY include a single MIME-Version general-header field to
- indicate what version of the MIME protocol was used to construct the
- message. Use of the MIME-Version header field indicates that the message is
- in full compliance with the MIME protocol as defined in
- <a href = "http://www.ietf.org/rfc/rfc2405.txt">RFC2045</a>. Proxies/gateways
- are responsible for ensuring full compliance (where possible) when exporting
- SIP messages to strict MIME environments.
- <p>
- For Example:<br>
- <code>MIME-Version: 1.0</code>
type MinExpires ¶
type MinExpires struct { SIPHeader // contains filtered or unexported fields }
* * MinExpires SIP Header.
func (*MinExpires) EncodeBody ¶
func (this *MinExpires) EncodeBody() string
*
- Return canonical form.
- @return String
func (*MinExpires) GetExpires ¶
func (this *MinExpires) GetExpires() int
*
- Gets the expires value of the ExpiresHeader. This expires value is *
- relative time. * * *
- @return the expires value of the ExpiresHeader. *
func (*MinExpires) SetExpires ¶
func (this *MinExpires) SetExpires(expires int) (InvalidArgumentException error)
*
- Sets the relative expires value of the ExpiresHeader.
- The expires value MUST be greater than zero and MUST be
- less than 2**31. *
- @param expires - the new expires value of this ExpiresHeader *
- @throws InvalidArgumentException if supplied value is less than zero. *
func (*MinExpires) String ¶
func (this *MinExpires) String() string
type MinExpiresHeader ¶
type MinExpiresHeader interface { ExpiresHeader }
type OptionTag ¶
type OptionTag interface { /** * Sets the option tag value to the new supplied optionTag * parameter. * * @param optionTag - the new string value of the option tag. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the optionTag value. */ SetOptionTag(optionTag string) (ParseException error) /** * Gets the option tag of this OptionTag class. * * @return the string that identifies the option tag value. */ GetOptionTag() string }
type Organization ¶
type Organization struct { SIPHeader // contains filtered or unexported fields }
* *Organization SIP Header.
func (*Organization) EncodeBody ¶
func (this *Organization) EncodeBody() string
*
- Return encoding of value of the header.
- @return String
func (*Organization) GetOrganization ¶
func (this *Organization) GetOrganization() string
* get the organization field.
- @return String
func (*Organization) SetOrganization ¶
func (this *Organization) SetOrganization(o string) (ParseException error)
*
- Set the organization member
- @param o String to set
func (*Organization) String ¶
func (this *Organization) String() string
type OrganizationHeader ¶
type Parameters ¶
type Parameters struct { SIPHeader // contains filtered or unexported fields }
func NewParameters ¶
func NewParameters(hdrName string) *Parameters
func (*Parameters) EncodeBody ¶
func (this *Parameters) EncodeBody() string
func (*Parameters) GetNameValue ¶
func (this *Parameters) GetNameValue(parameterName string) *core.NameValue
* This is for the benifit of the TCK. * *@return the name value pair for the given parameter name.
func (*Parameters) GetParameter ¶
func (this *Parameters) GetParameter(name string) string
*
- Returns the value of the named parameter, or null if it is not set. A
- zero-length String indicates flag parameter. *
- @param <var>name</var> name of parameter to retrieve
- @return the value of specified parameter
func (*Parameters) GetParameterNames ¶
func (this *Parameters) GetParameterNames() *list.List
func (*Parameters) GetParameterValue ¶
func (this *Parameters) GetParameterValue(name string) string
- Return the parameter as an object (dont convert to string). * *@param name is the name of the parameter to get. *@return the object associated with the name. *
func (*Parameters) GetParameters ¶
func (this *Parameters) GetParameters() *core.NameValueList
*
- get the parameter list.
- @return parameter list
func (*Parameters) HasParameter ¶
func (this *Parameters) HasParameter(parameterName string) bool
- Return true if has a parameter. * *@param paramName is the name of the parameter. * *@return true if the parameter exists and false if not.
func (*Parameters) HasParameters ¶
func (this *Parameters) HasParameters() bool
func (*Parameters) RemoveParameter ¶
func (this *Parameters) RemoveParameter(name string)
func (*Parameters) RemoveParameters ¶
func (this *Parameters) RemoveParameters()
*
*Remove all parameters.
func (*Parameters) SetParameter ¶
func (this *Parameters) SetParameter(name, value string) (ParseException error)
*
- Sets the value of the specified parameter. If the parameter already had *
- a value it will be overwritten. A zero-length String indicates flag *
- parameter. * * *
- @param name - a String specifying the parameter name *
- @param value - a String specifying the parameter value *
- @throws ParseException which signals that an error has been reached *
- unexpectedly while parsing the parameter name or value. *
func (*Parameters) SetParameterFromNameValue ¶
func (this *Parameters) SetParameterFromNameValue(nameValue *core.NameValue)
- Set the parameter given a name and value. *
- @param nameValue - the name value of the parameter to set.
func (*Parameters) SetParameters ¶
func (this *Parameters) SetParameters(parameters *core.NameValueList)
- Set the parameter list. * *@param nameValueList - the name value list to set as the parameter list.
func (*Parameters) SetQuotedParameter ¶
func (this *Parameters) SetQuotedParameter(name, value string)
*
- Sets the value of the specified parameter. If the parameter already had *
- a value it will be overwritten. A zero-length String indicates flag *
- parameter. * * *
- @param name - a String specifying the parameter name *
- @param value - a String specifying the parameter value *
- @throws ParseException which signals that an error has been reached *
- unexpectedly while parsing the parameter name or value. *
func (*Parameters) String ¶
func (this *Parameters) String() string
type ParametersHeader ¶
type ParametersHeader interface { Header GetParameter(name string) string GetParameterValue(name string) string //interface{} TODO GetParameterNames() *list.List HasParameters() bool RemoveParameter(name string) SetParameter(name, value string) (ParseException error) SetQuotedParameter(name, value string) HasParameter(parameterName string) bool RemoveParameters() GetParameters() *core.NameValueList SetParameters(parameters *core.NameValueList) GetNameValue(parameterName string) *core.NameValue }
type Priority ¶
type Priority struct { SIPHeader // contains filtered or unexported fields }
* * the Priority header.
type PriorityHeader ¶
type Protocol ¶
type Protocol struct {
// contains filtered or unexported fields
}
* * Protocol name and version.
type ProxyAuthenticate ¶
type ProxyAuthenticate struct {
Authentication
}
* * Proxy Authenticate SIP (HTTP ) header.
type ProxyAuthenticateHeader ¶
type ProxyAuthenticateHeader interface { WWWAuthenticateHeader }
*
- A Proxy-Authenticate header field value contains an authentication
- challenge. When a UAC sends a request to a proxy server, the proxy server
- MAY authenticate the originator before the request is processed. If no
- credentials (in the Proxy-Authorization header field) are provided in the
- request, the proxy can challenge the originator to provide credentials by
- rejecting the request with a 407 (Proxy Authentication Required) status
- code. The proxy MUST populate the 407 (Proxy Authentication Required)
- message with a Proxy-Authenticate header field value applicable to the
- proxy for the requested resource. The field value consists of a challenge
- that indicates the authentication and parameters applicable to the proxy
- for this RequestURI.
- <p>
- Note - Unlike its usage within HTTP, the ProxyAuthenticateHeader must be
- passed upstream in the Response to the UAC. In SIP, only UAC's can
- authenticate themselves to proxies.
- <p>
- Proxies MUST NOT add values to the Proxy-Authorization header field. All
- 407 (Proxy Authentication Required) responses MUST be forwarded upstream
- toward the UAC following the procedures for any other response. It is the
- UAC's responsibility to add the Proxy-Authorization header field value
- containing credentials for the realm of the proxy that has asked for
- authentication.
- <p>
- When the originating UAC receives the 407 (Proxy Authentication Required)
- it SHOULD, if it is able, re-originate the request with the proper
- credentials. It should follow the same procedures for the display of the
- "realm" parameter that are given above for responding to 401. If no
- credentials for a realm can be located, UACs MAY attempt to retry the
- request with a username of "anonymous" and no password (a password of "").
- The UAC SHOULD also cache the credentials used in the re-originated request.
- <p>
- For Example:<br>
- <code>Proxy-Authenticate: Digest realm="jcp.org",
- domain="sip:ss1.duke.com", qop="auth",
- nonce="f84f1cec41e6cbe5aea9c8e88d359", opaque="", stale=FALSE,
- algorithm=MD5</code> *
- @see Parameters
- @see ProxyAuthorizationHeader
type ProxyAuthenticateList ¶
type ProxyAuthenticateList struct {
SIPHeaderList
}
* * List of ProxyAuthenticate headers.
func NewProxyAuthenticateList ¶
func NewProxyAuthenticateList() *ProxyAuthenticateList
* Default constructor
type ProxyAuthorization ¶
type ProxyAuthorization struct {
Authentication
}
* * ProxyAuthorization SIP header.
func NewProxyAuthorization ¶
func NewProxyAuthorization() *ProxyAuthorization
* Default constructor.
type ProxyAuthorizationHeader ¶
type ProxyAuthorizationHeader interface { AuthenticationHeader }
type ProxyRequire ¶
type ProxyRequire struct { SIPHeader // contains filtered or unexported fields }
* * ProxyRequire Header.
func NewProxyRequire ¶
func NewProxyRequire() *ProxyRequire
* Default Constructor
- @param s String to set
func NewProxyRequireFromString ¶
func NewProxyRequireFromString(s string) *ProxyRequire
* Constructor
- @param s String to set
func (*ProxyRequire) EncodeBody ¶
func (this *ProxyRequire) EncodeBody() string
*
- Encode in canonical form.
- @return String
func (*ProxyRequire) GetOptionTag ¶
func (this *ProxyRequire) GetOptionTag() string
*
- Gets the option tag of this OptionTag class. *
- @return the string that identifies the option tag value.
func (*ProxyRequire) SetOptionTag ¶
func (this *ProxyRequire) SetOptionTag(optionTag string) (ParseException error)
*
- Sets the option tag value to the new supplied <var>optionTag</var>
- parameter. *
- @param optionTag - the new string value of the option tag.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the optionTag value.
func (*ProxyRequire) String ¶
func (this *ProxyRequire) String() string
type ProxyRequireHeader ¶
type ProxyRequireHeader interface { RequireHeader }
type ProxyRequireList ¶
type ProxyRequireList struct {
SIPHeaderList
}
* * Proxy Require SIPSIPObject (list of option tags)
type RAck ¶
type RAck struct { SIPHeader // contains filtered or unexported fields }
* * RAck SIP Header implementation
func (*RAck) EncodeBody ¶
* Encode the body of this header (the stuff that follows headerName).
- A.K.A headerValue.
func (*RAck) GetCSeqNumber ¶
- Gets the CSeq sequence number of this RAckHeader. *
- @return the integer value of the cSeq number of the RAckHeader
func (*RAck) GetRSeqNumber ¶
- Gets the RSeq sequence number of this RAckHeader. *
- @return the integer value of the RSeq number of the RAckHeader
func (*RAck) SetCSeqNumber ¶
* Sets the sequence number value of the CSeqHeader of the provisional
- response being acknowledged. The sequence number MUST be expressible as
- a 32-bit unsigned integer and MUST be less than 2**31. *
- @param cSeqNumber - the new cSeq number of this RAckHeader
- @throws InvalidArgumentException if supplied value is less than zero.
func (*RAck) SetMethod ¶
* Sets the method of RAckHeader, which correlates to the method of the
- CSeqHeader of the provisional response being acknowledged. *
- @param method - the new string value of the method of the RAckHeader
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the method value.
func (*RAck) SetRSeqNumber ¶
* Sets the sequence number value of the RSeqHeader of the provisional
- response being acknowledged. The sequence number MUST be expressible as
- a 32-bit unsigned integer and MUST be less than 2**31. *
- @param rSeqNumber - the new rSeq number of this RAckHeader
- @throws InvalidArgumentException if supplied value is less than zero.
type RAckHeader ¶
type RAckHeader interface { Header /** * Sets the method of RAckHeader, which correlates to the method of the * CSeqHeader of the provisional response being acknowledged. * * @param method - the new string value of the method of the RAckHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the method value. */ SetMethod(method string) (ParseException error) /** * Gets the method of RAckHeader. * * @return method of RAckHeader. */ GetMethod() string /** * Sets the sequence number value of the CSeqHeader of the provisional * response being acknowledged. The sequence number MUST be expressible as * a 32-bit unsigned integer and MUST be less than 2**31. * * @param cSeqNumber - the new cSeq number of this RAckHeader. * @throws InvalidArgumentException if supplied value is less than zero. */ SetCSeqNumber(cSeqNumber int) (InvalidArgumentException error) /** * Gets the CSeq sequence number of this RAckHeader. * * @return the integer value of the cSeq number of the RAckHeader. */ GetCSeqNumber() int /** * Sets the sequence number value of the RSeqHeader of the provisional * response being acknowledged. The sequence number MUST be expressible as * a 32-bit unsigned integer and MUST be less than 2**31. * * @param rSeqNumber - the new rSeq number of this RAckHeader. * @throws InvalidArgumentException if supplied value is less than zero. */ SetRSeqNumber(rSeqNumber int) (InvalidArgumentException error) /** * Gets the RSeq sequence number of this RAckHeader. * * @return the integer value of the RSeq number of the RAckHeader. */ GetRSeqNumber() int }
type RSeq ¶
type RSeq struct { SIPHeader // contains filtered or unexported fields }
func (*RSeq) EncodeBody ¶
* Encode the body of this header (the stuff that follows headerName).
- A.K.A headerValue.
func (*RSeq) GetSequenceNumber ¶
- Gets the sequence number of this RSeqHeader. *
- @return the integer value of the Sequence number of the RSeqHeader
func (*RSeq) SetSequenceNumber ¶
* Sets the sequence number value of the RSeqHeader of the provisional
- response. The sequence number MUST be expressible as a 32-bit unsigned
- integer and MUST be less than 2**31. *
- @param sequenceNumber - the new Sequence number of this RSeqHeader
- @throws InvalidArgumentException if supplied value is less than zero.
type RSeqHeader ¶
type RSeqHeader interface { Header /** * Sets the sequence number value of the RSeqHeader of the provisional * response. The sequence number MUST be expressible as a 32-bit unsigned * integer and MUST be less than 2**31. * * @param sequenceNumber - the new Sequence number of this RSeqHeader * @throws InvalidArgumentException if supplied value is less than zero. */ SetSequenceNumber(sequenceNumber int) (InvalidArgumentException error) /** * Gets the sequence number of this RSeqHeader. * * @return the integer value of the Sequence number of the RSeqHeader */ GetSequenceNumber() int }
type Reason ¶
type Reason struct { Parameters // contains filtered or unexported fields }
* *Definition of the Reason SIP Header.
func (*Reason) EncodeBody ¶
* Encode the body of this header (the stuff that follows headerName).
- A.K.A headerValue.
func (*Reason) GetName ¶
* Set the cause.
/** Gets the unique string name of this Header. A name constant is defined in * each individual Header identifying each Header. * * @return the name of this specific Header
func (*Reason) GetProtocol ¶
- Return the protocol. * *@return the protocol.
func (*Reason) SetProtocol ¶
type ReasonHeader ¶
type ReasonHeader interface { ParametersHeader /** * Gets the cause value of the ReasonHeader * * @return the integer value of the cause of the ReasonHeader */ GetCause() int /** * Sets the cause value of the ReasonHeader. Any SIP status code MAY * appear in the Reason header field of a request, assuming the protocol * field of the ReasonHeader is SIP. * * @param cause - the new integer value of the cause of the ReasonHeader * @throws InvalidArgumentException if the cause value is less than zero. */ SetCause(cause int) (InvalidArgumentException error) /** * Sets the protocol of the ReasonHeader, for example SIP or Q.850. * * @param protocol - the new string value of the protocol of the ReasonHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the protocol value. */ SetProtocol(protocol string) (ParseException error) /** * Gets the protocol value of the ReasonHeader * * @return the string value of the protocol of the ReasonHeader */ GetProtocol() string /** * Sets the text value of the ReasonHeader. * * @param text - the new string value of the text of the ReasonHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the text value. */ SetText(text string) (ParseException error) /** * Gets the text value of the ReasonHeader * * @return the string value of the text of the ReasonHeader */ GetText() string }
type RecordRoute ¶
type RecordRoute struct {
AddressParameters
}
* The Request-Route header is added to a request by any proxy that insists on
- being in the path of subsequent requests for the same call leg.
func NewRecordRouteFromAddress ¶
func NewRecordRouteFromAddress(addr address.Address) *RecordRoute
* constructor
- @param addr address to set
func (*RecordRoute) EncodeBody ¶
func (this *RecordRoute) EncodeBody() string
- Encode into canonical form. *@return String containing the canonicaly encoded header.
func (*RecordRoute) String ¶
func (this *RecordRoute) String() string
type RecordRouteHeader ¶
type RecordRouteHeader interface { AddressHeader ParametersHeader }
*
- The Record-Route header field is inserted by proxies in a request to force
- future requests in the dialog to be routed through the proxy. The
- SipProvider (as opposed to the application) should attach Record-Route
- headers to messages explicitly when forwarding them if necessary.
- <p>
- The RecordRouteHeader is added to a Request by any proxy that insists on being
- in the path of subsequent Requests for the same call leg. It contains
- a globally reachable RequestURI that identifies the proxy server. Each proxy
- server adds its Address URI to the beginning of the list.
- <p>
- The calling user agent client copies the RecordRouteHeaders into
- RouteHeaders of subsequent Requests within the same call leg, reversing the
- order, so that the first entry is closest to the user agent client. If the
- Response contained a ContactHeader field, the calling user agent adds its
- content as the last RouteHeader. Unless this would cause a loop, a client
- must send subsequent Requests for this call leg to the Address URI in the
- first RouteHeader and remove that entry.
- <p>
- Some proxies, such as those controlling firewalls or in an automatic call
- distribution (ACD) system, need to maintain call state and thus need to
- receive any BYE and ACK Requests for the call.
- <p>
- For Example:<br>
- <code>Record-Route: sip:server10.jcp.org;lr,
- sip:bigbox3.duke.jcp.org;lr</code> *
- @see RouteHeader
- @see AddressHeader
- @see Parameters
type RecordRouteList ¶
type RecordRouteList struct {
SIPHeaderList
}
* * RecordRoute List of SIP headers (a collection of Addresses)
type ReferTo ¶
type ReferTo struct {
AddressParameters
}
type ReferToHeader ¶
type ReferToHeader interface { AddressHeader ParametersHeader }
*
- This interface represents the ReferTo SIP header, as defined by
- <a href = "http://www.ietf.org/rfc/rfc3515.txt">RFC3515</a>, this header is
- not part of RFC3261.
- <p>
- A ReferToHeader only appears in a REFER request. It provides a URL to
- reference. The ReferToHeader field MAY be encrypted as part of end-to-end
- encryption. The resource identified by the Refer-To URI is contacted using
- the normal mechanisms for that URI type.
type ReplyTo ¶
type ReplyTo struct {
AddressParameters
}
* * ReplyTo Header.
func NewReplyToFromAddress ¶
- Default constructor given an address. * *@param address -- address of this header. *
func (*ReplyTo) GetHostPort ¶
*
- Conveniance accessor function to get the hostPort field from the address
- @return HostPort
type ReplyToHeader ¶
type ReplyToHeader interface { AddressHeader ParametersHeader }
type RequestLine ¶
type RequestLine struct {
// contains filtered or unexported fields
}
* * RequestLine of SIP Request.
func NewRequestLineFromString ¶
func NewRequestLineFromString(requestURI address.URI, method string) *RequestLine
* Constructor given the request URI and the method.
func (*RequestLine) GetMethod ¶
func (this *RequestLine) GetMethod() string
*
- Get the Method *
- @return method string.
func (*RequestLine) GetSipVersion ¶
func (this *RequestLine) GetSipVersion() string
*
- Get the SIP version. *
- @return String
func (*RequestLine) GetUri ¶
func (this *RequestLine) GetUri() address.URI
- Get the Request-URI. *
- @return the request URI
func (*RequestLine) GetVersionMajor ¶
func (this *RequestLine) GetVersionMajor() string
* * Get the major verrsion number. * *@return String major version number
func (*RequestLine) GetVersionMinor ¶
func (this *RequestLine) GetVersionMinor() string
*
- Get the minor version number. * *@return String minor version number *
func (*RequestLine) SetMethod ¶
func (this *RequestLine) SetMethod(method string)
*
- Set the method member *
- @param method String to Set
func (*RequestLine) SetSIPVersion ¶
func (this *RequestLine) SetSIPVersion(sipVersion string)
* Set the SIP version. *@param sipVersion -- the SIP version to Set.
func (*RequestLine) SetSipVersion ¶
func (this *RequestLine) SetSipVersion(s string)
*
- Set the sipVersion member *
- @param s String to Set
func (*RequestLine) SetUri ¶
func (this *RequestLine) SetUri(uri address.URI)
*
- Set the uri member.
- @param uri URI to Set.
func (*RequestLine) String ¶
func (this *RequestLine) String() string
- Encode the request line as a String. *
- @return requestLine encoded as a string.
type Require ¶
type Require struct { SIPHeader // contains filtered or unexported fields }
* *Require SIP Header.
func (*Require) GetOptionTag ¶
*
- Gets the option tag of this OptionTag class. *
- @return the string that identifies the option tag value.
func (*Require) SetOptionTag ¶
*
- Sets the option tag value to the new supplied <var>optionTag</var>
- parameter. *
- @param optionTag - the new string value of the option tag.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the optionTag value.
type RequireHeader ¶
type RequireList ¶
type RequireList struct {
SIPHeaderList
}
* * List of Require headers. * <pre> * Require = "Require" ":" 1#option-tag * </pre>
type RetryAfter ¶
type RetryAfter struct { Parameters // contains filtered or unexported fields }
* Retry-After SIP Header.
func (*RetryAfter) EncodeBody ¶
func (this *RetryAfter) EncodeBody() string
* Encode body of this into cannonical form.
- @return encoded body
func (*RetryAfter) GetComment ¶
func (this *RetryAfter) GetComment() string
func (*RetryAfter) GetDuration ¶
func (this *RetryAfter) GetDuration() int
func (*RetryAfter) GetRetryAfter ¶
func (this *RetryAfter) GetRetryAfter() int
func (*RetryAfter) HasComment ¶
func (this *RetryAfter) HasComment() bool
* Boolean function
- @return true if comment exist, false otherwise
func (*RetryAfter) RemoveDuration ¶
func (this *RetryAfter) RemoveDuration()
* remove duration field
func (*RetryAfter) SetComment ¶
func (this *RetryAfter) SetComment(comment string) (ParseException error)
func (*RetryAfter) SetDuration ¶
func (this *RetryAfter) SetDuration(duration int) (InvalidArgumentException error)
func (*RetryAfter) SetRetryAfter ¶
func (this *RetryAfter) SetRetryAfter(retryAfter int) (InvalidArgumentException error)
func (*RetryAfter) String ¶
func (this *RetryAfter) String() string
type RetryAfterHeader ¶
type Route ¶
type Route struct {
AddressParameters
}
func NewRouteFromAddress ¶
- Default constructor given an address. * *@param address -- address of this header. *
func (*Route) EncodeBody ¶
*
- Encode into canonical form.
- Acknowledgement: contains a bug fix for a bug reported by
- Laurent Schwizer * *@return a canonical encoding of the header.
type RouteHeader ¶
type RouteHeader interface { AddressHeader ParametersHeader }
*
- The Route header field is used to force routing for a request through the
- listed set of proxies. Each host removes the first entry and then proxies
- the Request to the host listed in that entry using it as the RequestURI.
- <p>
- Explicit Route assignment (if needed) for the initial dialog establishment
- is the applications responsibility, but once established Routes are
- maintained by the dialog layer and should not be manupulated by the
- application. For example the SipProvider queries the dialog for Route
- assignment and adds these to the outgoing message as needed. The
- {@link javax.sip.address.Router} may be used by the application to determine
- the initial Route of the message. *
- @see RecordRouteHeader
- @see AddressHeader
- @see Parameters *
type SIPHeader ¶
type SIPHeader struct {
// contains filtered or unexported fields
}
* * Root class from which all Header objects are subclassed.
func (*SIPHeader) EncodeBody ¶
* Encode the body of this header (the stuff that follows headerName). * A.K.A headerValue.
func (*SIPHeader) GetHeaderValue ¶
* Get the header value (i.e. what follows the name:). * This merely goes through and lops off the portion that follows * the headerName:
func (*SIPHeader) IsHeaderList ¶
* Return false if this is not a header list * (SIPHeaderList overrrides this method). *@return false
type SIPHeaderList ¶
*
- This is the root class for all lists of SIP headers.
- It imbeds a SIPObjectList object and extends Header
- Lists of ContactSIPObjects etc. derive from this class.
- This supports homogeneous lists (all elements in the list are of
- the same class). We use this for building type homogeneous lists of
- SIPObjects that appear in SIPHeaders * *
func NewSIPHeaderList ¶
func NewSIPHeaderList(hname string) *SIPHeaderList
* Constructor
- @param hl SIPObjectList to set
- @param hname String to set
func (*SIPHeaderList) Clone ¶
func (this *SIPHeaderList) Clone() interface{}
*
- Implement the clone method.
func (*SIPHeaderList) Concatenate ¶
func (this *SIPHeaderList) Concatenate(shl SIPHeaderLister, topFlag bool)
func (*SIPHeaderList) EncodeBody ¶
func (this *SIPHeaderList) EncodeBody() string
* Encode the body of this header (the stuff that follows headerName).
- A.K.A headerValue. This will not give a reasonable result for *WWW-Authenticate, Authorization, Proxy-Authenticate and *Proxy-Authorization and hence this is protected.
func (*SIPHeaderList) GetHeadersAsEncodedStrings ¶
func (this *SIPHeaderList) GetHeadersAsEncodedStrings() *list.List
- Get the headers as a linked list of encoded Strings *@return a linked list with each element of the list containing a
- string encoded header in canonical form.
func (*SIPHeaderList) IsHeaderList ¶
func (this *SIPHeaderList) IsHeaderList() bool
func (*SIPHeaderList) String ¶
func (this *SIPHeaderList) String() string
*
- Encode a list of sip headers.
- Headers are returned in cannonical form.
- @return String encoded string representation of this list of
- headers. (Contains string append of each encoded header).
type SIPHeaderLister ¶
type Server ¶
type Server struct { SIPHeader // contains filtered or unexported fields }
* *Supported SIP Header.
func (*Server) EncodeBody ¶
* Encode only the body of this header. *@return encoded value of the header.
func (*Server) GetProduct ¶
*
- Returns the list value of the product parameter. *
- @return the software of this UserAgentHeader
func (*Server) SetProduct ¶
*
- Sets the product value of the UserAgentHeader. *
- @param product - a List specifying the product value
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the product value.
type ServerHeader ¶
type ServerHeader interface { Header /** * Returns a ListIterator over the List of product values. * * @return a ListIterator over the List of strings identifying the * software of this ServerHeader */ GetProduct() *list.List /** * Sets the List of product values of the ServerHeader. * * @param product - a List of Strings specifying the product values * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the List of product value strings. */ SetProduct(product *list.List) (ParseException error) }
*
- The Server header field contains information about the software used by
- the UAS to handle the request. Revealing the specific software version of
- the server might allow the server to become more vulnerable to attacks
- against software that is known to contain security holes. Implementers
- SHOULD make the Server header field a configurable option. If the Response
- is being forwarded through a proxy, the proxy application must not modify
- the ServerHeaders. Instead, it should include a ViaHeader.
- <p>
- For Example:<br>
- <code>Server: HomeServer v2</code> *
- @see ViaHeader
- @see UserAgentHeader
type StatusLine ¶
type StatusLine struct {
// contains filtered or unexported fields
}
func (*StatusLine) GetReasonPhrase ¶
func (this *StatusLine) GetReasonPhrase() string
* Get the ReasonPhrase field
- @return ReasonPhrase field
func (*StatusLine) GetSipVersion ¶
func (this *StatusLine) GetSipVersion() string
* Get the Sip Version
- @return SipVersion
func (*StatusLine) GetStatusCode ¶
func (this *StatusLine) GetStatusCode() int
* Get the Status Code
- @return StatusCode
func (*StatusLine) GetVersionMajor ¶
func (this *StatusLine) GetVersionMajor() string
*
- Get the major version number. *@return String major version number
func (*StatusLine) GetVersionMinor ¶
func (this *StatusLine) GetVersionMinor() string
*
- Get the minor version number. *@return String minor version number
func (*StatusLine) SetMatchStatusClass ¶
func (this *StatusLine) SetMatchStatusClass(flag bool)
- Set the flag on a match template. *If this Set to true, then the whole status code is matched (default
- behavior) else only the class of the response is matched.
func (*StatusLine) SetReasonPhrase ¶
func (this *StatusLine) SetReasonPhrase(reasonPhrase string)
*
- Set the reasonPhrase member
- @param reasonPhrase String to Set
func (*StatusLine) SetSipVersion ¶
func (this *StatusLine) SetSipVersion(s string)
*
- Set the sipVersion member
- @param s String to Set
func (*StatusLine) SetStatusCode ¶
func (this *StatusLine) SetStatusCode(statusCode int)
*
- Set the statusCode member
- @param statusCode int to Set
func (*StatusLine) String ¶
func (this *StatusLine) String() string
*
- Encode into a canonical form.
- @return String
type Subject ¶
type Subject struct { SIPHeader // contains filtered or unexported fields }
* *Supported SIP Header.
func (*Subject) GetSubject ¶
func (*Subject) SetSubject ¶
type SubjectHeader ¶
type SubscriptionState ¶
type SubscriptionState struct { Parameters // contains filtered or unexported fields }
* *SubscriptionState header
func NewSubscriptionState ¶
func NewSubscriptionState() *SubscriptionState
* Creates a new instance of SubscriptionState
func (*SubscriptionState) EncodeBody ¶
func (this *SubscriptionState) EncodeBody() string
* Just the encoded body of the header.
- @return the string encoded header body.
func (*SubscriptionState) GetExpires ¶
func (this *SubscriptionState) GetExpires() int
*
- Gets the expires value of the SubscriptionStateHeader. This expires value is
- relative time. *
- @return the expires value of the SubscriptionStateHeader.
func (*SubscriptionState) GetReasonCode ¶
func (this *SubscriptionState) GetReasonCode() string
*
- Gets the reason code of SubscriptionStateHeader. *
- @return the comment of this SubscriptionStateHeader, return null if no reason code
- is available.
func (*SubscriptionState) GetRetryAfter ¶
func (this *SubscriptionState) GetRetryAfter() int
*
- Gets the retry after value of the SubscriptionStateHeader. This retry after
- value is relative time. *
- @return the retry after value of the SubscriptionStateHeader.
func (*SubscriptionState) GetState ¶
func (this *SubscriptionState) GetState() string
*
- Gets the state of SubscriptionStateHeader. *
- @return the state of this SubscriptionStateHeader.
func (*SubscriptionState) SetExpires ¶
func (this *SubscriptionState) SetExpires(expires int) (InvalidArgumentException error)
*
- Sets the relative expires value of the SubscriptionStateHeader. The
- expires value MUST be greater than zero and MUST be less than 2**31. *
- @param expires - the new expires value of this SubscriptionStateHeader.
- @throws InvalidArgumentException if supplied value is less than zero.
func (*SubscriptionState) SetReasonCode ¶
func (this *SubscriptionState) SetReasonCode(reasonCode string) (ParseException error)
*
- Sets the reason code value of the SubscriptionStateHeader. *
- @param reasonCode - the new reason code string value of the SubscriptionStateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the reason code.
func (*SubscriptionState) SetRetryAfter ¶
func (this *SubscriptionState) SetRetryAfter(retryAfter int) (InvalidArgumentException error)
*
- Sets the retry after value of the SubscriptionStateHeader. The retry after value
- MUST be greater than zero and MUST be less than 2**31. *
- @param retryAfter - the new retry after value of this SubscriptionStateHeader
- @throws InvalidArgumentException if supplied value is less than zero.
func (*SubscriptionState) SetState ¶
func (this *SubscriptionState) SetState(state string) (ParseException error)
*
- Sets the state value of the SubscriptionStateHeader. *
- @param state - the new state string value of the SubscriptionStateHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the state.
func (*SubscriptionState) String ¶
func (this *SubscriptionState) String() string
type SubscriptionStateHeader ¶
type SubscriptionStateHeader interface { ParametersHeader /** * Sets the relative expires value of the SubscriptionStateHeader. The * expires value MUST be greater than zero and MUST be less than 2**31. * * @param expires - the new expires value of this SubscriptionStateHeader. * @throws InvalidArgumentException if supplied value is less than zero. */ SetExpires(expires int) (InvalidArgumentException error) /** * Gets the expires value of the SubscriptionStateHeader. This expires value is * relative time. * * @return the expires value of the SubscriptionStateHeader. */ GetExpires() int /** * Sets the retry after value of the SubscriptionStateHeader. The retry after value * MUST be greater than zero and MUST be less than 2**31. * * @param retryAfter - the new retry after value of this SubscriptionStateHeader * @throws InvalidArgumentException if supplied value is less than zero. */ SetRetryAfter(retryAfter int) (InvalidArgumentException error) /** * Gets the retry after value of the SubscriptionStateHeader. This retry after * value is relative time. * * @return the retry after value of the SubscriptionStateHeader. */ GetRetryAfter() int /** * Gets the reason code of SubscriptionStateHeader. * * @return the comment of this SubscriptionStateHeader, return null if no reason code * is available. */ GetReasonCode() string /** * Sets the reason code value of the SubscriptionStateHeader. * * @param reasonCode - the new reason code string value of the SubscriptionStateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the reason code. */ SetReasonCode(reasonCode string) (ParseException error) /** * Gets the state of SubscriptionStateHeader. * * @return the state of this SubscriptionStateHeader. */ GetState() string /** * Sets the state value of the SubscriptionStateHeader. * * @param state - the new state string value of the SubscriptionStateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the state. */ SetState(state string) (ParseException error) }
type Supported ¶
type Supported struct { SIPHeader // contains filtered or unexported fields }
* *Supported SIP Header.
func (*Supported) EncodeBody ¶
* Just the encoded body of the header. *@return the string encoded header body.
func (*Supported) GetOptionTag ¶
*
- Gets the option tag of this OptionTag class. *
- @return the string that identifies the option tag value.
func (*Supported) SetOptionTag ¶
*
- Sets the option tag value to the new supplied <var>optionTag</var>
- parameter. *
- @param optionTag - the new string value of the option tag.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the optionTag value.
type SupportedHeader ¶
type SupportedList ¶
type SupportedList struct {
SIPHeaderList
}
type TimeStamp ¶
type TimeStamp struct { SIPHeader // contains filtered or unexported fields }
func (*TimeStamp) GetDelay ¶
*
- Gets delay of TimeStampHeader. This method return <code>-1</code> if the
- delay paramater is not set. *
- @return the delay value of this TimeStampHeader
func (*TimeStamp) GetTimeStamp ¶
*
- Gets the timestamp value of this TimeStampHeader. *
- @return the timestamp value of this TimeStampHeader
func (*TimeStamp) SetTimeStamp ¶
*
- Sets the timestamp value of this TimeStampHeader to the new timestamp
- value passed to this method. *
- @param timestamp - the new float timestamp value
- @throws InvalidArgumentException if the timestamp value argument is a
- negative value.
type TimeStampHeader ¶
type TimeStampHeader interface { Header /** * Sets the timestamp value of this TimeStampHeader to the new timestamp * value passed to this method. * * @param timestamp - the new float timestamp value * @throws InvalidArgumentException if the timestamp value argument is a * negative value. */ SetTimeStamp(timeStamp float32) (InvalidArgumentException error) /** * Gets the timestamp value of this TimeStampHeader. * * @return the timestamp value of this TimeStampHeader */ GetTimeStamp() float32 GetDelay() float32 SetDelay(delay float32) (InvalidArgumentException error) }
type To ¶
type To struct {
AddressParameters
}
* *To SIP Header.
func (*To) GetHostPort ¶
*
- Conveniance accessor function to get the hostPort field from the address.
- Warning -- this assumes that the embedded URI is a SipURL. *
- @return hostport field
func (*To) GetUserAtHostPort ¶
* Get the user@host port string.
type ToHeader ¶
type ToHeader interface { AddressHeader ParametersHeader /** * Sets the tag parameter of the ToHeader. The tag in the To field of a * request identifies the peer of the dialog. If no dialog is established, * no tag is present. * <p> * The To Header MUST contain a new "tag" parameter. When acting as a UAC * the To "tag" is maintained by the SipProvider from the dialog layer, * however whan acting as a UAS the To "tag" is assigned by the application. * That is the tag assignment for outbound responses for messages in a * dialog is only the responsibility of the application for the first * outbound response. After dialog establishment, the stack will take care * of the tag assignment. * * @param tag - the new tag of the To Header * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Tag value. */ SetTag(tag string) (ParseException error) /** * Gets tag of ToHeader. The Tag parameter identified the Peer of the * dialogue. * * @return the tag parameter of the ToHeader. Returns null if no Tag is * present, i.e no dialogue is established. */ GetTag() string }
*
- The To header field first and foremost specifies the desired "logical"
- recipient of the request, or the address-of-record of the user or resource
- that is the target of this request. This may or may not be the ultimate
- recipient of the request. Requests and Responses must contain a ToHeader,
- indicating the desired recipient of the Request. The UAS or redirect server
- copies the ToHeader into its Response.
- <p>
- The To header field MAY contain a SIP or SIPS URI, but it may also make use
- of other URI schemes i.e the telURL, when appropriate. All SIP
- implementations MUST support the SIP URI scheme. Any implementation that
- supports TLS MUST support the SIPS URI scheme. Like the From header field,
- it contains a URI and optionally a display name, encapsulated in a
- {@link javax.sip.address.Address}.
- <p>
- A UAC may learn how to populate the To header field for a particular request
- in a number of ways. Usually the user will suggest the To header field
- through a human interface, perhaps inputting the URI manually or selecting
- it from some sort of address book. Using the string to form the user part
- of a SIP URI implies that the User Agent wishes the name to be resolved in the
- domain to the right-hand side (RHS) of the at-sign in the SIP URI. Using
- the string to form the user part of a SIPS URI implies that the User Agent wishes to
- communicate securely, and that the name is to be resolved in the domain to
- the RHS of the at-sign. The RHS will frequently be the home domain of the
- requestor, which allows for the home domain to process the outgoing request.
- This is useful for features like "speed dial" that require interpretation of
- the user part in the home domain.
- <p>
- The telURL may be used when the User Agent does not wish to specify the domain that
- should interpret a telephone number that has been input by the user. Rather,
- each domain through which the request passes would be given that opportunity.
- As an example, a user in an airport might log in and send requests through
- an outbound proxy in the airport. If they enter "411" (this is the phone
- number for local directory assistance in the United States), that needs to
- be interpreted and processed by the outbound proxy in the airport, not the
- user's home domain. In this case, tel:411 would be the right choice.
- <p>
- Two To header fields are equivalent if their URIs match, and their
- parameters match. Extension parameters in one header field, not present in
- the other are ignored for the purposes of comparison. This means that the
- display name and presence or absence of angle brackets do not affect
- matching.
- <ul>
- <li> The "Tag" parameter - is used in the To and From header fields of SIP
- messages. It serves as a general mechanism to identify a dialog, which is
- the combination of the Call-ID along with two tags, one from each
- participant in the dialog. When a UA sends a request outside of a dialog,
- it contains a From tag only, providing "half" of the dialog ID. The dialog
- is completed from the response(s), each of which contributes the second half
- in the To header field. When a tag is generated by a UA for insertion into
- a request or response, it MUST be globally unique and cryptographically
- random with at least 32 bits of randomness. Besides the requirement for
- global uniqueness, the algorithm for generating a tag is implementation
- specific. Tags are helpful in fault tolerant systems, where a dialog is to
- be recovered on an alternate server after a failure. A UAS can select the
- tag in such a way that a backup can recognize a request as part of a dialog
- on the failed server, and therefore determine that it should attempt to
- recover the dialog and any other state associated with it.
- </ul>
- A request outside of a dialog MUST NOT contain a To tag; the tag in the To
- field of a request identifies the peer of the dialog. Since no dialog is
- established, no tag is present.
- <p>
- For Example:<br>
- <code>To: Carol sip:carol@jcp.org<br>
- To: Duke sip:duke@jcp.org;tag=287447</code> *
- @see AddressHeader
type Unsupported ¶
type Unsupported struct { SIPHeader // contains filtered or unexported fields }
* * the Unsupported header.
func NewUnsupportedFromString ¶
func NewUnsupportedFromString(ot string) *Unsupported
* Constructor
- @param ot String to set
func (*Unsupported) EncodeBody ¶
func (this *Unsupported) EncodeBody() string
*
- Return a canonical value.
- @return String.
func (*Unsupported) GetOptionTag ¶
func (this *Unsupported) GetOptionTag() string
* get the option tag field
- @return option Tag field
func (*Unsupported) SetOptionTag ¶
func (this *Unsupported) SetOptionTag(o string) (ParseException error)
*
- Set the option member
- @param o String to set
func (*Unsupported) String ¶
func (this *Unsupported) String() string
type UnsupportedHeader ¶
type UnsupportedList ¶
type UnsupportedList struct {
SIPHeaderList
}
* * List of Unsupported headers.
type UserAgent ¶
type UserAgent struct { SIPHeader // contains filtered or unexported fields }
* * the UserAgent SIPObject.
func (*UserAgent) EncodeBody ¶
* Encode only the body of this header. *@return encoded value of the header.
func (*UserAgent) GetProduct ¶
*
- Returns the list value of the product parameter. *
- @return the software of this UserAgentHeader
func (*UserAgent) SetProduct ¶
*
- Sets the product value of the UserAgentHeader. *
- @param product - a List specifying the product value
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the product value.
type UserAgentHeader ¶
type UserAgentHeader interface { Header /** * Returns the List of product values. * * @return the List of strings identifying the software of this ServerHeader */ GetProduct() *list.List /** * Sets the List of product values of the ServerHeader. * * @param product - a List of Strings specifying the product values * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the List of product value strings. */ SetProduct(product *list.List) (ParseException error) }
*
- The User-Agent header field contains information about the UAC originating
- the request. This is for statistical purposes, the tracing of protocol
- violations, and automated recognition of user agents for the sake of
- tailoring Responses to avoid particular user agent limitations. However
- revealing the specific software version of the user agent might allow the
- user agent to become more vulnerable to attacks against software that is
- known to contain security holes. Implementers SHOULD make the User-Agent
- header field a configurable option.
- <p>
- For Example:<br>
- <code>User-Agent: Softphone Beta1.5</code> *
- @see ServerHeader
- @see ViaHeader
type Via ¶
type Via struct { Parameters // contains filtered or unexported fields }
func (*Via) EncodeBody ¶
* Encode the body of this header (the stuff that follows headerName).
- A.K.A headerValue.
func (*Via) GetBranch ¶
*
- Gets the branch paramater of the ViaHeader. Returns null if branch
- does not exist. *
- @return the string branch value of ViaHeader
func (*Via) GetHost ¶
*
- Returns the host part of this ViaHeader. *
- @return the string value of the host
func (*Via) GetMAddr ¶
*
- Returns the value of the <code>maddr</code> parameter, or null if this
- is not set. *
- @return the string value of the maddr parameter
func (*Via) GetPort ¶
*
- Returns the port part of this ViaHeader. *
- @return the integer value of the port
func (*Via) GetProtocol ¶
*
- Returns the value of the protocol used. *
- @return the string value of the protocol paramter of the ViaHeader
func (*Via) GetReceived ¶
*
- Gets the received paramater of the ViaHeader. Returns null if received
- does not exist. *
- @return the string received value of ViaHeader
func (*Via) GetTTL ¶
*
- Returns the value of the ttl parameter, or -1 if this is not set. *
- @return the integer value of the <code>ttl</code> parameter
func (*Via) GetTransport ¶
*
- Returns the value of the transport parameter. *
- @return the string value of the transport paramter of the ViaHeader
func (*Via) GetViaParms ¶
func (this *Via) GetViaParms() *core.NameValueList
*
- Accessor for the parameters field
- @return parameters field
func (*Via) HasComment ¶
- comment of the Via Header. *
- @return false if comment does not exist and true otherwise.
func (*Via) SetBranch ¶
*
- Sets the branch parameter of the ViaHeader to the newly supplied
- branch value. *
- @param branch - the new string branch parmameter of the ViaHeader.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the branch value.
func (*Via) SetHostFromString ¶
*
- Set the host part of this ViaHeader to the newly supplied <code>host</code>
- parameter. *
- @return host - the new interger value of the host of this ViaHeader
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the host value.
func (*Via) SetMAddr ¶
*
- Sets the value of the <code>maddr</code> parameter of this ViaHeader. The
- maddr parameter indicates the server address to be contacted for this
- user, overriding any address derived from the host field. *
- @param method - new value of the <code>maddr</code> parameter
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the mAddr value.
func (*Via) SetPort ¶
*
- Set the port part of this ViaHeader to the newly supplied <code>port</code>
- parameter. *
- @param port - the new interger value of the port of this ViaHeader
func (*Via) SetProtocol ¶
*
- Sets the value of the protocol parameter. This parameter specifies
- which protocol is used, for example "SIP/2.0". *
- @param protocol - new value for the protocol parameter
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the protocol value.
func (*Via) SetReceived ¶
*
- Sets the received parameter of ViaHeader. *
- @param received - the newly supplied received parameter.
- @throws ParseException which signals that an error has been reached
- unexpectedly while parsing the received value.
func (*Via) SetTTL ¶
*
- Sets the value of the ttl parameter. The ttl parameter specifies the
- time-to-live value when packets are sent using UDP multicast. *
- @param ttl - new value of the ttl parameter
- @throws InvalidArgumentException if supplied value is less than zero or
- greater than 255, excluding -1 the default not set value.
type ViaHeader ¶
type ViaHeader interface { ParametersHeader /** * Set the host part of this ViaHeader to the newly supplied <code>host</code> * parameter. * * @return host - the new interger value of the host of this ViaHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the host value. */ SetHost(host string) (ParseException error) /** * Returns the host part of this ViaHeader. * * @return the string value of the host */ GetHost() string /** * Set the port part of this ViaHeader to the newly supplied <code>port</code> * parameter. * * @param port - the new interger value of the port of this ViaHeader */ SetPort(port int) /** * Returns the port part of this ViaHeader. * * @return the integer value of the port */ GetPort() int /** * Returns the value of the transport parameter. * * @return the string value of the transport paramter of the ViaHeader */ GetTransport() string /** * Sets the value of the transport. This parameter specifies * which transport protocol to use for sending requests and responses to * this entity. The following values are defined: "udp", "tcp", "sctp", * "tls", but other values may be used also. * * @param transport - new value for the transport parameter * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the transport value. */ SetTransport(transport string) (ParseException error) /** * Returns the value of the protocol used. * * @return the string value of the protocol paramter of the ViaHeader */ GetProtocol() string /** * Sets the value of the protocol parameter. This parameter specifies * which protocol is used, for example "SIP/2.0". * * @param protocol - new value for the protocol parameter * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the protocol value. */ SetProtocol(protocol string) (ParseException error) /** * Returns the value of the ttl parameter, or -1 if this is not set. * * @return the integer value of the <code>ttl</code> parameter */ GetTTL() int /** * Sets the value of the ttl parameter. The ttl parameter specifies the * time-to-live value when packets are sent using UDP multicast. * * @param ttl - new value of the ttl parameter * @throws InvalidArgumentException if supplied value is less than zero or * greater than 255, excluding -1 the default not set value. */ SetTTL(ttl int) (InvalidArgumentException error) /** * Returns the value of the <code>maddr</code> parameter, or null if this * is not set. * * @return the string value of the maddr parameter */ GetMAddr() string /** * Sets the value of the <code>maddr</code> parameter of this ViaHeader. The * maddr parameter indicates the server address to be contacted for this * user, overriding any address derived from the host field. * * @param method - new value of the <code>maddr</code> parameter * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the mAddr value. */ SetMAddr(mAddr string) (ParseException string) /** * Gets the received paramater of the ViaHeader. Returns null if received * does not exist. * * @return the string received value of ViaHeader */ GetReceived() string /** * Sets the received parameter of ViaHeader. * * @param received - the newly supplied received parameter. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the received value. */ SetReceived(received string) (ParseException error) /** * Gets the branch paramater of the ViaHeader. Returns null if branch * does not exist. * * @return the string branch value of ViaHeader */ GetBranch() string /** * Sets the branch parameter of the ViaHeader to the newly supplied * branch value. Note that when sending a Request within a transaction, * branch id management will be the responsibility of the SipProvider; * that is the application should not set this value. This method should * only be used by the application when sending Requests outside of a * transaction. * * @param branch - the new string branch parmameter of the ViaHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the branch value. */ SetBranch(branch string) (ParseException error) }
*
- The Via header field indicates the transport used for the transaction and
- identifies the location where the response is to be sent. A Via header
- field value is added only after the transport that will be used to reach
- the next hop has been selected. When the UAC creates a request, it MUST
- insert a Via into that request. The protocol name and protocol version in
- the header field MUST be SIP and 2.0, respectively. The Via header field
- value MUST contain a branch parameter. This parameter is used to identify
- the transaction created by that request. This parameter is used by both the
- client and the server.
- <p>
- <b>Branch Paramater:<br></b>
- The branch parameter value MUST be unique across space and time for all
- requests sent by the User Agent. The exceptions to this rule are CANCEL and ACK for
- non-2xx responses. A CANCEL request will have the same value of the branch
- parameter as the request it cancels. An ACK for a non-2xx response will also
- have the same branch ID as the INVITE whose response it acknowledges.
- <p>
- The uniqueness property of the branch ID parameter, to facilitate its use as
- a transaction ID, was not part of RFC 2543. The branch ID inserted by an
- element compliant with this specification MUST always begin with the
- characters "z9hG4bK". These 7 characters are used as a magic cookie (7 is
- deemed sufficient to ensure that an older RFC 2543 implementation would not
- pick such a value), so that servers receiving the request can determine that
- the branch ID was constructed in the fashion described by this specification
- (that is, globally unique). Beyond this requirement, the precise format of
- the branch token is implementation-defined. JAIN SIP defines a convenience
- function to generate unique branch idenifiers at
- {@link javax.sip.Transaction#getBranchId()}
- <p>
- A common way to create the branch value is to compute a cryptographic hash
- of the To tag, From tag, Call-ID header field, the Request-URI of the
- request received (before translation), the topmost Via header, and the
- sequence number from the CSeq header field, in addition to any Proxy-Require
- and Proxy-Authorization header fields that may be present. The algorithm
- used to compute the hash is implementation-dependent.
- <p>
- <b>Via Processing Rules</b>
- <ul>
- <li>Generating Requests (UAC): The client originating the Request must insert
- into the Request a ViaHeader containing its host name or network address
- and, if not the default port number, the port number at which it wishes to
- receive Responses. (Note that this port number can differ from the UDP
- source port number of the Request.) A fully-qualified domain name is
- recommended.
- <li>Request Forwarding by Proxies: The proxy MUST insert a Via header field
- value into the copy before the existing Via header field values. This
- implies that the proxy will compute its own branch parameter, which will be
- globally unique for that branch, and contain the requisite magic cookie. Note
- that this implies that the branch parameter will be different for different
- instances of a spiraled or looped request through a proxy. If a proxy server
- receives a Request which contains its own address in a ViaHeader, it must
- respond with a 482 (Loop Detected) Response. A proxy server must not forward
- a Request to a multicast group which already appears in any of the ViaHeaders.
- This prevents a malfunctioning proxy server from causing loops. Also, it
- cannot be guaranteed that a proxy server can always detect that the address
- returned by a location service refers to a host listed in the ViaHeader list,
- as a single host may have aliases or several network interfaces.
- <li>Response processing by UAC and proxies:
- <ul>
- <li>The first ViaHeader should indicate the proxy or client processing this
- Response. If it does not, discard the Response. Otherwise, remove this
- ViaHeader.
- <li>If there is no second ViaHeader, this Response is destined for this
- client. Otherwise, the processing depends on whether the ViaHeader contains
- a maddr parameter or is a receiver-tagged field.
- <li>If the second ViaHeader contains a maddr parameter, send the Response to
- the multicast address listed there, using the port indicated in "sent-by",
- or port 5060 if none is present. The Response should be sent using the TTL
- indicated in the ttl parameter, or with a TTL of 1 if that parameter is not
- present. For robustness, Responses must be sent to the address indicated in
- the maddr parameter even if it is not a multicast address.
- <li>If the second ViaHeader does not contain a maddr parameter and is a
- receiver-tagged ViaHeader, send the Response to the address in the received
- parameter, using the port indicated in the port value, or using port 5060
- if none is present.
- <li>If neither of the previous cases apply, send the Response to the address
- indicated by the host value in the second ViaHeader.
- </ul>
- <li>Sending Responses (UAS):
- <ul>
- <li>If the first ViaHeader in the Request contains a maddr parameter, send
- the Response to the multicast address listed there, using the port indicated,
- or port 5060 if none is present. The Response should be sent using the TTL
- indicated in the ttl parameter, or with a TTL of 1 if that parameter is not
- present. For robustness, Responses must be sent to the address indicated in
- the maddr parameter even if it is not a multicast address.
- <li>If the address in the first ViaHeader differs from the source address of
- the packet, send the Response to the actual packet source address, similar
- to the treatment for receiver-tagged ViaHeaders.
- <li>If neither of these conditions is true, send the Response to the address
- contained in the host value. If the Request was sent using TCP, use the
- existing TCP connection if available.
- </ul>
- </ul>
- <b>Via Parameters:</b>
- A Via header field value contains the transport protocol used to send the
- message, the client's host name or network address, and possibly the port
- number at which it wishes to receive responses. Transport protocols defined
- here are "UDP", "TCP", "TLS", and "SCTP". "TLS" means TLS over TCP. When a
- request is sent to a SIPS URI, the protocol still indicates "SIP", and the
- transport protocol is TLS. A Via header field value can also contain
- parameters such as "maddr", "ttl", "received", and "branch". A proxy sending
- a Request to a multicast address must add the maddr parameter to its
- ViaHeader, and should add the ttl parameter. If a server receives a Request
- which contained an maddr parameter in the topmost ViaHeader, it should send
- the Response to the multicast address listed in the maddr parameter. The
- received parameter is added only for receiver-added ViaHeaders.
- <p>
- Two Via header fields are equal if their sent-protocol and sent-by fields
- are equal, both have the same set of parameters, and the values of all
- parameters are equal.
type ViaList ¶
type ViaList struct { SIPHeaderList // contains filtered or unexported fields }
* * Keeps a list and a hashtable of via header functions.
type WWWAuthenticate ¶
type WWWAuthenticate struct {
Authentication
}
type WWWAuthenticateHeader ¶
type WWWAuthenticateHeader interface { ParametersHeader /** * Sets the scheme of the challenge information for this WWWAuthenticateHeader. * For example, Digest. * * @param scheme - the new string value that identifies the challenge * information scheme. * */ SetScheme(scheme string) /** * Returns the scheme of the challenge information for this WWWAuthenticateHeader. * * @return the string value of the challenge information. * */ GetScheme() string /** * Sets the Realm of the WWWAuthenicateHeader to the realm * parameter value. Realm strings MUST be globally unique. It is * RECOMMENDED that a realm string contain a hostname or domain name. * Realm strings SHOULD present a human-readable identifier that can be * rendered to a user. * * @param realm the new Realm string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the realm. * */ SetRealm(realm string) (ParseException error) /** * Returns the Realm value of this WWWAuthenicateHeader. This convenience * method returns only the realm of the complete Challenge. * * @return the string representing the Realm information, null if value is * not Set. * */ GetRealm() string /** * Sets the Nonce of the WWWAuthenicateHeader to the nonce * parameter value. * * @param nonce - the new nonce string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the nonce value. * */ SetNonce(nonce string) (ParseException error) /** * Returns the Nonce value of this WWWAuthenicateHeader. * * @return the string representing the nonce information, null if value is * not Set. * */ GetNonce() string /** * Sets the URI of the WWWAuthenicateHeader to the uri * parameter value. * * @param uri - the new URI of this WWWAuthenicateHeader. * */ SetURI(uri address.URI) /** * Returns the URI value of this WWWAuthenicateHeader, for example DigestURI. * * @return the URI representing the URI information, null if value is * not Set. * */ GetURI() address.URI /** * Sets the Algorithm of the WWWAuthenicateHeader to the new * algorithm parameter value. * * @param algorithm - the new algorithm string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the algorithm value. * */ SetAlgorithm(algorithm string) (ParseException error) /** * Returns the Algorithm value of this WWWAuthenicateHeader. * * @return the string representing the Algorithm information, null if the * value is not Set. * */ GetAlgorithm() string /** * Sets the Qop value of the WWWAuthenicateHeader to the new * qop parameter value. * * @param qop - the new Qop string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the Qop value. * */ SetQop(qop string) (ParseException error) /** * Returns the Qop value of this WWWAuthenicateHeader. * * @return the string representing the Qop information, null if the * value is not Set. * */ GetQop() string /** * Sets the Opaque value of the WWWAuthenicateHeader to the new * opaque parameter value. * * @param opaque - the new Opaque string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the opaque value. * */ SetOpaque(opaque string) (ParseException error) /** * Returns the Opaque value of this WWWAuthenicateHeader. * * @return the string representing the Opaque information, null if the * value is not Set. * */ GetOpaque() string /** * Sets the Domain of the WWWAuthenicateHeader to the domain * parameter value. * * @param domain - the new Domain string of this WWWAuthenicateHeader. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the domain. * */ SetDomain(domain string) (ParseException error) /** * Returns the Domain value of this WWWAuthenicateHeader. * * @return the string representing the Domain information, null if value is * not Set. * */ GetDomain() string /** * Sets the value of the stale parameter of the WWWAuthenicateHeader to the * stale parameter value. * * @param stale - the new boolean value of the stale parameter. * */ SetStale(stale bool) /** * Returns the boolean value of the state paramater of this * WWWAuthenicateHeader. * * @return the boolean representing if the challenge is stale. * */ IsStale() bool }
type WWWAuthenticateList ¶
type WWWAuthenticateList struct {
SIPHeaderList
}
* * WWWAuthenticate SIPHeader (of which there can be several?)
type Warning ¶
type Warning struct { SIPHeader // contains filtered or unexported fields }
func (*Warning) EncodeBody ¶
- Encode the body of the header (return the stuff following name:). *@return the string encoding of the header value.
func (*Warning) SetAgent ¶
*
- Sets host of WarningHeader
- @param host String to Set
- @throws ParseException if host is not accepted by implementation
func (*Warning) SetCode ¶
*
- Sets code of WarningHeader
- @param code int to Set
- @throws SipParseException if code is not accepted by implementation
type WarningHeader ¶
type WarningHeader interface { Header /** * Gets the agent of the server that created this WarningHeader. * * @return the agent of the WarningHeader */ GetAgent() string /** * Sets the agent value of the WarningHeader to the new value passed to the * method. * * @param agent - the new agent value of WarningHeader * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the agent value. */ SetAgent(agent string) (ParseException error) /** * Gets text of WarningHeader. * * @return the string text value of the WarningHeader. */ GetText() string /** * Sets the text of WarningHeader to the newly supplied text value. * * @param text - the new text value of the Warning Header. * @throws ParseException which signals that an error has been reached * unexpectedly while parsing the text value. */ SetText(text string) (ParseException error) /** * Sets the code of the WarningHeader. The standard RFC3261 codes are * defined as constants in this class. * * @param code - the new code that defines the warning code. * @throws InvalidArgumentException if an invalid integer code is given for * the WarningHeader. */ SetCode(code int) (InvalidArgumentException error) /** * Gets the code of the WarningHeader. * * @return the integer code value of the WarningHeader */ GetCode() int }
type WarningList ¶
type WarningList struct {
SIPHeaderList
}
* * A Warning SIPObject. (A list of Warning headers).
Source Files
¶
- AcceptEncodingHeader.go
- AcceptEncodingImpl.go
- AcceptEncodingList.go
- AcceptHeader.go
- AcceptImpl.go
- AcceptLanguageHeader.go
- AcceptLanguageImpl.go
- AcceptLanguageList.go
- AcceptList.go
- AddressHeader.go
- AddressParametersHeader.go
- AddressParametersImpl.go
- AlertInfoHeader.go
- AlertInfoImpl.go
- AlertInfoList.go
- AllowEventsHeader.go
- AllowEventsImpl.go
- AllowEventsList.go
- AllowHeader.go
- AllowImpl.go
- AllowList.go
- AuthenticationHeader.go
- AuthenticationImpl.go
- AuthenticationInfoHeader.go
- AuthenticationInfoImpl.go
- AuthorizationHeader.go
- AuthorizationImpl.go
- CSeqHeader.go
- CSeqImpl.go
- CallIdHeader.go
- CallIdImpl.go
- CallIdentifier.go
- CallInfoHeader.go
- CallInfoImpl.go
- CallInfoList.go
- Challenge.go
- ContactHeader.go
- ContactImpl.go
- ContactListImpl.go
- ContentDispositionHeader.go
- ContentDispositionImpl.go
- ContentEncodingHeader.go
- ContentEncodingImpl.go
- ContentEncodingList.go
- ContentLanguageHeader.go
- ContentLanguageImpl.go
- ContentLanguageList.go
- ContentLengthHeader.go
- ContentLengthImpl.go
- ContentTypeHeader.go
- ContentTypeImpl.go
- DateHeader.go
- DateImpl.go
- Encoding.go
- ErrorInfoHeader.go
- ErrorInfoImpl.go
- ErrorInfoList.go
- EventHeader.go
- EventImpl.go
- ExpiresHeader.go
- ExpiresImpl.go
- ExtensionHeader.go
- ExtensionImpl.go
- ExtensionList.go
- FromHeader.go
- FromImpl.go
- InReplyToHeader.go
- InReplyToImpl.go
- InReplyToList.go
- MaxForwardsHeader.go
- MaxForwardsImpl.go
- MediaRange.go
- MediaType.go
- MimeVersionHeader.go
- MimeVersionImpl.go
- MinExpiresHeader.go
- MinExpiresImpl.go
- OptionTag.go
- OrganizationHeader.go
- OrganizationImpl.go
- ParametersHeader.go
- ParametersImpl.go
- PriorityHeader.go
- PriorityImpl.go
- Protocol.go
- ProxyAuthenticateHeader.go
- ProxyAuthenticateImpl.go
- ProxyAuthenticateList.go
- ProxyAuthorizationHeader.go
- ProxyAuthorizationImpl.go
- ProxyRequireHeader.go
- ProxyRequireImpl.go
- ProxyRequireList.go
- QValue.go
- RAckHeader.go
- RAckImpl.go
- RSeqHeader.go
- RSeqImpl.go
- ReasonHeader.go
- ReasonImpl.go
- ReasonList.go
- RecordRouteHeader.go
- RecordRouteImpl.go
- RecordRouteList.go
- ReferToHeader.go
- ReferToImpl.go
- ReplyToHeader.go
- ReplyToImpl.go
- RequestLine.go
- RequireHeader.go
- RequireImpl.go
- RequireList.go
- RetryAfterHeader.go
- RetryAfterImpl.go
- RouteHeader.go
- RouteImpl.go
- RouteList.go
- SIPHeaderHeader.go
- SIPHeaderImpl.go
- SIPHeaderList.go
- ServerHeader.go
- ServerImpl.go
- StatusLine.go
- SubjectHeader.go
- SubjectImpl.go
- SubscriptionStateHeader.go
- SubscriptionStateImpl.go
- SupportedHeader.go
- SupportedImpl.go
- SupportedList.go
- TimeStampHeader.go
- TimeStampImpl.go
- ToHeader.go
- ToImpl.go
- UnsupportedHeader.go
- UnsupportedImpl.go
- UnsupportedList.go
- UserAgentHeader.go
- UserAgentImpl.go
- ViaHeader.go
- ViaImpl.go
- ViaList.go
- WWWAuthenticateHeader.go
- WWWAuthenticateImpl.go
- WWWAuthenticateList.go
- WarningHeader.go
- WarningImpl.go
- WarningList.go