Oracle Collaboration Suite Discussions Java API Reference
10g (10.1.1)

Part No. B16232-01


oracle.discussions.sdk
Class TdStoreManager

java.lang.Object
  extended byoracle.discussions.sdk.TdStoreManager


public final class TdStoreManager
extends java.lang.Object

Entry point for all oracle discussions APIs. The TdStoreManager is used by callers to acquire an instance of a TdStore and interact with the store boards. Each TdStore is associated with a message store where discusssion message will be saved under facilities and boards.

Oracle discussions elements names have been changed in the webui compared to that of sdk portion. The existing names to the new names mapping is as shown.

Sample code snippet illustrating the usage of TdStoreManager

 //Create a discussions initial context.
 TdInitialContext tdic = new TdInitialContext(mEnv);
 //Create an instance of store manager.
 TdStoreManager s_tdStoreMgr = TdStoreManager.createInstance(tdic);
 //Retrieve store factory from the store manager.
 TdStoreFactory s_tdsf = s_tdStoreMgr.getTdStoreFactory();
 
Since:
OCS 10.1.1
See Also:
TdStore.java, TdUserFactory.java, TdLoggerFactory.java, CacheManager.java

Method Summary
void close()
Closes the resources associated with this store manager.
static TdStoreManager createInstance(TdInitialContext tdic)
Returns a new instance of the TdStoreManager initialized with the supplied initial context parameters.
TdStoreFactory getTdStoreFactory()
Returns a TdStoreFactory configured for a discussions store.
TdStoreFactory getTdStoreFactory(java.lang.String midtierInstance)
Returns a TdStoreFactory configured for a Discussions Store based on the supplied domain.

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Detail

createInstance

public static TdStoreManager createInstance(TdInitialContext tdic)
                                     throws TdException
Returns a new instance of the TdStoreManager initialized with the supplied initial context parameters.
Parameters:
tdic - Discussions initial Context
Throws:
TdException

getTdStoreFactory

public TdStoreFactory getTdStoreFactory()
                                 throws TdException
Returns a TdStoreFactory configured for a discussions store. TdStoreFactory returned is determined following these rules.
  1. If the email address of the internal Discussions admin account is supplied, the associated store will be used.
  2. If the midtier instance is supplied, the code will look up the OCS Service Registry and determine the Discussions Store associated with this midtier instance.
  3. If a email domain is supplied, then a Discussions Store associated with this domain will be used.
Returns:
TdStoreFactory
Throws:
TdException

getTdStoreFactory

public TdStoreFactory getTdStoreFactory(java.lang.String midtierInstance)
                                 throws TdException
Returns a TdStoreFactory configured for a Discussions Store based on the supplied domain.
Parameters:
midtierInstance - Discussions instance name
Returns:
TdStoreFactory
Throws:
TD_MIDTIER_NOT_CONFIGURED - if no Discussions Store has been configured under the supplied midtier instance
TdException

close

public void close()
           throws TdException
Closes the resources associated with this store manager.

Also resets teh boolean flag indicating that the resources will have to be initialized again when the first user logs in.

Throws:
TdException

Copyright © 2005, Oracle. All rights reserved.