Inheritance: implements jose\JWTCreatorInterface
 /**
  * @param string $jwt
  *
  * @return string
  */
 public function encrypt($jwt)
 {
     $headers = $this->getEncryptionHeaders();
     $encryption_key = $this->encryption_jwkset[0];
     if ($encryption_key->has('kid')) {
         $headers['kid'] = $encryption_key->get('kid');
     }
     return $this->jwt_creator->encrypt($jwt, $headers, $encryption_key);
 }
 /**
  * @param \Jose\SignerInterface         $signer
  * @param \Jose\EncrypterInterface|null $encrypter
  *
  * @return \Jose\JWTCreator
  */
 public function createJWTCreator(SignerInterface $signer, EncrypterInterface $encrypter = null)
 {
     $jwt_creator = new JWTCreator($signer);
     if (null !== $encrypter) {
         $jwt_creator->enableEncryptionSupport($encrypter);
     }
     return $jwt_creator;
 }