Solved

spring annotation

Posted on 2012-03-29
2
388 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 35

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

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
web application structure 18 137
convert Absolute path to relative path of FTP location 7 51
Is there a Google Voice API? 9 75
Firefox and firebub 5 29
By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
Suggested Courses

710 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