Asterisk-Java

org.asteriskjava.live.internal
Class ConfigFileImpl

java.lang.Object
  extended by org.asteriskjava.live.internal.ConfigFileImpl
All Implemented Interfaces:
ConfigFile

public class ConfigFileImpl
extends java.lang.Object
implements ConfigFile

ConfigFile implementation based on the config actions of the Manager API.

Since:
1.0.0
Version:
$Id: ConfigFileImpl.java 992 2008-03-08 23:31:13Z srt $
Author:
srt

Constructor Summary
ConfigFileImpl(java.lang.String filename, java.util.Map<java.lang.String,java.util.List<java.lang.String>> categories)
           
 
Method Summary
 java.util.Map<java.lang.String,java.util.List<java.lang.String>> getCategories()
          Returns the lines per category.
 java.lang.String getFilename()
          Returns the filename.
 java.lang.String getValue(java.lang.String category, java.lang.String key)
           
 java.util.List<java.lang.String> getValues(java.lang.String category, java.lang.String key)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfigFileImpl

public ConfigFileImpl(java.lang.String filename,
                      java.util.Map<java.lang.String,java.util.List<java.lang.String>> categories)
Method Detail

getFilename

public java.lang.String getFilename()
Description copied from interface: ConfigFile
Returns the filename.

Specified by:
getFilename in interface ConfigFile
Returns:
the filename, for example "voicemail.conf".

getCategories

public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getCategories()
Description copied from interface: ConfigFile
Returns the lines per category.

Specified by:
getCategories in interface ConfigFile
Returns:
the lines per category.

getValue

public java.lang.String getValue(java.lang.String category,
                                 java.lang.String key)
Specified by:
getValue in interface ConfigFile

getValues

public java.util.List<java.lang.String> getValues(java.lang.String category,
                                                  java.lang.String key)
Specified by:
getValues in interface ConfigFile

Asterisk-Java

Copyright © 2004-2009 Stefan Reuter. All Rights Reserved.