Search:
Namespaces
Discussions
.NET v1.1
Feedback
Code DOM
Messages
Related Types
This message was discovered on
microsoft.public.dotnet.languages.csharp
.
Post a new message to this list...
J.Marsch
We are going to use the Code DOM to generate some utility classes. CodeDom
looks really cool. My question: is there a built in parser? I want to
write a code generator that will create classes that represent table
structures. The thing is, that it will also need to be able to load an
existing copy of a class that it created and analyze it (when the table
structures are modified). Looks like the DOM already contains a nice model
that categorizes the properties and methods that are in a class. I just
need a way to load an existing source file into it.
Reply to this message...
BACbKA
Unfortunately, such stuff is not implemented yet.
You would use a parser as follows:
System.CodeDom.Compiler.
CodeDomProvider
provider =
new Microsoft.CSharp.
CSharpCodeProvider
();
System.CodeDom.Compiler.
ICodeParser
parser =
provider.CreateParser();
....
System.CodeDom.
CodeCompileUnit
unit = parser.Parse( textReader );
.... etc ...
However, provider.CreateParser() returns you 'null' no matter what.
On Thu, 30 May 2002 11:22:49 -0500, "J.Marsch"
<
Click here to reveal e-mail address
> wrote:
[Original message clipped]
Reply to this message...
J.Marsch
Bummer. Do they have a wishlist?
"BACbKA" <
Click here to reveal e-mail address
> wrote in message
news:
Click here to reveal e-mail address
...
[Original message clipped]
Reply to this message...
Microsoft.CSharp.CSharpCodeProvider
System.CodeDom.CodeCompileUnit
System.CodeDom.Compiler.CodeDomProvider
System.CodeDom.Compiler.ICodeParser
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us
-
Terms of Use
-
Privacy Policy
-
www.dotnet247.com