de.unikassel.android.sdcframework.util
Class AbstractTimeProviderEvent

Package class diagram package AbstractTimeProviderEvent
java.lang.Object
  extended by de.unikassel.android.sdcframework.util.AbstractTimeProviderEvent
All Implemented Interfaces:
BroadcastableEvent, ObservableEvent, TimeProviderEvent
Direct Known Subclasses:
TimeErrorEvent, TimeUpdateEvent

public abstract class AbstractTimeProviderEvent
extends Object
implements BroadcastableEvent, TimeProviderEvent

Abstract base class for time provider events


Field Summary
protected  long ts
          The time stamp in UTC.
static String TS
          The intent identifier for the time stamp field
 
Constructor Summary
AbstractTimeProviderEvent(Intent intent)
          Constructor
AbstractTimeProviderEvent(long ts)
          Constructor
 
Method Summary
protected abstract  String getAction()
          Getter for the intent action.
 Intent getIntent()
          Getter for an intent representation
 long getTimeStamp()
          Getter for the event time stamp.
protected abstract  void putAdditionalExtras(Intent intent)
          Method to add extra information for intent creation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.unikassel.android.sdcframework.util.facade.TimeProviderEvent
isSynced
 

Field Detail

TS

public static final String TS
The intent identifier for the time stamp field

See Also:
Constant Field Values

ts

protected final long ts
The time stamp in UTC.

Constructor Detail

AbstractTimeProviderEvent

public AbstractTimeProviderEvent(long ts)
Constructor

Parameters:
ts - the time stamp.

AbstractTimeProviderEvent

public AbstractTimeProviderEvent(Intent intent)
Constructor

Parameters:
intent - the intent to create from
Method Detail

getIntent

public final Intent getIntent()
Description copied from interface: BroadcastableEvent
Getter for an intent representation

Specified by:
getIntent in interface BroadcastableEvent
Returns:
the Intent representation of this LogEvent

putAdditionalExtras

protected abstract void putAdditionalExtras(Intent intent)
Method to add extra information for intent creation.

Parameters:
intent - the intent to add extras to

getAction

protected abstract String getAction()
Getter for the intent action.

Returns:
the intent action.

getTimeStamp

public long getTimeStamp()
Description copied from interface: TimeProviderEvent
Getter for the event time stamp.

Specified by:
getTimeStamp in interface TimeProviderEvent
Returns:
the time stamp of the event