JMXAccessorConditionBase (Apache Tomcat 7.0.104 API Documentation)

org.apache.catalina.ant.jmx

## Class JMXAccessorConditionBase

- java.lang.Object
- - org.apache.tools.ant.ProjectComponent
  - - org.apache.catalina.ant.jmx.JMXAccessorConditionBase

- All Implemented Interfaces:
    Cloneable, org.apache.tools.ant.taskdefs.condition.Condition
  Direct Known Subclasses:
    JMXAccessorCondition, JMXAccessorEqualsCondition

      public abstract class JMXAccessorConditionBase
      extends org.apache.tools.ant.ProjectComponent
      implements org.apache.tools.ant.taskdefs.condition.Condition

- - ### Field Summary

    - ### Fields inherited from class org.apache.tools.ant.ProjectComponent

      `description, location, project`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `JMXAccessorConditionBase()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected String` | `accessJMXValue()` Get value from MBeans attribute.
    `String` | `getAttribute()`
    `String` | `getHost()`
    `protected MBeanServerConnection` | `getJMXConnection()` Get JMXConnection (default look at jmx.server project reference from jmxOpen Task).
    `String` | `getName()`
    `String` | `getPassword()`
    `String` | `getPort()`
    `String` | `getRef()`
    `String` | `getUrl()`
    `String` | `getUsername()`
    `String` | `getValue()`
    `void` | `setAttribute(String attribute)`
    `void` | `setHost(String host)`
    `void` | `setName(String objectName)`
    `void` | `setPassword(String password)`
    `void` | `setPort(String port)`
    `void` | `setRef(String refId)`
    `void` | `setUrl(String url)`
    `void` | `setUsername(String username)`
    `void` | `setValue(String value)`

    - ### Methods inherited from class org.apache.tools.ant.ProjectComponent

      `clone, getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.apache.tools.ant.taskdefs.condition.Condition

      `eval`

- - ### Constructor Detail

    - #### JMXAccessorConditionBase

          public JMXAccessorConditionBase()

  - ### Method Detail

    - #### getAttribute

          public String getAttribute()

      Returns:
        Returns the attribute.

    - #### setAttribute

          public void setAttribute(String attribute)

      Parameters:
        `attribute` - The attribute to set.

    - #### getHost

          public String getHost()

      Returns:
        Returns the host.

    - #### setHost

          public void setHost(String host)

      Parameters:
        `host` - The host to set.

    - #### getName

          public String getName()

      Returns:
        Returns the name.

    - #### setName

          public void setName(String objectName)

      Parameters:
        `objectName` - The name to set.

    - #### getPassword

          public String getPassword()

      Returns:
        Returns the password.

    - #### setPassword

          public void setPassword(String password)

      Parameters:
        `password` - The password to set.

    - #### getPort

          public String getPort()

      Returns:
        Returns the port.

    - #### setPort

          public void setPort(String port)

      Parameters:
        `port` - The port to set.

    - #### getUrl

          public String getUrl()

      Returns:
        Returns the url.

    - #### setUrl

          public void setUrl(String url)

      Parameters:
        `url` - The url to set.

    - #### getUsername

          public String getUsername()

      Returns:
        Returns the username.

    - #### setUsername

          public void setUsername(String username)

      Parameters:
        `username` - The username to set.

    - #### getValue

          public String getValue()

      Returns:
        Returns the value.

    - #### setValue

          public void setValue(String value)

    - #### getRef

          public String getRef()

      Returns:
        Returns the ref.

    - #### setRef

          public void setRef(String refId)

      Parameters:
        `refId` - The ref to set.

    - #### getJMXConnection

          protected MBeanServerConnection getJMXConnection()
                                                    throws MalformedURLException,
                                                           IOException

      Get JMXConnection (default look at jmx.server project reference from jmxOpen Task).
      Returns:
        active JMXConnection
      Throws:
        `MalformedURLException` - Invalid URL for JMX server
        `IOException` - Connection error

    - #### accessJMXValue

          protected String accessJMXValue()

      Get value from MBeans attribute.
      Returns:
        The value

Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.