This content has been marked as final.
Show 2 replies
-
1. Re: Why not TreeCacheMBean::get(FQN) or TreeCacheMBean::get(
ticklishturtletoe Jun 28, 2005 11:52 AM (in response to ticklishturtletoe)I still have the same question, but I've implemented an alternative approach that seems to work just fine:
Set nodeKeySet = treeCache.get(fqn); MyObject myObject = null; if (nodeKeySet != null && nodeKeySet.size() > 0) { // I have my reasons for preferring a list to a Set List nodeKeyList = new ArrayList(nodeKeySet); String key = ""; // Not precisely the termination condition... for (int i = 0; i < nodeKeyList.size(); i++) { key = (String)nodeKeyList.get(i); myObject = (MyObject)treeCache.get(fqn, key); ... } ... }
Please let me know if others out there have similar logic or if I've done something totally bizarre or wrong.
TIA,
TTT -
2. Re: Why not TreeCacheMBean::get(FQN) or TreeCacheMBean::get(
belaban Jun 29, 2005 6:24 AM (in response to ticklishturtletoe)I have added those 2 methods. Note though that we may deprecate direct access to a Node in the future since you're bypassing the interceptors...
Also, in 1.3, we will change TreeCache (the class) into Cache (the interface).