The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

WebService::UMLSKS::GetAllowablePaths - Get an allowable shortest path between the supplied terms.

SYNOPSIS

Basic Usage

use WebService::UMLSKS::GetAllowablePaths;

%subgraph = graph formed by FormGraph module;

$regex = allowable pattern regex specified by configuaration;

# $term1 and $term2 are current pair of terms

my $get_paths = WebService::UMLSKS::GetAllowablePaths->new;

my $get_path_info_result = $get_paths->get_shortest_path_info( \%subgraph, $term1, $term2,$verbose, $regex );

# $get_path_info_result is an array reference which consists of path information.

DESCRIPTION

Get an allowable shortest path between the input terms. This module uses a standard BFS graph algorithm with small modifications to accomodate the rules for allowable path. It calculates the shortest allowable path between any two terms supplied to it as a input with a graph formed by FormGraph module.

SUBROUTINES

The subroutines are as follows:

new

This sub creates a new object of GetAllowablePaths

get_shortest_path_info

This sub returns the shortest path along with its cost and number of changes in direction

getCost

This sub finds the cost of the path accepted as a parameter

printHoH

This subroutines prints the current contents of hash of hash

printHash

This sub prints argument hash.

SEE ALSO

GetUserData.pm Query.pm ws-getAllowabletPath.pl GetParents.pm

AUTHORS

Mugdha Choudhari, University of Minnesota Duluth <chou0130 at d.umn.edu>

Ted Pedersen, University of Minnesota Duluth <tpederse at d.umn.edu>

COPYRIGHT

Copyright (C) 2011, Mugdha Choudhari, Ted Pedersen

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to The Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.