Cisco Systems, Inc.

com.cisco.scabb.servconf.mgmt
Class SCABB

java.lang.Object
  extended by com.cisco.scabb.servconf.mgmt.SCABB

public class SCABB
extends java.lang.Object

SCABB supplies login and logout functions to the SCE. The handle returned by the login serves all of the Service Configuration and Subscriber API functions which directly affect the SCE.

See Also:
ServiceConfigApi

Method Summary
static void activateLicense(java.lang.String user, java.lang.String key)
          Deprecated. license is no longer required.
static void addNotificationListener(NotificationListener listener)
          Subscribes the specific SCABB notification listener to recieve notifications regarding all the operations performed by the SCABB API.
static void fireNotification(Notification notification)
          Used to send a notification to the listeners defined by the function addNotificationListener(NotificationListener)
static void fireNotification(java.lang.String msg)
          Fire a notification with the given message
static void fireWarningNotification(java.lang.String msg)
          Fire a warning notification with the given message
static java.io.InputStream getDefaultProtocolFamilies()
          Get the default protocol families for this class
static byte getLicenseType()
          Returns the license type
static boolean isAllowedFullyFunctionalMode()
          Deprecated. license system was deprecated
static boolean isServConfCompatibleWithLicense(ServiceConfig servConf)
          Deprecated. license system was deprecated
static ConnectionApi login(com.pcube.management.framework.client.SessionObject sessionObject)
          Connects to a device by using an existing SessionObject.
static ConnectionApi login(java.lang.String hostName, java.lang.String userName, java.lang.String password)
          Deprecated. use Cisco SM API instead
static ConnectionApi login(java.lang.String hostName, java.lang.String userName, java.lang.String password, byte deviceType)
          Connects to the SCE device.
static void logout(ConnectionApi connectionApi)
          Disconnects from the SCE.
static void removeNotificationListener(NotificationListener listener)
          Unsubscribes the SCABB listener from recieving notifications regarding SCABB API operations.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

login

public static ConnectionApi login(java.lang.String hostName,
                                  java.lang.String userName,
                                  java.lang.String password)
                           throws ConnectionFailedException
Deprecated. use Cisco SM API instead

Connects to the SCABB SM. The function returns a handle which is used by all the API functions which affect the SM. Every login action must be closed with a logout(ConnectionApi) action.

Parameters:
hostName - the SM host address
userName - the user name
password - the password
Returns:
the connection which is a handle passed to all the API functions
Throws:
ConnectionFailedException - if the login failed. The failure reason can be retrieved from the ConnectionFailedException.

login

public static ConnectionApi login(java.lang.String hostName,
                                  java.lang.String userName,
                                  java.lang.String password,
                                  byte deviceType)
                           throws ConnectionFailedException
Connects to the SCE device. The function returns a handle which is used by all the API functions which affect the device.
Use device type Connection.SE_DEVICEto connect to the SCE.
Every login action must be closed with a logout(ConnectionApi)action.

Parameters:
hostName - the device host address
userName - the user name
password - the password
deviceType - the device type
Returns:
the connection which is a handle passed to all the API functions
Throws:
ConnectionFailedException - if the login failed. The failure reason can be retrieved from the ConnectionFailedException.

login

public static ConnectionApi login(com.pcube.management.framework.client.SessionObject sessionObject)
Connects to a device by using an existing SessionObject. The function returns a handle which is used by all the API functions which affect the device. Every login action must be closed with a logout(ConnectionApi)action.

Parameters:
sessionObject - the SessionObject to the SCE device
Returns:
the connection which is a handle passed to all the API functions

logout

public static void logout(ConnectionApi connectionApi)
Disconnects from the SCE. The connection is no longer useful after this function is called.

Parameters:
connection - the connection which keeps a handle to the connection to the SCE

activateLicense

public static void activateLicense(java.lang.String user,
                                   java.lang.String key)
                            throws java.lang.IllegalArgumentException
Deprecated. license is no longer required.

Sets the SCABB API client to be an active one, that is, enabling the client to change the SCABB system to have licensed abilities. Notice that the active mode is an atribute of the client and not of the Service Configuration. For a unique registration key please contact your Cisco representative.

Parameters:
user - the user name
key - the user's unique key
Throws:
java.lang.IllegalArgumentException - if the registration key is invalid

getLicenseType

public static byte getLicenseType()
Returns the license type

Returns:
the license-type as byte
See Also:
Engage.LICENSE_VIEW, Engage.LICENSE_CAPACITY_CONTROL, Engage.LICENSE_TIERED_CONTROL

addNotificationListener

public static void addNotificationListener(NotificationListener listener)
Subscribes the specific SCABB notification listener to recieve notifications regarding all the operations performed by the SCABB API. The listener must implement the NotificationListener interface.

Parameters:
listener - the NotificationListener

removeNotificationListener

public static void removeNotificationListener(NotificationListener listener)
Unsubscribes the SCABB listener from recieving notifications regarding SCABB API operations. The removed listener will not recieve any more notifications.

Parameters:
listener - the NotificationListener to be removed
Throws:
java.lang.IllegalArgumentException - if the listener was never subscribed to listen to SCABB notifications

fireNotification

public static void fireNotification(Notification notification)
Used to send a notification to the listeners defined by the function addNotificationListener(NotificationListener)

Parameters:
notification - the notification to be sent

isServConfCompatibleWithLicense

public static boolean isServConfCompatibleWithLicense(ServiceConfig servConf)
Deprecated. license system was deprecated

Checks if a given Service Configuration can be handled by the the current license

Parameters:
servConf - the Service Configuration to check
Returns:
true or false

isAllowedFullyFunctionalMode

public static boolean isAllowedFullyFunctionalMode()
Deprecated. license system was deprecated

Checks if the license allows working in fully-functional system mode.

Returns:
true if the license allows fully-functional mode

fireNotification

public static void fireNotification(java.lang.String msg)
Fire a notification with the given message

Parameters:
msg - the notification message to be sent

fireWarningNotification

public static void fireWarningNotification(java.lang.String msg)
Fire a warning notification with the given message

Parameters:
msg - the notification message to be sent

getDefaultProtocolFamilies

public static java.io.InputStream getDefaultProtocolFamilies()
Get the default protocol families for this class

Returns:
an InputStream of the protocol families
See Also:
Class.getResourceAsStream(java.lang.String)

Cisco Systems, Inc.

Copyright © 2013 Cisco Systems, Inc. Confidential.