gov.sns.xal.smf.data
Class BucketParser

java.lang.Object
  |
  +--gov.sns.xal.smf.data.BucketParser
All Implemented Interfaces:
DataListener

public class BucketParser
extends java.lang.Object
implements DataListener

BucketParser is a wrapper for the collection of attribute buckets associated with an AcceleratorNode. Since each attribute bucket has a type and that type is used as the bucket's data node name within the "attributes" data node hierarchy, a wrapper is needed to hold all such buckets. The BucketParser is that wrapper.


Constructor Summary
BucketParser()
          Creates new BucketParser
BucketParser(java.util.Collection bucketList)
          creates a new BucketParser from a list of buckets
 
Method Summary
 java.lang.String dataLabel()
          DataListener interface support
 AttributeBucket getBucket(java.lang.String bucketType)
          get a specific bucket keyed by the bucket type
 java.util.Collection getBuckets()
          get a collection of all the buckets
 void update(DataAdaptor adaptor)
          DataListener interface support
 void write(DataAdaptor adaptor)
          DataListener interface support
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BucketParser

public BucketParser()
Creates new BucketParser


BucketParser

public BucketParser(java.util.Collection bucketList)
creates a new BucketParser from a list of buckets

Method Detail

dataLabel

public java.lang.String dataLabel()
DataListener interface support

Specified by:
dataLabel in interface DataListener
Returns:
a tag that identifies the receiver's type

update

public void update(DataAdaptor adaptor)
            throws java.lang.NumberFormatException
DataListener interface support

Specified by:
update in interface DataListener
Parameters:
adaptor - The adaptor from which to update the data
java.lang.NumberFormatException

write

public void write(DataAdaptor adaptor)
DataListener interface support

Specified by:
write in interface DataListener
Parameters:
adaptor - The adaptor to which the receiver's data is written

getBuckets

public java.util.Collection getBuckets()
get a collection of all the buckets


getBucket

public AttributeBucket getBucket(java.lang.String bucketType)
get a specific bucket keyed by the bucket type