Moved configuration to Quadwriter and added to config file

This commit is contained in:
l.albertalli 2015-02-09 18:43:26 -08:00
parent 68cd44b986
commit 6134bc8bdd
7 changed files with 48 additions and 33 deletions

View file

@ -24,6 +24,7 @@ package graph
import (
"errors"
"time"
"flag"
"github.com/google/cayley/quad"
)
@ -58,6 +59,11 @@ var (
ErrQuadNotExist = errors.New("quad does not exist")
)
var (
IgnoreDup = flag.Bool("ignoredup", false, "Don't stop loading on duplicated key on add")
IgnoreMissing = flag.Bool("ignoremissing", false, "Don't stop loading on missing key on delete")
)
type QuadWriter interface {
// Add a quad to the store.
AddQuad(quad.Quad) error