|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AddressBookManager
This interface provides all of the basic functions for managing ReportCaster's distribution list information. A DistributionElement specifies destination locations and burst values. It can be represented as a single line in an Address Book, containing the destination for ReportCaster output and the burst value, if any, associated with that destination. The following sample code shows the instantiation of an AddressBookManager object. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Copyright (c) 2004 Information Builders, Inc. All Rights Reserved. + + + + Information Builders offers sample API programs as a heuristic device. + + They are not intended, as is, for production use. Licensed users are + + welcome to alter and extend these samples and deploy them in other + + environments, or alternate configurations, as they see fit. + + Information Builders will support the documented functionality of + + its API classes and methods. However, Information Builders is not + + responsible for functionality or behavior of products built with + + its API unless the documented behavior of its discrete classes and + + methods is different than the actual results. + + + + Redistributions of IBI source code and documentation must be within + + the scope of the Information Builders Software License Agreement. + + + + ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ CasterManagedConnectionFactory managedConnectionFactory = new CasterManagedConnectionFactory(); managedConnectionFactory.setServerName(host);//the name of the server running the distribution server managedConnectionFactory.setPortNumber(port);//the port the distribution server is listening CasterConnectionFactory connectionFactory = (CasterConnectionFactory)managedConnectionFactory.createConnectionFactory(); ConnectionSpec credential = new PasswordCredential(user, password.toCharArray()); //This can be any of the credential objects. It is assumed here the user String has been assigned earlier // and that password, also assigned earlier, is a String that needs to be converted to a character Array. CasterConnection connectionObject = ((CasterConnection)connectionFactory.getConnection(credential)); AddressBookManager manager = connectionObject.getAddressBookManager();
AddrBook
,
DestinationElement
Method Summary | |
---|---|
void |
addAddressBook(AddrBook addrBook)
Creates an Address Book in the ReportCaster Repository. |
void |
addDestinationElement(java.lang.String bookName,
DestinationElement destinationElement)
Adds a DestinationElement to the Address Book specified by bookName. |
void |
deleteAddressBook(java.lang.String bookName)
Deletes the Address Book specified by bookName. |
void |
deleteDestinationElement(java.lang.String bookName,
DestinationElement destinationElement)
Deletes a DestinationElement from the Address Book specified by bookName. |
AddrBook |
getAddressBook(java.lang.String bookName)
Returns an AddrBook object specified by bookName. |
AddrBook[] |
getAddressBookPrivateList(java.lang.String method)
|
AddrBook[] |
getAddressBookPrivateListByCaller(java.lang.String method)
Returns an Array of PRIVATE AddrBook objects for both the given
distribution method and the caller who has authenticated. |
AddrBook[] |
getAddressBookPrivateListByOwner(java.lang.String owner,
java.lang.String method)
Returns an Array of PRIVATE AddrBook objects for a given
distribution method and the specified owner of the AddrBooks. |
AddrBook |
getAddressBookProperty(java.lang.String bookName)
Returns an AddrBook object specified by bookName. |
AddrBook[] |
getAddressBookPublicList(java.lang.String method)
Returns an Array of PUBLIC AddrBook objects for a given
distribution method. |
AddrBook[] |
getAddressBookPublicListByCaller(java.lang.String method)
Returns an Array of PUBLIC AddrBook objects for a given
distribution method and the caller who has authenticated. |
AddrBook[] |
getAddressBookPublicListByOwner(java.lang.String owner,
java.lang.String method)
Returns an Array of PUBLIC AddrBook objects for a given
distribution method and the specified owner of the Address Books. |
java.lang.String[] |
getOwnerList()
Retrieves the Address Book owner list as a String Array from the ReportCaster Repository. |
java.lang.String[] |
getOwnerList(java.lang.String method,
java.lang.String access)
|
void |
updateAddressBook(AddrBook addrBook)
Updates an Address Book's properties, deletes all existing distribution lists and inserts the new ones, which are represented by the DestinationElement Array stored in AddrBook . |
void |
updateAddressBookProperty(AddrBook addrBook)
Address Book's properties in the ReportCaster Repository. |
Method Detail |
---|
AddrBook[] getAddressBookPublicList(java.lang.String method) throws CasterException
AddrBook
objects for a given
distribution method. The distribution method is one of three String
constants: Distribution.EMAIL
, Distribution.PRINT
,
or Distribution.FTP
. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
If there are no PUBLIC Address Books for the specified distribution method,
an empty Array will be returned. If the specified distribution method is NULL,
all Address Books will be returned.
method
- The method of distribution as a String constant
AddrBook
objects.
CasterException
AddrBook[] getAddressBookPrivateList(java.lang.String method) throws CasterException
CasterException
AddrBook[] getAddressBookPublicListByCaller(java.lang.String method) throws CasterException
AddrBook
objects for a given
distribution method and the caller who has authenticated.
The distribution method is one of three String
constants: Distribution.EMAIL
, Distribution.PRINT
,
or Distribution.FTP
. If there are no PUBLIC Address Books for the specified
distribution method, an empty Array will be returned. If the specified distribution method is NULL,
all Address Books will be returned. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
method
- The method of distribution as a String constant.
AddrBook
objects.
CasterException
for all the methods values.
AddrBook[] getAddressBookPublicListByOwner(java.lang.String owner, java.lang.String method) throws CasterException
AddrBook
objects for a given
distribution method and the specified owner of the Address Books.
The distribution method is one of three String
Distribution.EMAIL
, Distribution.PRINT
. If there are no PUBLIC Address Books for the specified
distribution method, an empty Array will be returned. If the specified distribution method is NULL,
all Address Books will be returned. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
owner
- The owner of the Address Book as a String.method
- The method of distribution, as a String constant.
AddrBook
objects.
CasterException
AddrBook[] getAddressBookPrivateListByCaller(java.lang.String method) throws CasterException
AddrBook
objects for both the given
distribution method and the caller who has authenticated.
The distribution method is one of three String constants:
Distribution.EMAIL
, Distribution.PRINT
, or Distribution.FTP
. If there are no PUBLIC Address Books for the specified
distribution method, an empty Array will be returned. If the specified distribution method is NULL,
all Address Books will be returned. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
method
- The method of distribution, as a String constant.
This method is available only to the administrator and the Address Book owner.
AddrBook
objects.
CasterException
AddrBook[] getAddressBookPrivateListByOwner(java.lang.String owner, java.lang.String method) throws CasterException
AddrBook
objects for a given
distribution method and the specified owner of the AddrBooks.
The distribution method is one of three String
Distribution.EMAIL
, Distribution.PRINT
.
If there are no PUBLIC Address Books for the specified
distribution method, an empty Array will be returned. If the specified distribution method is NULL
all Address Books will be returned.
If the caller is an administrator, any owner may be specified. If the
caller is an End User, the user may specify his own userID.
Otherwise, an exception is thrown. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
This method is available only to the administrator and the Address Book owner.
owner
- The owner of the Address Book, as a String.method
- The method of distribution, as a String constant.
AddrBook
objects.
CasterException
AddrBook getAddressBookProperty(java.lang.String bookName) throws CasterException
AddrBook
object specified by bookName. For performance reasons,
the AddrBook objects returned by this method do not contain the distribution list.
This method is available only to the administrator and the Address Book owner.
bookName
- The name of the Address Book stored in the database, as a String.
CasterException
AddrBook getAddressBook(java.lang.String bookName) throws CasterException
AddrBook
object specified by bookName. The AddrBook objects
returned by this method contain distribution list information
in the form of a DestinationElement
Array.
This method is available only to the administrator and the Address Book owner.
bookName
- The name of the Address Book stored in the database, as a String.
CasterException
void addAddressBook(AddrBook addrBook) throws CasterException
AddrBook
may or may not
contain a DestinationElement
Array. All distribution lists
represented by the DestinationElement
Array will also be
inserted into the repository.
This method is available only to the administrator and the Address Book owner.
addrBook
- AddrBook object associated with the repository data that is to be added.
CasterException
void updateAddressBookProperty(AddrBook addrBook) throws CasterException
DestinationElement
Array.
This method is available only to the administrator and the Address Book owner.
addrBook
- AddrBook object containing the data that is to be updated in the repository.
CasterException
void updateAddressBook(AddrBook addrBook) throws CasterException
DestinationElement
Array stored in AddrBook
.
This method is available only to the administrator and the Address Book owner.
addrBook
- object containing the data that is to be updated in the repository.
CasterException
void deleteAddressBook(java.lang.String bookName) throws CasterException
bookName
- The name of the Address Book stored in the database, as a String.
CasterException
java.lang.String[] getOwnerList() throws CasterException
CasterException
java.lang.String[] getOwnerList(java.lang.String method, java.lang.String access) throws CasterException
CasterException
void addDestinationElement(java.lang.String bookName, DestinationElement destinationElement) throws CasterException
bookName
- The name of the Address Book stored in the database, as a String.destinationElement
- DestinationElement object containing the line in the Address Book that is to be
added.
CasterException
void deleteDestinationElement(java.lang.String bookName, DestinationElement destinationElement) throws CasterException
bookName
- The name of the Address Book stored in the database, as a String.destinationElement
- DestinationElement object containing the line in the Address Book that is to be
deleted.
CasterException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |