state

Specifies the abstract base type of any presence state category instance value.

<st:state xmlns:st="https://schemas.microsoft.com/2006/09/sip/state" 
       manual="xs:boolean" 
       startTime="xs:dateTime" 
       majorVersion="xs:unsignedInt" 
       minorVersion="xs:unsignedInt"
       [anyAttri]="anyAttribute">
   <st:availability>xs:unsignedInt</st:availability>
   <st:activity>st:activityType</st:activity>
   <st:endpointLocation>st:endpointLocationEnumEx</st:endpointLocation>
   <st:extension>st:extensionType</st:extension>
</st:state>

stateType

Attributes and Elements

The following sections describe attributes, child elements, and parent elements.

Attributes

Attribute

Description

manual

Optional attribute to specify if the publication of this state is manual (true) or not (false). The default value is false.

startTime

Optional attribute to specify the starting time of this state publication. The default value is unspecified.

majorVersion

Optional attribute to specify schema-dependent major version information. The default value is unspecified.

minorVersion

Optional attribute to specify schema-dependent minor version information. The default value is unspecified.

[anyAttr]

Optional custom attribute of any name and namespace

Child Elements

Element

Occurrence

Description

availability

0 ore 1

Availability number indicating the presence status.

activity

0 or more

An activity string and/or token describing the presence status.

endpointLocation

0 or 1

Location of the endpoint associated with this presence state

state/extension

0 or 1

Custom extension to the presence state

Parent Elements

Element

Description

None

This is a top-level element as a presence state category instance value.

Text Value

None

Remarks

stateType is an abstract XML type and services as the base type of all of the following concrete presence state types: aggregateMachineState, aggregateState, calendarState, machineState, phoneState, userState

All the concrete presence state category instance values has an xsi:type attribute declared. The value of this attribute is the name of concrete presence state derived from stateType. For example, the userState category instance value is expressed as <state type="userState"> ...</state>

While the attributes and elements tables above list all the common features of the enhanced presence state category instance can have, the features specific to the individual concrete state types are documented in the XML elements of the following XSD types:

Concrete Presence State

Description

state[@type='aggregateMachineState']

Aggregated presence state over all the signed-in devices.

state[@type='aggregateState']

Aggregated presence state over all the presence states data of a presentity.

state[@type='calendarState']

Presence state according the user’s calendar data.

state[@type='machineState']

Presence state of individual signed-in devices.

state[@type='phoneState']

Presence state of a voice/video call.

state[@type='userState']

User-specific presence state.

Tip

Programming with the enhanced presence state involves creating XML elements of the concrete presence state types in publication and parsing them in subscription or query. These programming tasks can be facilitated by using the .NET Framework’s System.Xml.Serialization namespace. However, to serialize or de-serialize the XML elements of the concrete presence state types, you must specify their base type, stateType, as the serialization type. For more information, see Serialization of Enhanced Presence Category Instancess.

Element Information

Namespace

https://schemas.microsoft.com/2006/09/sip/state

Schema Name

state

Validation File

state.xsd, statetypes.xsd

Can be Empty

True

See Also

Other Resources

Presence State and state Category Instances