Java Code Examples for com.sun.jmx.remote.util.EnvHelp#checkAttributes()

The following examples show how to use com.sun.jmx.remote.util.EnvHelp#checkAttributes() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RMIConnector.java    From jdk8u-dev-jdk with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 2
Source File: RMIConnector.java    From Java8CN with Apache License 2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 3
Source File: RMIConnector.java    From jdk8u-jdk with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 4
Source File: RMIConnector.java    From openjdk-8-source with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 5
Source File: RMIConnector.java    From jdk8u_jdk with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 6
Source File: RMIConnector.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 7
Source File: RMIConnector.java    From JDKSourceCode1.8 with MIT License 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 8
Source File: RMIConnector.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 9
Source File: RMIConnector.java    From dragonwell8_jdk with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 10
Source File: RMIConnector.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
private RMIConnector(RMIServer rmiServer, JMXServiceURL address,
        Map<String, ?> environment) {
    if (rmiServer == null && address == null) throw new
            IllegalArgumentException("rmiServer and jmxServiceURL both null");
    initTransients();

    this.rmiServer = rmiServer;
    this.jmxServiceURL = address;
    if (environment == null) {
        this.env = Collections.emptyMap();
    } else {
        EnvHelp.checkAttributes(environment);
        this.env = Collections.unmodifiableMap(environment);
    }
}
 
Example 11
Source File: RMIConnectorServer.java    From openjdk-8 with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 12
Source File: RMIConnectorServer.java    From JDKSourceCode1.8 with MIT License 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 13
Source File: RMIConnectorServer.java    From jdk8u60 with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 14
Source File: RMIConnectorServer.java    From openjdk-jdk8u with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 15
Source File: RMIConnectorServer.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 16
Source File: RMIConnectorServer.java    From openjdk-8-source with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 17
Source File: RMIConnectorServer.java    From openjdk-jdk9 with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 18
Source File: RMIConnectorServer.java    From jdk8u-dev-jdk with GNU General Public License v2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 19
Source File: RMIConnectorServer.java    From Java8CN with Apache License 2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}
 
Example 20
Source File: RMIConnectorServer.java    From jdk1.8-source-analysis with Apache License 2.0 4 votes vote down vote up
/**
 * <p>Returns a client stub for this connector server.  A client
 * stub is a serializable object whose {@link
 * JMXConnector#connect(Map) connect} method can be used to make
 * one new connection to this connector server.</p>
 *
 * @param env client connection parameters of the same sort that
 * could be provided to {@link JMXConnector#connect(Map)
 * JMXConnector.connect(Map)}.  Can be null, which is equivalent
 * to an empty map.
 *
 * @return a client stub that can be used to make a new connection
 * to this connector server.
 *
 * @exception UnsupportedOperationException if this connector
 * server does not support the generation of client stubs.
 *
 * @exception IllegalStateException if the JMXConnectorServer is
 * not started (see {@link #isActive()}).
 *
 * @exception IOException if a communications problem means that a
 * stub cannot be created.
 **/
public JMXConnector toJMXConnector(Map<String,?> env) throws IOException {
    // The serialized for of rmiServerImpl is automatically
    // a RMI server stub.
    if (!isActive()) throw new
        IllegalStateException("Connector is not active");

    // Merge maps
    Map<String, Object> usemap = new HashMap<String, Object>(
            (this.attributes==null)?Collections.<String, Object>emptyMap():
                this.attributes);

    if (env != null) {
        EnvHelp.checkAttributes(env);
        usemap.putAll(env);
    }

    usemap = EnvHelp.filterAttributes(usemap);

    final RMIServer stub=(RMIServer)rmiServerImpl.toStub();

    return new RMIConnector(stub, usemap);
}