All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.wildfly.swarm.config.jmx.JMXRemotingConnector Maven / Gradle / Ivy

There is a newer version: 2.7.0
Show newest version
package org.wildfly.swarm.config.jmx;

import org.wildfly.swarm.config.runtime.AttributeDocumentation;
import org.wildfly.swarm.config.runtime.ResourceDocumentation;
import org.wildfly.swarm.config.runtime.SingletonResource;
import org.wildfly.swarm.config.runtime.Address;
import org.wildfly.swarm.config.runtime.ResourceType;
import org.wildfly.swarm.config.runtime.Implicit;
import java.beans.PropertyChangeSupport;
import java.beans.PropertyChangeListener;
import org.wildfly.swarm.config.runtime.ModelNodeBinding;

/**
 * A JBoss remoting connector for the JMX subsystem.
 */
@Address("/subsystem=jmx/remoting-connector=jmx")
@ResourceType("remoting-connector")
@Implicit
public class JMXRemotingConnector>
		implements
			org.wildfly.swarm.config.runtime.Keyed {

	private String key;
	private PropertyChangeSupport pcs;
	@AttributeDocumentation("If true the connector will use the management endpoint, otherwise it will use the remoting subsystem one")
	private Boolean useManagementEndpoint;

	public JMXRemotingConnector() {
		super();
		this.key = "jmx";
		this.pcs = new PropertyChangeSupport(this);
	}

	public String getKey() {
		return this.key;
	}

	/**
	 * Adds a property change listener
	 */
	public void addPropertyChangeListener(PropertyChangeListener listener) {
		if (null == this.pcs)
			this.pcs = new PropertyChangeSupport(this);
		this.pcs.addPropertyChangeListener(listener);
	}

	/**
	 * Removes a property change listener
	 */
	public void removePropertyChangeListener(
			java.beans.PropertyChangeListener listener) {
		if (this.pcs != null)
			this.pcs.removePropertyChangeListener(listener);
	}

	/**
	 * If true the connector will use the management endpoint, otherwise it will
	 * use the remoting subsystem one
	 */
	@ModelNodeBinding(detypedName = "use-management-endpoint")
	public Boolean useManagementEndpoint() {
		return this.useManagementEndpoint;
	}

	/**
	 * If true the connector will use the management endpoint, otherwise it will
	 * use the remoting subsystem one
	 */
	@SuppressWarnings("unchecked")
	public T useManagementEndpoint(java.lang.Boolean value) {
		Object oldValue = this.useManagementEndpoint;
		this.useManagementEndpoint = value;
		if (this.pcs != null)
			this.pcs.firePropertyChange("useManagementEndpoint", oldValue,
					value);
		return (T) this;
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy