// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/ext/ExtendedWatchEventKind.java
// public class ExtendedWatchEventKind {
// 	/**
// 	 * Indicates the old file name of a renamed file. The
// 	 * {@link WatchEvent}'s {@link WatchEvent#context} method will return
// 	 * a Path that indicates the previous name that the file had.
// 	 */
// 	public static WatchEvent.Kind<Path> 	ENTRY_RENAME_FROM = new PathWatchEventKind("ENTRY_RENAME_FROM");
// 	/**
// 	 * Indicates the new file name of a renamed file. The
// 	 * {@link WatchEvent}'s {@link WatchEvent#context} method will return
// 	 * a Path that indicates the new name of the file.
// 	 */
// 	public static WatchEvent.Kind<Path> 	ENTRY_RENAME_TO = new PathWatchEventKind("ENTRY_RENAME_TO");
// 
// 	/**
// 	 * Indicates that the given {@link WatchKey} has become invalid. This
// 	 * can happen for a number of reasons:
// 	 * <ul>
// 	 *	<li>The key has been invalidated programmatically by calling
// 	 *		{@link WatchKey#cancel}.</li>
// 	 *	<li>The {@link WatchService} has been closed.</li>
// 	 *	<li>The path that the key has been registered with has become
// 	 *		unavailable, e.g because it was deleted or the file system on which
// 	 *		it resides has been unmounted.</li>
// 	 * </ul>
// 	 * Note that not all operating systems will invalidate the WatchKey
// 	 * (and report KEY_INVALID) under the same circumstances. On most platforms,
// 	 * moving or renaming the directory that the key was registered with will
// 	 * invalidate it, however, on Windows it will not (only when it is
// 	 * deleted or unmounted).
// 	 */
// 	public static WatchEvent.Kind<Void> 	KEY_INVALID = new VoidWatchEventKind("KEY_INVALID");
// }
// 
// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/impl/VoidWatchEventKind.java
// public class VoidWatchEventKind implements WatchEvent.Kind<Void> {
// 
// 	public VoidWatchEventKind(String name) {
// 		this.name = name;
// 	}
// 	private final String name;
// 
// 	public String name() {
// 		return name;
// 	}
// 
// 	public Class<Void> type() {
// 		throw new UnsupportedOperationException("Not supported yet.");
// 	}
// }
// 
// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/impl/PathWatchEventKind.java
// public class PathWatchEventKind implements WatchEvent.Kind<Path> {
// 
// 	private final String name;
// 
// 	public PathWatchEventKind(String name) {
// 		this.name = name;
// 	}
// 
// 	public String name() {
// 		return name;
// 	}
// 
// 	public Class<Path> type() {
// 		return Path.class;
// 	}
// 	
// 	@Override
// 	public String toString() {
// 		return name();
// 	}
// }


import name.pachler.nio.file.ext.ExtendedWatchEventKind;
import name.pachler.nio.file.impl.VoidWatchEventKind;
import name.pachler.nio.file.impl.PathWatchEventKind;
/*
 * Copyright 2008-2011 Uwe Pachler
 *
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation. This particular file is
 * subject to the "Classpath" exception as provided in the LICENSE file
 * that accompanied this code.
 *
 * This code 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 General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 */

package name.pachler.nio.file;


/**
 * This class contains the standard watch event kinds, which are basically
 * flags that indicate which events a WatchService should report when a
 * Watchable is registered with a WatchService.
 * The kinds are also used to indicate the kind of event on events that
 * are reported back.</br>
 * Note that the event kinds defined in this class are supported on all platforms
 * @author count
 * @see Watchable#register
 * @see WatchEvent$Kind
 */
public class StandardWatchEventKind {
	/**
	 * Indicates that a file has been created under the watched path.
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_CREATE = new PathWatchEventKind("ENTRY_CREATE");
	/**
	 * Indicates that a file has been deleted under the watched path. Note that
	 * on file rename the old file name will be reported as deleted if no other
	 * (extended) watch event kinds are specified.
	 * @see ExtendedWatchEventKind
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_DELETE = new PathWatchEventKind("ENTRY_DELETE");
	/**
	 * Indicates that a file under the watched path has been modified. Note that
	 * modification can never be byte-accurate, which means that you won't
	 * receive a modification event for each byte written to a file. It is
	 * higly implementation dependent how many modification events are produced.
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_MODIFY = new PathWatchEventKind("ENTRY_MODIFY");

	/**
	 * Indicates queue overflow in the WatchService. If the event queue
	 * overflows (because, for example,the WatchService runs
	 * out of space to store events because they occur faster than the client
	 * code can retreives them from the designated watch keys), additional
	 * events are dropped, and this event is reported.
	 * Note that WatchKeys are always subscribed to this event, regardless
	 * of whether it is specified to <code>register()</code> or not.
	 * @see Watchable#register
	 */
// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/ext/ExtendedWatchEventKind.java
// public class ExtendedWatchEventKind {
// 	/**
// 	 * Indicates the old file name of a renamed file. The
// 	 * {@link WatchEvent}'s {@link WatchEvent#context} method will return
// 	 * a Path that indicates the previous name that the file had.
// 	 */
// 	public static WatchEvent.Kind<Path> 	ENTRY_RENAME_FROM = new PathWatchEventKind("ENTRY_RENAME_FROM");
// 	/**
// 	 * Indicates the new file name of a renamed file. The
// 	 * {@link WatchEvent}'s {@link WatchEvent#context} method will return
// 	 * a Path that indicates the new name of the file.
// 	 */
// 	public static WatchEvent.Kind<Path> 	ENTRY_RENAME_TO = new PathWatchEventKind("ENTRY_RENAME_TO");
// 
// 	/**
// 	 * Indicates that the given {@link WatchKey} has become invalid. This
// 	 * can happen for a number of reasons:
// 	 * <ul>
// 	 *	<li>The key has been invalidated programmatically by calling
// 	 *		{@link WatchKey#cancel}.</li>
// 	 *	<li>The {@link WatchService} has been closed.</li>
// 	 *	<li>The path that the key has been registered with has become
// 	 *		unavailable, e.g because it was deleted or the file system on which
// 	 *		it resides has been unmounted.</li>
// 	 * </ul>
// 	 * Note that not all operating systems will invalidate the WatchKey
// 	 * (and report KEY_INVALID) under the same circumstances. On most platforms,
// 	 * moving or renaming the directory that the key was registered with will
// 	 * invalidate it, however, on Windows it will not (only when it is
// 	 * deleted or unmounted).
// 	 */
// 	public static WatchEvent.Kind<Void> 	KEY_INVALID = new VoidWatchEventKind("KEY_INVALID");
// }
// 
// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/impl/VoidWatchEventKind.java
// public class VoidWatchEventKind implements WatchEvent.Kind<Void> {
// 
// 	public VoidWatchEventKind(String name) {
// 		this.name = name;
// 	}
// 	private final String name;
// 
// 	public String name() {
// 		return name;
// 	}
// 
// 	public Class<Void> type() {
// 		throw new UnsupportedOperationException("Not supported yet.");
// 	}
// }
// 
// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/impl/PathWatchEventKind.java
// public class PathWatchEventKind implements WatchEvent.Kind<Path> {
// 
// 	private final String name;
// 
// 	public PathWatchEventKind(String name) {
// 		this.name = name;
// 	}
// 
// 	public String name() {
// 		return name;
// 	}
// 
// 	public Class<Path> type() {
// 		return Path.class;
// 	}
// 	
// 	@Override
// 	public String toString() {
// 		return name();
// 	}
// }


// Path: jpathwatch-java/src/main/java/name/pachler/nio/file/StandardWatchEventKind.java
import name.pachler.nio.file.ext.ExtendedWatchEventKind;
import name.pachler.nio.file.impl.VoidWatchEventKind;
import name.pachler.nio.file.impl.PathWatchEventKind;

/*
 * Copyright 2008-2011 Uwe Pachler
 *
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation. This particular file is
 * subject to the "Classpath" exception as provided in the LICENSE file
 * that accompanied this code.
 *
 * This code 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 General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 */

package name.pachler.nio.file;


/**
 * This class contains the standard watch event kinds, which are basically
 * flags that indicate which events a WatchService should report when a
 * Watchable is registered with a WatchService.
 * The kinds are also used to indicate the kind of event on events that
 * are reported back.</br>
 * Note that the event kinds defined in this class are supported on all platforms
 * @author count
 * @see Watchable#register
 * @see WatchEvent$Kind
 */
public class StandardWatchEventKind {
	/**
	 * Indicates that a file has been created under the watched path.
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_CREATE = new PathWatchEventKind("ENTRY_CREATE");
	/**
	 * Indicates that a file has been deleted under the watched path. Note that
	 * on file rename the old file name will be reported as deleted if no other
	 * (extended) watch event kinds are specified.
	 * @see ExtendedWatchEventKind
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_DELETE = new PathWatchEventKind("ENTRY_DELETE");
	/**
	 * Indicates that a file under the watched path has been modified. Note that
	 * modification can never be byte-accurate, which means that you won't
	 * receive a modification event for each byte written to a file. It is
	 * higly implementation dependent how many modification events are produced.
	 */
	public static final WatchEvent.Kind<Path> 	ENTRY_MODIFY = new PathWatchEventKind("ENTRY_MODIFY");

	/**
	 * Indicates queue overflow in the WatchService. If the event queue
	 * overflows (because, for example,the WatchService runs
	 * out of space to store events because they occur faster than the client
	 * code can retreives them from the designated watch keys), additional
	 * events are dropped, and this event is reported.
	 * Note that WatchKeys are always subscribed to this event, regardless
	 * of whether it is specified to <code>register()</code> or not.
	 * @see Watchable#register
	 */
	public static final WatchEvent.Kind<Void> 	OVERFLOW = new VoidWatchEventKind("OVERFLOW");