import { BaseAPI } from '../common/BaseApi'; import { OldPaginationParams, OldPaginationResponse, UnlApiConfig } from '../models'; import { ClaimRequest } from './models/ClaimRequest'; import { Claim } from './models/Claim'; import { BoundingBox } from './models'; /** * ClaimApi class contains all the methods related to claiming locations. * @class ClaimApi * @extends {BaseAPI} */ export default class ClaimApi extends BaseAPI { constructor(configuration: UnlApiConfig); /** * Create a new claim. * * @param {ClaimRequest} claimRequest ClaimRequest object which represent the new claim to be created. * @returns {Promise} A promise that, in case of success, returns the newly created claim object. * @memberof ClaimApi */ create(claimRequest: ClaimRequest): Promise; /** * Get all claims. * @returns {Promise} A promise that, in case of success, returns an array of Claim objects. * @memberof ClaimApi */ getAll(): Promise; /** * Get a claim by id. * * @param {string} claimId Id of the requested claim. * @return {Promise} A promise that, in case of success, returns the requested claim object. * @memberof ClaimApi */ getById(claimId: string): Promise; /** * Get all claims within a bounding box. * * @param {BoundingBox} boundingBox A bounding box to get the claims from. * @returns {Promise>} A promise that, in case of success, returns an array of all the claims within the specified bounding box, wrapped around a OldPaginationResponse object. * @memberof ClaimApi */ getInBoundingBox(boundingBox: BoundingBox, paginationParams?: OldPaginationParams): Promise>; /** * Update a claim. * * @param {string} claimId Id of the claim to be updated. * @param {ClaimRequest} claimRequest ClaimRequest object which represents the updated claim. * @returns {Promise} A promise that, in case of success, returns the updated claim object. * @memberof ClaimApi */ update(claimId: string, claimRequest: ClaimRequest): Promise; /** * Delete a claim. * * @param {string} claimId Id of the claim to be deleted * @returns {Promise} A promise that, in case of success, returns the deleted claim object. * @memberof ClaimApi */ delete(claimId: string): Promise; }