/usr/share/doc/camlidl/html/main001.html is in camlidl-doc 1.04-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<HTML>
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<META name="GENERATOR" content="hevea 1.06-7 of 2001-11-14">
<TITLE>
Overview
</TITLE>
</HEAD>
<BODY >
<A HREF="index.html"><IMG SRC ="contents_motif.gif" ALT="Contents"></A>
<A HREF="main002.html"><IMG SRC ="next_motif.gif" ALT="Next"></A>
<HR>
<H2><A NAME="htoc1">1</A> Overview</H2>
Camlidl generates stub code for interfacing Caml with C
(as described in chapter ``Interfacing with C'' of the
<A HREF="http://caml.inria.fr/ocaml/htmlman/index.html">Objective Caml
reference manual</A>) from an IDL description of the C functions to be
made available in Caml.
Thus, Camlidl automates the most tedious task in interfacing C
libraries with Caml programs. It can also be used to interface Caml
programs with other languages, as long as those languages have a
well-defined C interface.<BR>
<BR>
In addition, Camlidl provides basic support for COM interfaces and
components. It supports both using COM components (usually written in
C++ or C) from Caml programs, and packaging Caml objects as
COM components that can then be used from C++ or C.<BR>
<BR>
<A NAME="toc1"></A>
<H3><A NAME="htoc2">1.1</A> What is IDL?</H3>
IDL stands for Interface Description Language. This is a generic term
for a family of small languages that have been developed to provide
type specifications for libraries written in C and C++. Those
languages resembles C declarations (as found in C header files), with
extra annotations to provide more precise types for the arguments and
results of the functions.<BR>
<BR>
The particular IDL used by Camlidl is inspired by Microsoft's IDL,
which itself is an extension of the IDL found in DCE (The Open Group's
Distributed Common Environment). The initial motivation for those IDLs
was to automate the generation of stub code for remote procedure calls
and network objects, where the arguments to the function are marshaled
at the calling site, then sent across the network or through
interprocess communications to a server process, which unmarshals the
arguments, compute the function application, marshal the results,
sends them back to the calling site, where they are unmarshaled and
returned to the caller. IDLs were also found to be very useful for
inter-language communications, since the same type information that
guides the generation of marshaling stubs can be used to generate
stubs to convert between the data representations of several
languages.<BR>
<BR>
<A NAME="toc2"></A>
<H3><A NAME="htoc3">1.2</A> What is COM?</H3>
COM is Microsoft's Common Object Model. It provides a set of
programming conventions as well as system support for packaging
C++ objects as executable components that can be used in other
programs, either by dynamic linking of the component inside the
program, or through interprocess or internetwork communications
between the program and a remote server. COM components implement one
or several interfaces, (similar to Caml object types or Java
interfaces) identified by unique 128-bit interface identifiers (IIDs).
COM specifies a standard protocol for reference counting of
components, and for asking a component which interfaces it
implements.<BR>
<BR>
While the full range of COM services and third-party components is
available only on Microsoft's Windows operating systems, the basic COM
conventions can also be used on Unix and other operating systems
to exchange objects between Caml and C or C++. Of particular
interest is the encapsulation of Caml objects as COM components, which
can then be used inside larger C or C++ applications; those
applications do not need to know anything about Caml: they just call
the component methods as if they were C++ methods or C
functions, without knowing that they are actually implemented in Caml.<BR>
<BR>
For more information about COM, see for instance <EM>Inside COM</EM>
by Dale Rogerson (Microsoft Press), or the
<A HREF="http://msdn.microsoft.com">Microsoft developer Web site</A>.<BR>
<BR>
<HR>
<A HREF="index.html"><IMG SRC ="contents_motif.gif" ALT="Contents"></A>
<A HREF="main002.html"><IMG SRC ="next_motif.gif" ALT="Next"></A>
</BODY>
</HTML>
|