本文介绍了在STS 4中启用Spring Project Nature来修复XML模式问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试采用,将会有一个Spring Tools上下文菜单,可以在该菜单上执行"Spring Tools->添加Spring项目性质" .我没有看到该菜单:

I'm trying to apply the solutions (proper XML schema resolution) mentioned here which requires me to enable Spring project nature in an existing project in STS 4. According to this, there would be a Spring Tools context menu on which one can do "Spring Tools -> Add Spring Project Nature". I'm not seeing that menu:

我的.project文件已经具有以下内容:

My .project file has the following already:

<natures>
        <nature>org.springframework.ide.eclipse.core.springnature</nature>
        <nature>org.eclipse.jdt.core.javanature</nature>
        <nature>org.eclipse.m2e.core.maven2Nature</nature>
        <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
    </natures>

我想念什么?

更新:

根据马丁的第二句话,以下作品:

As per Martin's second comment, the following works:

<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"
    xmlns:int="http://www.springframework.org/schema/integration"
    xmlns:int-jdbc="http://www.springframework.org/schema/integration/jdbc"
    xmlns:jdbc="http://www.springframework.org/schema/jdbc"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
       http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
       http://www.springframework.org/schema/integration http://www.springframework.org/schema/integration/spring-integration-5.0.xsd
       http://www.springframework.org/schema/integration/jdbc http://www.springframework.org/schema/integration/jdbc/spring-integration-jdbc.xsd
       http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.0.xsd">

推荐答案

您所使用的STS4公共beta版中不再存在您所指的Spring Nature功能.因此,上下文菜单中不再有提供春季自然"的春季"部分.在STS4中不再不再需要它了.

The Spring Nature feature that you are referring to doesn't exist anymore in the STS4 public beta that you seem to use. Therefore there is no "Spring" section in the context-menu anymore that offers the Spring Nature. It is not simply not needed anymore in STS4.

这里的问题是:在STS4中,您到底想做什么?如果您希望看到它从STS3中恢复过来,并且在STS4中缺少某些奇怪的东西,那么您应该在 https://github.com/spring-projects/sts4/issues 并附加一个示例项目,该项目再现了潜在的问题.那么,我很乐意进行更详细的介绍.

The question here is: What exactly are you trying to do in STS4 that doesn't work? If something is strange and missing in STS4 that you would like to see it getting back from STS3, you should raise an issue at https://github.com/spring-projects/sts4/issues and attach a sample project that reproduces the underlying issue. I would be happy to take a more detailed look then.

作为一种解决方法,您可以返回并下载最新的STS 3.9.2发行版并从那里进行工作,它仍然包含所有旧功能.

As a workaround, you can go back and download the latest STS 3.9.2 distribution and work from there, it still has all the old features included.

这篇关于在STS 4中启用Spring Project Nature来修复XML模式问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-22 07:15