8283254: Remove redundant class jdk/internal/agent/spi/AgentProvider

Reviewed-by: mchung, redestad, dfuchs
This commit is contained in:
Kevin Walls 2022-03-23 11:03:25 +00:00
parent 6ed0ba2f8a
commit 61d7d868db
3 changed files with 1 additions and 80 deletions

View File

@ -51,7 +51,6 @@ import javax.management.remote.JMXConnectorServer;
import javax.management.remote.JMXServiceURL;
import static jdk.internal.agent.AgentConfigurationError.*;
import jdk.internal.agent.spi.AgentProvider;
import jdk.internal.vm.VMSupport;
import sun.management.jdp.JdpController;
import sun.management.jdp.JdpException;

View File

@ -1,76 +0,0 @@
/*
* Copyright (c) 2016, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package jdk.internal.agent.spi;
import java.util.Properties;
/**
* Service interface for management agent
*/
public abstract class AgentProvider {
/**
* Instantiates a new AgentProvider.
*/
protected AgentProvider() {
}
/**
* Gets the name of the agent provider.
*
* @return name of agent provider
*/
public abstract String getName();
/**
* Initializes and starts the agent.
*
* @throws IllegalStateException if this agent has already been started.
*/
public abstract void startAgent();
/**
* Initializes and starts the agent at given port and with given properties
*
* @param props environment variables for agent
*
* @throws IllegalStateException if this agent has already been started.
*/
public abstract void startAgent(Properties props);
/**
* Checks if agent is started and not terminated.
*
* @return true if agent is running, false otherwise.
*/
public abstract boolean isActive();
/**
* Stops this agent.
*
* @throws IllegalStateException if this agent is not started.
*/
public abstract void stopAgent();
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2022, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -39,6 +39,4 @@ module jdk.management.agent {
requires java.management.rmi;
exports jdk.internal.agent to jdk.jconsole;
uses jdk.internal.agent.spi.AgentProvider;
}