|
using System;
using System.Collections.Generic;
using System.Text;
using NetMX.Proxy;
namespace NetMX
{
public static partial class NetMX
{
/// <summary>
/// Creates new proxy for a MBean in local or remote server.
/// </summary>
/// <typeparam name="T">Type of MBean interface.</typeparam>
/// <param name="connection">Connection to MBean server.</param>
/// <param name="objectName">ObjectName of MBean to proxy.</param>
/// <returns>A new proxy instance.</returns>
public static T NewMBeanProxy<T>(IMBeanServerConnection connection, ObjectName objectName)
{
ProxyInvocationHandler handler = new ProxyInvocationHandler(connection, objectName);
return (T)ProxyFactory.CreateProxy(typeof(T), handler);
}
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.