datasourceVariableBuilder.ts 445 B

123456789101112131415
  1. import { DataSourceVariableModel, VariableRefresh } from 'app/features/variables/types';
  2. import { MultiVariableBuilder } from './multiVariableBuilder';
  3. export class DatasourceVariableBuilder<T extends DataSourceVariableModel> extends MultiVariableBuilder<T> {
  4. withRefresh(refresh: VariableRefresh) {
  5. this.variable.refresh = refresh;
  6. return this;
  7. }
  8. withRegEx(regex: any) {
  9. this.variable.regex = regex;
  10. return this;
  11. }
  12. }