markLockedIfNecessary( iobj, null );
secSys.markLockedIfNecessary( iobj );
    public boolean onSave(Object entity, Serializable id,     		Object[] state,     		String[] propertyNames, Type[] types)    {    	debug("Intercepted save.");    	    	    	if ( entity instanceof IObject )    	{    		IObject iobj = (IObject) entity;    		int idx = detailsIndex( propertyNames );    		// New instances don't inherently need to be locked    		// as they have no trustedDetails    		markLockedIfNecessary( iobj, null );    		// Get a new details based on the current context    		Details d = secSys.transientDetails( iobj );    		state[idx] = d;    		    	}    	        return true; // transferDetails ALWAYS edits the new entity.    }