Package sk.iway.iwcm.system
Class ConfigurationModulePath
java.lang.Object
sk.iway.iwcm.system.ConfigurationModulePath
Parses hierarchical configuration module paths.
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanisInBranch(String modules, String branch) Tests whether any declared path is the selected branch or its descendant.static booleanisValidPath(String path) Tests whether a value consists only of valid dot-separated path segments.static booleanmatchesLegacyModule(String modules, String module) Matches the historical flat module identifier against a complete segment of a hierarchical path.static StringReturns the canonical semicolon-separated representation of module paths.Splits semicolon-separated module memberships, removes invalid entries and preserves the declaration order while removing duplicates.
-
Method Details
-
parse
Splits semicolon-separated module memberships, removes invalid entries and preserves the declaration order while removing duplicates.- Parameters:
modules- semicolon-separated module paths- Returns:
- normalized module paths
-
normalize
Returns the canonical semicolon-separated representation of module paths.- Parameters:
modules- semicolon-separated module paths- Returns:
- normalized module memberships
-
isInBranch
Tests whether any declared path is the selected branch or its descendant.- Parameters:
modules- semicolon-separated module pathsbranch- selected hierarchy branch- Returns:
- true when a membership belongs to the branch
-
matchesLegacyModule
Matches the historical flat module identifier against a complete segment of a hierarchical path. A hierarchical module identifier must match the full path.- Parameters:
modules- semicolon-separated module pathsmodule- historical module identifier or a full module path- Returns:
- true when the module matches exactly
-
isValidPath
Tests whether a value consists only of valid dot-separated path segments.- Parameters:
path- module path- Returns:
- true for a valid module path
-