Package org.jboss.dashboard.database.hibernate

Examples of org.jboss.dashboard.database.hibernate.HibernateTxFragment.execute()


                param.setPanelInstance(theInstance);
                session.saveOrUpdate(theInstance);
            }
        };
        try {
            txFragment.execute();
        } catch (Exception e) {
            log.error("Error:", e);
        }
    }
View Full Code Here


            protected void txFragment(Session session) throws Exception {
                session.saveOrUpdate(instance);
            }
        };

        txFragment.execute();
    }

    /**
     * Restores content from secondary storage
     *
 
View Full Code Here

                }
                session.setFlushMode(oldFlushMode);
            }
        };

        txFragment.execute();
        Collections.sort(elements);
    }

    /**
     * Reads zipped elements in a directory and deploys them all.
View Full Code Here

                HibernateTxFragment fragment = new HibernateTxFragment(true) {
                    public void txFragment(Session session) throws Exception {
                        deployZippedElement(elementZip, elementName);//Global for all workspaces.
                    }
                };
                fragment.execute();
            }
        }
    }

    /**
 
View Full Code Here

                    element.setLastModified(new Date());
                    session.save(element);
                }
            };

            txFragment.execute();
            elements.add(element);
            Collections.sort(elements);
        }
    }
View Full Code Here

                session.delete(section);
            }
        };

        txFragment.execute();
    }

    /**
     * Stores workspace section state in database
     */
 
View Full Code Here

                        workspace.setDefaultWorkspace(defaultWorkspace);
                        getWorkspacesManager().store(workspace);
                    }
                };

                txFragment.execute();
                MessagesComponentHandler.lookup().addMessage("ui.alert.workspaceEdition.OK");
            } catch (Exception e) {
                log.error("Error: ", e);
            }
        }
View Full Code Here

            }
        };


        try {
            txFragment.execute();
        } catch (Exception e) {
            log.error("Can't delete section " + section.getId(), e);
        }
    }
View Full Code Here

                        panelInstancesSet.remove(instance);
                        session.delete(instance);
                    }
                };

                txFragment.execute();
            } catch (Exception e) {
                log.error("Can't remove panel instance with id " + instance.getId(), e);
            }
        }
    }
View Full Code Here

                        UIServices.lookup().getSectionsManager().store(section);
                }
            }
        };

        txFragment.execute();
    }


    /**
     * Shows the screen for a new panel creation
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.