martijnversluis/ChordSheetJS

View on GitHub
src/chord_sheet/chord_pro/literal.ts

Summary

Maintainability
A
0 mins
Test Coverage
import Evaluatable from './evaluatable';

class Literal extends Evaluatable {
  string: string;

  constructor(string: string) {
    super();
    this.string = string;
  }

  evaluate(): string {
    return this.string;
  }

  isRenderable(): boolean {
    return true;
  }

  clone(): Literal {
    return new Literal(this.string);
  }
}

export default Literal;