Table of Contents

Class ResponseSession

Namespace
InSite.Domain.Surveys.Sessions
Assembly
Shift.Sdk.dll

A survey response session (previously a survey submission form) is the list of answers input by a respondent on a single specific instance of a survey form.

public class ResponseSession
Inheritance
ResponseSession
Inherited Members
Extension Methods

Constructors

ResponseSession()

public ResponseSession()

Properties

Answers

The list of answers in the session.

public List<ResponseAnswer> Answers { get; set; }

Property Value

List<ResponseAnswer>

Completed

When was the session started? If a session is completed, unlocked, and recompleted at a later time, then this property stores the date/time when the session was last completed.

public DateTimeOffset? Completed { get; set; }

Property Value

DateTimeOffset?

Created

When was the session created?

public DateTimeOffset? Created { get; set; }

Property Value

DateTimeOffset?

Form

The survey form for the session.

public Guid Form { get; set; }

Property Value

Guid

Group

public Guid? Group { get; set; }

Property Value

Guid?

Identifier

Uniquely identifies the session.

public Guid Identifier { get; set; }

Property Value

Guid

IsLocked

Changes to the answers in a session are disallowed when the session is locked.

public bool IsLocked { get; set; }

Property Value

bool

Language

The language preference indicated by the respondent/user.

public string Language { get; set; }

Property Value

string

LastQuestion

The last question answered by the respondent.

public Guid? LastQuestion { get; set; }

Property Value

Guid?

Period

public Guid? Period { get; set; }

Property Value

Guid?

Source

Information about the source of this data (e.g. Authored|Uploaded|Upgraded|Copied).

public string Source { get; set; }

Property Value

string

Started

When was the session started? If a session is started, paused, and restarted at a later time, then this property stores the date/time when the session was first started.

public DateTimeOffset? Started { get; set; }

Property Value

DateTimeOffset?

Status

Created | Started | Completed

public ResponseSessionStatus Status { get; set; }

Property Value

ResponseSessionStatus

Tenant

The organization account in which the session occurs.

public Guid Tenant { get; set; }

Property Value

Guid

User

The respondent/user answering questions.

public Guid User { get; set; }

Property Value

Guid

Methods

ContainsAnswer(Guid)

public bool ContainsAnswer(Guid question)

Parameters

question Guid

Returns

bool

ContainsOption(Guid)

public bool ContainsOption(Guid option)

Parameters

option Guid

Returns

bool

FindAnswer(Guid)

public ResponseAnswer FindAnswer(Guid question)

Parameters

question Guid

Returns

ResponseAnswer

FindAnswerAndOption(Guid, out ResponseAnswer, out ResponseOption)

public bool FindAnswerAndOption(Guid optionId, out ResponseAnswer answer, out ResponseOption option)

Parameters

optionId Guid
answer ResponseAnswer
option ResponseOption

Returns

bool

FindOption(Guid)

public ResponseOption FindOption(Guid optionId)

Parameters

optionId Guid

Returns

ResponseOption

FindOptions(List<SurveyOptionItem>)

public ResponseOption[] FindOptions(List<SurveyOptionItem> items)

Parameters

items List<SurveyOptionItem>

Returns

ResponseOption[]

FlattenOptionItems()

public ResponseOption[] FlattenOptionItems()

Returns

ResponseOption[]

Initialize()

public void Initialize()