StateSelector.java 872 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
package de.tud.kom.p2psim.impl.topology.movement.modularosm.movementIconVisualisation;

import de.tud.kom.p2psim.api.topology.movement.SimLocationActuator;

/**
 * Interface for the state selector which shall be used in conjunction with the
 * {@link ModularMovementIconVis} in order to use state icons.
 *
 * @author Clemens Krug
 */
public interface StateSelector
{
    /**
     * Returns the state of the host as string. The returned state
     * must be equal to the one specified in the state-icon mapping to have any effect.
     * The state of a host can not be null! In case there is no state matched which has an icon
     * specified, you can return whatever string you like.
     *
     * @param ms The host of whom the state should be determined.
     * @return The state of the host as string, not null.
     */
    String getState(SimLocationActuator ms);
}