Skip to content

Commit

Permalink
docs and ts
Browse files Browse the repository at this point in the history
  • Loading branch information
Liza K committed Sep 24, 2020
1 parent 624f30f commit f3b5e62
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ export interface ISearchStart
| [aggs](./kibana-plugin-plugins-data-public.isearchstart.aggs.md) | <code>AggsStart</code> | agg config sub service [AggsStart](./kibana-plugin-plugins-data-public.aggsstart.md) |
| [search](./kibana-plugin-plugins-data-public.isearchstart.search.md) | <code>ISearchGeneric</code> | low level search [ISearchGeneric](./kibana-plugin-plugins-data-public.isearchgeneric.md) |
| [searchSource](./kibana-plugin-plugins-data-public.isearchstart.searchsource.md) | <code>ISearchStartSearchSource</code> | high level search [ISearchStartSearchSource](./kibana-plugin-plugins-data-public.isearchstartsearchsource.md) |
| [showError](./kibana-plugin-plugins-data-public.isearchstart.showerror.md) | <code>(e: any) =&gt; void</code> | |
| [showError](./kibana-plugin-plugins-data-public.isearchstart.showerror.md) | <code>(e: Error) =&gt; void</code> | |

Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
<b>Signature:</b>

```typescript
showError: (e: any) => void;
showError: (e: Error) => void;
```
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ Constructs a new instance of the `PainlessError` class
<b>Signature:</b>

```typescript
constructor(err: EsError, request: IEsSearchRequest);
constructor(err: EsError, request: IKibanaSearchRequest);
```

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| err | <code>EsError</code> | |
| request | <code>IEsSearchRequest</code> | |
| request | <code>IKibanaSearchRequest</code> | |

Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@
<b>Signature:</b>

```typescript
protected handleSearchError(e: any, request: IEsSearchRequest, timeoutSignal: AbortSignal, appAbortSignal?: AbortSignal): Error;
protected handleSearchError(e: any, request: IKibanaSearchRequest, timeoutSignal: AbortSignal, appAbortSignal?: AbortSignal): Error;
```

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| e | <code>any</code> | |
| request | <code>IEsSearchRequest</code> | |
| request | <code>IKibanaSearchRequest</code> | |
| timeoutSignal | <code>AbortSignal</code> | |
| appAbortSignal | <code>AbortSignal</code> | |

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ Searches using the given `search` method. Overrides the `AbortSignal` with one t
<b>Signature:</b>

```typescript
search(request: IEsSearchRequest, options?: ISearchOptions): Observable<IKibanaSearchResponse>;
search(request: IKibanaSearchRequest, options?: ISearchOptions): Observable<IKibanaSearchResponse>;
```

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| request | <code>IEsSearchRequest</code> | |
| request | <code>IKibanaSearchRequest</code> | |
| options | <code>ISearchOptions</code> | |

<b>Returns:</b>
Expand Down
10 changes: 5 additions & 5 deletions src/plugins/data/public/public.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1465,7 +1465,7 @@ export interface ISearchStart {
search: ISearchGeneric;
searchSource: ISearchStartSearchSource;
// (undocumented)
showError: (e: any) => void;
showError: (e: Error) => void;
}

// @public
Expand Down Expand Up @@ -1638,7 +1638,7 @@ export interface OptionedValueProp {
// @public (undocumented)
export class PainlessError extends KbnError {
// Warning: (ae-forgotten-export) The symbol "EsError" needs to be exported by the entry point index.d.ts
constructor(err: EsError, request: IEsSearchRequest);
constructor(err: EsError, request: IKibanaSearchRequest);
// (undocumented)
getErrorMessage(application: ApplicationStart): JSX.Element;
// (undocumented)
Expand Down Expand Up @@ -2036,12 +2036,12 @@ export class SearchInterceptor {
// (undocumented)
protected getTimeoutMode(): TimeoutErrorMode;
// (undocumented)
protected handleSearchError(e: any, request: IEsSearchRequest, timeoutSignal: AbortSignal, appAbortSignal?: AbortSignal): Error;
protected handleSearchError(e: any, request: IKibanaSearchRequest, timeoutSignal: AbortSignal, appAbortSignal?: AbortSignal): Error;
// @internal
protected pendingCount$: BehaviorSubject<number>;
// @internal (undocumented)
protected runSearch(request: IEsSearchRequest, signal: AbortSignal, strategy?: string): Observable<IKibanaSearchResponse>;
search(request: IEsSearchRequest, options?: ISearchOptions): Observable<IKibanaSearchResponse>;
protected runSearch(request: IKibanaSearchRequest, signal: AbortSignal, strategy?: string): Observable<IKibanaSearchResponse>;
search(request: IKibanaSearchRequest, options?: ISearchOptions): Observable<IKibanaSearchResponse>;
// @internal (undocumented)
protected setupAbortSignal({ abortSignal, timeout, }: {
abortSignal?: AbortSignal;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ describe('alert actions', () => {
updateTimelineIsLoading = jest.fn() as jest.Mocked<UpdateTimelineLoading>;
searchStrategyClient = {
aggs: {} as ISearchStart['aggs'],
showError: jest.fn(),
search: jest.fn().mockResolvedValue({ data: mockTimelineDetails }),
searchSource: {} as ISearchStart['searchSource'],
};
Expand Down

0 comments on commit f3b5e62

Please sign in to comment.