/** * This is a factory method for this Alpha Threshold configuration. * The factory method is a best practice for the case where the * actual object construction is changed in the future. * * @param threshold the threshold value for the alpha hashing option * * @return the actual type safe alpha threshold configuration. */ public static AlphaThresholdOption get( int threshold ) { return new AlphaThresholdOption( threshold ); }
return (T) PermGenThresholdOption.get( permGenThreshold ); } else if ( AlphaThresholdOption.class.equals( option ) ) { return (T) AlphaThresholdOption.get( alphaNodeHashingThreshold ); } else if ( CompositeKeyDepthOption.class.equals( option ) ) { return (T) CompositeKeyDepthOption.get( compositeKeyDepth );
public static KieBaseOption adaptOption(KnowledgeBaseOption option) { if (option instanceof org.drools.conf.AlphaThresholdOption) { org.drools.conf.AlphaThresholdOption legacyOption = (org.drools.conf.AlphaThresholdOption)option; return AlphaThresholdOption.get(legacyOption.getThreshold());
public static SingleValueKnowledgeBaseOption adaptOption(SingleValueKieBaseOption option) { if (option instanceof AlphaThresholdOption) { AlphaThresholdOption kieOption = (AlphaThresholdOption)option; return org.drools.conf.AlphaThresholdOption.get(kieOption.getThreshold());
setPermGenThreshold(((PermGenThresholdOption) option).getThreshold()); } else if ( option instanceof AlphaThresholdOption ) { setAlphaNodeHashingThreshold(((AlphaThresholdOption) option).getThreshold()); } else if ( option instanceof CompositeKeyDepthOption ) { setCompositeKeyDepth(((CompositeKeyDepthOption) option).getDepth());
/** * This is a factory method for this Alpha Threshold configuration. * The factory method is a best practice for the case where the * actual object construction is changed in the future. * * @param threshold the threshold value for the alpha hashing option * * @return the actual type safe alpha threshold configuration. */ public static AlphaThresholdOption get( int threshold ) { return new AlphaThresholdOption( threshold ); }
/** * This is a factory method for this Alpha Threshold configuration. * The factory method is a best practice for the case where the * actual object construction is changed in the future. * * @param threshold the threshold value for the alpha hashing option * * @return the actual type safe alpha threshold configuration. */ public static AlphaThresholdOption get( int threshold ) { return new AlphaThresholdOption( threshold ); }