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

Side by Side Diff: Source/core/workers/SharedWorker.h

Issue 177073004: Oilpan: move core/workers to oilpan's heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2010 Apple Inc. All rights reserved. 3 * Copyright (C) 2010 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 23 matching lines...) Expand all
34 34
35 #include "core/workers/AbstractWorker.h" 35 #include "core/workers/AbstractWorker.h"
36 #include "platform/Supplementable.h" 36 #include "platform/Supplementable.h"
37 37
38 namespace WebCore { 38 namespace WebCore {
39 39
40 class ExceptionState; 40 class ExceptionState;
41 41
42 class SharedWorker FINAL : public AbstractWorker, public ScriptWrappable, public Supplementable<SharedWorker> { 42 class SharedWorker FINAL : public AbstractWorker, public ScriptWrappable, public Supplementable<SharedWorker> {
43 public: 43 public:
44 static PassRefPtr<SharedWorker> create(ExecutionContext*, const String& url, const String& name, ExceptionState&); 44 static PassRefPtrWillBeRawPtr<SharedWorker> create(ExecutionContext*, const String& url, const String& name, ExceptionState&);
45 virtual ~SharedWorker(); 45 virtual ~SharedWorker();
46 46
47 MessagePort* port() const { return m_port.get(); } 47 MessagePort* port() const { return m_port.get(); }
48 48
49 virtual const AtomicString& interfaceName() const OVERRIDE; 49 virtual const AtomicString& interfaceName() const OVERRIDE;
50 50
51 // Prevents this SharedWorker + JS wrapper from being garbage collected. 51 // Prevents this SharedWorker + JS wrapper from being garbage collected.
52 void setPreventGC(); 52 void setPreventGC();
53 // Allows this SharedWorker + JS wrapper to be garbage collected. 53 // Allows this SharedWorker + JS wrapper to be garbage collected.
54 void unsetPreventGC(); 54 void unsetPreventGC();
55 55
56 void trace(Visitor*);
57
56 private: 58 private:
57 explicit SharedWorker(ExecutionContext*); 59 explicit SharedWorker(ExecutionContext*);
58 60
59 RefPtr<MessagePort> m_port; 61 RefPtrWillBeMember<MessagePort> m_port;
60 }; 62 };
61 63
62 } // namespace WebCore 64 } // namespace WebCore
63 65
64 #endif // SharedWorker_h 66 #endif // SharedWorker_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698