Index Page
cspice_tpictr
A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X 

Abstract
I/O
Examples
Particulars
Required Reading
Version
Index_Entries

Abstract


   CSPICE_TPICTR takes a time format sample then creates a 
   time format picture suitable for use by cspice_timout.

   For important details concerning this module's function, please refer to
   the CSPICE routine tpictr_c.

I/O

   
   Given:
   
      sample   a representative scalar time string to use 
               as a model to format time strings (the string need 
               not describe an actual date - only format matters) 
               
      lenout   the length in characters of output 'pictur' (this
               argument should have a value of 1 plus the 
               assumed output string length to accommodate the C 
               null terminator)
   
   the call:
   
      cspice_tpictr, sample, lenout, pictur, ok, errmsg
   
   returns:
   
      pictur   a scalar format picture string suitable for 
               use with the SPICE routine cspice_timout
               
      ok       a scalar boolean indicating whether 'sample' parsed
               without error (TRUE) or some parse error occurred 
               (FALSE)
               
      errmsg   a scalar string containing the explanation of
               the parse error
   

Examples


   Any numerical results shown for this example may differ between
   platforms as the results depend on the SPICE kernels used as input
   and the machine specific arithmetic implementation.

   
      ;;
      ;; Given a sample with the format of the UNIX date string,
      ;; create a SPICE time picture for use in cspice_timout.
      ;;
      sample = 'Thu Oct 1 11:11:11 PDT 1111'
   
      ;;
      ;; Assign a length for 'pictur' long enough to hold
      ;; the picture based on 'sample' - the length should
      ;; always be at least the string length of the
      ;; time string described by 'sample' plus one. 
      ;;
      lenout = 64L
   
      ;; 
      ;; Make the call. 'ok' returns false is an error occurred.
      ;; The error description returns in the err variable.
      ;;
      cspice_tpictr, sample, lenout, pictur, ok, errmsg
   
      ;;
      ;; If a false error flag, print the picture; if
      ;; a true error flag, print the error message.
      ;;
      if( ok ) then begin
         print, pictur
      endif else begin
         print, errmsg
      endelse
   
   IDL outputs:  Wkd Mon DD HR:MN:SC PDT YYYY ::UTC-7

Particulars


   None.

Required Reading


   ICY.REQ
   TIME.REQ

Version


   -Icy Version 1.0.0, 16-JUN-2003, EDW (JPL)

Index_Entries


   Use a sample time string to produce a time format picture




Wed Apr  5 17:58:04 2017