GTAdhocAPI
Gran Turismo (6) Adhoc API Documentation
Loading...
Searching...
No Matches
pdistd::MTime Class Reference

Represents an object describing a date and time. More...

Inheritance diagram for pdistd::MTime:
System::Object

Public Member Functions

 MTime ()
 Gets a new time initialized to 0000/00/00 00:00:00 as UTC. More...
 
 MTime (String time_str)
 Gets a time formatted from input string - Should be UTC. More...
 
String ctime ()
 Returns the date as a C-Type time string i.e Sun Jan 1 13:00:01 2000. More...
 
MTime toLocal ()
 Returns the date accounted with locale offset. More...
 
MTime toGMT ()
 Returns the date accounted converted to GMT. More...
 
Long getBySecond ()
 Returns timestamp as seconds (Julian) More...
 
void setBySecond (Long timestamp)
 Sets timestamp from seconds (Julian) More...
 
void setTimeFromMinutes (Int minutes)
 Sets the MTime's time (date is not altered!) More...
 
void getLocaleString ()
 Gets the time as string for current locale - France will be dd/MM/YYYY for instance. More...
 
void setForCourse (Int seconds)
 
 operator== ()
 Whether two dates are equal. More...
 
 operator!= ()
 Whether two dates are not equal. More...
 
 operator< ()
 Whether a date is earlier to the other. More...
 
 operator<= ()
 Whether a date is earlier or equal to the other. More...
 
 operator> ()
 Whether a date is later to the other. More...
 
 operator>= ()
 Whether a date is later or equal to the other. More...
 
- Public Member Functions inherited from System::Object
 Object ()
 constructor taking no param More...
 
Bool isInstanceOf (Class classType)
 Returns whether an object is of a specific class/type. More...
 
Object getDeepCopy ()
 Gets a deep copy of this object. More...
 
void setDeepCopy (Object obj)
 Unk. More...
 
String dump ()
 Dumps all info about an object. More...
 
Object getObjectAttribute (string path)
 
void setObjectAttribute (string path, Object value)
 
Bool hasPrimitiveInterface ()
 Returns whether this object has a primitive interface. More...
 
Bool toBool ()
 Casts this object to Bool. More...
 
Byte toByte ()
 Casts this object to Byte. More...
 
Short toShort ()
 Casts this object to Short. More...
 
Int toInt ()
 Casts this object to Int. More...
 
Long toLong ()
 Casts this object to Long. More...
 
UByte toUByte ()
 Casts this object to UByte. More...
 
UShort toUShort ()
 Casts this object to UShort. More...
 
UInt toUInt ()
 Casts this object to UInt. More...
 
ULong toULong ()
 Casts this object to ULong. More...
 
Float toFloat ()
 Casts this object to Float. More...
 
Double toDouble ()
 Casts this object to Double. More...
 
String toString ()
 Casts this object to String. More...
 
Symbol toSymbol ()
 Casts this object to Symbol. More...
 
Bool hasArrayInterface ()
 Returns whether this object has an Array interface. More...
 
Int getArrayCount ()
 Gets the Array item count for this object. More...
 
void setArrayCount ()
 Sets the Array item count for this object. More...
 
Object getArrayElement (Object arg0)
 Gets an Array item for this object. More...
 
void setArrayElement (Object arg0, Object arg1)
 Sets the Array item for this object. More...
 
Bool hasMapInterface ()
 Returns whether this object has a Map interface. More...
 
int getMapCount ()
 Returns the count of items in the map. More...
 
void setMapElement (Object arg0, Object arg1)
 Returns whether the Map has a specific object key. Bool hasMapElement(Object arg0);. More...
 
Object getMapElement (Object arg0)
 Gets a Map element by key. More...
 
void hasGeneratorInterface ()
 Returns whether this object has a generator interface. More...
 
Iterator generator ()
 Returns generator (?) More...
 
void hasIteratorInterface ()
 Returns whether this object has an iterator. More...
 
Iterator iterator ()
 Gets the iterator for this object. More...
 
void hasVariableInterface ()
 Returns whether this object is a variable. More...
 
void hasFunctionInterface ()
 Returns whether this object has a function interface. More...
 
Object call ()
 Calls this object as a function. More...
 
Bool hasByteDataInterface ()
 Returns whether this object has a byte data interface. More...
 
Int getByteDataCount ()
 Returns the ByteData size for this object. More...
 
void setByteDataCount (Int count)
 Sets the ByteData size for this object. More...
 
Int getByteDataCapacity ()
 Returns the ByteData capacity for this object. More...
 
void setByteDataCapacity (Int capacity)
 Sets the ByteData capacity for this object. More...
 
ByteData getByteData ()
 Gets the underlaying ByteData. More...
 
void setByteData (ByteData bytedata)
 Sets the underlaying ByteData. More...
 
void hasObjectSelectorInterface ()
 Returns whether this object has an object selector interface. More...
 
void self ()
 Gets the get for this object if it has a get interface. More...
 
void getArchiveTree ()
 
void setArchiveTree ()
 
ByteData serialize ()
 Serializes this object. More...
 
void deserialize (ByteData serializedData)
 Deserializes this object. More...
 
void defined (Object obj)
 Returns whether a certain object is defined within this object. More...
 
Array find_all (FunctionObject func)
 Finds all the elements in this object that matches the predicates. More...
 
void each_all (FunctionObject func)
 Applies callback to all elements in this object. More...
 
Array map_all (FunctionObject< Object > func)
 Maps all the elements in this object. More...
 
Bool operator!= ()
 Returns whether this object is not equal to another. More...
 
Bool operator== ()
 Returns whether this object is equal to another. More...
 

Static Public Member Functions

static MTime getCurrentTime ()
 Gets MTime for current UTC. More...
 
static Int getDifferenceOfDay (MTime left, MTime right)
 Gets the number of days between two dates. More...
 

Public Attributes

Int racetime1000
 Gets the total milliseconds for this day (year/month/day is ignored) More...
 
Int year
 Gets the year component for this date. More...
 
Int month
 Gets the month component for this date. More...
 
Int day
 Gets the day component for this date. More...
 
Int hour
 Gets the hour component for this date. More...
 
Int minute
 Gets the minute component for this date. More...
 
Int second
 Gets the second component for this date. More...
 
Int dow
 Gets the day of week (as number) More...
 
- Public Attributes inherited from System::Object
Int rc_size
 Getter-only. Reference counter size of this object. More...
 
Object rc_class
 Getter-only. Type name of the object. More...
 
Int rc_count
 Getter-only. Reference count of this object. More...
 
Int weak_count
 Getter-only. Weak reference count of this object. More...
 
Class class_id
 Class (type) object for this object. More...
 

Detailed Description

Represents an object describing a date and time.

Internally uses Julian.

Definition at line 7 of file MTime.cpp.

Constructor & Destructor Documentation

◆ MTime() [1/2]

pdistd::MTime::MTime ( )
inline

Gets a new time initialized to 0000/00/00 00:00:00 as UTC.

Definition at line 12 of file MTime.cpp.

◆ MTime() [2/2]

pdistd::MTime::MTime ( String  time_str)

Gets a time formatted from input string - Should be UTC.

Parameters
time_strFormat must be 'yyyy/mm/dd hh:mm:dd' i.e 0000/00/00 00:00:00

Member Function Documentation

◆ ctime()

String pdistd::MTime::ctime ( )

Returns the date as a C-Type time string i.e Sun Jan 1 13:00:01 2000.

◆ getBySecond()

Long pdistd::MTime::getBySecond ( )

Returns timestamp as seconds (Julian)

◆ getCurrentTime()

static MTime pdistd::MTime::getCurrentTime ( )
static

Gets MTime for current UTC.

◆ getDifferenceOfDay()

static Int pdistd::MTime::getDifferenceOfDay ( MTime  left,
MTime  right 
)
static

Gets the number of days between two dates.

◆ getLocaleString()

void pdistd::MTime::getLocaleString ( )

Gets the time as string for current locale - France will be dd/MM/YYYY for instance.

◆ operator!=()

pdistd::MTime::operator!= ( )
inline

Whether two dates are not equal.

Definition at line 75 of file MTime.cpp.

◆ operator<()

pdistd::MTime::operator< ( )
inline

Whether a date is earlier to the other.

Definition at line 75 of file MTime.cpp.

◆ operator<=()

pdistd::MTime::operator<= ( )
inline

Whether a date is earlier or equal to the other.

Definition at line 75 of file MTime.cpp.

◆ operator==()

pdistd::MTime::operator== ( )
inline

Whether two dates are equal.

Definition at line 72 of file MTime.cpp.

◆ operator>()

pdistd::MTime::operator> ( )
inline

Whether a date is later to the other.

Definition at line 84 of file MTime.cpp.

◆ operator>=()

pdistd::MTime::operator>= ( )
inline

Whether a date is later or equal to the other.

Definition at line 87 of file MTime.cpp.

◆ setBySecond()

void pdistd::MTime::setBySecond ( Long  timestamp)

Sets timestamp from seconds (Julian)

◆ setForCourse()

void pdistd::MTime::setForCourse ( Int  seconds)

◆ setTimeFromMinutes()

void pdistd::MTime::setTimeFromMinutes ( Int  minutes)

Sets the MTime's time (date is not altered!)

◆ toGMT()

MTime pdistd::MTime::toGMT ( )

Returns the date accounted converted to GMT.

◆ toLocal()

MTime pdistd::MTime::toLocal ( )

Returns the date accounted with locale offset.

Member Data Documentation

◆ day

Int pdistd::MTime::day

Gets the day component for this date.

Definition at line 28 of file MTime.cpp.

◆ dow

Int pdistd::MTime::dow

Gets the day of week (as number)

Definition at line 69 of file MTime.cpp.

◆ hour

Int pdistd::MTime::hour

Gets the hour component for this date.

Definition at line 31 of file MTime.cpp.

◆ minute

Int pdistd::MTime::minute

Gets the minute component for this date.

Definition at line 34 of file MTime.cpp.

◆ month

Int pdistd::MTime::month

Gets the month component for this date.

Definition at line 25 of file MTime.cpp.

◆ racetime1000

Int pdistd::MTime::racetime1000

Gets the total milliseconds for this day (year/month/day is ignored)

Definition at line 19 of file MTime.cpp.

◆ second

Int pdistd::MTime::second

Gets the second component for this date.

Definition at line 37 of file MTime.cpp.

◆ year

Int pdistd::MTime::year

Gets the year component for this date.

Definition at line 22 of file MTime.cpp.


The documentation for this class was generated from the following file: