Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Benefit of make the business layer class as sealed class

Benefit of make the business layer class as sealed class

Scheduled Pinned Locked Moved ASP.NET
businessperformancequestioncode-review
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hogan smith
    wrote on last edited by
    #1

    I set all my business layer classes as sealed class. I did like this because I read from somewhere that this will improve the performance. Is it true? Thanks and Regards, Hogan

    M 1 Reply Last reply
    0
    • H hogan smith

      I set all my business layer classes as sealed class. I did like this because I read from somewhere that this will improve the performance. Is it true? Thanks and Regards, Hogan

      M Offline
      M Offline
      Michael Sync
      wrote on last edited by
      #2

      hogan.smith wrote:

      I read from somewhere that this will improve the performance. Is it true?

      I set the class as sealed class when I want to prevent derivation.. That's all. I never heard that the sealed class is better than the normal class..

      Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

      H 1 Reply Last reply
      0
      • M Michael Sync

        hogan.smith wrote:

        I read from somewhere that this will improve the performance. Is it true?

        I set the class as sealed class when I want to prevent derivation.. That's all. I never heard that the sealed class is better than the normal class..

        Thanks and Regards, Michael Sync ( Blog: http://michaelsync.net)

        H Offline
        H Offline
        hogan smith
        wrote on last edited by
        #3

        A sealed class cannot be used as a base class. For this reason, it cannot also be an abstract class. Sealed classes are primarily used to prevent derivation. Because they can never be used as a base class, some run-time optimizations can make calling sealed class members slightly faster. I copied the above sentance from MSDN 2005 Thanks, Hogan

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups