C# Class Universe.Modules.VivoxVoiceService

Inheritance: IVoiceService, IService
Exibir arquivo Open project: Virtual-Universe/Virtual-Universe

Public Properties

Property Type Description
CHAN_MODE_AUDITORIUM string
CHAN_MODE_DEFAULT string
CHAN_MODE_LECTURE string
CHAN_MODE_OPEN string
CHAN_MODE_PRESENTATION string
CHAN_TYPE_CHANNEL string
CHAN_TYPE_DEFAULT string
CHAN_TYPE_POSITIONAL string

Protected Properties

Property Type Description
m_registry IRegistryCore

Public Methods

Method Description
FinishedStartup ( ) : void
GetParcelChannelInfo ( UUID avatarID, Framework region, string URL, bool &success, UUID &parcelID, string &parcelName, int &localID, uint &parcelFlags, string &ParentID ) : void
GroupConferenceCallRequest ( IRegionClientCapsService caps, UUID sessionid ) : OSDMap
Initialize ( IConfigSource config, IRegistryCore registry ) : void
ParcelVoiceRequest ( IRegionClientCapsService regionClient, string &channel_uri, int &localID ) : void
Start ( IConfigSource config, IRegistryCore registry ) : void
VoiceAccountRequest ( IRegionClientCapsService regionClient, string &agentname, string &password, string &vivoxSipUri, string &vivoxVoiceAccountApi ) : void
XmlScanl ( XmlElement e, int index ) : void

The XmlScan routine is provided to aid in the reverse engineering of incompletely documented packets returned by the Vivox voice server. It is only called if the m_dumpXml switch is set.

Private Methods

Method Description
DoAdminLogin ( ) : bool

Login has been factored in this way because it gets called from several places in the module, and we want it to work the same way each time.

GetParentIDForRegion ( Framework region ) : string
IsOK ( XmlElement resp ) : bool

Just say if it worked.

RegionGetOrCreateChannel ( UUID regionID, string regionName, UUID parcelID, string parcelName, int localID, uint parcelFlags, string voiceParentID ) : string
VivoxCall ( string requrl, bool admin ) : XmlElement

This method handles the WEB side of making a request over the Vivox interface. The returned values are transferred to a hash table which is returned as the result. The outcome of the call can be determined by examining the status value in the hash table.

VivoxCreateAccount ( string user, string password ) : XmlElement

Creates a new account. For now we supply the minimum set of values, which is user name and password. We *can* supply a lot more demographic data.

VivoxDeleteChannel ( string parent, string channelid ) : XmlElement
VivoxGetAccountInfo ( string user ) : XmlElement

Retrieve account information for the specified user. Returns a hash table containing values returned from the request.

VivoxListChildren ( string channelid ) : XmlElement
VivoxLogin ( string name, string password ) : XmlElement

Perform administrative login for Vivox. Returns a hash table containing values returned from the request.

VivoxLogout ( ) : XmlElement

Perform administrative logout for Vivox.

VivoxPassword ( string user, string password ) : XmlElement

Change the user's password.

VivoxTryCreateChannel ( string parent, string channelId, string description, string &channelUri ) : bool

Create a channel. Once again, there a multitude of options possible. In the simplest case we specify only the name and get a non-persistent cannel in return. Non persistent means that the channel gets deleted if no-one uses it for 5 hours. To accommodate future requirements, it may be a good idea to initially create channels under the umbrella of a parent ID based upon the region name. That way we have a context for side channels, if those are required in a later phase. In this case the call handles parent and description as optional values.

VivoxTryCreateDirectory ( string dirId, string description, string &channelId ) : bool

Create a directory. Create a channel with an unconditional type of "dir" (indicating directory). This is used to create an arbitrary name tree for partitioning of the channel name space. The parent and description are optional values.

VivoxTryGetChannel ( string channelParent, string channelName, string &channelId, string &channelUri ) : bool

Retrieve a channel. Once again, there a multitude of options possible. In the simplest case we specify only the name and get a non-persistent cannel in return. Non persistent means that the channel gets deleted if no-one uses it for 5 hours. To accommodate future requirements, it may be a good idea to initially create channels under the umbrella of a parent ID based upon the region name. That way we have a context for side channels, if those are required in a later phase. In this case the call handles parent and description as optional values.

VivoxTryGetDirectory ( string directoryName, string &directoryId ) : bool
XmlFind ( XmlElement root, string tag, int nth, string &result ) : bool

The Find method is passed an element whose inner text is scanned in an attempt to match the name hierarchy passed in the 'tag' parameter. If the whole hierarchy is resolved, the InnerText value at that point is returned. Note that this may itself be a sub-hierarchy of the entire document. The function returns a Boolean indicator of the search's success. The search is performed by the recursive Search method.

XmlFind ( XmlElement root, string tag, string &result ) : bool
XmlSearch ( XmlElement e, string tags, int index, int &nth, string &result ) : bool

XmlSearch is initially called by XmlFind, and then recursively called by itself until the document supplied to XmlFind is either exhausted or the name hierarchy is matched. If the hierarchy is matched, the value is returned in result, and true returned as the function's value. Otherwise the result is set to the empty string and false is returned.

Method Details

FinishedStartup() public method

public FinishedStartup ( ) : void
return void

GetParcelChannelInfo() public method

public GetParcelChannelInfo ( UUID avatarID, Framework region, string URL, bool &success, UUID &parcelID, string &parcelName, int &localID, uint &parcelFlags, string &ParentID ) : void
avatarID UUID
region Framework
URL string
success bool
parcelID UUID
parcelName string
localID int
parcelFlags uint
ParentID string
return void

GroupConferenceCallRequest() public method

public GroupConferenceCallRequest ( IRegionClientCapsService caps, UUID sessionid ) : OSDMap
caps IRegionClientCapsService
sessionid UUID
return OSDMap

Initialize() public method

public Initialize ( IConfigSource config, IRegistryCore registry ) : void
config IConfigSource
registry IRegistryCore
return void

ParcelVoiceRequest() public method

public ParcelVoiceRequest ( IRegionClientCapsService regionClient, string &channel_uri, int &localID ) : void
regionClient IRegionClientCapsService
channel_uri string
localID int
return void

Start() public method

public Start ( IConfigSource config, IRegistryCore registry ) : void
config IConfigSource
registry IRegistryCore
return void

VoiceAccountRequest() public method

public VoiceAccountRequest ( IRegionClientCapsService regionClient, string &agentname, string &password, string &vivoxSipUri, string &vivoxVoiceAccountApi ) : void
regionClient IRegionClientCapsService
agentname string
password string
vivoxSipUri string
vivoxVoiceAccountApi string
return void

XmlScanl() public method

The XmlScan routine is provided to aid in the reverse engineering of incompletely documented packets returned by the Vivox voice server. It is only called if the m_dumpXml switch is set.
public XmlScanl ( XmlElement e, int index ) : void
e System.Xml.XmlElement
index int
return void

Property Details

CHAN_MODE_AUDITORIUM public_oe static_oe property

public static string CHAN_MODE_AUDITORIUM
return string

CHAN_MODE_DEFAULT public_oe static_oe property

public static string CHAN_MODE_DEFAULT
return string

CHAN_MODE_LECTURE public_oe static_oe property

public static string CHAN_MODE_LECTURE
return string

CHAN_MODE_OPEN public_oe static_oe property

public static string CHAN_MODE_OPEN
return string

CHAN_MODE_PRESENTATION public_oe static_oe property

public static string CHAN_MODE_PRESENTATION
return string

CHAN_TYPE_CHANNEL public_oe static_oe property

public static string CHAN_TYPE_CHANNEL
return string

CHAN_TYPE_DEFAULT public_oe static_oe property

public static string CHAN_TYPE_DEFAULT
return string

CHAN_TYPE_POSITIONAL public_oe static_oe property

public static string CHAN_TYPE_POSITIONAL
return string

m_registry protected_oe property

protected IRegistryCore m_registry
return IRegistryCore