Package com.crystaldecisions.sdk.framework

This package implements the highest object model that branches off to the individual library implementations.

See:
          Description

Interface Summary
CeEnterpriseContext This interface specifies the system properties that BusinessObjects Enterprise expects to be set.
IEnterprisePrincipal  
IEnterpriseSession IEnterpriseSession is created when a user logs on to the application.
IEnterpriseSession.CeEnterpriseVersion Constants for the BusinessObjects Enterprise Version
ILanguageMgr This interface provides access to information about the locales that are supported and which locales (language packs) are installed for this deployment.
ISessionMgr This is the basic, top level client side object.
ITrustedPrincipal This interface represents a trusted principal object.
 

Class Summary
CrystalEnterprise The CrystalEnterprise class is the starting point for BusinessObjects Enterprise.
 

Package com.crystaldecisions.sdk.framework Description

This package implements the highest object model that branches off to the individual library implementations. It also contains the client-side security proxy code to deal with the APS. This package is hierarchically the highest-level package in the Crystal Enterprise SDK. It provides you with the primary entry point into Crystal Enterprise. The CrystalEnterprise class is the starting point, allowing you to get a session and log on to the system.

All the methods throw an exception if they fail. See com.crystaldecisions.sdk.exception for a list of errors and their descriptions.

View the Object Model Diagram.

Note: The only object that can be created dynamically is the ISessionMgr. This is done through calling the CrystalEnterprise object's static method getSessionMgr(). All other objects must be accessed through another object's methods or properties. In other words, the ISessionMgr is the source from which all other objects are eventually created.

Logging on and retrieving an Enterprise session

Before anything can be done within Crystal Enterprise, you must first log on and retrieve an Enterprise session. The following example demonstrates how to log on to an APS using preset properties using the secEnterprise authentication method:

  1. Set the user name and password for the Administrator account. This uses the default values that were created when Crystal Enterprise was installed.
        String user = "Administrator";
        String password = "";
        
  2. Set the name of the APS to log on to.
        String apsName = "APS";
        
  3. Set the authentication method to be used and initialize a variable to store any exceptions thrown.
        String apsAuthType = "secEnterprise";    
        SDKException failure = null;   
            
  4. Log on to the APS using the specified values. If the logon is successful, the Enterprise session will be retrieved.
        try
        {
            es = CrystalEnterprise.getSessionMgr().logon(
                    user,
                    password,
                    apsName,
                    apsAuthType);
        }
            
  5. Catch the exception thrown if the logon process failed.
        catch (SDKException error)
        {
            failure = error;
        }
        
  6. Display an error message if the logon failed.
        if (failure != null)
        {        
            out.println(failure);
        }
            
  7. Otherwise, if the logon was successful, set the enterprise session so that it can be retreived later.
        else
        {
            session.setAttribute("CE_Session", es);
        }
        
  8. Retrieve the InfoStore from the Enterprise session.
        IInfoStore iStore = (IInfoStore) es.getService("", "InfoStore");