pongo2

package
v2.0.0+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2019 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Copyright 2016 Wenhui Shen <www.webx.top>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(templateDir string, args ...logger.Logger) driver.Driver

func Strip

func Strip(b []byte) []byte

Types

type Pongo2

type Pongo2 struct {
	Mgr driver.Manager
	// contains filtered or unexported fields
}

func (*Pongo2) ClearCache

func (a *Pongo2) ClearCache()

func (*Pongo2) Close

func (a *Pongo2) Close()

func (*Pongo2) Debug

func (self *Pongo2) Debug() bool

func (*Pongo2) Fetch

func (a *Pongo2) Fetch(tmpl string, data interface{}, funcMap map[string]interface{}) string

func (*Pongo2) Init

func (a *Pongo2) Init()

func (*Pongo2) Logger

func (self *Pongo2) Logger() logger.Logger

func (*Pongo2) Manager

func (a *Pongo2) Manager() driver.Manager

func (*Pongo2) MonitorEvent

func (a *Pongo2) MonitorEvent(fn func(string))

func (*Pongo2) RawContent

func (a *Pongo2) RawContent(tmpl string) (b []byte, e error)

func (*Pongo2) Render

func (a *Pongo2) Render(w io.Writer, tmpl string, data interface{}, c echo.Context) error

func (*Pongo2) SetContentProcessor

func (a *Pongo2) SetContentProcessor(fn func([]byte) []byte)

func (*Pongo2) SetDebug

func (self *Pongo2) SetDebug(on bool)

func (*Pongo2) SetFuncMap

func (a *Pongo2) SetFuncMap(fn func() map[string]interface{})

func (*Pongo2) SetLogger

func (self *Pongo2) SetLogger(l logger.Logger)

func (*Pongo2) SetManager

func (a *Pongo2) SetManager(mgr driver.Manager)

func (*Pongo2) SetTmplPathFixer

func (self *Pongo2) SetTmplPathFixer(fn func(string) string)

func (*Pongo2) TmplDir

func (self *Pongo2) TmplDir() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL