Package io.github.qishr.cascara.schema.rule
Class TypeRule
java.lang.Object
io.github.qishr.cascara.schema.rule.AbstractValidationRule
io.github.qishr.cascara.schema.rule.TypeRule
All Implemented Interfaces:
ValidationRule
public class TypeRule
extends AbstractValidationRule
Constructor Summary
| Constructor | Description |
|---|---|
| TypeRule(PrimitiveType expectedType) |
Method Summary
| Modifier and Type | Method | Description |
|---|---|---|
| public boolean | validate(AstNode node, String path, Reporter reporter) | |
| public boolean | validateValue(Object value, String path, int line, int column, Reporter reporter) |
Methods inherited from AbstractValidationRule
error, error
Method Details
validate
public boolean validate(AstNode node, String path, Reporter reporter)
Specified By:
validateValue
public boolean validateValue(Object value, String path, int line, int column, Reporter reporter)