VMware vSphere Automation SDK Perl The VMware vSphere Automation SDK for Perl supports the client-side vSphere Automation API for access to vSphere services and capabilities

- Main Page
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Files Functions
List of all members
Com::Vmware::Appliance::Techpreview::Ntp::Server Class Reference
Inheritance diagram for Com::Vmware::Appliance::Techpreview::Ntp::Server:

## Avaliable Methods
public method | add ()
public method | delete ()
public method | new ()
public method | set ()

## Detailed Description

`Com::Vmware::Appliance::Techpreview::Ntp::Server` interface provides methods* Performs NTP configuration.

## Member Function Documentation

public method Com::Vmware::Appliance::Techpreview::Ntp::Server::add | ( |  | ) |

Add NTP servers. This command adds NTP servers to the configuration. If the time synchronization is NTP-based, then NTP daemon is restarted to reload the new NTP servers. Otherwise, this command just adds servers to the NTP configuration.

Parameters

  servers | [REQUIRED] List of host names or IP addresses of NTP servers. . The value must be Array of String.

Exceptions

  Com::Vmware::Vapi::Std::Errors::Error | Generic error

Code:
click to view
# Number of lines of code in add: 10
sub add {
my ($self, %args) = @_;
my $servers = $args {servers};
$self->validate_args (method_name => 'add',
method_args => \%args);
return $self->invoke (method_name => 'add',
method_args => \%args);
}

public method Com::Vmware::Appliance::Techpreview::Ntp::Server::delete | ( |  | ) |

Delete NTP servers. This command deletes NTP servers from the configuration. If the time synchronization mode is NTP-based, the NTP daemon is restarted to reload the new NTP configuration. Otherwise, this command just deletes servers from the NTP configuration.

Parameters

  servers | [REQUIRED] List of host name or ip addresses of ntp servers. . The value must be Array of String.

Exceptions

  Com::Vmware::Vapi::Std::Errors::Error | Generic error

Code:
click to view
# Number of lines of code in delete: 10
sub delete {
my ($self, %args) = @_;
my $servers = $args {servers};
$self->validate_args (method_name => 'delete',
method_args => \%args);
return $self->invoke (method_name => 'delete',
method_args => \%args);
}

public method Com::Vmware::Appliance::Techpreview::Ntp::Server::new | ( |  | ) |

Constructor to initialize the object

Parameters

  api_provider | - protocol connection to use with stubs created by this factory
  StubConfig | - Stub's additional configuration

Return values

  Blessed | object

Code:
click to view
# Number of lines of code in new: 11
sub new {
my ($class, %args) = @_;
$class = ref($class) || $class;
my $stub_config = $args {stub_config};
my $api_provider = $args {api_provider};
my $self = $class->SUPER::new('stub_config' => $stub_config,
'api_provider' => $api_provider);
bless $self, $class;
return $self;
}

public method Com::Vmware::Appliance::Techpreview::Ntp::Server::set | ( |  | ) |

Set NTP servers. This command deletes old NTP servers from the configuration and sets the input NTP servers in the configuration. If the time synchronization is NTP-based, the NTP daemon is restarted to reload the new NTP configuration. Otherwise, this command just replaces servers in the NTP configuration.

Parameters

  servers | [REQUIRED] List of host names or ip addresses of ntp servers. . The value must be Array of String.

Exceptions

  Com::Vmware::Vapi::Std::Errors::Error | Generic error

Code:
click to view
# Number of lines of code in set: 10
sub set {
my ($self, %args) = @_;
my $servers = $args {servers};
$self->validate_args (method_name => 'set',
method_args => \%args);
return $self->invoke (method_name => 'set',
method_args => \%args);
}

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

- Com/Vmware/Appliance/Techpreview/Ntp/Server.pm