=head1 NAME

ASNMTAP::Asnmtap::Applications::Display is a Perl module that provides a nice object oriented interface for ASNMTAP Display Applications

=head1 Description

ASNMTAP::Asnmtap::Applications::Display Subclass of ASNMTAP::Asnmtap::Applications

This version is still the old ASNMTAP Applications v3.000.001 addapted for using with the new ASNMTAP::Asnmtap, ASNMTAP::Asnmtap::Plugins and ASNMTAP::Asnmtap::Plugins::Nagios plugins.

We are working onto an new Object Oriented version for the ASNMTAP Applications

=head1 FILES

=over 4

=item located at /opt/asnmtap/applications/custom

=over 4

=item display.pm

Here we can add customised expressions to manipulate the output of the display regarding the content of the $statusMessage where the extra error information is added to $errorMessage

 sub printStatusMessageCustom {
   my $statusMessage = shift(@_);

   my $break = '';
   my $errorMessage = '';

   if ($statusMessage =~ /&lt;NIHIL&gt/ ) {
     $errorMessage = 'possible a problem with this execution for this plugin';
   # ***************************************************************************
   # Error codes indicate an error with DUMMY-Tn                               *
   # ***************************************************************************
   } elsif ($statusMessage =~ /Check Dummy:/ ) {
     if ($statusMessage =~ /\+DUMMY-T1\+/ ) { $errorMessage = 'testing: <normal crontab>'; }
     if ($statusMessage =~ /\+DUMMY-T2\+/ ) { $errorMessage = 'testing: noOFFLINE'; }
     if ($statusMessage =~ /\+DUMMY-T3\+/ ) { $errorMessage = 'testing: multiOFFLINE'; }
     if ($statusMessage =~ /\+DUMMY-T4\+/ ) { $errorMessage = 'testing: noTEST'; }
   # ---------------------------------------------------------------------------
   # Start custom code ---------------------------------------------------------
   # ---------------------------------------------------------------------------
 # } elsif ($statusMessage =~ /<string to find>/ ) {
 #   if ($statusMessage =~ /\+<substring to find>\+/ ) { $errorMessage = '<erormessage to return>'; }
   # ---------------------------------------------------------------------------
   # End custom code -----------------------------------------------------------
   # ---------------------------------------------------------------------------
   }

   return $errorMessage;
 }

=over 4

=item cartography.pm

Integration with Cartography

printLinkToCartography()

=back

=over 4

=item sde.pm

Integration with SDE

printRelationshipsSDE()

=back

=item located at /opt/asnmtap/applications/etc

=over 4

=item DisplayCT-*

are the config files used by the program display.pl

when the Application CGI module and CGI applications are installed, these config files is automatically generated by the program generateConfig.pl

=over 4

=item format

 Format: <Interval>#<Groep Title>#<resultsdir>#[<catalogID>_]<uniqueKey>#<Title nnn>#check_nnn#<help 0|1>[|[<catalogID>_]<uniqueKey>#<Title mmm>#check_mmm#<help 0|1>]

   <Interval>		:
   <Groep Title>	:
   <resultsdir>		: result subdir where the data from the collector is located
   <catalogID>      : unique catalogID
   <uniqueKey>		: unique key for this plugin
   <Title nnn>		:
   check_nnn		: plugin name
   <help 0|1>		:

=item example

 more /opt/asnmtap/applications/etc/DisplayCT-test

 # DisplayCT-test - CTP-CENTRAL, generated on 2010/mm/dd 17:58:16, ASNMTAP v3.002.002 or higher
 #
 # <interval>#<groep title>#<resultsdir>#[<catalogID>_]<uniqueKey>#<titel nnn>#check_nnn#<help 0|1>[|[<catalogID>_]<uniqueKey>#<titel mmm>#check_mmm#<help 0|1>]
 #
 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
 #
 10#CACTUS: Based onto Template cactus#index#CITAP-04#CACTUS plugin cactus.citap.com#cactus-citap-com.pl --trendline=5#0
 #
 2#Condenced View Test#test-05#CID_DUMMY-T5#Condenced View test#check_dummy.pl --trendline=5#1
 #
 2#Testing Collector & Display for the 'Application Monitor'#test-01#CID_DUMMY-T1#DUMMY-T1#check_dummy.pl --trendline=0#1
 2#Testing Collector & Display for the 'Application Monitor'#test-02#CID_DUMMY-T2#DUMMY-T2#check_dummy.pl --trendline=1#1
 2#Testing Collector & Display for the 'Application Monitor'#test-03#CID_DUMMY-T3#DUMMY-T3#check_dummy.pl --trendline=2#1
 2#Testing Collector & Display for the 'Application Monitor'#test-04#CID_DUMMY-T4#DUMMY-T4#check_dummy.pl --trendline=3#1
 #
 # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
 # Einde DisplayCT-test - CTP-CENTRAL

=back

=back

=item located at /opt/asnmtap/applications/master

=over 4

=item DisplayCT-*.sh

start, stop, reload, restart or get status for an Display daemon with the correspondending DisplayCT-*.sh shell script

=item asnmtap-display.sh

shell script to start, stop, reload, restart or get status for all the Display daemons by the user asnmtap

=item root-display.sh

shell script to start, stop, reload, restart or get status for all the Display daemons by the user root

=back

=item located at /opt/asnmtap/applications/slave

=over 4

=item ...

...

=back

=back

=back

=head1 PROGRAMS

=over 4

=item located at /opt/asnmtap/applications

=over 4

=item display.pl

this program is the Display, and generate the statically pages used through the CGI interface.

the PID files his atime and mtime is updated every timeslot, to make monitoring possible with Nagios, etc.

=item display-test.pl

test version from the program display.pl

=back

=item located at /opt/asnmtap/applications/master

=over 4

=item ...

...

=back

=item located at /opt/asnmtap/applications/slave

=over 4

=item ...

...

=back

=back

=head1 EXPORT

...

=head1 AUTHOR

Alex Peeters [alex.peeters@citap.be]

=head1 SEE ALSO

ASNMTAP::Asnmtap, ASNMTAP::Asnmtap::Applications

=head1 DEPENDENCIES

 ASNMTAP::Asnmtap::Applications
 Carp
 Time::Local

=head1 COPYRIGHT NOTICE

(c) Copyright 2000-2010 by Alex Peeters [alex.peeters@citap.be],
                        All Rights Reserved.

ASNMTAP is based on 'Process System daemons v1.60.17-01', Alex Peeters [alex.peeters@citap.be]

 Purpose: CronTab (CT, sysdCT),
          Disk Filesystem monitoring (DF, sysdDF),
          Intrusion Detection for FW-1 (ID, sysdID)
          Process System daemons (PS, sysdPS),
          Reachability of Remote Hosts on a network (RH, sysdRH),
          Rotate Logfiles (system activity files) (RL),
          Remote Socket monitoring (RS, sysdRS),
          System Activity monitoring (SA, sysdSA).

'Process System daemons' is based on 'sysdaemon 1.60' written by Trans-Euro I.T Ltd

=head1 LICENSE

This ASNMTAP CPAN library and Plugin templates are free software; you can redistribute it and/or modify it under the same terms as Perl itself.

The other parts of ASNMTAP may be used and modified free of charge by anyone so long as this copyright notice and the comments above remain intact. By using this code you agree to indemnify Alex Peeters from any liability that might arise from it's use.

Selling the code for this program without prior written consent is expressly forbidden. In other words, please ask first before you try and make money off of my program.

Obtain permission before redistributing this software over the Internet or in any other medium. In all cases copyright and header must remain intact.

=cut
