public class XMLProperties extends Object
Title: 常用代码打包
Description: Provides the the ability to use simple XML property files. Each property is in the form X.Y.Z, which would map to an XML snippet of:
<X>
<Y>
<Z>someValue</Z>
</Y>
</X>
The XML file is passed in to the constructor and must be readable.
Copyright: Copyright (c) 2006
Company: www.justdos.net
| 限定符和类型 | 方法和说明 |
|---|---|
void |
deleteProperty(String name)
Deletes the specified property.
|
String[] |
getChildrenProperties(String parent)
Return all children property names of a parent property as a String array, or an empty array if the if there are
no children.
|
String[] |
getProperties(String name)
Returns the values of the specified property.
|
String |
getProperty(String name)
Returns the value of the specified property.
|
void |
init(InputStream xmlStream) |
void |
reLoad() |
void |
setProperty(String name,
String value)
Sets the value of the specified property.
|
public void reLoad()
public void init(InputStream xmlStream)
public String getProperty(String name)
name - the name of the property to get.public String[] getProperties(String name)
name - the name of the property to get.public String[] getChildrenProperties(String parent)
parent - the name of the parent property.public void setProperty(String name, String value)
name - the name of the property to set.value - the new value for the property.public void deleteProperty(String name)
name - the property to delete.Copyright © 2023 onecode. All rights reserved.