/// <summary> /// get the service value for a specific service by name or null if no such /// Service exists. /// /// </summary> public virtual S getServiceValue <S>(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType type, string localName) { string globalName = composeLocalName(type, localName); ObjectName serviceName = getObjectName(globalName); return(getServiceValue(serviceName)); }
public virtual void startService <S>(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType serviceType, string localName, PlatformService <S> service) { lock (this) { string serviceName = composeLocalName(serviceType, localName); startService(serviceName, service); } }
public virtual void stopService(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType serviceType, string localName) { lock (this) { string globalName = composeLocalName(serviceType, localName); stopService(globalName); } }
/// <returns> the service names ( <seealso cref="ObjectName"/> ) for all services for a given type </returns> public virtual ISet <string> getServiceNames(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType type) { string typeName = composeLocalName(type, "*"); ObjectName typeObjectName = getObjectName(typeName); ISet <ObjectName> resultNames = getmBeanServer().queryNames(typeObjectName, null); ISet <string> result = new HashSet <string>(); foreach (ObjectName objectName in resultNames) { result.Add(objectName.ToString()); } return(result); }
/// <returns> all services for a specific <seealso cref="ServiceType"/> </returns> //JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @SuppressWarnings("unchecked") public <S> java.util.List<org.camunda.bpm.container.impl.spi.PlatformService<S>> getServicesByType(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType type) public virtual IList <PlatformService <S> > getServicesByType <S>(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType type) { // query the MBeanServer for all services of the given type ISet <string> serviceNames = getServiceNames(type); IList <PlatformService <S> > res = new List <PlatformService <S> >(); foreach (string serviceName in serviceNames) { res.Add((PlatformService <S>)servicesByName[getObjectName(serviceName)]); } return(res); }
public static string composeLocalName(org.camunda.bpm.container.impl.spi.PlatformServiceContainer_ServiceType type, string localName) { return(type.TypeName + ":type=" + localName); }