001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.commons.vfs2.operations;
018
019import org.apache.commons.vfs2.FileSystemException;
020
021/**
022 * <p>
023 * A FileOperation is an object that brings an extra function to a FileObject. The VFS provides the basic functionality
024 * to deal with FileObject's. That is create, delete, rename, copy, and so on functions. However, if you are working
025 * with FileSystem and its files are, for example, under Version Control System (VCS) you might want to get an access to
026 * the versioning framework and to be able to manage your files regarding VCS (e.g. commit them, update, get logs,
027 * etc.). Such type of extended functionality is provided by FileOperation.
028 * </p>
029 * <p>
030 * The FileOperation interface is a genetic interface that should not be implemented directly. It rather should be
031 * extended by other interfaces that provide some concrete functions.
032 * </p>
033 * <p>
034 * FileOperation is provided by
035 * </p>
036 *
037 * @see FileOperationProvider Especially the FileOperationProvider is responsible for looking up and instantiating any
038 *      concrete FileOperation.
039 *
040 * @since 0.1
041 */
042public interface FileOperation {
043
044    /**
045     * Performs necessary actions that are related to the concrete implementation of a FileOperation.
046     *
047     * @throws FileSystemException if an error occurs
048     */
049    void process() throws FileSystemException;
050}