Sha256: 74bb7ea77a1a11a856065976fbc421da450112df5e38e232b83c63e072c60c62

Contents?: true

Size: 497 Bytes

Versions: 240

Compression:

Stored size: 497 Bytes

Contents

#if !defined(CLOCK_H)
#define CLOCK_H

#include <string>

namespace date_independent
{

class clock
{
public:
    static clock at(int hour, int minute = 0);

    clock& plus(int minutes);
    clock& minus(int minutes);

    operator std::string() const;

    bool operator==(const clock& rhs) const;

private:
    clock(int hour, int minute);
    void clean();
    int hour_;
    int minute_;
};

inline bool operator!=(const clock& lhs, const clock& rhs)
{
    return !(lhs == rhs);
}

}

#endif

Version data entries

240 entries across 240 versions & 1 rubygems

Version Path
trackler-2.1.0.20 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.19 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.18 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.17 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.16 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.15 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.14 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.13 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.12 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.11 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.10 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.9 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.8 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.7 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.6 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.5 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.4 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.3 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.2 tracks/cpp/exercises/clock/example.h
trackler-2.1.0.1 tracks/cpp/exercises/clock/example.h