Snapd.Notice¶
- Subclasses:
 None
Methods¶
- Inherited:
 - Structs:
 
  | 
|
  | 
|
  | 
|
  | 
Virtual Methods¶
- Inherited:
 
Properties¶
Name  | 
Type  | 
Flags  | 
Short Description  | 
|---|---|---|---|
r/w/co  | 
Time (in ms) since one of these last occurred until we should drop the notice  | 
||
r/w/co  | 
Time this notice first occurred  | 
||
r/w/co  | 
ID of notice  | 
||
r/w/co  | 
Key of notice  | 
||
r/w/co  | 
Data for this notice  | 
||
r/w/co  | 
Time this notice last occurred  | 
||
r/w/co  | 
Time this notice last ocurred, in string format and with nanosecond accuracy  | 
||
r/w/co  | 
Time this notice was last repeated  | 
||
r/w/co  | 
Type of notice  | 
||
r/w/co  | 
Number of time one of these notices has occurred  | 
||
r/w/co  | 
Time (in ms) after one of these was last repeated should we allow it to repeat  | 
||
r/w/co  | 
UserID of the user who may view this notice (  | 
Signals¶
- Inherited:
 
Fields¶
- Inherited:
 
Class Details¶
- class Snapd.Notice(**kwargs)¶
 - Bases:
 - Abstract:
 No
- Structure:
 
Snapd.Noticecontains information on a notification element.New in version 1.65.
- compare_last_occurred(notice_to_compare)¶
 - Parameters:
 notice_to_compare (
Snapd.Notice) – anotherSnapd.Notice.- Returns:
 -1 if the first one is before the second one; 0 if both are the same time instant, and 1 if the first one is after the second one.
- Return type:
 
Compare the last_occurred fields (and the last_occurred_nanosecond if available) of both notices, and returns whether the first one is before, same or after the second one.
New in version 1.66.
- get_expire_after()¶
 - Returns:
 a #GTimeSpan.
- Return type:
 
Get the time interval after this notification can expire.
New in version 1.65.
- get_first_occurred()¶
 - Returns:
 - Return type:
 
Get the time this notification first occurred.
New in version 1.65.
Deprecated since version 1.66: Use
Snapd.Notice.get_first_occurred2()
- get_first_occurred2()¶
 - Returns:
 - Return type:
 
Get the time this notification first occurred.
New in version 1.66.
- get_key()¶
 - Returns:
 a string with the key.
- Return type:
 
Get the notice-id or the instance-name, depending on the type.
New in version 1.65.
- get_last_data()¶
 - 
Get the data of the notice.
New in version 1.65.
Deprecated since version 1.66: Use
Snapd.Notice.get_last_data2() 
- get_last_data2()¶
 - 
Get the data of the notice.
New in version 1.66.
 
- get_last_occurred()¶
 - Returns:
 - Return type:
 
Get the time this notification last occurred.
New in version 1.65.
Deprecated since version 1.66: Use
Snapd.Notice.get_last_occurred2()
- get_last_occurred2()¶
 - Returns:
 - Return type:
 
Get the time this notification last occurred.
New in version 1.66.
- get_last_occurred_nanoseconds()¶
 - Returns:
 the nanosecond value between 0 and 999999999, or -1 if no nanosecond value was set.
- Return type:
 
Get the nanoseconds value of *last-occurred*, exactly as sent by snapd. Useful when combined with
Snapd.Client.notices_set_since_nanoseconds, and used internally bySnapd.Client.notices_set_after_notice, to ensure the maximum possible precission when dealing with timestamps.New in version 1.66.
- get_last_repeated()¶
 - Returns:
 - Return type:
 
Get the time this notification last repeated.
New in version 1.65.
Deprecated since version 1.66: Use
Snapd.Notice.get_last_repeated2()
- get_last_repeated2()¶
 - Returns:
 - Return type:
 
Get the time this notification last repeated.
New in version 1.66.
- get_notice_type()¶
 - Returns:
 the type of notice.
- Return type:
 
Gets the type of notice this is.
New in version 1.65.
- get_occurrences()¶
 - Returns:
 a count.
- Return type:
 
Get the number of times that this notification has been triggered.
New in version 1.65.
- get_repeat_after()¶
 - Returns:
 a #GTimeSpan.
- Return type:
 
Get the time interval after this notification can be repeated.
New in version 1.65.
Property Details¶
- Snapd.Notice.props.expire_after¶
 - Name:
 expire-after- Type:
 - Default Value:
 0- Flags:
 
Time (in ms) since one of these last occurred until we should drop the notice
- Snapd.Notice.props.first_occurred¶
 - Name:
 first-occurred- Type:
 - Default Value:
 - Flags:
 
Time this notice first occurred
- Snapd.Notice.props.id¶
 - Name:
 id- Type:
 - Default Value:
 - Flags:
 
ID of notice
- Snapd.Notice.props.key¶
 - Name:
 key- Type:
 - Default Value:
 - Flags:
 
Key of notice
- Snapd.Notice.props.last_data¶
 - Name:
 last-data- Type:
 - Default Value:
 - Flags:
 
Data for this notice
- Snapd.Notice.props.last_occurred¶
 - Name:
 last-occurred- Type:
 - Default Value:
 - Flags:
 
Time this notice last occurred
- Snapd.Notice.props.last_occurred_nanoseconds¶
 - Name:
 last-occurred-nanoseconds- Type:
 - Default Value:
 -1- Flags:
 
Time this notice last ocurred, in string format and with nanosecond accuracy
- Snapd.Notice.props.last_repeated¶
 - Name:
 last-repeated- Type:
 - Default Value:
 - Flags:
 
Time this notice was last repeated
- Snapd.Notice.props.notice_type¶
 - Name:
 notice-type- Type:
 - Default Value:
 0- Flags:
 
Type of notice
- Snapd.Notice.props.occurrences¶
 - Name:
 occurrences- Type:
 - Default Value:
 -1- Flags:
 
Number of time one of these notices has occurred
- Snapd.Notice.props.repeat_after¶
 - Name:
 repeat-after- Type:
 - Default Value:
 0- Flags:
 
Time (in ms) after one of these was last repeated should we allow it to repeat