1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/toolkit/components/feeds/nsIFeedResult.idl Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,65 @@ 1.4 +/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#include "nsISupports.idl" 1.10 +interface nsIFeedContainer; 1.11 +interface nsIProperties; 1.12 +interface nsIURI; 1.13 + 1.14 +/** 1.15 + * The nsIFeedResult interface provides access to HTTP and parsing 1.16 + * metadata for a feed or entry. 1.17 + */ 1.18 +[scriptable, uuid(7a180b78-0f46-4569-8c22-f3d720ea1c57)] 1.19 +interface nsIFeedResult : nsISupports { 1.20 + 1.21 + /** 1.22 + * The Feed parser will set the bozo bit when a feed triggers a fatal 1.23 + * error during XML parsing. There may be entries and feed metadata 1.24 + * that were parsed before the error. Thanks to Tim Bray for 1.25 + * suggesting this terminology. 1.26 + * <http://www.tbray.org/ongoing/When/200x/2004/01/11/PostelPilgrim> 1.27 + */ 1.28 + attribute boolean bozo; 1.29 + 1.30 + /** 1.31 + * The parsed feed or entry. 1.32 + * 1.33 + * Will be null if a non-feed is processed. 1.34 + */ 1.35 + attribute nsIFeedContainer doc; 1.36 + 1.37 + /** 1.38 + * The address from which the feed was fetched. 1.39 + */ 1.40 + attribute nsIURI uri; 1.41 + 1.42 + /** 1.43 + * Feed Version: 1.44 + * atom, rss2, rss09, rss091, rss091userland, rss092, rss1, atom03, 1.45 + * atomEntry, rssItem 1.46 + * 1.47 + * Will be null if a non-feed is processed. 1.48 + */ 1.49 + attribute AString version; 1.50 + 1.51 + /** 1.52 + * An XSLT stylesheet available to transform the source of the 1.53 + * feed. Some feeds include this information in a processing 1.54 + * instruction. It's generally intended for clients with specific 1.55 + * feed capabilities. 1.56 + */ 1.57 + attribute nsIURI stylesheet; 1.58 + 1.59 + /** 1.60 + * HTTP response headers that accompanied the feed. 1.61 + */ 1.62 + attribute nsIProperties headers; 1.63 + 1.64 + /** 1.65 + * Registers a prefix used to access an extension in the feed/entry 1.66 + */ 1.67 + void registerExtensionPrefix(in AString aNamespace, in AString aPrefix); 1.68 +};