assessmentsession

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 1, 2019 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrorResponseIdentNotFound       = errors.New("ResponseDeclaration Identifier Not Found")
	ErrorResponseIfNotFound          = errors.New("Required responseIf not found")
	ErrorUnexpectedNode              = errors.New("Unexpected Node")
	ErrorUnknownResponseVariable     = errors.New("Unknown Response Variable")
	ErrorIncompatibleBaseType        = errors.New("Incompatible BaseType")
	ErrorBaseTypeMisMatch            = errors.New("BaseType Mismatch")
	ErrorUnsupportedFeature          = errors.New("Unsupported Feature")
	ErrorUnknownVariable             = errors.New("Not Found")
	ErrorMissingValue                = errors.New("Missing Value")
	ErrorDuplicateVariableIdentifier = errors.New("Duplicate variable identifiers")
	ErrorMissingTemplate             = errors.New("QTI Template Not Defined")
	ErrorResponseProcessingMissing   = errors.New("Missing ResponseProcessing")
	ErrorOutcomeProcessingMissing    = errors.New("Missing OutcomeProcessing")
)

Functions

This section is empty.

Types

type ItemSession

type ItemSession struct {
	// contains filtered or unexported fields
}

func NewItemSession

func NewItemSession(itemxml string) (*ItemSession, error)

func NewItemSessionFromItem

func NewItemSessionFromItem(itm *assessmentitem.AssessmentItem) (*ItemSession, error)

func NewItemSessionParseFile

func NewItemSessionParseFile(filename string) (*ItemSession, error)

func (*ItemSession) ItemResult

func (is *ItemSession) ItemResult() (*asr.ItemResult, error)

func (*ItemSession) OutcomeVars

func (is *ItemSession) OutcomeVars() []*OutcomeSessionVaraible

func (*ItemSession) ProcessResponse

func (is *ItemSession) ProcessResponse(vars []*ResponseSessionVariable) error

type OutcomeSessionVaraible

type OutcomeSessionVaraible struct {
	Identifier         string
	BaseType           string
	Cardinality        string
	Interpretation     string
	LongInterpretation string
	View               string
	NormalMaximum      float64
	NormalMinium       float64
	MasteryValue       float64
	DefaultValue       *qti.DefaultValue
	Value              []qti.Value
}

func (*OutcomeSessionVaraible) AddValue

func (ov *OutcomeSessionVaraible) AddValue(val qti.Value)

func (*OutcomeSessionVaraible) Equal

func (ov *OutcomeSessionVaraible) Equal(v Variable) bool

func (*OutcomeSessionVaraible) GetBaseType

func (ov *OutcomeSessionVaraible) GetBaseType() string

func (*OutcomeSessionVaraible) GetCardinality

func (ov *OutcomeSessionVaraible) GetCardinality() string

func (*OutcomeSessionVaraible) GetIdentifier

func (ov *OutcomeSessionVaraible) GetIdentifier() string

func (*OutcomeSessionVaraible) GetValue

func (ov *OutcomeSessionVaraible) GetValue() []qti.Value

func (*OutcomeSessionVaraible) SetIdentifier

func (ov *OutcomeSessionVaraible) SetIdentifier(id string)

func (*OutcomeSessionVaraible) SetValue

func (ov *OutcomeSessionVaraible) SetValue(vals []qti.Value)

type ResponseSessionVariable

type ResponseSessionVariable struct {
	Identifier   string            `xml:"identifier,attr" json:"identifier"`
	BaseType     string            `xml:"baseType,attr" json:"baseType"`
	Cardinality  string            `xml:"cardinality,attr" json:"cardinality"`
	DefaultValue *qti.DefaultValue `xml:"defaultValue,attr" json:"defaultValue"`
	Value        []qti.Value       `xml:"value" json:"values"`
}

func (*ResponseSessionVariable) AddValue

func (rv *ResponseSessionVariable) AddValue(val qti.Value)

func (*ResponseSessionVariable) Equal

func (rv *ResponseSessionVariable) Equal(v Variable) bool

func (*ResponseSessionVariable) GetBaseType

func (rv *ResponseSessionVariable) GetBaseType() string

func (*ResponseSessionVariable) GetCardinality

func (rv *ResponseSessionVariable) GetCardinality() string

func (*ResponseSessionVariable) GetIdentifier

func (rv *ResponseSessionVariable) GetIdentifier() string

func (*ResponseSessionVariable) GetValue

func (rv *ResponseSessionVariable) GetValue() []qti.Value

func (*ResponseSessionVariable) SetIdentifier

func (rv *ResponseSessionVariable) SetIdentifier(id string)

func (*ResponseSessionVariable) SetValue

func (rv *ResponseSessionVariable) SetValue(vals []qti.Value)

type TestSession

type TestSession struct {
	Test *ast.AssessmentTest

	Items []*asi.AssessmentItem
	// contains filtered or unexported fields
}

func NewTestSession

func NewTestSession(test *ast.AssessmentTest) (*TestSession, error)

func (*TestSession) ProcessOutcome

func (is *TestSession) ProcessOutcome(itemresults map[string]*asr.ItemResult) error

func (*TestSession) TestResult

func (ts *TestSession) TestResult() *asr.TestResult

type Variable

type Variable interface {
	GetIdentifier() string
	SetIdentifier(string)
	GetBaseType() string
	GetCardinality() string
	GetValue() []qti.Value
	SetValue([]qti.Value)
	AddValue(value qti.Value)
	Equal(v Variable) bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL