Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5558)

Unified Diff: chrome/test/webdriver/cookie.h

Issue 6330012: Cookie commands for the webdriver protocol (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: dsdsdsdjsdsj Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/test/webdriver/cookie.h
diff --git a/chrome/test/webdriver/cookie.h b/chrome/test/webdriver/cookie.h
new file mode 100644
index 0000000000000000000000000000000000000000..f61881cd97760b2b0d56e8f9290e3282d8d03c6d
--- /dev/null
+++ b/chrome/test/webdriver/cookie.h
@@ -0,0 +1,43 @@
+// Copyright (c) 2010 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.
+
+#ifndef CHROME_TEST_WEBDRIVER_COOKIE_H_
+#define CHROME_TEST_WEBDRIVER_COOKIE_H_
+#pragma once
+
+#include <string>
+
+#include "base/values.h"
+
+namespace webdriver {
+
+// Class used to convert cookies to various formats.
+class Cookie {
+ public:
+ explicit Cookie(const std::string& cookie);
+ explicit Cookie(const DictionaryValue& dict);
+
+ DictionaryValue* ToDictionary();
+ std::string ToJSONString();
John Grabowski 2011/02/14 21:59:06 Like. Can you give a brief example in comments as
Joe 2011/02/15 02:30:48 Done.
+ std::string ToString();
+
+ bool IsValid() const { return valid_; }
+ const std::string get_name() const { return name_; }
+
+ private:
+ std::string name_;
+ std::string value_;
+ std::string path_;
+ std::string domain_;
+ std::string expires_;
+ bool secure_;
+ bool http_;
+ bool valid_;
+
+ DISALLOW_COPY_AND_ASSIGN(Cookie);
+};
+
+} // namespace webdriver
+
+#endif // CHROME_TEST_WEBDRIVER_COOKIE_H_

Powered by Google App Engine
This is Rietveld 408576698