Class: GVIVE::Identity::Driver
- Inherits:
-
GVIVE::Identities
- Object
- GVIVE::Identities
- GVIVE::Identity::Driver
- Defined in:
- lib/gvive/identity/driver.rb
Instance Attribute Summary collapse
-
#fullname ⇒ Object
Returns the value of attribute fullname.
Attributes inherited from GVIVE::Identities
#data, #id, #photo, #response, #signature
Attributes included from Utils
#amount, #response, #response_text, #result, #status, #transaction_id, #uuid
Instance Method Summary collapse
-
#initialize(coc, fullname, photo = false, signature = false) ⇒ Driver
constructor
Certificate of Competence required Fullname of card holder as it appears on the card Optionally specify whether you want to return a Base64Encoded Photo Optionally specify whether you want to return a Base64Encoded signature.
-
#valid? ⇒ Boolean
Implementing valid? method signature as described in Identity Class.
Methods inherited from GVIVE::Identities
Methods included from Utils
#driver_endpoint, #endpoint, #gvive_request, #http_connect, #passport_endpoint, #voter_endpoint
Methods included from Encoding
#auth_token, #hmac_digest, #request_concat
Constructor Details
#initialize(coc, fullname, photo = false, signature = false) ⇒ Driver
Certificate of Competence required Fullname of card holder as it appears on the card Optionally specify whether you want to return a Base64Encoded Photo Optionally specify whether you want to return a Base64Encoded signature
14 15 16 17 |
# File 'lib/gvive/identity/driver.rb', line 14 def initialize(coc, fullname, photo = false, signature = false) super(coc, photo, signature) @fullname = fullname end |
Instance Attribute Details
#fullname ⇒ Object
Returns the value of attribute fullname.
4 5 6 |
# File 'lib/gvive/identity/driver.rb', line 4 def fullname @fullname end |
Instance Method Details
#valid? ⇒ Boolean
Implementing valid? method signature as described in Identity Class
20 21 22 23 24 |
# File 'lib/gvive/identity/driver.rb', line 20 def valid? @response = gvive_request(driver_endpoint, id_params({ coc: @id, fname: @fullname})) @data = @response.to_o @response.success? end |