Package Torello.Browser
Class BackgroundService.BackgroundServiceEvent
- java.lang.Object
-
- Torello.Java.JSON.BaseType
-
- Torello.Browser.BackgroundService.BackgroundServiceEvent
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- BackgroundService
public static class BackgroundService.BackgroundServiceEvent extends BaseType implements java.io.Serializable
[No Description Provided by Google]
- See Also:
- Serialized Form
Hi-Lited Source-Code:- View Here: Torello/Browser/BackgroundService.java
- Open New Browser-Tab: Torello/Browser/BackgroundService.java
File Size: 6,193 Bytes Line Count: 129 '\n' Characters Found
-
-
Field Summary
Serializable ID Modifier and Type Field protected static long
serialVersionUID
For Object Serialization.Type Properties Modifier and Type Field BackgroundService.EventMetadata[]
eventMetadata
A list of event-specific information.String
eventName
A description of the event.String
instanceId
An identifier that groups related events together.String
origin
The origin this event belongs to.String
service
The Background Service this event belongs to.String
serviceWorkerRegistrationId
The Service Worker ID that initiated the event.Number
timestamp
Timestamp of the event (in seconds).
-
Constructor Summary
Constructors Constructor Description BackgroundServiceEvent(Number timestamp, String origin, String serviceWorkerRegistrationId, String service, String eventName, String instanceId, BackgroundService.EventMetadata[] eventMetadata)
ConstructorBackgroundServiceEvent(JsonObject jo)
JSON Object Constructor
-
Method Summary
Generate Array that Indicates which Parameter are Optional Modifier and Type Method boolean[]
optionals()
Implementing this method allows sub-classes to specify which JSON Properties may be absent or null.Methods: class java.lang.Object Modifier and Type Method boolean
equals(Object other)
Checks whether'this'
equals an input Java-Object
int
hashCode()
Generates a Hash-Code for'this'
instance
-
-
-
Field Detail
-
serialVersionUID
protected static final long serialVersionUID
For Object Serialization. java.io.Serializable- See Also:
- Constant Field Values
-
timestamp
public final java.lang.Number timestamp
Timestamp of the event (in seconds).
-
origin
public final java.lang.String origin
The origin this event belongs to.
-
serviceWorkerRegistrationId
public final java.lang.String serviceWorkerRegistrationId
The Service Worker ID that initiated the event.
-
service
public final java.lang.String service
The Background Service this event belongs to.
-
eventName
public final java.lang.String eventName
A description of the event.
-
instanceId
public final java.lang.String instanceId
An identifier that groups related events together.
-
eventMetadata
public final BackgroundService.EventMetadata[] eventMetadata
A list of event-specific information.
-
-
Constructor Detail
-
BackgroundServiceEvent
public BackgroundServiceEvent (java.lang.Number timestamp, java.lang.String origin, java.lang.String serviceWorkerRegistrationId, java.lang.String service, java.lang.String eventName, java.lang.String instanceId, BackgroundService.EventMetadata[] eventMetadata)
Constructor- Parameters:
timestamp
- Timestamp of the event (in seconds).origin
- The origin this event belongs to.serviceWorkerRegistrationId
- The Service Worker ID that initiated the event.service
- The Background Service this event belongs to.eventName
- A description of the event.instanceId
- An identifier that groups related events together.eventMetadata
- A list of event-specific information.
-
BackgroundServiceEvent
public BackgroundServiceEvent(JsonObject jo)
JSON Object Constructor- Parameters:
jo
- A Json-Object having data about an instance of'BackgroundServiceEvent'
.
-
-
Method Detail
-
optionals
public boolean[] optionals()
Description copied from class:BaseType
Implementing this method allows sub-classes to specify which JSON Properties may be absent or null. When binding aJsonObject
to a Java-Object, if some of the expected fields for the Java-Object map to Properties which might be left-out or omitted, then that may be indicated by setting that fields array positionTRUE
.
NOTE: This array should have a length equal to the number of fields contained by the Java Object. The first boolean in the array should specify whether the first Object Field may by absent. The second boolean should specify whether the second Object Field is optional in the JSON - and so on and so forth...
-
equals
public boolean equals(java.lang.Object other)
Checks whether'this'
equals an input Java-Object
- Overrides:
equals
in classjava.lang.Object
- Code:
- Exact Method Body:
if (other == null) return false; if (other.getClass() != this.getClass()) return false; BackgroundServiceEvent o = (BackgroundServiceEvent) other; return Objects.equals(this.timestamp, o.timestamp) && Objects.equals(this.origin, o.origin) && Objects.equals(this.serviceWorkerRegistrationId, o.serviceWorkerRegistrationId) && Objects.equals(this.service, o.service) && Objects.equals(this.eventName, o.eventName) && Objects.equals(this.instanceId, o.instanceId) && Arrays.deepEquals(this.eventMetadata, o.eventMetadata);
-
hashCode
public int hashCode()
Generates a Hash-Code for'this'
instance- Overrides:
hashCode
in classjava.lang.Object
- Code:
- Exact Method Body:
return Objects.hashCode(this.timestamp) + Objects.hashCode(this.origin) + Objects.hashCode(this.serviceWorkerRegistrationId) + Objects.hashCode(this.service) + Objects.hashCode(this.eventName) + Objects.hashCode(this.instanceId) + Arrays.deepHashCode(this.eventMetadata);
-
-