diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-16 21:32:10 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-16 21:32:10 +0000 |
commit | 127dd58a7dae9f8492bb2426ce190d7d2c9ca1d7 (patch) | |
tree | deaa6d755e460f647d14d49cf963eb3b1cb509bf /content/common/serialized_script_value.h | |
parent | 25f8a30ee91813f9216c6e9b23eaf760a3bd02a8 (diff) | |
download | chromium_src-127dd58a7dae9f8492bb2426ce190d7d2c9ca1d7.zip chromium_src-127dd58a7dae9f8492bb2426ce190d7d2c9ca1d7.tar.gz chromium_src-127dd58a7dae9f8492bb2426ce190d7d2c9ca1d7.tar.bz2 |
Move all the message files in chrome that belong in content.
TBR=avi
Review URL: http://codereview.chromium.org/6672057
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78435 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/common/serialized_script_value.h')
-rw-r--r-- | content/common/serialized_script_value.h | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/content/common/serialized_script_value.h b/content/common/serialized_script_value.h new file mode 100644 index 0000000..7352298 --- /dev/null +++ b/content/common/serialized_script_value.h @@ -0,0 +1,41 @@ +// 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 CONTENT_COMMON_SERIALIZED_SCRIPT_VALUE_H_ +#define CONTENT_COMMON_SERIALIZED_SCRIPT_VALUE_H_ +#pragma once + +#include "base/string16.h" + +namespace WebKit { +class WebSerializedScriptValue; +} + +class SerializedScriptValue { + public: + SerializedScriptValue(); + SerializedScriptValue(bool is_null, bool is_invalid, const string16& data); + explicit SerializedScriptValue(const WebKit::WebSerializedScriptValue& value); + + void set_is_null(bool is_null) { is_null_ = is_null; } + bool is_null() const { return is_null_; } + + void set_is_invalid(bool is_invalid) { is_invalid_ = is_invalid; } + bool is_invalid() const { return is_invalid_; } + + void set_data(const string16& data) { data_ = data; } + const string16& data() const { return data_; } + + void set_web_serialized_script_value( + const WebKit::WebSerializedScriptValue& value); + + operator WebKit::WebSerializedScriptValue() const; + + private: + bool is_null_; // Is this null? If so, none of the other properties are valid. + bool is_invalid_; // Is data_ valid? + string16 data_; // The wire string format of the serialized script value. +}; + +#endif // CONTENT_COMMON_SERIALIZED_SCRIPT_VALUE_H_ |