public class IniParser extends Object
| Constructor and Description |
|---|
IniParser() |
| Modifier and Type | Method and Description |
|---|---|
static BufferedReader |
openTextResource(String path)
Opens a buffered reader for the given resource.
|
static BufferedReader |
openTextResource(String path,
Class<?> c)
Opens a buffered reader for the given resource.
|
IniList |
parseINI(BufferedReader in)
Parses the INI-style configuration data from the given input stream.
|
IniList |
parseINI(File file)
Parses the INI-style wrapping the given file in a
BufferedReader |
IniList |
parseINI(String path)
Parses the INI-style configuration data from the given resource.
|
IniList |
parseINI(String path,
Class<?> c)
Parses the INI-style configuration data from the given resource,
using the given class to find the resource.
|
void |
setBackslashContinuesLine(boolean slashContinues)
Set whether or not a '\' at the end of a line signifies that the
line continues on the following line.
|
void |
setCommentDelimiter(String delimiter)
Set the String that identifies a comment.
|
public void setCommentDelimiter(String delimiter)
delimiter - the String used to identify commentspublic void setBackslashContinuesLine(boolean slashContinues)
slashContinues - true if a '\' at the end of a line signifies that
the line continues on the following linepublic IniList parseINI(String path) throws IOException
path - the name of the resource to readIOException - if the resource cannot be readopenTextResource(String)public IniList parseINI(String path, Class<?> c) throws IOException
path - the name of the resource to readc - the Class to use for finding the named resourceIOException - if the resource cannot be readopenTextResource(String, Class)public IniList parseINI(File file) throws IOException
BufferedReaderfile - the file on disk from which to readIOException - if the file cannot be readpublic IniList parseINI(BufferedReader in) throws IOException
in - the BufferedReader stream from which to readIOException - if the stream cannot be readpublic static BufferedReader openTextResource(String path)
path - the name of the resource to readopenTextResource(String)public static BufferedReader openTextResource(String path, Class<?> c)
path - the name of the resource to readc - the Class to use for finding the named resourceopenTextResource(String)Copyright © 2005–2024 Open Microscopy Environment. All rights reserved.