Author: skabashnyuk
Date: 2009-12-11 11:34:30 -0500 (Fri, 11 Dec 2009)
New Revision: 1012
Modified:
jcr/branches/1.12.0-JBC/component/core/src/main/java/org/exoplatform/services/jcr/impl/storage/jbosscache/JBossCacheStorageConnection.java
Log:
EXOJCR-199: removed depricated code
Modified:
jcr/branches/1.12.0-JBC/component/core/src/main/java/org/exoplatform/services/jcr/impl/storage/jbosscache/JBossCacheStorageConnection.java
===================================================================
---
jcr/branches/1.12.0-JBC/component/core/src/main/java/org/exoplatform/services/jcr/impl/storage/jbosscache/JBossCacheStorageConnection.java 2009-12-11
16:34:14 UTC (rev 1011)
+++
jcr/branches/1.12.0-JBC/component/core/src/main/java/org/exoplatform/services/jcr/impl/storage/jbosscache/JBossCacheStorageConnection.java 2009-12-11
16:34:30 UTC (rev 1012)
@@ -532,98 +532,8 @@
}
/**
- * @deprecated version of getItemData(NodeData parentData, QPathEntry name) .
- * Should be removed
* {@inheritDoc}
- *
*/
- @Deprecated
- public ItemData getItemData_old(NodeData parentData, QPathEntry name) throws
RepositoryException,
- IllegalStateException
- {
- // try as Node
- // TODO validate ParentNotFound for both Node and Property
- Node<Serializable, Object> childNode =
nodesRoot.getChild(makeChildNodeFqn(parentData.getIdentifier(), name));
- if (childNode != null)
- {
- String nodeId = (String)childNode.get(ITEM_ID);
- if (nodeId != null)
- {
- Node<Serializable, Object> node =
nodesRoot.getChild(makeNodeFqn(nodeId));
- if (node != null)
- {
- NodeData itemData = (NodeData)node.get(ITEM_DATA);
- if (itemData != null)
- {
- return itemData;
- }
- else
- {
- throw new RepositoryException("FATAL NodeData empty " +
parentData.getQPath()
- + name.getAsString(true));
- }
- }
- else
- {
- throw new RepositoryException("FATAL Node record not found (" +
name.getAsString(true)
- + "), but listed in childs of " + parentData.getQPath());
- }
- }
- else
- {
- throw new RepositoryException("FATAL Node Id empty " +
parentData.getQPath() + name.getAsString(true));
- }
- }
- else
- {
- // try as Property
- Node<Serializable, Object> parent =
nodesRoot.getChild(makeNodeFqn(parentData.getIdentifier()));
- if (parent != null)
- {
- // get property id
- String propId = (String)parent.get(name.getAsString(false));
- if (propId != null)
- {
- Node<Serializable, Object> prop =
propsRoot.getChild(makePropFqn(propId));
- if (prop != null)
- {
- Object itemData = prop.get(ITEM_DATA);
- if (itemData != null)
- {
- return (PropertyData)itemData;
- }
- else
- {
- throw new RepositoryException("FATAL PropertyData empty "
+ parentData.getQPath()
- + name.getAsString(true));
- }
- }
- else
- {
- throw new RepositoryException("FATAL Property record not
found(" + name.getAsString(true)
- + "), but listed in proprties of " +
parentData.getQPath().getAsString());
- }
- }
- }
- else
- {
- if (LOG.isDebugEnabled())
- {
- LOG.debug("FATAL Parent not found " +
parentData.getQPath().getAsString() + " for "
- + name.getAsString(true));
- }
-
- // TODO should be Exception, but after OPT branch optimization merge, current
impl requires it as null returned
- //throw new RepositoryException("FATAL Parent not found " +
parentData.getQPath().getAsString() + " for "
- // + name.getAsString(true));
- }
- }
- return null;
- }
-
- /**
- * {@inheritDoc}
- */
public ItemData getItemData(String identifier) throws RepositoryException,
IllegalStateException
{