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.impl; 018 019import java.util.ArrayList; 020import java.util.List; 021 022/** 023 * This class describes the configuration for a provider. 024 * <p> 025 * Used by digester in StandardFileSystemManager 026 * </p> 027 */ 028public class ProviderConfiguration { 029 030 private String className; 031 private final List<String> schemes = new ArrayList<>(10); 032 private final List<String> dependencies = new ArrayList<>(10); 033 034 /** 035 * Constructs a new instance. 036 */ 037 public ProviderConfiguration() { 038 } 039 040 /** 041 * Gets the class name. 042 * 043 * @return the class name. 044 */ 045 public String getClassName() { 046 return className; 047 } 048 049 /** 050 * Gets the dependency. 051 * 052 * @return the dependency. 053 */ 054 public List<String> getDependencies() { 055 return dependencies; 056 } 057 058 /** 059 * Gets the schema. 060 * 061 * @return the scheme. 062 */ 063 public List<String> getSchemes() { 064 return schemes; 065 } 066 067 /** 068 * Always returns false. 069 * 070 * @return false. 071 */ 072 public boolean isDefault() { 073 return false; 074 } 075 076 /** 077 * sets the class name. 078 * 079 * @param className the class name. 080 */ 081 public void setClassName(final String className) { 082 this.className = className; 083 } 084 085 /** 086 * Sets the dependency. 087 * 088 * @param dependency the dependency. 089 */ 090 public void setDependency(final String dependency) { 091 dependencies.add(dependency); 092 } 093 094 /** 095 * Sets the scheme. 096 * 097 * @param scheme the scheme. 098 */ 099 public void setScheme(final String scheme) { 100 schemes.add(scheme); 101 } 102}