TuttleOFX  1
TuttleOFX/libraries/tuttle/src/tuttle/host/NodeAtTimeKey.hpp
Go to the documentation of this file.
00001 #ifndef _TUTTLE_HOST_NODEATTIMEKEY_HPP_
00002 #define _TUTTLE_HOST_NODEATTIMEKEY_HPP_
00003 
00004 #include <ofxCore.h>
00005 
00006 #include <string>
00007 #include <ostream>
00008 
00009 namespace tuttle {
00010 namespace host {
00011 
00012 class NodeAtTimeKey
00013 {
00014 public:
00015         NodeAtTimeKey()
00016         : _time(-9876.54321)
00017         {}
00018         NodeAtTimeKey( const std::string& name, const OfxTime& time )
00019         : _name(name)
00020         , _time(time)
00021         {}
00022         
00023         const std::string& getName() const { return _name; }
00024         void setName( const std::string& name ) { _name = name; }
00025 
00026         OfxTime getTime() const { return _time; }
00027         void setTime( const OfxTime time ) { _time = time; }
00028 
00029         bool operator==( const NodeAtTimeKey& v ) const;
00030         bool operator<( const NodeAtTimeKey& v ) const;
00031 
00032         std::size_t getHash() const;
00033 
00034 public:
00035         friend std::ostream& operator<<( std::ostream& os, const NodeAtTimeKey& k );
00036 
00037 private:
00038         std::string _name;
00039         OfxTime _time;
00040 };
00041 
00042 }
00043 }
00044 
00045 #endif
00046