Overview

Namespaces

  • OpenCloud
    • Autoscale
      • Resource
    • CloudMonitoring
      • Exception
      • Resource
    • Common
      • Collection
      • Constants
      • Exceptions
      • Http
        • Message
      • Identity
      • Log
      • Service
    • Compute
      • Constants
      • Exception
      • Resource
    • Database
      • Resource
    • DNS
      • Resource
    • LoadBalancer
      • Resource
    • ObjectStore
      • Constants
      • Exception
      • Resource
      • Upload
    • Orchestration
    • Queues
      • Exception
      • Resource
    • Volume
      • Resource
  • PHP

Classes

  • Flavor
  • Image
  • KeyPair
  • Network
  • Server
  • ServerMetadata
  • VolumeAttachment
  • Overview
  • Namespace
  • Class
  • Tree
  • Download

Class KeyPair

Description of KeyPair

OpenCloud\Common\Base
Extended by OpenCloud\Common\PersistentObject
Extended by OpenCloud\Compute\Resource\KeyPair
Namespace: OpenCloud\Compute\Resource
Link
Located at OpenCloud/Compute/Resource/KeyPair.php
Methods summary
public
# setName( mixed $name )
public
# getName( )
public
# createJson( )

Returns an object for the Create() method JSON Must be overridden in a child class.

Returns an object for the Create() method JSON Must be overridden in a child class.

Throws

CreateError
if not overridden

Overrides

OpenCloud\Common\PersistentObject::createJson()
public HttpResponse
# create( array $params = array() )

Creates a new object

Creates a new object

Parameters

$params
array
$params array of values to set when creating the object

Returns

HttpResponse

Throws

VolumeCreateError
if HTTP status is not Success

Overrides

OpenCloud\Common\PersistentObject::create()
public type
# upload( array $options = array() )

Upload an existing public key to a new keypair.

Upload an existing public key to a new keypair.

Parameters

$options
array
$options

Returns

type

Throws

OpenCloud\Compute\Exception\KeyPairException
public HttpResponse
# update( array $params = array() )

Updates an existing object

Updates an existing object

Parameters

$params
array
$params array of values to set when updating the object

Returns

HttpResponse

Throws

VolumeCreateError
if HTTP status is not Success

Overrides

OpenCloud\Common\PersistentObject::update()
public string
# primaryKeyField( )

Returns the primary key field for the object

Returns the primary key field for the object

Returns

string

Overrides

OpenCloud\Common\PersistentObject::primaryKeyField()
Methods inherited from OpenCloud\Common\PersistentObject
__construct(), action(), checkExtension(), createUrl(), delete(), findLink(), getClient(), getMetadata(), getParent(), getService(), getUrl(), id(), jsonCollectionElement(), jsonCollectionName(), jsonName(), name(), noCreate(), noDelete(), noUpdate(), parseResponse(), refresh(), refreshFromLocationUrl(), region(), resourceName(), setMetadata(), setParent(), setService(), status(), updateJson(), url(), waitFor()
Methods inherited from OpenCloud\Common\Base
__call(), checkJsonError(), generateUuid(), getLogger(), getProperty(), makeResourceIteratorOptions(), populate(), propertyExists(), setLogger(), setProperty(), stripNamespace(), toCamel(), toUnderscores()
Properties summary
public array $aliases array( 'private_key' => 'privateKey', 'public_key' => 'publicKey', 'user_id' => 'userId' )
#
protected static string $url_resource 'os-keypairs'
#
protected static string $json_name 'keypair'
#
protected static string $json_collection_element 'keypair'
#
Properties inherited from OpenCloud\Common\PersistentObject
$metadata
PHP OpenCloud API API documentation generated by ApiGen 2.8.0