public class SchemaUpgradeUtil extends Object
Modifier and Type | Method and Description |
---|---|
static String |
extractProperty(String content,
String propertyName,
String variableName,
String propertyPattern,
String defaultValue,
Map<String,String> newProperties)
Extracts a new property that was introduced to make a content type property more configurable by making a hard coded value
changeable.
|
public static String extractProperty(String content, String propertyName, String variableName, String propertyPattern, String defaultValue, Map<String,String> newProperties)
content
- the content type variable's content before upgradepropertyName
- the name of the new propertyvariableName
- the name of the variable that will be used in the contentpropertyPattern
- the regexp pattern to identify the property, must contain exactly one "(\w+)" for the actual value of
the new propertydefaultValue
- the default value for the new property if the actual value can not be found in the contentnewProperties
- map of new properties where the extracted property will be putCopyright © 2022 Apache Software Foundation. All rights reserved.