Package blog.softwaretester.properties
Class PropertyAggregator
- java.lang.Object
-
- blog.softwaretester.properties.PropertyAggregator
-
public final class PropertyAggregator extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classPropertyAggregator.BuilderBuilder used to create aPropertyAggregatorinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PropertiesgetAllProperties()Get all processed properties.intgetPropertiesCount()Get the size of all stored property key value pairs including the ones that are only set by defaults.PropertiesgetPropertiesWithCustomPredicate(Predicate<? super Map.Entry<String,String>> predicate)Returns a subset of properties that match a provided predicate.StringgetProperty(String key)Get the value of a specific properties key.voidlogFinalProperties()Log all final processed properties in natural sort order.
-
-
-
Method Detail
-
getProperty
public String getProperty(String key)
Get the value of a specific properties key.- Parameters:
key- The key of the property.- Returns:
- The value of the property.
-
getPropertiesCount
public int getPropertiesCount()
Get the size of all stored property key value pairs including the ones that are only set by defaults.- Returns:
- The number of stored properties.
-
getAllProperties
public Properties getAllProperties()
Get all processed properties.- Returns:
- The
Properties.
-
getPropertiesWithCustomPredicate
public Properties getPropertiesWithCustomPredicate(Predicate<? super Map.Entry<String,String>> predicate)
Returns a subset of properties that match a provided predicate.- Parameters:
predicate- The filter to apply to the properties.- Returns:
- The filtered properties.
-
logFinalProperties
public void logFinalProperties()
Log all final processed properties in natural sort order.
-
-