Java Code Examples for org.apache.catalina.UserDatabase#createGroup()
The following examples show how to use
org.apache.catalina.UserDatabase#createGroup() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: MemoryUserDatabaseMBean.java From Tomcat7.0.67 with Apache License 2.0 | 6 votes |
/** * Create a new Group and return the corresponding MBean Name. * * @param groupname Group name of the new group * @param description Description of the new group */ public String createGroup(String groupname, String description) { UserDatabase database = (UserDatabase) this.resource; Group group = database.createGroup(groupname, description); try { MBeanUtils.createMBean(group); } catch (Exception e) { IllegalArgumentException iae = new IllegalArgumentException ("Exception creating group [" + groupname + "] MBean"); iae.initCause(e); throw iae; } return (findGroup(groupname)); }
Example 2
Source File: MemoryUserDatabaseMBean.java From tomcatsrc with Apache License 2.0 | 6 votes |
/** * Create a new Group and return the corresponding MBean Name. * * @param groupname Group name of the new group * @param description Description of the new group */ public String createGroup(String groupname, String description) { UserDatabase database = (UserDatabase) this.resource; Group group = database.createGroup(groupname, description); try { MBeanUtils.createMBean(group); } catch (Exception e) { IllegalArgumentException iae = new IllegalArgumentException ("Exception creating group [" + groupname + "] MBean"); iae.initCause(e); throw iae; } return (findGroup(groupname)); }
Example 3
Source File: MemoryUserDatabaseMBean.java From Tomcat8-Source-Read with MIT License | 5 votes |
/** * Create a new Group and return the corresponding MBean Name. * * @param groupname Group name of the new group * @param description Description of the new group * @return the new group object name */ public String createGroup(String groupname, String description) { UserDatabase database = (UserDatabase) this.resource; Group group = database.createGroup(groupname, description); try { MBeanUtils.createMBean(group); } catch (Exception e) { IllegalArgumentException iae = new IllegalArgumentException( "Exception creating group [" + groupname + "] MBean"); iae.initCause(e); throw iae; } return findGroup(groupname); }