Add static has function to save a copy. Use <0 for 'whole object', not 0.

This commit is contained in:
JoelKatz
2011-12-02 16:23:46 -08:00
parent 150a3165c4
commit d61c8ae013
2 changed files with 13 additions and 7 deletions

View File

@@ -39,9 +39,10 @@ class Serializer
std::vector<unsigned char> getRaw(int offset, int length) const;
// hash functions
uint160 getRIPEMD160(int size=0) const;
uint256 getSHA256(int size=0) const;
uint256 getSHA512Half(int size=0) const;
uint160 getRIPEMD160(int size=-1) const;
uint256 getSHA256(int size=-1) const;
uint256 getSHA512Half(int size=-1) const;
static uint256 getSHA512Half(const std::vector<unsigned char>& data, int size=-1);
// totality functions
int getLength() const { return mData.size(); }