Module: ActiveFacts::AutoCounterClass
- Defined in:
- lib/activefacts/api/numeric.rb
Instance Method Summary collapse
Instance Method Details
#identifying_role_values(constellation, args) ⇒ Object
98 99 100 101 102 103 104 105 106 107 108 109 110 111 |
# File 'lib/activefacts/api/numeric.rb', line 98 def (constellation, args) arg_hash = args[-1].is_a?(Hash) ? args.pop : {} n = case when args == [:new] # A new object has no identifying_role_values :new when args.size == 1 && args[0].is_a?(AutoCounter) args[0] # An AutoCounter is its own key else new(*args) end args.replace([arg_hash]) n end |