Documentation
¶
Index ¶
- type CachedDoc
- type CachedIndex
- type DocServer
- func (ds *DocServer) GetIndexJSONLD() ([]byte, error)
- func (ds *DocServer) HandleDoc(w http.ResponseWriter, r *http.Request, slug string)
- func (ds *DocServer) HandleDocJSONLD(w http.ResponseWriter, r *http.Request, slug string)
- func (ds *DocServer) HandleDocList(w http.ResponseWriter, r *http.Request)
- func (ds *DocServer) HandleIndexJSONLD(w http.ResponseWriter, r *http.Request)
- func (ds *DocServer) HandleRSSList(w http.ResponseWriter, r *http.Request)
- func (ds *DocServer) HandleSiteRSS(w http.ResponseWriter, r *http.Request)
- func (ds *DocServer) HandleUserRSS(w http.ResponseWriter, r *http.Request, userName string)
- type DocumentCache
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CachedIndex ¶
CachedIndex represents the cached document index
type DocServer ¶
type DocServer struct {
// contains filtered or unexported fields
}
DocServer handles markdown document requests
func NewDocServer ¶
NewDocServer creates a new document server
func (*DocServer) GetIndexJSONLD ¶
GetIndexJSONLD returns the JSON-LD index data without setting HTTP headers This is used for embedding JSON-LD in HTML pages
func (*DocServer) HandleDocJSONLD ¶
HandleDocJSONLD handles GET /posts/:slug.jsonld - return JSON-LD only
func (*DocServer) HandleDocList ¶
func (ds *DocServer) HandleDocList(w http.ResponseWriter, r *http.Request)
HandleDocList handles GET /posts - list all posts
func (*DocServer) HandleIndexJSONLD ¶
func (ds *DocServer) HandleIndexJSONLD(w http.ResponseWriter, r *http.Request)
HandleIndexJSONLD handles GET /posts/index.jsonld - return collection index
func (*DocServer) HandleRSSList ¶
func (ds *DocServer) HandleRSSList(w http.ResponseWriter, r *http.Request)
HandleRSSList handles GET /rss - return HTML page listing all available RSS feeds
func (*DocServer) HandleSiteRSS ¶
func (ds *DocServer) HandleSiteRSS(w http.ResponseWriter, r *http.Request)
HandleSiteRSS handles GET /posts.rss - return RSS feed for all blog posts
func (*DocServer) HandleUserRSS ¶
HandleUserRSS handles GET /u/{user}/posts.rss - return RSS feed for user's blog posts
type DocumentCache ¶
type DocumentCache struct {
// contains filtered or unexported fields
}
DocumentCache caches rendered documents