Class ByteBuddyAgent.AttachmentTypeEvaluator.ForJava9CapableVm

    • Field Detail

      • current

        private final java.lang.reflect.Method current
        The java.lang.ProcessHandle#current() method.
      • pid

        private final java.lang.reflect.Method pid
        The java.lang.ProcessHandle#pid() method.
    • Constructor Detail

      • ForJava9CapableVm

        protected ForJava9CapableVm​(java.lang.reflect.Method current,
                                    java.lang.reflect.Method pid)
        Creates a new attachment type evaluator.
        Parameters:
        current - The java.lang.ProcessHandle#current() method.
        pid - The java.lang.ProcessHandle#pid() method.
    • Method Detail

      • requiresExternalAttachment

        public boolean requiresExternalAttachment​(java.lang.String processId)
        Checks if the current VM requires external attachment for the supplied process id.
        Specified by:
        requiresExternalAttachment in interface ByteBuddyAgent.AttachmentTypeEvaluator
        Parameters:
        processId - The process id of the process to which to attach.
        Returns:
        true if the current VM requires external attachment for the supplied process.