MmdbDGPS.sgm 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. <!-- $XConsortium: MmdbDGPS.sgm /main/6 1996/09/08 20:05:50 rws $ -->
  2. <!-- (c) Copyright 1996 Digital Equipment Corporation. -->
  3. <!-- (c) Copyright 1996 Hewlett-Packard Company. -->
  4. <!-- (c) Copyright 1996 International Business Machines Corp. -->
  5. <!-- (c) Copyright 1996 Sun Microsystems, Inc. -->
  6. <!-- (c) Copyright 1996 Novell, Inc. -->
  7. <!-- (c) Copyright 1996 FUJITSU LIMITED. -->
  8. <!-- (c) Copyright 1996 Hitachi. -->
  9. <![ %CDE.C.CDE; [<refentry id="CDE.INFO.DtMmdbDlpGetPrevSection">]]><refmeta><refentrytitle>
  10. DtMmdbDlpGetPrevSectionId</refentrytitle><manvolnum>library call</manvolnum></refmeta><refnamediv>
  11. <refname><function>DtMmdbDlpGetPrevSectionId</function></refname><refpurpose>obtains
  12. the object identifier of the previous section</refpurpose></refnamediv><refsynopsisdiv>
  13. <funcsynopsis>
  14. <funcsynopsisinfo>#include &lt;DtMmdb.h></funcsynopsisinfo>
  15. <funcdef>DtMmdbHandle* <function>DtMmdbDlpGetPrevSectionId</function></funcdef>
  16. <paramdef>DtMmdbInfoRequest* <parameter>request</parameter></paramdef>
  17. </funcsynopsis>
  18. </refsynopsisdiv><refsect1>
  19. <title>DESCRIPTION</title>
  20. <para>The <function>DtMmdbDlpGetPrevSectionId</function> function
  21. returns the object identifier of the previous section. You can use
  22. this function to traverse the TOC hierarchy in a depth-first fashion.
  23. </para>
  24. <para>Use the <function>DtMmdbFreeHandleList</function>
  25. function to release the memory when the object identifier is no
  26. longer needed. Table lookup is involved.
  27. </para>
  28. </refsect1><refsect1>
  29. <title>ARGUMENTS</title>
  30. <variablelist>
  31. <varlistentry><term><symbol role="Variable">request</symbol></term>
  32. <listitem>
  33. <para>Specifies the bookcase in the bookcase descriptor field, as well
  34. as the id of the current section in the
  35. <symbol role="Variable">primary_oid</symbol> field.
  36. </para>
  37. </listitem>
  38. </varlistentry>
  39. </variablelist>
  40. </refsect1><refsect1>
  41. <title>RETURN VALUE</title>
  42. <para>If <function>DtMmdbDlpGetPrevSectionId</function> completes
  43. successfully, it returns a pointer to the object identifier
  44. for the previous section or
  45. <SystemItem Class="Constant">DtMmdbGroundId</SystemItem>,
  46. if there is no previous section.
  47. If it fails, it returns a NULL pointer.
  48. </para>
  49. </refsect1><refsect1>
  50. <title>EXAMPLE</title>
  51. <para>The following shows how a <function>DtMmdbDlpGetPrevSectionId</function> call
  52. might be coded.</para>
  53. <informalexample>
  54. <programlisting>DtMmdbInfoRequest request;
  55. /* fill the request here */
  56. DtMmdbHandle* x = DtMmdbDlpGetPrevSectionId(&amp;request);
  57. if ( x == DtMMdbGroundId) {
  58. /* no previous section */
  59. } else
  60. {
  61. if (x == 0) {
  62. /* bad request */
  63. }
  64. else
  65. { /* make use of x */
  66. }
  67. </programlisting>
  68. </informalexample>
  69. </refsect1><refsect1>
  70. <title>SEE ALSO</title>
  71. <para>&cdeman.DtMmdbDlpGetNextSectionId;
  72. </para>
  73. </refsect1></refentry>