This file is indexed.

/usr/lib/perl5/PDA/Pilot.pm is in libpda-pilot-perl 0.12.5-4ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

   1
   2
   3
   4
   5
   6
   7
   8
   9
  10
  11
  12
  13
  14
  15
  16
  17
  18
  19
  20
  21
  22
  23
  24
  25
  26
  27
  28
  29
  30
  31
  32
  33
  34
  35
  36
  37
  38
  39
  40
  41
  42
  43
  44
  45
  46
  47
  48
  49
  50
  51
  52
  53
  54
  55
  56
  57
  58
  59
  60
  61
  62
  63
  64
  65
  66
  67
  68
  69
  70
  71
  72
  73
  74
  75
  76
  77
  78
  79
  80
  81
  82
  83
  84
  85
  86
  87
  88
  89
  90
  91
  92
  93
  94
  95
  96
  97
  98
  99
 100
 101
 102
 103
 104
 105
 106
 107
 108
 109
 110
 111
 112
 113
 114
 115
 116
 117
 118
 119
 120
 121
 122
 123
 124
 125
 126
 127
 128
 129
 130
 131
 132
 133
 134
 135
 136
 137
 138
 139
 140
 141
 142
 143
 144
 145
 146
 147
 148
 149
 150
 151
 152
 153
 154
 155
 156
 157
 158
 159
 160
 161
 162
 163
 164
 165
 166
 167
 168
 169
 170
 171
 172
 173
 174
 175
 176
 177
 178
 179
 180
 181
 182
 183
 184
 185
 186
 187
 188
 189
 190
 191
 192
 193
 194
 195
 196
 197
 198
 199
 200
 201
 202
 203
 204
 205
 206
 207
 208
 209
 210
 211
 212
 213
 214
 215
 216
 217
 218
 219
 220
 221
 222
 223
 224
 225
 226
 227
 228
 229
 230
 231
 232
 233
 234
 235
 236
 237
 238
 239
 240
 241
 242
 243
 244
 245
 246
 247
 248
 249
 250
 251
 252
 253
 254
 255
 256
 257
 258
 259
 260
 261
 262
 263
 264
 265
 266
 267
 268
 269
 270
 271
 272
 273
 274
 275
 276
 277
 278
 279
 280
 281
 282
 283
 284
 285
 286
 287
 288
 289
 290
 291
 292
 293
 294
 295
 296
 297
 298
 299
 300
 301
 302
 303
 304
 305
 306
 307
 308
 309
 310
 311
 312
 313
 314
 315
 316
 317
 318
 319
 320
 321
 322
 323
 324
 325
 326
 327
 328
 329
 330
 331
 332
 333
 334
 335
 336
 337
 338
 339
 340
 341
 342
 343
 344
 345
 346
 347
 348
 349
 350
 351
 352
 353
 354
 355
 356
 357
 358
 359
 360
 361
 362
 363
 364
 365
 366
 367
 368
 369
 370
 371
 372
 373
 374
 375
 376
 377
 378
 379
 380
 381
 382
 383
 384
 385
 386
 387
 388
 389
 390
 391
 392
 393
 394
 395
 396
 397
 398
 399
 400
 401
 402
 403
 404
 405
 406
 407
 408
 409
 410
 411
 412
 413
 414
 415
 416
 417
 418
 419
 420
 421
 422
 423
 424
 425
 426
 427
 428
 429
 430
 431
 432
 433
 434
 435
 436
 437
 438
 439
 440
 441
 442
 443
 444
 445
 446
 447
 448
 449
 450
 451
 452
 453
 454
 455
 456
 457
 458
 459
 460
 461
 462
 463
 464
 465
 466
 467
 468
 469
 470
 471
 472
 473
 474
 475
 476
 477
 478
 479
 480
 481
 482
 483
 484
 485
 486
 487
 488
 489
 490
 491
 492
 493
 494
 495
 496
 497
 498
 499
 500
 501
 502
 503
 504
 505
 506
 507
 508
 509
 510
 511
 512
 513
 514
 515
 516
 517
 518
 519
 520
 521
 522
 523
 524
 525
 526
 527
 528
 529
 530
 531
 532
 533
 534
 535
 536
 537
 538
 539
 540
 541
 542
 543
 544
 545
 546
 547
 548
 549
 550
 551
 552
 553
 554
 555
 556
 557
 558
 559
 560
 561
 562
 563
 564
 565
 566
 567
 568
 569
 570
 571
 572
 573
 574
 575
 576
 577
 578
 579
 580
 581
 582
 583
 584
 585
 586
 587
 588
 589
 590
 591
 592
 593
 594
 595
 596
 597
 598
 599
 600
 601
 602
 603
 604
 605
 606
 607
 608
 609
 610
 611
 612
 613
 614
 615
 616
 617
 618
 619
 620
 621
 622
 623
 624
 625
 626
 627
 628
 629
 630
 631
 632
 633
 634
 635
 636
 637
 638
 639
 640
 641
 642
 643
 644
 645
 646
 647
 648
 649
 650
 651
 652
 653
 654
 655
 656
 657
 658
 659
 660
 661
 662
 663
 664
 665
 666
 667
 668
 669
 670
 671
 672
 673
 674
 675
 676
 677
 678
 679
 680
 681
 682
 683
 684
 685
 686
 687
 688
 689
 690
 691
 692
 693
 694
 695
 696
 697
 698
 699
 700
 701
 702
 703
 704
 705
 706
 707
 708
 709
 710
 711
 712
 713
 714
 715
 716
 717
 718
 719
 720
 721
 722
 723
 724
 725
 726
 727
 728
 729
 730
 731
 732
 733
 734
 735
 736
 737
 738
 739
 740
 741
 742
 743
 744
 745
 746
 747
 748
 749
 750
 751
 752
 753
 754
 755
 756
 757
 758
 759
 760
 761
 762
 763
 764
 765
 766
 767
 768
 769
 770
 771
 772
 773
 774
 775
 776
 777
 778
 779
 780
 781
 782
 783
 784
 785
 786
 787
 788
 789
 790
 791
 792
 793
 794
 795
 796
 797
 798
 799
 800
 801
 802
 803
 804
 805
 806
 807
 808
 809
 810
 811
 812
 813
 814
 815
 816
 817
 818
 819
 820
 821
 822
 823
 824
 825
 826
 827
 828
 829
 830
 831
 832
 833
 834
 835
 836
 837
 838
 839
 840
 841
 842
 843
 844
 845
 846
 847
 848
 849
 850
 851
 852
 853
 854
 855
 856
 857
 858
 859
 860
 861
 862
 863
 864
 865
 866
 867
 868
 869
 870
 871
 872
 873
 874
 875
 876
 877
 878
 879
 880
 881
 882
 883
 884
 885
 886
 887
 888
 889
 890
 891
 892
 893
 894
 895
 896
 897
 898
 899
 900
 901
 902
 903
 904
 905
 906
 907
 908
 909
 910
 911
 912
 913
 914
 915
 916
 917
 918
 919
 920
 921
 922
 923
 924
 925
 926
 927
 928
 929
 930
 931
 932
 933
 934
 935
 936
 937
 938
 939
 940
 941
 942
 943
 944
 945
 946
 947
 948
 949
 950
 951
 952
 953
 954
 955
 956
 957
 958
 959
 960
 961
 962
 963
 964
 965
 966
 967
 968
 969
 970
 971
 972
 973
 974
 975
 976
 977
 978
 979
 980
 981
 982
 983
 984
 985
 986
 987
 988
 989
 990
 991
 992
 993
 994
 995
 996
 997
 998
 999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
#
# Pilot.pm - Interface glue for the pilot-link libraries and Perl.
#
# Copyright (C) 1997, 1998, Kenneth Albanowski
#
# This library is free software; you can redistribute it and/or modify it
# under the terms of the GNU Library General Public License as published by
# the Free Software Foundation; either version 2 of the License, or (at your
# option) any later version.
# 
# This library is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
# or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
# License for more details.
# 
# You should have received a copy of the GNU Library General Public License
# along with this library; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. *
#

package PDA::Pilot;

require Exporter;
require DynaLoader;
require AutoLoader;
use Carp;

@ISA = qw(Exporter DynaLoader);
# Items to export into callers namespace by default. Note: do not export
# names by default without a very good reason. Use EXPORT_OK instead.
# Do not simply export all your public functions/methods/constants.
@ EXPORT = qw(PI_AF_SLP
              PI_PF_LOOP
              PI_PF_PADP
              PI_PF_SLP
              PI_PilotSocketConsole
              PI_PilotSocketDLP
              PI_PilotSocketDebugger
              PI_PilotSocketRemoteUI
              PI_SOCK_DGRAM
              PI_SOCK_RAW
              PI_SOCK_SEQPACKET
              PI_SOCK_STREAM
              dlpOpenRead
              dlpOpenWrite
              dlpOpenExclusive
              dlpOpenSecret
              dlpOpenReadWrite
              dlpEndCodeNormal
              dlpEndCodeOutOfMemory
              dlpEndCodeUserCan
              dlpEndCodeOther
              dlpRecAttrDeleted
              dlpRecAttrDirty
              dlpRecAttrBusy
              dlpRecAttrSecret
              dlpRecAttrArchived
              dlpDBFlagResource
              dlpDBFlagReadOnly
              dlpDBFlagAppInfoDirty
              dlpDBFlagBackup
              dlpDBFlagOpen
              dlpDBFlagNewer
              dlpDBFlagReset
              dlpDBFlagCopyPrevention
              dlpDBFlagStream 
	      dlpDBListRAM
	      dlpDBListROM
);

# Other items we are prepared to export if requested
@EXPORT_OK = qw(
	CompareTm
);

# This AUTOLOAD is used to 'autoload' constants from the constant() XS
# function.  If a constant is not found then control is passed to the
# AUTOLOAD in AutoLoader.

sub AUTOLOAD {
    # This AUTOLOAD is used to 'autoload' constants from the constant()
    # XS function.

    my $constname;
    our $AUTOLOAD;
    ($constname = $AUTOLOAD) =~ s/.*:://;
    croak "&PDA::Pilot::constant not defined" if $constname eq 'constant';
    my ($error, $val) = constant($constname);
    if ($error) { croak $error; }
    {
        no strict 'refs';
        # Fixed between 5.005_53 and 5.005_61
#XXX    if ($] >= 5.00561) {
#XXX        *$AUTOLOAD = sub () { $val };
#XXX    }
#XXX    else {
            *$AUTOLOAD = sub { $val };
#XXX    }
    }
    goto &$AUTOLOAD;
}


bootstrap PDA::Pilot;
package PDA::Pilot::Block;

#####################################################################
#
# Generic functions for "blocks", i.e., chunks of data from a Pilot.
#
#####################################################################
sub new {
	my($self,$data) = @_;
	$self = bless {}, (ref($self) || $self);
	if (defined($data)) {
		$self->Unpack($data);
	} else {
		$self->Fill();
	}
	return $self;
}

#####################################################################
#
# Translate a "packed" block of binary data into a decent Perl 
# representation
#
#####################################################################
sub Unpack {
	my($self,$data) = @_;
	$self->{raw} = $data;
}


#####################################################################
#
# Translate a Perl representation of a data block into a string of 
# binary data
#
#####################################################################
sub Pack {
	my($self) = @_;
	return $self->{raw};
}

#####################################################################
#
# Just copy the "raw" item straight through
#
#####################################################################
sub Raw {
	my($self) = @_;
	return $self->{raw};
}

#####################################################################
#
# Fill in a block with default Perl data
#
#####################################################################
sub Fill {

}

#####################################################################
#
# Copy a block
#
#####################################################################
sub Clone {
	my($self) = @_;
	my($k,$v);
	my($new) = bless {}, ref($_);
	for (($k,$v) = each %$self) { $new->{$k} = $v }
	$new;
}

package PDA::Pilot::Record;

#####################################################################
#
# A class to represent generic database records
#
#####################################################################
@ISA = qw(PDA::Pilot::Block);

sub new {
	my($self,$data,$id,$attr,$cat,$index) = @_;

      $index = 0 unless defined($index);
      $id = 0 unless defined($id);
      $attr = 0 unless defined($attr);
      $cat = "" unless defined($cat);

	$self = bless { 
		"index" => $index,
		id => $id,
		deleted => !!($attr & 0x80),
		modified => !!($attr & 0x40),
		busy => !!($attr & 0x20),
		secret => !!($attr & 0x10),
		archived => !!($attr & 0x08),
		category => $cat}, 
		(ref($self) || $self);
	if (defined($data)) {
		$self->Unpack($data);
	} else {
		$self->Fill();
	}
	return $self;
}

package PDA::Pilot::Resource;

#####################################################################
#
# A class to represent generic database resources
#
#####################################################################
@ISA = qw(PDA::Pilot::Block);

sub new {
	my($self,$data,$index,$type,$id) = @_;
	$self = bless { "index" => $index, type => $type, id => $id}, 
		(ref($self) || $self);
	if (defined($data)) {
		$self->Unpack($data);
	} else {
		$self->Fill();
	}
	return $self;
}

package PDA::Pilot::AppBlock;

#####################################################################
# A class to represent generic application-information blocks
#####################################################################
@ISA = qw(PDA::Pilot::Block);

package PDA::Pilot::SortBlock;

#####################################################################
# A class to represent generic sort-information blocks
#####################################################################
@ISA = qw(PDA::Pilot::Block);

package PDA::Pilot::Pref;

#####################################################################
# A class to represent generic preference blocks
#####################################################################
@ISA = qw(PDA::Pilot::Block);

sub new {
	my($self,$data,$creator,$id,$version,$backup) = @_;
	$self = bless { creator => $creator, id => $id, version => $version, backup => $backup}, 
		(ref($self) || $self);
	if (defined($data)) {
		$self->Unpack($data);
	} else {
		$self->Fill();
	}
	return $self;
}

package PDA::Pilot::MemoRecord;

#####################################################################
# A class to represent records of the Memo application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return $self->{raw} = PDA::Pilot::Memo::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Memo::Unpack($self);
}

package PDA::Pilot::MemoAppBlock;

#####################################################################
# A class to represent records of the Memo application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Memo::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Memo::UnpackAppBlock($self);
}

package PDA::Pilot::ToDoRecord;

#####################################################################
# A class to represent records of the ToDo application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return $self->{raw} = PDA::Pilot::ToDo::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::ToDo::Unpack($self);
}

package PDA::Pilot::ToDoAppBlock;

#####################################################################
# A class to represent the app block of the ToDo application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::ToDo::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::ToDo::UnpackAppBlock($self);
}

package PDA::Pilot::AddressRecord;

#####################################################################
# A class to represent records of the Address application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return $self->{raw} = PDA::Pilot::Address::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Address::Unpack($self);
}

package PDA::Pilot::AddressAppBlock;

#####################################################################
# A class to represent the app block of the Address application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Address::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Address::UnpackAppBlock($self);
}

package PDA::Pilot::AppointmentRecord;

#####################################################################
# A class to represent records of the Appointment application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Appointment::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Appointment::Unpack($self);
}

package PDA::Pilot::AppointmentAppBlock;

#####################################################################
# A class to represent the app block of the Appointment application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Appointment::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Appointment::UnpackAppBlock($self);
}

package PDA::Pilot::MailRecord;

#####################################################################
# A class to represent records of the Mail application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Mail::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Mail::Unpack($self);
}

package PDA::Pilot::MailAppBlock;

#####################################################################
# A class to represent the app block of the Mail application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Mail::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Mail::UnpackAppBlock($self);
}

package PDA::Pilot::MailSyncPref;

#####################################################################
# A class to represent the sync pref of the Mail application
#####################################################################
@ISA = qw(PDA::Pilot::Pref);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Mail::PackSyncPref($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Mail::UnpackSyncPref($self);
}

package PDA::Pilot::MailSignaturePref;

#####################################################################
# A class to represent the signature pref of the Mail application
#####################################################################
@ISA = qw(PDA::Pilot::Pref);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Mail::PackSignaturePref($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Mail::UnpackSignaturePref($self);
}

package PDA::Pilot::ExpenseRecord;

#####################################################################
# A class to represent records of the Expense application
#####################################################################
@ISA = qw(PDA::Pilot::Record);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Expense::Pack($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Expense::Unpack($self);
}

package PDA::Pilot::ExpenseAppBlock;

#####################################################################
# A class to represent the app block of the Expense application
#####################################################################
@ISA = qw(PDA::Pilot::AppBlock);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Expense::PackAppBlock($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Expense::UnpackAppBlock($self);
}

package PDA::Pilot::ExpensePref;

#####################################################################
# A class to represent the pref of the Expense application
#####################################################################
@ISA = qw(PDA::Pilot::Pref);

sub Pack {
	my($self) = @_;
	return PDA::Pilot::Expense::PackPref($self);
}

sub Unpack {
	my($self, $data) = @_;
	$self->{raw} = $data;
	PDA::Pilot::Expense::UnpackPref($self);
}

package PDA::Pilot::Database;

#####################################################################
# A class to specify which classes are used for generic database entries
#####################################################################
sub record { shift @_; PDA::Pilot::Record->new(@_) }
sub resource { shift @_; PDA::Pilot::Resource->new(@_) }
sub pref { shift @_; PDA::Pilot::Pref->new(@_) }
sub appblock { shift @_; PDA::Pilot::AppBlock->new(@_) }
sub sortblock { shift @_; PDA::Pilot::SortBlock->new(@_) }

package PDA::Pilot::MemoDatabase;

#####################################################################
# A class to specify which classes are used for Memo database entries
#####################################################################
@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::MemoRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::MemoAppBlock->new(@_) }
sub creator { 'memo' }
sub dbname { 'MemoDB' }

package PDA::Pilot::ToDoDatabase;

@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::ToDoRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::ToDoAppBlock->new(@_) }
sub creator { 'todo' }
sub dbname { 'ToDoDB' }

package PDA::Pilot::AppointmentDatabase;

@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::AppointmentRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::AppointmentAppBlock->new(@_) }
sub creator { 'date' }
sub dbname { 'DatebookDB' }

package PDA::Pilot::AddressDatabase;

@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::AddressRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::AddressAppBlock->new(@_) }
sub creator { 'addr' }
sub dbname { 'AddressDB' }

package PDA::Pilot::MailDatabase;

@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::MailRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::MailAppBlock->new(@_) }
sub pref {
	shift @_;
	my($data,$creator,$id) = @_;
	if (($id == 1) || ($id == 2)) {
		PDA::Pilot::MailSyncPref->new(@_);
	} elsif ($id == 3) {
		PDA::Pilot::MailSignaturePref->new(@_);
	} else {
		PDA::Pilot::Database->pref(@_);
	}
}
sub creator { 'mail' }
sub dbname { 'MailDB' }

package PDA::Pilot::ExpenseDatabase;

@ISA=qw(PDA::Pilot::Database);

sub record { shift @_; PDA::Pilot::ExpenseRecord->new(@_) }
sub appblock { shift @_; PDA::Pilot::ExpenseAppBlock->new(@_) }
sub pref {
	shift @_;
	my($data,$creator,$id) = @_;
	if ($id == 1) {
		PDA::Pilot::ExpensePref->new(@_);
	} else {
		PDA::Pilot::Database->pref(@_);
	}
}
sub creator { 'exps' }
sub dbname { 'ExpenseDB' }

package PDA::Pilot;

%DBClasses = (	MemoDB => 'PDA::Pilot::MemoDatabase',
				ToDoDB => 'PDA::Pilot::ToDoDatabase',
				AddressDB => 'PDA::Pilot::AddressDatabase',
				DatebookDB => 'PDA::Pilot::AppointmentDatabase',
				MailDB => 'PDA::Pilot::MailDatabase',
				ExpenseDB => 'PDA::Pilot::ExpenseDatabase'
				);
%PrefClasses = (	memo => 'PDA::Pilot::MemoDatabase',
				todo => 'PDA::Pilot::ToDoDatabase',
				mail => 'PDA::Pilot::MailDatabase',
				date => 'PDA::Pilot::AppointmentDatabase',
				addr => 'PDA::Pilot::AddressDatabase',
				exps => 'PDA::Pilot::ExpenseDatabase'
				);

#####################################################################
# Default classes
#####################################################################
$DBClasses{''} = 'PDA::Pilot::Database';
$PrefClasses{''} = 'PDA::Pilot::Database';

sub CompareTm {
	my(@a) = @{$_[0]};
	my(@b) = @{$_[1]};
	return ($a[5] <=> $b[5]) || ($a[4] <=> $b[4]) || ($a[3] <=> $b[3]) ||
	       ($a[2] <=> $b[2]) || ($a[1] <=> $b[1]) || ($a[0] <=> $b[0]);
}

#####################################################################
# Autoload methods go after __END__, and are processed by the 
# autosplit program.
#####################################################################

1;
__END__

=head1

Commands include:

B<Notice!> This information is out of date, and potentially quite
misleading.

=over 4

=item PDA::Pilot::Appointment::Unpack(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given a record from a .pdb file or a Pilot database.

=item PDA::Pilot::Appointment::Pack(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database.

=item PDA::Pilot::Appointment::UnpackAppInfo(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given the AppInfo record from a .pdb file or a Pilot database.

=item PDA::Pilot::Appointment::PackAppInfo(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database AppInfo block.

=item PDA::Pilot::Memo::Unpack(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given a record from a .pdb file or a Pilot database.

=item PDA::Pilot::Memo::Pack(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database.

=item PDA::Pilot::Memo::UnpackAppInfo(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given the AppInfo record from a .pdb file or a Pilot database.

=item PDA::Pilot::Memo::PackAppInfo(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database AppInfo block.

=item PDA::Pilot::ToDo::Unpack(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given a record from a .pdb file or a Pilot database.

=item PDA::Pilot::ToDo::Pack(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database.

=item PDA::Pilot::ToDo::UnpackAppInfo(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given the AppInfo record from a .pdb file or a Pilot database.

=item PDA::Pilot::ToDo::PackAppInfo(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database AppInfo block.

=item PDA::Pilot::Address::Unpack(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given a record from a .pdb file or a Pilot database.

=item PDA::Pilot::Address::Pack(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database.

=item PDA::Pilot::Address::UnpackAppInfo(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given the AppInfo record from a .pdb file or a Pilot database.

=item PDA::Pilot::Address::PackAppInfo(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database AppInfo block.

=item PDA::Pilot::Mail::Unpack(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given a record from a .pdb file or a Pilot database.

=item PDA::Pilot::Mail::Pack(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database.

=item PDA::Pilot::Mail::UnpackAppInfo(buffer) 

Returns hash reference containing appointment (datebook entry) in a usable
format, given the AppInfo record from a .pdb file or a Pilot database.

=item PDA::Pilot::Mail::PackAppInfo(buffer) 

Given a hash reference in the form that the previous call generates, returns 
a single string suitable for storing in a Pilot's database AppInfo block.

=item PDA::Pilot::Socket::socket(domain, type, protocol)

Same as pi-link routine called pi_socket.

=item PDA::Pilot::Socket::close(socket)

Same as pi-link routine called pi_close.

=item PDA::Pilot::Socket::write(socket, string)

Same as pi-link routine called pi_write.

=item PDA::Pilot::Socket::read(socket, len)

Same as pi-link routine called pi_write (returns read data as result.)

=item PDA::Pilot::Socket::listen(socket, backlog)

Same as pi-link routine called pi_listen.

=item PDA::Pilot::Socket::bind(socket, sockaddr)

Same as pi-link routine called pi_bind. Sockaddr may either be a packed
string containing a pi_sockaddr structure, or a hash reference containing
"device", "family", and "port" keys.

=item PDA::Pilot::Socket::accept(socket)

Same as pi-link routine called pi_accept. If connection is successfull, returns
reference to hash containing remote address, as described above. If failed, returns
undef.

=item PDA::Pilot::DLP::errno()

Returns last DLP error, resetting error to zero.

=item PDA::Pilot::DLP::GetSysDateTime(socket)

Same as DLP call dlp_GetSysDateTime. If successfull, returns time, otherwise
returns undef.

=item PDA::Pilot::DLP::SetSysDateTime(socket, time)

Same as DLP call dlp_SetSysDateTime. time must be a time_t value.

=item PDA::Pilot::DLP::ReadSysInfo(socket)

Same as DLP call dlp_ReadSysInfo. If successfull, returns reference to hash
containing system information.

=item PDA::Pilot::DLP::ReadStorageInfo(socket, cardno)

Same as DLP call dlp_ReadStorageInfo. If successfull, returns reference to hash
containing information on given memory card.

=item PDA::Pilot::DLP::ReadUserInfo(socket)

Same as DLP call dlp_ReadUserInfo. If successfull, returns reference to hash
containing information about user settings.

=item PDA::Pilot::DLP::WriteUserInfo(socket, info)

Same as DLP call dlp_WriteUserInfo. info must be a reference to a hash
containing data similar to that returned by ReadUserInfo (Note: the password
can not be set through this call.)

=item PDA::Pilot::DLP::OpenDB(socket, cardno, mode, name)

Same as DLP call dlp_OpenDB. If successfull returns database handle,
otherwise returns undef.

=item PDA::Pilot::DLP::CloseDB(socket, handle)

Same as DLP call dlp_CloseDB. 

=item PDA::Pilot::DLP::EndOfSync(socket, status)

Same as DLP call dlp_EndOfSync. 

=item PDA::Pilot::DLP::AbortSync(socket)

Same as DLP call dlp_AbortSync. 

=item PDA::Pilot::DLP::MoveCategory(socket, handle, fromcat, tocat)

Same as DLP call dlp_MoveCategory. 

=item PDA::Pilot::DLP::ResetSystem(socket)

Same as DLP call dlp_ResetSystem. 

=item PDA::Pilot::DLP::OpenConduit(socket)

Same as DLP call dlp_OpenConduit. 

=item PDA::Pilot::DLP::AddSyncLogEntry(socket, message)

Same as DLP call dlp_AddSyncLogEntry 

=item PDA::Pilot::DLP::CleanUpDatabase(socket, handle)

Same as DLP call dlp_CleanUpDatabase. 

=item PDA::Pilot::DLP::ResetSyncFlags(socket, handle)

Same as DLP call dlp_ResetSyncFlags. 

=item PDA::Pilot::DLP::ResetDBIndex(socket, handle)

Same as DLP call dlp_ResetDBIndex. 

=item PDA::Pilot::DLP::ResetLastSyncPC(socket)

Same as DLP call dlp_ResetLastSyncPC. 

=item PDA::Pilot::DLP::DeleteCategory(socket, handle, category)

Same as DLP call dlp_DeleteCategory. 

=item PDA::Pilot::DLP::DeleteRecord(socket, handle, all, id)

Same as DLP call dlp_DeleteRecord. 

=item PDA::Pilot::DLP::ReadDBList(socket, cardno, flags, start)

Same as DLP call dlp_ReadDBList. If successfull, returns reference
to hash containing DB information. If failed, returns undef.

=item PDA::Pilot::DLP::FindDBInfo(socket, cardno, flags, name, type, creator)

Same as DLP call dlp_FindDBInfo. If successfull, returns reference
to hash containing DB information. If failed, returns undef.

=item PDA::Pilot::DLP::ReadFeature(socket, creator, number)

Same as DLP call dlp_ReadFeature. If successfull, returns feature value. If
failed, returns undef.

=item PDA::Pilot::DLP::ReadAppBlock(socket, handle)

Same as DLP call dlp_ReadAppBlock. If successfull, returns app block. If
failed, returns undef.

=item PDA::Pilot::DLP::ReadSortBlock(socket, handle)

Same as DLP call dlp_ReadSortBlock. If successfull, returns app block. If
failed, returns undef.

=item PDA::Pilot::DLP::WriteAppBlock(socket, handle, block)

Same as DLP call dlp_WriteAppBlock.

=item PDA::Pilot::DLP::WriteSortBlock(socket, handle, block)

Same as DLP call dlp_WriteSortBlock.

=item PDA::Pilot::DLP::ReadOpenDBInfo(socket, handle)

Same as DLP call dlp_ReadOpenDBInfo.

=item PDA::Pilot::DLP::ReadRecordByIndex(socket, handle, index)

Same as DLP call dlp_ReadRecordByIndex. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, id, index, attr, and category, in that order.

=item PDA::Pilot::DLP::ReadRecordById(socket, handle, id)

Same as DLP call dlp_ReadRecordById. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, id, index, attr, and category, in that order.

=item PDA::Pilot::DLP::ReadNextModifiedRec(socket, handle)

Same as DLP call dlp_ReadNextModifiedRec. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, id, index, attr, and category, in that order.

=item PDA::Pilot::DLP::ReadNextRecInCategory(socket, handle, category)

Same as DLP call dlp_ReadNextRecInCategory. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, id, index, attr, and category, in that order.

=item PDA::Pilot::DLP::ReadNextModifiedRecInCategory(socket, handle, category)

Same as DLP call dlp_ReadNextModifiedRecInCategory. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, id, index, attr, and category, in that order.

=item PDA::Pilot::DLP::WriteRecord(socket, handle, record, id, attr, category)

Same as DLP call dlp_WriteRecord.

=item PDA::Pilot::DLP::ReadResourceByType(socket, handle, type, id)

Same as DLP call dlp_ReadResourceByType. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, type, id, and index, in that order.

=item PDA::Pilot::DLP::ReadResourceByIndex(socket, handle, index)

Same as DLP call dlp_ReadResourceByIndex. If call fails, it returns undef.
Otherwise, in scalar context it returns the read record, in array it returns
the record, type, id, and index, in that order.

=item PDA::Pilot::DLP::WriteResource(socket, handle, record, type, id)

Same as DLP call dlp_WriteResource.

=item PDA::Pilot::DLP::DeleteResource(socket, handle, all, type, id)

Same as DLP call dlp_DeleteResource.

=item PDA::Pilot::DLP::CallApplication(socket, creator, type, action, data)

Same as DLP call dlp_CallApplication.

=item PDA::Pilot::File::open(name)

Same as pi_file_open. Returns a PDA::Pilot::File object on success.

=item PDA::Pilot::File::close(file)

Same as pi_file_close.

=item PDA::Pilot::File::get_app_info(file)

Same as pi_file_get_app_info.

=item PDA::Pilot::File::get_sort_info(file)

Same as pi_file_get_sort_info.

=item PDA::Pilot::File::get_entries(file)

Same as pi_file_get_entries.

=item PDA::Pilot::File::read_resource(file, index)

Same as pi_file_read_resource. Returns (record, type, id, index).

=item PDA::Pilot::File::read_record(file, index)

Same as pi_file_read_record. Returns (record, id, index, attr, category).

=item PDA::Pilot::File::read_record_by_id(file, type, id)

Same as pi_file_read_record_by_id. Returns (record, id, index, attr, category).

=item PDA::Pilot::File::create(name, info)

Same as pi_file_create. Info is reference to hash containg dbinfo data.

=item PDA::Pilot::File::get_info(file)

Same as pi_file_get_info.

=item PDA::Pilot::File::set_info(file, info)

Same as pi_file_set_info.

=item PDA::Pilot::File::set_app_info(file, data)

Same as pi_file_set_app_info.

=item PDA::Pilot::File::set_sort_info(file, data)

Same as pi_file_set_sort_info.

=item PDA::Pilot::File::append_resource(file, data, type, id)

Same as pi_file_append_resource.

=item PDA::Pilot::File::append_record(file, data, attr, category, id)

Same as pi_file_append_record.

=item PDA::Pilot::File::install(file, socket, cardno)

Same as pi_file_install.

=item PDA::Pilot::File::retrieve(file, socket, cardno)

Same as pi_file_retrieve.

=back

=cut