class CF::Service::Unbind

Public Instance Methods

unbind_service() click to toggle source
# File lib/cf/cli/service/unbind.rb, line 11
def unbind_service
  app = input[:app]
  service = input[:service, app]

  with_progress(
      "Unbinding #{c(service.name, :name)} from #{c(app.name, :name)}") do
    app.unbind(service)
  end
end

Private Instance Methods

ask_app() click to toggle source
# File lib/cf/cli/service/unbind.rb, line 31
def ask_app
  ask "Which application?", :choices => client.apps,
    :display => proc(&:name)
end
ask_service(app) click to toggle source
# File lib/cf/cli/service/unbind.rb, line 23
def ask_service(app)
  services = app.services
  fail "No bound services." if services.empty?

  ask "Which service?", :choices => services,
    :display => proc(&:name)
end