Class: Ebay::Notification

Inherits:
Object
  • Object
show all
Defined in:
lib/ebay/notification.rb

Instance Method Summary (collapse)

Constructor Details

- (Notification) initialize(post_data)



13
14
15
16
# File 'lib/ebay/notification.rb', line 13

def initialize(post_data)
  @raw_data = post_data
  parse
end

Instance Method Details

- (Object) body



22
23
24
# File 'lib/ebay/notification.rb', line 22

def body
  @body ||= parse_body
end

- (Object) document



34
35
36
# File 'lib/ebay/notification.rb', line 34

def document
  @document ||= load_document
end

- (Object) event_name



42
43
44
# File 'lib/ebay/notification.rb', line 42

def event_name
  @event_name ||= parse_event_name
end

- (Object) signature



26
27
28
# File 'lib/ebay/notification.rb', line 26

def signature
  @signature ||= parse_signature
end

- (Object) timestamp



30
31
32
# File 'lib/ebay/notification.rb', line 30

def timestamp
  @timestamp ||= parse_timestamp
end

- (Boolean) valid?



18
19
20
# File 'lib/ebay/notification.rb', line 18

def valid?
  signature == generated_signature
end

- (Object) xml_body



38
39
40
# File 'lib/ebay/notification.rb', line 38

def xml_body
  @xml_body ||= parse_xml_body
end