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. General Programming
  3. C#
  4. Differance Between Protected and protected internal

Differance Between Protected and protected internal

Scheduled Pinned Locked Moved C#
tutorialquestion
7 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.
  • R Offline
    R Offline
    Rahul RK
    wrote on last edited by
    #1

    Hello Friends, I want to know what is difference between protected and protected internal. i know that protected means access limited to type and types derived from it. and protected internal means access limited to type and types derived from it or in the assembly. Do protected is subset of protected internal. And do protected is required when we specify internal as access specifier. please give example that will be helpfull.. Thanks in advance. rahul kulkarni

    C 1 Reply Last reply
    0
    • R Rahul RK

      Hello Friends, I want to know what is difference between protected and protected internal. i know that protected means access limited to type and types derived from it. and protected internal means access limited to type and types derived from it or in the assembly. Do protected is subset of protected internal. And do protected is required when we specify internal as access specifier. please give example that will be helpfull.. Thanks in advance. rahul kulkarni

      C Offline
      C Offline
      Colin Angus Mackay
      wrote on last edited by
      #2

      Rahul.RK wrote:

      I want to know what is difference between protected and protected internal.

      According to the documentation[^] the answer is: protected = Access is limited to the containing class or types derived from the containing class protected internal = Access is limited to the current assembly or types derived from the containing class


      Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

      R 1 Reply Last reply
      0
      • C Colin Angus Mackay

        Rahul.RK wrote:

        I want to know what is difference between protected and protected internal.

        According to the documentation[^] the answer is: protected = Access is limited to the containing class or types derived from the containing class protected internal = Access is limited to the current assembly or types derived from the containing class


        Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

        R Offline
        R Offline
        Rahul RK
        wrote on last edited by
        #3

        hello Thanks for reply... i got the concept according to definition. But as internal gives access to all the assembly then what is use of protected? Thats my question.. Rahul Kulkarni

        C 1 Reply Last reply
        0
        • R Rahul RK

          hello Thanks for reply... i got the concept according to definition. But as internal gives access to all the assembly then what is use of protected? Thats my question.. Rahul Kulkarni

          C Offline
          C Offline
          Colin Angus Mackay
          wrote on last edited by
          #4

          Rahul.RK wrote:

          But as internal gives access to all the assembly then what is use of protected?

          So you can derive a class from it from outside the assembly.


          Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

          R 1 Reply Last reply
          0
          • C Colin Angus Mackay

            Rahul.RK wrote:

            But as internal gives access to all the assembly then what is use of protected?

            So you can derive a class from it from outside the assembly.


            Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

            R Offline
            R Offline
            Rahul RK
            wrote on last edited by
            #5

            Thanks alot.... Will you please give me any helpfull site of book name which will give me idea of all this basic fundamentals of C#.Net Rahul Kulkarni

            C 1 Reply Last reply
            0
            • R Rahul RK

              Thanks alot.... Will you please give me any helpfull site of book name which will give me idea of all this basic fundamentals of C#.Net Rahul Kulkarni

              C Offline
              C Offline
              Colin Angus Mackay
              wrote on last edited by
              #6

              There are lots of beginner books. It really depends on your style of learning. Go to the book store and browse through a few books. Pick the one that appeals to you most.


              Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

              R 1 Reply Last reply
              0
              • C Colin Angus Mackay

                There are lots of beginner books. It really depends on your style of learning. Go to the book store and browse through a few books. Pick the one that appeals to you most.


                Upcoming events: * Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ... * Reading: Developer Day 5 Ready to Give up - Your help will be much appreciated. My website

                R Offline
                R Offline
                Rahul RK
                wrote on last edited by
                #7

                Thanks for help. Rahul Kulkarni

                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