Class: ForeignKeyChecker::Checkers::Relations::Result
- Inherits:
-
Object
- Object
- ForeignKeyChecker::Checkers::Relations::Result
- Defined in:
- lib/foreign_key_checker/checkers/relations.rb
Direct Known Subclasses
ErrorResult, HasOneOrManyDependentResult, HasOneOrManyResult, JoinResult, NoModelResult
Instance Attribute Summary collapse
-
#association ⇒ Object
readonly
Returns the value of attribute association.
-
#error ⇒ Object
readonly
Returns the value of attribute error.
-
#fk ⇒ Object
readonly
Returns the value of attribute fk.
-
#model ⇒ Object
readonly
Returns the value of attribute model.
-
#ok ⇒ Object
readonly
Returns the value of attribute ok.
-
#table ⇒ Object
readonly
Returns the value of attribute table.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Result
constructor
A new instance of Result.
Constructor Details
#initialize(**args) ⇒ Result
Returns a new instance of Result.
6 7 8 9 10 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 6 def initialize(**args) %i[model association ok error fk table].each do |key| instance_variable_set("@#{key}", args[key]) end end |
Instance Attribute Details
#association ⇒ Object (readonly)
Returns the value of attribute association.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def association @association end |
#error ⇒ Object (readonly)
Returns the value of attribute error.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def error @error end |
#fk ⇒ Object (readonly)
Returns the value of attribute fk.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def fk @fk end |
#model ⇒ Object (readonly)
Returns the value of attribute model.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def model @model end |
#ok ⇒ Object (readonly)
Returns the value of attribute ok.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def ok @ok end |
#table ⇒ Object (readonly)
Returns the value of attribute table.
5 6 7 |
# File 'lib/foreign_key_checker/checkers/relations.rb', line 5 def table @table end |