@loopback/docs
Version:
Documentation for LoopBack 4
33 lines (22 loc) • 1.05 kB
Markdown
lang: en
title: 'API docs: repository.defaultkeyvaluerepository._constructor_'
keywords: LoopBack 4.0, LoopBack 4
sidebar: lb4_sidebar
permalink: /doc/en/lb4/apidocs.repository.defaultkeyvaluerepository._constructor_.html
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@loopback/repository](./repository.md) > [DefaultKeyValueRepository](./repository.defaultkeyvaluerepository.md) > [(constructor)](./repository.defaultkeyvaluerepository._constructor_.md)
## DefaultKeyValueRepository._constructor_
Construct a KeyValueRepository with a legacy DataSource
<b>Signature:</b>
```typescript
constructor(entityClass: typeof Entity & {
prototype: T;
}, ds: juggler.DataSource);
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| entityClass | <code>typeof Entity & {</code><br/><code> prototype: T;</code><br/><code> }</code> | |
| ds | <code>juggler.DataSource</code> | Legacy DataSource |