home *** CD-ROM | disk | FTP | other *** search
- /*
- * ---------------------------------------------------------------------
- * CGenericAE.h :
- *
- * © Copyright 1992 by F. Menneteau. All rights reserved.
- * This code can be both distributed and used freely.
- *
- * ---------------------------------------------------------------------
- */
-
-
- #pragma once
-
-
- #include "AEUtilities.h"
-
- #if !defined NO_TCL
-
- #include <CObject.h>
-
-
- class CGenericAE : indirect CObject {
- #else
- class CGenericAE : indirect {
- #endif
- private:
- AEAddressDesc itsAEAddrDesc ;
- Boolean fDescIsValid ;
-
- DescType itsEventClass ;
- DescType itsEventID ;
-
- AppleEvent itsEvent ;
- AppleEvent itsReply ;
-
- Boolean fEventIsValid ;
- Boolean fReplyIsValid ;
-
- OSErr privBuidTargetDesc(TargetInfPtr);
-
- protected:
- OSErr itsError ;
-
- Size strcspn(const Ptr, const Ptr);
-
- OSErr protPutParam(AEKeyword, DescType, Ptr, Size);
- OSErr protFolderPathPutParam(Ptr);
- OSErr protFilesListPutParam(Ptr, Ptr);
-
- public:
- CGenericAE(void) ;
- ~CGenericAE(void) ;
-
- OSErr BuildTargetWithTargetID(TargetIDPtr);
- OSErr BuildTargetWithSignOnly(OSType);
- OSErr BuildTargetWithTypeAndSign(OSType, OSType);
- OSErr BuildTargetWithPSN(ProcessSerialNumberPtr);
- OSErr BuildTargetWithSessionID(PPCSessRefNumPtr);
- OSErr BuildTargetWithRemoteName(Ptr);
- OSErr AskAndBuildTarget(SelectorType); // calls PPCBrowser()
-
- OSErr CreateAE(DescType, DescType);
- OSErr SendAE(AESendMode);
- OSErr SendAEWithoutReply(void);
- OSErr SendAEWithReply(void);
-
- Boolean GetEvent(AppleEventPtr);
- Boolean GetReply(AppleEventPtr);
- } ;
-
-
-