# GMSFetchPhotoRequest

Deprecated

This class is deprecated, please use the Place Details component (<https://developers.google.com/maps/documentation/places/ios-sdk/place-details-ui-kit>) instead.


    @interface GMSFetchPhotoRequest : NSObject

Request object to use with `https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacesClient.html` to fetch a photo.
- `
  ### [-initWithPhotoMetadata:maxSize:](https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSFetchPhotoRequest#/c:objc(cs)GMSFetchPhotoRequest(im)initWithPhotoMetadata:maxSize:)

  ` Deprecated

  This class is deprecated, please use the Place Details component (<https://developers.google.com/maps/documentation/places/ios-sdk/place-details-ui-kit>) instead.
  Request object to use with `https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacesClient.html` to fetch a photo.

  #### Declaration

  Swift

      init(photoMetadata: https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacePhotoMetadata.html, maxSize: CGSize)

  Objective-C

      - (nonnull instancetype)initWithPhotoMetadata:
                                  (nonnull https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacePhotoMetadata.html *)photoMetadata
                                            maxSize:(CGSize)maxSize;

  #### Parameters

  |---|---|
  | ` photoMetadata ` | `https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacePhotoMetadata.html` The maximum desired size in pixels of the image returned by the Place Photos service. |
  | ` maxSize ` | `CGSize` The photo metadata to request. If the image is smaller than the values specified, the original image will be returned. If the image is larger in either dimension, it will be scaled to match the smaller of the two dimensions, restricted to its original aspect ratio. CGSize height and width should be set to an integer between 1 and 4800. If not, the `https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSPlacesClient.html` request callback will return an error. |

- `
  ### [-init](https://developers.google.com/maps/documentation/places/ios-sdk/reference/objc/Classes/GMSFetchPhotoRequest#/c:objc(cs)GMSFetchPhotoRequest(im)init)

  ` Deprecated

  This class is deprecated, please use the Place Details component (<https://developers.google.com/maps/documentation/places/ios-sdk/place-details-ui-kit>) instead.
  Unavailable
  Default init is not available. Please use the designated initializer.

  #### Declaration

  Objective-C

      - (nonnull instancetype)init;