diff --git a/documentation/classes/EsQueryDto.html b/documentation/classes/EsQueryDto.html new file mode 100644 index 0000000..1a26a78 --- /dev/null +++ b/documentation/classes/EsQueryDto.html @@ -0,0 +1,396 @@ + + +
+ + ++
+ src/core/domain/dtos/es-query.dto.ts
+
+
+
Elasticsearch query DTO
+ + + + + + +
+ Properties+ |
+
+ + | +
+ + + pit + + + | +
+ Type : object
+
+ |
+
+ Defined in src/core/domain/dtos/es-query.dto.ts:39
+ |
+
+ Object, that stores Point-In-Time ID and time alive + |
+
+ + + query + + + | +
+ Type : object
+
+ |
+
+ Decorators :
+ +
+ @IsDefined()
+ |
+
+ Defined in src/core/domain/dtos/es-query.dto.ts:34
+ |
+
+ The search query object passed to Elasticsearch + |
+
+ + + size + + + | +
+ Type : number
+
+ |
+
+ Decorators :
+ +
+ @IsDefined()
+ |
+
+ Defined in src/core/domain/dtos/es-query.dto.ts:23
+ |
+
+ Maximum number of elements returned by Elasticsearch + |
+
+ + + sort + + + | +
+ Type : object
+
+ |
+
+ Defined in src/core/domain/dtos/es-query.dto.ts:44
+ |
+
+ Object, that stores + |
+
import { ApiProperty } from "@nestjs/swagger";
+import { IsDefined, IsInt, IsNotEmpty, IsNumber, IsObject } from "class-validator";
+
+/**
+ * List of allowed properties in this DTO
+ */
+ const allowedProperties = ['size', 'query', 'pit', 'sort'];
+
+ /**
+ * Elasticsearch query DTO
+ */
+ export class EsQueryDto {
+ /**
+ * Maximum number of elements returned by Elasticsearch
+ */
+ @IsDefined()
+ @IsNumber()
+ @IsInt()
+ @ApiProperty({
+ description: 'Maximum number of elements returned by Elasticsearch',
+ example: 30
+ })
+ size: number;
+
+ /**
+ * The search query object passed to Elasticsearch
+ */
+ @IsDefined()
+ @IsObject()
+ @ApiProperty({
+ description: 'Search query object passed to Elasticsearch',
+ example: false,
+ })
+ query: object;
+
+ /**
+ * Object, that stores Point-In-Time ID and time alive
+ */
+ pit: object;
+
+ /**
+ * Object, that stores
+ */
+ sort: object;
+ }
+
+constructor(query: string, page: number, limit: number, order: string)
+ |
+
+ Defined in src/core/domain/dtos/search-q.dto.ts:58
+ |
+
+ Constructs an object with provided parameters + |
+
@ApiOperation({summary: 'Finds paper by its UUID.'})
@ApiResponse({status: 200, description: 'Returns back acquired paper.', type: SearchResultDto})
@Get(':uuid')
+ @ApiOperation({summary: 'Finds paper by its UUID.'})
@ApiResponse({status: 200, description: 'Returns back acquired paper.', type: SearchResultDto})
@Get(':uuid')
@UseInterceptors(PageInterceptor)
@HttpCode(200)
Number of elements on the page
++ + total + + + + + | +
+ total:
+ |
+
+ Type : number
+
+ |
+
+ Total search results |
|
+ + + allowedProperties + + + | +
+ Type : []
+
+ |
+
+ Default value : ['size', 'query', 'pit', 'sort']
+ |
+
+ List of allowed properties in this DTO + |
+
- - - allowedProperties - - - | -
- Type : []
-
- |
-
- Default value : ['query', 'pagen', 'limit', 'order']
- |
-
- List of allowed properties in this DTO - |
-
+ + + allowedProperties + + + | +
+ Type : []
+
+ |
+
+ Default value : ['query', 'pagen', 'limit', 'order']
+ |
+
+ List of allowed properties in this DTO + |
+