| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2008 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2013 Google Inc. All rights reserved. | 3 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 virtual String LanguageAttributeValue() const = 0; | 53 virtual String LanguageAttributeValue() const = 0; |
| 54 virtual bool NomoduleAttributeValue() const = 0; | 54 virtual bool NomoduleAttributeValue() const = 0; |
| 55 virtual String SourceAttributeValue() const = 0; | 55 virtual String SourceAttributeValue() const = 0; |
| 56 virtual String TypeAttributeValue() const = 0; | 56 virtual String TypeAttributeValue() const = 0; |
| 57 | 57 |
| 58 virtual String TextFromChildren() = 0; | 58 virtual String TextFromChildren() = 0; |
| 59 virtual String TextContent() const = 0; | 59 virtual String TextContent() const = 0; |
| 60 virtual bool HasSourceAttribute() const = 0; | 60 virtual bool HasSourceAttribute() const = 0; |
| 61 virtual bool IsConnected() const = 0; | 61 virtual bool IsConnected() const = 0; |
| 62 virtual bool HasChildren() const = 0; | 62 virtual bool HasChildren() const = 0; |
| 63 virtual bool IsNonceableElement() const = 0; | 63 virtual const AtomicString& GetNonceForElement() const = 0; |
| 64 virtual AtomicString InitiatorName() const = 0; | 64 virtual AtomicString InitiatorName() const = 0; |
| 65 | 65 |
| 66 virtual bool AllowInlineScriptForCSP(const AtomicString& nonce, | 66 virtual bool AllowInlineScriptForCSP(const AtomicString& nonce, |
| 67 const WTF::OrdinalNumber&, | 67 const WTF::OrdinalNumber&, |
| 68 const String& script_content) = 0; | 68 const String& script_content) = 0; |
| 69 virtual Document& GetDocument() const = 0; | 69 virtual Document& GetDocument() const = 0; |
| 70 virtual void SetScriptElementForBinding( | 70 virtual void SetScriptElementForBinding( |
| 71 HTMLScriptElementOrSVGScriptElement&) = 0; | 71 HTMLScriptElementOrSVGScriptElement&) = 0; |
| 72 | 72 |
| 73 ScriptLoader* Loader() const { return loader_.Get(); } | 73 ScriptLoader* Loader() const { return loader_.Get(); } |
| 74 | 74 |
| 75 AtomicString nonce() const { return nonce_; } | |
| 76 void setNonce(const String& nonce) { nonce_ = AtomicString(nonce); } | |
| 77 | |
| 78 DECLARE_VIRTUAL_TRACE(); | 75 DECLARE_VIRTUAL_TRACE(); |
| 79 | 76 |
| 80 protected: | 77 protected: |
| 81 void InitializeScriptLoader(bool parser_inserted, | 78 void InitializeScriptLoader(bool parser_inserted, |
| 82 bool already_started, | 79 bool already_started, |
| 83 bool created_during_document_write); | 80 bool created_during_document_write); |
| 84 | 81 |
| 85 Member<ScriptLoader> loader_; | 82 Member<ScriptLoader> loader_; |
| 86 | |
| 87 private: | |
| 88 AtomicString nonce_; | |
| 89 }; | 83 }; |
| 90 | 84 |
| 91 } // namespace blink | 85 } // namespace blink |
| 92 | 86 |
| 93 #endif | 87 #endif |
| OLD | NEW |