Class ContentSourcePublisher

java.lang.Object
org.eclipse.jetty.io.content.ContentSourcePublisher
All Implemented Interfaces:
Flow.Publisher<Content.Chunk>

public class ContentSourcePublisher extends Object implements Flow.Publisher<Content.Chunk>

Wraps a Content.Source as a Flow.Publisher. When content is requested via Flow.Subscription.request(long), it is read from the passed Content.Source and passed to Flow.Subscriber.onNext(Object). If no content is available, then the Content.Source.demand(Runnable) method is used to ultimately call Flow.Subscriber.onNext(Object) once content is available.