Class: Quack::Types::String

Inherits:
Quack::Type show all
Defined in:
lib/quack/types/string.rb

Instance Attribute Summary

Attributes inherited from Quack::Type

#value

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Quack::Type

already_coerced?, #already_coerced?, built_in_types, #initialize, #to_s, #type_matches?

Constructor Details

This class inherits a constructor from Quack::Type

Class Method Details

.matches?(value) ⇒ Boolean

Returns:



7
8
9
# File 'lib/quack/types/string.rb', line 7

def matches?(value)
  true
end

Instance Method Details

#to_coercedObject



12
13
14
# File 'lib/quack/types/string.rb', line 12

def to_coerced
  value.to_s
end