public class VProperty extends Object
| Modifier and Type | Class and Description | 
|---|---|
| protected static class  | VProperty.Param | 
| protected static class  | VProperty.State | 
| Modifier and Type | Field and Description | 
|---|---|
| protected String | key | 
| protected static HashSet<String> | MULTIVALUED_PROPERTIES | 
| protected List<VProperty.Param> | params | 
| protected List<String> | values | 
| Constructor and Description | 
|---|
| VProperty(String line)Create VProperty from line. | 
| VProperty(String name,
         String value)Create VProperty for key and value. | 
| Modifier and Type | Method and Description | 
|---|---|
| protected void | addParam(String paramName) | 
| protected void | addParam(String paramName,
        List<String> paramValues) | 
| void | addParam(String paramName,
        String paramValue)Add param value on property. | 
| protected List<String> | addParamValue(List<String> paramValues,
             String value)Add value to paramValues and return list, create list if null. | 
| protected void | addValue(String value) | 
| protected void | appendMultilineEncodedValue(StringBuilder buffer,
                           String value)Append and encode \n to \\n in value. | 
| protected void | appendParamValues(StringBuilder buffer,
                 VProperty.Param param) | 
| protected boolean | containsIgnoreCase(List<String> stringCollection,
                  String value) | 
| protected String | decodeValue(String value) | 
| String | getKey()Property key, without optional parameters (e.g. | 
| protected VProperty.Param | getParam(String paramName) | 
| protected List<VProperty.Param> | getParams() | 
| String | getParamValue(String paramName)Return param value. | 
| String | getValue()Property value. | 
| List<String> | getValues()Property values. | 
| Map<String,String> | getValuesAsMap()Return property values as a map. | 
| boolean | hasParam(String paramName)Test if the property has a param named paramName. | 
| boolean | hasParam(String paramName,
        String paramValue)Test if the property has a param named paramName with given value. | 
| void | removeParam(String paramName)Remove param from property. | 
| void | removeValue(String value) | 
| void | setKey(String key)Set property key. | 
| void | setParam(String paramName,
        String paramValue)Set param value on property. | 
| protected void | setParams(List<VProperty.Param> params) | 
| protected void | setValue(String value) | 
| String | toString() | 
protected String key
protected List<VProperty.Param> params
public VProperty(String name, String value)
name - property namevalue - property valuepublic VProperty(String line)
line - card linepublic String getKey()
public String getValue()
public Map<String,String> getValuesAsMap()
public boolean hasParam(String paramName, String paramValue)
paramName - param nameparamValue - param valuepublic boolean hasParam(String paramName)
paramName - param namepublic void removeParam(String paramName)
paramName - param nameprotected boolean containsIgnoreCase(List<String> stringCollection, String value)
protected List<String> addParamValue(List<String> paramValues, String value)
paramValues - value listvalue - new valueprotected void addParam(String paramName)
public void setParam(String paramName, String paramValue)
paramName - param nameparamValue - param valuepublic void addParam(String paramName, String paramValue)
paramName - param nameparamValue - param valueprotected VProperty.Param getParam(String paramName)
public String getParamValue(String paramName)
paramName - param nameprotected List<VProperty.Param> getParams()
protected void setParams(List<VProperty.Param> params)
protected void setValue(String value)
protected void addValue(String value)
public void removeValue(String value)
public void setKey(String key)
key - property keyprotected void appendParamValues(StringBuilder buffer, VProperty.Param param)
protected void appendMultilineEncodedValue(StringBuilder buffer, String value)
buffer - line buffervalue - valueCopyright © 2001–2025 MickaĆ«l Guessant. All rights reserved.