|
|||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | ||||||||
See:
Description
| Interface Summary | |
|---|---|
| IFTP |
This interface extends the IInfoObject and the IDestinationPlugin interfaces. |
| IFTPOptions |
The IFTPOptions object allows you to set the global or schedule options to an FTP location. |
This package provides an interface through which the destination options for FTP can be specified. Two types of options can be set for each destination: global and scheduling. Global options are the default settings for a particular job server. Scheduling options are the default settings for the destination plugin and can be copied to a report. When the report is run, the global and scheduling destination options are compared; the scheduling options override the global options.
Both the global and schedule options are set through the
corresponding object: the IDiskUnmanagedOptions object, IFtpOptions object, or
ISMTPOptions object. Set the global options by using the getPluginInterface() method of the
IJobServerDestination object to retrieve the destination plugin. Set the schedule
options by directly querying the APS InfoStore for the destination plugin. The
query returns the plugin's default object, through which you can access the
destination options object.
Note: Enable the destination with IJobServerDestination before a job for that destination is run.
The following example retrieves the FTP plugin:
IInfoObjects serverObjs = iStore.query( "SELECT SI_NAME, SI_SERVER_KIND FROM CI_SYSTEMOBJS WHERE
SI_PROGID='CrystalEnterprise.Server' AND SI_SERVER_KIND='jobserver'");
for (int i = 0; i < serverObjs.size(); i++)
{
IInfoObject obj = (IInfoObject) serverObjs.get(i);
IServer serverObj = (IServer) obj;
IJobServerAdmin jobServer = (IJobServerAdmin) serverObj.getServerAdmin();
IJobServerDestination[] jobServerDests = jobServer.getDestinations( iStore );
for ( int j = 0; j < jobServerDests.length; j++ )
{
IJobServerDestination jobServerDest = jobServerDests[ j ];
if ( jobServerDest.getName().equals( "CrystalEnterprise.Ftp" ) )
{
IFTPOptions ftpOptions = (IFTPOptions) jobServerDest.getPluginInterface();
}
}
}
The query method returns a collection of InfoObjects, which in this case are Server plugin objects.
Like other InfoObjects, these objects are uniquely represented by their ID property. For each object
in the collection, you can access general InfoObject properties, such as the SI_NAME property,
SI_DESCRIPTION property, and
SI_ID property.
The process for retrieving a destination plugin is as follows:
IInfoStore object for the job server objects.IFTPOptions object can be retrieved. This object allows you
to modify the properties of the ftp destination.
|
|||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | ||||||||