camera.getMetadata
Restituisce i metadati del file a partire dal relativo URI. L'intestazione immagine
elenca i campi Exif e XMP. Questo comando è stato deprecato nel livello API 2.
Parametri
- fileUri: URI del file di destinazione. Sono i produttori a decidere se
per utilizzare URI assoluti o relativi. I clienti possono considerarlo come un identificatore opaco.
Risultati
- metadata: EXIF (incluse le informazioni GPS), XMP foto sferica in
JSON. Non include immagini o miniature.
Errori
- missingParameter:
fileUri
non è specificato.
- invalidParameterName:nome del parametro di input non riconosciuto.
- invalidParameterValue: il parametro di input viene riconosciuto, ma i suoi
il valore non è valido. ad esempio
fileUri
non esiste o i relativi dati
il tipo non è corretto.
I/O comando |
Input comando |
{ "parameters": { "fileUri": "file URI" } } |
Output comando |
{ "results": { "exif": { ... "ImageWidth": 2000, "ImageLength": 1000, ... }, "xmp": { "ProjectionType": "equirectangular", "UsePanoramaViewer": true, ... } } } |
Output comando (errore) |
{ "error": { "code": "invalidParameterValue", "message": "Parameter fileUri doesn't exist." } } |
Salvo quando diversamente specificato, i contenuti di questa pagina sono concessi in base alla licenza Creative Commons Attribution 4.0, mentre gli esempi di codice sono concessi in base alla licenza Apache 2.0. Per ulteriori dettagli, consulta le norme del sito di Google Developers. Java è un marchio registrato di Oracle e/o delle sue consociate.
Ultimo aggiornamento 2024-08-21 UTC.
[null,null,["Ultimo aggiornamento 2024-08-21 UTC."],[[["Returns file metadata such as Exif and XMP data for a given file URI."],["This command is deprecated and was previously used in API level 2."],["Important parameters include the `fileUri`, which specifies the location of the target file."],["Potential errors encompass missing or invalid parameters, including an invalid or non-existent `fileUri`."],["The command output provides Exif and Photo Sphere XMP data in JSON format if successful."]]],["This command retrieves a file's metadata using its URI. It's deprecated in API level 2. Input requires a `fileUri`. The output provides Exif data (including GPS) and Photo Sphere XMP in JSON format, excluding the image itself. Possible errors include a missing or invalid `fileUri`, or an unrecognized parameter name. Example input shows providing a file URI, with successful output including `exif` and `xmp` fields, and error output shown when a file URI does not exist.\n"]]