Solved

spring annotation

Posted on 2012-03-29
2
397 Views
Last Modified: 2012-04-08
hi guys

I am using this confirugation in my spring xml to handle annotation

<context:annotation-config/>
<context:component-scan base-package="com.mat.delegate" />


com.mat.delegate package has 10 delegates

DelegateOne.java
DelegateTwo.java
DelegateThree.java
DelegateFour.java
...
DelegateTen.java

If i want to load only DelegateOne.java and avoid the rest of the delegate classes, how can i do that? Do i use filters?

thanks
0
Comment
Question by:royjayd
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 36

Accepted Solution

by:
mccarl earned 500 total points
ID: 37785062
Try this ...

<context:component-scan base-package="com.mat.delegate" use-default-filters="false">
   <context:include-filter type="regex" expression=".*DelegateOne" />
</context:component-scan>

Open in new window

0
 

Author Comment

by:royjayd
ID: 37821928
thanks
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Are you developing a Java application and want to create Excel Spreadsheets? You have come to the right place, this article will describe how you can create Excel Spreadsheets from a Java Application. For the purposes of this article, I will be u…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question