Class CallStackReader


  • class CallStackReader
    extends java.lang.Object
    A class to find the unique ordered classpath elements.
    • Constructor Detail

      • CallStackReader

        public CallStackReader​(ReflectionUtils reflectionUtils)
        Constructor.
    • Method Detail

      • getCallStackViaStackWalker

        private static java.lang.Class<?>[] getCallStackViaStackWalker()
        Get the call stack via the StackWalker API (JRE 9+).
        Returns:
        the call stack, or null if it could not be obtained.
      • getCallStackViaSecurityManager

        private static java.lang.Class<?>[] getCallStackViaSecurityManager​(LogNode log)
        Get the call stack via the SecurityManager.getClassContext() native method.
        Parameters:
        log - the log
        Returns:
        the call stack.
      • getClassContext

        java.lang.Class<?>[] getClassContext​(LogNode log)
        Get the class context.
        Parameters:
        log - the log
        Returns:
        The classes in the call stack.