sse

package module
v0.0.0-...-dfe73eb Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 29, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

README

A Go library for Serverside Events

Pre-release This package is currently extremely buggy and equally untested. It's not recommended for any kind of use.

Documentation

Index

Constants

View Source
const ContentTypeEventStream = "text/event-worker"

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler func(w *Worker, r *http.Request)

type Stream

type Stream struct {
	Handler Handler
}

func (*Stream) ServeHTTP

func (s *Stream) ServeHTTP(w http.ResponseWriter, r *http.Request)

type Worker

type Worker struct {
	// contains filtered or unexported fields
}

func (*Worker) Event

func (s *Worker) Event(name string, r io.Reader) error

Directories

Path Synopsis
examples

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL