📄 rmacomm.pas
字号:
unit RmaComm;
interface
uses
PnResult, PnTypes, RmaPckts;
(****************************************************************************
*
* $Id: rmacomm.h,v 1.27 2000/04/24 23:23:20 smpatel Exp $
*
* Copyright (C) 1995-1999 RealNetworks, Inc. All rights reserved.
*
* http://www.real.com/devzone
*
* This program contains proprietary
* information of Progressive Networks, Inc, and is licensed
* subject to restrictions on use and distribution.
*
*
* RealMedia Architecture Common Utility interfaces
*
*)
(****************************************************************************
*
* Interface:
*
* IRMACommonClassFactory
*
* Purpose:
*
* RMA interface that manages the creation of common RMA classes.
*
* IID_IRMACommonClassFactory:
*
* {00000000-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMACommonClassFactory: TGUID = '{00000000-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMACommonClassFactory}
type
IRMACommonClassFactory = interface (IUnknown)
['{00000000-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* Method:
* IRMACommonClassFactory::CreateInstance
* Purpose:
* Creates instances of common objects supported by the system,
* like IRMABuffer, IRMAPacket, IRMAValues, etc.
*
* This method is similar to Window's CoCreateInstance() in its
* purpose, except that it only creates objects of a well known
* types.
*
* NOTE: Aggregation is never used. Therefore and outer unknown is
* not passed to this function, and you do not need to code for this
* situation.
*)
function CreateInstance(const rclsid: TGUID; out ppUnknown: IUnknown): HRESULT; stdcall;
(************************************************************************
* Method:
* IRMAController::CreateInstanceAggregatable
* Purpose:
* Creates instances of common objects that can be aggregated
* supported by the system, like IRMASiteWindowed
*
* This method is similar to Window's CoCreateInstance() in its
* purpose, except that it only creates objects of a well known
* types.
*
* NOTE 1: Unlike CreateInstance, this method will create internal
* objects that support Aggregation.
*
* NOTE 2: The output interface is always the non-delegating
* IUnknown.
*)
function CreateInstanceAggregatable(const rclsid: TGUID; out ppUnknown: IUnknown;
pUnkOuter: IUnknown): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMACommonClassFactory}
(****************************************************************************
*
* Interface:
*
* IRMAStatistics
*
* Purpose:
*
* This interface allows update of the client statistics.
*
* IID_IRMAStatistics:
*
* {00000001-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAStatistics: TGUID = '{00000001-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAStatistics}
type
IRMAStatistics = interface (IUnknown)
['{00000001-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* Method:
* IRMAStatistics::Init
* Purpose:
* Pass registry ID to the caller
*
*)
function InitializeStatistics(ulRegistryID: UINT32): HRESULT; stdcall;
(************************************************************************
* Method:
* IRMAStatistics::Update
* Purpose:
* Notify the client to update its statistics stored in the registry
*
*)
function UpdateStatistics: HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAStatistics}
(****************************************************************************
*
* Interface:
*
* IRMARegistryID
*
* Purpose:
*
* This interface is implemented by IRMAPlayer, IRMAStreamSource,
* and IRMAStream. It allows the user to get the registry Base ID,
* for an object that you have a pointer to.
*
* IID_IRMARegistryID:
*
* {00000002-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMARegistryID: TGUID = '{00000002-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMARegistryID}
type
IRMARegistryID = interface (IUnknown)
['{00000002-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* Method:
* IRMARegistryID::GetID
* Purpose:
* Get the registry ID of the object.
*
*)
function GetID(var ulRegistryID: UINT32): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMARegistryID}
(****************************************************************************
*
* Interface:
*
* IRMAServerFork
*
* Purpose:
*
* This interface is implemented by the server context on Unix
* platforms. This interface allows your plugin to fork off a
* process. Note that the process that is forked off cannot use
* any RMA APIs. The fork() system call is prohibited from within
* a RMA plugin.
*
* IID_IRMAServerFork:
*
* {00000003-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAServerFork: TGUID = '{00000003-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAServerFork}
type
IRMAServerFork = interface (IUnknown)
['{00000003-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* Method:
* IRMAServerFork::Fork
* Purpose:
* Fork off a child process. The child process cannot use any RMA
* APIs. Upon successful completion, Fork returns 0 to the child
* process and the PID of the child to the parent. A return value
* of -1 indicates an error.
*
* Note: The child process should *NOT* Release any interfaces.
* The cleanup of the IRMAServerFork() interface and other
* RMA interfaces is done by the parent.
*
*)
function Fork: INT32; stdcall;
end;
{$EXTERNALSYM IRMAServerFork}
(*
*
* Interface:
*
* IRMAServerControl
*
* Purpose:
*
* This inteface provides access to the RealMedia server's controls
* for shutting down (for now).
*
* Note: This registry is not related to the Windows system registry.
*
* IID_IRMAServerControl:
*
* {00000004-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAServerControl: TGUID = '{00000004-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAServerControl}
CLSID_IRMAServerControl: TGUID = '{00000004-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM CLSID_IRMAServerControl}
type
IRMAServerControl = interface (IUnknown)
['{00000004-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* Method:
* IRMAServerControl::ShutdownServer
* Purpose:
* Shutdown the server.
*)
function ShutdownServer(status: UINT32): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAServerControl}
(*
*
* Interface:
*
* IRMAReconfigServerResponse
*
* Purpose:
*
* Response interface for IRMAServerControl2::ReconfigServer
*
*
* IID_IRMAReconfigServerResponse:
*
* {00000006-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAReconfigServerResponse: TGUID = '{00000006-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAReconfigServerResponse}
type
IRMAReconfigServerResponse = interface (IUnknown)
['{00000006-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* IRMAReconfigServerResponse::ReconfigServerDone
*
* Purpose:
*
* Notification that reconfiguring the server is done.
*)
function ReconfigServerDone(res: PN_RESULT; var pInfo: IRMABuffer; ulNumInfo: UINT32): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAReconfigServerResponse}
(*
*
* Interface:
*
* IRMAServerControl2
*
* Purpose:
*
* Interface for extended server control methods.
*
*
* IID_IRMAServerControl2:
*
* {00000005-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAServerControl2: TGUID = '{00000005-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAServerControl2}
type
IRMAServerControl2 = interface (IUnknown)
['{00000005-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* IRMAServerControl2::RestartServer
*
* Purpose:
*
* Completely shutdown the server, then restart. Mainly used to
* cause not hot setting config var changes to take effect.
*)
function RestartServer: HRESULT; stdcall;
(************************************************************************
* IRMAServerControl2::ReconfigServer
*
* Purpose:
*
* Used to cause the server to re-read in config from file or registry
* (however it was started) and attempt to use the values.
*)
function ReconfigServer(pResp: IRMAReconfigServerResponse): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAServerControl2}
(*
*
* Interface:
*
* IRMAWantServerReconfigNotification
*
* Purpose:
*
* Tell user that the server got a reconfig request and it is time to
* do your reconfiguration. NOTE: You should not need this if all of your
* configuration is stored in the config file; that is taken care of through
* IRMAActiveRegistry.
*
* IID_IRMAWantServerReconfigNotification:
*
* {00000008-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAWantServerReconfigNotification: TGUID = '{00000008-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAWantServerReconfigNotification}
type
IRMAWantServerReconfigNotification = interface (IUnknown)
['{00000008-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* IRMAWantServerReconfigNotification::ServerReconfig
*
* Purpose:
*
* Notify user that a server reconfig request had come in and it
* is now your turn to do external (not server config) reconfiguration.*
*)
function ServerReconfig(pResponse: IRMAReconfigServerResponse): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAWantServerReconfigNotification}
(*
*
* Interface:
*
* IRMAServerReconfigNotification
*
* Purpose:
*
* Register with the server that you want notification when a reconfig
* request comes in and want/need to take part in the reconfiguration. This
* is used when you have configuration info outside the server config file
* which needs to be re-initialized.
*
*
* IID_IRMAServerReconfigNotification:
*
* {00000007-0901-11d1-8B06-00A024406D59}
*
*)
const
IID_IRMAServerReconfigNotification: TGUID = '{00000007-0901-11d1-8B06-00A024406D59}';
{$EXTERNALSYM IID_IRMAServerReconfigNotification}
type
IRMAServerReconfigNotification = interface (IUnknown)
['{00000007-0901-11d1-8B06-00A024406D59}']
(************************************************************************
* IRMAServerReconfigNotification::WantReconfigNotification
*
* Purpose:
*
* Tell the server that you want reconfig notification.
*)
function WantReconfigNotification(pResponse: IRMAWantServerReconfigNotification): HRESULT; stdcall;
(************************************************************************
* IRMAServerReconfigNotification::CancelReconfigNotification
*
* Purpose:
*
* Tell the server that you no longer want reconfig notification.
*)
function CancelReconfigNotification(pResponse: IRMAWantServerReconfigNotification): HRESULT; stdcall;
end;
{$EXTERNALSYM IRMAServerReconfigNotification}
implementation
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -