Show / Hide Table of Contents

Class SerializableValidationResult

A model for a validation result which is easy to serialize/deserialize to/from data formats.

Inheritance
System.Object
SerializableValidationResult
Implements
System.Runtime.Serialization.ISerializable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: CSF.Validation
Assembly: CSF.Validation.Abstractions.dll
Syntax
[Serializable]
public sealed class SerializableValidationResult : ISerializable
Remarks

Whilst this model lacks some of the functionality of a full validation result, it is easy to consume across API boundaries or mediums like JSON, XML or tables of a relational database.

This class conceptually corresponds to ValidationResult.

Constructors

| Improve this Doc View Source

SerializableValidationResult()

Initialises a new instance of SerializableValidationResult.

Declaration
public SerializableValidationResult()

Properties

| Improve this Doc View Source

RuleResults

Gets or sets an array of the individual rule results which make up the current validation result.

Declaration
public SerializableValidationRuleResult[] RuleResults { get; set; }
Property Value
Type Description
SerializableValidationRuleResult[]

Methods

| Improve this Doc View Source

IsPass()

Gets a value which indicates whether or not the current instance represents a passing validation result.

Declaration
public bool IsPass()
Returns
Type Description
System.Boolean

Explicit Interface Implementations

| Improve this Doc View Source

ISerializable.GetObjectData(SerializationInfo, StreamingContext)

Declaration
void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
Type Name Description
System.Runtime.Serialization.SerializationInfo info
System.Runtime.Serialization.StreamingContext context

Implements

System.Runtime.Serialization.ISerializable
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX