class Thumbtack::Types::Title

Handles validation of title values as supported by Pinboard

@api private

Constants

MAXIMUM_LENGTH

Maximum length of a title value

Public Class Methods

validate(value) click to toggle source

Validate a title

@param [String] value

the title to validate

@return [self]

@raise [Types::ValidationError]

if the value is longer than 255 characters
# File lib/thumbtack/types/title.rb, line 21
def self.validate(value)
  LengthValidation.validate value, MAXIMUM_LENGTH
  self
end