Package nl.basjes.parse.useragent
Class AgentField.ImmutableAgentField
java.lang.Object
nl.basjes.parse.useragent.AgentField.ImmutableAgentField
- All Implemented Interfaces:
Serializable
,AgentField
- Enclosing interface:
- AgentField
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface nl.basjes.parse.useragent.AgentField
AgentField.ImmutableAgentField, AgentField.MutableAgentField
-
Constructor Summary
ConstructorDescriptionImmutableAgentField
(String value, long confidence, boolean isDefaultValue, String defaultValue) ImmutableAgentField
(AgentField agentField) -
Method Summary
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface nl.basjes.parse.useragent.AgentField
afEquals, afHashCode, afToString
-
Constructor Details
-
ImmutableAgentField
-
ImmutableAgentField
-
-
Method Details
-
getValue
Description copied from interface:AgentField
What is the value we have for this field? If we do not know you'll get the default value that has been defined (which may be null).- Specified by:
getValue
in interfaceAgentField
-
getConfidence
public long getConfidence()- Specified by:
getConfidence
in interfaceAgentField
- Returns:
- How certain are we about this value? <0 : We are uncertain. 0>= : The higher the more confident.
-
isDefaultValue
public boolean isDefaultValue()- Specified by:
isDefaultValue
in interfaceAgentField
- Returns:
- Is the value you are getting the default (i.e. we do not know what this is)?
-
getDefaultValue
- Specified by:
getDefaultValue
in interfaceAgentField
- Returns:
- The default value for this field in case we do not know what this is.
-
equals
-
hashCode
public int hashCode() -
toString
-