|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.james.mailrepository.javamail.FolderGateKeeperImpl
public class FolderGateKeeperImpl
offers access to an underlaying Folder and manages open/close operations.
The FolderGateKeeper can be handed over to different threads.
FolderGateKeeper| Constructor Summary | |
|---|---|
FolderGateKeeperImpl(FolderInterface folder,
StoreGateKeeper storeGateKeeper)
|
|
| Method Summary | |
|---|---|
void |
create(int holds_folders)
|
boolean |
exists()
|
void |
free()
decrements count of users and closes folder if 0 and folder is open. |
FolderInterface |
getFolder()
Gets the Folder and don't care whether it is open or closed. |
java.lang.String |
getFullName()
|
FolderInterface |
getOpenFolder()
Gets the Folder and opens it, if necessary |
int |
getUseCount()
used to test whether everyone has freed it |
void |
renameTo(javax.mail.Folder destination)
|
void |
renameTo(java.lang.String newName)
|
void |
use()
increments count of users |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FolderGateKeeperImpl(FolderInterface folder,
StoreGateKeeper storeGateKeeper)
| Method Detail |
|---|
public void use()
FolderGateKeeper
use in interface FolderGateKeeperFolderGateKeeper.use()
public void free()
throws javax.mail.MessagingException
FolderGateKeeper
free in interface FolderGateKeeperjavax.mail.MessagingException - if something went wrong closing the FolderFolderGateKeeper.free()
public FolderInterface getOpenFolder()
throws javax.mail.MessagingException
FolderGateKeeper
getOpenFolder in interface FolderGateKeeperjavax.mail.MessagingException - if something went wron opening the FolderFolderGateKeeper.getOpenFolder()public int getUseCount()
FolderGateKeeper
getUseCount in interface FolderGateKeeperFolderGateKeeper.getUseCount()public FolderInterface getFolder()
FolderGateKeeper
getFolder in interface FolderGateKeeperFolderGateKeeper.getFolder()
public java.lang.String getFullName()
throws javax.mail.MessagingException
getFullName in interface FolderGateKeeperjavax.mail.MessagingExceptionFolderGateKeeper.getFullName()
public void create(int holds_folders)
throws javax.mail.MessagingException
create in interface FolderGateKeeperjavax.mail.MessagingExceptionFolderGateKeeper.create(int)
public boolean exists()
throws javax.mail.MessagingException
exists in interface FolderGateKeeperjavax.mail.MessagingExceptionFolderGateKeeper.exists()
public void renameTo(javax.mail.Folder destination)
throws javax.mail.MessagingException
renameTo in interface FolderGateKeeperjavax.mail.MessagingExceptionFolderGateKeeper.renameTo(javax.mail.Folder)
public void renameTo(java.lang.String newName)
throws javax.mail.MessagingException
renameTo in interface FolderGateKeeperjavax.mail.MessagingExceptionFolderGateKeeper.renameTo(java.lang.String)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||