Package org.drools.repository

Examples of org.drools.repository.PackageItem.updateDescription()


            p.checkout();
            // TODO: support rename package.
            // p.updateTitle(entry.getTitle());

            if (entry.getSummary() != null) {
                p.updateDescription(entry.getSummary());
            }
            // TODO: support LastContributor
            if (entry.getAuthor() != null) {
            }
View Full Code Here


    @Consumes({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
    public void updatePackageFromJAXB(@PathParam("packageName") String packageName, Package p) {
        try {
            PackageItem item = repository.loadPackage(packageName);
            item.checkout();
            item.updateDescription(p.getDescription());
            item.updateTitle(p.getTitle());
            /* TODO: add more updates to package item from JSON */
            item.checkin(p.getCheckInComment());
            repository.save();
        } catch (Exception e) {
View Full Code Here

        ServiceImplementation impl = getServiceImplementation();
        RulesRepository repo = impl.getRulesRepository();

        PackageItem pkg = repo.loadPackage( nm );
        pkg.updateDescription( System.currentTimeMillis() + "" );
        pkg.checkin( "a change" );
        repo.logout();

    }
View Full Code Here

    private void updatePackage(String nm) throws Exception {
        System.err.println( "---> Updating the package " );
        RulesRepository repo = new RulesRepository( session );
        PackageItem pkg = repo.loadPackage( nm );
        pkg.updateDescription( System.currentTimeMillis() + "" );
        pkg.checkin( "a change" );
        repo.logout();

    }
View Full Code Here

                item );
        updateCategoryRules( data,
                item );

        item.updateExternalURI( data.getExternalURI() );
        item.updateDescription( data.getDescription() );
        item.archiveItem( data.isArchived() );
        item.updateBinaryUpToDate( false );
        if(!data.getFormat().equals("")) {
            item.updateFormat(data.getFormat());
        }
View Full Code Here

            if (!existingPackage.getTitle().equalsIgnoreCase(entry.getTitle())) {
                repository.renamePackage(existingPackage.getUUID(), entry.getTitle());
            }

            if (entry.getSummary() != null) {
                existingPackage.updateDescription(entry.getSummary());
            }
            // TODO: support LastContributor
            if (entry.getAuthor() != null) {
            }
View Full Code Here

            //Rename:
            if (!existingPackage.getTitle().equalsIgnoreCase(newPackage.getTitle())) {
                repository.renamePackage(existingPackage.getUUID(), newPackage.getTitle());
            }           

            existingPackage.updateDescription(newPackage.getDescription());

            /* TODO: add more updates to package item from JSON */
            String checkInComment = "";
            if (newPackage.getCheckInComment() != null) {
                checkInComment = newPackage.getCheckInComment();
View Full Code Here

            p.checkout();
            // TODO: support rename package.
            // p.updateTitle(entry.getTitle());

            if (entry.getSummary() != null) {
                p.updateDescription(entry.getSummary());
            }
            // TODO: support LastContributor
            if (entry.getAuthor() != null) {
            }
View Full Code Here

    @Consumes({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
    public void updatePackageFromJAXB(@PathParam("packageName") String packageName, Package p) {
        try {
            PackageItem item = rulesRepository.loadPackage(packageName);
            item.checkout();
            item.updateDescription(p.getDescription());
            item.updateTitle(p.getTitle());
            /* TODO: add more updates to package item from JSON */
            item.checkin(p.getCheckInComment());
            rulesRepository.save();
        } catch (Exception e) {
View Full Code Here

                                                      true ),
                                  convertMapToString( data.catRules,
                                                      false ) );

        item.updateExternalURI( data.externalURI );
        item.updateDescription( data.description );
        item.archiveItem( data.archived );
        item.updateBinaryUpToDate( false );
        this.ruleBaseCache.remove( data.uuid );
        item.checkin( data.description );
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.