FastSyntaxCheck.error

FastSyntaxCheck.error(syntax)

Tell why the description is not valid for a syntax.

Parameters:

syntax (pyagrum.FastSyntax) – the syntax

Returns:

the error (empty if the description is valid for this syntax)

Return type:

str

Example

import pyagrum as gum

check = gum.checkFastSyntax("A->B")
check.error(gum.FastSyntax.DiGraph)  # valid
# ''
check.error(gum.FastSyntax.UndiGraph) != ""
# True

Class

FastSyntaxCheck