/** * Return base DN of this directory context */ @RemoteMethod public String getBaseDN() { return baseDN; }
@RemoteMethod public String processGeometry(JAXBElement<AbstractGeometryType> geometryElement) throws Exception { final StringWriter stringWriter = new StringWriter(); final Marshaller marshaller = context.createMarshaller(); marshaller.setProperty(Marshaller.JAXB_FORMATTED_OUTPUT, Boolean.TRUE); marshaller.marshal(geometryElement, stringWriter); return stringWriter.toString(); } }
@RemoteMethod public String getCurrentContainerProperty(String containerId, String propertyKey){ ContainerSystemInfo systemInfo = configuration.containerSystem; List<ContainerInfo> containerInfos = systemInfo.containers; for (ContainerInfo containerInfo : containerInfos) { containerId = replaceEscapes(containerId); if (containerInfo.id.equals(containerId)) { return containerInfo.properties.getProperty(propertyKey); } } return null; }
@RemoteMethod public CommandResult handleInput(String key, String formKey, List<ListItem> items, HttpServletRequest request, HttpServletResponse response) { Form form = (Form) request.getSession().getAttribute(formKey); return new CommandContextHandler(this, key, request) .handleDialogInput(form); }
/** * Returns the value of the given property. */ @RemoteMethod public String getText(String contentId, String property) { ContentMap content = Content.loadFragment(contentId); Object value = content.get(property); return value != null ? value.toString() : null; }
@Override @RemoteMethod public Point getSnapPoint(String layerId, double resolution, Point newCoordinate, HttpSession session) { return snappingResolverProvider.getSnappingResolver(layerId).getSnapPoint(resolution, newCoordinate); }
@RemoteMethod public String saveGeneratedPlan(HttpServletRequest request, String plan) { return getEarConfigData(request).setDeploymentPlan(plan); } /*@RemoteMethod
@RemoteMethod public ListModel getModel(String key, String expandedId, HttpServletRequest request) { return new ListModelBuilder(this, key, request).buildModel(expandedId); }
@RemoteMethod public List<CommandButton> getFormCommands(String key, ListItem item, HttpServletRequest request) { return new CommandContextHandler(this, key, request).createFormButtons(item); }
@RemoteMethod public CommandResult execCommand(String key, String commandId, List<ListItem> items, HttpServletRequest request, HttpServletResponse response) throws Exception { return new ChooserCommandHandler(this, key, request) .execCommand(commandId, items); }
@RemoteMethod public List<String> getEnabledCommands(String key, List<ListItem> items, HttpServletRequest request, HttpServletResponse response) { return new ChooserCommandHandler(this, key, request) .getEnabledCommands(items); }
@RemoteMethod public String setType(String componentId, String type) { Assert.notNull(componentId, "componentId must not be null"); Assert.notNull(type, "type must not be null"); Component component = Component.load(componentId); assertIsEditGranted(component); component.setType(type); return renderComponent(component); }
@RemoteMethod public Object execute( ServletContext servletContext, HttpServletRequest httpRequest, Execute request) throws IOException { try { return getWpsOperations(servletContext, httpRequest).execute(request); //ExecuteResponse } catch (OwsException e) { return e.getExceptionReport(); } }
@RemoteMethod public Object getCapabilities( ServletContext servletContext, HttpServletRequest httpRequest, GetCapabilities request) throws IOException { try { return getWpsOperations(servletContext, httpRequest).getCapabilities(request); //WPSCapabilitiesType } catch (OwsException e) { return e.getExceptionReport(); } }
@RemoteMethod public Object describeProcess( ServletContext servletContext, HttpServletRequest httpRequest, DescribeProcess request) throws IOException { try { return getWpsOperations(servletContext, httpRequest).describeProcess(request); //ProcessDescriptions } catch (OwsException e) { return e.getExceptionReport(); } }
@RemoteMethod public ListModel filter(String key, Map<String, String> filter, HttpServletRequest request) { return new ListModelBuilder(this, key, request) .filter(filter).buildModel(); }
@RemoteMethod public ListModel gotoPage(String key, int page, HttpServletRequest request) { return new ListModelBuilder(this, key, request) .gotoPage(page).buildModel(); }
@RemoteMethod public void moveComponent(String componentId, String prevComponentId) { Component component = Component.load(componentId); assertIsEditGranted(component); component.move(prevComponentId); nofifyUsers(); }
/** * Sets the given property to a new value. */ @RemoteMethod public void updateText(String contentId, String property, String text) { ContentMap content = Content.loadFragment(contentId); assertIsEditGranted(content); content.put(property, text); nofifyUsers(); }
/** * Performs a logout. */ @RemoteMethod public void logout() { WebContext ctx = WebContextFactory.get(); LoginManager.logout(ctx.getHttpServletRequest(), ctx.getHttpServletResponse()); }