Struct JsonSchemaLimits
- Namespace
- ShapeShift.Json
- Assembly
- ShapeShift.Json.dll
The deserializer limits that a JSON Schema projection should express.
public record struct JsonSchemaLimits : IEquatable<JsonSchemaLimits>
- Implements
- Inherited Members
Constructors
JsonSchemaLimits(int, int, int)
The deserializer limits that a JSON Schema projection should express.
public JsonSchemaLimits(int MaxCollectionLength, int MaxStringLength, int MaxBinaryLength)
Parameters
MaxCollectionLengthintThe maximum number of elements permitted in an array or object.
MaxStringLengthintThe maximum number of characters permitted in a string.
MaxBinaryLengthintThe maximum number of bytes permitted in a binary value.
Properties
MaxBinaryLength
The maximum number of bytes permitted in a binary value.
public int MaxBinaryLength { readonly get; set; }
Property Value
MaxCollectionLength
The maximum number of elements permitted in an array or object.
public int MaxCollectionLength { readonly get; set; }
Property Value
MaxStringLength
The maximum number of characters permitted in a string.
public int MaxStringLength { readonly get; set; }
Property Value
Methods
FromContext(SerializationContext<JsonEncoder, JsonDecoder>)
Creates limits that match a serialization context.
public static JsonSchemaLimits FromContext(SerializationContext<JsonEncoder, JsonDecoder> context)
Parameters
contextSerializationContext<JsonEncoder, JsonDecoder>The context whose limits should be described.
Returns
- JsonSchemaLimits
The limits.