DateTime
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
ייצוג JSON |
{
"date": string
} |
שדות |
date |
string
תאריך/שעה בפורמט מורחב לפי תקן ISO 8601. לא חובה לבצע או לא צריך קיזוז (מידע נוסף זמין במסמכי התיעוד של שדה ההורה). ניתן לציין זמן עד לרמת דיוק של ננו-שנייה. אפשר לציין היסט בדיוק בשניות (למרות ששניות היסט הן חלק מתקן ISO 8601). לדוגמה: 1985-04-12T23:20:50.52Z יהיה 20 דקות ו-50.52 שניות אחרי השעה ה-23 של 12 באפריל 1985 לפי שעון UTC.
1985-04-12T19:20:50.52-04:00 יהיה 20 דקות ו-50.52 שניות אחרי השעה ה-19 של 12 באפריל 1985, 4 שעות לפני שעון UTC (אותה נקודת זמן כמו בדוגמה שלמעלה). אם התאריך והשעה מיועדים למיקום פיזי בניו יורק, הם יהיו זהים לשעון הקיץ המזרחי (EDT). חשוב לזכור שההיסט שונה באזורים שבהם יש שעון קיץ (או שעון קיץ), בהתאם לעונה בשנה.
1985-04-12T19:20:50.52 יהיה 20 דקות ו-50.52 שניות אחרי השעה ה-19 של 12 באפריל 1985, ללא מידע על היסט.
ציון קיזוז הופך את הצילום ל מיידי בזמן מסביב לעולם. התאריך/השעה יותאמו לאזור הזמן של המשתמש. לדוגמה, השעה של 2018-06-19T18:30:00-04:00 תהיה 18:30:00 למשתמש בניו יורק ו-15:30:00 למשתמש בלוס אנג'לס. השמטת הקיזוז הופכת את התאריך הזה לתאריך/שעה מקומיים, שמייצג כמה נקודות זמן ברחבי העולם. התאריך והשעה יהיו תמיד באזור הזמן הנוכחי של המשתמש. לדוגמה, השעה של 2018-06-19T18:30:00 תהיה 18:30:00 למשתמש בניו יורק ו-18:30:00 למשתמש בתל אביב. האפשרות הזו שימושית כשאותו תאריך/שעה צריכים לחול על מיקומים פיזיים רבים במספר אזורי זמן.
|
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-07-25 (שעון UTC).
[null,null,["עדכון אחרון: 2025-07-25 (שעון UTC)."],[[["\u003cp\u003eThe JSON schema represents a date object.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003edate\u003c/code\u003e field is a string that adheres to the ISO 8601 extended format for date and time.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003edate\u003c/code\u003e field can include an offset to specify the time zone, or it can be omitted for local time representation.\u003c/p\u003e\n"],["\u003cp\u003eProviding an offset ensures the \u003ccode\u003edate\u003c/code\u003e represents a specific instant in time globally, while omitting it makes it a local time subject to user time zones.\u003c/p\u003e\n"]]],["The core information defines the `date` field within a JSON structure. The `date` is a string representing an ISO 8601 date/time, with optional offset information. It may include nanosecond precision. Providing an offset creates an absolute instant in time, adjusted to the user's timezone. Omitting the offset creates a local date/time, consistent across time zones. This format can represent times down to the nanosecond and offsets with second precision.\n"],null,["# DateTime\n\n- [JSON representation](#SCHEMA_REPRESENTATION)\n\n| JSON representation |\n|----------------------------|\n| ``` { \"date\": string } ``` |\n\n| Fields ||\n|--------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `date` | `string` An ISO 8601 extended format date/time. Offset may or may not be required (refer to the parent field's documentation). Time may be specified up to nanosecond precision. Offsets may be specified with seconds precision (even though offset seconds is not part of ISO 8601). For example: `1985-04-12T23:20:50.52Z` would be 20 minutes and 50.52 seconds after the 23rd hour of April 12th, 1985 in UTC. `1985-04-12T19:20:50.52-04:00` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985, 4 hours before UTC (same instant in time as the above example). If the date/time is intended for a physical location in New York, this would be the equivalent of Eastern Daylight Time (EDT). Remember that offset varies in regions that observe Daylight Saving Time (or Summer Time), depending on the time of the year. `1985-04-12T19:20:50.52` would be 20 minutes and 50.52 seconds after the 19th hour of April 12th, 1985 with no offset information. Providing an offset makes this an absolute instant in time around the world. The date/time will be adjusted based on the user's time zone. For example, a time of `2018-06-19T18:30:00-04:00` will be 18:30:00 for a user in New York and 15:30:00 for a user in Los Angeles. Omitting the offset makes this a local date/time, representing several instants in time around the world. The date/time will always be in the user's current time zone. For example, a time of `2018-06-19T18:30:00` will be 18:30:00 for a user in New York and also 18:30:00 for a user in Los Angeles. This is useful when the same local date/time should apply to many physical locations across several time zones. |"]]