Remove View from Group Example



Example Overview

Example name : RemoveViewFromGroup.java
Location : <Web NMS Home>/examples/Security/authorization directory

This example explains how to use the method "removeViewFromGroup()" and removes the given view from the respective group.

The interface used in this example is AuthorizationAdmin

Method used in this example is :

This method removes(disassociates) an AuthorizedView from a group.

Parameters: groupName - The name of the group from which the AuthorizedView is to be disassociated.
                   authorizedViewName - The authorizedViewName that is to be disassociated.
Throws: java.rmi.RemoteException - In case of RMI.
AuthorizationException - In case of null parameter, any exception or error during database operation.

Note : The source code will have comment statements in it which will explain to you the different segments of the program.

 

Integration with Web NMS

The steps given below will help you in integrating this example with Web NMS. If any of the steps given below are not followed properly, then the example might not function in a desired manner.

java  com.adventnet.nms.example.security.authorization.RemoveViewFromGroup  <group name>  <view name>

 

Sample Output

On giving a group name and view name as arguments to this example program, the output of the program printed in your console, will be : "Removed <view name> from  <group name>".

 

De-referencing

After you have tried this example, to remove its association with Web NMS, you must remove the class file RemoveViewFromGroup.class from <Web NMS Home>/classes/com/adventnet/nms/example/security/authorization directory.


Copyright © 1996-2002, AdventNet Inc. All Rights Reserved.