Time.st
changeset 20614 0a5744a1f46c
parent 19922 e0d6d301a4dc
child 20727 fb8c5591428b
child 20818 efa2de8569f6
equal deleted inserted replaced
20613:b70eb66c0f7a 20614:0a5744a1f46c
     1 "{ Encoding: utf8 }"
       
     2 
       
     3 "
     1 "
     4  COPYRIGHT (c) 1989 by Claus Gittinger
     2  COPYRIGHT (c) 1989 by Claus Gittinger
     5 	      All Rights Reserved
     3 	      All Rights Reserved
     6 
     4 
     7  This software is furnished under a license and may be used
     5  This software is furnished under a license and may be used
   458 
   456 
   459 defaultFormatString
   457 defaultFormatString
   460     "a language specific format string to present times in user interfaces.
   458     "a language specific format string to present times in user interfaces.
   461      Do not use this to store/retrieve times (use ISO8601 for that)"
   459      Do not use this to store/retrieve times (use ISO8601 for that)"
   462 
   460 
   463     LanguageTerritory == #us ifTrue:[
   461     Smalltalk languageTerritory == #us ifTrue:[
   464 	^ self formatString12us
   462         ^ self formatString12us
   465     ] ifFalse:[
   463     ] ifFalse:[
   466 	^ self formatString24
   464         ^ self formatString24
   467     ]
   465     ]
   468 
   466 
   469     "Created: / 16-01-2011 / 11:23:36 / cg"
   467     "Created: / 16-01-2011 / 11:23:36 / cg"
   470 !
   468 !
   471 
   469 
   472 defaultFormatStringWithMilliseconds
   470 defaultFormatStringWithMilliseconds
   473     LanguageTerritory == #us ifTrue:[
   471     Smalltalk languageTerritory == #us ifTrue:[
   474 	^ self formatStringWithMilliseconds12us
   472         ^ self formatStringWithMilliseconds12us
   475     ] ifFalse:[
   473     ] ifFalse:[
   476 	^ self formatStringWithMilliseconds24
   474         ^ self formatStringWithMilliseconds24
   477     ]
   475     ]
   478 !
   476 !
   479 
   477 
   480 formatString12us
   478 formatString12us
   481     "return the format string used to format US times (and other areas)"
   479     "return the format string used to format US times (and other areas)"