Class: MicrosoftGraph::Models::WorkbookTableSort

Inherits:
Entity
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/workbook_table_sort.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Entity

#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=

Constructor Details

#initializeObject

Instantiates a new workbookTableSort and sets the default values.



22
23
24
# File 'lib/models/workbook_table_sort.rb', line 22

def initialize()
    super
end

Class Method Details

.create_from_discriminator_value(parse_node) ⇒ Object

Creates a new instance of the appropriate class based on discriminator value

Parameters:

  • parse_node

    The parse node to use to read the discriminator value and create the object

Returns:

  • a workbook_table_sort

Raises:

  • (StandardError)


30
31
32
33
# File 'lib/models/workbook_table_sort.rb', line 30

def self.create_from_discriminator_value(parse_node)
    raise StandardError, 'parse_node cannot be null' if parse_node.nil?
    return WorkbookTableSort.new
end

Instance Method Details

#fieldsObject

Gets the fields property value. Represents the current conditions used to last sort the table. Read-only.

Returns:

  • a workbook_sort_field



38
39
40
# File 'lib/models/workbook_table_sort.rb', line 38

def fields
    return @fields
end

#fields=(value) ⇒ Object

Sets the fields property value. Represents the current conditions used to last sort the table. Read-only.

Parameters:

  • value

    Value to set for the fields property.

Returns:

  • a void



46
47
48
# File 'lib/models/workbook_table_sort.rb', line 46

def fields=(value)
    @fields = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



53
54
55
56
57
58
59
# File 'lib/models/workbook_table_sort.rb', line 53

def get_field_deserializers()
    return super.merge({
        "fields" => lambda {|n| @fields = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::WorkbookSortField.create_from_discriminator_value(pn) }) },
        "matchCase" => lambda {|n| @match_case = n.get_boolean_value() },
        "method" => lambda {|n| @method = n.get_string_value() },
    })
end

#match_caseObject

Gets the matchCase property value. Represents whether the casing impacted the last sort of the table. Read-only.

Returns:

  • a boolean



64
65
66
# File 'lib/models/workbook_table_sort.rb', line 64

def match_case
    return @match_case
end

#match_case=(value) ⇒ Object

Sets the matchCase property value. Represents whether the casing impacted the last sort of the table. Read-only.

Parameters:

  • value

    Value to set for the matchCase property.

Returns:

  • a void



72
73
74
# File 'lib/models/workbook_table_sort.rb', line 72

def match_case=(value)
    @match_case = value
end

#methodObject

Gets the method property value. Represents Chinese character ordering method last used to sort the table. The possible values are: PinYin, StrokeCount. Read-only.

Returns:

  • a string



79
80
81
# File 'lib/models/workbook_table_sort.rb', line 79

def method
    return @method
end

#method=(value) ⇒ Object

Sets the method property value. Represents Chinese character ordering method last used to sort the table. The possible values are: PinYin, StrokeCount. Read-only.

Parameters:

  • value

    Value to set for the method property.

Returns:

  • a void



87
88
89
# File 'lib/models/workbook_table_sort.rb', line 87

def method=(value)
    @method = value
end

#serialize(writer) ⇒ Object

Serializes information the current object

Parameters:

  • writer

    Serialization writer to use to serialize this model

Returns:

  • a void

Raises:

  • (StandardError)


95
96
97
98
99
100
101
# File 'lib/models/workbook_table_sort.rb', line 95

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_collection_of_object_values("fields", @fields)
    writer.write_boolean_value("matchCase", @match_case)
    writer.write_string_value("method", @method)
end