class Dry::Types::AnyClass
@api public
and anything is acceptable.
This type is useful in places where you can’t be specific about the type
Any is a nominal type that defines Object as the primitive class
def self.name
def self.name "Any" end
def initialize(**options)
- Api: - private
def initialize(**options) super(::Object, **options) end
def name
- Api: - public
Returns:
-
(String)
-
def name "Any" end
def to_ast(meta: true)
- Api: - public
Returns:
-
(Array)
-
def to_ast(meta: true) [:any, meta ? self.meta : EMPTY_HASH] end
def with(**new_options)
- Api: - public
Returns:
-
(Type)
-
Parameters:
-
new_options
(Hash
) --
def with(**new_options) self.class.new(**options, meta: @meta, **new_options) end