Documentation ¶
Index ¶
- func Abs(v int16) int16
- func Contains(vs []int16, v int16) bool
- func FromString(s string) (int16, error)
- func FromStringOrDefault(s string, defaultVal int16) int16
- func Int16OrDefault(v *int16, defaultVal int16) *int16
- func Max(v int16, vs ...int16) int16
- func Min(v int16, vs ...int16) int16
- func Pointer(v int16) *int16
- func Random() int16
- func RandomN(n int16) int16
- func Sort(vs []int16) []int16
- func Unique(vs []int16) []int16
- type Int16Slice
- type Set
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Abs ¶
Abs returns the absolute value of v. NOTE: this method is deprecated. Use helpy.Abs instead.
func Contains ¶
Contains returns true if vs contains v. NOTE: this function is deprecated. Use slicey.Contains instead.
func FromStringOrDefault ¶ added in v0.1.0
FromStringOrDefault parses s and returns a int16.
func Int16OrDefault ¶
Int16OrDefault returns int16 if it is not nil, and a pointer to defaultVal otherwise. NOTE: this method is deprecated. Use helpy.DerefOrValue instead.
func Max ¶
Max returns the maximum value from v and vs. NOTE: this method is deprecated. Use helpy.Max instead.
func Min ¶
Min returns the minimum value from v and vs. NOTE: this method is deprecated. Use helpy.Min instead.
func Pointer ¶
Pointer returns a pointer to the given int16. NOTE: this method is deprecated. Use helpy.Pointer instead.
Types ¶
type Int16Slice ¶
type Int16Slice []int16
func (Int16Slice) Len ¶
func (p Int16Slice) Len() int
func (Int16Slice) Less ¶
func (p Int16Slice) Less(i, j int) bool
func (Int16Slice) Swap ¶
func (p Int16Slice) Swap(i, j int)
type Set ¶
type Set helpy.Set[int16]
NOTE: this type is deprecated. Use helpy.Set instead
func MakeSet ¶
MakeSet returns a lookup map for int16 NOTE: this function is deprecated. Use helpy.MakeSet instead.