Class: Lutaml::Xsd::SchemaRepositoryPackage::ValidationResult
- Inherits:
-
Object
- Object
- Lutaml::Xsd::SchemaRepositoryPackage::ValidationResult
- Defined in:
- lib/lutaml/xsd/schema_repository_package.rb
Overview
Package validation result
Instance Attribute Summary collapse
-
#errors ⇒ Object
readonly
Returns the value of attribute errors.
-
#metadata ⇒ Object
readonly
Returns the value of attribute metadata.
-
#valid ⇒ Object
readonly
Returns the value of attribute valid.
-
#warnings ⇒ Object
readonly
Returns the value of attribute warnings.
Instance Method Summary collapse
-
#initialize(valid:, errors: [], warnings: [], metadata: nil) ⇒ ValidationResult
constructor
A new instance of ValidationResult.
- #to_h ⇒ Object
- #valid? ⇒ Boolean
Constructor Details
#initialize(valid:, errors: [], warnings: [], metadata: nil) ⇒ ValidationResult
Returns a new instance of ValidationResult.
18 19 20 21 22 23 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 18 def initialize(valid:, errors: [], warnings: [], metadata: nil) @valid = valid @errors = errors @warnings = warnings @metadata = end |
Instance Attribute Details
#errors ⇒ Object (readonly)
Returns the value of attribute errors.
16 17 18 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 16 def errors @errors end |
#metadata ⇒ Object (readonly)
Returns the value of attribute metadata.
16 17 18 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 16 def @metadata end |
#valid ⇒ Object (readonly)
Returns the value of attribute valid.
16 17 18 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 16 def valid @valid end |
#warnings ⇒ Object (readonly)
Returns the value of attribute warnings.
16 17 18 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 16 def warnings @warnings end |
Instance Method Details
#to_h ⇒ Object
29 30 31 32 33 34 35 36 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 29 def to_h { valid?: valid?, errors: errors, warnings: warnings, metadata: , } end |
#valid? ⇒ Boolean
25 26 27 |
# File 'lib/lutaml/xsd/schema_repository_package.rb', line 25 def valid? @valid end |