Class: Jafry::Identificator::Number

Inherits:
Object
  • Object
show all
Defined in:
lib/jafry/identificator.rb

Overview

Since:

  • 0.2.0

Instance Method Summary collapse

Instance Method Details

#id_scaffold(wrapper, scheme) ⇒ Hash

Specify hash for basic scheme id type with custom id wrapper

Returns:

  • (Hash)

    Hash with basic id

Since:

  • 0.2.0



116
117
118
# File 'lib/jafry/identificator.rb', line 116

def id_scaffold(wrapper, scheme)
  {"#{wrapper}" => Identificator::inc_scheme_counter(scheme)}
end

#scheme_scaffold(scheme_name) ⇒ Hash

Specify hash for basic scheme id type

Returns:

  • (Hash)

    Hash with basic id

Since:

  • 0.2.0



108
109
110
# File 'lib/jafry/identificator.rb', line 108

def scheme_scaffold(scheme_name)
  {scheme: scheme_name, counter: 0}
end