All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amadeus.dutyOfCare.diseases.Covid19Report Maven / Gradle / Ivy

package com.amadeus.dutyofcare.diseases;

import com.amadeus.Amadeus;
import com.amadeus.Params;
import com.amadeus.Response;
import com.amadeus.exceptions.ResponseException;
import com.amadeus.resources.DiseaseReport;
import com.amadeus.resources.Resource;

/**
 * 

* A namespaced client for the * /v2/duty-of-care/diseases/covid19-area-report endpoints. *

* *

* Access via the Amadeus client object. *

* *
 * Amadeus amadeus = Amadeus.builder(API_KEY, API_SECRET).build();
 * amadeus.dutyOfCare.diseases.covid19Report;
*/ public class Covid19Report { private Amadeus client; /** * Constructor. * @hide */ public Covid19Report(Amadeus client) { this.client = client; } /** *

* Get up-to-date data on COVID-19 caseloads and travel restrictions * for a given country, city or region. *

* *
   * amadeus.dutyOfCare.diseases.covid19Report.get(Params
   *     .with("countryCode", "US"));
   * 
* * @param params the parameters to send to the API * @return an API response object * @throws ResponseException when an exception occurs */ public DiseaseReport get(Params params) throws ResponseException { Response response = client.get("/v2/duty-of-care/diseases/covid19-area-report", params); return (DiseaseReport) Resource.fromObject(response, DiseaseReport.class); } /** * Convenience method for calling get without any parameters. * @see Covid19Report#get() */ public DiseaseReport get() throws ResponseException { return get(null); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy