IsValidTime.xml 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
  4. <sect1 id="IsValidTime">
  5. <title>IsValidTime</title>
  6. <para><emphasis role="bold">STD.Date.IsValidTime<indexterm>
  7. <primary>STD.Date.IsValidTime</primary>
  8. </indexterm><indexterm>
  9. <primary>Date.IsValidTime</primary>
  10. </indexterm>(</emphasis> <emphasis>time</emphasis> <emphasis
  11. role="bold">)</emphasis></para>
  12. <informaltable colsep="1" frame="all" rowsep="1">
  13. <tgroup cols="2">
  14. <colspec colwidth="80.50pt" />
  15. <colspec />
  16. <tbody>
  17. <row>
  18. <entry><emphasis>time</emphasis></entry>
  19. <entry>A time value in the Time_t format.</entry>
  20. </row>
  21. <row>
  22. <entry>Return:</entry>
  23. <entry>IsValidTime returns a BOOLEAN value.</entry>
  24. </row>
  25. </tbody>
  26. </tgroup>
  27. </informaltable>
  28. <para>The <emphasis role="bold">IsValidDate</emphasis> function returns TRUE
  29. if the time is valid, by validating each of the individual components
  30. (hours, minutes, and seconds)..</para>
  31. <para>Example:</para>
  32. <programlisting format="linespecific">IMPORT STD;
  33. d1 := 19631122;
  34. d2 := 19990230;
  35. firstTest := STD.Date.IsValidDate(d1); //d1 is valid
  36. secondTest := STD.Date.IsValidDate(d2); //d2 is not valid
  37. </programlisting>
  38. <para></para>
  39. </sect1>