Class: AsposePdfCloud::PermissionsFlags

Inherits:
Object
  • Object
show all
Defined in:
lib/aspose_pdf_cloud/models/permissions_flags.rb

Constant Summary collapse

"PrintDocument".freeze
MODIFY_CONTENT =
"ModifyContent".freeze
EXTRACT_CONTENT =
"ExtractContent".freeze
MODIFY_TEXT_ANNOTATIONS =
"ModifyTextAnnotations".freeze
FILL_FORM =
"FillForm".freeze
EXTRACT_CONTENT_WITH_DISABILITIES =
"ExtractContentWithDisabilities".freeze
ASSEMBLE_DOCUMENT =
"AssembleDocument".freeze
PRINTING_QUALITY =
"PrintingQuality".freeze

Instance Method Summary collapse

Instance Method Details

#build_from_hash(value) ⇒ String

Builds the enum from string

Parameters:

  • The (String)

    enum value in the form of the string

Returns:

  • (String)

    The enum value



40
41
42
43
44
45
46
47
# File 'lib/aspose_pdf_cloud/models/permissions_flags.rb', line 40

def build_from_hash(value)
  # resolve issue with Concstant Name modification (ex: "FooName" to :FOO_NAME)
  # consantValues = PermissionsFlags.constants.select{|c| c.to_s == value}
  constantValues = PermissionsFlags.constants.select{ |const_name| PermissionsFlags.const_get(const_name) == value}
  
  raise "Invalid ENUM value #{value} for class #PermissionsFlags" if constantValues.empty?
  value
end