dynlibs.xml 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. <?xml version="1.0" encoding="ISO8859-1"?>
  2. <!--
  3. $Id$
  4. This file is part of the FPC documentation.
  5. Copyright (C) 1997, by Michael Van Canneyt
  6. The FPC documentation is free text; you can redistribute it and/or
  7. modify it under the terms of the GNU Library General Public License as
  8. published by the Free Software Foundation; either version 2 of the
  9. License, or (at your option) any later version.
  10. The FPC Documentation is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  13. Library General Public License for more details.
  14. You should have received a copy of the GNU Library General Public
  15. License along with the FPC documentation; see the file COPYING.LIB. If not,
  16. write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  17. Boston, MA 02111-1307, USA.
  18. -->
  19. <fpdoc-descriptions>
  20. <package name="rtl">
  21. <module name="dynlibs">
  22. <short>Cross-platform support for dynamically loadable libraries</short>
  23. <descr>
  24. <p>
  25. The <file>Dynlibs</file> unit provides support for dynamically loading
  26. shared libraries. It is available only on those platforms that support
  27. shared libraries. The functionality available here may only be a part of
  28. the functionality available on each separate platform, in the interest of
  29. portability.
  30. </p>
  31. <p>
  32. On unix platforms, using this unit will cause the program to be linked to
  33. the C library, as most shared libraries are implemented in C and the
  34. dynamical linker too.
  35. </p>
  36. </descr>
  37. <!-- alias type Visibility: default -->
  38. <element name="TLibHandle">
  39. <short>Library handle type</short>
  40. <descr>
  41. <var>TLibHandle</var> should be considered an opaque type. It is defined
  42. differently on various platforms. The definition shown here depends on the
  43. platform for which the documentation was generated.
  44. </descr>
  45. <seealso>
  46. <link id="LoadLibrary"/>
  47. <link id="UnloadLibrary"/>
  48. </seealso>
  49. </element>
  50. <element name="HMODULE">
  51. <short>Alias for <link id="#rtl.dynlibs.TLibHandle">TLibHandle</link> type.</short>
  52. </element>
  53. <!-- constant Visibility: default -->
  54. <element name="NilHandle">
  55. <short>Correctly typed Nil handle - returned on error by <link id="LoadLibrary"/></short>
  56. </element>
  57. <!-- function Visibility: default -->
  58. <element name="LoadLibrary">
  59. <short>Load a dynamic library and return a handle to it.</short>
  60. <descr>
  61. <p>
  62. <var>LoadLibrary</var> loads a dynamic library in file <var>Name</var>
  63. and returns a handle to it. If the library cannot be loaded,
  64. <link id="NilHandle"/> is returned.
  65. </p>
  66. <p>
  67. No assumptions should be made about the location of the loaded library if a
  68. relative pathname is specified. The behaviour is dependent on the platform.
  69. Therefore it is best to specify an absolute pathname if possible.
  70. </p>
  71. </descr>
  72. <errors>
  73. On error, <link id="NilHandle"/> is returned.
  74. </errors>
  75. <seealso>
  76. <link id="UnloadLibrary"/>
  77. <link id="GetProcedureAddress"/>
  78. </seealso>
  79. </element>
  80. <!-- function Visibility: default -->
  81. <element name="GetProcedureAddress">
  82. <short>Get the address of a procedure or symbol in a dynamic library.</short>
  83. <descr>
  84. <p>
  85. <var>GetProcedureAddress</var> returns a pointer to the location in memory
  86. of the symbol <var>ProcName</var> in the dynamically loaded library
  87. specified by it's handle <var>lib</var>. If the symbol cannot be found or
  88. the handle is invalid, <var>Nil</var> is returned.
  89. </p>
  90. <p>
  91. On Windows, only an exported procedure or
  92. function can be searched this way. On Unix platforms the location of any
  93. exported symbol can be retrieved this way.
  94. </p>
  95. </descr>
  96. <errors>
  97. If the symbol cannot be found, <var>Nil</var> is returned.
  98. </errors>
  99. <seealso>
  100. <link id="LoadLibrary"/>
  101. <link id="UnLoadLibrary"/>
  102. </seealso>
  103. </element>
  104. <!-- function Visibility: default -->
  105. <element name="UnloadLibrary">
  106. <short>Unload a previously loaded library</short>
  107. <descr>
  108. <var>UnloadLibrary</var> unloads a previously loaded library (specified by
  109. the handle <var>lib</var>). The call returns <var>True</var> if succesful,
  110. <var>False</var> otherwisa.
  111. </descr>
  112. <errors>
  113. On error, <var>False</var> is returned.
  114. </errors>
  115. <seealso>
  116. <link id="LoadLibrary"/>
  117. <link id="GetProcedureAddress"/>
  118. </seealso>
  119. </element>
  120. <!-- function Visibility: default -->
  121. <element name="FreeLibrary">
  122. <short>For compatibility with Delphi/Windows: Unload a library</short>
  123. <descr>
  124. <var>FreeLibrary</var> provides the same functionality as <link
  125. id="UnloadLibrary"/>, and is provided for compatibility with Delphi.
  126. </descr>
  127. <seealso>
  128. <link id="UnloadLibrary"/>
  129. </seealso>
  130. </element>
  131. <!-- function Visibility: default -->
  132. <element name="GetProcAddress">
  133. <short>For compatibility with Delphi/Windows: Get the address of a procedure</short>
  134. <descr>
  135. <var>GetProcAddress</var> provides the same functionality as <link
  136. id="GetProcedureAddress"/>, and is provided for compatibility with Delphi.
  137. </descr>
  138. <seealso>
  139. <link id="GetProcedureAddress"/>
  140. </seealso>
  141. </element>
  142. </module> <!-- dynlibs -->
  143. </package>
  144. </fpdoc-descriptions>