Home | History | Annotate | Download | only in base
      1 // Copyright 2014 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #ifndef NET_BASE_FILENAME_UTIL_UNSAFE_H_
      6 #define NET_BASE_FILENAME_UTIL_UNSAFE_H_
      7 
      8 #include <string>
      9 
     10 #include "base/files/file_path.h"
     11 #include "base/strings/string16.h"
     12 #include "net/base/net_export.h"
     13 
     14 class GURL;
     15 
     16 namespace net {
     17 
     18 // Extract extension from FilePath generated by GenerateFileName(), but without
     19 // replacing illegal characters. Does not depend on ICU.
     20 NET_EXPORT base::FilePath::StringType GenerateFileExtensionUnsafe(
     21     const GURL& url,
     22     const std::string& content_disposition,
     23     const std::string& referrer_charset,
     24     const std::string& suggested_name,
     25     const std::string& mime_type,
     26     const std::string& default_name);
     27 
     28 }  // namespace net
     29 
     30 #endif  // NET_BASE_FILENAME_UTIL_UNSAFE_H_
     31