Class: LintFu::ActiveRecord::ModelModel
- Inherits:
-
Object
- Object
- LintFu::ActiveRecord::ModelModel
- Includes:
- ModelElement
- Defined in:
- lib/lint_fu/active_record/model_model.rb
Instance Attribute Summary collapse
-
#associations ⇒ Object
readonly
Returns the value of attribute associations.
-
#named_scopes ⇒ Object
readonly
Returns the value of attribute named_scopes.
-
#paranoid ⇒ Object
writeonly
Sets the attribute paranoid.
Attributes included from ModelElement
#modeled_class_name, #modeled_class_superclass_name, #parse_tree, #supermodel
Instance Method Summary collapse
-
#initialize(sexp, namespace = nil) ⇒ ModelModel
constructor
A new instance of ModelModel.
- #paranoid? ⇒ Boolean
Methods included from ModelElement
Constructor Details
#initialize(sexp, namespace = nil) ⇒ ModelModel
Returns a new instance of ModelModel.
10 11 12 13 14 |
# File 'lib/lint_fu/active_record/model_model.rb', line 10 def initialize(sexp, namespace=nil) super(sexp, namespace) @associations = {} @named_scopes = {} end |
Instance Attribute Details
#associations ⇒ Object (readonly)
Returns the value of attribute associations.
6 7 8 |
# File 'lib/lint_fu/active_record/model_model.rb', line 6 def associations @associations end |
#named_scopes ⇒ Object (readonly)
Returns the value of attribute named_scopes.
7 8 9 |
# File 'lib/lint_fu/active_record/model_model.rb', line 7 def named_scopes @named_scopes end |
#paranoid=(value) ⇒ Object (writeonly)
Sets the attribute paranoid
8 9 10 |
# File 'lib/lint_fu/active_record/model_model.rb', line 8 def paranoid=(value) @paranoid = value end |
Instance Method Details
#paranoid? ⇒ Boolean
16 17 18 |
# File 'lib/lint_fu/active_record/model_model.rb', line 16 def paranoid? !!@paranoid end |