Class KeyPairInfo.Builder

  • Enclosing class:
    KeyPairInfo

    public static class KeyPairInfo.Builder
    extends java.lang.Object
    A builder that constructs a KeyPairInfo instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      KeyPairInfo build()
      Builds and returns an instance according to the configuration of this builder.
      KeyPairInfo.Builder certificates​(java.util.List<java.security.cert.X509Certificate> certificates)
      Specifies a list of corresponding certificates.
      KeyPairInfo.Builder id​(java.lang.String id)
      Specifies an identifier for this privateKey.
      KeyPairInfo.Builder privateKey​(java.security.PrivateKey privateKey)
      Specifies the private key.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • id

        public KeyPairInfo.Builder id​(java.lang.String id)
        Specifies an identifier for this privateKey.
        Parameters:
        id - identifier
        Returns:
        this builder
      • privateKey

        public KeyPairInfo.Builder privateKey​(java.security.PrivateKey privateKey)
        Specifies the private key.
        Parameters:
        privateKey - the subject privateKey
        Returns:
        this builder
      • certificates

        public KeyPairInfo.Builder certificates​(java.util.List<java.security.cert.X509Certificate> certificates)
        Specifies a list of corresponding certificates.
        Parameters:
        certificates - certificates to add
        Returns:
        this builder
      • build

        public KeyPairInfo build()
        Builds and returns an instance according to the configuration of this builder.
        Returns:
        privateKey info instance