
/*
 * This file was generated by the SOM Compiler.
 * FileName: wpdataf.xh.
 * Generated using:
 *     SOM Precompiler spc: 1.22
 *     SOM Emitter emitxh: 1.11
 */

/*
 * 
 *  Module Header
 * 
 *  Module Name: WPDATAF
 * 
 *  OS/2 Presentation Manager Workplace class definitions
 * 
 *  Copyright (c) International Business Machines Corporation 1991, 1992
 * 
 */

#ifndef wpdataf_xh
#define wpdataf_xh
class WPDataFile;

#define WPDataFile_MajorVersion 1
#define WPDataFile_MinorVersion 2


/*
 * Passthru lines: File: "C.xh", "before"
 */
#define MAX_ASSOC_ITEMS 12
/* C++ som defs */
#include <somcls.xh>

/* C++ parent def */
#ifndef wpfsys_xh
#include "wpfsys.xh"
#endif

#ifndef WPDataFile_API
#define WPDataFile_API
/*
 * The Class API
 */

/* A procedure to create the WPDataFile Class */
SOMEXTERN SOMClass * SOMLINK WPDataFileNewClass(
		integer4 majorVersion,
		integer4 minorVersion);

/* A macro to return the WPDataFile class object */
class M_WPDataFile;
#define _WPDataFile ((M_WPDataFile*)WPDataFileClassData.classObject)

/* The static interface to WPDataFile and its instances */
SOMEXTERN struct WPDataFileClassDataStructure {
	SOMClass *classObject;
	somMToken wpAddFileTypePage;
	somMToken wpPrintMetaFile;
	somMToken wpPrintPifFile;
	somMToken wpPrintPrinterSpecificFile;
	somMToken wpPrintUnknownFile;
	somMToken wpQueryAssociatedProgram;
	somMToken wpSetAssociatedFileIcon;
} WPDataFileClassData;

/*
 * -- Typedefs for Procedures that support WPDataFile Methods
 */
extern "C" {
typedef ULONG    (SOMLINK *somTD_WPDataFile_wpAddFileTypePage)(WPDataFile *somSelf,HWND hwndNotebook);
typedef BOOL    (SOMLINK *somTD_WPDataFile_wpPrintMetaFile)(WPDataFile *somSelf,PPRINTDEST pPrintDest);
typedef BOOL    (SOMLINK *somTD_WPDataFile_wpPrintPifFile)(WPDataFile *somSelf,PPRINTDEST pPrintDest);
typedef BOOL    (SOMLINK *somTD_WPDataFile_wpPrintPrinterSpecificFile)(WPDataFile *somSelf,PPRINTDEST pPrintDest);
typedef BOOL    (SOMLINK *somTD_WPDataFile_wpPrintUnknownFile)(WPDataFile *somSelf,PPRINTDEST pPrintDest);
typedef WPObject *   (SOMLINK *somTD_WPDataFile_wpQueryAssociatedProgram)(WPDataFile *somSelf,ULONG ulView,PULONG pulHowMatched,PSZ pszMatchString,ULONG cbMatchString,PSZ pszDefaultType);
typedef VOID    (SOMLINK *somTD_WPDataFile_wpSetAssociatedFileIcon)(WPDataFile *somSelf);
}


#endif /* WPDataFile_API */


/*
 * -- The C++ Wrapper Class for WPDataFile
 */
class WPDataFile : public WPFileSystem
{
public:

void *operator new(size_t size)
{
   (void) size;
   if (!WPDataFileClassData.classObject) 
      WPDataFileNewClass(WPDataFile_MajorVersion,WPDataFile_MinorVersion);
   return (void *)
      ((somTD_SOMClass_somNew)
      somResolve(SOM_TestCls((SOMAny *)(WPDataFileClassData.classObject),
                             SOMClassClassData.classObject),
                 SOMClassClassData.somNew))
         ((SOMClass*)(WPDataFileClassData.classObject));
}

void operator delete(void * obj)
{
   ((SOMObject *)obj)->somFree();
}

/* public method: wpAddFileTypePage */
ULONG    wpAddFileTypePage(HWND hwndNotebook)
{
   return (ULONG) SOM_Resolve((SOMAny *)this,WPDataFile,wpAddFileTypePage)
	(this,hwndNotebook);
}


/* public method: wpPrintMetaFile */
BOOL    wpPrintMetaFile(PPRINTDEST pPrintDest)
{
   return (BOOL) SOM_Resolve((SOMAny *)this,WPDataFile,wpPrintMetaFile)
	(this,pPrintDest);
}


/* public method: wpPrintPifFile */
BOOL    wpPrintPifFile(PPRINTDEST pPrintDest)
{
   return (BOOL) SOM_Resolve((SOMAny *)this,WPDataFile,wpPrintPifFile)
	(this,pPrintDest);
}


/* public method: wpPrintPrinterSpecificFile */
BOOL    wpPrintPrinterSpecificFile(PPRINTDEST pPrintDest)
{
   return (BOOL) SOM_Resolve((SOMAny *)this,WPDataFile,wpPrintPrinterSpecificFile)
	(this,pPrintDest);
}


/* public method: wpPrintUnknownFile */
BOOL    wpPrintUnknownFile(PPRINTDEST pPrintDest)
{
   return (BOOL) SOM_Resolve((SOMAny *)this,WPDataFile,wpPrintUnknownFile)
	(this,pPrintDest);
}


/* public method: wpQueryAssociatedProgram */
WPObject *   wpQueryAssociatedProgram(ULONG ulView,
		PULONG pulHowMatched,
		PSZ pszMatchString,
		ULONG cbMatchString,
		PSZ pszDefaultType)
{
   return (WPObject*) SOM_Resolve((SOMAny *)this,WPDataFile,wpQueryAssociatedProgram)
	(this,ulView,pulHowMatched,pszMatchString,cbMatchString,pszDefaultType);
}


/* public method: wpSetAssociatedFileIcon */
VOID    wpSetAssociatedFileIcon()
{
   SOM_Resolve((SOMAny *)this,WPDataFile,wpSetAssociatedFileIcon)
	(this);
}



};   /* WPDataFile */



#endif       /* wpdataf_xh */

/*
 * This file was generated by the SOM Compiler.
 * FileName: wpdataf.xh.
 * Generated using:
 *     SOM Precompiler spc: 1.22
 *     SOM Emitter emitxh: 1.11
 */
#ifndef wpdataf_mxh
#define wpdataf_mxh
class M_WPDataFile;

#define M_WPDataFile_MajorVersion 1
#define M_WPDataFile_MinorVersion 2

/* C++ som defs */
#include <somcls.xh>

/* C++ parent def */
#ifndef wpfsys_xh
#include "wpfsys.xh"
#endif

#ifndef M_WPDataFile_API
#define M_WPDataFile_API
/*
 * The Class API
 */

/* A procedure to create the M_WPDataFile Class */
SOMEXTERN SOMClass * SOMLINK M_WPDataFileNewClass(
		integer4 majorVersion,
		integer4 minorVersion);

/* A macro to return the M_WPDataFile class object */
#define _M_WPDataFile ((SOMClass*)M_WPDataFileClassData.classObject)

/* The static interface to M_WPDataFile and its instances */
SOMEXTERN struct M_WPDataFileClassDataStructure {
	SOMClass *classObject;
} M_WPDataFileClassData;

/*
 * -- Typedefs for Procedures that support M_WPDataFile Methods
 */
extern "C" {
}


#endif /* M_WPDataFile_API */


/*
 * -- The C++ Wrapper Class for M_WPDataFile
 */
class M_WPDataFile : public M_WPFileSystem
{
public:

void *operator new(size_t size)
{
   (void) size;
   if (!M_WPDataFileClassData.classObject) 
      M_WPDataFileNewClass(M_WPDataFile_MajorVersion,M_WPDataFile_MinorVersion);
   return (void *)
      ((somTD_SOMClass_somNew)
      somResolve(SOM_TestCls((SOMAny *)(M_WPDataFileClassData.classObject),
                             SOMClassClassData.classObject),
                 SOMClassClassData.somNew))
         ((SOMClass*)(M_WPDataFileClassData.classObject));
}

void operator delete(void * obj)
{
   ((SOMObject *)obj)->somFree();
}


};   /* M_WPDataFile */



#endif       /* wpdataf_mxh */
