libcompose: github.com/docker/libcompose/project/events Index | Files

package events

import "github.com/docker/libcompose/project/events"

Package events holds event structures, methods and functions.

Index

Package Files

events.go

Constants

const (
    NoEvent = EventType(iota)

    ContainerCreated = EventType(iota)
    ContainerStarted = EventType(iota)

    ServiceAdd          = EventType(iota)
    ServiceUpStart      = EventType(iota)
    ServiceUpIgnored    = EventType(iota)
    ServiceUp           = EventType(iota)
    ServiceCreateStart  = EventType(iota)
    ServiceCreate       = EventType(iota)
    ServiceDeleteStart  = EventType(iota)
    ServiceDelete       = EventType(iota)
    ServiceDownStart    = EventType(iota)
    ServiceDown         = EventType(iota)
    ServiceRestartStart = EventType(iota)
    ServiceRestart      = EventType(iota)
    ServicePullStart    = EventType(iota)
    ServicePull         = EventType(iota)
    ServiceKillStart    = EventType(iota)
    ServiceKill         = EventType(iota)
    ServiceStartStart   = EventType(iota)
    ServiceStart        = EventType(iota)
    ServiceBuildStart   = EventType(iota)
    ServiceBuild        = EventType(iota)
    ServicePauseStart   = EventType(iota)
    ServicePause        = EventType(iota)
    ServiceUnpauseStart = EventType(iota)
    ServiceUnpause      = EventType(iota)
    ServiceStopStart    = EventType(iota)
    ServiceStop         = EventType(iota)
    ServiceRunStart     = EventType(iota)
    ServiceRun          = EventType(iota)

    VolumeAdd  = EventType(iota)
    NetworkAdd = EventType(iota)

    ProjectDownStart     = EventType(iota)
    ProjectDownDone      = EventType(iota)
    ProjectCreateStart   = EventType(iota)
    ProjectCreateDone    = EventType(iota)
    ProjectUpStart       = EventType(iota)
    ProjectUpDone        = EventType(iota)
    ProjectDeleteStart   = EventType(iota)
    ProjectDeleteDone    = EventType(iota)
    ProjectRestartStart  = EventType(iota)
    ProjectRestartDone   = EventType(iota)
    ProjectReload        = EventType(iota)
    ProjectReloadTrigger = EventType(iota)
    ProjectKillStart     = EventType(iota)
    ProjectKillDone      = EventType(iota)
    ProjectStartStart    = EventType(iota)
    ProjectStartDone     = EventType(iota)
    ProjectBuildStart    = EventType(iota)
    ProjectBuildDone     = EventType(iota)
    ProjectPauseStart    = EventType(iota)
    ProjectPauseDone     = EventType(iota)
    ProjectUnpauseStart  = EventType(iota)
    ProjectUnpauseDone   = EventType(iota)
    ProjectStopStart     = EventType(iota)
    ProjectStopDone      = EventType(iota)
)

Definitions of libcompose events

type ContainerEvent Uses

type ContainerEvent struct {
    Service    string            `json:"service"`
    Event      string            `json:"event"`
    ID         string            `json:"id"`
    Time       time.Time         `json:"time"`
    Attributes map[string]string `json:"attributes"`
    Type       string            `json:"type"`
}

ContainerEvent holds attributes of container events.

type Emitter Uses

type Emitter interface {
    AddListener(c chan<- Event)
}

Emitter defines the methods an event emitter should have.

type Event Uses

type Event struct {
    EventType   EventType
    ServiceName string
    Data        map[string]string
}

Event holds project-wide event informations.

type EventType Uses

type EventType int

EventType defines a type of libcompose event.

func (EventType) String Uses

func (e EventType) String() string

type Notifier Uses

type Notifier interface {
    Notify(eventType EventType, serviceName string, data map[string]string)
}

Notifier defines the methods an event notifier should have.

Package events imports 2 packages (graph) and is imported by 29 packages. Updated 2016-07-19. Refresh now. Tools for package owners.