.NET SDK Documentation
Search Results for

    Show / Hide Table of Contents

    Class SessionService

    The session service is responsible for connecting the SDK with the Dolby.io backend by opening and closing sessions.

    To use the session service, follow these steps:

    1. Open a session using the OpenAsync(UserInfo) method.
    2. Join a conference using the ConferenceService.
    3. Leave the conference and close the session using the CloseAsync() method.
    Inheritance
    Object
    SessionService
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Object.ReferenceEquals(Object, Object)
    Object.ToString()
    Namespace: DolbyIO.Comms.Services
    Assembly: DolbyIO.Comms.Sdk.dll
    Syntax
    public sealed class SessionService
    Examples
    try
    {
        UserInfo user = new UserInfo();
        user.Name = "Some Name";
    
        user = await _sdk.Session.OpenAsync(user);
    }
    catch (DolbyIOException e)
    {
        // Error handling
    }

    Properties

    | Improve this Doc View Source

    IsOpen

    Gets if a session is currently open.

    Declaration
    public bool IsOpen { get; }
    Property Value
    Type Description
    Boolean

    true if a session is open; otherwise, false.

    | Improve this Doc View Source

    User

    Gets the local participant object that belongs to the current session.

    Declaration
    public UserInfo User { get; }
    Property Value
    Type Description
    UserInfo

    The UserInfo class that contains information about the participant who opened the session.

    Methods

    | Improve this Doc View Source

    CloseAsync()

    Closes the current session.

    Declaration
    public async Task CloseAsync()
    Returns
    Type Description
    Task

    A Task that represents the asynchronous operation.

    | Improve this Doc View Source

    OpenAsync(UserInfo)

    Opens a new session for the specified participant.

    Declaration
    public async Task<UserInfo> OpenAsync(UserInfo user)
    Parameters
    Type Name Description
    UserInfo user

    Information about the participant who opens the session.

    Returns
    Type Description
    Task<UserInfo>

    The Task<TResult> that represents the asynchronous open operation. The Result property returns the UserInfo object representing the participant who opened the session.

    • Improve this Doc
    • View Source
    ☀
    ☾
    In This Article
    Back to top
    Generated by DocFX
    ☀
    ☾