Beispiel #1
0
func NewEngine(logger utils.Logger) Engine {
	return Engine{
		ns:      memory.NewMemoryNamespace(),
		clients: memory.NewClientRegister(logger),
		logger:  logger,
	}
}
Beispiel #2
0
package protocol_test

import (
	"github.com/roncohen/faye-go/memory"
	. "github.com/roncohen/faye-go/protocol"
	"log"
	"os"
	"testing"
)

var test_ns = memory.NewMemoryNamespace()

type Logger struct {
	*log.Logger
}

func (l Logger) Debugf(format string, args ...interface{}) {
	l.Printf(format, args...)
}

func (l Logger) Errorf(format string, args ...interface{}) {
	l.Printf(format, args...)
}

func (l Logger) Infof(format string, args ...interface{}) {
	l.Printf(format, args...)
}

func (l Logger) Warnf(format string, args ...interface{}) {
	l.Printf(format, args...)
}