Skip to content

Latest commit

 

History

History

setter

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Setter

Package setter allows for write operations on fields of any struct.

person := struct {
    name string
}{}
_ = setter.Set(&person, "name", "Mary", false)
fmt.Println(person.name)
// Output: Mary

See examples.