class Sinatra::Base

def build(*args, &bk)

an instance of this class as end point.
Creates a Rack::Builder instance with all the middleware set up and
def build(*args, &bk)
  builder = Rack::Builder.new
  builder.use Rack::MethodOverride if method_override?
  builder.use ShowExceptions       if show_exceptions?
  builder.use Rack::CommonLogger   if logging?
  setup_sessions builder
  middleware.each { |c,a,b| builder.use(c, *a, &b) }
  builder.run new!(*args, &bk)
  builder
end