Package org.drools.guvnor.client.rpc

Examples of org.drools.guvnor.client.rpc.PageRequest


        this.newUserCommand = newUserCommand;
        this.deleteUserCommand = deleteUserCommand;
        this.openSelectedCommand = openSelectedCommand;
        setDataProvider( new AsyncDataProvider<PermissionsPageRow>() {
            protected void onRangeChanged(HasData<PermissionsPageRow> display) {
                PageRequest request = new PageRequest();
                request.setStartRowIndex( pager.getPageStart() );
                request.setPageSize( pageSize );
                repositoryService.listUserPermissions( request,
                                                             new GenericCallback<PageResponse<PermissionsPageRow>>() {
                                                                 public void onSuccess(PageResponse<PermissionsPageRow> response) {
                                                                     updateRowCount( response.getTotalRowSize(),
                                                                                     response.isTotalRowSizeExact() );
View Full Code Here


        ServiceImplementation impl = getServiceImplementation();
        impl.createUser( "user1" );
        impl.createUser( "user2" );
        impl.createUser( "user3" );

        PageRequest requestPage1 = new PageRequest( 0,
                                                    PAGE_SIZE );
        PageResponse<PermissionsPageRow> responsePage1 = impl.listUserPermissions( requestPage1 );

        assertNotNull( responsePage1 );
        assertNotNull( responsePage1.getPageRowList() );

        System.out.println( "ListUserPermissionsFullResults-page1" );
        for ( PermissionsPageRow row : responsePage1.getPageRowList() ) {
            System.out.println( "--> Username = " + row.getUserName() );
        }

        assertEquals( 0,
                      responsePage1.getStartRowIndex() );
        assertEquals( PAGE_SIZE,
                      responsePage1.getPageRowList().size() );
        assertFalse( responsePage1.isLastPage() );

        PageRequest requestPage2 = new PageRequest( PAGE_SIZE,
                                                    PAGE_SIZE );
        PageResponse<PermissionsPageRow> responsePage2 = impl.listUserPermissions( requestPage2 );

        assertNotNull( responsePage2 );
        assertNotNull( responsePage2.getPageRowList() );
View Full Code Here

        ServiceImplementation impl = getServiceImplementation();
        impl.createUser( "user1" );
        impl.createUser( "user2" );
        impl.createUser( "user3" );

        PageRequest request = new PageRequest( 0,
                                               null );
        PageResponse<PermissionsPageRow> response;
        response = impl.listUserPermissions( request );

        assertNotNull( response );
View Full Code Here

        impl.cleanLog();
        impl.createUser( "user1" );
        impl.createUser( "user2" );
        impl.createUser( "user3" );

        PageRequest request = new PageRequest( 0,
                                               PAGE_SIZE );
        PageResponse<LogPageRow> response;
        response = impl.showLog( request );

        assertNotNull( response );
        assertNotNull( response.getPageRowList() );
        assertTrue( response.getStartRowIndex() == 0 );
        assertTrue( response.getPageRowList().size() == PAGE_SIZE );
        assertFalse( response.isLastPage() );

        request.setStartRowIndex( PAGE_SIZE );
        response = impl.showLog( request );

        assertNotNull( response );
        assertNotNull( response.getPageRowList() );
        assertTrue( response.getStartRowIndex() == PAGE_SIZE );
View Full Code Here

        impl.cleanLog();
        impl.createUser( "user1" );
        impl.createUser( "user2" );
        impl.createUser( "user3" );

        PageRequest request = new PageRequest( 0,
                                               null );
        PageResponse<LogPageRow> response;
        response = impl.showLog( request );

        assertNotNull( response );
View Full Code Here

                                           "testLoadArchivedAssetsCat",
                                           "testLoadArchivedAssetsPackage",
                                           AssetFormats.DRL );
        repositoryAssetService.archiveAsset( uuid3 );

        PageRequest request = new PageRequest( 0,
                                               PAGE_SIZE );
        PageResponse<AdminArchivedPageRow> response;
        response = repositoryAssetService.loadArchivedAssets( request );

        assertNotNull( response );
        assertNotNull( response.getPageRowList() );
        assertTrue( response.getStartRowIndex() == 0 );
        assertTrue( response.getPageRowList().size() == PAGE_SIZE );
        assertFalse( response.isLastPage() );

        request.setStartRowIndex( PAGE_SIZE );
        response = repositoryAssetService.loadArchivedAssets( request );

        assertNotNull( response );
        assertNotNull( response.getPageRowList() );
        assertTrue( response.getStartRowIndex() == PAGE_SIZE );
View Full Code Here

                                           "testLoadArchivedAssetsCat",
                                           "testLoadArchivedAssetsPackage",
                                           AssetFormats.DRL );
        repositoryAssetService.archiveAsset( uuid3 );

        PageRequest request = new PageRequest( 0,
                                               null );
        PageResponse<AdminArchivedPageRow> response;
        response = repositoryAssetService.loadArchivedAssets( request );

        assertNotNull( response );
View Full Code Here

TOP

Related Classes of org.drools.guvnor.client.rpc.PageRequest

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.