adding more helper methods to time and elliptic crypto
This commit is contained in:
parent
105948ea65
commit
c88ce7984e
2 changed files with 6 additions and 2 deletions
|
|
@ -31,6 +31,9 @@ namespace fc {
|
||||||
~public_key();
|
~public_key();
|
||||||
bool verify( const fc::sha256& digest, const signature& sig );
|
bool verify( const fc::sha256& digest, const signature& sig );
|
||||||
public_key_data serialize()const;
|
public_key_data serialize()const;
|
||||||
|
|
||||||
|
operator public_key_data()const { return serialize(); }
|
||||||
|
|
||||||
public_key( const public_key_data& v );
|
public_key( const public_key_data& v );
|
||||||
public_key( const compact_signature& c, const fc::sha256& digest );
|
public_key( const compact_signature& c, const fc::sha256& digest );
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -76,6 +76,7 @@ namespace fc {
|
||||||
}
|
}
|
||||||
friend bool operator < ( const time_point_sec& a, const time_point_sec& b ) { return a.utc_seconds < b.utc_seconds; }
|
friend bool operator < ( const time_point_sec& a, const time_point_sec& b ) { return a.utc_seconds < b.utc_seconds; }
|
||||||
friend bool operator > ( const time_point_sec& a, const time_point_sec& b ) { return a.utc_seconds > b.utc_seconds; }
|
friend bool operator > ( const time_point_sec& a, const time_point_sec& b ) { return a.utc_seconds > b.utc_seconds; }
|
||||||
|
friend bool operator == ( const time_point_sec& a, const time_point_sec& b ) { return a.utc_seconds == b.utc_seconds; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
uint32_t utc_seconds;
|
uint32_t utc_seconds;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue