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. 4 5 /** 6 * @fileoverview Implements a helper using USB gnubbies. 7 */ 8 'use strict'; 9 10 /** 11 * @constructor 12 * @extends {GenericRequestHelper} 13 */ 14 function UsbHelper() { 15 GenericRequestHelper.apply(this, arguments); 16 17 var self = this; 18 this.registerHandlerFactory('enroll_helper_request', function(request) { 19 return new UsbEnrollHandler(/** @type {EnrollHelperRequest} */ (request)); 20 }); 21 this.registerHandlerFactory('sign_helper_request', function(request) { 22 return new UsbSignHandler(/** @type {SignHelperRequest} */ (request)); 23 }); 24 } 25 26 inherits(UsbHelper, GenericRequestHelper); 27