All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.antmedia.webresource.StreamWebRoot Maven / Gradle / Ivy

Go to download

Ant Media Server supports RTMP, RTSP, MP4, HLS, WebRTC, Adaptive Streaming, etc.

There is a newer version: 2.10.0
Show newest version
package io.antmedia.webresource;

import org.apache.catalina.WebResource;
import org.apache.catalina.webresources.StandardRoot;

public class StreamWebRoot extends StandardRoot {

	
	 @Override
	 public WebResource getResource(String path) {
		 if (path.endsWith(".m3u8") || path.endsWith(".ts") || (path.endsWith(".png") && path.contains("/previews/"))) {
			 return getResourceInternal(path, true);
		 }
		 else {
			 return super.getResource(path);
		 }
		 
	 }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy