public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
objects.add(obj2); Host host = new Host(); host.setName("myHost"); host.setService(objects); try {
public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
private Host prepareVirtualHost(Tomcat tomcat, List<String> virtualHosts) { // assume that the first virtual-host will be the default; additional virtual-hosts will be aliases String hostName = virtualHosts.get(0); Host host; Engine engine = tomcat.getEngine(); org.apache.catalina.Container childContainer = engine.findChild(hostName); if (childContainer instanceof Host) { host = (Host) childContainer; } else { host = new StandardHost(); host.setName(hostName); engine.addChild(host); } virtualHosts.stream() .filter(virtualHost -> virtualHost != hostName) .forEach(virtualHost -> host.addAlias(virtualHost)); return host; }
public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
public Host getHost() { if (host == null) { host = new StandardHost(); host.setName(hostname); getEngine().addChild( host ); } return host; }
public Host getHost() { Engine engine = getEngine(); if (engine.findChildren().length > 0) { return (Host) engine.findChildren()[0]; } Host host = new StandardHost(); host.setName(hostname); getEngine().addChild(host); return host; }
public Host getHost() { Engine engine = getEngine(); if (engine.findChildren().length > 0) { return (Host) engine.findChildren()[0]; } Host host = new StandardHost(); host.setName(hostname); getEngine().addChild(host); return host; }
host.setName(hostname); host.setAppBase(appBase.getAbsolutePath());
(org.apache.catalina.Host) getInstance(hostMetaData, "org.apache.catalina.core.StandardHost"); addLifecycleListeners(host, hostMetaData.getListeners()); host.setName(hostMetaData.getName()); engine.addChild(host);
embeddedTomcat.getHost().setName( hostName );
embeddedTomcat.getHost().setName( hostName );
host.setName( hostName );
@Before public void setupManager() { Context context = new StandardContext(); Host host = new StandardHost(); this.manager.setContext(context); context.setName("test-context-name"); context.setParent(host); host.setName("test-host-name"); }