Class: DynamicPDFApi::TextReplace
- Inherits:
-
Object
- Object
- DynamicPDFApi::TextReplace
- Defined in:
- lib/ruby_client/TextReplace.rb
Instance Attribute Summary collapse
-
#match_case ⇒ Object
If True, the search operation will be case sensitive.
-
#replace_text ⇒ Object
Gets or sets ReplaceText value.This string will replace the Text during conversion.
-
#text ⇒ Object
Gets or sets the Find Text value.
Instance Method Summary collapse
-
#initialize(text, replaceText, matchCase = false) ⇒ TextReplace
constructor
Represents the find and replace values and its options.
- #to_json(_options = {}) ⇒ Object
Constructor Details
#initialize(text, replaceText, matchCase = false) ⇒ TextReplace
Represents the find and replace values and its options.
10 11 12 13 14 |
# File 'lib/ruby_client/TextReplace.rb', line 10 def initialize(text, replaceText, matchCase = false) @text = text @replace_text = replaceText @match_case = matchCase end |
Instance Attribute Details
#match_case ⇒ Object
If True, the search operation will be case sensitive.
29 30 31 |
# File 'lib/ruby_client/TextReplace.rb', line 29 def match_case @match_case end |
#replace_text ⇒ Object
Gets or sets ReplaceText value.This string will replace the Text during conversion.
24 25 26 |
# File 'lib/ruby_client/TextReplace.rb', line 24 def replace_text @replace_text end |
#text ⇒ Object
Gets or sets the Find Text value. This string will be replaced with ReplaceText during conversion.
19 20 21 |
# File 'lib/ruby_client/TextReplace.rb', line 19 def text @text end |
Instance Method Details
#to_json(_options = {}) ⇒ Object
31 32 33 34 35 36 37 38 39 40 41 |
# File 'lib/ruby_client/TextReplace.rb', line 31 def to_json( = {}) json_array = {} json_array["text"] = @text json_array["replaceText"] = @replace_text unless @replace_text.nil? json_array["matchCase"] = @match_case unless @match_case.nil? JSON.pretty_generate(json_array) end |