Class ServiceNameFactory


  • public final class ServiceNameFactory
    extends Object
    Provides a factory for creating ServiceName instances from dot-separated strings while trying to mitigate the memory overhead of having multiple copies of elements of the name that have the same simple name.
    Author:
    Brian Stansberry
    • Constructor Detail

      • ServiceNameFactory

        public ServiceNameFactory()
    • Method Detail

      • parseServiceName

        public static org.jboss.msc.service.ServiceName parseServiceName​(String toParse)
        Parses a string into a ServiceName using the same algorithm as ServiceName.parse(String) but also attempts to ensure that once parsing occurs if any other name that is equal to the parsed name or one of its ancestors has been parsed previously that that previously parsed name is used.
        Parameters:
        toParse - the string form of a service name. Cannot be null
        Returns:
        a ServiceName instance