@Override public void printPlanEndpoints() { this.init(); this.em.getTransaction().begin(); List<WSDLEndpoint> endpoints = null; Query queryWSDLEndpoint = this.em.createQuery("SELECT e FROM WSDLEndpoint e"); endpoints = queryWSDLEndpoint.getResultList(); this.em.getTransaction().commit(); StringBuilder builder = new StringBuilder(); String ls = System.getProperty("line.separator"); builder.append( "debug output for stored endpoints of management plans, flags: csarid, planid, ianame, porttype " + ls); for (WSDLEndpoint endpoint : endpoints) { builder.append( "endpoint: " + endpoint.getCSARId() + " " + endpoint.getPlanId() + " " + endpoint.getIaName() + " " + endpoint.getPortType() + ls); } CoreInternalEndpointServiceImpl.LOG.debug(builder.toString()); }
public void _endpoint_show_wsdl(CommandInterpreter commandInterpreter) { this.em.getTransaction().begin(); Query query = this.em.createQuery("SELECT e FROM WSDLEndpoint e"); @SuppressWarnings("unchecked") List<WSDLEndpoint> queryResults = query.getResultList(); for (WSDLEndpoint e : queryResults) { commandInterpreter.println("CSARId: " + e.getCSARId()); commandInterpreter.println("PortType: " + e.getPortType().toString()); commandInterpreter.println( "PlanId: " + (e.getPlanId() == null ? "" : e.getPlanId().toString())); commandInterpreter.println( "NodeTypeImpl: " + (e.getNodeTypeImplementation() == null ? "" : e.getNodeTypeImplementation().toString())); commandInterpreter.println("IaName: " + (e.getIaName() == null ? "" : e.getIaName())); commandInterpreter.println("URI: " + e.getURI().toString()); commandInterpreter.println(""); } this.em.getTransaction().commit(); }