Package org.jabusuite.core.users.session

Examples of org.jabusuite.core.users.session.JbsUserGroupsRemote


    }

    @Override
    public void doDeleteJbsObject(JbsBaseObject jbsObject) throws Exception {
        try {
            JbsUserGroupsRemote groupManagement = (JbsUserGroupsRemote)ClientTools.getRemoteBean(JbsUserGroupsRemote.class);
            groupManagement.deleteDataset((JbsUserGroup)jbsObject);
        } catch (NamingException e) {
            throw new Exception(e);
        }
    }
View Full Code Here


    @Override
    public void doSave() throws EJbsObject {
        System.out.println("Saving data...");
        try {
            JbsUserGroupsRemote jbsUserGroups = (JbsUserGroupsRemote) ClientTools.getRemoteBean(JbsUserGroupsRemote.class);

            super.doSave();
            if (this.getDlgState() == DlgState.dsInsert) {
                System.out.println("Adding new entity");
                jbsUserGroups.createGroup(this.getUserGroup());
            } else if (this.getDlgState() == DlgState.dsEdit) {
                System.out.println("Saving existing entity " + this.getUserGroup().getId() + ".");
                jbsUserGroups.updateDataset(this.getUserGroup());
            }
            System.out.println("Entity saved.");

        } catch (NamingException e) {
            e.printStackTrace();
View Full Code Here

        load();
    }

    public void load() {
        try {
            JbsUserGroupsRemote userGroups = (JbsUserGroupsRemote) ClientTools.getRemoteBean(JbsUserGroupsRemote.class);
            this.setGroups(new ArrayList<JbsUserGroup>(userGroups.getDatasets("", "a.groupName", 0, 0)));
        } catch (Exception e) {
            e.printStackTrace();
        }

    }
View Full Code Here

        }
    }
   
    protected void importJobs(String fileName) {
        try {
            JbsUserGroupsRemote userGroups = (JbsUserGroupsRemote)ClientTools.getRemoteBean(JbsUserGroupsRemote.class);
            JbsUserGroup group = userGroups.findGroup("users");
           
            JobGroupsRemote jobGroups = (JobGroupsRemote)ClientTools.getRemoteBean(JobGroupsRemote.class);
            BufferedReader in = new BufferedReader(new FileReader(fileName));
            String zeile = null;
            while ((zeile = in.readLine()) != null) {
View Full Code Here

     */
    @Override
    public List<JbsBaseObject> getDataFromServer(int startIndex,
            int resultCount) {
        try {
            JbsUserGroupsRemote groups = (JbsUserGroupsRemote)ClientTools.getRemoteBean(JbsUserGroupsRemote.class);
            return groups.getDatasets(this.getFilter(), this.getOrderFields(), this.getUser(), this.getCompany(), startIndex, resultCount);

        } catch (Exception e) {
            logger.error("Error fetching users.", e);
            return null;
        }
View Full Code Here

     * @see org.jabusuite.client.datalist.LiveJbsObjectList#getListSize()
     */
    @Override
    public int getListSize() {
        try {
            JbsUserGroupsRemote groups = (JbsUserGroupsRemote)ClientTools.getRemoteBean(JbsUserGroupsRemote.class);
            return (int) groups.getDatasetCount(this.getFilter(), this.getUser(), this.getCompany());
        } catch (Exception e) {
            logger.error("Error fetching users.", e);
            return 0;
        }
    }
View Full Code Here

TOP

Related Classes of org.jabusuite.core.users.session.JbsUserGroupsRemote

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.