diva.util
Class BasicPropertyContainer

java.lang.Object
  extended by diva.util.BasicPropertyContainer
All Implemented Interfaces:
PropertyContainer
Direct Known Subclasses:
BasicEdge, BasicNode

public class BasicPropertyContainer
extends Object
implements PropertyContainer

An object that can be annotated with arbitrary objects whose keys are strings.

Version:
$Revision: 1.10 $
Author:
Michael Shilman (michaels@eecs.berkeley.edu)

Constructor Summary
BasicPropertyContainer()
          A property container with no defaults.
BasicPropertyContainer(PropertyContainer defaults)
          A property container with no defaults.
 
Method Summary
 Object getProperty(String key)
          Return the property corresponding to the given key, or null if no such property exists.
 Iterator properties()
           
 Iterator propertyNames()
          Return an iteration of the names of the properties
 void removeAllProperties()
           
 void setProperty(String key, Object value)
          Set the property corresponding to the given key.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicPropertyContainer

public BasicPropertyContainer()
A property container with no defaults.


BasicPropertyContainer

public BasicPropertyContainer(PropertyContainer defaults)
A property container with no defaults.

Method Detail

getProperty

public Object getProperty(String key)
Return the property corresponding to the given key, or null if no such property exists.

Specified by:
getProperty in interface PropertyContainer

setProperty

public void setProperty(String key,
                        Object value)
Set the property corresponding to the given key.

Specified by:
setProperty in interface PropertyContainer

removeAllProperties

public void removeAllProperties()

properties

public Iterator properties()

propertyNames

public Iterator propertyNames()
Return an iteration of the names of the properties

Specified by:
propertyNames in interface PropertyContainer


Copyright © 2015 Central Laboratory of the Research Councils. All Rights Reserved.