Module: Hubert::DSL

Defined in:
lib/hubert/dsl.rb

Defined Under Namespace

Classes: MethodDefiner

Instance Method Summary collapse

Instance Method Details

#_hubert_builderObject



56
57
58
# File 'lib/hubert/dsl.rb', line 56

def _hubert_builder
  @_hubert_builder ||= Builder.new
end

#host(host) ⇒ Object



44
45
46
# File 'lib/hubert/dsl.rb', line 44

def host(host)
  _hubert_builder.host = host
end

#http!Object



36
37
38
# File 'lib/hubert/dsl.rb', line 36

def http!
  _hubert_builder.http!
end

#https!Object



40
41
42
# File 'lib/hubert/dsl.rb', line 40

def https!
  _hubert_builder.https!
end

#path(path, options = {}) ⇒ Object



28
29
30
# File 'lib/hubert/dsl.rb', line 28

def path(path, options = {})
  MethodDefiner.new(self).define(:path, path, options)
end

#path_prefix(path_prefix) ⇒ Object



52
53
54
# File 'lib/hubert/dsl.rb', line 52

def path_prefix(path_prefix)
  _hubert_builder.path_prefix = path_prefix
end

#port(port) ⇒ Object



48
49
50
# File 'lib/hubert/dsl.rb', line 48

def port(port)
  _hubert_builder.port = port
end

#url(path, options = {}) ⇒ Object



32
33
34
# File 'lib/hubert/dsl.rb', line 32

def url(path, options = {})
  MethodDefiner.new(self).define(:url, path, options)
end