From 906144128eaed56eca88a618083c3888780b169e Mon Sep 17 00:00:00 2001 From: miker Date: Sun, 19 Feb 2006 01:19:07 +0000 Subject: [PATCH] fixups, and starting a paged interface git-svn-id: svn://svn.open-ils.org/ILS/trunk@3116 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/extras/docgen.xsl | 98 ++++++++++++--------- OpenSRF/src/perlmods/OpenSRF/Application.pm | 26 ++++-- 2 files changed, 75 insertions(+), 49 deletions(-) diff --git a/Open-ILS/src/extras/docgen.xsl b/Open-ILS/src/extras/docgen.xsl index 4c45b4f397..27047ee797 100644 --- a/Open-ILS/src/extras/docgen.xsl +++ b/Open-ILS/src/extras/docgen.xsl @@ -36,8 +36,26 @@ span.subcode { color:darkblue;} + + + + + + + + + + + + + + + + + + @@ -48,9 +66,11 @@ span.subcode { color:darkblue;} + + - +











@@ -62,19 +82,13 @@ span.subcode { color:darkblue;} this.param.value = "\"" + this.param.value + "\""; if (this.all.checked) this.method.value = "opensrf.system.method.all"; '> - + Application: - - - - - - -   +   API Method Name Regex: ' = 'true'"> @@ -82,13 +96,8 @@ span.subcode { color:darkblue;} - ' = '(none)'"> - - - -   - All Methods + All Methods (Use with care!) - +
@@ -121,19 +130,13 @@ span.subcode { color:darkblue;} this.param.value = "\"" + this.param.value + "\""; if (this.all.checked) this.method.value = "opensrf.system.method.all"; '> - + Application: - - - - - - -   +   API Method Name Regex: ' = 'true'"> @@ -141,13 +144,8 @@ span.subcode { color:darkblue;} - ' = '(none)'"> - - - -   - All Methods + All Methods (Use with care!) + API Level: / Method:
# @@ -180,14 +179,23 @@ span.subcode { color:darkblue;} - -

Method Index

- - -

Method Definitions

-
- - + + +

Matching Methods

+ + + + +

Method Definitions

+
+ +

No Matching Methods Found

+
+
+ + + +
@@ -263,6 +271,10 @@ span.subcode { color:darkblue;} + + + + @@ -289,7 +301,9 @@ span.subcode { color:darkblue;} Parameters: - + + + @@ -310,12 +324,14 @@ span.subcode { color:darkblue;} - + + - + + diff --git a/OpenSRF/src/perlmods/OpenSRF/Application.pm b/OpenSRF/src/perlmods/OpenSRF/Application.pm index 922ed521f2..738bae7753 100644 --- a/OpenSRF/src/perlmods/OpenSRF/Application.pm +++ b/OpenSRF/src/perlmods/OpenSRF/Application.pm @@ -620,22 +620,32 @@ sub introspect { my $self = shift; my $client = shift; my $method = shift; + my $limit = shift; + my $offset = shift; $method = undef if ($self->api_name =~ /all$/o); + my ($seen,$returned) = (0,0); for my $api_level ( reverse(1 .. $#_METHODS) ) { for my $api_name ( sort keys %{$_METHODS[$api_level]} ) { - if (!$_METHODS[$api_level]{$api_name}{remote}) { - if (defined($method)) { - if ($api_name =~ $method) { - $client->respond( $_METHODS[$api_level]{$api_name} ); + if (!$offset || $offset < $seen) { + if (!$_METHODS[$api_level]{$api_name}{remote}) { + if (defined($method)) { + if ($api_name =~ $method) { + if (!$limit || $returned < $limit) { + $client->respond( $_METHODS[$api_level]{$api_name} ); + $returned++; + } + } + } else { + if (!$limit || $returned < $limit) { + $client->respond( $_METHODS[$api_level]{$api_name} ); + $returned++; + } } - } else { - $log->debug( "Returning definition for method [$api_name]", INTERNAL ); - $client->respond( $_METHODS[$api_level]{$api_name} ); - $log->debug( "responed with definition for method [$api_name]", INTERNAL ); } } + $seen++; } } -- 2.43.2
Position:
Returns: