Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cayenne.configuration
Class DefaultRuntimeProperties

    java.lang.Object
      org.apache.cayenne.configuration.DefaultRuntimeProperties

All Implemented Interfaces:
  RuntimeProperties

    public class DefaultRuntimeProperties

extends java.lang.Object
implements RuntimeProperties

An implementation of `RuntimeProperties` that returns properties that were injected via a map in constructor. Each property can be overridden via -D command line option (i.e. in this implementation JVM system properties take precedence over any other property configuration mechanism).

Since:
  3.1

Field Summary
`protected java.util.Map<java.lang.String,java.lang.String>` | `properties`

Constructor Summary
`DefaultRuntimeProperties(java.util.Map<java.lang.String,java.lang.String> properties)`

Method Summary
`java.lang.String` | `get(java.lang.String key)` Returns a String property value for a given key.
`boolean` | `getBoolean(java.lang.String key, boolean defaultValue)`
`int` | `getInt(java.lang.String key, int defaultValue)`
`long` | `getLong(java.lang.String key, long defaultValue)`

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

Field Detail

### properties

    protected java.util.Map<java.lang.String,java.lang.String> properties

Constructor Detail

### DefaultRuntimeProperties

    public DefaultRuntimeProperties(java.util.Map<java.lang.String,java.lang.String> properties)

Method Detail

### get

    public java.lang.String get(java.lang.String key)

  Description copied from interface: `RuntimeProperties`
  Returns a String property value for a given key.

  Specified by:
    `get` in interface `RuntimeProperties`

### getLong

    public long getLong(java.lang.String key,
                        long defaultValue)

  Specified by:
    `getLong` in interface `RuntimeProperties`

### getInt

    public int getInt(java.lang.String key,
                      int defaultValue)

  Specified by:
    `getInt` in interface `RuntimeProperties`

### getBoolean

    public boolean getBoolean(java.lang.String key,
                              boolean defaultValue)

  Specified by:
    `getBoolean` in interface `RuntimeProperties`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2012 Apache Cayenne. All Rights Reserved.