Package net.sf.freecol.common.networking
Class ChangeSet.See
- java.lang.Object
-
- net.sf.freecol.common.networking.ChangeSet.See
-
- Enclosing class:
- ChangeSet
public static class ChangeSet.See extends java.lang.ObjectClass to control the visibility of a change.
-
-
Constructor Summary
Constructors Modifier Constructor Description privateSee(int type)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ChangeSet.Seeall()Make this change visible to all players.ChangeSet.Seealways(Player player)Make this change visible to the given player.ChangeSet.SeeCheckcheck(Player player)Check this visibility with respect to a player.ChangeSet.Seeexcept(Player player)Make this change invisible to the given player.static ChangeSet.Seeonly(Player player)Make this change visible only to the given player.static ChangeSet.Seeperhaps()Make this change visible to all players, provided they can see the objects that are being changed.ChangeSet.SeeperhapsOnly(Player player)Make this change visible to the given player, provided the player can see the objects being changed.java.lang.StringtoString()
-
-
-
Field Detail
-
ALL
private static final int ALL
- See Also:
- Constant Field Values
-
PERHAPS
private static final int PERHAPS
- See Also:
- Constant Field Values
-
ONLY
private static final int ONLY
- See Also:
- Constant Field Values
-
seeAlways
private Player seeAlways
-
seePerhaps
private Player seePerhaps
-
seeNever
private Player seeNever
-
type
private final int type
-
-
Method Detail
-
check
public ChangeSet.SeeCheck check(Player player)
Check this visibility with respect to a player.- Parameters:
player- ThePlayerto consider.- Returns:
- If the player satisfies the visibility test return VISIBLE, or INVISIBLE on failure, or SPECIAL if indeterminate.
-
all
public static ChangeSet.See all()
Make this change visible to all players.- Returns:
- See(ALL).
-
perhaps
public static ChangeSet.See perhaps()
Make this change visible to all players, provided they can see the objects that are being changed.- Returns:
- See(PERHAPS).
-
only
public static ChangeSet.See only(Player player)
Make this change visible only to the given player.- Parameters:
player- ThePlayerto see this change.- Returns:
- A
See(ONLY) with attached player.
-
always
public ChangeSet.See always(Player player)
Make this change visible to the given player.- Parameters:
player- ThePlayerto see this change.- Returns:
- A
Seewith attached player.
-
perhapsOnly
public ChangeSet.See perhapsOnly(Player player)
Make this change visible to the given player, provided the player can see the objects being changed.- Parameters:
player- ThePlayerto perhaps see this change.- Returns:
- A
Seewith attached player.
-
except
public ChangeSet.See except(Player player)
Make this change invisible to the given player.- Parameters:
player- ThePlayerthat can not see this change.- Returns:
- A
Seewith attached player.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-