Class: Google::Apis::SecuresourcemanagerV1::PullRequest

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/securesourcemanager_v1/classes.rb,
lib/google/apis/securesourcemanager_v1/representations.rb,
lib/google/apis/securesourcemanager_v1/representations.rb

Overview

Metadata of a PullRequest. PullRequest is the request from a user to merge a branch (head) into another branch (base).

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ PullRequest

Returns a new instance of PullRequest.



1847
1848
1849
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1847

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#baseGoogle::Apis::SecuresourcemanagerV1::Branch

Branch represents a branch involved in a pull request. Corresponds to the JSON property base



1801
1802
1803
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1801

def base
  @base
end

#bodyString

Optional. The pull request body. Provides a detailed description of the changes. Corresponds to the JSON property body

Returns:

  • (String)


1807
1808
1809
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1807

def body
  @body
end

#close_timeString

Output only. Close timestamp (if closed or merged). Cleared when pull request is re-opened. Corresponds to the JSON property closeTime

Returns:

  • (String)


1813
1814
1815
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1813

def close_time
  @close_time
end

#create_timeString

Output only. Creation timestamp. Corresponds to the JSON property createTime

Returns:

  • (String)


1818
1819
1820
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1818

def create_time
  @create_time
end

#headGoogle::Apis::SecuresourcemanagerV1::Branch

Branch represents a branch involved in a pull request. Corresponds to the JSON property head



1823
1824
1825
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1823

def head
  @head
end

#nameString

Output only. A unique identifier for a PullRequest. The number appended at the end is generated by the server. Format: projects/project/locations/ location/repositories/repository/pullRequests/pull_request_id` Corresponds to the JSON propertyname`

Returns:

  • (String)


1830
1831
1832
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1830

def name
  @name
end

#stateString

Output only. State of the pull request (open, closed or merged). Corresponds to the JSON property state

Returns:

  • (String)


1835
1836
1837
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1835

def state
  @state
end

#titleString

Required. The pull request title. Corresponds to the JSON property title

Returns:

  • (String)


1840
1841
1842
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1840

def title
  @title
end

#update_timeString

Output only. Last updated timestamp. Corresponds to the JSON property updateTime

Returns:

  • (String)


1845
1846
1847
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1845

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
# File 'lib/google/apis/securesourcemanager_v1/classes.rb', line 1852

def update!(**args)
  @base = args[:base] if args.key?(:base)
  @body = args[:body] if args.key?(:body)
  @close_time = args[:close_time] if args.key?(:close_time)
  @create_time = args[:create_time] if args.key?(:create_time)
  @head = args[:head] if args.key?(:head)
  @name = args[:name] if args.key?(:name)
  @state = args[:state] if args.key?(:state)
  @title = args[:title] if args.key?(:title)
  @update_time = args[:update_time] if args.key?(:update_time)
end