开发者

How to specify template class visibility for a T4 preprocessed template?

开发者 https://www.devze.com 2023-01-30 19:27 出处:网络
I have started adding some preprocessed T4 templates to a VS2010 C# library project. They are implementation details only, and I would prefer to not have them exposed on the library\'s API. I have not

I have started adding some preprocessed T4 templates to a VS2010 C# library project. They are implementation details only, and I would prefer to not have them exposed on the library's API. I have not found a way to set the template开发者_运维技巧's generated class visibility to 'internal'.

Is there a way? (If there is, I assume it will be something obvious that I have missed)

Thanks in advance,

/AI/


VS2012 has visibility="internal" on template.


Aethon, Unfortunately there is no way to do this today short of post-processing the generated code in some fashion.

I'm looking at adding this for a future release of Visual Studio. If you wanted to log a Connect issue for this, that would be helpful.

0

精彩评论

暂无评论...
验证码 换一张
取 消