Module: StateGate
- Defined in:
- lib/state_gate.rb,
lib/state_gate/type.rb,
lib/state_gate/engine.rb,
lib/state_gate/builder.rb,
lib/state_gate/version.rb,
lib/state_gate/assertions.rb,
lib/state_gate/engine/fixer.rb,
lib/state_gate/engine/scoper.rb,
lib/state_gate/engine/stator.rb,
lib/state_gate/engine/errator.rb,
lib/state_gate/engine/sequencer.rb,
lib/state_gate/engine/configurator.rb,
lib/state_gate/engine/transitioner.rb,
lib/state_gate/builder/scope_methods.rb,
lib/state_gate/builder/state_methods.rb,
lib/state_gate/builder/transition_methods.rb,
lib/state_gate/builder/conflict_detection_methods.rb,
lib/state_gate/builder/transition_validation_methods.rb,
lib/state_gate/builder/dynamic_module_creation_methods.rb
Overview
Version for StateGate
Defined Under Namespace
Modules: Assertions, VERSION Classes: Builder, ConfigurationError, ConflictError, Engine, Type
Class Method Summary collapse
-
.gem_version ⇒ Gem::Version
Returns the gem version.
-
.symbolize(val) ⇒ Symbol?
Returns the Symbol version of the provided value as long as it responds to #to_s and has no included whitespace in the resulting String.
Class Method Details
.gem_version ⇒ Gem::Version
Returns the gem version.
13 14 15 |
# File 'lib/state_gate/version.rb', line 13 def self.gem_version Gem::Version.new VERSION::STRING end |
.symbolize(val) ⇒ Symbol?
Returns the Symbol version of the provided value as long as it responds to #to_s and has no included whitespace in the resulting String.
148 149 150 151 152 153 154 |
# File 'lib/state_gate.rb', line 148 def self.symbolize(val) return nil if val.blank? return nil unless val.respond_to?(:to_s) return nil unless val.to_s.remove(/\s+/) == val.to_s val.to_s.downcase.to_sym end |