Home | History | Annotate | Download | only in base
      1 // Copyright (c) 2010 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 #include "net/base/cookie_store.h"
      6 
      7 #include "net/base/cookie_options.h"
      8 
      9 namespace net {
     10 
     11 bool CookieStore::SetCookie(const GURL& url, const std::string& cookie_line) {
     12   return SetCookieWithOptions(url, cookie_line, CookieOptions());
     13 }
     14 
     15 std::string CookieStore::GetCookies(const GURL& url) {
     16   return GetCookiesWithOptions(url, CookieOptions());
     17 }
     18 
     19 void CookieStore::SetCookiesWithOptions(
     20     const GURL& url,
     21     const std::vector<std::string>& cookie_lines,
     22     const CookieOptions& options) {
     23   for (size_t i = 0; i < cookie_lines.size(); ++i)
     24     SetCookieWithOptions(url, cookie_lines[i], options);
     25 }
     26 
     27 void CookieStore::SetCookies(const GURL& url,
     28                              const std::vector<std::string>& cookie_lines) {
     29   SetCookiesWithOptions(url, cookie_lines, CookieOptions());
     30 }
     31 
     32 CookieStore::CookieStore() {}
     33 
     34 CookieStore::~CookieStore() {}
     35 
     36 }  // namespace net
     37