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

Side by Side Diff: sky/shell/dart/dart_library_provider_network.h

Issue 1203143004: Make it possible to run Sky apps offline (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: gn check Created 5 years, 5 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
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_
6 #define SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_
7
8 #include "mojo/services/network/public/interfaces/network_service.mojom.h"
9 #include "sky/engine/tonic/dart_library_provider.h"
10 #include "sky/engine/wtf/HashSet.h"
11 #include "sky/engine/wtf/OwnPtr.h"
12
13 namespace sky {
14 namespace shell {
15
16 class DartLibraryProviderNetwork : public blink::DartLibraryProvider {
17 public:
18 explicit DartLibraryProviderNetwork(mojo::NetworkService* network_service);
19 ~DartLibraryProviderNetwork() override;
20
21 mojo::NetworkService* network_service() const { return network_service_; }
22
23 protected:
24 // |DartLibraryProvider| implementation:
25 void GetLibraryAsStream(const String& name,
26 blink::DataPipeConsumerCallback callback) override;
27 Dart_Handle CanonicalizeURL(Dart_Handle library, Dart_Handle url) override;
28
29 private:
30 class Job;
31
32 mojo::NetworkService* network_service_;
33 HashSet<OwnPtr<Job>> jobs_;
34
35 DISALLOW_COPY_AND_ASSIGN(DartLibraryProviderNetwork);
36 };
37
38 } // namespace shell
39 } // namespace sky
40
41 #endif // SKY_SHELL_DART_DART_LIBRARY_PROVIDER_NETWORK_H_
OLDNEW
« no previous file with comments | « sky/shell/dart/dart_library_provider_files.cc ('k') | sky/shell/dart/dart_library_provider_network.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698