sources

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2016 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Core = `` /* 1041-byte string literal not displayed */
View Source
var Logic = `
package logic

import (
	"fmt"
	"math/rand"
	"net/http"
	"time"
)

var Info string = ` + "`" + `
{
	"name": "hello_effe",
	"version": "0.1",
	"doc" : "Getting start with effe"
}
` + "`" + `

type Context struct {
	value int64
}

func Init() {
	rand.Seed(time.Now().UTC().UnixNano())
}

func Start() Context {
	fmt.Println("Start new Context") 
	return Context{1 + rand.Int63n(2)}
}

func Run(ctx Context, w http.ResponseWriter, r *http.Request) error {
	fmt.Fprintf(w, "Hello from Effe:  %d\n", ctx.value)
	return nil
}

func Stop(ctx Context) { return }
`

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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