Class: ZAPv2::Acsrf

Inherits:
Object
  • Object
show all
Defined in:
lib/zap/v2apis/acsrf.rb

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Acsrf

Returns a new instance of Acsrf.



5
6
7
# File 'lib/zap/v2apis/acsrf.rb', line 5

def initialize(client)
  @client = client
end

Instance Method Details

#add_option_token(string) ⇒ Object



17
18
19
# File 'lib/zap/v2apis/acsrf.rb', line 17

def add_option_token(string)
  @client.get("/JSON/acsrf/action/addOptionToken/?String=#{string}")
end

#gen_form(href_id, action_url) ⇒ Object



29
30
31
# File 'lib/zap/v2apis/acsrf.rb', line 29

def gen_form(href_id, action_url)
  @client.get("/JSON/acsrf/other/genForm/?hrefId=#{href_id}&actionUrl=#{action_url}")
end

#option_partial_matching_enabledObject



9
10
11
# File 'lib/zap/v2apis/acsrf.rb', line 9

def option_partial_matching_enabled
  @client.get('/JSON/acsrf/view/optionPartialMatchingEnabled/')
end

#option_tokens_namesObject



13
14
15
# File 'lib/zap/v2apis/acsrf.rb', line 13

def option_tokens_names
  @client.get('/JSON/acsrf/view/optionTokensNames/')
end

#remove_option_token(string) ⇒ Object



21
22
23
# File 'lib/zap/v2apis/acsrf.rb', line 21

def remove_option_token(string)
  @client.get("/JSON/acsrf/action/removeOptionToken/?String=#{string}")
end

#set_option_partial_matching_enabled(boolean) ⇒ Object



25
26
27
# File 'lib/zap/v2apis/acsrf.rb', line 25

def set_option_partial_matching_enabled(boolean)
  @client.get("/JSON/acsrf/action/setOptionPartialMatchingEnabled/?Boolean=#{boolean}")
end