Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.red5.server.tomcat
Class TomcatLoader

    java.lang.Object
      org.red5.server.LoaderBase
          org.red5.server.tomcat.TomcatLoader

All Implemented Interfaces:
  LoaderMBean, ApplicationContextAware

Direct Known Subclasses:
  RTMPTLoader, TomcatVHostLoader

    public class TomcatLoader

extends LoaderBase
implements ApplicationContextAware, LoaderMBean

Red5 loader for Tomcat.

Author:
  Paul Gregoire (mondain@gmail.com)

Nested Class Summary
`protected static class` | `TomcatLoader.DirectoryFilter` Filters directory content

Field Summary
`protected InetAddress` | `address` IP Address to bind to.
`protected Map<String,String>` | `connectionProperties` Additional connection properties to be set at init.
`protected Connector` | `connector` Tomcat connector.
`protected List<Connector>` | `connectors` Connectors
`static String` | `defaultParentContextKey`
`static String` | `defaultSpringConfigLocation`
`protected static Embedded` | `embedded` Embedded Tomcat service (like Catalina).
`protected static Engine` | `engine` Tomcat engine.
`protected Host` | `host` Base container host.
`protected List<Host>` | `hosts` Hosts
`protected Realm` | `realm` Tomcat realm.
`String` | `serviceEngineName` Common name for the Service and Engine components.
`protected List<Valve>` | `valves` Valves

Fields inherited from class org.red5.server.LoaderBase
`applicationContext, loader, red5AppCtx, webappFolder`

Constructor Summary
`TomcatLoader()`

Method Summary
`Context` | `addContext(String path, String docBase)` Add context for path and docbase to current host.
`Context` | `addContext(String path, String docBase, Host host)` Add context for path and docbase to a host.
`Host` | `getBaseHost()` Get base host.
`Connector` | `getConnector()` Return connector.
`Embedded` | `getEmbedded()` Getter for embedded object.
`Engine` | `getEngine()` Return Tomcat engine.
`Host` | `getHost()` Get the host.
`protected String` | `getHostId()` Returns a semi-unique id for this host based on its host values
`Realm` | `getRealm()` Getter for realm.
`void` | `init()` Initialization.
`void` | `registerJMX()`
`void` | `removeContext(String path)` Remove context from the current host.
`void` | `setAddress(InetSocketAddress address)` The address to which we will bind.
`void` | `setBaseHost(Host baseHost)` Set base host.
`void` | `setConnectionProperties(Map<String,String> props)` Set connection properties for the connector
`void` | `setConnector(Connector connector)` Set connector.
`void` | `setConnectors(List<Connector> connectors)` Set additional connectors.
`void` | `setContexts(Map<String,String> contexts)` Set additional contexts.
`void` | `setEmbedded(Embedded embedded)` Setter for embedded object.
`void` | `setHost(Host host)` Set the host.
`void` | `setHosts(List<Host> hosts)` Set additional hosts.
`void` | `setRealm(Realm realm)` Setter for realm.
`void` | `setValves(List<Valve> valves)` Set additional valves.
`void` | `shutdown()` Shut server down.
`boolean` | `startWebApplication(String applicationName)` Starts a web application and its red5 (spring) component.

Methods inherited from class org.red5.server.LoaderBase
`getApplicationContext, getApplicationLoader, getRed5ApplicationContext, getRed5ApplicationContexts, removeRed5ApplicationContext, setApplicationContext, setApplicationLoader, setRed5ApplicationContext, setWebappFolder`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.springframework.context.ApplicationContextAware
`setApplicationContext`

Field Detail

### defaultSpringConfigLocation

    public static final String defaultSpringConfigLocation

See Also:
  Constant Field Values

### defaultParentContextKey

    public static final String defaultParentContextKey

See Also:
  Constant Field Values

### serviceEngineName

    public String serviceEngineName

  Common name for the Service and Engine components.

### host

    protected Host host

  Base container host.

### connector

    protected Connector connector

  Tomcat connector.

### embedded

    protected static Embedded embedded

  Embedded Tomcat service (like Catalina).

### engine

    protected static Engine engine

  Tomcat engine.

### realm

    protected Realm realm

  Tomcat realm.

### hosts

    protected List<Host> hosts

  Hosts

### connectors

    protected List<Connector> connectors

  Connectors

### valves

    protected List<Valve> valves

  Valves

### connectionProperties

    protected Map<String,String> connectionProperties

  Additional connection properties to be set at init.

### address

    protected InetAddress address

  IP Address to bind to.

Constructor Detail

### TomcatLoader

    public TomcatLoader()

Method Detail

### addContext

    public Context addContext(String path,
                              String docBase)

  Add context for path and docbase to current host.

  Parameters:
    `path` - Path
    `docBase` - Document base
  Returns:
    Catalina context (that is, web application)

### addContext

    public Context addContext(String path,
                              String docBase,
                              Host host)

  Add context for path and docbase to a host.

  Parameters:
    `path` - Path
    `docBase` - Document base
    `host` - Host to add context to
  Returns:
    Catalina context (that is, web application)

### removeContext

    public void removeContext(String path)

  Remove context from the current host.

  Specified by:
    `removeContext` in interface `LoaderMBean`
  Overrides:
    `removeContext` in class `LoaderBase`
  Parameters:
    `path` - Path

### getBaseHost

    public Host getBaseHost()

  Get base host.

  Returns:
    Base host

### getConnector

    public Connector getConnector()

  Return connector.

  Returns:
    Connector

### getEmbedded

    public Embedded getEmbedded()

  Getter for embedded object.

  Returns:
    Embedded object

### getEngine

    public Engine getEngine()

  Return Tomcat engine.

  Returns:
    Tomcat engine

### getRealm

    public Realm getRealm()

  Getter for realm.

  Returns:
    Realm

### init

    public void init()

  Initialization.

  Specified by:
    `init` in interface `LoaderMBean`

### startWebApplication

    public boolean startWebApplication(String applicationName)

  Starts a web application and its red5 (spring) component. This is basically a stripped down version of init().

  Specified by:
    `startWebApplication` in interface `LoaderMBean`
  Returns:
    true on success

### setAddress

    public void setAddress(InetSocketAddress address)

  The address to which we will bind.

  Parameters:
    `address` -

### setBaseHost

    public void setBaseHost(Host baseHost)

  Set base host.

  Parameters:
    `baseHost` - Base host

### setConnector

    public void setConnector(Connector connector)

  Set connector.

  Parameters:
    `connector` - Connector

### setConnectors

    public void setConnectors(List<Connector> connectors)

  Set additional connectors.

  Parameters:
    `connectors` - Additional connectors

### setContexts

    public void setContexts(Map<String,String> contexts)

  Set additional contexts.

  Parameters:
    `contexts` - Map of contexts

### setEmbedded

    public void setEmbedded(Embedded embedded)

  Setter for embedded object.

  Parameters:
    `embedded` - Embedded object

### getHost

    public Host getHost()

  Get the host.

  Returns:
    host

### setHost

    public void setHost(Host host)

  Set the host.

  Parameters:
    `host` - host

### setHosts

    public void setHosts(List<Host> hosts)

  Set additional hosts.

  Parameters:
    `hosts` - List of hosts added to engine

### setRealm

    public void setRealm(Realm realm)

  Setter for realm.

  Parameters:
    `realm` - Realm

### setValves

    public void setValves(List<Valve> valves)

  Set additional valves.

  Parameters:
    `valves` - List of valves

### setConnectionProperties

    public void setConnectionProperties(Map<String,String> props)

  Set connection properties for the connector

  Parameters:
    `props` - additional properties to set

### getHostId

    protected String getHostId()

  Returns a semi-unique id for this host based on its host values

  Returns:
    host id

### registerJMX

    public void registerJMX()

### shutdown

    public void shutdown()

  Shut server down.

  Specified by:
    `shutdown` in interface `LoaderMBean`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2010 The Red5 Project