把red5安装目录lib包中的所有jar包 拷贝到我们的RED5源码结构中的LIB里面
然后在ECLIPSE把这个LIB中的所有JAR加入到build path中.
记住还加入junit.jar(myeclipse自带)
以及GroboUtils .jar http://red5.googlecode.com/svn/repository/GroboUtils-5-core.jar
spring-test2.5.5.jar http://red5.googlecode.com/svn/repository/spring/spring-test-2.5.5.jar
spring-croe.jar
有可能还有groovy的zip http://dist.groovy.codehaus.org/distributions/groovy-binary-1.7.5.zip
Scope
The GlobalScope is the parent of all WebScopes.
If the scope is a leaf node, it is called a BasicScope
There're two pre-defined BasicScopes in Red5, SharedObject Scope and BroadcastStream Scope
system properties
These system properties are available to you within Red5
- red5.root - This is the location from which Red5 was launched or is installed
- red5.lib_root - The common library directory
- red5.config_root - The configuration directory
- red5.plugins_root - The plug-ins directory
- red5.webapp.root - The web applications directory
In code you may access them like so:
String prop = System.getProperty("red5.root");
拿到ApplicationAdpter
IContext context = scope.getContext(); ApplicationContext appCtx = context.getApplicationContext(); Application app = (Application) appCtx.getBean("web.handler");或者ApplicationContext appCtx = (ApplicationContext) getServletContext().getAttribute(WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE);或者this.application = (Application) appCtx.getBean("web.handler");