urls

package
v0.0.0-...-7e42488 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func File

func File(resource string) (string, error)

File gets the provided resource to a temporary file on the local machine and returns the path.

func ReadFile

func ReadFile(resource string) ([]byte, error)

ReadFile returns the content of the provided resource as an array of bytes or returns an error.

func WithFile

func WithFile(resource string, callback func(path string) (interface{}, error)) (interface{}, error)

WithFile gets the provided resource to a temporary file on the local machine, invokes the callback with the path and returns the result. Note that the temporary file is deleted when the callback returns.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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