File: syslog_example1.adb

package info (click to toggle)
libalog 0.3-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 2,056 kB
  • ctags: 465
  • sloc: ada: 5,203; makefile: 166; sql: 9; sh: 2
file content (16 lines) | stat: -rw-r--r-- 430 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
with Alog.Logger;
with Alog.Facilities.Syslog;

use Alog;

--  Alog syslog example.
procedure Syslog_Example1 is
   Log    : Logger.Instance (Init => False);
   Syslog : constant Facilities.Syslog.Handle :=
     new Facilities.Syslog.Instance;
begin
   Log.Attach_Facility (Facility => Facilities.Handle (Syslog));

   Log.Log_Message (Level  => Debug,
                    Msg    => "This is a testmessage");
end Syslog_Example1;