I have a netbeans demo program with clasess and libraries the whole bit. I need to understand these lines of code because I need to click on the button I added:caputure the string in the jtextbox;put it into a query and put the resultset into a list and then display it .
right now the program does this but it has a query to get everything and display it. Can anyone give me a simple explination on the basic procedure to add a query and create a list. Because I do not understand how to use libraries and <propertyies> .

Please find enclosed some lines of code that I saw relevant to what I need to do but I can not find a way to alter it to do what I want

private javax.persistence.Query query;
setMessage("Fetching new data...");
                java.util.Collection data = query.getResultList();
                Thread.sleep(1300L); // remove for real app
                setProgress(4, 0, 4);
SearchTask(org.jdesktop.application.Application app) {
        searchList = org.jdesktop.observablecollections.ObservableCollections.observableList(query.getResultList());
        //public <PropertyType> get<PropertyName>();
entityManager = javax.persistence.Persistence.createEntityManagerFactory("splashbookdbPU").createEntityManager();
        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance(splashapp.SplashApp.class).getContext().getResourceMap(SplashView.class);
        query = entityManager.createQuery(resourceMap.getString("query.query")); // NOI18N
        list = org.jdesktop.observablecollections.ObservableCollections.observableList(query.getResultList());
9 Years
Discussion Span
Last Post by ceyesuma
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.