NSData+YYAdd.h 840 B

123456789101112131415161718192021222324252627282930313233
  1. //
  2. // NSData+YYAdd.h
  3. // YYKit <https://github.com/ibireme/YYKit>
  4. //
  5. // Created by ibireme on 13/4/4.
  6. // Copyright (c) 2015 ibireme.
  7. //
  8. // This source code is licensed under the MIT-style license found in the
  9. // LICENSE file in the root directory of this source tree.
  10. //
  11. #import <Foundation/Foundation.h>
  12. /**
  13. Provide hash, encrypt, encode and some common method for `NSData`.
  14. */
  15. @interface NSData (YYAdd)
  16. #pragma mark - Others
  17. ///=============================================================================
  18. /// @name Others
  19. ///=============================================================================
  20. /**
  21. Create data from the file in main bundle (similar to [UIImage imageNamed:]).
  22. @param name The file name (in main bundle).
  23. @return A new data create from the file.
  24. */
  25. + (NSData *)dataNamed:(NSString *)name;
  26. @end