Show / Hide Table of Contents

Class Validator

Contains all JSON validation methods.

Inheritance
System.Object
Validator
Namespace: CycloneDX.Json
Assembly: CycloneDX.Core.dll
Syntax
public static class Validator : object

Methods

| Improve this Doc View Source

Validate(String)

Validate the string contents represent a valid CycloneDX JSON document.

Declaration
public static ValidationResult Validate(string jsonString)
Parameters
Type Name Description
System.String jsonString
Returns
Type Description
ValidationResult
| Improve this Doc View Source

Validate(String, SpecificationVersion)

Validate the string contents represent a valid CycloneDX JSON document.

Declaration
public static ValidationResult Validate(string jsonString, SpecificationVersion specificationVersion)
Parameters
Type Name Description
System.String jsonString
SpecificationVersion specificationVersion
Returns
Type Description
ValidationResult
| Improve this Doc View Source

ValidateAsync(Stream, SpecificationVersion)

Validate the stream contents represent a valid CycloneDX JSON document.

Declaration
public static async Task<ValidationResult> ValidateAsync(Stream jsonStream, SpecificationVersion specificationVersion)
Parameters
Type Name Description
Stream jsonStream
SpecificationVersion specificationVersion
Returns
Type Description
Task<ValidationResult>
  • Improve this Doc
  • View Source
In This Article
  • Methods
    • Validate(String)
    • Validate(String, SpecificationVersion)
    • ValidateAsync(Stream, SpecificationVersion)
Back to top Generated by DocFX