Class: TeamcityRestClient::BuildType

Inherits:
Struct
  • Object
show all
Defined in:
lib/teamcity-rest-client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#hrefObject

Returns the value of attribute href

Returns:

  • (Object)

    the current value of href



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def href
  @href
end

#idObject

Returns the value of attribute id

Returns:

  • (Object)

    the current value of id



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def id
  @id
end

#nameObject

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def name
  @name
end

#project_idObject

Returns the value of attribute project_id

Returns:

  • (Object)

    the current value of project_id



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def project_id
  @project_id
end

#project_nameObject

Returns the value of attribute project_name

Returns:

  • (Object)

    the current value of project_name



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def project_name
  @project_name
end

#teamcityObject

Returns the value of attribute teamcity

Returns:

  • (Object)

    the current value of teamcity



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def teamcity
  @teamcity
end

#web_urlObject

Returns the value of attribute web_url

Returns:

  • (Object)

    the current value of web_url



85
86
87
# File 'lib/teamcity-rest-client.rb', line 85

def web_url
  @web_url
end

Instance Method Details

#builds(options = {}) ⇒ Object



86
87
88
# File 'lib/teamcity-rest-client.rb', line 86

def builds options = {}
  teamcity.builds({:buildType => "id:#{id}"}.merge(options))
end

#latest_buildObject



89
90
91
# File 'lib/teamcity-rest-client.rb', line 89

def latest_build
  builds(:count => 1)[0]
end