solver

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package solver implements a general-purpose solver for boolean constraint satisfiability problems.

Index

Constants

This section is empty.

Variables

View Source
var ErrIncomplete = errors.New("cancelled before a solution could be found")

Functions

This section is empty.

Types

type DefaultTracer

type DefaultTracer struct{}

func (DefaultTracer) Trace

type DuplicateIdentifier

type DuplicateIdentifier deppy.Identifier

func (DuplicateIdentifier) Error

func (e DuplicateIdentifier) Error() string

type LoggingTracer

type LoggingTracer struct {
	Writer io.Writer
}

func (LoggingTracer) Trace

func (t LoggingTracer) Trace(p deppy.SearchPosition)

type Option

type Option func(s *solver) error

func WithInput

func WithInput(input []deppy.Variable) Option

func WithTracer

func WithTracer(t deppy.Tracer) Option

type Solver

type Solver interface {
	Solve() ([]deppy.Variable, error)
}

func NewSolver

func NewSolver(options ...Option) (Solver, error)

Jump to

Keyboard shortcuts

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