/* @(#)Z 1.3 com/src/registry/localidl/ODPrtReg.idl, odconfig, od96nt, odnt9712d 97/03/21 17:15:52 (96/10/29 09:29:42) */
//#====START_GENERATED_PROLOG======================================
//#
//#
//#   COMPONENT_NAME: odconfig
//#
//#   CLASSES: none
//#
//#   ORIGINS: 27
//#
//#
//#   (C) COPYRIGHT International Business Machines Corp. 1995,1996
//#   All Rights Reserved
//#   Licensed Materials - Property of IBM
//#   US Government Users Restricted Rights - Use, duplication or
//#   disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
//#   	
//#   IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
//#   ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
//#   PURPOSE. IN NO EVENT SHALL IBM BE LIABLE FOR ANY SPECIAL, INDIRECT OR
//#   CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
//#   USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
//#   OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE
//#   OR PERFORMANCE OF THIS SOFTWARE.
//#
//#====END_GENERATED_PROLOG========================================
//#

/********************************************************************/
/*  Licensed Materials - Property of IBM                            */
/*                                                                  */
/*                                                                  */
/* Copyright (C) International Business Machines Corp., 1994.       */
/* Copyright (C) Apple Computer, Inc., 1994                         */
/*                                                                  */
/*  US Government Users Restricted Rights -                         */
/*  Use, duplication, or disclosure restricted                      */
/*  by GSA ADP Schedule Contract with IBM Corp.                     */
/*                                                                  */
/*                                                                  */
/********************************************************************/
#ifdef __PRIVATE__
//#
//#     File:           ODPrtReg.idl
//#     
//#     Contains:       Interface for ODPartHandlerInfo class
//#     
//#     Written by:     Kirk Searls           
//#     
//#     Copyright:      @1994 by International Business Machines, Inc., 
//#                              all rights reserved.
//#     
//#     IBM Change History (most recent first):
//#     
//#     <3>    6/23/95  jso  123479  Added UpdateODPartHandlerInfo
//#     <2>    8/27/94  MAP          Port A8C3
//#     <1>    6/8/94        KLS  first checked in
//#     
//#     To Do:
//#
#else
//#  Copyright:  1993-1994 by Apple Computer, Inc., all rights reserved.
#endif

#ifndef _ODPRTREG_
#define _ODPRTREG_

#include <somobj.idl>

#ifndef _ODTYPESM_
#include "ODTypesM.idl"
#endif


//==============================================================================
// Theory of Operation
//==============================================================================

//
//   changed comments  3/15:  VSM
//   This file defines class ODPartHandlerRegistry.  It uses ODPartHandlerInfo
//   which contains information about a part handler class.  This information
//   is kept by the Opendoc part registry and is used by the Opendoc shell.
/*
  This file defines class ODPartHandlerInfo.  This class contains information 
  about a part handler class.  This information is kept by the OpenDoc part 
  registry and is used by the OpenDoc shell and some OpenDoc utilities.
*/

//==============================================================================
// Implemenation types 
//==============================================================================
//typedef somToken ISOString;
//typedef somToken PartKindInfo;

//==============================================================================
// Classes defined in this interface
//==============================================================================

interface  ODPartHandlerRegistry;

//==============================================================================
// Classes used by this interface
//==============================================================================

interface ODPartHandlerInfo;

//==============================================================================
// ODPartHandlerRegistry
//==============================================================================

interface ODPartHandlerRegistry  : SOMObject
{
  long RegisterPartHandlerClass( in string className, in string DLLName, in long cTemplate, in long reserved);
  long DeregisterPartHandler( in ISOString partHandlerName);
  long DeregisterPartHandlerClass( in string partHandlerClassName);
  sequence<ISOString> GetPartHandlerList( in ISOString partKindName, in string category);
  sequence<ISOString> GetPartKindList( in ISOString partHandlerName, in string category);
  ODPartHandlerInfo GetPartHandlerInfo( in ISOString partHandlerName);
  ISOString GetPreferredPartHandler( in ISOString partKindName);
  long      SetPreferredPartHandler( in ISOString partKindName, in ISOString partHandlerName);
  void      UpdateODPartHandlerInfo( in ISOString partHandlerName, in sequence<PartKindInfo> newKindInfo);
  ISOString GetPreferredPartHandlerForFileType( in ISOString partFileTypeName);
  long      SetPreferredPartHandlerForFileType( in ISOString partFileTypeName, in ISOString partHandlerName);
  ISOString GetPreferredPartHandlerForFileExt( in ISOString partFileExtensionName);
  long      SetPreferredPartHandlerForFileExt( in ISOString partFileExtensionName, in ISOString partHandlerName);
  sequence<string> GetFileTypeList( in ISOString partHandlerName, in ISOString partKindName);  
  sequence<string> GetFileExtensionList( in ISOString partHandlerName, in ISOString partKindName); 
  sequence<ISOString> GetPartHandlerListForFileTypes(in string fileType);
  sequence<ISOString> GetPartHandlerListForFileExt(in string fileExtension);
  ISOString GetPreferredPartHandlerForCategory( in ISOString category);
  long      SetPreferredPartHandlerForCategory( in ISOString category, in ISOString partHandlerName);
  sequence<string> GetCategoryList( in ISOString partHandlerName, in ISOString partKindName); 
#ifdef __SOMIDL__

  implementation
  {

    passthru C_xh =
    ""
    "#include <ODTypes.h>"
    "";

    functionprefix = ODPartHandlerRegistry;

    releaseorder:
      RegisterPartHandlerClass,
      DeregisterPartHandler,
      DeregisterPartHandlerClass,
      GetPartHandlerList,
      GetPartKindList,
      GetPartHandlerInfo,
      GetPreferredPartHandler,
      SetPreferredPartHandler,
      UpdateODPartHandlerInfo,
      GetPreferredPartHandlerForFileType,
      SetPreferredPartHandlerForFileType,
      GetPreferredPartHandlerForFileExt,
      SetPreferredPartHandlerForFileExt,
      GetFileTypeList,
      GetFileExtensionList,
      GetPartHandlerListForFileTypes,
      GetPartHandlerListForFileExt,
      GetPreferredPartHandlerForCategory,
      SetPreferredPartHandlerForCategory,
      GetCategoryList;

  
  };
  
#endif

};

#endif 


