Class: AILabTools::Generated::Params::PortraitAIBeardStylingParams
- Defined in:
- lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb
Instance Attribute Summary collapse
-
#beard ⇒ Object
readonly
Returns the value of attribute beard.
-
#image ⇒ Object
readonly
Returns the value of attribute image.
-
#image_template ⇒ Object
readonly
Returns the value of attribute image_template.
Instance Method Summary collapse
- #body_fields ⇒ Object
-
#initialize(image:, beard: nil, image_template: nil) ⇒ PortraitAIBeardStylingParams
constructor
A new instance of PortraitAIBeardStylingParams.
- #query_fields ⇒ Object
Constructor Details
#initialize(image:, beard: nil, image_template: nil) ⇒ PortraitAIBeardStylingParams
Returns a new instance of PortraitAIBeardStylingParams.
8 9 10 11 12 13 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 8 def initialize(image:, beard: nil, image_template: nil) @image = image @beard = beard @image_template = image_template raise ArgumentError, "At least one of beard, image_template is required" if @beard.nil? && @image_template.nil? end |
Instance Attribute Details
#beard ⇒ Object (readonly)
Returns the value of attribute beard.
7 8 9 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 7 def beard @beard end |
#image ⇒ Object (readonly)
Returns the value of attribute image.
7 8 9 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 7 def image @image end |
#image_template ⇒ Object (readonly)
Returns the value of attribute image_template.
7 8 9 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 7 def image_template @image_template end |
Instance Method Details
#body_fields ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 19 def body_fields compact_hash({ "image" => @image, "beard" => @beard, "image_template" => @image_template, }) end |
#query_fields ⇒ Object
15 16 17 |
# File 'lib/ailabtools/generated/params/portrait_ai_beard_styling_params.rb', line 15 def query_fields {} end |