PropertyUtil (Hyperic HQ Plugin API)
Keywords: org.hyperic.util.PropertyUtil class

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hyperic.util
Class PropertyUtil

    java.lang.Object
      org.hyperic.util.PropertyUtil

    public class PropertyUtil

extends java.lang.Object

Constructor Summary
`PropertyUtil()`

Method Summary
`static void` | `expandVariables(java.util.Map props)` Expand variable references in property values.
`static java.util.Properties` | `loadProperties(java.lang.String file)` Load properties from a file.
`static void` | `storeProperties(java.lang.String file, java.util.Properties props, java.lang.String header)` Store properties to a file
`static void` | `stripKeys(java.util.Properties props, java.lang.String prefix)` Strip a prefix from the keys in a properties object.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### PropertyUtil

    public PropertyUtil()

Method Detail

### expandVariables

    public static void expandVariables(java.util.Map props)

  Expand variable references in property values. I.e. if you have a props file: a=foo b=bar c=${a} ${b} The value for 'c' will be 'foo bar'

  Parameters:
    `props` - Properties to replace

### stripKeys

    public static void stripKeys(java.util.Properties props,
                                 java.lang.String prefix)

  Strip a prefix from the keys in a properties object. Mainly used for backwards compatibility of net.covalent property keys.

### loadProperties

    public static java.util.Properties loadProperties(java.lang.String file)
                                               throws java.io.IOException

  Load properties from a file.

  Throws:
    `java.io.IOException`

### storeProperties

    public static void storeProperties(java.lang.String file,
                                       java.util.Properties props,
                                       java.lang.String header)
                                throws java.io.IOException

  Store properties to a file

  Throws:
    `java.io.IOException`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.