Differences From Artifact [c3a8ed0de1]:
- File src/OFCryptoHash.h — part of check-in [f663d40cbd] at 2017-05-13 16:29:52 on branch trunk — Also use nonatomic for non-object properties (user: js, size: 2511) [annotate] [blame] [check-ins using]
To Artifact [ab2417692f]:
- File
src/OFCryptoHash.h
— part of check-in
[f3ccf14461]
at
2017-10-29 21:58:14
on branch trunk
— Convert methods to properties where appropriate
This improves Swift compatibility. (user: js, size: 2485) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | */ @protocol OFCryptoHash <OFObject, OFCopying> /*! * A boolean whether the hash has already been calculated. */ @property (readonly, nonatomic, getter=isCalculated) bool calculated; /*! * @brief Creates a new cryptographic hash. * * @return A new autoreleased OFCryptoHash */ + (instancetype)cryptoHash; | > > > > > > > > > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | */ @protocol OFCryptoHash <OFObject, OFCopying> /*! * A boolean whether the hash has already been calculated. */ @property (readonly, nonatomic, getter=isCalculated) bool calculated; /*! * A buffer containing the cryptographic hash. * * The size of the buffer depends on the hash used. The buffer is part of the * receiver's memory pool. */ @property (readonly, nonatomic) const unsigned char *digest OF_RETURNS_INNER_POINTER; /*! * @brief Creates a new cryptographic hash. * * @return A new autoreleased OFCryptoHash */ + (instancetype)cryptoHash; |
︙ | ︙ | |||
59 60 61 62 63 64 65 | * * @param buffer The buffer which should be included into the calculation * @param length The length of the buffer */ - (void)updateWithBuffer: (const void *)buffer length: (size_t)length; | < < < < < < < < < < | 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 | * * @param buffer The buffer which should be included into the calculation * @param length The length of the buffer */ - (void)updateWithBuffer: (const void *)buffer length: (size_t)length; /*! * @brief Resets all state so that a new hash can be calculated. * * @warning This invalidates any pointer previously returned by @ref digest. If * you are still interested in the previous digest, you need to memcpy * it yourself before calling @ref reset! */ - (void)reset; @end OF_ASSUME_NONNULL_END |