compute  v1
Public Member Functions | Static Public Member Functions | List of all members
google_compute_api::Scheduling Class Reference

#include <scheduling.h>

Inheritance diagram for google_compute_api::Scheduling:

Public Member Functions

 Scheduling (const Json::Value &storage)
 
 Scheduling (Json::Value *storage)
 
virtual ~Scheduling ()
 
const StringPiece GetTypeName () const
 
bool has_automatic_restart () const
 
void clear_automatic_restart ()
 
bool get_automatic_restart () const
 
void set_automatic_restart (bool value)
 
bool has_node_affinities () const
 
void clear_node_affinities ()
 
const client::JsonCppArray< SchedulingNodeAffinityget_node_affinities () const
 
client::JsonCppArray< SchedulingNodeAffinitymutable_nodeAffinities ()
 
bool has_on_host_maintenance () const
 
void clear_on_host_maintenance ()
 
const StringPiece get_on_host_maintenance () const
 
void set_on_host_maintenance (const StringPiece &value)
 
bool has_preemptible () const
 
void clear_preemptible ()
 
bool get_preemptible () const
 
void set_preemptible (bool value)
 

Static Public Member Functions

static SchedulingNew ()
 

Detailed Description

Sets the scheduling options for an Instance.

Constructor & Destructor Documentation

◆ Scheduling() [1/2]

google_compute_api::Scheduling::Scheduling ( const Json::Value &  storage)
explicit

Standard constructor for an immutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ Scheduling() [2/2]

google_compute_api::Scheduling::Scheduling ( Json::Value *  storage)
explicit

Standard constructor for a mutable data object instance.

Parameters
[in]storageThe underlying data storage for this instance.

◆ ~Scheduling()

google_compute_api::Scheduling::~Scheduling ( )
virtual

Standard destructor.

Member Function Documentation

◆ clear_automatic_restart()

void google_compute_api::Scheduling::clear_automatic_restart ( )
inline

Clears the 'automaticRestart' attribute.

◆ clear_node_affinities()

void google_compute_api::Scheduling::clear_node_affinities ( )
inline

Clears the 'nodeAffinities' attribute.

◆ clear_on_host_maintenance()

void google_compute_api::Scheduling::clear_on_host_maintenance ( )
inline

Clears the 'onHostMaintenance' attribute.

◆ clear_preemptible()

void google_compute_api::Scheduling::clear_preemptible ( )
inline

Clears the 'preemptible' attribute.

◆ get_automatic_restart()

bool google_compute_api::Scheduling::get_automatic_restart ( ) const
inline

Get the value of the 'automaticRestart' attribute.

◆ get_node_affinities()

const client::JsonCppArray<SchedulingNodeAffinity > google_compute_api::Scheduling::get_node_affinities ( ) const

Get a reference to the value of the 'nodeAffinities' attribute.

◆ get_on_host_maintenance()

const StringPiece google_compute_api::Scheduling::get_on_host_maintenance ( ) const
inline

Get the value of the 'onHostMaintenance' attribute.

◆ get_preemptible()

bool google_compute_api::Scheduling::get_preemptible ( ) const
inline

Get the value of the 'preemptible' attribute.

◆ GetTypeName()

const StringPiece google_compute_api::Scheduling::GetTypeName ( ) const
inline

Returns a string denoting the type of this data object.

Returns
google_compute_api::Scheduling

◆ has_automatic_restart()

bool google_compute_api::Scheduling::has_automatic_restart ( ) const
inline

Determine if the 'automaticRestart' attribute was set.

Returns
true if the 'automaticRestart' attribute was set.

◆ has_node_affinities()

bool google_compute_api::Scheduling::has_node_affinities ( ) const
inline

Determine if the 'nodeAffinities' attribute was set.

Returns
true if the 'nodeAffinities' attribute was set.

◆ has_on_host_maintenance()

bool google_compute_api::Scheduling::has_on_host_maintenance ( ) const
inline

Determine if the 'onHostMaintenance' attribute was set.

Returns
true if the 'onHostMaintenance' attribute was set.

◆ has_preemptible()

bool google_compute_api::Scheduling::has_preemptible ( ) const
inline

Determine if the 'preemptible' attribute was set.

Returns
true if the 'preemptible' attribute was set.

◆ mutable_nodeAffinities()

client::JsonCppArray<SchedulingNodeAffinity > google_compute_api::Scheduling::mutable_nodeAffinities ( )

Gets a reference to a mutable value of the 'nodeAffinities' property.

A set of node affinity and anti-affinity.

Returns
The result can be modified to change the attribute value.

◆ New()

Scheduling * google_compute_api::Scheduling::New ( )
static

Creates a new default instance.

Returns
Ownership is passed back to the caller.

◆ set_automatic_restart()

void google_compute_api::Scheduling::set_automatic_restart ( bool  value)
inline

Change the 'automaticRestart' attribute.

Specifies whether the instance should be automatically restarted if it is terminated by Compute Engine (not terminated by a user). You can only set the automatic restart option for standard instances. Preemptible instances cannot be automatically restarted.

By default, this is set to true so an instance is automatically restarted if it is terminated by Compute Engine.

Parameters
[in]valueThe new value.

◆ set_on_host_maintenance()

void google_compute_api::Scheduling::set_on_host_maintenance ( const StringPiece &  value)
inline

Change the 'onHostMaintenance' attribute.

Defines the maintenance behavior for this instance. For standard instances, the default behavior is MIGRATE. For preemptible instances, the default and only possible behavior is TERMINATE. For more information, see Setting Instance Scheduling Options.

Parameters
[in]valueThe new value.

◆ set_preemptible()

void google_compute_api::Scheduling::set_preemptible ( bool  value)
inline

Change the 'preemptible' attribute.

Defines whether the instance is preemptible. This can only be set during instance creation, it cannot be set or changed after the instance has been created.

Parameters
[in]valueThe new value.

The documentation for this class was generated from the following files: