Class KeyPairInfo

java.lang.Object
com.amazonaws.services.ec2.model.KeyPairInfo
All Implemented Interfaces:
Serializable, Cloneable

public class KeyPairInfo extends Object implements Serializable, Cloneable

Describes a key pair.

See Also:
  • Constructor Details

    • KeyPairInfo

      public KeyPairInfo()
  • Method Details

    • setKeyName

      public void setKeyName(String keyName)

      The name of the key pair.

      Parameters:
      keyName - The name of the key pair.
    • getKeyName

      public String getKeyName()

      The name of the key pair.

      Returns:
      The name of the key pair.
    • withKeyName

      public KeyPairInfo withKeyName(String keyName)

      The name of the key pair.

      Parameters:
      keyName - The name of the key pair.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setKeyFingerprint

      public void setKeyFingerprint(String keyFingerprint)

      If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.

      Parameters:
      keyFingerprint - If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.
    • getKeyFingerprint

      public String getKeyFingerprint()

      If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.

      Returns:
      If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.
    • withKeyFingerprint

      public KeyPairInfo withKeyFingerprint(String keyFingerprint)

      If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.

      Parameters:
      keyFingerprint - If you used CreateKeyPair to create the key pair, this is the SHA-1 digest of the DER encoded private key. If you used ImportKeyPair to provide AWS the public key, this is the MD5 public key fingerprint as specified in section 4 of RFC4716.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      public KeyPairInfo clone()
      Overrides:
      clone in class Object