Class: Elf::Policy::DataBuilder
- Inherits:
-
Object
- Object
- Elf::Policy::DataBuilder
- Includes:
- BuilderHelper
- Defined in:
- lib/mithril/policy/dsl.rb
Instance Method Summary collapse
- #exec(v = true) ⇒ Object
-
#initialize(transition) ⇒ DataBuilder
constructor
A new instance of DataBuilder.
-
#read(v = true) ⇒ Object
TODO: Unify transitions? Intervaltree?.
- #write(v = true) ⇒ Object
Methods included from BuilderHelper
Constructor Details
#initialize(transition) ⇒ DataBuilder
Returns a new instance of DataBuilder.
235 236 237 |
# File 'lib/mithril/policy/dsl.rb', line 235 def initialize(transition) @transition = transition end |
Instance Method Details
#exec(v = true) ⇒ Object
245 246 247 248 |
# File 'lib/mithril/policy/dsl.rb', line 245 def exec(v=true) @transition.exec = v @transition.read ||= v end |
#read(v = true) ⇒ Object
TODO: Unify transitions? Intervaltree?
238 239 240 |
# File 'lib/mithril/policy/dsl.rb', line 238 def read(v=true) #TODO: Unify transitions? Intervaltree? @transition.read = v end |
#write(v = true) ⇒ Object
241 242 243 244 |
# File 'lib/mithril/policy/dsl.rb', line 241 def write(v=true) @transition.write = v @transition.read ||= v end |