strutil

package
v0.1.361 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2024 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ISSNPattern = regexp.MustCompile(`[0-9]{4,4}-[0-9]{3,3}[0-9X]`)

ISSNPattern is a regular expression matching standard ISSN.

Functions

func Intersection added in v0.1.343

func Intersection(a, b []string) []string

Intersection returns strings contained in boths given slices.

func Overlap added in v0.1.343

func Overlap(a, b []string) bool

func RemoveEach added in v0.1.343

func RemoveEach(ss []string, drop []string) (result []string)

RemoveEach returns a new slice with elements not contained in a drop list.

func StringSliceContains added in v0.1.343

func StringSliceContains(ss []string, s string) bool

StringSliceContains returns true, if a given string is contained in a slice.

func Truncate

func Truncate(s string, length int) string

Truncate truncates a string.

func UnescapeTrim

func UnescapeTrim(s string) string

UnescapeTrim unescapes HTML character references and trims the space of a given string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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