1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/netwerk/protocol/app/AppProtocolHandler.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,35 @@ 1.4 +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 1.5 +/* vim:set expandtab ts=4 sw=4 sts=4 cin: */ 1.6 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.7 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.8 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.9 + 1.10 +#ifndef AppProtocolHandler_ 1.11 +#define AppProtocolHandler_ 1.12 + 1.13 +#include "nsIProtocolHandler.h" 1.14 +#include "nsClassHashtable.h" 1.15 +#include "mozilla/dom/AppInfoBinding.h" 1.16 + 1.17 +class AppProtocolHandler : public nsIProtocolHandler 1.18 +{ 1.19 +public: 1.20 + NS_DECL_ISUPPORTS 1.21 + 1.22 + // nsIProtocolHandler methods: 1.23 + NS_DECL_NSIPROTOCOLHANDLER 1.24 + 1.25 + // AppProtocolHandler methods: 1.26 + AppProtocolHandler(); 1.27 + virtual ~AppProtocolHandler(); 1.28 + 1.29 + // Define a Create method to be used with a factory: 1.30 + static nsresult Create(nsISupports* aOuter, 1.31 + const nsIID& aIID, 1.32 + void* *aResult); 1.33 + 1.34 +private: 1.35 + nsClassHashtable<nsCStringHashKey, mozilla::dom::AppInfo> mAppInfoCache; 1.36 +}; 1.37 + 1.38 +#endif /* AppProtocolHandler_ */