package DTS::Assignment::DataFile; =head1 NAME DTS::Assignment::DataFile - a class to represent a DTS DynamicPropertiesTaskAssignment object =head1 SYNOPSIS use warnings; use strict; use DTS::Application; use Test::More; use XML::Simple; my $xml = XML::Simple->new(); my $config = $xml->XMLin('test-config.xml'); my $app = DTS::Application->new($config->{credential}); my $package = $app->get_db_package( { id => '', version_id => '', name => $config->{package}, package_password => '' } ); foreach my $dyn_prop ( @{ $package->get_dynamic_props } ) { foreach my $assignment_prop ( @{ $dyn_prop->get_properties } ) { if ( $assignment_prop->get_type eq 'DataFile' ) { print $assignment_prop->to_string, "\n"; } } } =head1 DESCRIPTION C is a subclass of L superclass. It represents a DTS C object that has a C property defined. Unless you want to extend the C API is quite probably that you're going to use C returned by the C method from C class. =head2 EXPORT Nothing. =cut use 5.008008; use strict; use warnings; use base qw(DTS::Assignment); our $VERSION = '0.02'; =head2 METHODS Inherits all methods from C. =cut sub new { my $class = shift; my $self = $class->SUPER::new(@_); $self->{source} = $self->get_sibling()->SourceDataFileFileName(); return $self; } =head3 get_source Overrided method from L class. Returns a string containing the complete pathname plus filename from where the value will be fetched to set a destination. See L method for more information. =cut sub get_source { my $self = shift; return $self->{source}; } 1; __END__ =head1 SEE ALSO =over =item * L at C. =item * L at C. =item * MSDN on Microsoft website and MS SQL Server 2000 Books Online are a reference about using DTS' object hierarchy, but one will need to convert examples written in VBScript to Perl code. =back =head1 AUTHOR Alceu Rodrigues de Freitas Junior, Earfreitas@cpan.orgE =head1 COPYRIGHT AND LICENSE Copyright (C) 2006 by Alceu Rodrigues de Freitas Junior This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available. =cut