else
else if (!nmap.isStorageCompatible (value.getDbMapping ()))
    public void setNode (String propname, INode value) {	// nmgr.logEvent ("setting node prop");	// check if types match, otherwise throw exception	DbMapping nmap = dbmap == null ? null : dbmap.getPropertyMapping (propname);	if (nmap != null && nmap != value.getDbMapping()) {	    if (value.getDbMapping () == null)	        value.setDbMapping (nmap);	    else	        throw new RuntimeException ("Can't set "+propname+" to object with prototype "+value.getPrototype()+", was expecting "+nmap.getTypeName());	}	checkWriteLock ();    	Node n = null;    	if (value instanceof Node)	    n = (Node) value;	else 	    throw new RuntimeException ("Can't add fixed-transient node to a persistent node");	// if the new node is marked as TRANSIENT and this node is not, mark new node as NEW	if (state != TRANSIENT && n.state == TRANSIENT)	    n.makePersistentCapable ();	n.checkWriteLock ();	// check if the main identity of this node is as a named property	// or as an anonymous node in a collection	if (n.parentHandle == null && n.adoptName && !"root".equalsIgnoreCase (n.getPrototype ())) {	    n.setParent (this);	    n.name = propname;	    n.anonymous = false;	}	propname = propname.trim ();	String p2 = propname.toLowerCase ();	Property prop = propMap == null ? null : (Property) propMap.get (p2);	if (prop != null) {	    if (prop.type == IProperty.NODE && n.getHandle ().equals (prop.nhandle)) {	        // nothing to do, just clean up locks and return	        if (state == CLEAN) clearWriteLock ();	        if (n.state == CLEAN) n.clearWriteLock ();	        return;	    }	} else {	    prop = new Property (propname, this);	}	prop.setNodeValue (n);	Relation rel = dbmap == null ? null : dbmap.getPropertyRelation (propname);	if (rel == null || rel.reftype == Relation.REFERENCE || rel.virtual ||			rel.otherType == null || !rel.otherType.isRelational()) {	    // the node must be stored as explicit property	    if (propMap == null)	        propMap = new Hashtable ();	    propMap.put (p2, prop);	    if (state == CLEAN) markAs (MODIFIED);	}		/* if (rel != null && rel.reftype == Relation.REFERENCE && !rel.usesPrimaryKey ()) {	    // if the relation for this property doesn't use the primary key of the value object, make a	    // secondary key object with the proper db column	    String kval = n.getString (rel.otherType.columnNameToProperty (rel.getRemoteField ()), false);	    prop.nhandle = new NodeHandle (new DbKey (n.getDbMapping (), kval, rel.getRemoteField ()));	} */		// don't check node in transactor cache -- this is done anyway when the node becomes persistent.	if (n.state != TRANSIENT) {	    // check node in with transactor cache	    String nID = n.getID();	    Transactor tx = (Transactor) Thread.currentThread ();	    tx.visitCleanNode (new DbKey (nmap, nID), n);	    // if the field is not the primary key of the property, also register it	    if (rel != null && rel.accessor != null && state != TRANSIENT) {	        Key secKey = new SyntheticKey (getKey (), propname);	        nmgr.evictKey (secKey);	        tx.visitCleanNode (secKey, n);	    }	}	lastmodified = System.currentTimeMillis ();	if (n.state == DELETED) n.markAs (MODIFIED);    }