Commit 0cdbf858 authored by Jeremy Roman's avatar Jeremy Roman Committed by Commit Bot

Add a summary comment to blink::Supplementable.

There is existing documentation about the details, but as yet no overall
"what is this thing" summary.

Change-Id: I057d1c67a8f7d5fe1cbbeb65505a3be0419bfafc
Reviewed-on: https://chromium-review.googlesource.com/1246951
Commit-Queue: Jeremy Roman <jbroman@chromium.org>
Reviewed-by: default avatarKentaro Hara <haraken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#594696}
parent 712d4017
......@@ -40,6 +40,16 @@ namespace blink {
// What you should know about Supplementable and Supplement
// ========================================================
// Supplementable allows a garbage-collected object to be extended with
// additional data.
//
// Most commonly, this is used to attach data to a central object, such as
// LocalFrame, so that it can be easily accessed. This is similar to adding a
// member to that class (e.g. it is kept alive while the supplementable is),
// except that it occupies less memory if not used, and can be done in cases
// that would otherwise be a layering violation. For example, it is common for
// features implemented in modules/ to supplement classes in core/.
//
// Supplementable and Supplement instances are meant to be thread local. They
// should only be accessed from within the thread that created them. The
// 2 classes are not designed for safe access from another thread. Violating
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment