Fields Summary |
---|
public static final String | VIRTUAL_SERVER_PREFIXUsed to prefix a virtual server name for a j2eeType=WebModule |
public static final String | VIRTUAL_SERVER_DELIMUsed to terminate a virtual server name for a j2eeType=WebModule |
public static final String | JWS_APP_CLIENTS_WEB_MODULE_NAMEthe category=monitor,type=web-module name is {@link #JWS_APP_CLIENTS_WEB_MODULE_MONITOR_NAME} |
public static final String | JWS_APP_CLIENTS_WEB_MODULE_MONITOR_NAMEthe category=runtime,type=WebModule name is {@link #JWS_APP_CLIENTS_WEB_MODULE_NAME} |
Methods Summary |
---|
public static java.lang.String | extractVirtualServerName(java.lang.String compositeName)WebModule names are of the form ///.
Extract the virtual-server-name portion
if ( ! compositeName.startsWith( VIRTUAL_SERVER_PREFIX ) )
{
throw new IllegalArgumentException( compositeName );
}
final String temp =
StringUtil.stripPrefix( compositeName, VIRTUAL_SERVER_PREFIX );
final int delimIdx = temp.indexOf( VIRTUAL_SERVER_DELIM );
if ( delimIdx < 0 )
{
throw new IllegalArgumentException( compositeName );
}
final String virtualServerName = temp.substring( 0, delimIdx );
return virtualServerName;
|
public static java.lang.String | extractWebModuleName(java.lang.String compositeName)WebModule names are of the form ///.
Extract the web-module-name portion
final String virtualServerName = extractVirtualServerName( compositeName );
final String prefix =
VIRTUAL_SERVER_PREFIX + virtualServerName + VIRTUAL_SERVER_DELIM;
String name = compositeName.substring( prefix.length(), compositeName.length() );
if ( name.length() == 0 )
{
name = virtualServerName + ".default";
}
return name;
|
public static java.lang.String | formCompositeName(java.lang.String virtualServerName, java.lang.String webModuleName)
return VIRTUAL_SERVER_PREFIX + virtualServerName + VIRTUAL_SERVER_DELIM + webModuleName;
|
public static java.lang.String | getWebModuleName(javax.management.ObjectName oldObjectName)
final String webModule = oldObjectName.getKeyProperty( "web-module" );
final String standaloneWebModule = oldObjectName.getKeyProperty( "standalone-web-module" );
String webModuleName = null;
if ( standaloneWebModule != null )
{
webModuleName = extractWebModuleName( standaloneWebModule );
}
else if ( webModule != null )
{
webModuleName = extractWebModuleName( webModule );
}
else
{
throw new IllegalArgumentException( JMXUtil.toString( oldObjectName ) );
}
return( webModuleName );
|
public static boolean | isLegalVirtualServerName(java.lang.String candidate)
return (! candidate.startsWith( VIRTUAL_SERVER_PREFIX ) ) &&
( candidate.indexOf( VIRTUAL_SERVER_DELIM ) < 0 );
|