Sha256: dda4973d1eff4438572f2ec03979f65fa82c3b84eef0734f79b37a6f200bddb3

Contents?: true

Size: 792 Bytes

Versions: 60

Compression:

Stored size: 792 Bytes

Contents

  class {{classname}}{{#allowableValues}}{{#enumVars}}
    {{{name}}} = {{{value}}}.freeze{{/enumVars}}

{{/allowableValues}}
    # Builds the enum from string
    # @param [String] The enum value in the form of the string
    # @return [String] The enum value
    def self.build_from_hash(value)
      new.build_from_hash(value)
    end

    # Builds the enum from string
    # @param [String] The enum value in the form of the string
    # @return [String] The enum value
    def build_from_hash(value)
      {{! Modified by Plaid - allow for extensible enum values }}
      # We do not validate that the value is one of the enums set in the OpenAPI
      # file because we want to be able to add to our list of enums without
      # breaking this client library.
      value
    end
  end

Version data entries

60 entries across 60 versions & 1 rubygems

Version Path
plaid-36.1.0 templates/ruby/partial_model_enum_class.mustache
plaid-36.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-35.1.0 templates/ruby/partial_model_enum_class.mustache
plaid-35.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-34.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-33.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-32.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-31.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-30.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-29.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-27.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-26.0.1 templates/ruby/partial_model_enum_class.mustache
plaid-26.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-25.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-24.4.0 templates/ruby/partial_model_enum_class.mustache
plaid-24.3.0 templates/ruby/partial_model_enum_class.mustache
plaid-24.2.0 templates/ruby/partial_model_enum_class.mustache
plaid-24.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-23.0.0 templates/ruby/partial_model_enum_class.mustache
plaid-22.0.0 templates/ruby/partial_model_enum_class.mustache