pydicom.valuerep.DA¶
- class pydicom.valuerep.DA(*args: Any, **kwargs: Any)[source]¶
Store value for an element with VR DA as
datetime.date.Note that the
datetime.datebase class is immutable.Methods
__init__(*args, **kwargs)Create a new DA element value.
ctime()Return ctime() style string.
fromisocalendarint, int, int -> Construct a date from the ISO year, week number and weekday.
fromisoformat(object, /)str -> Construct a date from a string in ISO 8601 format.
fromordinalint -> date corresponding to a proleptic Gregorian ordinal.
fromtimestamp(timestamp, /)Create a date from a POSIX timestamp.
isocalendar()Return a named tuple containing ISO year, week number, and weekday.
isoformat()Return string in ISO 8601 format, YYYY-MM-DD.
isoweekday()Return the day of the week represented by the date.
replaceReturn date with new specified fields.
strftimeformat -> strftime() style string.
timetuple()Return time tuple, compatible with time.localtime().
today()Current date or datetime: same as self.__class__.fromtimestamp(time.time()).
toordinal()Return proleptic Gregorian ordinal.
weekday()Return the day of the week represented by the date.
Attributes
daymaxminmonthresolutionyearoriginal_string