Commit a5f1f22a authored by dougt%netscape.com's avatar dougt%netscape.com
Browse files

First checkin of our interface and IIDs

parent cc2a1cf9
Loading
Loading
Loading
Loading
+32 −0
Original line number Diff line number Diff line
#!nmake
#
# 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.

DEPTH=..\..

DEFINES=-D_IMPL_NS_DOM 

EXPORTS=	nsIDOMInstall.h              \
			nsIDOMInstallTriggerGlobal.h \
			nsIDOMInstallVersion.h       \
            nsIDOMInstallFolder.h       \
            nsSoftwareUpdateIIDs.h       \
			nsISoftwareUpdate.h

MODULE=xpinstall 

include <$(DEPTH)\config\rules.mak>
+176 −0
Original line number Diff line number Diff line
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * 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.
 */
/* AUTO-GENERATED. DO NOT EDIT!!! */

#ifndef nsIDOMInstall_h__
#define nsIDOMInstall_h__

#include "nsISupports.h"
#include "nsString.h"
#include "nsIScriptContext.h"

class nsIDOMInstallFolder;
class nsIDOMInstallVersion;

#define NS_IDOMINSTALL_IID \
 { 0x18c2f988, 0xb09f, 0x11d2, \
  {0xbc, 0xde, 0x00, 0x80, 0x5f, 0x0e, 0x13, 0x53}} 

class nsIDOMInstall : public nsISupports {
public:
  static const nsIID& IID() { static nsIID iid = NS_IDOMINSTALL_IID; return iid; }
  enum {
    SUERR_BAD_PACKAGE_NAME = -200,
    SUERR_UNEXPECTED_ERROR = -201,
    SUERR_ACCESS_DENIED = -202,
    SUERR_TOO_MANY_CERTIFICATES = -203,
    SUERR_NO_INSTALLER_CERTIFICATE = -204,
    SUERR_NO_CERTIFICATE = -205,
    SUERR_NO_MATCHING_CERTIFICATE = -206,
    SUERR_UNKNOWN_JAR_FILE = -207,
    SUERR_INVALID_ARGUMENTS = -208,
    SUERR_ILLEGAL_RELATIVE_PATH = -209,
    SUERR_USER_CANCELLED = -210,
    SUERR_INSTALL_NOT_STARTED = -211,
    SUERR_SILENT_MODE_DENIED = -212,
    SUERR_NO_SUCH_COMPONENT = -213,
    SUERR_FILE_DOES_NOT_EXIST = -214,
    SUERR_FILE_READ_ONLY = -215,
    SUERR_FILE_IS_DIRECTORY = -216,
    SUERR_NETWORK_FILE_IS_IN_USE = -217,
    SUERR_APPLE_SINGLE_ERR = -218,
    SUERR_INVALID_PATH_ERR = -219,
    SUERR_PATCH_BAD_DIFF = -220,
    SUERR_PATCH_BAD_CHECKSUM_TARGET = -221,
    SUERR_PATCH_BAD_CHECKSUM_RESULT = -222,
    SUERR_UNINSTALL_FAILED = -223,
    SUERR_GESTALT_UNKNOWN_ERR = -5550,
    SUERR_GESTALT_INVALID_ARGUMENT = -5551,
    SU_SUCCESS = 0,
    SU_REBOOT_NEEDED = 999,
    SU_LIMITED_INSTALL = 0,
    SU_FULL_INSTALL = 1,
    SU_NO_STATUS_DLG = 2,
    SU_NO_FINALIZE_DLG = 4,
    SU_INSTALL_FILE_UNEXPECTED_MSG_ID = 0,
    SU_DETAILS_REPLACE_FILE_MSG_ID = 1,
    SU_DETAILS_INSTALL_FILE_MSG_ID = 2
  };

  NS_IMETHOD    GetUserPackageName(nsString& aUserPackageName)=0;

  NS_IMETHOD    GetRegPackageName(nsString& aRegPackageName)=0;

  NS_IMETHOD    AbortInstall()=0;

  NS_IMETHOD    AddDirectory(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aSubdir, PRBool aForceMode, PRInt32* aReturn)=0;

  NS_IMETHOD    AddSubcomponent(const nsString& aRegName, nsIDOMInstallVersion* aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRBool aForceMode, PRInt32* aReturn)=0;

  NS_IMETHOD    DeleteComponent(const nsString& aRegistryName, PRInt32* aReturn)=0;

  NS_IMETHOD    DeleteFile(nsIDOMInstallFolder* aFolder, const nsString& aRelativeFileName, PRInt32* aReturn)=0;

  NS_IMETHOD    DiskSpaceAvailable(nsIDOMInstallFolder* aFolder, PRInt32* aReturn)=0;

  NS_IMETHOD    Execute(const nsString& aJarSource, const nsString& aArgs, PRInt32* aReturn)=0;

  NS_IMETHOD    FinalizeInstall(PRInt32* aReturn)=0;

  NS_IMETHOD    Gestalt(const nsString& aSelector, PRInt32* aReturn)=0;

  NS_IMETHOD    GetComponentFolder(const nsString& aRegName, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn)=0;

  NS_IMETHOD    GetFolder(nsIDOMInstallFolder* aTargetFolder, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn)=0;

  NS_IMETHOD    GetLastError(PRInt32* aReturn)=0;

  NS_IMETHOD    GetWinProfile(nsIDOMInstallFolder* aFolder, const nsString& aFile, PRInt32* aReturn)=0;

  NS_IMETHOD    GetWinRegistry(PRInt32* aReturn)=0;

  NS_IMETHOD    Patch(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRInt32* aReturn)=0;

  NS_IMETHOD    ResetError()=0;

  NS_IMETHOD    SetPackageFolder(nsIDOMInstallFolder* aFolder)=0;

  NS_IMETHOD    StartInstall(const nsString& aUserPackageName, const nsString& aPackageName, const nsString& aVersion, PRInt32 aFlags, PRInt32* aReturn)=0;

  NS_IMETHOD    Uninstall(const nsString& aPackageName, PRInt32* aReturn)=0;

  NS_IMETHOD    ExtractFileFromJar(const nsString& aJarfile, const nsString& aFinalFile, nsString& aTempFile, nsString& aErrorMsg)=0;
};


#define NS_DECL_IDOMINSTALL   \
  NS_IMETHOD    GetUserPackageName(nsString& aUserPackageName);  \
  NS_IMETHOD    GetRegPackageName(nsString& aRegPackageName);  \
  NS_IMETHOD    AbortInstall();  \
  NS_IMETHOD    AddDirectory(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aSubdir, PRBool aForceMode, PRInt32* aReturn);  \
  NS_IMETHOD    AddSubcomponent(const nsString& aRegName, nsIDOMInstallVersion* aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRBool aForceMode, PRInt32* aReturn);  \
  NS_IMETHOD    DeleteComponent(const nsString& aRegistryName, PRInt32* aReturn);  \
  NS_IMETHOD    DeleteFile(nsIDOMInstallFolder* aFolder, const nsString& aRelativeFileName, PRInt32* aReturn);  \
  NS_IMETHOD    DiskSpaceAvailable(nsIDOMInstallFolder* aFolder, PRInt32* aReturn);  \
  NS_IMETHOD    Execute(const nsString& aJarSource, const nsString& aArgs, PRInt32* aReturn);  \
  NS_IMETHOD    FinalizeInstall(PRInt32* aReturn);  \
  NS_IMETHOD    Gestalt(const nsString& aSelector, PRInt32* aReturn);  \
  NS_IMETHOD    GetComponentFolder(const nsString& aRegName, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn);  \
  NS_IMETHOD    GetFolder(nsIDOMInstallFolder* aTargetFolder, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn);  \
  NS_IMETHOD    GetLastError(PRInt32* aReturn);  \
  NS_IMETHOD    GetWinProfile(nsIDOMInstallFolder* aFolder, const nsString& aFile, PRInt32* aReturn);  \
  NS_IMETHOD    GetWinRegistry(PRInt32* aReturn);  \
  NS_IMETHOD    Patch(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRInt32* aReturn);  \
  NS_IMETHOD    ResetError();  \
  NS_IMETHOD    SetPackageFolder(nsIDOMInstallFolder* aFolder);  \
  NS_IMETHOD    StartInstall(const nsString& aUserPackageName, const nsString& aPackageName, const nsString& aVersion, PRInt32 aFlags, PRInt32* aReturn);  \
  NS_IMETHOD    Uninstall(const nsString& aPackageName, PRInt32* aReturn);  \
  NS_IMETHOD    ExtractFileFromJar(const nsString& aJarfile, const nsString& aFinalFile, nsString& aTempFile, nsString& aErrorMsg);  \



#define NS_FORWARD_IDOMINSTALL(_to)  \
  NS_IMETHOD    GetUserPackageName(nsString& aUserPackageName) { return _to##GetUserPackageName(aUserPackageName); } \
  NS_IMETHOD    GetRegPackageName(nsString& aRegPackageName) { return _to##GetRegPackageName(aRegPackageName); } \
  NS_IMETHOD    AbortInstall() { return _to##AbortInstall(); }  \
  NS_IMETHOD    AddDirectory(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aSubdir, PRBool aForceMode, PRInt32* aReturn) { return _to##AddDirectory(aRegName, aVersion, aJarSource, aFolder, aSubdir, aForceMode, aReturn); }  \
  NS_IMETHOD    AddSubcomponent(const nsString& aRegName, nsIDOMInstallVersion* aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRBool aForceMode, PRInt32* aReturn) { return _to##AddSubcomponent(aRegName, aVersion, aJarSource, aFolder, aTargetName, aForceMode, aReturn); }  \
  NS_IMETHOD    DeleteComponent(const nsString& aRegistryName, PRInt32* aReturn) { return _to##DeleteComponent(aRegistryName, aReturn); }  \
  NS_IMETHOD    DeleteFile(nsIDOMInstallFolder* aFolder, const nsString& aRelativeFileName, PRInt32* aReturn) { return _to##DeleteFile(aFolder, aRelativeFileName, aReturn); }  \
  NS_IMETHOD    DiskSpaceAvailable(nsIDOMInstallFolder* aFolder, PRInt32* aReturn) { return _to##DiskSpaceAvailable(aFolder, aReturn); }  \
  NS_IMETHOD    Execute(const nsString& aJarSource, const nsString& aArgs, PRInt32* aReturn) { return _to##Execute(aJarSource, aArgs, aReturn); }  \
  NS_IMETHOD    FinalizeInstall(PRInt32* aReturn) { return _to##FinalizeInstall(aReturn); }  \
  NS_IMETHOD    Gestalt(const nsString& aSelector, PRInt32* aReturn) { return _to##Gestalt(aSelector, aReturn); }  \
  NS_IMETHOD    GetComponentFolder(const nsString& aRegName, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn) { return _to##GetComponentFolder(aRegName, aSubdirectory, aReturn); }  \
  NS_IMETHOD    GetFolder(nsIDOMInstallFolder* aTargetFolder, const nsString& aSubdirectory, nsIDOMInstallFolder** aReturn) { return _to##GetFolder(aTargetFolder, aSubdirectory, aReturn); }  \
  NS_IMETHOD    GetLastError(PRInt32* aReturn) { return _to##GetLastError(aReturn); }  \
  NS_IMETHOD    GetWinProfile(nsIDOMInstallFolder* aFolder, const nsString& aFile, PRInt32* aReturn) { return _to##GetWinProfile(aFolder, aFile, aReturn); }  \
  NS_IMETHOD    GetWinRegistry(PRInt32* aReturn) { return _to##GetWinRegistry(aReturn); }  \
  NS_IMETHOD    Patch(const nsString& aRegName, const nsString& aVersion, const nsString& aJarSource, nsIDOMInstallFolder* aFolder, const nsString& aTargetName, PRInt32* aReturn) { return _to##Patch(aRegName, aVersion, aJarSource, aFolder, aTargetName, aReturn); }  \
  NS_IMETHOD    ResetError() { return _to##ResetError(); }  \
  NS_IMETHOD    SetPackageFolder(nsIDOMInstallFolder* aFolder) { return _to##SetPackageFolder(aFolder); }  \
  NS_IMETHOD    StartInstall(const nsString& aUserPackageName, const nsString& aPackageName, const nsString& aVersion, PRInt32 aFlags, PRInt32* aReturn) { return _to##StartInstall(aUserPackageName, aPackageName, aVersion, aFlags, aReturn); }  \
  NS_IMETHOD    Uninstall(const nsString& aPackageName, PRInt32* aReturn) { return _to##Uninstall(aPackageName, aReturn); }  \
  NS_IMETHOD    ExtractFileFromJar(const nsString& aJarfile, const nsString& aFinalFile, nsString& aTempFile, nsString& aErrorMsg) { return _to##ExtractFileFromJar(aJarfile, aFinalFile, aTempFile, aErrorMsg); }  \


extern nsresult NS_InitInstallClass(nsIScriptContext *aContext, void **aPrototype);

extern "C" NS_DOM nsresult NS_NewScriptInstall(nsIScriptContext *aContext, nsISupports *aSupports, nsISupports *aParent, void **aReturn);

#endif // nsIDOMInstall_h__
+100 −0
Original line number Diff line number Diff line
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * 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.
 */
/* AUTO-GENERATED. DO NOT EDIT!!! */

#ifndef nsIDOMInstallFolder_h__
#define nsIDOMInstallFolder_h__

#include "nsISupports.h"
#include "nsString.h"
#include "nsIScriptContext.h"


#define NS_IDOMINSTALLFOLDER_IID \
 { 0x18c2f993, 0xb09f, 0x11d2, \
  {0xbc, 0xde, 0x00, 0x80, 0x5f, 0x0e, 0x13, 0x53}} 

class nsIDOMInstallFolder : public nsISupports {
public:
  static const nsIID& IID() { static nsIID iid = NS_IDOMINSTALLFOLDER_IID; return iid; }
  enum {
    BadFolder = 0,
    PluginFolder = 1,
    ProgramFolder = 2,
    PackageFolder = 3,
    TemporaryFolder = 4,
    CommunicatorFolder = 5,
    InstalledFolder = 6,
    CurrentUserFolder = 7,
    NetHelpFolder = 8,
    OSDriveFolder = 9,
    FileURLFolder = 10,
    JavaBinFolder = 11,
    JavaClassesFolder = 12,
    JavaDownloadFolder = 13,
    Win_WindowsFolder = 14,
    Win_SystemFolder = 15,
    Win_System16Folder = 16,
    Mac_SystemFolder = 17,
    Mac_DesktopFolder = 18,
    Mac_TrashFolder = 19,
    Mac_StartupFolder = 20,
    Mac_ShutdownFolder = 21,
    Mac_AppleMenuFolder = 22,
    Mac_ControlPanelFolder = 23,
    Mac_ExtensionFolder = 24,
    Mac_FontsFolder = 25,
    Mac_PreferencesFolder = 26,
    Unix_LocalFolder = 27,
    Unix_LibFolder = 28
  };

  NS_IMETHOD    Init(const nsString& aFolderID, const nsString& aVrPatch, const nsString& aPackageName)=0;

  NS_IMETHOD    GetDirectoryPath(nsString& aDirectoryPath)=0;

  NS_IMETHOD    MakeFullPath(const nsString& aRelativePath, nsString& aFullPath)=0;

  NS_IMETHOD    IsJavaCapable(PRBool* aReturn)=0;

  NS_IMETHOD    ToString(nsString& aFolderString)=0;
};


#define NS_DECL_IDOMINSTALLFOLDER   \
  NS_IMETHOD    Init(const nsString& aFolderID, const nsString& aVrPatch, const nsString& aPackageName);  \
  NS_IMETHOD    GetDirectoryPath(nsString& aDirectoryPath);  \
  NS_IMETHOD    MakeFullPath(const nsString& aRelativePath, nsString& aFullPath);  \
  NS_IMETHOD    IsJavaCapable(PRBool* aReturn);  \
  NS_IMETHOD    ToString(nsString& aFolderString);  \



#define NS_FORWARD_IDOMINSTALLFOLDER(_to)  \
  NS_IMETHOD    Init(const nsString& aFolderID, const nsString& aVrPatch, const nsString& aPackageName) { return _to##Init(aFolderID, aVrPatch, aPackageName); }  \
  NS_IMETHOD    GetDirectoryPath(nsString& aDirectoryPath) { return _to##GetDirectoryPath(aDirectoryPath); }  \
  NS_IMETHOD    MakeFullPath(const nsString& aRelativePath, nsString& aFullPath) { return _to##MakeFullPath(aRelativePath, aFullPath); }  \
  NS_IMETHOD    IsJavaCapable(PRBool* aReturn) { return _to##IsJavaCapable(aReturn); }  \
  NS_IMETHOD    ToString(nsString& aFolderString) { return _to##ToString(aFolderString); }  \


extern nsresult NS_InitInstallFolderClass(nsIScriptContext *aContext, void **aPrototype);

extern "C" NS_DOM nsresult NS_NewScriptInstallFolder(nsIScriptContext *aContext, nsISupports *aSupports, nsISupports *aParent, void **aReturn);

#endif // nsIDOMInstallFolder_h__
+72 −0
Original line number Diff line number Diff line
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * 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.
 */
/* AUTO-GENERATED. DO NOT EDIT!!! */

#ifndef nsIDOMInstallTriggerGlobal_h__
#define nsIDOMInstallTriggerGlobal_h__

#include "nsISupports.h"
#include "nsString.h"
#include "nsIScriptContext.h"


#define NS_IDOMINSTALLTRIGGERGLOBAL_IID \
 { 0x18c2f987, 0xb09f, 0x11d2, \
  {0xbc, 0xde, 0x00, 0x80, 0x5f, 0x0e, 0x13, 0x53}} 

class nsIDOMInstallTriggerGlobal : public nsISupports {
public:
  static const nsIID& IID() { static nsIID iid = NS_IDOMINSTALLTRIGGERGLOBAL_IID; return iid; }
  enum {
    MAJOR_DIFF = 4,
    MINOR_DIFF = 3,
    REL_DIFF = 2,
    BLD_DIFF = 1,
    EQUAL = 0
  };

  NS_IMETHOD    UpdateEnabled(PRBool* aReturn)=0;

  NS_IMETHOD    StartSoftwareUpdate(const nsString& aURL, PRInt32* aReturn)=0;

  NS_IMETHOD    ConditionalSoftwareUpdate(const nsString& aURL, const nsString& aRegName, PRInt32 aDiffLevel, const nsString& aVersion, PRInt32 aMode, PRInt32* aReturn)=0;

  NS_IMETHOD    CompareVersion(const nsString& aRegName, const nsString& aVersion, PRInt32* aReturn)=0;
};


#define NS_DECL_IDOMINSTALLTRIGGERGLOBAL   \
  NS_IMETHOD    UpdateEnabled(PRBool* aReturn);  \
  NS_IMETHOD    StartSoftwareUpdate(const nsString& aURL, PRInt32* aReturn);  \
  NS_IMETHOD    ConditionalSoftwareUpdate(const nsString& aURL, const nsString& aRegName, PRInt32 aDiffLevel, const nsString& aVersion, PRInt32 aMode, PRInt32* aReturn);  \
  NS_IMETHOD    CompareVersion(const nsString& aRegName, const nsString& aVersion, PRInt32* aReturn);  \



#define NS_FORWARD_IDOMINSTALLTRIGGERGLOBAL(_to)  \
  NS_IMETHOD    UpdateEnabled(PRBool* aReturn) { return _to##UpdateEnabled(aReturn); }  \
  NS_IMETHOD    StartSoftwareUpdate(const nsString& aURL, PRInt32* aReturn) { return _to##StartSoftwareUpdate(aURL, aReturn); }  \
  NS_IMETHOD    ConditionalSoftwareUpdate(const nsString& aURL, const nsString& aRegName, PRInt32 aDiffLevel, const nsString& aVersion, PRInt32 aMode, PRInt32* aReturn) { return _to##ConditionalSoftwareUpdate(aURL, aRegName, aDiffLevel, aVersion, aMode, aReturn); }  \
  NS_IMETHOD    CompareVersion(const nsString& aRegName, const nsString& aVersion, PRInt32* aReturn) { return _to##CompareVersion(aRegName, aVersion, aReturn); }  \


extern nsresult NS_InitInstallTriggerGlobalClass(nsIScriptContext *aContext, void **aPrototype);

extern "C" NS_DOM nsresult NS_NewScriptInstallTriggerGlobal(nsIScriptContext *aContext, nsISupports *aSupports, nsISupports *aParent, void **aReturn);

#endif // nsIDOMInstallTriggerGlobal_h__
+101 −0
Original line number Diff line number Diff line
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
 *
 * 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.
 */
/* AUTO-GENERATED. DO NOT EDIT!!! */

#ifndef nsIDOMInstallVersion_h__
#define nsIDOMInstallVersion_h__

#include "nsISupports.h"
#include "nsString.h"
#include "nsIScriptContext.h"

class nsIDOMInstallVersion;

#define NS_IDOMINSTALLVERSION_IID \
 { 0x18c2f986, 0xb09f, 0x11d2, \
  {0xbc, 0xde, 0x00, 0x80, 0x5f, 0x0e, 0x13, 0x53}} 

class nsIDOMInstallVersion : public nsISupports {
public:
  static const nsIID& IID() { static nsIID iid = NS_IDOMINSTALLVERSION_IID; return iid; }
  enum {
    SU_EQUAL = 0,
    SU_BLD_DIFF = 1,
    SU_BLD_DIFF_MINUS = -1,
    SU_REL_DIFF = 2,
    SU_REL_DIFF_MINUS = -2,
    SU_MINOR_DIFF = 3,
    SU_MINOR_DIFF_MINUS = -3,
    SU_MAJOR_DIFF = 4,
    SU_MAJOR_DIFF_MINUS = -4
  };

  NS_IMETHOD    GetMajor(PRInt32* aMajor)=0;
  NS_IMETHOD    SetMajor(PRInt32 aMajor)=0;

  NS_IMETHOD    GetMinor(PRInt32* aMinor)=0;
  NS_IMETHOD    SetMinor(PRInt32 aMinor)=0;

  NS_IMETHOD    GetRelease(PRInt32* aRelease)=0;
  NS_IMETHOD    SetRelease(PRInt32 aRelease)=0;

  NS_IMETHOD    GetBuild(PRInt32* aBuild)=0;
  NS_IMETHOD    SetBuild(PRInt32 aBuild)=0;

  NS_IMETHOD    Init(const nsString& aVersionString)=0;

  NS_IMETHOD    ToString(nsString& aReturn)=0;

  NS_IMETHOD    CompareTo(nsIDOMInstallVersion* aVersionObject, PRInt32* aReturn)=0;
};


#define NS_DECL_IDOMINSTALLVERSION   \
  NS_IMETHOD    GetMajor(PRInt32* aMajor);  \
  NS_IMETHOD    SetMajor(PRInt32 aMajor);  \
  NS_IMETHOD    GetMinor(PRInt32* aMinor);  \
  NS_IMETHOD    SetMinor(PRInt32 aMinor);  \
  NS_IMETHOD    GetRelease(PRInt32* aRelease);  \
  NS_IMETHOD    SetRelease(PRInt32 aRelease);  \
  NS_IMETHOD    GetBuild(PRInt32* aBuild);  \
  NS_IMETHOD    SetBuild(PRInt32 aBuild);  \
  NS_IMETHOD    Init(const nsString& aVersionString);  \
  NS_IMETHOD    ToString(nsString& aReturn);  \
  NS_IMETHOD    CompareTo(nsIDOMInstallVersion* aVersionObject, PRInt32* aReturn);  \



#define NS_FORWARD_IDOMINSTALLVERSION(_to)  \
  NS_IMETHOD    GetMajor(PRInt32* aMajor) { return _to##GetMajor(aMajor); } \
  NS_IMETHOD    SetMajor(PRInt32 aMajor) { return _to##SetMajor(aMajor); } \
  NS_IMETHOD    GetMinor(PRInt32* aMinor) { return _to##GetMinor(aMinor); } \
  NS_IMETHOD    SetMinor(PRInt32 aMinor) { return _to##SetMinor(aMinor); } \
  NS_IMETHOD    GetRelease(PRInt32* aRelease) { return _to##GetRelease(aRelease); } \
  NS_IMETHOD    SetRelease(PRInt32 aRelease) { return _to##SetRelease(aRelease); } \
  NS_IMETHOD    GetBuild(PRInt32* aBuild) { return _to##GetBuild(aBuild); } \
  NS_IMETHOD    SetBuild(PRInt32 aBuild) { return _to##SetBuild(aBuild); } \
  NS_IMETHOD    Init(const nsString& aVersionString) { return _to##Init(aVersionString); }  \
  NS_IMETHOD    ToString(nsString& aReturn) { return _to##ToString(aReturn); }  \
  NS_IMETHOD    CompareTo(nsIDOMInstallVersion* aVersionObject, PRInt32* aReturn) { return _to##CompareTo(aVersionObject, aReturn); }  \


extern nsresult NS_InitInstallVersionClass(nsIScriptContext *aContext, void **aPrototype);

extern "C" NS_DOM nsresult NS_NewScriptInstallVersion(nsIScriptContext *aContext, nsISupports *aSupports, nsISupports *aParent, void **aReturn);

#endif // nsIDOMInstallVersion_h__
Loading