Class: Appwrite::Models::AlgoScryptModified

Inherits:
Object
  • Object
show all
Defined in:
lib/appwrite/models/algo_scrypt_modified.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type:, salt:, salt_separator:, signer_key:) ⇒ AlgoScryptModified

Returns a new instance of AlgoScryptModified.



11
12
13
14
15
16
17
18
19
20
21
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 11

def initialize(
    type:,
    salt:,
    salt_separator:,
    signer_key:
)
    @type = type
    @salt = salt
    @salt_separator = salt_separator
    @signer_key = signer_key
end

Instance Attribute Details

#saltObject (readonly)

Returns the value of attribute salt.



7
8
9
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 7

def salt
  @salt
end

#salt_separatorObject (readonly)

Returns the value of attribute salt_separator.



8
9
10
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 8

def salt_separator
  @salt_separator
end

#signer_keyObject (readonly)

Returns the value of attribute signer_key.



9
10
11
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 9

def signer_key
  @signer_key
end

#typeObject (readonly)

Returns the value of attribute type.



6
7
8
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 6

def type
  @type
end

Class Method Details

.from(map:) ⇒ Object



23
24
25
26
27
28
29
30
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 23

def self.from(map:)
    AlgoScryptModified.new(
        type: map["type"],
        salt: map["salt"],
        salt_separator: map["saltSeparator"],
        signer_key: map["signerKey"]
    )
end

Instance Method Details

#to_mapObject



32
33
34
35
36
37
38
39
# File 'lib/appwrite/models/algo_scrypt_modified.rb', line 32

def to_map
    {
        "type": @type,
        "salt": @salt,
        "saltSeparator": @salt_separator,
        "signerKey": @signer_key
    }
end