Interface PathResolver
- All Known Implementing Classes:
PathResolverImpl
public interface PathResolver
Port for resolving paths in different architecture types.
Handles placeholder substitution and path validation.
-
Method Summary
Modifier and TypeMethodDescriptionresolveAdapterPath(ArchitectureType architecture, String adapterType, String name, Map<String, String> context) Resolves the path for an adapter based on architecture configuration.substitutePlaceholders(String template, Map<String, String> context) Substitutes placeholders in a path template with actual values.validatePath(Path path, ArchitectureType architecture) Validates that a path respects layer dependency rules.
-
Method Details
-
resolveAdapterPath
Path resolveAdapterPath(ArchitectureType architecture, String adapterType, String name, Map<String, String> context) Resolves the path for an adapter based on architecture configuration.- Parameters:
architecture- The architecture typeadapterType- The adapter type (driven or driving)name- The adapter namecontext- Additional context for placeholder substitution (basePackage, module, etc.)- Returns:
- The resolved path
-
validatePath
Validates that a path respects layer dependency rules.- Parameters:
path- The path to validatearchitecture- The architecture type- Returns:
- ValidationResult indicating if path is valid
-
substitutePlaceholders
Substitutes placeholders in a path template with actual values.- Parameters:
template- The path template with placeholderscontext- Map of placeholder names to values- Returns:
- The path with placeholders substituted
-