Add testing/scripts/OWNERS
[chromium-blink-merge.git] / chrome / renderer / resources / extensions / log_private_custom_bindings.js
blobae209d07ef7bfe6460cdf9cdfa92f3fe8c78027a
1 // Copyright 2014 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.
5 // Custom binding for the logPrivate API.
6 var binding = require('binding').Binding.create('logPrivate');
7 var sendRequest = require('sendRequest');
9 var getFileBindingsForApi =
10     require('fileEntryBindingUtil').getFileBindingsForApi;
11 var fileBindings = getFileBindingsForApi('logPrivate');
12 var bindFileEntryCallback = fileBindings.bindFileEntryCallback;
14 binding.registerCustomHook(function(bindingsAPI) {
15   var apiFunctions = bindingsAPI.apiFunctions;
16   var fileSystem = bindingsAPI.compiledApi;
18   $Array.forEach(['dumpLogs'],
19                   function(functionName) {
20     bindFileEntryCallback(functionName, apiFunctions);
21   });
23 });
25 exports.bindFileEntryCallback = bindFileEntryCallback;
26 exports.binding = binding.generate();