NAME
Siebel::COM::App::DataServer - Perl extension for connecting to a Siebel COM Data Server environment
SYNOPSIS
$sa = Siebel::COM::App::DataServer->new(
{
cfg => $cfg,
data_source => $datasource,
user => $user,
password => $password
}
);
my ( $bo, $bc, $key, $field, $moreResults );
$sa->login();
foreach $key ( keys(%$schema) ) {
$bo = $sa->get_bus_object($key);
$bc = $bo->get_bus_comp($key);
foreach $field ( @{ $schema->{$key} } ) {
$bc->activate_field($field);
}
$bc->clear_query();
$bc->query();
DESCRIPTION
Siebel::COM::App::DataServer is a subclass of Siebel::COM::App, providing access to the Siebel COM Data Server environment as well as additional functionality.
Additionally to all architecture differences from Siebel::COM::App::DataControl, this class have important difference about error treament: all method calls requires a Win32::OLE::Variant to be passed as a parameter for error checking, so all those procedures are executed internally.
To be able to do that, almost all methods inherited from Siebel::COM::App are overloaded or overrided and a specific role (Siebel::COM::Exception::DataServer) is applied.
Usually using Siebel::COM::App::DataControl is preferable since it is faster to load and execute and can multiplex connections to a Siebel Enterprise, but DataServer still have it's specific uses:
Provides CRUD operations in the Siebel Client local database.
Avoid object restrictions in the Siebel Repository by using a local modified SRF.
Avoid security restrictions applied to the Siebel Enterprise, like firewalls and authentication.
ATTRIBUTES
cfg
The complete path to the Siebel application configuration file. Required.
datasource
The datasource name as described in the file of cfg
attribute.
ole_class
Differently from the superclass, this attributes defaults to "SiebelDataServer.ApplicationObject". You probably don't want to change that, so this attribute is not required during object creation.
get_bus_object
Overrided from superclass.
Expects a Business Object name as parameter.
Returns a Siebel::COM::Business::Object::DataServer object. If the Business Object name does not exists in the repository, an exception is raised.
METHODS
BUILD
Additionally to the superclass operations, this method will call the load_objects
method automatically.
get_app_def
Returns a string as expected by the LoadObjects COM method from the ole_class
. It will validate if the cfg
can be read and will raise and exception in the case it cannot.
load_objects
Same as COM LoadObjects method, but adding the proper error checking.
EXPORT
None by default.
SEE ALSO
AUTHOR
Alceu Rodrigues de Freitas Junior, <arfreitas@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2012 of Alceu Rodrigues de Freitas Junior, <arfreitas@cpan.org>
This file is part of Siebel COM project.
Siebel COM is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
Siebel COM 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 General Public License for more details.
You should have received a copy of the GNU General Public License along with Siebel COM. If not, see <http://www.gnu.org/licenses/>.