Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
d4093c24
Commit
d4093c24
authored
Mar 13, 1997
by
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
parent
32797bc3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
39 deletions
+25
-39
lib/python/DateTime/DateTime.py
lib/python/DateTime/DateTime.py
+25
-39
No files found.
lib/python/DateTime/DateTime.py
View file @
d4093c24
...
...
@@ -44,7 +44,7 @@
"""Encapsulation of date/time values"""
__version__
=
'$Revision: 1.
6
$'
[
11
:
-
2
]
__version__
=
'$Revision: 1.
7
$'
[
11
:
-
2
]
import
sys
,
os
,
regex
,
DateTimeZone
...
...
@@ -1069,62 +1069,48 @@ class DateTime:
self._hour,self._minute,self._nearsec,self._tz)
# New formats
useful with DocumentTemplates
def
mo_d_y4_hm_pm_z
(self):
# New formats
def
fCommon
(self):
"""Return a string representing the object
\
'
s value
in the format: Mar
1, 1997 1:45 pm US/Eastern
"""
return '
%
s
%
s
,
%
4.4
d
%
d
:
%
2.2
d
%
s
%
s
' % (
self._
a
mon,self._day,self._year,self._pmhour,
self._minute,self._pm
,self._tz
)
in the format: Mar
ch 1, 1997 1:45 pm
"""
return '
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._
f
mon,self._day,self._year,self._pmhour,
self._minute,self._pm)
def
Mo_d_y4_hm_pm_z
(self):
def
fCommonZ
(self):
"""Return a string representing the object
\
'
s value
in the format: March 1, 1997 1:45 pm US/Eastern"""
return '
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
%
s
' % (
return '
%
s
%
s
,
%
4.4
d
%
d
:
%
2.2
d
%
s
%
s
' % (
self._fmon,self._day,self._year,self._pmhour,
self._minute,self._pm,self._tz)
def
mo_d_y4_hm_pm
(self):
def
aCommon
(self):
"""Return a string representing the object
\
'
s value
in the format: Mar 1, 1997 1:45 pm"""
return '
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._amon,self._day,self._year,self._pmhour,
self._minute,self._pm)
def
Mo_d_y4_hm_pm
(self):
def
aCommonZ
(self):
"""Return a string representing the object
\
'
s value
in the format: March 1, 1997 1:45 pm"""
return '
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._fmon,self._day,self._year,self._pmhour,
self._minute,self._pm)
def D_mo_d_y4_hm_pm(self):
"""Return a string representing the object
\
'
s value
in the format: Saturday Mar 1, 1997 1:45 pm"""
return '
%
s
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._fday,self._amon,self._day,self._year,
self._pmhour,self._minute,self._pm)
def D_Mo_d_y4_hm_pm(self):
"""Return a string representing the object
\
'
s value
in the format: Saturday March 1, 1997 1:45 pm"""
return '
%
s
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._fday,self._amon,self._day,self._year,
self._pmhour,self._minute,self._pm)
in the format: Mar 1, 1997 1:45 pm US/Eastern"""
return '
%
s
%
s
,
%
4.4
d
%
d
:
%
2.2
d
%
s
%
s
' % (
self._amon,self._day,self._year,self._pmhour,
self._minute,self._pm,self._tz)
def
d_Mo_d_y4_hm_pm
(self):
def
pCommon
(self):
"""Return a string representing the object
\
'
s value
in the format:
Sat March
1, 1997 1:45 pm"""
return '
%
s
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._
aday,self._fmon,self._day,self._yea
r,
self._
pmhour,self._
minute,self._pm)
in the format:
Mar.
1, 1997 1:45 pm"""
return '
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._
pmon,self._day,self._year,self._pmhou
r,
self._minute,self._pm)
def
d_mo_d_y4_hm_pm
(self):
def
pCommonZ
(self):
"""Return a string representing the object
\
'
s value
in the format:
Sat Mar 1, 1997 1:45 pm
"""
return '
%
s
%
s
%
s
,
%
4.4
d
%
s
:
%
2.2
d
%
s
' % (
self._
aday,self._amon,self._day,self._yea
r,
self._
pmhour,self._minute,self._pm
)
in the format:
Mar. 1, 1997 1:45 pm US/Eastern
"""
return '
%
s
%
s
,
%
4.4
d
%
d
:
%
2.2
d
%
s
%
s
' % (
self._
pmon,self._day,self._year,self._pmhou
r,
self._
minute,self._pm,self._tz
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment