1 |
joko |
1.2 |
## ------------------------------------------------------------------------ |
2 |
joko |
1.3 |
## $Id: Outlook.pm,v 1.2 2003/01/19 03:32:39 joko Exp $ |
3 |
joko |
1.2 |
## ------------------------------------------------------------------------ |
4 |
joko |
1.3 |
## $Log: Outlook.pm,v $ |
5 |
|
|
## Revision 1.2 2003/01/19 03:32:39 joko |
6 |
|
|
## + new proposal for passing metadata-information to 'Data::Transfer::Sync' |
7 |
|
|
## |
8 |
joko |
1.2 |
## ------------------------------------------------------------------------ |
9 |
|
|
|
10 |
|
|
|
11 |
joko |
1.1 |
package Torus::Map::Outlook; |
12 |
|
|
|
13 |
|
|
use strict; |
14 |
|
|
use warnings; |
15 |
|
|
|
16 |
joko |
1.2 |
use base qw( DesignPattern::Object ); |
17 |
|
|
|
18 |
|
|
use Data::Transform::Map; |
19 |
|
|
use Data::Dumper; |
20 |
|
|
|
21 |
|
|
=pod |
22 |
|
|
sub Folder { |
23 |
|
|
my $self = shift; |
24 |
|
|
my $baseMap = shift; |
25 |
|
|
print Dumper($baseMap); |
26 |
|
|
exit; |
27 |
|
|
|
28 |
|
|
my $sourceFolder = $baseMap->{source}; |
29 |
|
|
my $targetFolder = $sourceFolder; |
30 |
|
|
print "Mapping MAPI-Folder \"$sourceFolder\" to LDAP-Folder \"$targetFolder\".", "\n"; |
31 |
|
|
} |
32 |
|
|
=cut |
33 |
joko |
1.1 |
|
34 |
|
|
|
35 |
|
|
sub ContactItem { |
36 |
|
|
return { |
37 |
joko |
1.2 |
|
38 |
|
|
metadata => { |
39 |
|
|
version => 0.2, |
40 |
|
|
syncMethod => 'checksum', |
41 |
|
|
}, |
42 |
|
|
|
43 |
|
|
# metadata on node-level |
44 |
|
|
source => { |
45 |
|
|
#nodeType => 'ContactItem', |
46 |
joko |
1.3 |
ident => 'property:EntryID', |
47 |
joko |
1.2 |
exclude => [qw( cs )], |
48 |
|
|
}, |
49 |
|
|
target => { |
50 |
|
|
#address => 'code:Folder', |
51 |
joko |
1.3 |
#ident => 'property:rid', |
52 |
|
|
ident => 'code:dn', |
53 |
|
|
autocreateFolders => 1, |
54 |
joko |
1.2 |
}, |
55 |
|
|
|
56 |
|
|
# metadata on field-level |
57 |
|
|
fieldmap => Data::Transform::Map->new( |
58 |
|
|
lookup => 'local', # local|dsn(csv|xml|ldap) |
59 |
|
|
rules => [ |
60 |
|
|
{ source => 'ckey', target => 'rkey' }, |
61 |
|
|
{ source => 'cname', target => 'rval' }, |
62 |
|
|
], |
63 |
|
|
), |
64 |
joko |
1.1 |
}; |
65 |
|
|
} |
66 |
|
|
|
67 |
|
|
1; |