net.sourceforge.pmd.lang.dfa

## Class AbstractDataFlowNode

- java.lang.Object
- - net.sourceforge.pmd.lang.dfa.AbstractDataFlowNode

All Implemented Interfaces:
  DataFlowNode

Direct Known Subclasses:
  JavaDataFlowNode, StartOrEndDataFlowNode

    public abstract class AbstractDataFlowNode
    extends Object
    implements DataFlowNode

Author:
  raik

  Each data flow contains a set of DataFlowNodes.

### Field Summary

Fields
`protected List<DataFlowNode>` `children`
`protected List<DataFlowNode>` `dataFlow`
`protected int` `line`
`protected Node` `node`
`protected List<DataFlowNode>` `parents`
`protected BitSet` `type`
`protected Map<Integer,String>` `typeMap`
`protected List<VariableAccess>` `variableAccess`

### Constructor Summary

Constructors
Constructor and Description
`AbstractDataFlowNode(List<DataFlowNode> dataFlow)`
`AbstractDataFlowNode(List<DataFlowNode> dataFlow, Node node)`

### Method Summary

Methods
`void` `addPathToChild(DataFlowNode child)`
`List<DataFlowNode>` `getChildren()`
`List<DataFlowNode>` `getFlow()`
`int` `getIndex()`
`int` `getLine()`
`Node` `getNode()`
`List<DataFlowNode>` `getParents()`
`List<VariableAccess>` `getVariableAccess()`
`boolean` `isType(int intype)`
`boolean` `removePathToChild(DataFlowNode child)`
`void` `reverseParentPathsTo(DataFlowNode destination)`
`void` `setType(int type)`
`void` `setVariableAccess(List<VariableAccess> variableAccess)`
`String` `toString()`

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

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

### Field Detail

#### node

    protected Node node

#### typeMap

    protected Map<Integer,String> typeMap

#### parents

    protected List<DataFlowNode> parents

#### children

    protected List<DataFlowNode> children

#### type

    protected BitSet type

#### variableAccess

    protected List<VariableAccess> variableAccess

#### dataFlow

    protected List<DataFlowNode> dataFlow

#### line

    protected int line

### Constructor Detail

#### AbstractDataFlowNode

    public AbstractDataFlowNode(List<DataFlowNode> dataFlow)

#### AbstractDataFlowNode

    public AbstractDataFlowNode(List<DataFlowNode> dataFlow,
                        Node node)

### Method Detail

#### addPathToChild

    public void addPathToChild(DataFlowNode child)

Specified by:
  `addPathToChild` in interface `DataFlowNode`

#### removePathToChild

    public boolean removePathToChild(DataFlowNode child)

Specified by:
  `removePathToChild` in interface `DataFlowNode`

#### reverseParentPathsTo

    public void reverseParentPathsTo(DataFlowNode destination)

Specified by:
  `reverseParentPathsTo` in interface `DataFlowNode`

#### getLine

    public int getLine()

Specified by:
  `getLine` in interface `DataFlowNode`

#### setType

    public void setType(int type)

Specified by:
  `setType` in interface `DataFlowNode`

#### isType

    public boolean isType(int intype)

Specified by:
  `isType` in interface `DataFlowNode`

#### getNode

    public Node getNode()

Specified by:
  `getNode` in interface `DataFlowNode`

#### getChildren

    public List<DataFlowNode> getChildren()

Specified by:
  `getChildren` in interface `DataFlowNode`

#### getParents

    public List<DataFlowNode> getParents()

Specified by:
  `getParents` in interface `DataFlowNode`

#### getFlow

    public List<DataFlowNode> getFlow()

Specified by:
  `getFlow` in interface `DataFlowNode`

#### getIndex

    public int getIndex()

Specified by:
  `getIndex` in interface `DataFlowNode`

#### setVariableAccess

    public void setVariableAccess(List<VariableAccess> variableAccess)

Specified by:
  `setVariableAccess` in interface `DataFlowNode`

#### getVariableAccess

    public List<VariableAccess> getVariableAccess()

Specified by:
  `getVariableAccess` in interface `DataFlowNode`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`