Class: Vx::ServiceConnector::Model::Payload
- Inherits:
-
Struct
- Object
- Struct
- Vx::ServiceConnector::Model::Payload
- Defined in:
- lib/vx/service_connector/model.rb
Instance Attribute Summary collapse
-
#author ⇒ Object
Returns the value of attribute author.
-
#author_email ⇒ Object
Returns the value of attribute author_email.
-
#branch ⇒ Object
Returns the value of attribute branch.
-
#branch_label ⇒ Object
Returns the value of attribute branch_label.
-
#message ⇒ Object
Returns the value of attribute message.
-
#pull_request? ⇒ Object
Returns the value of attribute pull_request?.
-
#pull_request_number ⇒ Object
Returns the value of attribute pull_request_number.
-
#sha ⇒ Object
Returns the value of attribute sha.
-
#skip ⇒ Object
Returns the value of attribute skip.
-
#web_url ⇒ Object
Returns the value of attribute web_url.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#author ⇒ Object
Returns the value of attribute author
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def @author end |
#author_email ⇒ Object
Returns the value of attribute author_email
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def @author_email end |
#branch ⇒ Object
Returns the value of attribute branch
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def branch @branch end |
#branch_label ⇒ Object
Returns the value of attribute branch_label
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def branch_label @branch_label end |
#message ⇒ Object
Returns the value of attribute message
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def @message end |
#pull_request? ⇒ Object
Returns the value of attribute pull_request?
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16
def pull_request?
@pull_request?
end
|
#pull_request_number ⇒ Object
Returns the value of attribute pull_request_number
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def pull_request_number @pull_request_number end |
#sha ⇒ Object
Returns the value of attribute sha
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def sha @sha end |
#skip ⇒ Object
Returns the value of attribute skip
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def skip @skip end |
#web_url ⇒ Object
Returns the value of attribute web_url
16 17 18 |
# File 'lib/vx/service_connector/model.rb', line 16 def web_url @web_url end |
Class Method Details
.from_hash(params) ⇒ Object
35 36 37 38 39 40 41 |
# File 'lib/vx/service_connector/model.rb', line 35 def from_hash(params) payload = Payload.new payload.members.each do |m| payload[m] = params.key?(m) ? params[m] : params[m.to_s] end payload end |
Instance Method Details
#ignore? ⇒ Boolean
30 31 32 |
# File 'lib/vx/service_connector/model.rb', line 30 def ignore? skip || .to_s =~ /#{PAYLOAD_IGNORE_RE}/ end |
#to_hash ⇒ Object
28 |
# File 'lib/vx/service_connector/model.rb', line 28 def to_hash ; to_h end |