/*
 * DomUI Java User Interface library
 * Copyright (c) 2010 by Frits Jalvingh, Itris B.V.
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
 *
 * See the "sponsors" file for a list of supporters.
 *
 * The latest version of DomUI and related code, support and documentation
 * can be found at http://www.domui.org/
 * The contact for the project is Frits Jalvingh <jal@etc.to>.
 */
package to.etc.domui.util.resources;

/**
 * This can be added to a ResourceDependencyList, and can be marked as "changed" by some event,
 * causing all dependent resources to reload in debug mode.
 *
 * @author <a href="mailto:jal@etc.to">Frits Jalvingh</a>
 * Created on Jan 10, 2011
 */
final public class FakeModifyableResource implements IModifyableResource {
	private long m_fakeTimestamp;

	/**
	 * Create the resource with a current timestamp.
	 */
	public FakeModifyableResource() {
		m_fakeTimestamp = System.currentTimeMillis();
	}

	/**
	 * Return the current "fake" timestamp, which will change when the user
	 * calls markChanged() on this instance.
	 * @see to.etc.domui.util.resources.IModifyableResource#getLastModified()
	 */
	@Override
	public synchronized long getLastModified() {
		return m_fakeTimestamp;
	}

	/**
	 * Useless, but if you really want to find a value yourself- be my guest. Better
	 * use {@link #markChanged()}.
	 * @param lm
	 */
	public synchronized void setLastModified(long lm) {
		m_fakeTimestamp = lm;
	}

	/**
	 * Mark this resource as "changed" by changing the "timestamp". When the resource dependency
	 * list this belongs to is queried this will notify this as changed which should prompt a
	 * reload.
	 */
	public synchronized void markChanged() {
		m_fakeTimestamp++;
	}
}

@@ -1419,58 +1419,48 @@
 ts I
+Is
 Modif
-yableResource %7B%0A%09private long m_fakeTimestamp
+ied %7B%0A%09private boolean m_modified
 ;%0A%0A%09
@@ -1558,258 +1558,10 @@
  %7B%0A%09
-%09m_fakeTimestamp = System.currentTimeMillis();%0A%09%7D%0A%0A%09/**%0A%09 * Return the current %22fake%22 timestamp, which will change when the user%0A%09 * calls markChanged() on this instance.%0A%09 * @see to.etc.domui.util.resources.IModifyableResource#getLastModified()%0A%09 */
+%7D%0A
 %0A%09@O
@@ -1593,20 +1593,18 @@
 zed 
-long getLast
+boolean is
 Modi
@@ -1627,240 +1627,16 @@
 n m_
-fakeTimestamp;%0A%09%7D%0A%0A%09/**%0A%09 * Useless, but if you really want to find a value yourself- be my guest. Better%0A%09 * use %7B@link #markChanged()%7D.%0A%09 * @param lm%0A%09 */%0A%09public synchronized void setLastModified(long lm) %7B%0A%09%09m_fakeTimestamp = lm
+modified
 ;%0A%09%7D
@@ -1894,23 +1894,23 @@
 %09%09m_
-fakeTimestamp++
+modified = true
 ;%0A%09%7D

Change to more reasonable interface.