Module: Formally
- Extended by:
- Forwardable
- Defined in:
- lib/formally.rb,
lib/formally/state.rb,
lib/formally/config.rb,
lib/formally/errors.rb,
lib/formally/railtie.rb,
lib/formally/version.rb,
lib/formally/overrides.rb,
lib/formally/class_methods.rb,
lib/formally/predicate_finder.rb
Defined Under Namespace
Modules: ClassMethods, Overrides, PredicateFinder, Predicates Classes: Config, Railtie, State
Constant Summary collapse
- Error =
Class.new StandardError
- ClassMismatch =
Class.new Error
- SchemaUndefined =
Class.new Error
- Unfilled =
Class.new Error
- Invalid =
Class.new Error do attr_accessor :form, :errors def to_s %|<Invalid(#{errors})>| end end
- VERSION =
"0.1.0"
Class Attribute Summary collapse
-
.config ⇒ Object
Returns the value of attribute config.
Instance Attribute Summary collapse
-
#formally ⇒ Object
readonly
Returns the value of attribute formally.
Class Method Summary collapse
Class Attribute Details
.config ⇒ Object
Returns the value of attribute config.
20 21 22 |
# File 'lib/formally.rb', line 20 def config @config end |
Instance Attribute Details
#formally ⇒ Object (readonly)
Returns the value of attribute formally.
39 40 41 |
# File 'lib/formally.rb', line 39 def formally @formally end |
Class Method Details
.included(base) ⇒ Object
26 27 28 29 30 |
# File 'lib/formally.rb', line 26 def included base base.extend Formally::ClassMethods base.prepend Formally::Overrides base.formally = Formally.config.with(klass: base) end |
.predicates(&block) ⇒ Object
22 23 24 |
# File 'lib/formally.rb', line 22 def predicates &block Predicates.class_exec(&block) end |