std

package
v0.0.0-...-21ef4fc Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: MIT Imports: 14 Imported by: 5

Documentation

Index

Constants

View Source
const (
	Reset  = "\033[0m"
	Red    = "\033[31m"
	Green  = "\033[32m"
	Yellow = "\033[33m"
	Blue   = "\033[34m"
	Purple = "\033[35m"
	Cyan   = "\033[36m"
	Gray   = "\033[37m"
	White  = "\033[97m"
)

Terminal Colours

Variables

This section is empty.

Functions

func DeepCopy

func DeepCopy(src interface{}) interface{}

DeepCopy recursively copies the given struct, slices, arrays, maps and pointers

func FlagOperationsDemo

func FlagOperationsDemo()

func HTMLTemplatesDemo

func HTMLTemplatesDemo()

func JSONOperationsDemo

func JSONOperationsDemo()

func LogOperationsDemo

func LogOperationsDemo()

func PrintC

func PrintC(color string, strs ...string) string

func PrintHeader

func PrintHeader(s string)

func ReflectionOperationsDemo

func ReflectionOperationsDemo()

func SliceOperationsDemo

func SliceOperationsDemo()

func StringConversionsDemo

func StringConversionsDemo()

*********************************************************************************************** String Conversions ***********************************************************************************************

func StringOperationsDemo

func StringOperationsDemo()

*********************************************************************************************** String Operations ***********************************************************************************************

Types

type Address

type Address struct {
	City  string
	State string
}

Address struct

type CustomFlag

type CustomFlag []string

func (*CustomFlag) Set

func (c *CustomFlag) Set(value string) error

Set parses and sets the value of the CustomFlag.

func (*CustomFlag) String

func (c *CustomFlag) String() string

String returns a string representation of the CustomFlag type.

type DeepCopyable

type DeepCopyable interface {
	DeepCopy() DeepCopyable
}

type Person

type Person struct {
	Name    string
	Age     int
	Address *Address
	Hobbies []string
}

Person struct with nested Address struct

func (*Person) DeepCopy

func (p *Person) DeepCopy() DeepCopyable

Attach

Jump to

Keyboard shortcuts

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