Revert from change in revision 1.132 to only check name in getElementName()
for relational nodes: We actually need to do this for embedded nodes.
This commit is contained in:
parent
460fe9c892
commit
945c18b4ba
1 changed files with 30 additions and 28 deletions
|
@ -413,9 +413,12 @@ public final class Node implements INode, Serializable {
|
||||||
* and a property value for named properties.
|
* and a property value for named properties.
|
||||||
*/
|
*/
|
||||||
public String getElementName() {
|
public String getElementName() {
|
||||||
// for relational nodes we need to consult parent mapping to find element name
|
// check element name - this is either the Node's id or name.
|
||||||
if (isRelational()) {
|
long lastmod = lastmodified;
|
||||||
long lastmod = Math.max(lastmodified, dbmap.getLastTypeChange());
|
|
||||||
|
if (dbmap != null) {
|
||||||
|
lastmod = Math.max(lastmod, dbmap.getLastTypeChange());
|
||||||
|
}
|
||||||
|
|
||||||
if ((parentHandle != null) && (lastNameCheck <= lastmod)) {
|
if ((parentHandle != null) && (lastNameCheck <= lastmod)) {
|
||||||
try {
|
try {
|
||||||
|
@ -450,7 +453,6 @@ public final class Node implements INode, Serializable {
|
||||||
|
|
||||||
lastNameCheck = System.currentTimeMillis();
|
lastNameCheck = System.currentTimeMillis();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return (anonymous || (name == null) || (name.length() == 0)) ? id : name;
|
return (anonymous || (name == null) || (name.length() == 0)) ? id : name;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue