com.rubecula.darwin.examples.pepperedmoth
Class Census_WingColor

java.lang.Object
  extended by com.rubecula.darwin.domain.helper.Sink_
      extended by com.rubecula.darwin.domain.helper.Census_Sink
          extended by com.rubecula.darwin.domain.world.Census_Darwinian
              extended by com.rubecula.darwin.examples.pepperedmoth.Census_WingColor
All Implemented Interfaces:
Census, Sink, SinkCensus, java.io.Closeable, java.io.Flushable, java.lang.Appendable

public final class Census_WingColor
extends Census_Darwinian

Implementation of SinkCensus specifically for the PepperedMoth example and which concentrates on showing the mean wing color (and numbers of organisms with each trait).

Author:
Robin Hillyard

Field Summary
 
Fields inherited from class com.rubecula.darwin.domain.helper.Sink_
LOG
 
Fields inherited from interface com.rubecula.darwin.domain.helper.Sink
NEWLINE
 
Constructor Summary
Census_WingColor(java.io.PrintWriter printWriter)
           
 
Method Summary
 void census(Censusible individual, int depth, java.lang.Object context)
          Collect and process census information about the individual specified.
 
Methods inherited from class com.rubecula.darwin.domain.helper.Census_Sink
append, close, equals, flush, getPrintWriter, hashCode, present, print, println, println
 
Methods inherited from class com.rubecula.darwin.domain.helper.Sink_
append, append, sinkOrLog
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.lang.Appendable
append, append
 

Constructor Detail

Census_WingColor

public Census_WingColor(java.io.PrintWriter printWriter)
Parameters:
printWriter -
Method Detail

census

public void census(Censusible individual,
                   int depth,
                   java.lang.Object context)
Description copied from interface: Census
Collect and process census information about the individual specified.

Specified by:
census in interface Census
Overrides:
census in class Census_Sink
Parameters:
individual - the object to be censused.
depth - the number of levels of depth which shall be censused below this object.
context - an arbitrary object which defines the context in which this census is happening.
See Also:
Census_Sink.census(Censusible, int, Object)


Copyright © 2010 Rubecula Software, LLC. All Rights Reserved.