godock: github.com/sqp/godock/libs/text/strhelp Index | Files

package strhelp

import "github.com/sqp/godock/libs/text/strhelp"

Package strhelp provides helpers to work with strings.


Package Files


func Bracket Uses

func Bracket(msg string) string

Bracket returns brackets added around text if any.

func First Uses

func First(list ...string) string

First returns the first non empty string found.

func Parenthesis Uses

func Parenthesis(msg string) string

Parenthesis returns parenthesis added around text if any.

func Separator Uses

func Separator(prev, sep, after string) string

Separator returns the string with separator if needed.

func YesNo Uses

func YesNo(b bool) string

YesNo returns Yes or No according to the bool value.

Package strhelp is imported by 5 packages. Updated 2017-10-01. Refresh now. Tools for package owners.