Class: G5AuthenticationClient::User

Inherits:
Modelish::Base
  • Object
show all
Defined in:
lib/g5_authentication_client/user.rb

Overview

A G5 Authentication User

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#emailString

The user’s email address.

Returns:

  • (String)


10
# File 'lib/g5_authentication_client/user.rb', line 10

property :email, type: String, required: true

#idInteger

The user’s id. Not required to create a user.

Returns:

  • (Integer)


25
# File 'lib/g5_authentication_client/user.rb', line 25

property :id, type: Integer

#passwordString

The user’s password. Required to create a user.

Returns:

  • (String)


15
# File 'lib/g5_authentication_client/user.rb', line 15

property :password, type: String

#password_confirmationString

The user’s password_confirmation.

Returns:

  • (String)


20
# File 'lib/g5_authentication_client/user.rb', line 20

property :password_confirmation, type: String

Instance Method Details

#validate_for_create!Object

Raises:

  • (ArgumentError)


27
28
29
30
# File 'lib/g5_authentication_client/user.rb', line 27

def validate_for_create!
  validate!
  raise ArgumentError.new("Password required for new user.") unless !password.nil?
end