Class: NetSuite::Passports::User

Inherits:
Object
  • Object
show all
Defined in:
lib/netsuite/passports/user.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(account, email, password, role) ⇒ User

Returns a new instance of User.



6
7
8
9
10
11
# File 'lib/netsuite/passports/user.rb', line 6

def initialize(, email, password, role)
  @account = .to_s
  @email = email
  @password = password
  @role = role
end

Instance Attribute Details

#accountObject (readonly)

Returns the value of attribute account.



4
5
6
# File 'lib/netsuite/passports/user.rb', line 4

def 
  @account
end

#emailObject (readonly)

Returns the value of attribute email.



4
5
6
# File 'lib/netsuite/passports/user.rb', line 4

def email
  @email
end

#passwordObject (readonly)

Returns the value of attribute password.



4
5
6
# File 'lib/netsuite/passports/user.rb', line 4

def password
  @password
end

#roleObject (readonly)

Returns the value of attribute role.



4
5
6
# File 'lib/netsuite/passports/user.rb', line 4

def role
  @role
end

Instance Method Details

#passportObject



13
14
15
16
17
18
19
20
21
22
# File 'lib/netsuite/passports/user.rb', line 13

def passport
  {
    'platformMsgs:passport' => {
      'platformCore:account'  => ,
      'platformCore:email'    => email,
      'platformCore:password' => password,
      'platformCore:role'     => { :@internalId => role }
    }
  }
end