class AsposeSlidesCloud::NotesCommentsLayoutingOptions
Notes & comments layouting options.
Attributes
Gets or sets the color of comments area (Applies only if comments are displayed on the right).
Gets or sets the width of the comment output area in pixels (Applies only if comments are displayed on the right).
Gets or sets the position of the comments on the page.
Gets or sets the position of the notes on the page.
Public Class Methods
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 44 def self.attribute_map super.merge({ :'notes_position' => :'NotesPosition', :'comments_position' => :'CommentsPosition', :'comments_area_width' => :'CommentsAreaWidth', :'comments_area_color' => :'CommentsAreaColor', :'show_comments_by_no_author' => :'ShowCommentsByNoAuthor', }) end
Attribute mapping from ruby-style variable name to JSON key.
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 67 def initialize(attributes = {}) super if attributes.has_key?(:'NotesPosition') self.notes_position = attributes[:'NotesPosition'] end if attributes.has_key?(:'CommentsPosition') self.comments_position = attributes[:'CommentsPosition'] end if attributes.has_key?(:'CommentsAreaWidth') self.comments_area_width = attributes[:'CommentsAreaWidth'] end if attributes.has_key?(:'CommentsAreaColor') self.comments_area_color = attributes[:'CommentsAreaColor'] end if attributes.has_key?(:'ShowCommentsByNoAuthor') self.show_comments_by_no_author = attributes[:'ShowCommentsByNoAuthor'] end self.layout_type = 'NotesComments' end
Initializes the object @param [Hash] attributes Model attributes in the form of hash
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 55 def self.swagger_types super.merge({ :'notes_position' => :'String', :'comments_position' => :'String', :'comments_area_width' => :'Integer', :'comments_area_color' => :'String', :'show_comments_by_no_author' => :'BOOLEAN', }) end
Attribute type mapping.
Public Instance Methods
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 132 def ==(o) return true if self.equal?(o) self.class == o.class && layout_type == o.layout_type && notes_position == o.notes_position && comments_position == o.comments_position && comments_area_width == o.comments_area_width && comments_area_color == o.comments_area_color && show_comments_by_no_author == o.show_comments_by_no_author end
Checks equality by comparing each attribute. @param [Object] Object to be compared
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 122 def comments_position=(comments_position) validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right']) unless validator.valid?(comments_position) fail ArgumentError, 'invalid value for "comments_position", must be one of #{validator.allowable_values}.' end @comments_position = comments_position end
Custom attribute writer method checking allowed values (enum). @param [Object] comments_position
Object to be assigned
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 145 def eql?(o) self == o end
@see the ‘==` method @param [Object] Object to be compared
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 151 def hash [layout_type, notes_position, comments_position, comments_area_width, comments_area_color, show_comments_by_no_author].hash end
Calculates hash code according to all attributes. @return [Fixnum] Hash code
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 94 def list_invalid_properties invalid_properties = super invalid_properties end
Show invalid properties with the reasons. Usually used together with valid? @return Array for valid properties with the reasons
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 112 def notes_position=(notes_position) validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated']) unless validator.valid?(notes_position) fail ArgumentError, 'invalid value for "notes_position", must be one of #{validator.allowable_values}.' end @notes_position = notes_position end
Custom attribute writer method checking allowed values (enum). @param [Object] notes_position
Object to be assigned
Source
# File lib/aspose_slides_cloud/models/notes_comments_layouting_options.rb, line 101 def valid? return false if !super notes_position_validator = EnumAttributeValidator.new('String', ['None', 'BottomFull', 'BottomTruncated']) return false unless notes_position_validator.valid?(@notes_position) comments_position_validator = EnumAttributeValidator.new('String', ['None', 'Bottom', 'Right']) return false unless comments_position_validator.valid?(@comments_position) true end
Check to see if the all the properties in the model are valid @return true if the model is valid