mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-07 03:45:42 +00:00
73 lines
2.1 KiB
Plaintext
73 lines
2.1 KiB
Plaintext
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
|
*
|
|
* The contents of this file are subject to the Netscape Public License
|
|
* Version 1.0 (the "NPL"); you may not use this file except in
|
|
* compliance with the NPL. You may obtain a copy of the NPL at
|
|
* http://www.mozilla.org/NPL/
|
|
*
|
|
* Software distributed under the NPL is distributed on an "AS IS" basis,
|
|
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
|
|
* for the specific language governing rights and limitations under the
|
|
* NPL.
|
|
*
|
|
* The Initial Developer of this code under the NPL is Netscape
|
|
* Communications Corporation. Portions created by Netscape are
|
|
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
|
|
* Reserved.
|
|
*/
|
|
|
|
#include "nsISupports.idl"
|
|
#include "nsIRDFDataSource.idl"
|
|
|
|
// XXX Until these get scriptable. See nsIRDFXMLDataSource::AddNameSpace()
|
|
[ptr] native nsIAtomPtr(nsIAtom);
|
|
[ref] native nsStringRef(nsString);
|
|
%{C++
|
|
class nsIAtom;
|
|
class nsString;
|
|
%}
|
|
|
|
interface nsIRDFXMLDataSource;
|
|
|
|
[scriptable, uuid(EB1A5D30-AB33-11D2-8EC6-00805F29F370)]
|
|
interface nsIRDFXMLDataSourceObserver : nsISupports
|
|
{
|
|
void OnBeginLoad(in nsIRDFXMLDataSource aStream);
|
|
void OnInterrupt(in nsIRDFXMLDataSource aStream);
|
|
void OnResume(in nsIRDFXMLDataSource aStream);
|
|
void OnEndLoad(in nsIRDFXMLDataSource aStream);
|
|
};
|
|
|
|
|
|
|
|
[scriptable, uuid(EB1A5D31-AB33-11D2-8EC6-00805F29F370)]
|
|
interface nsIRDFXMLDataSource : nsIRDFDataSource
|
|
{
|
|
attribute boolean ReadOnly;
|
|
|
|
void Open(in boolean aBlocking);
|
|
|
|
void BeginLoad();
|
|
void Interrupt();
|
|
void Resume();
|
|
void EndLoad();
|
|
|
|
void AddNameSpace(in nsIAtomPtr aPrefix, [const] in nsStringRef aURI);
|
|
|
|
void AddXMLStreamObserver(in nsIRDFXMLDataSourceObserver aObserver);
|
|
void RemoveXMLStreamObserver(in nsIRDFXMLDataSourceObserver aObserver);
|
|
};
|
|
|
|
|
|
%{C++
|
|
|
|
// Two different kinds of XML data sources exist for RDF: serialized RDF and XUL.
|
|
// These are the methods that make these data sources.
|
|
extern nsresult
|
|
NS_NewRDFXMLDataSource(nsIRDFXMLDataSource** result);
|
|
|
|
extern nsresult
|
|
NS_NewXULDataSource(nsIRDFXMLDataSource** result);
|
|
|
|
%}
|