org.codehaus.plexus.interpolation

Class PrefixedPropertiesValueSource

public class PrefixedPropertiesValueSource extends AbstractDelegatingValueSource implements QueryEnabledValueSource

Legacy support. Allow trimming one of a set of expression prefixes, the lookup the remaining expression as a literal key from the wrapped properties instance.
This is just a convenience implementation to provide a shorthand for constructing the properties value source and then wrapping it with a prefixed value-source wrapper.

Version: $Id: PrefixedPropertiesValueSource.java 7681 2008-08-22 20:34:22Z jdcasey $

Constructor Summary
PrefixedPropertiesValueSource(String prefix, Properties properties)
Wrap the specified properties file with a new PropertiesBasedValueSource, then wrap that source with a new PrefixedValueSourceWrapper that uses the specified expression prefix.
PrefixedPropertiesValueSource(List possiblePrefixes, Properties properties, boolean allowUnprefixedExpressions)
Wrap the specified properties file with a new PropertiesBasedValueSource, then wrap that source with a new PrefixedValueSourceWrapper that uses the specified expression-prefix list.
Method Summary
StringgetLastExpression()

Constructor Detail

PrefixedPropertiesValueSource

public PrefixedPropertiesValueSource(String prefix, Properties properties)
Wrap the specified properties file with a new PropertiesBasedValueSource, then wrap that source with a new PrefixedValueSourceWrapper that uses the specified expression prefix. Finally, set this wrapper source as a delegate for this instance to use.

Parameters: prefix The expression prefix to trim properties The properties instance to wrap

PrefixedPropertiesValueSource

public PrefixedPropertiesValueSource(List possiblePrefixes, Properties properties, boolean allowUnprefixedExpressions)
Wrap the specified properties file with a new PropertiesBasedValueSource, then wrap that source with a new PrefixedValueSourceWrapper that uses the specified expression-prefix list. Finally, set this wrapper source as a delegate for this instance to use.

Parameters: possiblePrefixes The expression-prefix list to trim properties The properties instance to wrap

Method Detail

getLastExpression

public String getLastExpression()
{@inheritDoc }
Copyright © 2001-2009 Codehaus. All Rights Reserved.