netcap: Index | Files

package utils

import ""


Package Files


func ClearLine Uses

func ClearLine()

ClearLine clears the current line of the terminal

func ClearScreen Uses

func ClearScreen()

ClearScreen prints ANSI escape to flush screen

func DumpProto Uses

func DumpProto(pb proto.Message)

DumpProto prints a protobuf message formatted

func GetBaseLayer Uses

func GetBaseLayer(value string) (t gopacket.LayerType)

GetBaseLayer resolves a baselayer string to the gopacket.LayerType

func GetDecodeOptions Uses

func GetDecodeOptions(value string) (o gopacket.DecodeOptions)

GetDecodeOptions resolves a decode option string to the gopacket.DecodeOptions type

func ListAllNetworkInterfaces Uses

func ListAllNetworkInterfaces()

ListAllNetworkInterfaces dumps a list of all visible network interfaces to stdout

func Pad Uses

func Pad(in interface{}, length int) string

Pad the input up to the given number of space characters

func Progress Uses

func Progress(current, total int64) string

Progress display

func StringToTime Uses

func StringToTime(val string) time.Time

StringToTime converts a seconds.micro string to a time.Time

func TimeToString Uses

func TimeToString(t time.Time) string

TimeToString converts a time.Time to seconds.micro string

func TimeToUTC Uses

func TimeToUTC(val string) string

TimeToUTC returns a time string in netcap format to a UTC string

func TrimFileExtension Uses

func TrimFileExtension(file string) string

TrimFileExtension returns the netcap file name without file extension

Package utils imports 11 packages (graph) and is imported by 23 packages. Updated 2020-08-02. Refresh now. Tools for package owners.