Commit Graph

3 Commits

Author SHA1 Message Date
Ryan Nowak 0dbf62196c Introduces RuntimeTarget and abstraction for APIs
This is a new abstraction that represents the api surface available for
codegen to target. Every kind of document should have an associated
RuntimeTarget or just use the default.

To prevent breakage, our DocumentClassifierBase class will provide a
default API set to implementors (like MVC).

I haven't fundamentally changed how codegen is done yet, I've just hidden
it behind a new abstraction. The RuntimeTarget now is also responsible for
selecting between design time and runtime.

The bulk of the noise here is from splitting a lot of the codegen stuff
into its own files.
2017-02-13 15:34:51 -08:00
N. Taylor Mullen 61b2b0d4e7 Add model for differentiating design time and runtime parsing.
- If needed, a phase/feature can always retrieve the syntax tree to lookup whether the parse tree was made in a "design time" fashion.
- Future DesignTime / Runtime specific bits will be added to their corresponding `AddRuntimeDefaults`/`AddDesignTimeDefaults` methods.
2016-12-14 12:39:25 -08:00
N. Taylor Mullen 5d4c4e1ccf Add Razor runtime code generation.
- Added TabSize,IsIndentingWithTabs and NamespaceImports to the RazorParser options. These are replacements for the existing RazorEngineHost abstraction.
- Added RazorParserOptions consumption pattern to more than just the parsing phase.
- Added a ChecksumIRNode to ensure Debugging can work.
- Updated tests to to react to new Checksum and Namespace nodes in the IR tree.
2016-12-14 11:18:30 -08:00