G
Guest
Hi,
I am working on CodeDOM to generate a more usable class to serialize
and deserialize WXS files. I have hit the wall at a pretty early
stage. :-( I am attempting to change the member public fields into
properties. I have written a generic field to property code for that.
It is almost straight out of the link that you gave me.
But that always creates code with the virtual keyword. I am not sure
on how to get rid of it. For example this is the sample Icon class
created.
public class Icon {
private string _id;
private string _src;
/// <remarks/>
[System.Xml.Serialization.XmlAttributeAttribute()]
public virtual string Id {
get {
return this._id;
}
set {
this._id = value;
}
}
/// <remarks/>
[System.Xml.Serialization.XmlAttributeAttribute()]
public virtual string src {
get {
return this._src;
}
set {
this._src = value;
}
}
}
public virtual string Id ...
public virtual string src ...
As you can see the properties above have the ugly 'virtual' keyword. I
am not sure how to get rid of it.
I am working on CodeDOM to generate a more usable class to serialize
and deserialize WXS files. I have hit the wall at a pretty early
stage. :-( I am attempting to change the member public fields into
properties. I have written a generic field to property code for that.
It is almost straight out of the link that you gave me.

But that always creates code with the virtual keyword. I am not sure
on how to get rid of it. For example this is the sample Icon class
created.
public class Icon {
private string _id;
private string _src;
/// <remarks/>
[System.Xml.Serialization.XmlAttributeAttribute()]
public virtual string Id {
get {
return this._id;
}
set {
this._id = value;
}
}
/// <remarks/>
[System.Xml.Serialization.XmlAttributeAttribute()]
public virtual string src {
get {
return this._src;
}
set {
this._src = value;
}
}
}
public virtual string Id ...
public virtual string src ...
As you can see the properties above have the ugly 'virtual' keyword. I
am not sure how to get rid of it.