public boolean checkKeyUsage(final KeyUsageBit keyUsageBit){
  Set<KeyUsageBit> keyUsageBits=getKeyUsageBits();
  return keyUsageBits.contains(keyUsageBit);
}

public boolean checkKeyUsage ( final KeyUsageBit keyUsageBit ) { Set < KeyUsageBit > keyUsageBits = getKeyUsageBits ( ) ; return keyUsageBits . contains ( keyUsageBit ) ; }
this method checks if the certificate contains the given key usage bit .
