|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.electrocodeogram.cpc.core.api.hub.event.CPCEvent org.electrocodeogram.cpc.core.api.hub.event.EclipseEvent
public abstract class EclipseEvent
Abstract parent class for all CPC Events which are created by Eclipse sensors.
CPCEvent
Field Summary | |
---|---|
protected boolean |
fileLocatedInWorkspace
|
protected boolean |
fileLocatedInWorkspaceCached
|
protected java.lang.String |
filePath
|
protected java.lang.String |
project
|
protected boolean |
supportedFile
|
protected boolean |
supportedFileCached
|
protected java.lang.String |
user
|
Constructor Summary | |
---|---|
EclipseEvent(java.lang.String user,
java.lang.String project)
Creates a new EclipseEvent instance. |
Method Summary | |
---|---|
java.lang.String |
getFilePath()
Retrieves the project relative file path for this event. |
java.lang.String |
getProject()
Retrieves the project name for this event. |
java.lang.String |
getUser()
Retrieves username of the currently logged in user. |
boolean |
isFileLocatedInWorkspace()
Caching convenience method which yields the same result as CoreFileUtils.isFileLocatedInWorkspace(String, String) . |
boolean |
isSupportedFile()
Caching convenience method which yields the same result as CoreConfigurationUtils.isSupportedFile(String, String) . |
boolean |
isValid()
Checks if this event has been fully initialised. |
void |
setFilePath(java.lang.String filePath)
Sets the project relative file path for this event. |
protected java.lang.String |
subToString()
Can be called by sub classes in order to obtain a string which can be included in their toString() output. |
Methods inherited from class org.electrocodeogram.cpc.core.api.hub.event.CPCEvent |
---|
checkSeal, clone, compareTo, getCreationTime, seal, toString |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.String user
protected java.lang.String project
protected java.lang.String filePath
protected boolean supportedFile
protected boolean supportedFileCached
protected boolean fileLocatedInWorkspace
protected boolean fileLocatedInWorkspaceCached
Constructor Detail |
---|
public EclipseEvent(java.lang.String user, java.lang.String project)
EclipseEvent
instance.
user
- username of current user, never null.project
- name of project, never null.Method Detail |
---|
public java.lang.String getUser()
public java.lang.String getProject()
public java.lang.String getFilePath()
public void setFilePath(java.lang.String filePath)
filePath
- project relative file path, never null.public boolean isSupportedFile()
CoreConfigurationUtils.isSupportedFile(String, String)
.
This method is thread safe.
CoreConfigurationUtils.isSupportedFile(String, String)
public boolean isFileLocatedInWorkspace()
CoreFileUtils.isFileLocatedInWorkspace(String, String)
.
CoreFileUtils.isFileLocatedInWorkspace(String, String)
public boolean isValid()
CPCEvent
Subclasses should override this method but should never return true. Instead they should delegate to the super class implementation once all validity checks on their level have passed.
The CPCEvent.isValid()
implementation always returns true.
isValid
in class CPCEvent
IEventHubRegistry.dispatch(CPCEvent)
protected java.lang.String subToString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |