mirror of
https://github.com/NohamR/papeer.git
synced 2026-05-25 12:27:20 +00:00
first commit
This commit is contained in:
23
book/chapter.go
Normal file
23
book/chapter.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package book
|
||||
|
||||
type chapter struct {
|
||||
name string
|
||||
author string
|
||||
content string
|
||||
}
|
||||
|
||||
func NewChapter(name, author, content string) chapter {
|
||||
return chapter{name, author, content}
|
||||
}
|
||||
|
||||
func (c chapter) Name() string {
|
||||
return c.name
|
||||
}
|
||||
|
||||
func (c chapter) Author() string {
|
||||
return c.author
|
||||
}
|
||||
|
||||
func (c chapter) Content() string {
|
||||
return c.content
|
||||
}
|
||||
Reference in New Issue
Block a user