Package com.ganteater.ae.util
package com.ganteater.ae.util
Low-level, dependency-light utilities shared across the project.
This package contains small helper types that are used across multiple parts of the codebase. The utilities are mostly stateless and focus on tasks that would otherwise be repeated in higher layers.
Key utilities
- Resource loading from the filesystem, classpath, and
jar:file:...URLs viaAEUtils.getInputStream(String, java.io.File)andAEUtils.loadResource(String, java.io.File, String). - Convenience text helpers such as best-effort JSON pretty printing embedded in
text (
AEUtils.format(String)) and masking email addresses (AEUtils.maskEmail(String)). - Service Provider Interface discovery using
ServiceLoader(ClassUtils). - Symmetric string encryption/decryption backed by Jasypt
(
Encryptor). - Regex-based file/path filtering for Apache Commons IO traversal
(
RegexPathFilter). - Minimal assertion helpers for runtime/non-JUnit contexts
(
TestCaseandAssertionFailedError). - Compatibility types such as an
NameValuePairimplementation (NameValuePairImplementation).
Usage examples
Load a resource relative to a base directory (including support for jar:file: paths):
String xml = AEUtils.loadResource("config.xml", new File("/opt/app"), null);
Discover SPI implementations registered via ServiceLoader:
List<Class<?>> implementations = ClassUtils.findAssignable(MySpi.class);
-
ClassDescription