Sha256: bdd5f1d572b4bdccf2dbd2000d98061665de0cb64b0008daabdd5acbcac8adce
Contents?: true
Size: 558 Bytes
Versions: 1
Compression:
Stored size: 558 Bytes
Contents
# frozen_string_literal: true # @api private # @since 0.1.0 class SmartCore::Types::Primitive::SumFactory::DefinitionContext # @return [Proc, NilClass] # # @api private # @since 0.1.0 attr_reader :type_caster # @return [void] # # @api private # @since 0.1.0 def initialize @type_caster = nil end # @param caster [Block] # @return [void] # # @api public # @since 0.1.0 def define_caster(&caster) raise(SmartCore::ArgumentError, 'No caster definition block') unless block_given? @type_caster = caster end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
smart_types-0.1.0 | lib/smart_core/types/primitive/sum_factory/definition_context.rb |