Spring custom namespaces with Maven -


I have written my custom namespace for a Spring based project, which I am working on. The project is made with Maven, and I will put my XSD files in the resource directory. The problem is that the spring schemas directory I need to define where I place my xsd file. In my dev environment this resource / schema / myschema.xsd will be. However, when I compile, the contents of the content are copied to target, not the target directory itself. So in the compiled code, I end up with the target / schema / myschema.xsd. What should my spring. Schemas file reference resource / schema / myschema.xsd? Or just schema / xsd?

thanks,

jeff

custom for spring When creating a name space, the spring.s. schemas file should be located in META-INF with an entry like this:

Http: // Www.springframework.org/schema/context/spring-context-2.5.xsd=org/springframework/context/config/spring-context-2.5.xsd

Your custom schema then Src / main / resources / org / springframework / context / config / should be added to the class of the project.

Any good IDE should be understood src / main / resources / as a source code folder and read the schema properly.

Note: I pulled this example from the spring-coat, just checked myself


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -