A Quick C# Question: Sealed classes

If you have a sealed class are all the methods inside the sealed class also typed as sealed.I am asking this because I have some virtual functions inside an abstract class that I would like to seal, I don’t want the class to be extended so sealing the class makes sense. Therefore if I just seal the class can all the methods be considered sealed by the JIT’er or do I have to seal the methods too.


This content originally appeared on Modern Web Development with Chrome and was authored by Paul Kinlan

<p>If you have a sealed class are all the methods inside the sealed class also typed as sealed.<p />I am asking this because I have some virtual functions inside an abstract class that I would like to seal, I don't want the class to be extended so sealing the class makes sense. Therefore if I just seal the class can all the methods be considered sealed by the JIT'er or do I have to seal the methods too.<p /></p>


This content originally appeared on Modern Web Development with Chrome and was authored by Paul Kinlan


Print Share Comment Cite Upload Translate Updates
APA

Paul Kinlan | Sciencx (2006-02-14T00:00:00+00:00) A Quick C# Question: Sealed classes. Retrieved from https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/

MLA
" » A Quick C# Question: Sealed classes." Paul Kinlan | Sciencx - Tuesday February 14, 2006, https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/
HARVARD
Paul Kinlan | Sciencx Tuesday February 14, 2006 » A Quick C# Question: Sealed classes., viewed ,<https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/>
VANCOUVER
Paul Kinlan | Sciencx - » A Quick C# Question: Sealed classes. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/
CHICAGO
" » A Quick C# Question: Sealed classes." Paul Kinlan | Sciencx - Accessed . https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/
IEEE
" » A Quick C# Question: Sealed classes." Paul Kinlan | Sciencx [Online]. Available: https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/. [Accessed: ]
rf:citation
» A Quick C# Question: Sealed classes | Paul Kinlan | Sciencx | https://www.scien.cx/2006/02/14/a-quick-c-question-sealed-classes/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.