Sha256: ba91fd74b20e3298361d7ab6e52f770f7cc9a696f37eb6689d667f49974cb2fe

Contents?: true

Size: 780 Bytes

Versions: 16

Compression:

Stored size: 780 Bytes

Contents

# frozen_string_literal: true

require_relative 'base_composer'
module EasyTalk
  module Types
    # Represents a composition type that allows one of the specified types.
    class OneOf < BaseComposer
      # Returns the name of the composition type.
      def self.name
        :oneOf
      end

      # Returns the name of the composition type.
      def name
        :oneOf
      end
    end
  end
end

module T
  # Creates a new instance of `EasyTalk::Types::OneOf` with the given arguments.
  #
  # @param args [Array] the list of arguments to be passed to the `EasyTalk::Types::OneOf` constructor
  # @return [EasyTalk::Types::OneOf] a new instance of `EasyTalk::Types::OneOf`
  module OneOf
    def self.[](*args)
      EasyTalk::Types::OneOf.new(*args)
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
easy_talk-1.0.2 lib/easy_talk/types/one_of.rb
easy_talk-1.0.1 lib/easy_talk/types/one_of.rb
easy_talk-1.0.0 lib/easy_talk/types/one_of.rb
easy_talk-0.2.1 lib/easy_talk/types/one_of.rb
easy_talk-0.2.0 lib/easy_talk/types/one_of.rb
easy_talk-0.1.10 lib/easy_talk/types/one_of.rb
easy_talk-0.1.9 lib/easy_talk/types/one_of.rb
easy_talk-0.1.8 lib/easy_talk/types/one_of.rb
easy_talk-0.1.7 lib/easy_talk/types/one_of.rb
easy_talk-0.1.6 lib/easy_talk/types/one_of.rb
easy_talk-0.1.5 lib/easy_talk/types/one_of.rb
easy_talk-0.1.4 lib/easy_talk/types/one_of.rb
easy_talk-0.1.3 lib/easy_talk/types/one_of.rb
easy_talk-0.1.2 lib/easy_talk/types/one_of.rb
easy_talk-0.1.1 lib/easy_talk/types/one_of.rb
easy_talk-0.1.0 lib/easy_talk/types/one_of.rb