module Eco module API class Session class Batch module Launcher module ValidMethods VALID_METHODS = %i[get create update upsert delete].freeze def self.included(base) super base.extend(ClassMethods) base.send(:include, InstanceMethods) end module ClassMethods # @return [Boolean] `true` if the method is supported, `false` otherwise. def valid_method?(value) VALID_METHODS.include?(value) end end module InstanceMethods private def valid_method?(value) self.class.valid_method?(value) end end end end end end end end