|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectccs.cpc.Viewer
public abstract class Viewer
A "viewer" is the commonality of a plug-in and an external helper application.
(NOTE: the above nomenclature is rather new. Until recently these two were
called internal and external viewers respectively.) Note that a "viewer" is
not necessarily passive - it may change its data - and isn't necessarily
even a viewer! (Now you can see why we changed the notation.) This class
represents static information about the "viewer". Runtime / lifecycle
is handled by ViewerRuntime
and its subclasses.
Nested Class Summary | |
---|---|
static class |
Viewer.FileCap
File handling capability. |
Field Summary | |
---|---|
protected boolean |
editness
|
protected Viewer.FileCap |
fileness
|
Constructor Summary | |
---|---|
protected |
Viewer(java.lang.String name,
boolean editness,
Viewer.FileCap fileness)
|
Method Summary | |
---|---|
int |
compareTo(Viewer v)
|
static Viewer |
createFrom(java.io.DataInputStream dis,
int marshalver)
Create a viewer from stored data |
boolean |
getEditness()
Whether the viewer edits files. |
Viewer.FileCap |
getFileness()
The viewer's capacity to be launched with or without a file (or either). |
abstract java.lang.String |
getID()
Return a unique ID for this viewer, unique at least within the current profile. |
java.lang.String |
getName()
Return the viewer's name. |
abstract ViewerRuntime |
getRuntime(PluginCallback callback,
VFile target)
create a suitable runtime instance of this viewer, viewing a given target. |
void |
marshalTo(java.io.DataOutputStream dos)
|
protected abstract void |
submarshal(java.io.DataOutputStream dos)
|
void |
validate(java.awt.Frame parent)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean editness
protected Viewer.FileCap fileness
Constructor Detail |
---|
protected Viewer(java.lang.String name, boolean editness, Viewer.FileCap fileness)
Method Detail |
---|
public final void marshalTo(java.io.DataOutputStream dos) throws java.io.IOException
java.io.IOException
public abstract java.lang.String getID()
protected abstract void submarshal(java.io.DataOutputStream dos) throws java.io.IOException
java.io.IOException
public static final Viewer createFrom(java.io.DataInputStream dis, int marshalver) throws java.io.IOException
dis
- The stream of previously stored data.marshalver
- the marshal version of the ProfileModel object this is stored in.
java.io.IOException
public java.lang.String getName()
public boolean getEditness()
public Viewer.FileCap getFileness()
public abstract ViewerRuntime getRuntime(PluginCallback callback, VFile target) throws java.io.IOException
java.io.IOException
public void validate(java.awt.Frame parent) throws ccs.LoseException
ccs.LoseException
public int compareTo(Viewer v)
compareTo
in interface java.lang.Comparable<Viewer>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |