Answer a Timestamp that represents this DateAndTime
Redefinition of:
- DateAndTime::asTimeStamp()
- Answer a Timestamp that represents this DateAndTime
Answer the reciever as a UNIX timestamp - The number of seconds since the Unix Epoch (January 1 1970 00:00:00 GMT/UTC).
integer
asUnixTimeStamp
()
Answer a TimeStamp representing now
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Answer the date of the receiver.
Answer a two element Array containing the receiver's date and time.
array
dateAndTimeArray
()
Answer a TimeStamp representing the Squeak epoch: 1 January 1901
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::epoch()
- Answer a new instance representing the Squeak epoch: 1 January 1901
Answer a new instance represented by a string:
- '-1199-01-05T20:33:14.321-05:00'
- ' 2002-05-16T17:20:45.00000001+01:01'
- ' 2002-05-16T17:20:45.00000001'
- ' 2002-05-16T17:20'
- ' 2002-05-16T17:20:45'
- ' 2002-05-16T17:20:45+01:57'
- ' 2002-05-16T17:20:45-02:34'
- ' 2002-05-16T17:20:45+00:00'
- ' 1997-04-26T01:02:03+01:02:3'
-
string
$aString: The input string.
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::fromString()
- Answer a new instance represented by a string:
Create a new TimeStamp from a UNIX timestamp.
object Timestamp
fromUnixTimeStamp
(integer $aUnixTimeStamp, [optional $class = 'TimeStamp'])
-
integer
$aUnixTimeStamp: The number of seconds since the Unix Epoch (January 1 1970 00:00:00 GMT/UTC)
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Answer a new instance starting at midnight local time.
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::midnight()
- Answer a new instance starting at midnight local time.
Answer a TimeStamp which is anInteger days before the receiver.
Answer a TimeStamp which is anInteger seconds before the receiver.
Answer a new instance starting at noon local time.
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::noon()
- Answer a new instance starting at noon local time.
Answer the current time.
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::now()
- Answer the current date and time.
Answer a TimeStamp which is anInteger days after the receiver.
Answer a TimeStamp which is anInteger seconds after the receiver.
Print receiver's date and time
string
printableString
()
Redefinition of:
- DateAndTime::printableString()
- Print as per ISO 8601 sections 5.3.3 and 5.4.1.
Answer the time of the receiver.
Answer a new instance representing today
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::today()
- Answer a new instance representing today
Answer a new instance representing tomorow
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::tomorrow()
- Answer a new instance representing tomorow
Create a new instance from Date and Time objects
object TimeStamp
withDateAndTime
(
optional $aDate,
mixed $aTime, [
mixed $class =
'TimeStamp'])
-
optional
$aDate: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withDateAndTime()
- Create a new instance from Date and Time objects
Create a new instance for a given Julian Day Number.
object TimeStamp
withJulianDayNumber
(
integer $aJulianDayNumber, [
optional $class =
'TimeStamp'])
-
integer
$aJulianDayNumber
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withJulianDayNumber()
- Create a new new instance for a given Julian Day Number.
Create a new instance.
void
withYearDay
(integer $anIntYear, integer $anIntDayOfYear, [optional $class = 'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntDayOfYear
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearDay()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearDayHourMinuteSecond
(
integer $anIntYear,
integer $anIntDayOfYear,
integer $anIntHour,
integer $anIntMinute,
integer $anIntSecond, [
optional $class =
'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntDayOfYear
-
integer
$anIntHour
-
integer
$anIntMinute
-
integer
$anIntSecond
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearDayHourMinuteSecond()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearDayHourMinuteSecondOffset
(
integer $anIntYear,
integer $anIntDayOfYear,
integer $anIntHour,
integer $anIntMinute,
integer $anIntSecond,
object Duration $aDurationOffset, [
optional $class =
'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntDayOfYear
-
integer
$anIntHour
-
integer
$anIntMinute
-
integer
$anIntSecond
-
object Duration
$aDurationOffset
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearDayHourMinuteSecondOffset()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearMonthDay
(
integer $anIntYear,
integer $anIntOrStringMonth,
integer $anIntDay, [
optional $class =
'Timestamp'])
-
integer
$anIntYear
-
integer
$anIntOrStringMonth
-
integer
$anIntDay
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearMonthDay()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearMonthDayHourMinute
(
integer $anIntYear,
integer $anIntOrStringMonth,
integer $anIntDay,
integer $anIntHour,
integer $anIntMinute, [
optional $class =
'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntOrStringMonth
-
integer
$anIntDay
-
integer
$anIntHour
-
integer
$anIntMinute
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearMonthDayHourMinute()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearMonthDayHourMinuteSecond
(
integer $anIntYear,
integer $anIntOrStringMonth,
integer $anIntDay,
integer $anIntHour,
integer $anIntMinute,
integer $anIntSecond, [
optional $class =
'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntOrStringMonth
-
integer
$anIntDay
-
integer
$anIntHour
-
integer
$anIntMinute
-
integer
$anIntSecond
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearMonthDayHourMinuteSecond()
- Create a new instance.
Create a new instance.
object TimeStamp
withYearMonthDayHourMinuteSecondOffset
(
integer $anIntYear,
integer $anIntOrStringMonth,
integer $anIntDay,
integer $anIntHour,
integer $anIntMinute,
integer $anIntSecond,
object Duration $aDurationOffset, [
optional $class =
'TimeStamp'])
-
integer
$anIntYear
-
integer
$anIntOrStringMonth
-
integer
$anIntDay
-
integer
$anIntHour
-
integer
$anIntMinute
-
integer
$anIntSecond
-
object Duration
$aDurationOffset
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::withYearMonthDayHourMinuteSecondOffset()
- Create a new instance.
Answer a new instance representing yesterday
-
optional
$class: string $class DO NOT USE OUTSIDE OF PACKAGE. This parameter is used to get around the limitations of not being able to find the class of the object that recieved the initial method call.
Redefinition of:
- DateAndTime::yesterday()
- Answer a new instance representing yesterday
Inherited Methods
Inherited From DateAndTime
DateAndTime::asDate()
DateAndTime::asDateAndTime()
DateAndTime::asDuration()
DateAndTime::asLocal()
DateAndTime::asMonth()
DateAndTime::asSeconds()
DateAndTime::asTime()
DateAndTime::asTimeStamp()
DateAndTime::asUTC()
DateAndTime::asWeek()
DateAndTime::asYear()
DateAndTime::atMidnight()
DateAndTime::atNoon()
DateAndTime::clockPrecision()
DateAndTime::day()
DateAndTime::dayMonthYearArray()
DateAndTime::dayOfMonth()
DateAndTime::dayOfWeek()
DateAndTime::dayOfWeekAbbreviation()
DateAndTime::dayOfWeekName()
DateAndTime::dayOfYear()
DateAndTime::daysInMonth()
DateAndTime::daysInYear()
DateAndTime::daysLeftInYear()
DateAndTime::duration()
DateAndTime::epoch()
DateAndTime::firstDayOfMonth()
DateAndTime::fromString()
DateAndTime::hmsString()
DateAndTime::hour()
DateAndTime::hour12()
DateAndTime::hour24()
DateAndTime::isEqualTo()
DateAndTime::isLeapYear()
DateAndTime::isLessThan()
DateAndTime::julianDayNumber()
DateAndTime::localOffset()
DateAndTime::localTimeZone()
DateAndTime::mdyString()
DateAndTime::meridianAbbreviation()
DateAndTime::middleOf()
DateAndTime::midnight()
DateAndTime::minus()
DateAndTime::minute()
DateAndTime::month()
DateAndTime::monthAbbreviation()
DateAndTime::monthIndex()
DateAndTime::monthName()
DateAndTime::noon()
DateAndTime::now()
DateAndTime::offset()
DateAndTime::plus()
DateAndTime::printableString()
DateAndTime::second()
DateAndTime::ticks()
DateAndTime::ticksOffset()
DateAndTime::timeZone()
DateAndTime::timeZoneAbbreviation()
DateAndTime::timeZoneName()
DateAndTime::to()
DateAndTime::toBy()
DateAndTime::today()
DateAndTime::tomorrow()
DateAndTime::utcOffset()
DateAndTime::withDateAndTime()
DateAndTime::withJulianDayNumber()
DateAndTime::withOffset()
DateAndTime::withYearDay()
DateAndTime::withYearDayHourMinuteSecond()
DateAndTime::withYearDayHourMinuteSecondOffset()
DateAndTime::withYearMonthDay()
DateAndTime::withYearMonthDayHourMinute()
DateAndTime::withYearMonthDayHourMinuteSecond()
DateAndTime::withYearMonthDayHourMinuteSecondOffset()
DateAndTime::year()
DateAndTime::yesterday()
DateAndTime::ymdString()
DateAndTime::_normalize()
Inherited From Magnitude
Magnitude::isBetween()
Magnitude::isEqualTo()
Magnitude::isGreaterThan()
Magnitude::isGreaterThanOrEqualTo()
Magnitude::isLessThan()
Magnitude::isLessThanOrEqualTo()
Magnitude::max()
Magnitude::min()
Inherited From SObject
SObject::asA()
SObject::asString()
SObject::copy()
SObject::copySameFrom()
SObject::copyTwoLevel()
SObject::deepCopy()
SObject::isEqual()
SObject::isEqualTo()
SObject::isNotEqualTo()
SObject::isNotReferenceTo()
SObject::isReferenceTo()
SObject::newFrom()
SObject::postCopy()
SObject::printableString()
SObject::shallowCopy()
SObject::_deepCopyArray()