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

com.factset.sdk.IRNNotes.api.EventsApi Maven / Gradle / Ivy

There is a newer version: 4.0.1
Show newest version
package com.factset.sdk.IRNNotes.api;

import com.factset.sdk.IRNNotes.ApiException;
import com.factset.sdk.IRNNotes.ApiClient;
import com.factset.sdk.IRNNotes.ApiResponse;
import com.factset.sdk.IRNNotes.Configuration;
import com.factset.sdk.IRNNotes.Pair;

import javax.ws.rs.core.GenericType;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;

import com.factset.sdk.IRNNotes.models.EventSnippetDto;
import com.factset.sdk.IRNNotes.models.NoteEventDto;
import com.factset.sdk.IRNNotes.models.ProblemDetails;
import com.factset.sdk.IRNNotes.models.RecordEventSummaryDto;

@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class EventsApi {
  private ApiClient apiClient;

  public EventsApi() {
    this(Configuration.getDefaultApiClient());
  }

  public EventsApi(ApiClient apiClient) {
    this.apiClient = apiClient;
  }
  
  private static final Map getAllEventsResponseTypeMap = new HashMap();
  static {
    getAllEventsResponseTypeMap.put(200, new GenericType>(){});
  }

  private static final Map getEventsResponseTypeMap = new HashMap();
  static {
    getEventsResponseTypeMap.put(200, new GenericType>(){});
    getEventsResponseTypeMap.put(404, new GenericType(){});
    getEventsResponseTypeMap.put(0, new GenericType(){});
  }

  private static final Map getRecordEventResponseTypeMap = new HashMap();
  static {
    getRecordEventResponseTypeMap.put(200, new GenericType(){});
    getRecordEventResponseTypeMap.put(403, new GenericType(){});
    getRecordEventResponseTypeMap.put(404, new GenericType(){});
  }

  


  /**
   * Get the API client
   *
   * @return API client
   */
  public ApiClient getApiClient() {
    return apiClient;
  }

  /**
   * Set the API client
   *
   * @param apiClient an instance of API client
   */
  public void setApiClient(ApiClient apiClient) {
    this.apiClient = apiClient;
  }

  /**
   * Get all the record events in the specified date range filtered on the given types
   * 
   * @param startDate StartDate (required)
   * @param endDate EndDate (optional)
   * @param types Set of event types to filter on (optional)
   * @return java.util.List
   * @throws ApiException if fails to make API call
   * @http.response.details
     
Status Code Description Response Headers
200 Success - Returns events list -
400 Bad Request - Returns error message -
*/ public java.util.List getAllEvents(String startDate, String endDate, java.util.List types) throws ApiException { return getAllEventsWithHttpInfo(startDate, endDate, types).getData(); } /** * Get all the record events in the specified date range filtered on the given types * * @param startDate StartDate (required) * @param endDate EndDate (optional) * @param types Set of event types to filter on (optional) * @return ApiResponse<java.util.List> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success - Returns events list -
400 Bad Request - Returns error message -
*/ public ApiResponse> getAllEventsWithHttpInfo(String startDate, String endDate, java.util.List types) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'startDate' is set if (startDate == null) { throw new ApiException(400, "Missing the required parameter 'startDate' when calling getAllEvents"); } // create path and map variables String localVarPath = "/v1/events"; // query params java.util.List localVarQueryParams = new java.util.ArrayList(); java.util.Map localVarHeaderParams = new java.util.HashMap(); java.util.Map localVarCookieParams = new java.util.HashMap(); java.util.Map localVarFormParams = new java.util.HashMap(); localVarQueryParams.addAll(apiClient.parameterToPairs("", "startDate", startDate)); localVarQueryParams.addAll(apiClient.parameterToPairs("", "endDate", endDate)); localVarQueryParams.addAll(apiClient.parameterToPairs("multi", "types", types)); final String[] localVarAccepts = { "text/plain", "application/json", "text/json" }; final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); final String[] localVarContentTypes = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< java.util.List > apiResponse = apiClient.invokeAPI("EventsApi.getAllEvents", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getAllEventsResponseTypeMap, false); return apiResponse; } /** * Get all the record events that belong to a note * * @param noteId Note Id (required) * @return java.util.List * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
404 Not Found -
0 Error -
*/ public java.util.List getEvents(java.util.UUID noteId) throws ApiException { return getEventsWithHttpInfo(noteId).getData(); } /** * Get all the record events that belong to a note * * @param noteId Note Id (required) * @return ApiResponse<java.util.List> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
404 Not Found -
0 Error -
*/ public ApiResponse> getEventsWithHttpInfo(java.util.UUID noteId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'noteId' is set if (noteId == null) { throw new ApiException(400, "Missing the required parameter 'noteId' when calling getEvents"); } // create path and map variables String localVarPath = "/v1/notes/{noteId}/events" .replaceAll("\\{" + "noteId" + "\\}", apiClient.escapeString(noteId.toString())); // query params java.util.List localVarQueryParams = new java.util.ArrayList(); java.util.Map localVarHeaderParams = new java.util.HashMap(); java.util.Map localVarCookieParams = new java.util.HashMap(); java.util.Map localVarFormParams = new java.util.HashMap(); final String[] localVarAccepts = { "application/json" }; final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); final String[] localVarContentTypes = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< java.util.List > apiResponse = apiClient.invokeAPI("EventsApi.getEvents", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getEventsResponseTypeMap, false); return apiResponse; } /** * Get details of a record event of a note * * @param noteId Note Id (required) * @param recordEventId Record Event Id (required) * @return NoteEventDto * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
403 Forbidden -
404 Not Found -
*/ public NoteEventDto getRecordEvent(java.util.UUID noteId, java.util.UUID recordEventId) throws ApiException { return getRecordEventWithHttpInfo(noteId, recordEventId).getData(); } /** * Get details of a record event of a note * * @param noteId Note Id (required) * @param recordEventId Record Event Id (required) * @return ApiResponse<NoteEventDto> * @throws ApiException if fails to make API call * @http.response.details
Status Code Description Response Headers
200 Success -
403 Forbidden -
404 Not Found -
*/ public ApiResponse getRecordEventWithHttpInfo(java.util.UUID noteId, java.util.UUID recordEventId) throws ApiException { Object localVarPostBody = null; // verify the required parameter 'noteId' is set if (noteId == null) { throw new ApiException(400, "Missing the required parameter 'noteId' when calling getRecordEvent"); } // verify the required parameter 'recordEventId' is set if (recordEventId == null) { throw new ApiException(400, "Missing the required parameter 'recordEventId' when calling getRecordEvent"); } // create path and map variables String localVarPath = "/v1/notes/{noteId}/events/{recordEventId}" .replaceAll("\\{" + "noteId" + "\\}", apiClient.escapeString(noteId.toString())) .replaceAll("\\{" + "recordEventId" + "\\}", apiClient.escapeString(recordEventId.toString())); // query params java.util.List localVarQueryParams = new java.util.ArrayList(); java.util.Map localVarHeaderParams = new java.util.HashMap(); java.util.Map localVarCookieParams = new java.util.HashMap(); java.util.Map localVarFormParams = new java.util.HashMap(); final String[] localVarAccepts = { "application/json" }; final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); final String[] localVarContentTypes = { }; final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); String[] localVarAuthNames = new String[] { "FactSetApiKey", "FactSetOAuth2", "FactSetOAuth2Client" }; ApiResponse< NoteEventDto > apiResponse = apiClient.invokeAPI("EventsApi.getRecordEvent", localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, getRecordEventResponseTypeMap, false); return apiResponse; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy