rpn

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2017 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Overview

Package rpn defines a kind of condition pattern just like normal if condition in Golang, which trasfer string pattern to normal if condition. e.g. "N>0.3&&N<=0.8". Bit operation is not supported.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReversePolishNotation

type ReversePolishNotation struct {
	// contains filtered or unexported fields
}

ReversePolishNotation represents a reverse polish notation.

func New

New creates a new ReversePolishNotation with a string pattern.

func (*ReversePolishNotation) Calculate

func (rpn *ReversePolishNotation) Calculate(value float64) (bool, error)

Calculate calculate condition result with float64.

Jump to

Keyboard shortcuts

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