Class: Stratagem::Instrumentation::Models::Authentication::RestfulAuthentication::Metadata

Inherits:
Object
  • Object
show all
Includes:
Metadata
Defined in:
lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb

Overview

prefix method names with to avoid collision

Constant Summary collapse

VIRTUAL_COLUMNS =
[:password, :password_confirmation]

Instance Method Summary collapse

Methods included from Metadata

#exclude_attributes_for_mocking

Constructor Details

#initialize(model) ⇒ Metadata

Returns a new instance of Metadata.



13
14
15
# File 'lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb', line 13

def initialize(model)
  @model = model
end

Instance Method Details

#attribute_namesObject



17
18
19
# File 'lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb', line 17

def attribute_names
  VIRTUAL_COLUMNS
end

#attribute_type(name) ⇒ Object



25
26
27
# File 'lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb', line 25

def attribute_type(name)
  :string
end

#authenticates?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb', line 9

def authenticates?
  true
end

#internal_attributesObject



21
22
23
# File 'lib/stratagem/instrumentation/models/authentication/restful_authentication/metadata.rb', line 21

def internal_attributes
  [:crypted_password]
end