diff options
author | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-28 23:48:44 +0000 |
---|---|---|
committer | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-28 23:48:44 +0000 |
commit | 9493ee95cd8475d2ce39276fddca3b4b3d3ae73e (patch) | |
tree | c9888c464ba0261f5daf7caaa6534c5510a12289 /base/md5.h | |
parent | 34ca58555bb67f8f72b84ba07b5c935928e2db3d (diff) | |
download | chromium_src-9493ee95cd8475d2ce39276fddca3b4b3d3ae73e.zip chromium_src-9493ee95cd8475d2ce39276fddca3b4b3d3ae73e.tar.gz chromium_src-9493ee95cd8475d2ce39276fddca3b4b3d3ae73e.tar.bz2 |
Base: Last set of files to use BASE_API (for base.dll)
Note that a bunck of these files have no unit tests :(
BUG=76996
TEST=none
Review URL: http://codereview.chromium.org/6747014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79633 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/md5.h')
-rw-r--r-- | base/md5.h | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -1,4 +1,4 @@ -// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -8,6 +8,8 @@ #include <string> +#include "base/base_api.h" + // MD5 stands for Message Digest algorithm 5. // MD5 is a robust hash function, designed for cyptography, but often used // for file checksums. The code is complex and slow, but has few @@ -42,25 +44,25 @@ typedef char MD5Context[88]; // Computes the MD5 sum of the given data buffer with the given length. // The given 'digest' structure will be filled with the result data. -void MD5Sum(const void* data, size_t length, MD5Digest* digest); +BASE_API void MD5Sum(const void* data, size_t length, MD5Digest* digest); // Initializes the given MD5 context structure for subsequent calls to // MD5Update(). -void MD5Init(MD5Context* context); +BASE_API void MD5Init(MD5Context* context); // For the given buffer of data, updates the given MD5 context with the sum of // the data. You can call this any number of times during the computation, // except that MD5Init() must have been called first. -void MD5Update(MD5Context* context, const void* buf, size_t len); +BASE_API void MD5Update(MD5Context* context, const void* buf, size_t len); // Finalizes the MD5 operation and fills the buffer with the digest. -void MD5Final(MD5Digest* digest, MD5Context* pCtx); +BASE_API void MD5Final(MD5Digest* digest, MD5Context* pCtx); // Converts a digest into human-readable hexadecimal. -std::string MD5DigestToBase16(const MD5Digest& digest); +BASE_API std::string MD5DigestToBase16(const MD5Digest& digest); // Returns the MD5 (in hexadecimal) of a string. -std::string MD5String(const std::string& str); +BASE_API std::string MD5String(const std::string& str); #endif // BASE_MD5_H_ |