1 16 17 package org.apache.commons.configuration; 18 19 import java.net.URL ; 20 import java.io.InputStream ; 21 import java.io.Reader ; 22 import java.io.OutputStream ; 23 import java.io.Writer ; 24 import java.io.File ; 25 26 import org.apache.commons.configuration.reloading.ReloadingStrategy; 27 28 35 public interface FileConfiguration extends Configuration 36 { 37 43 void load() throws ConfigurationException; 44 45 52 void load(String fileName) throws ConfigurationException; 53 54 61 void load(File file) throws ConfigurationException; 62 63 70 void load(URL url) throws ConfigurationException; 71 72 80 void load(InputStream in) throws ConfigurationException; 81 82 91 void load(InputStream in, String encoding) throws ConfigurationException; 92 93 100 void load(Reader in) throws ConfigurationException; 101 102 107 void save() throws ConfigurationException; 108 109 116 void save(String fileName) throws ConfigurationException; 117 118 125 void save(File file) throws ConfigurationException; 126 127 134 void save(URL url) throws ConfigurationException; 135 136 144 void save(OutputStream out) throws ConfigurationException; 145 146 154 void save(OutputStream out, String encoding) throws ConfigurationException; 155 156 163 void save(Writer out) throws ConfigurationException; 164 165 168 String getFileName(); 169 170 175 void setFileName(String fileName); 176 177 180 String getBasePath(); 181 182 187 void setBasePath(String basePath); 188 189 192 File getFile(); 193 194 199 void setFile(File file); 200 201 204 URL getURL(); 205 206 211 void setURL(URL url); 212 213 219 void setAutoSave(boolean autoSave); 220 221 227 boolean isAutoSave(); 228 229 234 ReloadingStrategy getReloadingStrategy(); 235 236 241 void setReloadingStrategy(ReloadingStrategy strategy); 242 243 248 void reload(); 249 250 256 String getEncoding(); 257 258 264 void setEncoding(String encoding); 265 266 } 267 | Popular Tags |