Class: Reve::Classes::Notification

Inherits:
Object
  • Object
show all
Defined in:
lib/reve/classes.rb

Overview

Represents a Notification for Reve::API#personal_notifications Attributes

  • id ( Fixnum ) - The unique notification ID number.

  • notification_type_id ( Fixnum ) - The notification type indicates what has happened but not who performed the action in question nor upon whom the action was performed. See wiki.eve-id.net/APIv2_Char_Notifications_XML for a list of ids

  • sender_id ( Fixnum ) - TThe ID of the entity that sent the notification.

  • send_date ( Time ) - The ID of the entity that sent the notification.

  • read ( Boolean ) - Whether the notification has been read in the EVE client. This does not change when you get it through the API.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(elem) ⇒ Notification

:nodoc:



1517
1518
1519
1520
1521
1522
1523
# File 'lib/reve/classes.rb', line 1517

def initialize(elem) #:nodoc:
  @id = elem['notificationID'].to_i
  @notification_type_id = elem['typeID'].to_i
  @sender_id = elem['senderID'].to_i
  @send_date = elem['sentDate'].to_time
  @read = elem['read'] == '1'
end

Instance Attribute Details

#idObject (readonly)

Returns the value of attribute id.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def id
  @id
end

#nameObject (readonly)

Returns the value of attribute name.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def name
  @name
end

#notification_type_idObject (readonly)

Returns the value of attribute notification_type_id.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def notification_type_id
  @notification_type_id
end

#readObject (readonly)

Returns the value of attribute read.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def read
  @read
end

#send_dateObject (readonly)

Returns the value of attribute send_date.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def send_date
  @send_date
end

#sender_idObject (readonly)

Returns the value of attribute sender_id.



1516
1517
1518
# File 'lib/reve/classes.rb', line 1516

def sender_id
  @sender_id
end