Skip to main content

I know an inner class can inherit the wrapper apex class. But can an inner apex class have different sharing (more or less restrictive) than its parent class? #PD1 #PlatformDevI 

2 Kommentare
  1. 1. Juli 2020, 05:32
    hi @Eric Kenney

    The inner classes do not inherit the sharing settings of their outer/container class .So yes , an inner apex class can have different sharing (more or less restrictive) than its parent class.

    But if a class extends or implements some other class in that case sharing settings are also inherited from that inherited class to the one that is inherititng.

    Please refer below link for further explanation :

    https://learn-force.com/2019/08/26/understanding-sharing-in-apex-class/#:~:text=If%20a%20class%20is%20not,class%2C%20then%20the%20called%20or
0/9000