Class AccessToSymbolOrError

All Implemented Interfaces:
Consumer<SymbolAccessData>

final class AccessToSymbolOrError extends TypedSymbolAccess implements Consumer<SymbolAccessData>
Check that a symbol can be accessed issues error if not possible.

isAccessible(SymbolAccessData) is THE access rule (private: only from within the same type; protected: only from within the same type hierarchy; public: anywhere). A check that must report a denial under its own, clearer code (E07835 for collect as T) asks the predicate rather than re-deriving the rule.