Documentation ¶
Index ¶
- func Bind(resource *resources.ResourceList) func(w http.ResponseWriter, r *http.Request)
- func BindCustomResource(resource *resources.ResourceList, cache *resources.Cache) func(w http.ResponseWriter, r *http.Request)
- func FilterItemsByFields(items []unstructured.Unstructured, fieldPaths []string) []map[string]interface{}
- func Handler(w http.ResponseWriter, r *http.Request, ...)
- func WriteHeaders(w http.ResponseWriter)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Bind ¶
func Bind(resource *resources.ResourceList) func(w http.ResponseWriter, r *http.Request)
func BindCustomResource ¶
func BindCustomResource(resource *resources.ResourceList, cache *resources.Cache) func(w http.ResponseWriter, r *http.Request)
func FilterItemsByFields ¶ added in v0.9.0
func FilterItemsByFields(items []unstructured.Unstructured, fieldPaths []string) []map[string]interface{}
FilterItemsByFields filters the given items based on the specified field paths - It takes a slice of unstructured.Unstructured and a slice of field paths. - It returns a slice of maps, each representing a filtered item.
func Handler ¶
func Handler(w http.ResponseWriter, r *http.Request, getData func(string, string) []unstructured.Unstructured, changes <-chan struct{}, fieldsList []string, crdExists func() bool)
Handler is a generic SSE handler that sends data to the client
func WriteHeaders ¶
func WriteHeaders(w http.ResponseWriter)
WriteHeaders sets the headers for an SSE connection
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.