Class AuditField
- java.lang.Object
-
- com.helger.photon.audit.v2.domain.AuditField
-
- All Implemented Interfaces:
Serializable
@Immutable public class AuditField extends Object implements Serializable
A single field of anAuditEvent. Has a mandatory name and an optional value.- Author:
- Philip Helger
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AuditField(String sName, String sValue)Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AuditFieldcreateWithHiddenValue(String sFieldName)Factory method to create anAuditFieldwith a value that indicates, that the real value is not to be persisted or displayed.booleanequals(Object o)StringgetName()StringgetValue()inthashCode()booleanhasName()booleanhasValue()StringtoString()
-
-
-
Method Detail
-
hasName
public boolean hasName()
- Returns:
trueif a name is present,falseif not.
-
hasValue
public boolean hasValue()
- Returns:
trueif a value is present,falseif not.
-
createWithHiddenValue
@Nonnull public static AuditField createWithHiddenValue(@Nullable String sFieldName)
Factory method to create anAuditFieldwith a value that indicates, that the real value is not to be persisted or displayed.- Parameters:
sFieldName- Field name. May benull.- Returns:
- A new
AuditFieldand nevernull.
-
-