#ifdef __PRIVATE__
//#
//#     File:           CMCtr.idl
//#
//#     Contains:       Class definition for Bento Container
//#
//#     Written by:     Vincent Lo
//#
//#     Copyright:      c 1994 by Apple Computer, Inc., all rights reserved.
//#
//#     Change History (most recent first):
//#
//#              <7>     9/23/94        VL              1184166: Added GetName and SetName to
//#                                                                     override.
//#              <6>      8/5/94        VL              1171603: Added GetCMSession.
//#              <5>     6/30/94        CC              GetCMContainer() is a subclass
//#                                                                     responsibility; added GetHandlers, also a
//#                                                                     subclass responsibility.
//#              <4>     6/29/94        CC              Added private methods to access
//#                                                                     fCMContainer and fHandlers.
//#              <3>     6/15/94        CC              Added functionprefix to eliminate Undefined
//#                                                                     entry, name: "_%CREATE".
//#              <2>     6/15/94        RR              ODHeap -> ODMemoryHeap
//#              <1>      6/8/94        VL              first checked in
//#
//#     To Do:
//#
#else
//#     Copyright:      c 1993-1994 by Apple Computer, Inc., all rights reserved.
#endif

#ifndef _CMCTR_
#define _CMCTR_

#ifndef _ODCTR_
#include "ODCtr.idl"
#endif

//==============================================================================
// Classes defined in this interface
//==============================================================================
interface ODBentoContainer;

//==============================================================================
// Classes used by this interface
//==============================================================================
#ifdef __PRIVATE__
typedef somToken CMContainer;
typedef somToken ODBentoHandlers;
typedef somToken ODMemoryHeapID;
typedef somToken CMSession;
#endif
interface ODStorageSystem; 
interface ODDocument;

//==============================================================================
// ODContainer
//==============================================================================

interface ODBentoContainer : ODContainer 
{
#ifdef __PRIVATE__

	// private within Bento Container Suite

	CMContainer                     GetCMContainer();
	ODBentoHandlers*        GetHandlers();
	ODBoolean                       GetDirtyFlag();
	void                            SetDirtyFlag();
	ODMemoryHeapID          GetHeap();
	CMSession                       GetCMSession();
	
#endif
  
#ifdef __SOMIDL__
  implementation
  {
	functionprefix = ODBentoContainer;
    override:
		somInit,
		somUninit,
		IncrementRefCount,
	Release,
	Purge,
	GetStorageSystem,
	GetID,
	GetName,
	SetName,
	GetDocument,
//#bln                #ifdef __PRIVATE__
			InitContainer,
//#bln                #else
//#bln                        reserved1,
//#bln                #endif
	Create,
	Open,
	Close,
	ReleaseDocument;
    releaseorder:
		#ifdef __PRIVATE__
			GetCMContainer,
			GetHandlers,
			GetDirtyFlag,
			SetDirtyFlag,
			GetHeap,
			GetCMSession;
		#else
			reserved1,
			reserved2,
			reserved3,
			reserved4,
			reserved5,
			reserved6;
		#endif

	#ifdef __PRIVATE__
		passthru C_xih = 
				"#include <BentoHdr.h>"
				"";
		passthru C_xh = ""
				"class ODBentoHandlers;"
				"#include <CMAPI.h>"
				"#include <ODMemory.h>"
				"";
		
		ODStorageSystem         fStorageSystem;
		ODContainerID*          fID;            
		ODDocument                      fDocument;              
		ODBoolean                       fDirty;         
		ODMemoryHeapID          fHeap;
		CMSession                       fCMSession;
	#endif
  };
#endif
};


#endif  // _CMCTR_

