java.lang.Objectcom.realtime.crossfire.jxclient.faces.AbstractFaceQueue
com.realtime.crossfire.jxclient.faces.FacesQueue
public class FacesQueue
The main FaceQueue for loading faces. It first delegates to a FileCacheFaceQueue to load the face from the disk cache. If this fails, the
face is requested through a AskfaceFaceQueue.
| Field Summary | |
|---|---|
private AskfaceFaceQueue |
askfaceFaceQueue
The AskfaceFaceQueue instance used to query faces from the
Crossfire server. |
private FaceQueueListener |
askfaceFaceQueueListener
The FaceQueueListener attached to askfaceFaceQueue. |
private FileCacheFaceQueue |
fileCacheFaceQueue
The FileCacheFaceQueue instance used to load faces from the file
cache. |
private FaceQueueListener |
fileCacheFaceQueueListener
The FaceQueueListener attached to fileCacheFaceQueue. |
| Constructor Summary | |
|---|---|
FacesQueue(CrossfireServerConnection crossfireServerConnection,
ImageCache imageCacheOriginal,
ImageCache imageCacheScaled,
ImageCache imageCacheMagicMap)
Creates a new instance. |
|
| Method Summary | |
|---|---|
AskfaceFaceQueue |
getAskfaceQueue()
Returns the AskfaceFaceQueue instance. |
void |
loadFace(Face face)
Request a face. |
void |
reset()
Reset the processing: forget about pending faces. |
| Methods inherited from class com.realtime.crossfire.jxclient.faces.AbstractFaceQueue |
|---|
addFaceQueueListener, fireFaceFailed, fireFaceLoaded, removeFaceQueueListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
@NotNull private final AskfaceFaceQueue askfaceFaceQueue
AskfaceFaceQueue instance used to query faces from the
Crossfire server.
@NotNull private final FaceQueueListener askfaceFaceQueueListener
FaceQueueListener attached to askfaceFaceQueue.
@NotNull private final FileCacheFaceQueue fileCacheFaceQueue
FileCacheFaceQueue instance used to load faces from the file
cache.
@NotNull private final FaceQueueListener fileCacheFaceQueueListener
FaceQueueListener attached to fileCacheFaceQueue.
| Constructor Detail |
|---|
public FacesQueue(@Nullable
CrossfireServerConnection crossfireServerConnection,
@NotNull
ImageCache imageCacheOriginal,
@NotNull
ImageCache imageCacheScaled,
@NotNull
ImageCache imageCacheMagicMap)
crossfireServerConnection - the server connection for sending
askface commandsimageCacheOriginal - the image cache used for loading original image
filesimageCacheScaled - the image cache used for loading scaled image
filesimageCacheMagicMap - the image cache used for loading magic map
image files| Method Detail |
|---|
@NotNull public AskfaceFaceQueue getAskfaceQueue()
AskfaceFaceQueue instance.
public void loadFace(@NotNull
Face face)
FaceQueueListener.faceLoaded(Face, FaceImages) or FaceQueueListener.faceFailed(Face) for the face. Faces re-requested
while still processing may be notified only once.
face - the requested facepublic void reset()