summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java')
-rw-r--r--plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java24
1 files changed, 24 insertions, 0 deletions
diff --git a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java
index 90bd517..411878d 100644
--- a/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java
+++ b/plugins/org.eclipse.emf.cdo.server/src/org/eclipse/emf/cdo/server/impl/MapperImpl.java
@@ -939,7 +939,31 @@ public class MapperImpl extends ServiceImpl implements Mapper, SQLConstants
});
channel.transmitLong(CDOProtocol.NO_MORE_OBJECTS);
+ }
+
+ public void transmitXRefs(final Channel channel, final long oid, int rid)
+ {
+ Object[] args = { new Long(oid)};
+ if (isDebugEnabled()) debug(StringHelper.replaceWildcards(SELECT_XREFS_OF_OBJECT, "?", args));
+ jdbcTemplate.query(SELECT_XREFS_OF_OBJECT, args, new RowCallbackHandler()
+ {
+ public void processRow(ResultSet resultSet) throws SQLException
+ {
+ long referer = resultSet.getLong(1);
+ int feature = resultSet.getInt(2);
+ int cid = resultSet.getInt(3);
+ if (isDebugEnabled())
+ debug("XRef: referer=" + oidEncoder.toString(referer) + ", feature=" + feature + ", cid="
+ + cid);
+
+ channel.transmitLong(referer);
+ channel.transmitInt(feature);
+ channel.transmitInt(cid);
+ }
+ });
+
+ channel.transmitLong(CDOProtocol.NO_MORE_OBJECTS);
}
public void createAttributeTables(PackageInfo packageInfo)