Cloud Spanner Client - Class Interval (1.104.0)
Note: Some or all of the information on this page might not apply
to Trusted Cloud. For a list of services that are available in
Trusted Cloud, see Services available for
Trusted Cloud .
Version latestkeyboard_arrow_down
Namespace
Google \ Cloud \ Spanner
Methods
__toString
static::parse
Parses an ISO8601 duration string into an Interval type.
The format for the string should be in the format:
P[n]Y[n]M[n]DT[n]H[n]M[n[.fraction]]S
where n
is an integer.
Parameter
Name
Description
text
string
The ISO8601 duration string
static::fromMonthsDaysNanos
Creates an Interval from months, days and nanoseconds given.
Parameters
Name
Description
months
int
days
int
nanoseconds
float
static::fromMonths
Creates an Interval from the months given.
Parameter
Name
Description
months
int
static::fromDays
Creates an Interval from the days given.
Parameter
Name
Description
days
int
static::fromSeconds
Creates an Interval from the seconds given.
Parameter
Name
Description
seconds
float
static::fromMilliseconds
Creates an Interval from the milliseconds given.
Parameter
Name
Description
milliseconds
float
static::fromMicroseconds
Creates an Interval from the microseconds given.
Parameter
Name
Description
microseconds
float
static::fromNanoseconds
Creates an Interval from the nanoseconds given.
Parameter
Name
Description
nanoseconds
float
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-07 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[],null,[]]