Module: Gorillib::Model::PositionalFields

Extended by:
Concern
Defined in:
lib/gorillib/model/positional_fields.rb

Overview

give each field the next position in order

@note: make sure you're keeping positionals straight in super classes, or in anything added after this.

Examples:

class Foo
  include Gorillib::Model
  field :bob,    String               # not positional
  field :zoe,    String, position: 0  # positional 0 (explicit)
end
class Subby < Foo
  include Gorillib::Model::PositionalFields
  field :wun, String                  # positional 1
end
Foo.field    :nope, String            # not positional
Subby.field  :toofer, String          # positional 2

Defined Under Namespace

Modules: ClassMethods

Method Summary

Methods included from Concern

append_features, extended, included