source: trip-planner-front/node_modules/@angular/cdk/esm2015/table/table-errors.js@ 6c1585f

Last change on this file since 6c1585f was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 6.7 KB
Line 
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8/**
9 * Returns an error to be thrown when attempting to find an unexisting column.
10 * @param id Id whose lookup failed.
11 * @docs-private
12 */
13export function getTableUnknownColumnError(id) {
14 return Error(`Could not find column with id "${id}".`);
15}
16/**
17 * Returns an error to be thrown when two column definitions have the same name.
18 * @docs-private
19 */
20export function getTableDuplicateColumnNameError(name) {
21 return Error(`Duplicate column definition name provided: "${name}".`);
22}
23/**
24 * Returns an error to be thrown when there are multiple rows that are missing a when function.
25 * @docs-private
26 */
27export function getTableMultipleDefaultRowDefsError() {
28 return Error(`There can only be one default row without a when predicate function.`);
29}
30/**
31 * Returns an error to be thrown when there are no matching row defs for a particular set of data.
32 * @docs-private
33 */
34export function getTableMissingMatchingRowDefError(data) {
35 return Error(`Could not find a matching row definition for the` +
36 `provided row data: ${JSON.stringify(data)}`);
37}
38/**
39 * Returns an error to be thrown when there is no row definitions present in the content.
40 * @docs-private
41 */
42export function getTableMissingRowDefsError() {
43 return Error('Missing definitions for header, footer, and row; ' +
44 'cannot determine which columns should be rendered.');
45}
46/**
47 * Returns an error to be thrown when the data source does not match the compatible types.
48 * @docs-private
49 */
50export function getTableUnknownDataSourceError() {
51 return Error(`Provided data source did not match an array, Observable, or DataSource`);
52}
53/**
54 * Returns an error to be thrown when the text column cannot find a parent table to inject.
55 * @docs-private
56 */
57export function getTableTextColumnMissingParentTableError() {
58 return Error(`Text column could not find a parent table for registration.`);
59}
60/**
61 * Returns an error to be thrown when a table text column doesn't have a name.
62 * @docs-private
63 */
64export function getTableTextColumnMissingNameError() {
65 return Error(`Table text column must have a name.`);
66}
67//# sourceMappingURL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