node.h
External header file
nodeInt.h
Internal header file
node.c
The main routines of the node package.
nodePkg.c
Initialization and deinitialization for package node and subpackages
nodePrint.c
Pretty prints a node struct.
nodeWffPrint.c
Pretty printing of formulas represented using node struct.

node.h

External header file

By: Marco Roveri

()
Casts the given pointer to a node_ptr
()
Casts the given node_ptr to an int
()
Casts the given int to a node_ptr

nodeInt.h

Internal header file

By: Marco Roveri


node.c

The main routines of the node package.

By: Marco Roveri

This file provides an abstract data type a la s-expression in LISP.

()
Quits the node manager.
free_node()
Free a node of the node manager.
new_node()
Creates a new node.
new_lined_node()
Creates a new node.
find_node()
Creates a new node.
find_atom()
Search the node hash for a given node.
cons()
Conses two nodes.
car()
Returns the left branch of a node.
cdr()
Returns the right branch of a node.
setcar()
Replaces the car of X with Y
setcdr()
Replaces the cdr of X with Y
node_set_type()
Replaces the type of the node
node_is_failure()
Returns 0 if given node is not a FAILURE node
node_is_leaf()
Tells if the given node is a numeric/boolean leaf
new_list()
Returns a new empty list
copy_list()
Returns a copy of a list
free_list()
Frees all the elements of the list.
is_list_empty()
Returns 1 is the list is empty, 0 otherwise
in_list()
Checks list R to see if it contains the element N.
llength()
Returns the length of list r.
append()
Appends two lists and returns the result.
append_ns()
Appends two lists and returns the result.
reverse()
Reverse a list.
reverse_ns()
reverses the list with no side-effect
last()
Returns the last cons in X.
map()
Applies FUN to successive cars of LISTs and returns the results as a list.
map2()
Applies FUN to successive cars of LISTs and returns the results as a list. Lists l1 and l2 are traversed in parallel.
odd_elements()
Extracts odd elements of list L.
even_elements()
Extracts even elements of list L.
walk()
Applies FUN to successive cars of LISTs.
node_subtract()
Deletes from list set2 the elements of list set1.
swap_nodes()
Swaps two nodes.
()
Traverses the tree, and returns a possibly new tree that is a normalized copy of the first. Use for constant-time comparison of two trees
node_normalize_list()
Does the same thing as node_normalize but do it more efficiently if sexp is a list
node_init()
Initializes the node manager.
node_quit()
De-initializes the node manager.
()
Inserts a node in the node hash.
node_hash_fun()
Hash function for nodes.
node_eq_fun()
Equality function for node hash.
node_cmp_fun()
Comparison function for node sorted insertion. Returns is < 0 if node1 < node2, 0 if node1 == node2, and > 0 if node1 > node2
node_alloc()
Allocates NODE_MEM_CHUNK records and stores them in the free list of the node manager.
_node_realloc_nodelist()
Reallocation of the hash
()
Comparison function used for profiling

nodePkg.c

Initialization and deinitialization for package node and subpackages

By: Roberto Cavada

Initialization and deinitialization for package node and subpackages

node_pkg_init()
Initializes the node package
node_pkg_quit()
Deinitializes the packages, finalizing all internal structures
node_pkg_get_global_master_normalizer()
Returns the global master normalizer
node_pkg_get_global_master_wff_printer()
Returns the global master wff printer
node_pkg_get_global_master_sexp_printer()
Returns the global master wff printer
node_pkg_get_indenting_master_wff_printer()
Returns the indenting master wff printer

nodePrint.c

Pretty prints a node struct.

By: Marco Roveri

This function pretty print a node struct, in a way similar to a s-expression in LISP.

print_array_type()
Print an ARRAY_TYPE structure in smv
print_array_type_rec()
Private function of print_array_type

nodeWffPrint.c

Pretty printing of formulas represented using node struct.

By: Marco Roveri

This file conatins the code to perform pretty printing of a formula represented with a node struct.

See Alsonode.c

print_node()
Pretty print a formula on a file
sprint_node()
Pretty print a formula into a string
print_node_indent_at()
Pretty print a formula on a file (indenting)
sprint_node_indent_at()
Pretty print a formula into a string (indenting)
print_node_indent()
Pretty print a formula on a file (indenting)
sprint_node_indent()
Pretty print a formula into a string (indenting)

Last updated on 2012/11/18 14h:16