# Service modules the +Service+ class depends on. def service_modules Dir[File.expand_path("../service/*.rb", __FILE__)] end service_modules.each { |file| require file } module Hexx # Base class for service objects. class Service include Messages, Parameters, Transactions, Validations, Callbacks # Runs the service object. # # The method must be defined in a specific service class, # inherited from Hexx::Service. # def run fail NotImplementedError.new "#{ self.class.name }#run not implemented." end end end