Пример #1
0
// --------------------- Implementation ---------------------
func plural(input string) (result string) {
	result = inflect.Pluralize(input)
	if result == input {
		result += "s"
	}
	return
}
Пример #2
0
func (m model) Plural() (result string) {
	result = inflect.Pluralize(m.Name)
	if result == m.Name {
		result += "s"
	}
	return
}
Пример #3
0
func (t *Type) Plural() (result string) {
	result = inflect.Pluralize(t.Name)
	if result == t.Name {
		result += "s"
	}
	return
}