Class WorkspaceMechanicConfigParser
java.lang.Object
de.funfried.netbeans.plugins.external.formatter.eclipse.mechanic.WorkspaceMechanicConfigParser
A parser for Workspace Mechanic configuration files.
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
WorkspaceMechanicConfigParser
public WorkspaceMechanicConfigParser()
-
-
Method Details
-
readPropertiesFromConfiguration
@NonNull public static Map<String,String> readPropertiesFromConfiguration(String path, String prefix) throws IOException Parses and returns properties of the givenpath
into a key valueMap
. If an optionalprefix
is specified, only the properties where the key starts with the givenprefix
are returned and theprefix
will be removed from the keys in the returnedMap
.- Parameters:
path
- a configuration file path or URLprefix
- an optional key prefix- Returns:
- properties of the given
path
as a key valueMap
- Throws:
IOException
- if there is an issue accessing the given configuration file
-