Show / Hide Table of Contents

Interface IScalarValidationErrors

Represents collection of scalar validation error(s), which is specially optimized for single item collection and immutability.

Inherited Members
System.Collections.Generic.IReadOnlyList<DevZest.Data.Presenters.ScalarValidationError>.Item[System.Int32]
System.Collections.Generic.IReadOnlyCollection<DevZest.Data.Presenters.ScalarValidationError>.Count
System.Collections.Generic.IEnumerable<DevZest.Data.Presenters.ScalarValidationError>.GetEnumerator()
Namespace: DevZest.Data.Presenters
Assembly: DevZest.Data.WPF.dll
Syntax
public interface IScalarValidationErrors : IReadOnlyList<ScalarValidationError>, IReadOnlyCollection<ScalarValidationError>, IEnumerable<ScalarValidationError>, IEnumerable
Remarks

ScalarValidationError class implements IScalarValidationErrors, so a ScalarValidationError instance can represent both the error itself and a single item collection of errors. This can improve performance by avoiding object creation.

IScalarValidationErrors can be sealed as immutable, any change to IScalarValidationErrors may or may not create a new IScalarValidationErrors instance. Consumer of IScalarValidationErrors should always assume it's immutable.

Static class ScalarValidationErrors is provided to manipulate IScalarValidationErrors.

Properties

Name Description
IsSealed

Gets a value indicates whether this collection is sealed.

Methods

Name Description
Add(ScalarValidationError)

Adds the specified error into this collection.

Seal()

Seals this collection as immutable.

Extension Methods

ScalarValidationErrors.Add(IScalarValidationErrors, IScalarValidationErrors)
  • Improve this Doc
  • View Source
Back to top Copyright © Weifen Luo | DevZest