Class: Evernote::EDAM::Type::Publishing

Inherits:
Object
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/Evernote/EDAM/types_types.rb

Overview

reference to one of these structures, which gives the location and optional description of the externally-visible public Notebook.

uri
If this field is present, then the notebook is published for mass consumption on the Internet under the provided URI, which is relative to a defined base publishing URI defined by the service. This field can only be modified via the web service GUI ... publishing cannot be modified via an offline client.
Length: EDAM_PUBLISHING_URI_LEN_MIN - EDAM_PUBLISHING_URI_LEN_MAX
Regex: EDAM_PUBLISHING_URI_REGEX
order
When the notes are publicly displayed, they will be sorted based on the requested criteria.
ascending
If this is set to true, then the public notes will be displayed in ascending order (e.g. from oldest to newest). Otherwise, the notes will be displayed in descending order (e.g. newest to oldest).
publicDescription
This field may be used to provide a short description of the notebook, which may be displayed when (e.g.) the notebook is shown in a public view. Can't begin or end with a space.
Length: EDAM_PUBLISHING_DESCRIPTION_LEN_MIN - EDAM_PUBLISHING_DESCRIPTION_LEN_MAX
Regex: EDAM_PUBLISHING_DESCRIPTION_REGEX

Constant Summary collapse

URI =
1
ORDER =
2
ASCENDING =
3
PUBLICDESCRIPTION =
4
FIELDS =
{
  URI => {:type => ::Thrift::Types::STRING, :name => 'uri', :optional => true},
  ORDER => {:type => ::Thrift::Types::I32, :name => 'order', :optional => true, :enum_class => ::Evernote::EDAM::Type::NoteSortOrder},
  ASCENDING => {:type => ::Thrift::Types::BOOL, :name => 'ascending', :optional => true},
  PUBLICDESCRIPTION => {:type => ::Thrift::Types::STRING, :name => 'publicDescription', :optional => true}
}

Constants included from Thrift::Struct_Union

Thrift::Struct_Union::CONTAINER_TYPES

Instance Method Summary collapse

Methods included from Thrift::Struct

#<=>, #==, #differences, #eql?, field_accessor, #fields_with_default_values, generate_accessors, #hash, #initialize, #inspect, qmark_isset_method, #read, #write

Methods included from Thrift::Struct_Union

#each_field, #field_info, #inspect_collection, #inspect_field, #is_container?, #name_to_id, #read_field, #sorted_field_ids, #write_container, #write_data

Instance Method Details

#struct_fieldsObject



1625
# File 'lib/Evernote/EDAM/types_types.rb', line 1625

def struct_fields; FIELDS; end

#validateObject



1627
1628
1629
1630
1631
# File 'lib/Evernote/EDAM/types_types.rb', line 1627

def validate
  unless @order.nil? || ::Evernote::EDAM::Type::NoteSortOrder::VALID_VALUES.include?(@order)
    raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field order!')
  end
end