github.com/niedbalski/juju@v0.0.0-20190215020005-8ff100488e47/core/watcher/offerstatus.go (about)

     1  // Copyright 2017 Canonical Ltd.
     2  // Licensed under the AGPLv3, see LICENCE file for details.
     3  
     4  package watcher
     5  
     6  import (
     7  	"github.com/juju/juju/core/status"
     8  )
     9  
    10  // OfferStatusChange describes changes to some offer.
    11  type OfferStatusChange struct {
    12  	// Name is the name of the offer.
    13  	Name string
    14  
    15  	// Status is the status of the offer.
    16  	Status status.StatusInfo
    17  }
    18  
    19  // OfferStatusChannel is a channel used to notify of changes to
    20  // an offer's status.
    21  type OfferStatusChannel <-chan []OfferStatusChange
    22  
    23  // OfferStatusWatcher conveniently ties an OfferStatusChannel to the
    24  // worker.Worker that represents its validity.
    25  type OfferStatusWatcher interface {
    26  	CoreWatcher
    27  	Changes() OfferStatusChannel
    28  }