| OLD | NEW | 
|---|
|  | (Empty) | 
| 1 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file |  | 
| 2 // for details. All rights reserved. Use of this source code is governed by a |  | 
| 3 // BSD-style license that can be found in the LICENSE file. |  | 
| 4 |  | 
| 5 library files; |  | 
| 6 |  | 
| 7 import 'package:html5lib/dom.dart'; |  | 
| 8 |  | 
| 9 /** An input file to process by the template compiler. */ |  | 
| 10 class SourceFile { |  | 
| 11   static const int HTML = 1; |  | 
| 12   static const int DART = 2; |  | 
| 13   static const int STYLESHEET = 3; |  | 
| 14 |  | 
| 15   final String path; |  | 
| 16   final int type; |  | 
| 17 |  | 
| 18   Document document; |  | 
| 19 |  | 
| 20   /** Dart code or contents of a linked style sheet. */ |  | 
| 21   String code; |  | 
| 22 |  | 
| 23   SourceFile(this.path, {this.type: HTML}); |  | 
| 24 |  | 
| 25   bool get isDart => type == DART; |  | 
| 26   bool get isHtml => type == HTML; |  | 
| 27   bool get isStyleSheet => type == STYLESHEET; |  | 
| 28 |  | 
| 29   String toString() => "#<SourceFile $path>"; |  | 
| 30 } |  | 
| 31 |  | 
| 32 /** An output file to generated by the template compiler. */ |  | 
| 33 class OutputFile { |  | 
| 34   final String path; |  | 
| 35   final String contents; |  | 
| 36 |  | 
| 37   /** |  | 
| 38    * Path to the source file that was transformed into this OutputFile, `null` |  | 
| 39    * for files that are generated and do not correspond to an input |  | 
| 40    * [SourceFile]. |  | 
| 41    */ |  | 
| 42   final String source; |  | 
| 43 |  | 
| 44   OutputFile(this.path, this.contents, {this.source}); |  | 
| 45 |  | 
| 46   String toString() => "#<OutputFile $path>"; |  | 
| 47 } |  | 
| OLD | NEW | 
|---|