provider

package
v0.0.0-...-c1fcc63 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewResourceLister

func NewResourceLister(provider EventsProvider) handlers.APIResourceLister

NewResourceLister creates a new APIResourceLister for provided EventsProvider

Types

type EventInfo

type EventInfo struct {
	// GroupResource is the group of the resources
	GroupResource schema.GroupResource
	// Namespaced will be true if the event will be namespaced
	Namespaced bool
	// Event will contain the name of the event
	Event string
}

EventInfo contains info relevant for an Event

type EventsProvider

type EventsProvider interface {
	// READ
	GetNamespacedEventsByName(namespace, eventName string) (*api.Event, error)
	ListAllEventsByNamespace(namespace string) (*api.EventList, error)
	ListAllEvents() (*api.EventList, error)

	// WRITE
	CreateNewEvent(namespace string) (*api.Event, error)
}

EventsProvider is an interface that contains the methods that will provide info for the given events

Jump to

Keyboard shortcuts

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