String resourceId = org.sipfoundry.sipxconfig.common.User.GROUP_RESOURCE_ID; Group g = m_settingDao.getGroupByName(resourceId, search.getByGroup());
Group g = m_settingDao.getGroupByName(GROUP_RESOURCE_ID, search.getByGroup());
    org.sipfoundry.sipxconfig.common.User[] search(UserSearch search) {        List users = Collections.EMPTY_LIST;        if (search == null) {            users = m_coreContext.loadUsers();        } else if (search.getByUserName() != null) {            org.sipfoundry.sipxconfig.common.User user = m_coreContext.loadUserByUserName(search.getByUserName());            if (user != null) {                users = Collections.singletonList(user);            }        } else if (search.getByFuzzyUserNameOrAlias() != null) {            users = m_coreContext.loadUsersByPage(search.getByFuzzyUserNameOrAlias(),                    null, 0, PAGE_SIZE, SORT_ORDER, true);                            warnIfOverflow(users, PAGE_SIZE);        } else if (search.getByGroup() != null) {            String resourceId = org.sipfoundry.sipxconfig.common.User.GROUP_RESOURCE_ID;            Group g = m_settingDao.getGroupByName(resourceId, search.getByGroup());            users = m_coreContext.loadUsersByPage(null, g.getId(), 0, PAGE_SIZE, SORT_ORDER, true);            warnIfOverflow(users, PAGE_SIZE);        }                return (org.sipfoundry.sipxconfig.common.User[])            users.toArray(new org.sipfoundry.sipxconfig.common.User[users.size()]);    }