message: Reordered the methods in BuildBundler to make them easier to find.
diff: @@ -80,39 +80,6 @@ export class BuildBundler extends Transform {
  this._urlMapper = urlMapper;
  }
  - _transform(
  - file: File,
  - _encoding: string,
  - callback: (error?: any, data?: File) => void): void {
  - this._mapFile(file);
  - callback(null, null);
  - }
  -
  - _mapFile(file: File) {
  - this.files.set(urlFromPath(this.config.root, file.path), file);
  - }
  -
  - _getFilesChangedSinceInitialAnalysis(): string[] {
  - const filesChanged = [];
  - for (const [url, originalFile] of this._buildAnalyzer.files) {
  - const downstreamFile = this.files.get(url);
  - if (downstreamFile.contents.toString() !==
  - originalFile.contents.toString()) {
  - filesChanged.push(url);
  - }
  - }
  - return filesChanged;
  - }
  -
  - async _flush(done: (error?: any) => void) {
  - await this._buildBundles();
  - for (const file of this.files.values()) {
  - this.push(file);
  - }
  - // end the stream
  - done();
  - }
  -
  async _buildBundles() {
  // Tell the analyzer about changed files so it can purge them from its cache
  // before using the analyzer for bundling.
  @@ -125,6 +92,7 @@ export class BuildBundler extends Transform {
  // Remove the bundled files from the file map so they are not emitted later.
  this._unmapBundledFiles(manifest);
  + // Map the bundles into the file map.
  for (const [filename, document] of bundles) {
  this._mapFile(new File({
  path: pathFromUrl(this.config.root, filename),
  @@ -133,6 +101,15 @@ export class BuildBundler extends Transform {
  }
  }
  + async _flush(done: (error?: any) => void) {
  + await this._buildBundles();
  + for (const file of this.files.values()) {
  + this.push(file);
  + }
  + // end the stream
  + done();
  + }
  +
  async _generateBundleManifest(): Promise<BundleManifest> {
  const strategy = this._strategy ||
  this.config.shell && generateShellMergeStrategy(urlFromPath(
  @@ -144,6 +121,30 @@ export class BuildBundler extends Transform {
  this._urlMapper);
  }
  + _getFilesChangedSinceInitialAnalysis(): string[] {
  + const filesChanged = [];
  + for (const [url, originalFile] of this._buildAnalyzer.files) {
  + const downstreamFile = this.files.get(url);
  + if (downstreamFile.contents.toString() !==
  + originalFile.contents.toString()) {
  + filesChanged.push(url);
  + }
  + }
  + return filesChanged;
  + }
  +
  + _mapFile(file: File) {
  + this.files.set(urlFromPath(this.config.root, file.path), file);
  + }
  +
  + _transform(
  + file: File,
  + _encoding: string,
  + callback: (error?: any, data?: File) => void): void {
  + this._mapFile(file);
  + callback(null, null);
  + }
  +
  _unmapBundledFiles(manifest: BundleManifest) {
  for (const bundle of manifest.bundles.values()) {
  for (const filename of bundle.files) {
  