# Poco::Net

# class NTPClient

Library: Net
Package: NTP
Header: Poco/Net/NTPClient.h

## Description

This class provides NTP (Network Time Protocol) client functionality.

## Member Summary

Member Functions: request

## Constructors

### NTPClient

explicit NTPClient(
IPAddress::Family family,
int timeout = 3000000
);

Creates an NTP client.

## Destructor

### ~NTPClient

~NTPClient();

Destroys the NTP client.

## Member Functions

### request

int request(
SocketAddress & address
) const;

Request the time from the server at address. Notifications are posted for events.

Returns the number of valid replies.

### request

int request(
const std::string & address
) const;

Request the time from the server at address. Notifications are posted for events.

Returns the number of valid replies.

## Variables

### response

mutable Poco::BasicEvent < NTPEventArgs > response;