Index: chrome/test/webdriver/web_element_id.h |
diff --git a/chrome/test/webdriver/web_element_id.h b/chrome/test/webdriver/web_element_id.h |
index 037f6335fc3fd673ba042e07118939cc475c3df3..05716f5eef3080aff9aaa4f8a978b26e5a230b27 100644 |
--- a/chrome/test/webdriver/web_element_id.h |
+++ b/chrome/test/webdriver/web_element_id.h |
@@ -8,6 +8,8 @@ |
#include <string> |
+#include "chrome/test/automation/value_conversion_traits.h" |
+ |
namespace base { |
class Value; |
} |
@@ -27,7 +29,7 @@ class WebElementId { |
// Creates a |WebElementId| from an element dictionary returned by a WebDriver |
// atom. It will be valid iff the dictionary is correctly constructed. |
- explicit WebElementId(base::Value* value); |
+ explicit WebElementId(const base::Value* value); |
~WebElementId(); |
@@ -60,4 +62,12 @@ struct LocatorType { |
} // namespace webdriver |
+template <> |
+struct ValueConversionTraits<webdriver::WebElementId> { |
Paweł Hajdan Jr.
2011/08/02 20:04:47
Why here? I think you may risk different behavior
kkania
2011/08/03 17:07:56
I was not quite sure where to put it myself. I tho
Paweł Hajdan Jr.
2011/08/04 17:51:36
After thinking more about it I still think it'd be
|
+ static base::Value* CreateValueFrom(const webdriver::WebElementId& t); |
+ static bool SetFromValue( |
+ const base::Value* value, webdriver::WebElementId* t); |
+ static bool CanConvert(const base::Value* value); |
+}; |
+ |
#endif // CHROME_TEST_WEBDRIVER_WEB_ELEMENT_ID_H_ |