Class: Zm::Client::Signature
Overview
Constant Summary
collapse
- TYPE_TXT =
'text/plain'
- TYPE_HTML =
'text/html'
- INSTANCE_VARIABLE_KEYS =
i[id name txt html]
Instance Attribute Summary collapse
Attributes inherited from Base::Object
#grantee_type, #name, #parent, #token
Instance Method Summary
collapse
included
#concat, #init_from_json, #rename!, #soap_account_connector, #to_h
#arrow_name, #clone, #concat, #convert_json_string_value, #disable_builder, #enable_builder, #init_from_json, #initialize, #instance_variables_array, #instance_variables_hash, #logger, #recorded?, #save!, #to_s, #use_builder?
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id.
14
15
16
|
# File 'lib/zm/client/signature/signature.rb', line 14
def id
@id
end
|
Instance Method Details
#all_instance_variable_keys ⇒ Object
18
19
20
|
# File 'lib/zm/client/signature/signature.rb', line 18
def all_instance_variable_keys
INSTANCE_VARIABLE_KEYS
end
|
#content ⇒ Object
51
52
53
|
# File 'lib/zm/client/signature/signature.rb', line 51
def content
html || txt
end
|
#create! ⇒ Object
22
23
24
25
26
|
# File 'lib/zm/client/signature/signature.rb', line 22
def create!
rep = @parent.sacc.create_signature(@parent.token, as_jsns)
@id = rep[:Body][:CreateSignatureResponse][:signature].first[:id]
super
end
|
#delete! ⇒ Object
33
34
35
36
|
# File 'lib/zm/client/signature/signature.rb', line 33
def delete!
@parent.sacc.delete_signature(@parent.token, jsns_builder.to_delete)
super
end
|
#html? ⇒ Boolean
43
44
45
|
# File 'lib/zm/client/signature/signature.rb', line 43
def html?
type == TYPE_HTML
end
|
#modify! ⇒ Object
28
29
30
31
|
# File 'lib/zm/client/signature/signature.rb', line 28
def modify!
@parent.sacc.modify_signature(@parent.token, as_jsns)
super
end
|
#txt? ⇒ Boolean
47
48
49
|
# File 'lib/zm/client/signature/signature.rb', line 47
def txt?
type == TYPE_TXT
end
|
#type ⇒ Object
38
39
40
41
|
# File 'lib/zm/client/signature/signature.rb', line 38
def type
return TYPE_HTML unless html.nil?
TYPE_TXT
end
|