Class: MkAcl::StampExpr
- Inherits:
-
Object
- Object
- MkAcl::StampExpr
- Defined in:
- lib/mikras_utils/mkacl/spec.rb
Overview
For debug. Express the structure of stamp syntax
Instance Attribute Summary collapse
-
#rule ⇒ Object
readonly
Returns the value of attribute rule.
-
#stamp ⇒ Object
[String].
-
#value ⇒ Object
Returns the value of attribute value.
-
#watch ⇒ Object
[String].
Instance Method Summary collapse
- #dump ⇒ Object
-
#initialize(rule, watch, stamp, value) ⇒ StampExpr
constructor
A new instance of StampExpr.
- #to_s ⇒ Object
Constructor Details
#initialize(rule, watch, stamp, value) ⇒ StampExpr
Returns a new instance of StampExpr.
327 328 329 330 331 332 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 327 def initialize(rule, watch, stamp, value) constrain rule, Rule @rule = rule @watch, @stamp, @value = watch, stamp, value rule.send :attach_stamp_expr, self end |
Instance Attribute Details
#rule ⇒ Object (readonly)
Returns the value of attribute rule.
320 321 322 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 320 def rule @rule end |
#stamp ⇒ Object
- String
324 325 326 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 324 def stamp @stamp end |
#value ⇒ Object
Returns the value of attribute value.
325 326 327 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 325 def value @value end |
#watch ⇒ Object
- String
323 324 325 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 323 def watch @watch end |
Instance Method Details
#dump ⇒ Object
336 337 338 339 340 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 336 def dump puts "watch: #{watch.join(" ")}" if watch puts "stamp: #{stamp.join(" ")}" if stamp puts "value: #{value}" if value end |
#to_s ⇒ Object
334 |
# File 'lib/mikras_utils/mkacl/spec.rb', line 334 def to_s() = watch |