[LON-CAPA-cvs] cvs: nsdl /lib/perl/Apache/GATEWAY FromLONCAPA.pm
harris41
lon-capa-cvs@mail.lon-capa.org
Tue, 07 May 2002 15:59:41 -0000
harris41 Tue May 7 11:59:41 2002 EDT
Added files:
/nsdl/lib/perl/Apache/GATEWAY FromLONCAPA.pm
Log:
NSDL Gateway: Software Structure: BUG 396
(Enhancement); perl syntax OK; considered complete
Index: nsdl/lib/perl/Apache/GATEWAY/FromLONCAPA.pm
+++ nsdl/lib/perl/Apache/GATEWAY/FromLONCAPA.pm
# Apache::GATEWAY::FromLONCAPA
#
# FromLONCAPA.pm
# API for passing information to the Gateway Server FROM NSDL
#
# For more documentation, read the POD documentation
# of this module with the perldoc command:
#
# perldoc ./FromLONCAPA.pm
#
# Brief description
# =================
#
# This module contains functionality for
# transferring information to the Gateway Server from LON-CAPA.
#
# In terms of the overall data flow, the
# '=====>' below indicates the role of this
# module.
#
# NSDL ---------> Gateway --------> LON-CAPA
# LON-CAPA ====> Gateway --------> NSDL
#
# SUBROUTINES:
# GATEWAY->search_against_LONCAPAnetwork
# GATEWAY->view_LONCAPAnetwork_results
# GATEWAY->view_LONCAPAnetwork_metadata_record
# GATEWAY->access_LONCAPAnetwork_resource
# Year 2002
# Scott Harrison
# February-May
#
###
package Apache::GATEWAY::FromLONCAPA;
# ================================================================ DEPENDENCIES
use strict; # enforce handling of variables, references and subroutines
# ============================================================ MODULE VARIABLES
my $VERSION = sprintf("%d.%02d", q$Revision: 1.1 $ =~ /(\d+)\.(\d+)/);
# ================================================================= SUBROUTINES
# ---------------------------------------- GATEWAY->view_LONCAPAnetwork_results
sub view_LONCAPAnetwork_results {
# Not yet implemented
# Need to specifically characterize INPUT arguments and OUTPUT data
}
# -------------------------------- GATEWAY->view_LONCAPAnetwork_metadata_record
sub view_LONCAPAnetwork_metadata_record {
# Not yet implemented
# Need to specifically characterize INPUT arguments and OUTPUT data
}
# ------------------------------------- GATEWAY->access_LONCAPAnetwork_resource
sub access_LONCAPAnetwork_resource {
# Not yet implemented
# Need to specifically characterize INPUT arguments and OUTPUT data
}
# -------------------------------------- GATEWAY->search_against_LONCAPAnetwork
sub search_against_LONCAPAnetwork {
# Not yet implemented
# Need to specifically characterize INPUT arguments and OUTPUT data
}
1;
__END__
=pod
=head1 NAME
B<Apache::GATEWAY::FromLONCAPA> - API for passing information to the Gateway Server from LON-CAPA
=head1 SYNOPSIS
use Apache::GATEWAY::FromLONCAPA;
my $arrayref=
Apache::GATEWAY::FromLONCAPA::view_LONCAPAnetwork_results
($result_list_identifier);
=head1 DESCRIPTION
This module contains functionality for
transferring information to the Gateway Server from LON-CAPA.
In terms of the overall data flow, the
'=====>' below indicates the role of this
module.
NSDL ---------E<gt> Gateway --------E<gt> LON-CAPA
B<LON-CAPA =====E<gt> Gateway> ========E<gt> NSDL
=head2 EXIT CODES
The subroutines of this module all output an exit code which
describes the status of function completion. The exit code
may be followed by a more descriptive message such as:
FORMATERROR:Sun May 5 20:15:16 GMT 2002:missing 'protocol://' pattern
=over 4
=item *
B<'SUCCESS'>, information was found and is being returned
=item *
B<'EMPTY'>, everything functioned properly, but no information was present
=item *
B<'BADEMPTY'>, everything appeared to function properly, but no information
was present (which defies expectation); this is useful for detecting phantom
cases of connectivity when verifying test cases of vertical software partitions
=item *
B<'TIMEOUT'>, the request is taking WAY too long
=item *
B<'FORMATERROR'>, the input argument is not formatted correctly in a way that
can be processed by the NSDL server
=item *
B<'CONNECTIONFAILURE'>, the NSDL server cannot be contacted
=back
=head2 SUBROUTINES
Note that the subroutines all output an exit code which
describes the status of function completion.
In the case of failed function completion, the other
output argument(s) will typically only be 'NULL' values.
=over 4
=item B<Apache::GATEWAY::FromLONCAPA::view_LONCAPAnetwork_results>
=over 4
=item B<Input> - Scalar string
Memory location of Gateway Server results.
=item B<Output> - Scalar string, Scalar string reference
An exit code is returned as a scalar string.
Pass on LON-CAPA result list tod the Gateway Server from LON-CAPA for viewing.
=item B<Description>
This facilitates the viewing of LON-CAPA record lists.
B<This relates to information that has passed
to the GATEWAY I<from> LON-CAPA>.
=item B<Status of Implementation>
n/a
=back
=item B<Apache::GATEWAY::FromLONCAPA::view_LONCAPAnetwork_metadata_record>
=over 4
=item B<Input> - Scalar string
Identifier for a specific LON-CAPA metadata record.
=item B<Output> - Scalar string, Scalar string reference
An exit code is returned as a scalar string.
A pointer to the metadata.
=item B<Description>
This provides the content of the resource matching a given request.
B<The information has passed to the GATEWAY I<from> LON-CAPA>.
=item B<Status of Implementation>
n/a
=back
=item B<Apache::GATEWAY::FromLONCAPA::access_LONCAPAnetwork_resource>
=over 4
=item B<Input> - Scalar string
Identifier for LON-CAPA resource.
=item B<Output> - Scalar string, Scalar string reference.
An exit code is returned as a scalar string.
Pointer to information about accessing LON-CAPA resource.
=item B<Description>
This accepts access to a LON-CAPA resource.
B<The information has passed to the GATEWAY I<from> LON-CAPA>.
=item B<Status of Implementation>
n/a
=back
=item B<Apache::GATEWAY::FromLONCAPA::search_against_LONCAPAnetwork>
=over 4
=item B<Input> - Scalar string
Search results to pass to the NSDL-LONCAPA Gateway Server from
LON-CAPA.
=item B<Output> - Scalar string, Scalar array reference
An exit code is returned as a scalar string.
A pointer to the location of search results is returned.
=item B<Description>
This models the functionality by which the NSDL-LONCAPA Gateway server will
receive search results from LON-CAPA.
This launches the search request and receives a pointer as to
where the results will be.
=item B<Status of Implementation>
n/a
=back
=back
=head1 README
B<Apache::GATEWAY::FromLONCAPA>
is part of the NSDL-LONCAPA Gateway Server system.
Please see http://nsdl.lon-capa.org/ for more information.
=head1 AUTHOR
Scott Harrison, 2002
=head1 PREREQUISITES
This module requires the C<strict> module.
=head1 COREQUISITES
Apache::NSDL::FromTheGateway
Apache::NSDL::ToTheGateway
Apache::GATEWAY::ToNSDL
Apache::GATEWAY::FromNSDL
Apache::GATEWAY::ToLONCAPA
Apache::LONCAPA::FromTheGateway
Apache::LONCAPA::ToTheGateway
=head1 SEE ALSO
http://www.lon-capa.org/
http://www.smete.org/
Also visit the other Apache::NSDL::*, Apache::LONCAPA::*,
and Apache::GATEWAY::* manpages.
=head1 OSNAMES
linux
=cut