|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectByteArrayTransfer
fable.gui.FableComponentTransfer
public class FableComponentTransfer
This class is about data-transfer between data-sender and data-receiver.
The data format is "String", ID of FableComponent.
In general, this class is used for Drag & Drop action.
ex>> 0 1 3 means zeroth -> first -> and then third.
Sender sends this string, (or sometimes strings) to receiver,
and receiver will parse received string(s) to
get the actual FableComponent.
FableComponent
,
FableManager
Constructor Summary | |
---|---|
FableComponentTransfer()
|
Method Summary | |
---|---|
static FableComponentTransfer |
getInstance(FableManager fbm)
This will return a static variable "instance" with provided FableManager. |
protected int[] |
getTypeIds()
|
protected java.lang.String[] |
getTypeNames()
|
protected void |
javaToNative(java.lang.Object inputObject,
TransferData transferData)
javeToNative: make an out-stream of the combination of type and ID. |
protected java.lang.Object |
nativeToJava(TransferData transferData)
nativeToJave: takes an input-stream, and then parse it. --------------------------------------------------------------------- (1) If type is "normal", then it will just return object of that type. (2) If type is "PseudoFeed', then it will return a new PseudoFeed with articles. line 3: 1st article -> extracted from FableManager, by ID. line 4: 2nd article -> extracted from FableManager, by ID. .... line last: last article -> extracted from FableManager, by ID. all these articles can be "packed" into PseudoFeed. --------------------------------------------------------------------- |
void |
setFableManager(FableManager fbm)
Set the FableManager of the instance. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FableComponentTransfer()
Method Detail |
---|
public static FableComponentTransfer getInstance(FableManager fbm)
fbm
-
public void setFableManager(FableManager fbm)
fbm
- protected int[] getTypeIds()
protected java.lang.String[] getTypeNames()
protected void javaToNative(java.lang.Object inputObject, TransferData transferData)
inputObject
- input objecttransferData
- protected java.lang.Object nativeToJava(TransferData transferData)
transferData
- the data that will be decoded.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |