org.eclipse.gef.zest.fx.models

## Class HidingModel

- java.lang.Object
- - org.eclipse.gef.zest.fx.models.HidingModel

    public class HidingModel
    extends Object

The `HidingModel` manages a `Set` of currently hidden `Node`s. The hidden neighbors of a `Node` can be identified using `getHiddenNeighbors(org.eclipse.gef.graph.Node)`.

### Property Summary

All Methods Instance Methods Concrete Methods
`ReadOnlySetProperty<Node>` `hidden` Returns a read-only property containing the hidden nodes.

### Field Summary

Fields
`static String` `HIDDEN_PROPERTY` Property name that is used when firing property change notifications when the `Set` of hidden `Node`s changes.

### Constructor Summary

Constructors
Constructor and Description
`HidingModel()`

### Method Summary

All Methods Instance Methods Concrete Methods
`Set<NodePart>` `getHiddenNeighborParts(NodePart nodePart)` Returns a `Set` containing all `NodePart`s corresponding to the hidden neighbors of the content of the given `NodePart`.
`Set<Node>` `getHiddenNeighbors(Node node)` Returns a `Set` containing all hidden neighbors of the given `Node`.
`Set<Node>` `getHiddenNodesUnmodifiable()` Returns a copy of the `Set` that contains all hidden `Node`s.
`boolean` `hasHiddenNeighbors(Node node)` Returns `true` if at least one neighbor of the given `Node` is currently hidden.
`boolean` `hasHiddenNeighbors(NodePart nodePart)` Returns `true` if at least one neighbor of the given `NodePart` is currently hidden.
`ReadOnlySetProperty<Node>` `hiddenProperty()` Returns a read-only property containing the hidden nodes.
`void` `hide(Node node)` Adds the given `Node` to the `Set` of hidden `Node`s.
`void` `hide(NodePart nodePart)` Adds the content of the given `NodePart` to the `Set` of hidden `Node`s.
`boolean` `isHidden(Node node)` Returns `true` if the given `Node` is currently contained within the `Set` of hidden `Node`s.
`boolean` `isHidden(NodePart nodePart)` Returns `true` if the given `NodePart` is currently contained within the `Set` of hidden `Node`s.
`void` `show(Node node)` Remove the given `Node` from the `Set` of hidden `Node` s.
`void` `show(NodePart nodePart)` Remove the content of the given `NodePart` from the `Set` of hidden `Node` s.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Property Detail

#### hidden

    public ReadOnlySetProperty<Node> hiddenProperty

Returns a read-only property containing the hidden nodes.

### Field Detail

#### HIDDEN_PROPERTY

    public static final String HIDDEN_PROPERTY

Property name that is used when firing property change notifications when the `Set` of hidden `Node`s changes.

See Also:
  Constant Field Values

### Constructor Detail

#### HidingModel

    public HidingModel()

### Method Detail

#### getHiddenNeighborParts

    public Set<NodePart> getHiddenNeighborParts(NodePart nodePart)

Returns a `Set` containing all `NodePart`s corresponding to the hidden neighbors of the content of the given `NodePart`.

Parameters:
  `nodePart` - The `NodePart` of which the hidden neighbors are returned.
Returns:
  A `Set` containing all hidden neighbors of the given `NodePart`.

#### getHiddenNeighbors

    public Set<Node> getHiddenNeighbors(Node node)

Returns a `Set` containing all hidden neighbors of the given `Node`.

Parameters:
  `node` - The `Node` of which the hidden neighbors are returned.
Returns:
  A `Set` containing all hidden neighbors of the given `Node`.

#### getHiddenNodesUnmodifiable

    public Set<Node> getHiddenNodesUnmodifiable()

Returns a copy of the `Set` that contains all hidden `Node`s.

Returns:
  A copy of the `Set` that contains all hidden `Node`s.

#### hasHiddenNeighbors

    public boolean hasHiddenNeighbors(NodePart nodePart)

Returns `true` if at least one neighbor of the given `NodePart` is currently hidden. Otherwise returns `false`.

Parameters:
  `nodePart` - The `NodePart` that is tested for hidden neighbors.
Returns:
  `true` if at least one neighbor of the given `NodePart` is currently hidden, otherwise `false`.

#### hasHiddenNeighbors

    public boolean hasHiddenNeighbors(Node node)

Returns `true` if at least one neighbor of the given `Node` is currently hidden. Otherwise returns `false`.

Parameters:
  `node` - The `Node` that is tested for hidden neighbors.
Returns:
  `true` if at least one neighbor of the given `Node` is currently hidden, otherwise `false`.

#### hiddenProperty

    public ReadOnlySetProperty<Node> hiddenProperty()

Returns a read-only property containing the hidden nodes.

#### hide

    public void hide(NodePart nodePart)

Adds the content of the given `NodePart` to the `Set` of hidden `Node`s. Notifies all property change listeners about this change.

Parameters:
  `nodePart` - The `NodePart` that is added to the `Set` of hidden `Node`s.

#### hide

    public void hide(Node node)

Adds the given `Node` to the `Set` of hidden `Node`s. Notifies all property change listeners about this change.

Parameters:
  `node` - The `Node` that is added to the `Set` of hidden `Node`s.

#### isHidden

    public boolean isHidden(NodePart nodePart)

Returns `true` if the given `NodePart` is currently contained within the `Set` of hidden `Node`s. Otherwise, returns `false`.

Parameters:
  `nodePart` - The `NodePart` in question.
Returns:
  `true` if the given `Node` is currently contained within the `Set` of hidden `Node`s, otherwise `false`.

#### isHidden

    public boolean isHidden(Node node)

Returns `true` if the given `Node` is currently contained within the `Set` of hidden `Node`s. Otherwise, returns `false`.

Parameters:
  `node` - The `Node` in question.
Returns:
  `true` if the content of the given `NodePart` is currently contained within the `Set` of hidden `Node`s, otherwise `false`.

#### show

    public void show(NodePart nodePart)

Remove the content of the given `NodePart` from the `Set` of hidden `Node` s. Notifies all property change listeners about this change.

Parameters:
  `nodePart` - The `NodePart` of which the content is removed from the `Set` of hidden `Node` s.

#### show

    public void show(Node node)

Remove the given `Node` from the `Set` of hidden `Node` s. Notifies all property change listeners about this change.

Parameters:
  `node` - The `Node` that is removed from the `Set` of hidden `Node` s.