Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.
deleted 1 character in body
Source Link
Andrea
  • 6.1k
  • 2
  • 31
  • 59

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: preffixprefix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: prefix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

added 9 characters in body
Source Link

Try this:

new ClassPathXmlApplicationContext("<b>file:</b>src/main/resources/beans.xml"); 

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("<b>file:</b>src/main/resources/beans.xml"); 

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

added 4 characters in body
Source Link
kleopatra
  • 51.6k
  • 28
  • 103
  • 220

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

new ClassPathXmlApplicationContext("<b>file:</b>src/main/resources/beans.xml"); 

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("file:src/main/resources/beans.xml");

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Try this:

new ClassPathXmlApplicationContext("<b>file:</b>src/main/resources/beans.xml"); 

file: preffix point to file system resources, not classpath.

file path can be relative or system (/home/user/Work/src...)

Source Link
Loading