java.lang.Object
eu.europa.esig.dss.tsl.dto.condition.KeyUsageCondition
- All Implemented Interfaces:
eu.europa.esig.dss.model.tsl.Condition,Serializable
Condition based on the certificate key usage
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionKeyUsageCondition(eu.europa.esig.dss.enumerations.KeyUsageBit bit, boolean value) Constructs a new KeyUsageCondition.KeyUsageCondition(String usage, boolean value) Constructs a new KeyUsageCondition. -
Method Summary
Modifier and TypeMethodDescriptionbooleancheck(eu.europa.esig.dss.model.x509.CertificateToken certificateToken) final eu.europa.esig.dss.enumerations.KeyUsageBitgetBit()Returns the key usage to be checked.final booleangetValue()Returns the required bit value of the key usage to be checked.toString()
-
Constructor Details
-
KeyUsageCondition
public KeyUsageCondition(eu.europa.esig.dss.enumerations.KeyUsageBit bit, boolean value) Constructs a new KeyUsageCondition.- Parameters:
bit- the key usagevalue- the required value of the key usage bit
-
KeyUsageCondition
Constructs a new KeyUsageCondition.- Parameters:
usage- the key usagevalue- the required value of the key usage bit
-
-
Method Details
-
getBit
public final eu.europa.esig.dss.enumerations.KeyUsageBit getBit()Returns the key usage to be checked.- Returns:
- never
null
-
getValue
public final boolean getValue()Returns the required bit value of the key usage to be checked.- Returns:
- the required bit value of the key usage to be checked
-
check
public boolean check(eu.europa.esig.dss.model.x509.CertificateToken certificateToken) - Specified by:
checkin interfaceeu.europa.esig.dss.model.tsl.Condition
-
toString
- Specified by:
toStringin interfaceeu.europa.esig.dss.model.tsl.Condition
-
toString
-