home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / warphead.zip / H / WPFSYS.XH < prev    next >
Text File  |  1997-07-09  |  26KB  |  892 lines

  1.  
  2. /*
  3.  * This file was generated by the SOM Compiler.
  4.  * FileName: E:\cwpsh\rel\os2c\include\base\os2\wpfsys.xh.
  5.  * Generated using:
  6.  *     SOM Precompiler somipc: 2.29.1.14
  7.  *     SOM Emitter emitxh: 2.43
  8.  */
  9.  
  10. /*
  11.  *   Module Header
  12.  * 
  13.  *   Module Name: WPFSYS
  14.  * 
  15.  *   OS/2 Presentation Manager Workplace class definitions
  16.  * 
  17.  *   Copyright (c) International Business Machines Corporation 1991, 1994
  18.  * 
  19.  */
  20.  
  21.  
  22. #ifndef SOM_WPFileSystem_xh
  23. #define SOM_WPFileSystem_xh
  24.  
  25. class WPFileSystem;
  26.  
  27. #define WPFileSystem_MajorVersion 1
  28. #define WPFileSystem_MinorVersion 2
  29.  
  30. /* C++ SOM defs */
  31. #include <somcls.xh>
  32. #include <somcm.xh>
  33.  
  34. /* C++ parent defs */
  35. #ifndef SOM_WPObject_xh
  36. #include <wpobject.xh>
  37. #endif
  38.  
  39. #ifndef WPFileSystem_API
  40. #define WPFileSystem_API
  41. /*
  42.  * -- The Class API
  43.  */
  44.  
  45. /*
  46.  * Start of bindings for IDL types
  47.  */
  48.  
  49. class SOMClass;
  50. class SOMObject;
  51. class WPFolder;
  52. class M_WPObject;
  53. class WPObject;
  54. class WPImageFile;
  55. class M_WPFileSystem;
  56.  
  57. /*
  58.  * End of bindings for IDL types.
  59.  */
  60.  
  61. /*
  62.  * Passthru lines: File: "C.h", "after"
  63.  */
  64. /* Structure used to read + write the .CLASSINFO ea */
  65.  
  66.       typedef struct _INFOCLASS
  67.       {
  68.          ULONG    flags;
  69.          PSZ      pszClass;
  70.          ULONG    cbObjData;
  71.          POBJDATA pObjData;
  72.       } INFOCLASS;
  73.       typedef INFOCLASS * PINFOCLASS;
  74.  
  75.       /* FILEDETAILS structure used for details view */
  76.  
  77.     typedef struct _FILEDETAILS
  78.     {
  79.        PSZ      pszRealName;     /* Real name */
  80.        ULONG    ulSize;          /* Size of the file */
  81.        CDATE    cdateLastMod;    /* Last modification date */
  82.        CTIME    ctimeLastMod;    /* Last modification time */
  83.        CDATE    cdateLastAccess; /* Last access date */
  84.        CTIME    ctimeLastAccess; /* Last access time */
  85.        CDATE    cdateCreation;   /* Date of creation */
  86.        CTIME    ctimeCreation;   /* Time of creation */
  87.        ULONG    ulFlags;         /* File flags */
  88.        PSZ      ReadOnly;
  89.        PSZ      Hidden;
  90.        PSZ      System;
  91.        PSZ      Directory;
  92.        PSZ      Archived;
  93.        PSZ      Subject;
  94.        PSZ      Comments;
  95.        PSZ      KeyPhrases;
  96.        PSZ      History;
  97.        ULONG    ExtAttr;
  98.     }  FILEDETAILS;
  99.  
  100.     typedef FILEDETAILS * PFILEDETAILS;
  101.  
  102.     #define NUM_FILEDETAILS_FIELDS    19     /* Count of fields in FILEDETAILS */
  103.  
  104.       /* format of the extended search criteria for this class */
  105.       typedef struct _FILESYS_SEARCH_INFO {
  106.          USHORT Exclude;
  107.          USHORT MustHave;
  108.  
  109.          BOOL   fIncludeLMD;
  110.          USHORT LMDyear;
  111.          USHORT LMDmonth;
  112.          USHORT LMDday;
  113.           SHORT LMDcriteria;
  114.  
  115.          BOOL   fIncludeLMT;
  116.          USHORT LMThours;
  117.          USHORT LMTminutes;
  118.          USHORT LMTseconds;
  119.           SHORT LMTcriteria;
  120.  
  121.          BOOL   fIncludeFDS;
  122.          ULONG  FDSsize;
  123.          SHORT  FDScriteria;
  124.  
  125.          BOOL   fIncludeFEAS;
  126.          ULONG  FEASsize;
  127.          SHORT  FEAScriteria;
  128.  
  129.          BOOL   fMustHaveNeedEA;
  130.          BOOL   fMustNotHaveNeedEA;
  131.          } FILESYS_SEARCH_INFO;
  132.          typedef FILESYS_SEARCH_INFO *PFILESYS_SEARCH_INFO;
  133.  
  134.  
  135.       /* Alignment macro: ensure alignment on 4byte boundary */
  136.  
  137.       #define ALIGN4(p) (PVOID)( ( ((ULONG)p) + 3 ) & 0xFFFFFFFC )
  138.  
  139.       /* return values for wpConfirmRenameFileWithExt */
  140.       #define KEEP_RENAMEFILESWITHEXT     1
  141.       #define DISCARD_RENAMEFILESWITHEXT  2
  142.       #define CANCEL_RENAMEFILESWITHEXT   3
  143.  
  144.  
  145.  
  146.  
  147. /* A procedure to create the WPFileSystem Class */
  148. class M_WPFileSystem;
  149. SOMEXTERN M_WPFileSystem * SOMLINK WPFileSystemNewClass(
  150.         integer4 majorVersion,
  151.         integer4 minorVersion);
  152.  
  153. /* The API to the WPFileSystem class object, and the methods it introduces. */
  154. SOMEXTERN struct WPFileSystemClassDataStructure {
  155.     M_WPFileSystem *classObject;
  156.     somMToken wpSetRealName;
  157.     somMToken withdrawn_wpQueryRealName;
  158.     somMToken wpSetType;
  159.     somMToken wpQueryType;
  160.     somMToken wpSetAttr;
  161.     somMToken wpQueryAttr;
  162.     somMToken wpQueryFilename;
  163.     somMToken wpAddFile1Page;
  164.     somMToken wpAddFile2Page;
  165.     somMToken wpAddFile3Page;
  166.     somMToken wpAddFileMenuPage;
  167.     somMToken wpQueryCreation;
  168.     somMToken wpQueryLastAccess;
  169.     somMToken wpQueryLastWrite;
  170.     somMToken wpQueryFileSize;
  171.     somMToken wpQueryEASize;
  172.     somMToken wpSetDateInfo;
  173.     somMToken wpSetFileSizeInfo;
  174.     somMToken wpRefresh;
  175.     somMToken wpPrintPlainTextFile;
  176.     somMToken wpSetRefreshFlags;
  177.     somMToken wpQueryRefreshFlags;
  178.     somMToken wpFilesystemPrivate1;
  179.     somMToken wpSetTitleAndRenameFile;
  180.     somMToken wpConfirmRenameFileWithExt;
  181.     somMToken wpConfirmKeepAssoc;
  182.     somMToken wpFilesystemPrivate2;
  183.     somMToken wpQueryDisk;
  184.     somMToken wpQueryDateInfo;
  185.     somMToken wpFileSystemPrivate3;
  186.     somMToken wpFileSystemPrivate4;
  187.     somMToken wpQueryRealName;
  188.     somMToken wpVerifyUpdateAccess;
  189.     somMToken wpAddUserItemsToPopupMenu;
  190.     somMToken wpFilesystemPrivate5;
  191.     somMToken wpIsDiskSwapped;
  192.     somMToken wpFilesystemPrivate6;
  193.     somMToken wpQueryEASupport;
  194.     somMToken wpFilesystemPrivate7;
  195.     somMToken wpFilesystemPrivate8;
  196.     somMToken wpFilesystemPrivate9;
  197. } SOMDLINK WPFileSystemClassData;
  198. #define _WPFileSystem WPFileSystemClassData.classObject
  199.  
  200. /* The API to parentMtabs for WPFileSystem, and the instance data it introduces. */
  201. SOMEXTERN struct WPFileSystemCClassDataStructure {
  202.     somMethodTabs parentMtab;
  203.     somDToken              instanceDataToken;
  204. } SOMDLINK WPFileSystemCClassData;
  205.  
  206. /*
  207.  * -- Typedefs for WPFileSystem Method Procedures
  208.  */
  209. SOMEXTERN {
  210. typedef BOOL   SOMLINK somTP_WPFileSystem_wpSetRealName(WPFileSystem *somSelf, 
  211.         PSZ pszName);
  212. typedef somTP_WPFileSystem_wpSetRealName *somTD_WPFileSystem_wpSetRealName;
  213. typedef BOOL   SOMLINK somTP_WPFileSystem_wpSetType(WPFileSystem *somSelf, 
  214.         PSZ pszTypes, 
  215.         PFEA2LIST pfeal);
  216. typedef somTP_WPFileSystem_wpSetType *somTD_WPFileSystem_wpSetType;
  217. typedef PSZ   SOMLINK somTP_WPFileSystem_wpQueryType(WPFileSystem *somSelf);
  218. typedef somTP_WPFileSystem_wpQueryType *somTD_WPFileSystem_wpQueryType;
  219. typedef BOOL   SOMLINK somTP_WPFileSystem_wpSetAttr(WPFileSystem *somSelf, 
  220.         ULONG attrFile);
  221. typedef somTP_WPFileSystem_wpSetAttr *somTD_WPFileSystem_wpSetAttr;
  222. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryAttr(WPFileSystem *somSelf);
  223. typedef somTP_WPFileSystem_wpQueryAttr *somTD_WPFileSystem_wpQueryAttr;
  224. typedef ULONG   SOMLINK somTP_WPFileSystem_wpAddFile1Page(WPFileSystem *somSelf, 
  225.         HWND hwndNotebook);
  226. typedef somTP_WPFileSystem_wpAddFile1Page *somTD_WPFileSystem_wpAddFile1Page;
  227. typedef ULONG   SOMLINK somTP_WPFileSystem_wpAddFile2Page(WPFileSystem *somSelf, 
  228.         HWND hwndNotebook);
  229. typedef somTP_WPFileSystem_wpAddFile2Page *somTD_WPFileSystem_wpAddFile2Page;
  230. typedef ULONG   SOMLINK somTP_WPFileSystem_wpAddFile3Page(WPFileSystem *somSelf, 
  231.         HWND hwndNotebook);
  232. typedef somTP_WPFileSystem_wpAddFile3Page *somTD_WPFileSystem_wpAddFile3Page;
  233. typedef ULONG   SOMLINK somTP_WPFileSystem_wpAddFileMenuPage(WPFileSystem *somSelf, 
  234.         HWND hwndNotebook);
  235. typedef somTP_WPFileSystem_wpAddFileMenuPage *somTD_WPFileSystem_wpAddFileMenuPage;
  236. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryCreation(WPFileSystem *somSelf, 
  237.         FDATE* fdate, 
  238.         FTIME* ftime);
  239. typedef somTP_WPFileSystem_wpQueryCreation *somTD_WPFileSystem_wpQueryCreation;
  240. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryLastAccess(WPFileSystem *somSelf, 
  241.         FDATE* fdate, 
  242.         FTIME* ftime);
  243. typedef somTP_WPFileSystem_wpQueryLastAccess *somTD_WPFileSystem_wpQueryLastAccess;
  244. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryLastWrite(WPFileSystem *somSelf, 
  245.         FDATE* fdate, 
  246.         FTIME* ftime);
  247. typedef somTP_WPFileSystem_wpQueryLastWrite *somTD_WPFileSystem_wpQueryLastWrite;
  248. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryFileSize(WPFileSystem *somSelf);
  249. typedef somTP_WPFileSystem_wpQueryFileSize *somTD_WPFileSystem_wpQueryFileSize;
  250. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryEASize(WPFileSystem *somSelf);
  251. typedef somTP_WPFileSystem_wpQueryEASize *somTD_WPFileSystem_wpQueryEASize;
  252. typedef ULONG   SOMLINK somTP_WPFileSystem_wpSetDateInfo(WPFileSystem *somSelf, 
  253.         FILEFINDBUF4* pstFileFindBuf);
  254. typedef somTP_WPFileSystem_wpSetDateInfo *somTD_WPFileSystem_wpSetDateInfo;
  255. typedef ULONG   SOMLINK somTP_WPFileSystem_wpSetFileSizeInfo(WPFileSystem *somSelf, 
  256.         ULONG cbFileSize, 
  257.         ULONG cbEASize);
  258. typedef somTP_WPFileSystem_wpSetFileSizeInfo *somTD_WPFileSystem_wpSetFileSizeInfo;
  259. typedef BOOL   SOMLINK somTP_WPFileSystem_wpRefresh(WPFileSystem *somSelf, 
  260.         ULONG ulView, 
  261.         PVOID pReserved);
  262. typedef somTP_WPFileSystem_wpRefresh *somTD_WPFileSystem_wpRefresh;
  263. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryRefreshFlags(WPFileSystem *somSelf);
  264. typedef somTP_WPFileSystem_wpQueryRefreshFlags *somTD_WPFileSystem_wpQueryRefreshFlags;
  265. typedef BOOL   SOMLINK somTP_WPFileSystem_wpSetRefreshFlags(WPFileSystem *somSelf, 
  266.         ULONG ulRefreshFlags);
  267. typedef somTP_WPFileSystem_wpSetRefreshFlags *somTD_WPFileSystem_wpSetRefreshFlags;
  268. typedef BOOL   SOMLINK somTP_WPFileSystem_wpPrintPlainTextFile(WPFileSystem *somSelf, 
  269.         PPRINTDEST pPrintDest);
  270. typedef somTP_WPFileSystem_wpPrintPlainTextFile *somTD_WPFileSystem_wpPrintPlainTextFile;
  271. typedef BOOL   SOMLINK somTP_WPFileSystem_wpSetTitleAndRenameFile(WPFileSystem *somSelf, 
  272.         PSZ pszNewTitle, 
  273.         ULONG fConfirmations);
  274. typedef somTP_WPFileSystem_wpSetTitleAndRenameFile *somTD_WPFileSystem_wpSetTitleAndRenameFile;
  275. typedef ULONG   SOMLINK somTP_WPFileSystem_wpConfirmRenameFileWithExt(WPFileSystem *somSelf);
  276. typedef somTP_WPFileSystem_wpConfirmRenameFileWithExt *somTD_WPFileSystem_wpConfirmRenameFileWithExt;
  277. typedef ULONG   SOMLINK somTP_WPFileSystem_wpVerifyUpdateAccess(WPFileSystem *somSelf);
  278. typedef somTP_WPFileSystem_wpVerifyUpdateAccess *somTD_WPFileSystem_wpVerifyUpdateAccess;
  279. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryEASupport(WPFileSystem *somSelf);
  280. typedef somTP_WPFileSystem_wpQueryEASupport *somTD_WPFileSystem_wpQueryEASupport;
  281. typedef BOOL   SOMLINK somTP_WPFileSystem_wpAddUserItemsToPopupMenu(WPFileSystem *somSelf, 
  282.         HWND hwndMenu, 
  283.         HWND hwndCnr, 
  284.         ULONG iPosition);
  285. typedef somTP_WPFileSystem_wpAddUserItemsToPopupMenu *somTD_WPFileSystem_wpAddUserItemsToPopupMenu;
  286. typedef BOOL   SOMLINK somTP_WPFileSystem_wpIsDiskSwapped(WPFileSystem *somSelf);
  287. typedef somTP_WPFileSystem_wpIsDiskSwapped *somTD_WPFileSystem_wpIsDiskSwapped;
  288. typedef BOOL   SOMLINK somTP_WPFileSystem_wpQueryRealName(WPFileSystem *somSelf, 
  289.         PSZ pszFilename, 
  290.         PULONG pcb, 
  291.         BOOL fQualified);
  292. typedef somTP_WPFileSystem_wpQueryRealName *somTD_WPFileSystem_wpQueryRealName;
  293. typedef PSZ   SOMLINK somTP_WPFileSystem_wpQueryFilename(WPFileSystem *somSelf, 
  294.         PSZ pszFilename, 
  295.         BOOL fQualified);
  296. typedef somTP_WPFileSystem_wpQueryFilename *somTD_WPFileSystem_wpQueryFilename;
  297. typedef WPFileSystem*   SOMLINK somTP_WPFileSystem_wpQueryDisk(WPFileSystem *somSelf);
  298. typedef somTP_WPFileSystem_wpQueryDisk *somTD_WPFileSystem_wpQueryDisk;
  299. typedef ULONG   SOMLINK somTP_WPFileSystem_wpQueryDateInfo(WPFileSystem *somSelf, 
  300.         FILEFINDBUF4* pstFileFindBuf);
  301. typedef somTP_WPFileSystem_wpQueryDateInfo *somTD_WPFileSystem_wpQueryDateInfo;
  302. typedef ULONG   SOMLINK somTP_WPFileSystem_wpConfirmKeepAssoc(WPFileSystem *somSelf);
  303. typedef somTP_WPFileSystem_wpConfirmKeepAssoc *somTD_WPFileSystem_wpConfirmKeepAssoc;
  304.  
  305. /*
  306.  * -- Typedefs for Reintroduced Wrapper Methods
  307.  */
  308. typedef M_WPFileSystem*   SOMLINK somTP_WPFileSystem_somGetClass(WPFileSystem *somSelf);
  309. typedef somTP_WPFileSystem_somGetClass *somTD_WPFileSystem_somGetClass;
  310. }
  311.  
  312. #endif /* WPFileSystem_API */
  313.  
  314.  
  315. /*
  316.  * -- This emitter treats Method Tokens as Thunks by default.
  317.  * -- Use the sc modifier "nothunks" to change this default
  318.  */
  319. #undef somresolve_
  320. #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
  321.  
  322. /*
  323.  * -- The C++ Wrapper Class for WPFileSystem
  324.  */
  325. class WPFileSystem : public WPObject
  326. {
  327. public:
  328.  
  329. // WPFileSystem::new creates the class object if necessary, and then uses somNewNoInit
  330. // to allocate memory and create the object. Initialization is in ctors.
  331. void *operator new(size_t)
  332. {
  333.    if (!_WPFileSystem) WPFileSystemNewClass(WPFileSystem_MajorVersion,WPFileSystem_MinorVersion);
  334.    return (void*)
  335.       SOM_Resolve(_WPFileSystem,SOMClass,somNewNoInit)
  336.          ((SOMClass *)((void*)_WPFileSystem));
  337. }
  338.  
  339. // WPFileSystem::delete uses somDestruct.
  340. void operator delete(void * obj)
  341. {
  342.    if (obj && *(void**)obj) {
  343.       SOM_Resolve(obj,SOMObject,somDestruct)
  344.          ((SOMObject*)obj, 1, 0);
  345.    }
  346. }
  347.  
  348. WPFileSystem& operator=(WPFileSystem& fromObj)
  349. {
  350.    this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
  351.    return *this;
  352. }
  353.  
  354. WPFileSystem()
  355. {
  356.    if (*(void**)this != 
  357.        ((somParentMtabStructPtr)
  358.         (WPFileSystemCClassData.parentMtab))->mtab)
  359.       return;
  360.    ((SOMObject*)((void*)this))->somDefaultInit(0);
  361. }
  362.  
  363. WPFileSystem(WPFileSystem* fromObj)
  364. {
  365.    if (*(void**)this != 
  366.        ((somParentMtabStructPtr)
  367.         (WPFileSystemCClassData.parentMtab))->mtab)
  368.       return;
  369.    ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
  370. }
  371.  
  372. WPFileSystem(const WPFileSystem* fromObj)
  373. {
  374.    if (*(void**)this != 
  375.        ((somParentMtabStructPtr)
  376.         (WPFileSystemCClassData.parentMtab))->mtab)
  377.       return;
  378.    ((SOMObject*)((void*)this))->somDefaultConstCopyInit(0,((SOMObject*)((void*)fromObj)));
  379. }
  380.  
  381.  
  382. /* method: wpSetRealName */
  383. BOOL   wpSetRealName(PSZ pszName)
  384. {
  385.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetRealName)
  386.     (this,pszName);
  387. }
  388.  
  389.  
  390. /* method: wpSetType */
  391. BOOL   wpSetType(PSZ pszTypes, 
  392.         PFEA2LIST pfeal)
  393. {
  394.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetType)
  395.     (this,pszTypes,pfeal);
  396. }
  397.  
  398.  
  399. /* method: wpQueryType */
  400. PSZ   wpQueryType()
  401. {
  402.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryType)
  403.     (this);
  404. }
  405.  
  406.  
  407. /* method: wpSetAttr */
  408. BOOL   wpSetAttr(ULONG attrFile)
  409. {
  410.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetAttr)
  411.     (this,attrFile);
  412. }
  413.  
  414.  
  415. /* method: wpQueryAttr */
  416. ULONG   wpQueryAttr()
  417. {
  418.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryAttr)
  419.     (this);
  420. }
  421.  
  422.  
  423. /* method: wpAddFile1Page */
  424. ULONG   wpAddFile1Page(HWND hwndNotebook)
  425. {
  426.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpAddFile1Page)
  427.     (this,hwndNotebook);
  428. }
  429.  
  430.  
  431. /* method: wpAddFile2Page */
  432. ULONG   wpAddFile2Page(HWND hwndNotebook)
  433. {
  434.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpAddFile2Page)
  435.     (this,hwndNotebook);
  436. }
  437.  
  438.  
  439. /* method: wpAddFile3Page */
  440. ULONG   wpAddFile3Page(HWND hwndNotebook)
  441. {
  442.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpAddFile3Page)
  443.     (this,hwndNotebook);
  444. }
  445.  
  446.  
  447. /* method: wpAddFileMenuPage */
  448. ULONG   wpAddFileMenuPage(HWND hwndNotebook)
  449. {
  450.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpAddFileMenuPage)
  451.     (this,hwndNotebook);
  452. }
  453.  
  454.  
  455. /* method: wpQueryCreation */
  456. ULONG   wpQueryCreation(FDATE* fdate, 
  457.         FTIME* ftime)
  458. {
  459.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryCreation)
  460.     (this,fdate,ftime);
  461. }
  462.  
  463.  
  464. /* method: wpQueryLastAccess */
  465. ULONG   wpQueryLastAccess(FDATE* fdate, 
  466.         FTIME* ftime)
  467. {
  468.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryLastAccess)
  469.     (this,fdate,ftime);
  470. }
  471.  
  472.  
  473. /* method: wpQueryLastWrite */
  474. ULONG   wpQueryLastWrite(FDATE* fdate, 
  475.         FTIME* ftime)
  476. {
  477.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryLastWrite)
  478.     (this,fdate,ftime);
  479. }
  480.  
  481.  
  482. /* method: wpQueryFileSize */
  483. ULONG   wpQueryFileSize()
  484. {
  485.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryFileSize)
  486.     (this);
  487. }
  488.  
  489.  
  490. /* method: wpQueryEASize */
  491. ULONG   wpQueryEASize()
  492. {
  493.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryEASize)
  494.     (this);
  495. }
  496.  
  497.  
  498. /* method: wpSetDateInfo */
  499. ULONG   wpSetDateInfo(FILEFINDBUF4* pstFileFindBuf)
  500. {
  501.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetDateInfo)
  502.     (this,pstFileFindBuf);
  503. }
  504.  
  505.  
  506. /* method: wpSetFileSizeInfo */
  507. ULONG   wpSetFileSizeInfo(ULONG cbFileSize, 
  508.         ULONG cbEASize)
  509. {
  510.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetFileSizeInfo)
  511.     (this,cbFileSize,cbEASize);
  512. }
  513.  
  514.  
  515. /* method: wpRefresh */
  516. BOOL   wpRefresh(ULONG ulView, 
  517.         PVOID pReserved)
  518. {
  519.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpRefresh)
  520.     (this,ulView,pReserved);
  521. }
  522.  
  523.  
  524. /* method: wpQueryRefreshFlags */
  525. ULONG   wpQueryRefreshFlags()
  526. {
  527.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryRefreshFlags)
  528.     (this);
  529. }
  530.  
  531.  
  532. /* method: wpSetRefreshFlags */
  533. BOOL   wpSetRefreshFlags(ULONG ulRefreshFlags)
  534. {
  535.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetRefreshFlags)
  536.     (this,ulRefreshFlags);
  537. }
  538.  
  539.  
  540. /* method: wpPrintPlainTextFile */
  541. BOOL   wpPrintPlainTextFile(PPRINTDEST pPrintDest)
  542. {
  543.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpPrintPlainTextFile)
  544.     (this,pPrintDest);
  545. }
  546.  
  547.  
  548. /* method: wpSetTitleAndRenameFile */
  549. BOOL   wpSetTitleAndRenameFile(PSZ pszNewTitle, 
  550.         ULONG fConfirmations)
  551. {
  552.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpSetTitleAndRenameFile)
  553.     (this,pszNewTitle,fConfirmations);
  554. }
  555.  
  556.  
  557. /* method: wpConfirmRenameFileWithExt */
  558. ULONG   wpConfirmRenameFileWithExt()
  559. {
  560.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpConfirmRenameFileWithExt)
  561.     (this);
  562. }
  563.  
  564.  
  565. /* method: wpVerifyUpdateAccess */
  566. ULONG   wpVerifyUpdateAccess()
  567. {
  568.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpVerifyUpdateAccess)
  569.     (this);
  570. }
  571.  
  572.  
  573. /* method: wpQueryEASupport */
  574. ULONG   wpQueryEASupport()
  575. {
  576.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryEASupport)
  577.     (this);
  578. }
  579.  
  580.  
  581. /* method: wpAddUserItemsToPopupMenu */
  582. BOOL   wpAddUserItemsToPopupMenu(HWND hwndMenu, 
  583.         HWND hwndCnr, 
  584.         ULONG iPosition)
  585. {
  586.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpAddUserItemsToPopupMenu)
  587.     (this,hwndMenu,hwndCnr,iPosition);
  588. }
  589.  
  590.  
  591. /* method: wpIsDiskSwapped */
  592. BOOL   wpIsDiskSwapped()
  593. {
  594.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpIsDiskSwapped)
  595.     (this);
  596. }
  597.  
  598.  
  599. /* method: wpQueryRealName */
  600. BOOL   wpQueryRealName(PSZ pszFilename, 
  601.         PULONG pcb, 
  602.         BOOL fQualified)
  603. {
  604.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryRealName)
  605.     (this,pszFilename,pcb,fQualified);
  606. }
  607.  
  608.  
  609. /* method: wpQueryFilename */
  610. PSZ   wpQueryFilename(PSZ pszFilename, 
  611.         BOOL fQualified)
  612. {
  613.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryFilename)
  614.     (this,pszFilename,fQualified);
  615. }
  616.  
  617.  
  618. /* method: wpQueryDisk */
  619. WPFileSystem*   wpQueryDisk()
  620. {
  621.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryDisk)
  622.     (this);
  623. }
  624.  
  625.  
  626. /* method: wpQueryDateInfo */
  627. ULONG   wpQueryDateInfo(FILEFINDBUF4* pstFileFindBuf)
  628. {
  629.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpQueryDateInfo)
  630.     (this,pstFileFindBuf);
  631. }
  632.  
  633.  
  634. /* method: wpConfirmKeepAssoc */
  635. ULONG   wpConfirmKeepAssoc()
  636. {
  637.    return SOM_ResolveD(this,WPFileSystem,WPFileSystem,wpConfirmKeepAssoc)
  638.     (this);
  639. }
  640.  
  641.  
  642. /*
  643.  * Reintroduce inherited methods
  644.  */
  645.  
  646. /* method: somGetClass */
  647. M_WPFileSystem*  somGetClass()
  648. {
  649. /*
  650.  *  Return the receiver's class.
  651.  */
  652.    return SOM_ResolveD(this,WPFileSystem,SOMObject,somGetClass)
  653.     (this);
  654. }
  655.  
  656.  
  657.  
  658. };   /* WPFileSystem */
  659.  
  660.  
  661.  
  662. #endif       /* SOM_WPFileSystem_xh */
  663.  
  664. #ifndef SOM_M_WPFileSystem_xh
  665. #define SOM_M_WPFileSystem_xh
  666.  
  667. class M_WPFileSystem;
  668.  
  669. #define M_WPFileSystem_MajorVersion 1
  670. #define M_WPFileSystem_MinorVersion 2
  671.  
  672. /* C++ SOM defs */
  673. #include <somcls.xh>
  674. #include <somcm.xh>
  675.  
  676. /* C++ parent defs */
  677. #ifndef SOM_M_WPObject_xh
  678. #include <wpobject.xh>
  679. #endif
  680.  
  681. #ifndef M_WPFileSystem_API
  682. #define M_WPFileSystem_API
  683. /*
  684.  * -- The Class API
  685.  */
  686.  
  687. /*
  688.  * Start of bindings for IDL types
  689.  */
  690.  
  691.  
  692. /*
  693.  * End of bindings for IDL types.
  694.  */
  695.  
  696. /*
  697.  * -- M_WPFileSystem is a metaclass for WPFileSystem. Make sure WPFileSystem is known.
  698.  */
  699. class WPFileSystem;
  700.  
  701.  
  702. /* A procedure to create the M_WPFileSystem Class */
  703. SOMEXTERN SOMClass * SOMLINK M_WPFileSystemNewClass(
  704.         integer4 majorVersion,
  705.         integer4 minorVersion);
  706.  
  707. /* The API to the M_WPFileSystem class object, and the methods it introduces. */
  708. SOMEXTERN struct M_WPFileSystemClassDataStructure {
  709.     SOMClass *classObject;
  710.     somMToken wpclsQueryInstanceType;
  711.     somMToken wpclsQueryInstanceFilter;
  712.     somMToken wpclsQueryObjectFromPath;
  713.     somMToken wpclsQueryAwakeObject;
  714.     somMToken wpclsFileSysExists;
  715.     somMToken wpclsQueryInstanceClass;
  716. } SOMDLINK M_WPFileSystemClassData;
  717. #define _M_WPFileSystem M_WPFileSystemClassData.classObject
  718.  
  719. /* The API to parentMtabs for M_WPFileSystem, and the instance data it introduces. */
  720. SOMEXTERN struct M_WPFileSystemCClassDataStructure {
  721.     somMethodTabs parentMtab;
  722.     somDToken              instanceDataToken;
  723. } SOMDLINK M_WPFileSystemCClassData;
  724.  
  725. /*
  726.  * -- Typedefs for M_WPFileSystem Method Procedures
  727.  */
  728. SOMEXTERN {
  729. typedef WPObject*   SOMLINK somTP_M_WPFileSystem_wpclsQueryAwakeObject(M_WPFileSystem *somSelf, 
  730.         PSZ pszInputPath);
  731. typedef somTP_M_WPFileSystem_wpclsQueryAwakeObject *somTD_M_WPFileSystem_wpclsQueryAwakeObject;
  732. typedef WPObject*   SOMLINK somTP_M_WPFileSystem_wpclsFileSysExists(M_WPFileSystem *somSelf, 
  733.         WPFolder* Folder, 
  734.         PSZ pszFilename, 
  735.         ULONG attrFile);
  736. typedef somTP_M_WPFileSystem_wpclsFileSysExists *somTD_M_WPFileSystem_wpclsFileSysExists;
  737. typedef WPObject*   SOMLINK somTP_M_WPFileSystem_wpclsQueryObjectFromPath(M_WPFileSystem *somSelf, 
  738.         PSZ pszFQPath);
  739. typedef somTP_M_WPFileSystem_wpclsQueryObjectFromPath *somTD_M_WPFileSystem_wpclsQueryObjectFromPath;
  740. typedef PSZ   SOMLINK somTP_M_WPFileSystem_wpclsQueryInstanceType(M_WPFileSystem *somSelf);
  741. typedef somTP_M_WPFileSystem_wpclsQueryInstanceType *somTD_M_WPFileSystem_wpclsQueryInstanceType;
  742. typedef PSZ   SOMLINK somTP_M_WPFileSystem_wpclsQueryInstanceFilter(M_WPFileSystem *somSelf);
  743. typedef somTP_M_WPFileSystem_wpclsQueryInstanceFilter *somTD_M_WPFileSystem_wpclsQueryInstanceFilter;
  744. typedef PSZ   SOMLINK somTP_M_WPFileSystem_wpclsQueryInstanceClass(M_WPFileSystem *somSelf);
  745. typedef somTP_M_WPFileSystem_wpclsQueryInstanceClass *somTD_M_WPFileSystem_wpclsQueryInstanceClass;
  746.  
  747. /*
  748.  * -- Typedefs for Reintroduced Wrapper Methods
  749.  */
  750. typedef WPFileSystem*   SOMLINK somTP_M_WPFileSystem_somNew(M_WPFileSystem *somSelf);
  751. typedef somTP_M_WPFileSystem_somNew *somTD_M_WPFileSystem_somNew;
  752. }
  753.  
  754. #endif /* M_WPFileSystem_API */
  755.  
  756.  
  757. /*
  758.  * -- This emitter treats Method Tokens as Thunks by default.
  759.  * -- Use the sc modifier "nothunks" to change this default
  760.  */
  761. #undef somresolve_
  762. #define somresolve_(obj,mToken) ((somMethodProc*)((void)obj, mToken))
  763.  
  764. /*
  765.  * -- The C++ Wrapper Class for M_WPFileSystem
  766.  */
  767. class M_WPFileSystem : public M_WPObject
  768. {
  769. public:
  770.  
  771. // M_WPFileSystem::new creates the class object if necessary, and then uses somNewNoInit
  772. // to allocate memory and create the object. Initialization is in ctors.
  773. void *operator new(size_t)
  774. {
  775.    if (!_M_WPFileSystem) M_WPFileSystemNewClass(M_WPFileSystem_MajorVersion,M_WPFileSystem_MinorVersion);
  776.    return (void*)
  777.       SOM_Resolve(_M_WPFileSystem,SOMClass,somNewNoInit)
  778.          ((SOMClass *)((void*)_M_WPFileSystem));
  779. }
  780.  
  781. // M_WPFileSystem::delete uses somDestruct.
  782. void operator delete(void * obj)
  783. {
  784.    if (obj && *(void**)obj) {
  785.       SOM_Resolve(obj,SOMObject,somDestruct)
  786.          ((SOMObject*)obj, 1, 0);
  787.    }
  788. }
  789.  
  790. M_WPFileSystem& operator=(M_WPFileSystem& fromObj)
  791. {
  792.    this->somDefaultAssign(0,(SOMObject*)((void*)&fromObj));
  793.    return *this;
  794. }
  795.  
  796. M_WPFileSystem()
  797. {
  798.    if (*(void**)this != 
  799.        ((somParentMtabStructPtr)
  800.         (M_WPFileSystemCClassData.parentMtab))->mtab)
  801.       return;
  802.    ((SOMObject*)((void*)this))->somDefaultInit(0);
  803. }
  804.  
  805. M_WPFileSystem(M_WPFileSystem* fromObj)
  806. {
  807.    if (*(void**)this != 
  808.        ((somParentMtabStructPtr)
  809.         (M_WPFileSystemCClassData.parentMtab))->mtab)
  810.       return;
  811.    ((SOMObject*)((void*)this))->somDefaultCopyInit(0,((SOMObject*)((void*)fromObj)));
  812. }
  813.  
  814. M_WPFileSystem(const M_WPFileSystem* fromObj)
  815. {
  816.    if (*(void**)this != 
  817.        ((somParentMtabStructPtr)
  818.         (M_WPFileSystemCClassData.parentMtab))->mtab)
  819.       return;
  820.    ((SOMObject*)((void*)this))->somDefaultConstCopyInit(0,((SOMObject*)((void*)fromObj)));
  821. }
  822.  
  823.  
  824. /* method: wpclsQueryAwakeObject */
  825. WPObject*   wpclsQueryAwakeObject(PSZ pszInputPath)
  826. {
  827.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsQueryAwakeObject)
  828.     (this,pszInputPath);
  829. }
  830.  
  831.  
  832. /* method: wpclsFileSysExists */
  833. WPObject*   wpclsFileSysExists(WPFolder* Folder, 
  834.         PSZ pszFilename, 
  835.         ULONG attrFile)
  836. {
  837.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsFileSysExists)
  838.     (this,Folder,pszFilename,attrFile);
  839. }
  840.  
  841.  
  842. /* method: wpclsQueryObjectFromPath */
  843. WPObject*   wpclsQueryObjectFromPath(PSZ pszFQPath)
  844. {
  845.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsQueryObjectFromPath)
  846.     (this,pszFQPath);
  847. }
  848.  
  849.  
  850. /* method: wpclsQueryInstanceType */
  851. PSZ   wpclsQueryInstanceType()
  852. {
  853.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsQueryInstanceType)
  854.     (this);
  855. }
  856.  
  857.  
  858. /* method: wpclsQueryInstanceFilter */
  859. PSZ   wpclsQueryInstanceFilter()
  860. {
  861.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsQueryInstanceFilter)
  862.     (this);
  863. }
  864.  
  865.  
  866. /* method: wpclsQueryInstanceClass */
  867. PSZ   wpclsQueryInstanceClass()
  868. {
  869.    return SOM_ResolveD(this,M_WPFileSystem,M_WPFileSystem,wpclsQueryInstanceClass)
  870.     (this);
  871. }
  872.  
  873.  
  874. /*
  875.  * Reintroduce inherited methods
  876.  */
  877.  
  878. /* method: somNew */
  879. WPFileSystem*  somNew()
  880. {
  881.    return SOM_ResolveD(this,M_WPFileSystem,SOMClass,somNew)
  882.     (this);
  883. }
  884.  
  885.  
  886.  
  887. };   /* M_WPFileSystem */
  888.  
  889.  
  890.  
  891. #endif       /* SOM_M_WPFileSystem_xh */
  892.