다음을 통해 공유


SshPublicKeyResourceInner Class

public final class SshPublicKeyResourceInner
extends Resource

Specifies information about the SSH public key.

Constructor Summary

Constructor Description
SshPublicKeyResourceInner()

Creates an instance of SshPublicKeyResourceInner class.

Method Summary

Modifier and Type Method and Description
static SshPublicKeyResourceInner fromJson(JsonReader jsonReader)

Reads an instance of SshPublicKeyResourceInner from the JsonReader.

String id()

Get the id property: Fully qualified resource Id for the resource.

String name()

Get the name property: The name of the resource.

String publicKey()

Get the publicKey property: SSH public key used to authenticate to a virtual machine through ssh.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The type of the resource.

void validate()

Validates the instance.

SshPublicKeyResourceInner withLocation(String location)
SshPublicKeyResourceInner withPublicKey(String publicKey)

Set the publicKey property: SSH public key used to authenticate to a virtual machine through ssh.

SshPublicKeyResourceInner withTags(Map<String,String> tags)

Methods inherited from ProxyResource

Methods inherited from Resource

Methods inherited from java.lang.Object

Constructor Details

SshPublicKeyResourceInner

public SshPublicKeyResourceInner()

Creates an instance of SshPublicKeyResourceInner class.

Method Details

fromJson

public static SshPublicKeyResourceInner fromJson(JsonReader jsonReader)

Reads an instance of SshPublicKeyResourceInner from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of SshPublicKeyResourceInner if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

id

public String id()

Get the id property: Fully qualified resource Id for the resource.

Overrides:

SshPublicKeyResourceInner.id()

Returns:

the id value.

name

public String name()

Get the name property: The name of the resource.

Overrides:

SshPublicKeyResourceInner.name()

Returns:

the name value.

publicKey

public String publicKey()

Get the publicKey property: SSH public key used to authenticate to a virtual machine through ssh. If this property is not initially provided when the resource is created, the publicKey property will be populated when generateKeyPair is called. If the public key is provided upon resource creation, the provided public key needs to be at least 2048-bit and in ssh-rsa format.

Returns:

the publicKey value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

SshPublicKeyResourceInner.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The type of the resource.

Overrides:

SshPublicKeyResourceInner.type()

Returns:

the type value.

validate

public void validate()

Validates the instance.

withLocation

public SshPublicKeyResourceInner withLocation(String location)

Overrides:

SshPublicKeyResourceInner.withLocation(String location)

Parameters:

location

withPublicKey

public SshPublicKeyResourceInner withPublicKey(String publicKey)

Set the publicKey property: SSH public key used to authenticate to a virtual machine through ssh. If this property is not initially provided when the resource is created, the publicKey property will be populated when generateKeyPair is called. If the public key is provided upon resource creation, the provided public key needs to be at least 2048-bit and in ssh-rsa format.

Parameters:

publicKey - the publicKey value to set.

Returns:

the SshPublicKeyResourceInner object itself.

withTags

public SshPublicKeyResourceInner withTags(Map tags)

Overrides:

SshPublicKeyResourceInner.withTags(Map<String,String> tags)

Parameters:

tags

Applies to