Skip to content

Table

reference
1 min readUpdated

Kind: Class

Source: Pams/Web/Pams.WebApp/Client/app/models/dashboard/data-source-schema/table.model.ts (line 6)

Part of: Pams

Table represents a table entry in the dashboard data-source schema model layer. Its clone() method creates a separate Table instance for workflows that need to preserve the original schema object.

Methods

MethodSignatureReturns
cloneclone(model: Table)void

Properties

PropertyType
ConStringstring
ConNamestring
Idstring
Namestring
TableIDstring
Schemastring
NameSpacestring
ColumnsColumn[]
Dataany

Where it refuses work

  • Table stops the work with an early return when model == null.

Diagram

mermaid
graph LR
  Schema[Data-source schema] --> Table[Table]
  Table --> Clone[clone()]
  Clone --> Copy[Copied Table]

Usage

ts
import { Table } from './models/dashboard/data-source-schema/table.model';

function prepareTableForEditing(sourceTable: Table): Table {
  const editableTable = sourceTable.clone();

  return editableTable;
}

AI Coding Instructions

  • Use clone() before modifying a Table when the original schema object must remain unchanged.
  • Keep Table instances within the dashboard data-source schema model layer.
  • Do not assume whether clone() performs shallow or deep copying; check its implementation before mutating nested values.
  • Pass cloned instances through existing schema-processing code rather than rebuilding Table objects manually.

Relationships

  • IMPORTS → Column
  • IMPORTS → GetColumnPrameter

Used by

3 references from 3 files. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

Imported by (3)

  • DataSourceServicePams/Web/Pams.WebApp/Client/app/services/dashboard/data-source.service.ts:1
  • DashboardWidgetPams/Web/Pams.WebApp/Client/app/models/dashboard/dashboard-widget.model.ts:11
  • DataSourceConnectionPams/Web/Pams.WebApp/Client/app/models/dashboard/data-source-schema/data-source-connection.model.ts:4

Was this page helpful?

Download as PDF