Skip to content

Commit 17fb876

Browse files
committed
update code docs
1 parent 7861729 commit 17fb876

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

reader.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,12 @@ type (
2828
// for _, field := range reader.GetAllFields() { ...
2929
//
3030
GetAllFields() []Field
31-
31+
// ToStruct maps all read values to passed instance of struct, by setting
32+
// all its values for fields with same names.
33+
// It returns an error if argument is not a pointer to a struct.
34+
//
35+
// err := reader.ToStruct(&instance)
36+
//
3237
ToStruct(value interface{}) error
3338
}
3439

0 commit comments

Comments
 (0)