AceTime  1.0
Date and time classes for Arduino that support timezones from the TZ Database, and a system clock that can synchronize from an NTP server or an RTC chip.
Public Member Functions | Protected Member Functions | List of all members
ace_time::ZoneManager< ZI, ZR, ZSC > Class Template Reference

Returns the TimeZone given the zoneInfo, zoneName, or zoneId. More...

#include <ZoneManager.h>

Public Member Functions

const ZR & getRegistrar () const
 
TimeZone createForZoneInfo (const ZI *zoneInfo)
 
TimeZone createForZoneName (const char *name)
 
TimeZone createForZoneId (uint32_t id)
 
TimeZone createForZoneIndex (uint16_t index)
 
TimeZone createForTimeZoneData (const TimeZoneData &d)
 Create from the TimeZoneData created by TimeZone::toTimeZoneData(). More...
 
uint16_t indexForZoneName (const char *name) const
 
uint16_t indexForZoneId (uint32_t id) const
 

Protected Member Functions

 ZoneManager (uint16_t registrySize, const ZI *const *zoneRegistry)
 

Detailed Description

template<typename ZI, typename ZR, typename ZSC>
class ace_time::ZoneManager< ZI, ZR, ZSC >

Returns the TimeZone given the zoneInfo, zoneName, or zoneId.

Looks up the ZoneInfo in the ZoneRegistrar. If an existing ZoneProcessor exists in the ZoneProcessorCache, then it is used. If not, another ZoneProcessor is picked from the cache in a round-robin fashion. The type of the TimeZone will be assigned to be the type of the ZoneProcessorCache, which will be either kTypeBasicManaged or kTypeExtendedManaged.

Template Parameters
ZItype of ZoneInfo (basic::ZoneInfo or extended::ZoneInfo) which make up the zone registry
ZRclass of ZoneRegistrar
ZSCclass of ZoneProcessorCache

Definition at line 21 of file TimeZone.h.

Member Function Documentation

◆ createForTimeZoneData()

template<typename ZI, typename ZR, typename ZSC>
TimeZone ace_time::ZoneManager< ZI, ZR, ZSC >::createForTimeZoneData ( const TimeZoneData d)
inline

Create from the TimeZoneData created by TimeZone::toTimeZoneData().

kTypeBasic is converted into a kTypeBasicManaged, and kTypeExtended is converted into a kTypeExtendedManaged.

Definition at line 59 of file ZoneManager.h.


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