private void ProcessValue()
{
if (_currentScope != null && _currentScope.TokenType == JTokenType.Array)
{
_currentScope.ArrayItemCount++;
foreach (JsonSchemaModel currentSchema in CurrentSchemas)
{
// if there is positional validation and the array index is past the number of item validation schemas and there is no additonal items then error
if (currentSchema != null
&& currentSchema.PositionalItemsValidation
&& !currentSchema.AllowAdditionalItems
&& (currentSchema.Items == null || _currentScope.ArrayItemCount - 1 >= currentSchema.Items.Count))
{
RaiseError("Index {0} has not been defined and the schema does not allow additional items.".FormatWith(CultureInfo.InvariantCulture, _currentScope.ArrayItemCount), currentSchema);
}
}
}
}