1 /* 2 * Licensed to the Apache Software Foundation (ASF) under one or more 3 * contributor license agreements. See the NOTICE file distributed with 4 * this work for additional information regarding copyright ownership. 5 * The ASF licenses this file to You under the Apache License, Version 2.0 6 * (the "License"); you may not use this file except in compliance with 7 * the License. You may obtain a copy of the License at 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 */ 17 package org.apache.commons.io.monitor; 18 19 import java.io.File; 20 21 /** 22 * Convenience {@link FileAlterationListener} implementation that does nothing. 23 * 24 * @see FileAlterationObserver 25 * 26 * @since 2.0 27 */ 28 public class FileAlterationListenerAdaptor implements FileAlterationListener { 29 30 /** 31 * Directory changed Event. 32 * 33 * @param directory The directory changed (ignored) 34 */ 35 @Override 36 public void onDirectoryChange(final File directory) { 37 // noop 38 } 39 40 /** 41 * Directory created Event. 42 * 43 * @param directory The directory created (ignored) 44 */ 45 @Override 46 public void onDirectoryCreate(final File directory) { 47 // noop 48 } 49 50 /** 51 * Directory deleted Event. 52 * 53 * @param directory The directory deleted (ignored) 54 */ 55 @Override 56 public void onDirectoryDelete(final File directory) { 57 // noop 58 } 59 60 /** 61 * File changed Event. 62 * 63 * @param file The file changed (ignored) 64 */ 65 @Override 66 public void onFileChange(final File file) { 67 // noop 68 } 69 70 /** 71 * File created Event. 72 * 73 * @param file The file created (ignored) 74 */ 75 @Override 76 public void onFileCreate(final File file) { 77 // noop 78 } 79 80 /** 81 * File deleted Event. 82 * 83 * @param file The file deleted (ignored) 84 */ 85 @Override 86 public void onFileDelete(final File file) { 87 // noop 88 } 89 90 /** 91 * File system observer started checking event. 92 * 93 * @param observer The file system observer (ignored) 94 */ 95 @Override 96 public void onStart(final FileAlterationObserver observer) { 97 // noop 98 } 99 100 /** 101 * File system observer finished checking event. 102 * 103 * @param observer The file system observer (ignored) 104 */ 105 @Override 106 public void onStop(final FileAlterationObserver observer) { 107 // noop 108 } 109 110 }