Class: Gophish::Campaign::Result
- Inherits:
-
Object
- Object
- Gophish::Campaign::Result
- Includes:
- ActiveModel::Attributes, ActiveModel::Model
- Defined in:
- lib/gophish/campaign.rb
Instance Method Summary collapse
- #clicked? ⇒ Boolean
- #inspect ⇒ Object
- #opened? ⇒ Boolean
- #reported? ⇒ Boolean
- #sent? ⇒ Boolean
- #submitted_data? ⇒ Boolean
- #to_s ⇒ Object
Instance Method Details
#clicked? ⇒ Boolean
291 292 293 |
# File 'lib/gophish/campaign.rb', line 291 def clicked? status == 'Clicked Link' end |
#inspect ⇒ Object
316 317 318 |
# File 'lib/gophish/campaign.rb', line 316 def inspect to_s end |
#opened? ⇒ Boolean
295 296 297 |
# File 'lib/gophish/campaign.rb', line 295 def opened? status == 'Email Opened' end |
#reported? ⇒ Boolean
287 288 289 |
# File 'lib/gophish/campaign.rb', line 287 def reported? reported == true end |
#sent? ⇒ Boolean
299 300 301 |
# File 'lib/gophish/campaign.rb', line 299 def sent? status == 'Email Sent' end |
#submitted_data? ⇒ Boolean
303 304 305 |
# File 'lib/gophish/campaign.rb', line 303 def submitted_data? status == 'Submitted Data' end |
#to_s ⇒ Object
307 308 309 310 311 312 313 314 |
# File 'lib/gophish/campaign.rb', line 307 def to_s attributes_hash = {} self.class.attribute_names.each do |attr_name| value = send attr_name attributes_hash[attr_name.to_sym] = value unless value.nil? end attributes_hash.to_s end |