Skip to content

Commit

Permalink
deprecate String based setFeature method, see #916
Browse files Browse the repository at this point in the history
  • Loading branch information
hennr committed Jan 4, 2023
1 parent 412eedc commit 846c623
Showing 1 changed file with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,19 @@
* Implementation of {@link FactoryBean} that creates a proxy that delegates invocation to one of two target beans depending on
* that state of a given feature.
* </p>
*
*
* <p>
* You can use the factory like this:
* </p>
*
*
* <pre>
* &lt;bean id="someService" class="org.togglz.spring.proxy.FeatureProxyFactoryBean"&gt;
* &lt;property name="feature" value=FEATURE_ONE /&gt;
* &lt;property name="active" ref="newServiceImpl" /&gt;
* &lt;property name="inactive" ref="oldServiceImpl" /&gt;
* &lt;/bean&gt;
* </pre>
*
*
* @author Christian Kaltepoth
*/
public class FeatureProxyFactoryBean implements FactoryBean<Object>, InitializingBean {
Expand Down Expand Up @@ -124,6 +124,10 @@ public String getFeature() {
return feature.name();
}

/**
* @deprecated use {@link org.togglz.spring.proxy.FeatureProxyFactoryBean#setFeature(Feature)} instead
*/
@Deprecated
public void setFeature(String feature) {
this.feature = new NamedFeature(feature);
}
Expand Down

0 comments on commit 846c623

Please sign in to comment.