9ccf40b45a
Former-commit-id: 4832e31eb564c1c6a3a43dcaf79ba4b5f3e3116b
1347 lines
51 KiB
HTML
1347 lines
51 KiB
HTML
<?xml version="1.0" encoding="us-ascii"?>
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<title>mono-api-assembly.html</title>
|
|
<style type="text/css">
|
|
.mapi-docs {
|
|
line-height: 1.5;
|
|
padding-left: 2em;
|
|
padding-right: 2em;
|
|
}
|
|
.mapi-docs p {
|
|
max-width: 60em;
|
|
}
|
|
.mapi-docs .mapi-body {
|
|
max-width: 60em;
|
|
}
|
|
.mapi-docs code {
|
|
border: 1px solid rgba(214,214,214,1);
|
|
background-color: rgba(249,249,249,1);
|
|
padding: 0.1em 0.5em;
|
|
}
|
|
.mapi-description code {
|
|
font-family: "Consolas", "Courier", monospace;
|
|
border: 1px solid rgba(214,214,214,1);
|
|
background-color: rgba(249,249,249,1);
|
|
padding: 0.1em 0.2em;
|
|
}
|
|
|
|
.mapi-header {
|
|
padding: 0 0 5pt 5pt;
|
|
margin: 10pt;
|
|
white-space: pre;
|
|
font-family: monospace;
|
|
border: 1px solid rgba(233,233,233,1);
|
|
background-color: rgba(249,249,249,1);
|
|
}
|
|
|
|
.mapi-code {
|
|
padding: 5pt 5pt;
|
|
margin: 10pt;
|
|
white-space: pre;
|
|
font-family: monospace;
|
|
border: 1px solid rgba(233,233,233,1);
|
|
background-color: rgba(249,249,249,1);
|
|
}
|
|
|
|
.mapi-code:first-line {
|
|
line-height: 0px;
|
|
}
|
|
|
|
.mapi-codeblock {
|
|
display: block;
|
|
padding: 5pt 5pt;
|
|
margin: 10pt;
|
|
white-space: pre;
|
|
font-family: monospace;
|
|
border: 1px solid rgba(233,233,233,1);
|
|
background-color: rgba(249,249,249,1);
|
|
}
|
|
|
|
.mapi-entry code {
|
|
border: none;
|
|
background-color: transparent;
|
|
}
|
|
|
|
.mapi-parameters {
|
|
border-collapse: collapse;
|
|
border-spacing: 0;
|
|
empty-cells: hide;
|
|
border: 0;
|
|
margin: 5px 0 26px;
|
|
}
|
|
|
|
.mapi-parameters td {
|
|
border: 1px solid rgba(214,214,214,1);
|
|
border-left-style: none;
|
|
padding: 5px 25px 5px 10px;
|
|
}
|
|
|
|
.mapi-parameters tr>td:last-child {
|
|
border-right: 0;
|
|
}
|
|
|
|
.mapi-parameters td:first-of-type {
|
|
text-align: right;
|
|
padding: 7px;
|
|
vertical-align: top;
|
|
word-break: normal;
|
|
width: 40px;
|
|
}
|
|
|
|
.mapi-parameters tr:last-child>td {
|
|
border-bottom: 0;
|
|
}
|
|
|
|
.mapi-parameters tr:first-child>td {
|
|
border-top: 0;
|
|
}
|
|
|
|
.mapi-parameters tr td:first-of-type {
|
|
text-align: right;
|
|
padding: 7px;
|
|
vertical-align: top;
|
|
word-break: normal;
|
|
width: 40px;
|
|
}
|
|
|
|
.mapi {
|
|
left: -25px;
|
|
margin: 0;
|
|
padding: 13px 25px 0;
|
|
position: relative;
|
|
width: 100%;
|
|
}
|
|
|
|
.mapi-description {
|
|
background: rgba(249,249,249,1);
|
|
border-bottom: 1px solid rgba(233,233,233,1);
|
|
left: -25px;
|
|
margin: 0;
|
|
padding: 13px 25px 0;
|
|
position: relative;
|
|
width: 100%;
|
|
}
|
|
|
|
.mapi-entry {
|
|
background: transparent;
|
|
}
|
|
|
|
.mapi-docs {
|
|
}
|
|
|
|
.mapi-prototype {
|
|
border-left: 5px solid rgba(205,233,244,1);
|
|
padding: .5em;
|
|
margin-top: 5pt;
|
|
margin-bottom: 5pt;
|
|
font-family: "Consolas", "Courier", monospace;
|
|
display: block;
|
|
overflow: auto;
|
|
background-color: #f9f9f9;
|
|
}
|
|
|
|
.mapi-declaration {
|
|
margin-top: 21px;
|
|
}
|
|
|
|
.mapi-section {
|
|
font-size: smaller;
|
|
font-weight: bold;
|
|
margin-top: 21px;
|
|
line-height: 1.5;
|
|
}
|
|
|
|
.mapi-strike {
|
|
text-decoration: line-through;
|
|
}
|
|
|
|
.mapi-deprecated {
|
|
color: red;
|
|
}
|
|
|
|
.mapi-ptr-container {
|
|
background: white;
|
|
border-bottom: 1px solid rgba(233,233,233,1);
|
|
left: -25px;
|
|
padding-left: 25px;
|
|
padding-right: 25px;
|
|
padding-bottom: 13px;
|
|
position: relative;
|
|
width: 100%;
|
|
}
|
|
|
|
.mapi-ptr {
|
|
background: rgba(249,249,249,1);
|
|
border-left: 1px solid rgba(233,233,233,1);
|
|
border-top: 1px solid rgba(233,233,233,1);
|
|
height: 12px;
|
|
left: 37px;
|
|
top: -7px;
|
|
-webkit-transform: rotate(45deg);
|
|
-moz-transform: rotate(45deg);
|
|
-o-transform: rotate(45deg);
|
|
transform: rotate(45deg);
|
|
position: absolute;
|
|
width: 12px;
|
|
}
|
|
|
|
.mapi-height-container {
|
|
left: -25px;
|
|
padding: 0 25px;
|
|
position: relative;
|
|
width: 100%;
|
|
}
|
|
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<div class="mapi-docs">
|
|
<h2>Assemblies</h2>
|
|
|
|
<p />Code in .NET and Mono is distributed in assemblies, there
|
|
are shipped typically in files with the extension .exe or
|
|
.dll, and they are files that extend
|
|
the <a href="https://en.wikipedia.org/wiki/Portable_Executable">Portable
|
|
Executable</a> file format to include the Common Intermediate
|
|
Language metadata and portable code.
|
|
|
|
<p />Assemblies are typically loaded either from a given file
|
|
path, or using an <a href="#assembly-name">Assembly Name</a>
|
|
to load them from the Global Assembly Cache.
|
|
|
|
<p />The Mono Assembly API contains method for dealing with
|
|
<a href="#assembly-name">assembly
|
|
names</a>, <a href="cil_assembly_load">loading assemblies</a>,
|
|
<a href="#working">accessing assembly
|
|
components</a>, <a href="#modules">modules</a> and
|
|
some <a href="#advanced">advanced</a> features.
|
|
|
|
<p />Assemblies contain one or
|
|
more images, the actual vessels for your code.
|
|
The <a href="mono-api-image.html">Image API</a> documents the
|
|
functions that operate on <code>MonoImage *</code>.
|
|
|
|
<h3>Synopsis</h3>
|
|
|
|
<div class="mapi-header">
|
|
#include <metadata/assembly.h>
|
|
|
|
typedef struct _MonoImage MonoImage;
|
|
typedef struct _MonoAssembly MonoAssembly;
|
|
</div>
|
|
|
|
<a name="cil_assembly_load"></a>
|
|
<h3>Assembly Loading</h3>
|
|
|
|
<a name="api:mono_assembly_close"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_close</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_close (MonoAssembly *assembly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>assembly</i></td><td> the assembly to release.</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This method releases a reference to the <i>assembly</i>. The assembly is
|
|
only released when all the outstanding references to it are released.</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_get_object"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_get_object</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoReflectionAssembly*
|
|
mono_assembly_get_object (MonoDomain *domain, MonoAssembly *assembly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>domain</i></td><td> an app domain</td></tr><tr><td><i>assembly</i></td><td> an assembly</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> a <code>System.Reflection.Assembly</code> object representing the <code>MonoAssembly</code> <i>assembly</i>.
|
|
</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_load (MonoAssemblyName *aname, const char *basedir, MonoImageOpenStatus *status)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> A MonoAssemblyName with the assembly name to load.</td></tr><tr><td><i>basedir</i></td><td> A directory to look up the assembly at.</td></tr><tr><td><i>status</i></td><td> a pointer to a MonoImageOpenStatus to return the status of the load operation</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> the assembly referenced by <i>aname</i> loaded or <code>NULL</code> on error. On error the
|
|
|
|
value pointed by <i>status</i> is updated with an error code.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Loads the assembly referenced by <i>aname</i>, if the value of <i>basedir</i> is not <code>NULL</code>, it
|
|
attempts to load the assembly from that directory before probing the standard locations.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_full"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_full</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_load_full (MonoAssemblyName *aname, const char *basedir, MonoImageOpenStatus *status, gboolean refonly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> A MonoAssemblyName with the assembly name to load.</td></tr><tr><td><i>basedir</i></td><td> A directory to look up the assembly at.</td></tr><tr><td><i>status</i></td><td> a pointer to a MonoImageOpenStatus to return the status of the load operation</td></tr><tr><td><i>refonly</i></td><td> Whether this assembly is being opened in "reflection-only" mode.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> the assembly referenced by <i>aname</i> loaded or <code>NULL</code> on error. On error the
|
|
|
|
value pointed by <i>status</i> is updated with an error code.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Loads the assembly referenced by <i>aname</i>, if the value of <i>basedir</i> is not <code>NULL</code>, it
|
|
attempts to load the assembly from that directory before probing the standard locations.
|
|
<p />
|
|
If the assembly is being opened in reflection-only mode (<i>refonly</i> set to <code>TRUE</code>) then no
|
|
assembly binding takes place.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_loaded"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_loaded</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_loaded (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> an assembly to look for.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>NULL</code> If the given <i>aname</i> assembly has not been loaded, or a pointer to
|
|
|
|
a <code>MonoAssembly</code> that matches the <code>MonoAssemblyName</code> specified.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This is used to determine if the specified assembly has been loaded
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_from"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_from</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_load_from (MonoImage *image, const char *fname,
|
|
MonoImageOpenStatus *status)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>image</i></td><td> Image to load the assembly from</td></tr><tr><td><i>fname</i></td><td> assembly name to associate with the assembly</td></tr><tr><td><i>status</i></td><td> return status code</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> A valid pointer to a <code>MonoAssembly*</code> on success and then <i>status</i> will be
|
|
|
|
set to <code>MONO_IMAGE_OK</code>; or <code>NULL</code> on error.
|
|
<p />
|
|
If there is an error loading the assembly the <i>status</i> will indicate the
|
|
reason with <i>status</i> being set to <code>MONO_IMAGE_INVALID</code> if the
|
|
image did not contain an assembly reference table.
|
|
<p /></div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
If the provided <i>image</i> has an assembly reference, it will process the given
|
|
image as an assembly with the given name.
|
|
<p />
|
|
Most likely you want to use the `api:mono_assembly_load_full` method instead.
|
|
<p />
|
|
This is equivalent to calling `api:mono_assembly_load_from_full` with the
|
|
<i>refonly</i> parameter set to <code>FALSE</code>.</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_from_full"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_from_full</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_load_from_full (MonoImage *image, const char*fname,
|
|
MonoImageOpenStatus *status, gboolean refonly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>image</i></td><td> Image to load the assembly from</td></tr><tr><td><i>fname</i></td><td> assembly name to associate with the assembly</td></tr><tr><td><i>status</i></td><td> returns the status condition</td></tr><tr><td><i>refonly</i></td><td> Whether this assembly is being opened in "reflection-only" mode.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> A valid pointer to a <code>MonoAssembly*</code> on success and the <i>status</i> will be
|
|
|
|
set to <code>MONO_IMAGE_OK</code>; or <code>NULL</code> on error.
|
|
<p />
|
|
If there is an error loading the assembly the <i>status</i> will indicate the
|
|
reason with <i>status</i> being set to <code>MONO_IMAGE_INVALID</code> if the
|
|
image did not contain an assembly reference table.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
If the provided <i>image</i> has an assembly reference, it will process the given
|
|
image as an assembly with the given name.
|
|
<p />
|
|
Most likely you want to use the `api:mono_assembly_load_full` method instead.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_with_partial_name"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_with_partial_name</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_load_with_partial_name (const char *name, MonoImageOpenStatus *status)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>name</i></td><td> an assembly name that is then parsed by `api:mono_assembly_name_parse`.</td></tr><tr><td><i>status</i></td><td> return status code</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>NULL</code> on failure, or a pointer to a <code>MonoAssembly</code> on success.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Loads a <code>MonoAssembly</code> from a name. The name is parsed using `api:mono_assembly_name_parse`,
|
|
so it might contain a qualified type name, version, culture and token.
|
|
<p />
|
|
This will load the assembly from the file whose name is derived from the assembly name
|
|
by appending the <code>.dll</code> extension.
|
|
<p />
|
|
The assembly is loaded from either one of the extra Global Assembly Caches specified
|
|
by the extra GAC paths (specified by the <code>MONO_GAC_PREFIX</code> environment variable) or
|
|
if that fails from the GAC.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_open"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_open</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_open (const char *filename, MonoImageOpenStatus *status)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>filename</i></td><td> Opens the assembly pointed out by this name</td></tr><tr><td><i>status</i></td><td> return status code</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> a pointer to the <code>MonoAssembly</code> if <i>filename</i> contains a valid
|
|
|
|
assembly or <code>NULL</code> on error. Details about the error are stored in the
|
|
<i>status</i> variable.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This loads an assembly from the specified <i>filename</i>. The <i>filename</i> allows
|
|
a local URL (starting with a <code>file://</code> prefix). If a file prefix is used, the
|
|
filename is interpreted as a URL, and the filename is URL-decoded. Otherwise the file
|
|
is treated as a local path.
|
|
<p />
|
|
First, an attempt is made to load the assembly from the bundled executable (for those
|
|
deployments that have been done with the <code>mkbundle</code> tool or for scenarios where the
|
|
assembly has been registered as an embedded assembly). If this is not the case, then
|
|
the assembly is loaded from disk using `api:mono_image_open_full`.
|
|
<p />
|
|
If the pointed assembly does not live in the Global Assembly Cache, a shadow copy of
|
|
the assembly is made.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_open_full"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_open_full</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_open_full (const char *filename, MonoImageOpenStatus *status, gboolean refonly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>filename</i></td><td> the file to load</td></tr><tr><td><i>status</i></td><td> return status code </td></tr><tr><td><i>refonly</i></td><td> Whether this assembly is being opened in "reflection-only" mode.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>NULL</code> on error, with the <i>status</i> set to an error code, or a pointer
|
|
|
|
to the assembly.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This loads an assembly from the specified <i>filename</i>. The <i>filename</i> allows
|
|
a local URL (starting with a <code>file://</code> prefix). If a file prefix is used, the
|
|
filename is interpreted as a URL, and the filename is URL-decoded. Otherwise the file
|
|
is treated as a local path.
|
|
<p />
|
|
First, an attempt is made to load the assembly from the bundled executable (for those
|
|
deployments that have been done with the <code>mkbundle</code> tool or for scenarios where the
|
|
assembly has been registered as an embedded assembly). If this is not the case, then
|
|
the assembly is loaded from disk using `api:mono_image_open_full`.
|
|
<p />
|
|
If the pointed assembly does not live in the Global Assembly Cache, a shadow copy of
|
|
the assembly is made.
|
|
<p />
|
|
If <i>refonly</i> is set to true, then the assembly is loaded purely for inspection with
|
|
the <code>System.Reflection</code> API.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_set_assemblies_path"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_set_assemblies_path</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_set_assemblies_path (const char* path)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>path</i></td><td> list of paths that contain directories where Mono will look for assemblies</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Use this method to override the standard assembly lookup system and
|
|
override any assemblies coming from the GAC. This is the method
|
|
that supports the <code>MONO_PATH</code> variable.
|
|
<p />
|
|
Notice that <code>MONO_PATH</code> and this method are really a very bad idea as
|
|
it prevents the GAC from working and it prevents the standard
|
|
resolution mechanisms from working. Nonetheless, for some debugging
|
|
situations and bootstrapping setups, this is useful to have. </div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_set_rootdir"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_set_rootdir</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_set_rootdir (void)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Registers the root directory for the Mono runtime, for Linux and Solaris 10,
|
|
this auto-detects the prefix where Mono was installed. </div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
|
|
<a name="working"></a>
|
|
<h3>Working with Assemblies</h3>
|
|
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_fill_assembly_name"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_fill_assembly_name</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">gboolean
|
|
mono_assembly_fill_assembly_name (MonoImage *image, MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>image</i></td><td> Image</td></tr><tr><td><i>aname</i></td><td> Name</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>TRUE</code> if successful
|
|
</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_foreach"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_foreach</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_foreach (GFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>func</i></td><td> function to invoke for each assembly loaded</td></tr><tr><td><i>user_data</i></td><td> data passed to the callback</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Invokes the provided <i>func</i> callback for each assembly loaded into
|
|
the runtime. The first parameter passed to the callback is the
|
|
<code>MonoAssembly*</code>, and the second parameter is the <i>user_data</i>.
|
|
<p />
|
|
This is done for all assemblies loaded in the runtime, not just
|
|
those loaded in the current application domain.</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_get_image"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_get_image</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoImage*
|
|
mono_assembly_get_image (MonoAssembly *assembly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>assembly</i></td><td> The assembly to retrieve the image from</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> the <code>MonoImage</code> associated with this assembly.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_get_main"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_get_main</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_get_main (void)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Return value</div>
|
|
<div> the assembly for the application, the first assembly that is loaded by the VM
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_get_name"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_get_name</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssemblyName*
|
|
mono_assembly_get_name (MonoAssembly *assembly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>assembly</i></td><td> The assembly to retrieve the name from</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> the <code>MonoAssemblyName</code> associated with this assembly.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
The returned name's lifetime is the same as <i>assembly</i>'s.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_getrootdir"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_getrootdir</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">G_CONST_RETURN gchar *
|
|
mono_assembly_getrootdir (void)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Return value</div>
|
|
<div> a string with the directory, this string should not be freed.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Obtains the root directory used for looking up assemblies.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_get_assemblyref"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_get_assemblyref</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_get_assemblyref (MonoImage *image, int index, MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>image</i></td><td> pointer to the <code>MonoImage</code> to extract the information from.</td></tr><tr><td><i>index</i></td><td> index to the assembly reference in the image.</td></tr><tr><td><i>aname</i></td><td> pointer to a <code>MonoAssemblyName</code> that will hold the returned value.</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Fills out the <i>aname</i> with the assembly name of the <i>index</i> assembly reference in <i>image</i>.</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_loaded_full"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_loaded_full</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_loaded_full (MonoAssemblyName *aname, gboolean refonly)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> an assembly to look for.</td></tr><tr><td><i>refonly</i></td><td> Whether this assembly is being opened in "reflection-only" mode.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>NULL</code> If the given <i>aname</i> assembly has not been loaded, or a pointer to
|
|
|
|
a <code>MonoAssembly</code> that matches the <code>MonoAssemblyName</code> specified.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This is used to determine if the specified assembly has been loaded</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_reference"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_reference</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_load_reference (MonoImage *image, int index)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_references"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry mapi-strike"><code>mono_assembly_load_references</code></div><br /><div class='mapi-deprecated'><b>Deprecated:</b> There is no reason to use this method anymore, it does nothing</div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_load_references (MonoImage *image, MonoImageOpenStatus *status)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>image</i></td><td></td></tr><tr><td><i>status</i></td><td></td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This method is now a no-op, it does nothing other than setting the <i>status</i> to <code>MONO_IMAGE_OK</code></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_load_module"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_load_module</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoImage*
|
|
mono_assembly_load_module (MonoAssembly *assembly, guint32 idx)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_invoke_load_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_invoke_load_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_invoke_load_hook (MonoAssembly *ass)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_invoke_search_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_invoke_search_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssembly*
|
|
mono_assembly_invoke_search_hook (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_set_main"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_set_main</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_set_main (MonoAssembly *assembly)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_setrootdir"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_setrootdir</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_setrootdir (const char *root_dir)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>root_dir</i></td><td> The pathname of the root directory where we will locate assemblies</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
This routine sets the internal default root directory for looking up
|
|
assemblies.
|
|
<p />
|
|
This is used by Windows installations to compute dynamically the
|
|
place where the Mono assemblies are located.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_register_config_for_assembly"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_register_config_for_assembly</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_register_config_for_assembly (const char* assembly_name, const char* config_xml)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_register_symfile_for_assembly"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_register_symfile_for_assembly</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_register_symfile_for_assembly (const char *assembly_name, const mono_byte *raw_contents, int size)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
|
|
<a name="assembly-name"></a>
|
|
<h3>Assembly Names</h3>
|
|
|
|
<p />The MonoAssemblyName contains the full identity of an
|
|
assembly (name, culture, public key, public key token,
|
|
version and any other flags).
|
|
|
|
<p />These unmanaged objects represent the <a href="http://www.mono-project.com/monodoc/T:System.Reflection.AssemblyName">System.Reflection.AssemblyName</a>
|
|
managed type.
|
|
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_new"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_new</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoAssemblyName*
|
|
mono_assembly_name_new (const char *name)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>name</i></td><td> name to parse</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> a newly allocated structure or <code>NULL</code> if there was any failure.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Allocate a new <code>MonoAssemblyName</code> and fill its values from the
|
|
passed <i>name</i>.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_get_name"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_get_name</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">const char*
|
|
mono_assembly_name_get_name (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_get_culture"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_get_culture</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">const char*
|
|
mono_assembly_name_get_culture (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_get_version"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_get_version</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">uint16_t
|
|
mono_assembly_name_get_version (MonoAssemblyName *aname, uint16_t *minor, uint16_t *build, uint16_t *revision)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_get_pubkeytoken"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_get_pubkeytoken</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">mono_byte*
|
|
mono_assembly_name_get_pubkeytoken (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_name_free"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_name_free</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_assembly_name_free (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> assembly name to free</td></tr></tbody></table> <div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Frees the provided assembly name object.
|
|
(it does not frees the object itself, only the name members).</div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_stringify_assembly_name"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_stringify_assembly_name</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">char*
|
|
mono_stringify_assembly_name (MonoAssemblyName *aname)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>aname</i></td><td> the assembly name.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> a newly allocated string with a string representation of
|
|
|
|
the assembly name.</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Convert <i>aname</i> into its string format. The returned string is dynamically
|
|
allocated and should be freed by the caller.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_assembly_names_equal"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_assembly_names_equal</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">gboolean
|
|
mono_assembly_names_equal (MonoAssemblyName *l, MonoAssemblyName *r)
|
|
|
|
</div>
|
|
<p />
|
|
<div class="mapi-section">Parameters</div>
|
|
<table class="mapi-parameters"><tbody><tr><td><i>l</i></td><td> first assembly</td></tr><tr><td><i>r</i></td><td> second assembly.</td></tr></tbody></table> <div class="mapi-section">Return value</div>
|
|
<div> <code>TRUE</code> if both assembly names are equal.
|
|
</div>
|
|
<div class="mapi-section">Description</div>
|
|
<div>
|
|
<p />
|
|
Compares two <code>MonoAssemblyName</code> instances and returns whether they are equal.
|
|
<p />
|
|
This compares the names, the cultures, the release version and their
|
|
public tokens.
|
|
<p /></div>
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
|
|
<a href="modules"></a>
|
|
<h3>Modules</h3>
|
|
|
|
<p />An assembly is made up of one or more modules.
|
|
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_module_file_get_object"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_module_file_get_object</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoReflectionModule*
|
|
mono_module_file_get_object (MonoDomain *domain, MonoImage *image, int table_index)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_module_get_object"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_module_get_object</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">MonoReflectionModule*
|
|
mono_module_get_object (MonoDomain *domain, MonoImage *image)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
|
|
|
|
<a href="advanced"></a>
|
|
<h3>Advanced</h3>
|
|
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_load_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_load_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_load_hook (MonoAssemblyLoadFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_search_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_search_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_search_hook (MonoAssemblySearchFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_refonly_search_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_refonly_search_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_refonly_search_hook (MonoAssemblySearchFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_preload_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_preload_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_preload_hook (MonoAssemblyPreLoadFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_refonly_preload_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_refonly_preload_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_refonly_preload_hook (MonoAssemblyPreLoadFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|
|
</div> <!-- class=mapi -->
|
|
|
|
<a name="api:mono_install_assembly_postload_search_hook"></a>
|
|
<div class="mapi">
|
|
<div class="mapi-entry "><code>mono_install_assembly_postload_search_hook</code></div>
|
|
<div class="mapi-height-container">
|
|
<div class="mapi-ptr-container"></div>
|
|
<div class="mapi-description">
|
|
<div class="mapi-ptr"></div>
|
|
|
|
<div class="mapi-declaration mapi-section">Syntax</div>
|
|
<div class="mapi-prototype">void
|
|
mono_install_assembly_postload_search_hook (MonoAssemblySearchFunc func, gpointer user_data)
|
|
|
|
</div>
|
|
<p />
|
|
</div><!--mapi-description -->
|
|
</div><!--height container -->
|