Class DT_UTC_SYSTEM_CLOCK PreviousNext

note
description:

    "UTC system clocks (precision to the second)"

library:    "Gobo Eiffel Time Library"
author:     "Eric Bezault <ericb@gobosoft.com>"
copyright:  "Copyright (c) 2001, Eric Bezault and others"
license:    "MIT License"
class interface
DT_UTC_SYSTEM_CLOCK
inherit
DT_CLOCK
    DT_DATE_HANDLER
    DT_TIME_HANDLER
    DT_DATE_TIME_HANDLER
create
make
        -- Create a new system clock.
feature -- Access
time_now: DT_TIME
        -- Current time
        -- (Create a new time object at each call.)
        -- (From DT_CLOCK.)
    ensure
        time_now_not_void: Result /= Void
date_now: DT_DATE
        -- Current date
        -- (Create a new date object at each call.)
        -- (From DT_CLOCK.)
    ensure
        date_now_not_void: Result /= Void
date_time_now: DT_DATE_TIME
        -- Current date time
        -- (Create a new date time object at each call.)
        -- (From DT_CLOCK.)
    ensure
        date_time_now_not_void: Result /= Void
feature -- Setting
set_time_to_now (a_time: DT_TIME)
        -- Set a_time to current UTC time.
        -- (From DT_CLOCK.)
    require
        a_time_not_void: a_time /= Void
set_date_to_now (a_date: DT_DATE)
        -- Set a_date to current UTC date.
        -- (From DT_CLOCK.)
    require
        a_date_not_void: a_date /= Void
set_date_time_to_now (a_date_time: DT_DATE_TIME)
        -- Set a_date_time to current UTC date time.
        -- (From DT_CLOCK.)
    require
        a_date_time_not_void: a_date_time /= Void
end -- class DT_UTC_SYSTEM_CLOCK

Copyright © 2001, Eric Bezault
mailto:
ericb@gobosoft.com
http:
//www.gobosoft.com
Last Updated: 10 October 2001

HomeTocPreviousNext