|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.inf.container.OrganizationCache
Maintains a cache of internet domain names to WTOrganizations, and a cache of
WTOrganizations to OrgContainers.
Also handles file-based overrides of the internet domain to container mapping.
Supported API: false
Extendable: false
Nested Class Summary | |
static class |
OrganizationCache.DomainToOrgMessenger
|
private static class |
OrganizationCache.ExchangeInfo
Stores the exchange's internet domain and oid JVM Ensures thread-safe lazy initialization |
static class |
OrganizationCache.OrgToContainerMessenger
|
private static class |
OrganizationCache.RemotePlaceholder
A utility class that allows the cache to signal whether a remote call is necessary when an object is added to the local cache |
private static class |
OrganizationCache.Singleton
JVM ensures thread-safe lazy initialization of instance |
Field Summary | |
private static String |
CLASSNAME
|
private static boolean |
DEBUG
|
(package private) DirtyMap |
domainToOrg
Maps internet domain to organization oid |
(package private) OrganizationCache.DomainToOrgMessenger |
domainToOrgMessenger
|
(package private) Map |
domainToPath
Maps internet domain to container path, and vice versa |
private static String |
EVENTS
|
private static String |
EXCHANGE_PATH
|
private static DebugWriter |
LOG
|
(package private) static String |
MAPPING_FILE
|
(package private) DirtyMap |
orgToContainer
Maps organization oid to container oid |
(package private) OrganizationCache.OrgToContainerMessenger |
orgToContainerMessenger
|
(package private) Map |
pathToDomain
Maps internet domain to container path, and vice versa |
private static String |
RESOURCE
|
Constructor Summary | |
private |
OrganizationCache()
|
Method Summary | |
private void |
addListeners()
|
String[] |
getAllInternetDomains(WTContainerRef ref)
|
WTContainerRef |
getByInternetDomain(String internet_domain)
|
private WTContainerRef |
getByInternetDomainFromDirectory(String internet_domain)
Find the mapping for the given internet domain. |
private WTContainerRef |
getByInternetDomainFromFile(String internet_domain)
See if the file mappings contain an entry for the given internet domain |
private WTContainerRef |
getContainerRef(ObjectIdentifier oid)
|
String |
getExchangeDomain()
|
private ObjectIdentifier |
getId(ObjectReference ref)
|
private ObjectIdentifier |
getId(Persistable obj)
|
(package private) static OrganizationCache |
getInstance()
|
String |
getInternetDomain(WTContainerRef ref)
|
WTContainerRef |
getOrgContainer(WTOrganization org)
|
WTContainerRef |
getOrgContainer(WTPrincipalReference org)
|
private WTPrincipalReference |
getPrincipalRef(ObjectIdentifier oid)
|
(package private) boolean |
isExchangeOrganization(WTOrganization org)
|
private boolean |
isExchangeOrganization(WTPrincipalReference org)
|
private boolean |
isSourceOfExchangeDomain(WTOrganization org)
Determine if the organization is where the exchange container's internet domain is derived form. |
private boolean |
isSourceOfExchangeDomain(WTPrincipalReference org_ref)
|
private void |
loadFile()
Loads overrides from file (by default internetDomain.properties) Called from the thread-safe constructor |
private void |
postChangeIdentity(OrgContainer container,
WTContainerIdentity old_identity)
|
private void |
postCreate(OrgContainer container)
|
private void |
postModify(WTOrganization org)
|
(package private) void |
putOverride(String internet_domain,
String container_path)
WARNING: This method does not ensure thread-safety |
private void |
removeFromCache(WTOrganization org)
|
(package private) void |
removeOverride(String internet_domain)
WARNING: This method does not ensure thread-safety |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final String CLASSNAME
private static final String RESOURCE
private static final boolean DEBUG
private static final DebugWriter LOG
private static final String EVENTS
private static final String EXCHANGE_PATH
static final String MAPPING_FILE
DirtyMap domainToOrg
OrganizationCache.DomainToOrgMessenger domainToOrgMessenger
DirtyMap orgToContainer
OrganizationCache.OrgToContainerMessenger orgToContainerMessenger
Map domainToPath
Map pathToDomain
Constructor Detail |
private OrganizationCache() throws WTException
Method Detail |
static OrganizationCache getInstance() throws WTException
WTException
public WTContainerRef getByInternetDomain(String internet_domain) throws WTException
WTException
private WTContainerRef getByInternetDomainFromFile(String internet_domain) throws WTException
WTException
private WTContainerRef getByInternetDomainFromDirectory(String internet_domain) throws WTException
WTException
public String getInternetDomain(WTContainerRef ref) throws WTException
WTException
public String[] getAllInternetDomains(WTContainerRef ref) throws WTException
WTException
public String getExchangeDomain() throws WTException
WTException
public WTContainerRef getOrgContainer(WTOrganization org) throws WTException
WTException
public WTContainerRef getOrgContainer(WTPrincipalReference org) throws WTException
WTException
void putOverride(String internet_domain, String container_path)
void removeOverride(String internet_domain)
private void loadFile() throws WTException
WTException
private void addListeners()
private void postCreate(OrgContainer container) throws WTException
WTException
private void postModify(WTOrganization org) throws WTException
WTException
private void postChangeIdentity(OrgContainer container, WTContainerIdentity old_identity) throws WTException
WTException
private void removeFromCache(WTOrganization org) throws WTException
WTException
private ObjectIdentifier getId(ObjectReference ref)
private ObjectIdentifier getId(Persistable obj)
private WTContainerRef getContainerRef(ObjectIdentifier oid) throws WTException
WTException
private WTPrincipalReference getPrincipalRef(ObjectIdentifier oid) throws WTException
WTException
boolean isExchangeOrganization(WTOrganization org) throws WTException
WTException
private boolean isExchangeOrganization(WTPrincipalReference org) throws WTException
WTException
private boolean isSourceOfExchangeDomain(WTOrganization org) throws WTException
org
-
WTException
private boolean isSourceOfExchangeDomain(WTPrincipalReference org_ref) throws WTException
WTException
isSourceOfExchangeDomain(WTOrganization)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |