/** * This is to be used only in the case where this process is a member of * one and only one group and the group name is unknown to the caller. * @return GroupManagementService * @throws GMSException - wraps a throwable GMSNotInitializedException if * there are no GMS instances found. */ public static GroupManagementService getGMSModule() throws GMSException { GroupManagementService gms; final Collection instances = getAllGMSInstancesForMember(); if(instances.size() == 0){ throw new GMSNotInitializedException(sm.get("ex.init.failure")); } gms = (GroupManagementService)instances.toArray()[0]; return gms; }
/** * This is to be used only in the case where this process is a member of * one and only one group and the group name is unknown to the caller. * @return GroupManagementService * @throws GMSException - wraps a throwable GMSNotInitializedException if * there are no GMS instances found. */ public static GroupManagementService getGMSModule() throws GMSException { GroupManagementService gms; final Collection instances = getAllGMSInstancesForMember(); if(instances.size() == 0){ throw new GMSNotInitializedException(sm.get("ex.init.failure")); } gms = (GroupManagementService)instances.toArray()[0]; return gms; }