Annotation of nsdl/lib/perl/Apache/NSDL/FromTheGateway.pm, revision 1.5

1.1       harris41    1: # Apache::NSDL::FromTheGateway
                      2: #
                      3: # FromTheGateway.pm
                      4: # API for passing information to NSDL from the Gateway Server
                      5: #
                      6: # For more documentation, read the POD documentation
                      7: # of this module with the perldoc command:
                      8: #
                      9: #         perldoc ./FromTheGateway.pm
                     10: #
                     11: # Brief description
                     12: # =================
                     13: #
                     14: # This module contains functionality for
                     15: # transferring information from NSDL to the Gateway Server.
                     16: #
                     17: # In terms of the overall data flow, the
                     18: # '=====>' below indicates the role of this
                     19: # module.
                     20: #
                     21: # NSDL ---------> Gateway --------> LON-CAPA
1.4       harris41   22: # LON-CAPA -----> Gateway ========> NSDL
1.1       harris41   23: #
                     24: # SUBROUTINES:
                     25: # NSDL->view_LONCAPAgateway_results
                     26: # NSDL->view_LONCAPAgateway_metadata_record
                     27: # NSDL->access_LONCAPAgateway_resource
                     28: # NSDL->search_against_LONCAPAgateway
                     29: 
                     30: # Year 2002
                     31: # Scott Harrison
                     32: # February-May
                     33: #
                     34: ###
                     35: 
                     36: package Apache::NSDL::FromTheGateway;
                     37: 
                     38: # ================================================================ DEPENDENCIES
                     39: use strict; # enforce handling of variables, references and subroutines
                     40: 
                     41: # ============================================================ MODULE VARIABLES
1.5     ! harris41   42: my $VERSION = sprintf("%d.%02d", q$Revision: 1.4 $ =~ /(\d+)\.(\d+)/);
1.1       harris41   43: 
                     44: # ================================================================= SUBROUTINES
                     45: 
                     46: # ------------------------------------------- NSDL->view_LONCAPAgateway_results
                     47: sub view_LONCAPAgateway_results {
                     48: # Not yet implemented
                     49: # Need to specifically characterize INPUT arguments and OUTPUT data
                     50: }
                     51: 
                     52: # ----------------------------------- NSDL->view_LONCAPAgateway_metadata_record
                     53: sub view_LONCAPAgateway_metadata_record {
                     54: # Not yet implemented
                     55: # Need to specifically characterize INPUT arguments and OUTPUT data
                     56: }
                     57: 
                     58: # ---------------------------------------- NSDL->access_LONCAPAgateway_resource
                     59: sub access_LONCAPAgateway_resource {
                     60: # Not yet implemented
                     61: # Need to specifically characterize INPUT arguments and OUTPUT data
                     62: }
                     63: 
                     64: # ----------------------------------------- NSDL->search_against_LONCAPAgateway
                     65: sub search_against_LONCAPAgateway {
                     66: # Not yet implemented
                     67: # Need to specifically characterize INPUT arguments and OUTPUT data
                     68: }
                     69: 
                     70: 1;
                     71: 
                     72: __END__
                     73: 
                     74: =pod
                     75: 
                     76: =head1 NAME
                     77: 
                     78: B<Apache::NSDL::FromTheGateway> - API for passing information to NSDL from the Gateway Server
                     79: 
                     80: =head1 SYNOPSIS
                     81: 
                     82:  use Apache::NSDL::FromTheGateway;
                     83: 
                     84:  my $arrayref=
                     85:     Apache::NSDL::FromTheGateway::view_LONCAPAgateway_results
                     86:       ($OAI_protocol_request);
                     87: 
                     88: =head1 DESCRIPTION
                     89: 
                     90: This module contains functionality for
                     91: transferring information to NSDL from the Gateway Server.
                     92: 
                     93: In terms of the overall data flow, the
                     94: '=====>' below indicates the role of this
                     95: module.
                     96: 
                     97: NSDL ---------E<gt> Gateway --------E<gt> LON-CAPA
                     98: 
1.2       harris41   99: LON-CAPA -----E<gt> B<Gateway ========E<gt> NSDL>
1.1       harris41  100: 
                    101: =head2 EXIT CODES
                    102: 
                    103: The subroutines of this module all output an exit code which
                    104: describes the status of function completion.  The exit code
                    105: may be followed by a more descriptive message such as:
                    106: 
                    107:  FORMATERROR:Sun May  5 20:15:16 GMT 2002:missing 'protocol://' pattern
                    108: 
                    109: =over 4
                    110: 
                    111: =item *
                    112: 
                    113: B<'SUCCESS'>, information was found and is being returned
                    114: 
                    115: =item *
                    116: 
                    117: B<'EMPTY'>, everything functioned properly, but no information was present
                    118: 
                    119: =item *
                    120: 
                    121: B<'BADEMPTY'>, everything appeared to function properly, but no information
                    122: was present (which defies expectation); this is useful for detecting phantom
                    123: cases of connectivity when verifying test cases of vertical software partitions
                    124: 
                    125: =item *
                    126: 
                    127: B<'TIMEOUT'>, the request is taking WAY too long
                    128: 
                    129: =item *
                    130: 
                    131: B<'FORMATERROR'>, the input argument is not formatted correctly in a way that
                    132: can be processed by the NSDL server
                    133: 
                    134: =item *
                    135: 
                    136: B<'CONNECTIONFAILURE'>, the NSDL server cannot be contacted
                    137: 
                    138: =back
                    139: 
                    140: =head2 SUBROUTINES
                    141: 
                    142: Note that the subroutines all output an exit code which
                    143: describes the status of function completion.
                    144: 
                    145: In the case of failed function completion, the other
                    146: output argument(s) will typically only be 'NULL' values.
                    147: 
                    148: =over 4
                    149: 
                    150: =item B<Apache::NSDL::view_LONCAPAgateway_results>
                    151: 
                    152: =over 4
                    153: 
                    154: =item B<Input> - Scalar string
                    155: 
                    156: Memory location of Gateway Server results.
                    157: 
                    158: =item B<Output> - Scalar string, Scalar string reference
                    159: 
                    160: An exit code is returned as a scalar string.
                    161: 
                    162: View the Gateway Server results.
                    163: 
                    164: =item B<Description>
                    165: 
                    166: This facilitates the viewing of LON-CAPA record lists.
                    167: B<This relates to information that has passed
                    168: to NSDL I<from the> GATEWAY>.
                    169: 
1.5     ! harris41  170: =item B<Status of Implementation>
        !           171: 
        !           172: n/a
        !           173: 
1.1       harris41  174: =back
                    175: 
                    176: =item B<Apache::NSDL::view_LONCAPAgateway_metadata_record>
                    177: 
                    178: =over 4
                    179: 
                    180: =item B<Input> - Scalar string
                    181: 
                    182: Identifier for a specific LON-CAPA metadata record.
                    183: 
                    184: =item B<Output> - Scalar string, Scalar string reference
                    185: 
                    186: An exit code is returned as a scalar string.
                    187: 
                    188: A pointer to the metadata.
                    189: 
                    190: =item B<Description>
                    191: 
                    192: This provides the content of the resource matching a given request.
                    193: B<The information has passed to NSDL I<from the> GATEWAY>.
                    194: 
1.5     ! harris41  195: =item B<Status of Implementation>
        !           196: 
        !           197: n/a
        !           198: 
1.1       harris41  199: =back
                    200: 
                    201: =item B<Apache::NSDL::access_LONCAPAgateway_resource>
                    202: 
                    203: =over 4
                    204: 
                    205: =item B<Input> - Scalar string
                    206: 
                    207: Identifier for LON-CAPA resource.
                    208: 
1.3       harris41  209: =item B<Output> - Scalar string, Scalar string reference.
1.1       harris41  210: 
                    211: An exit code is returned as a scalar string.
                    212: 
1.3       harris41  213: Pointer to information about accessing LON-CAPA resource.
1.1       harris41  214: 
                    215: =item B<Description>
                    216: 
                    217: This accepts access to a LON-CAPA resource.
                    218: B<The information has passed to NSDL I<from the> GATEWAY>.
                    219: 
1.5     ! harris41  220: =item B<Status of Implementation>
        !           221: 
        !           222: n/a
        !           223: 
1.1       harris41  224: =back
                    225: 
                    226: =item B<Apache::NSDL::search_against_LONCAPAgateway>
                    227: 
                    228: =over 4
                    229: 
                    230: =item B<Input> - Scalar string
                    231: 
                    232: Set of search expressions and corresponding fields to pass onto the
                    233: LONCAPAgateway.
                    234: 
                    235: =item B<Output> - Scalar string, Scalar array reference
                    236: 
                    237: An exit code is returned as a scalar string.
                    238: 
                    239: A pointer to the location of search results is returned.
                    240: 
                    241: =item B<Description>
                    242: 
                    243: This models the functionality by which an NSDL server will pass a search
                    244: request to the NSDL-LONCAPA Gateway Server.
                    245: This launches the search request and receives a pointer as to
                    246: where the results will be.
1.5     ! harris41  247: 
        !           248: =item B<Status of Implementation>
        !           249: 
        !           250: n/a
1.1       harris41  251: 
                    252: =back
                    253: 
                    254: =back
                    255: 
                    256: =head1 README
                    257: 
                    258: B<Apache::NSDL::FromTheGateway>
                    259: is part of the NSDL-LONCAPA Gateway Server system.
                    260: Please see http://nsdl.lon-capa.org/ for more information.
                    261: 
                    262: =head1 AUTHOR
                    263: 
                    264: Scott Harrison, 2002
                    265: 
                    266: =head1 PREREQUISITES
                    267: 
                    268: This module requires the C<strict> module.
                    269: 
                    270: =head1 COREQUISITES
                    271: 
                    272: Apache::NSDL::ToTheGateway
                    273: Apache::GATEWAY::ToNSDL
                    274: Apache::GATEWAY::FromNSDL
                    275: Apache::GATEWAY::ToLONCAPA
                    276: Apache::GATEWAY::FromLONCAPA
                    277: Apache::LONCAPA::FromTheGateway
                    278: Apache::LONCAPA::ToTheGateway
                    279: 
                    280: =head1 SEE ALSO
                    281: 
                    282: http://www.lon-capa.org/
                    283: 
                    284: http://www.smete.org/
                    285: 
                    286: Also visit the other Apache::NSDL::*, Apache::LONCAPA::*,
                    287: and Apache::GATEWAY::* manpages.
                    288: 
                    289: =head1 OSNAMES
                    290: 
                    291: linux
                    292: 
                    293: =cut
                    294: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>