com.azalient.api.b.display
Interface IShapeGroup


public interface IShapeGroup

A shape group is a named set of shapes. It is not saved directly - each shape saves its group name


Field Summary
static IShapeGroup[] ZERO
          A static zero-length array, created for convenience, and to save memory
 
Method Summary
 void addShape(IShape shape)
          Add a shape to this group
 String name()
          The name of the shape group
 IShape primaryShapeFromTripDNA(ITrip trip)
          If a shape group contains more than one shape, we want to be able to ensure that the same agent selects the same shape from the group every time the model runs.
 

Field Detail

ZERO

static final IShapeGroup[] ZERO
A static zero-length array, created for convenience, and to save memory

Method Detail

name

String name()
The name of the shape group


addShape

void addShape(IShape shape)
Add a shape to this group


primaryShapeFromTripDNA

IShape primaryShapeFromTripDNA(ITrip trip)
If a shape group contains more than one shape, we want to be able to ensure that the same agent selects the same shape from the group every time the model runs. Given the trip, containing DNA, this methods returns a randomly selected shape from the group, but the same shape each time for a given trip.