The metadata corresponding to a single photo associated with a place.
Nested Class Summary
class | PhotoMetadata.Builder | Builder for PhotoMetadata . |
Inherited Constant Summary
Public Constructor Summary
Public Method Summary
static PhotoMetadata.Builder | |
abstract String |
getAttributions()
Returns the attributions that must be shown to the user if this photo is displayed.
|
abstract AuthorAttributions |
getAuthorAttributions()
Returns this photo's
AuthorAttributions . |
abstract int |
getHeight()
Returns the maximum height in which this photo is available.
|
abstract int |
getWidth()
Returns the maximum width in which this photo is available.
|
Inherited Method Summary
Public Constructors
public PhotoMetadata ()
Public Methods
public static PhotoMetadata.Builder builder (String photoReference)
Returns a PhotoMetadata.Builder
.
If the attributions
value is not set, it default to an empty String.
If width
or height
values are not set, they default to 0.
Parameters
photoReference | Non-empty String used to identify the underlying photo. |
---|
public abstract String getAttributions ()
Returns the attributions that must be shown to the user if this photo is displayed.
See Displaying Attributions for more details.
Returns
- The attributions in HTML format, or an empty String if there are none.
public abstract AuthorAttributions getAuthorAttributions ()
Returns this photo's AuthorAttributions
.
The author attributions field is only supported by Places API (New). Please enable your API key for the Places API (New) in the Google Cloud Console to access the data.
public abstract int getHeight ()
Returns the maximum height in which this photo is available.
public abstract int getWidth ()
Returns the maximum width in which this photo is available.