blob: 6810b89a7b683b8b9d5b62af19c468cba68733ff [file] [log] [blame]
// Copyright 2013 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.
// This file contains a set of utility functions related to parsing,
// manipulating, and interacting with URLs and hostnames. These functions are
// intended to be of a text-processing nature, and should not attempt to use any
// networking or blocking services.
#ifndef NET_BASE_URL_UTIL_H_
#define NET_BASE_URL_UTIL_H_
#include <string>
#include "base/strings/string_piece.h"
#define NET_EXPORT
class GURL;
namespace url {
struct CanonHostInfo;
namespace net {
// Canonicalizes |host| and returns it. Also fills |host_info| with
// IP address information. |host_info| must not be NULL.
NET_EXPORT std::string CanonicalizeHost(base::StringPiece host,
url::CanonHostInfo* host_info);
} // namespace net
} // namespace url
#endif // NET_BASE_URL_UTIL_H_