| 4 |
## $Id$ |
## $Id$ |
| 5 |
## -------------------------------------------------------------------------------- |
## -------------------------------------------------------------------------------- |
| 6 |
## $Log$ |
## $Log$ |
| 7 |
|
## Revision 1.4 2003/02/20 21:11:15 joko |
| 8 |
|
## renamed module |
| 9 |
|
## modified runtime namespace hierarchy |
| 10 |
|
## |
| 11 |
|
## Revision 1.3 2003/02/14 14:18:36 joko |
| 12 |
|
## + new get-/setter-methods |
| 13 |
|
## |
| 14 |
## Revision 1.2 2003/02/11 09:48:57 joko |
## Revision 1.2 2003/02/11 09:48:57 joko |
| 15 |
## - moved notice output out of this module |
## - moved notice output out of this module |
| 16 |
## + some fixes |
## + some fixes |
| 29 |
#use base 'OEF::Component::Task'; |
#use base 'OEF::Component::Task'; |
| 30 |
use base qw( |
use base qw( |
| 31 |
DesignPattern::Object |
DesignPattern::Object |
| 32 |
DesignPattern::Object::Logger |
DesignPattern::Logger |
| 33 |
); |
); |
| 34 |
|
|
| 35 |
|
|
| 36 |
use Data::Dumper; |
use Data::Dumper; |
| 37 |
use Getopt::Long; |
use Getopt::Long; |
| 38 |
|
use Data::Transfer::Sync; |
| 39 |
|
|
| 40 |
|
|
| 41 |
# get logger instance |
# get logger instance |
| 60 |
exit; |
exit; |
| 61 |
} |
} |
| 62 |
|
|
| 63 |
sub getoptions { |
sub readoptions { |
| 64 |
my $self = shift; |
my $self = shift; |
| 65 |
|
|
| 66 |
GetOptions( |
GetOptions( |
| 79 |
); |
); |
| 80 |
} |
} |
| 81 |
|
|
| 82 |
|
sub getoptions { |
| 83 |
|
my $self = shift; |
| 84 |
|
return $self->{opt}; |
| 85 |
|
} |
| 86 |
|
|
| 87 |
|
sub setoptions { |
| 88 |
|
my $self = shift; |
| 89 |
|
my $options = shift; |
| 90 |
|
# FIXME: is this really true? |
| 91 |
|
$self->{opt} = $options; |
| 92 |
|
} |
| 93 |
|
|
| 94 |
sub getoptions_old { |
sub getoptions_old { |
| 95 |
my $self = shift; |
my $self = shift; |
| 96 |
GetOptions( |
GetOptions( |
| 184 |
#print Dumper($self); |
#print Dumper($self); |
| 185 |
#print Dumper($self); |
#print Dumper($self); |
| 186 |
#exit; |
#exit; |
| 187 |
|
|
| 188 |
|
# checks |
| 189 |
|
if (!$self->{app}->{storage}->{$self->{opt}->{source}}) { |
| 190 |
|
$logger->critical("Sync source storage handle undefined!"); |
| 191 |
|
} |
| 192 |
|
if (!$self->{app}->{storage}->{$self->{opt}->{target}}) { |
| 193 |
|
$logger->critical("Sync target storage handle undefined!"); |
| 194 |
|
} |
| 195 |
|
|
| 196 |
# configure the synchronization-object |
# configure the synchronization-object |
| 197 |
$sync->configure( |
$sync->configure( |
| 198 |
source => { |
source => { |
| 199 |
storage => { |
storage => { |
| 200 |
#handle => $mapiStorage, |
#handle => $mapiStorage, |
| 201 |
handle => $self->{app}->{$self->{opt}->{source}}, |
handle => $self->{app}->{storage}->{$self->{opt}->{source}}, |
| 202 |
#isIdentAuthority => $self->{app}->{config}->{{$self->{opt}->{source}}, |
#isIdentAuthority => $self->{app}->{config}->{{$self->{opt}->{source}}, |
| 203 |
#isChecksumAuthority => 1, |
#isChecksumAuthority => 1, |
| 204 |
#writeProtected => 1, |
#writeProtected => 1, |
| 207 |
target => { |
target => { |
| 208 |
storage => { |
storage => { |
| 209 |
#handle => $ldapStorage, |
#handle => $ldapStorage, |
| 210 |
handle => $self->{app}->{$self->{opt}->{target}}, |
handle => $self->{app}->{storage}->{$self->{opt}->{target}}, |
| 211 |
#idAuthority => 1, |
#idAuthority => 1, |
| 212 |
#isChecksumAuthority => 1, |
#isChecksumAuthority => 1, |
| 213 |
#isWriteProtected => 0, |
#isWriteProtected => 0, |