Skip to content

Commit 860b93a

Browse files
clydinalan-agius4
authored andcommitted
refactor(@angular-devkit/schematics): remove now unused internal UpdateBuffer class
The internal `UpdateBuffer` class is no longer used within the schematics package and can be removed.
1 parent 77f6a41 commit 860b93a

File tree

3 files changed

+7
-305
lines changed

3 files changed

+7
-305
lines changed

packages/angular_devkit/schematics/src/tree/recorder.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,17 @@
66
* found in the LICENSE file at https://angular.io/license
77
*/
88

9+
import { BaseException } from '@angular-devkit/core';
910
import MagicString from 'magic-string';
1011
import { ContentHasMutatedException } from '../exception/exception';
11-
import { IndexOutOfBoundException } from '../utility/update-buffer';
1212
import { FileEntry, UpdateRecorder } from './interface';
1313

14+
export class IndexOutOfBoundException extends BaseException {
15+
constructor(index: number, min: number, max = Infinity) {
16+
super(`Index ${index} outside of range [${min}, ${max}].`);
17+
}
18+
}
19+
1420
export class UpdateRecorderBase implements UpdateRecorder {
1521
protected _path: string;
1622
protected content: MagicString;

packages/angular_devkit/schematics/src/utility/update-buffer.ts

Lines changed: 0 additions & 98 deletions
This file was deleted.

packages/angular_devkit/schematics/src/utility/update-buffer_spec.ts

Lines changed: 0 additions & 206 deletions
This file was deleted.

0 commit comments

Comments
 (0)