/** * Removes an adapted, VisAD ScalarMap. * * @param adapter The {@link ScalarMapAdapter} to be removed from this instance. */ public final void remove(ScalarMapAdapter adapter) { scalarMapTable.remove(adapter); }
/** * Accepts a ScalarMapAdapter for inclusion. The name "accept" is used rather than "add" because * this class supports the "addition" of the same ScalarMapAdapter multiple times (unlike a VisAD * display with {@link visad.ScalarMap}). If a ScalarMapAdapter was previously added, then * subsequent additions result in the underlying {@link visad.ScalarMap} of the ScalarMapAdapter * being set to that of the previously- added ScalarMapAdapter (the "controlling" * ScalarMapAdapter). Otherwise, the ScalarMapAdapter is simply added and returned. In either * case, this instance registers itself with the ScalarMapAdapter as a {@link * java.beans.PropertyChangeListener} for the {@link ScalarMapAdapter#SCALAR_MAP} property. A * change to the ScalarMapAdapter's underlying ScalarMap will cause the display to be rebuilt, if * ncessary. * * @param adapter The adapted ScalarMap to accept. * @return The "controlling" ScalarMapAdapter. The argument is returned if its ScalarMap is * unique; otherwise, the previously-added ScalarMapAdapter with the same ScalarMap is * returned. * @throws VisADException VisAD failure. * @throws RemoteException Java RMI failure. */ public final ScalarMapAdapter accept(ScalarMapAdapter adapter) throws VisADException, RemoteException { return scalarMapTable.accept(adapter); }