scala.tools.refactoring.common.Selections

TreeSelection

case class TreeSelection(root: nsc.Global.Tree) extends (Selections.this)#Selection with Product with Serializable

Linear Supertypes
Serializable, java.io.Serializable, Product, Equals, (Selections.this)#Selection, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. TreeSelection
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. Selection
  7. AnyRef
  8. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new TreeSelection(root: nsc.Global.Tree)

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def contains(t: nsc.Global.Tree): Boolean

    Returns true if the given Tree is fully contained in the selection.

    Returns true if the given Tree is fully contained in the selection.

    Definition Classes
    Selection
  9. lazy val enclosingTree: nsc.Global.Tree

    Returns the tree that encloses the whole selection.

    Returns the tree that encloses the whole selection.

    Definition Classes
    Selection
  10. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  11. def expand: (Selections.this)#Selection

    Expands the selection in such a way, that partially selected trees are completely selected.

    Expands the selection in such a way, that partially selected trees are completely selected.

    Definition Classes
    Selection
  12. def expandTo[T <: nsc.Global.Tree](implicit m: Manifest[T]): Option[(Selections.this)#Selection]

    Expands to a specific type of tree.

    Expands to a specific type of tree.

    Definition Classes
    Selection
  13. def expandTo(tree: nsc.Global.Tree): Option[(Selections.this)#Selection]

    Tries to expand the selection to tree if the current selection contains only subtrees of tree.

    Tries to expand the selection to tree if the current selection contains only subtrees of tree.

    Definition Classes
    Selection
  14. def expandTo(newPos: nsc.Global.Position): Option[(Selections.this)#Selection]

    Tries to expand the selection to newPos.

    Tries to expand the selection to newPos.

    Definition Classes
    Selection
  15. def expandTo(pred: ((Selections.this)#Selection) ⇒ Boolean): Option[(Selections.this)#Selection]

    Expands the selection until pred evaluates to true.

    Expands the selection until pred evaluates to true.

    Definition Classes
    Selection
  16. def expandToNextEnclosingTree: Option[(Selections.this)#Selection]

    Tries to expand the selection to a tree that fully contains the selection but is not equal to the selection.

    Tries to expand the selection to a tree that fully contains the selection but is not equal to the selection.

    Definition Classes
    Selection
  17. val file: AbstractFile

    Definition Classes
    TreeSelectionSelection
  18. def filterSelected(predicate: (nsc.Global.Tree) ⇒ Boolean): List[nsc.Global.Tree]

    Definition Classes
    Selection
  19. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  20. def findSelectedOfType[T](implicit m: Manifest[T]): Option[T]

    Finds a selected tree by its type.

    Finds a selected tree by its type.

    Definition Classes
    Selection
    See also

    findSelectedWithPredicate for more information

  21. def findSelectedWithPredicate(predicate: (nsc.Global.Tree) ⇒ Boolean): Option[nsc.Global.Tree]

    Finds a selected tree by a predicate.

    Finds a selected tree by a predicate. The tree does not have to be selected completely, it is only checked whether this selection is contained in the tree.

    If multiple trees of the type are found, the last one (i.e. the deepest child) is returned.

    Definition Classes
    Selection
  22. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  23. lazy val inboundDeps: List[nsc.Global.Symbol]

    Returns a list of symbols that are used inside the selection but defined outside of it.

    Returns a list of symbols that are used inside the selection but defined outside of it.

    Definition Classes
    Selection
  24. def inboundDepsOwnedBy(owner: nsc.Global.Symbol): List[nsc.Global.Symbol]

    Returns only inbound dependencies that are directly or indirectly owned by owner.

    Returns only inbound dependencies that are directly or indirectly owned by owner.

    Definition Classes
    Selection
  25. lazy val inboundLocalDeps: List[nsc.Global.Symbol]

    Returns inbound dependencies that are owned by the outmost enclosing class or object in the CU.

    Returns inbound dependencies that are owned by the outmost enclosing class or object in the CU.

    Definition Classes
    Selection
  26. def isContainedIn(t: nsc.Global.Tree): Boolean

    Returns true if the given Tree fully contains this selection.

    Returns true if the given Tree fully contains this selection.

    Definition Classes
    Selection
  27. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  28. lazy val isSingleTree: Boolean

    Definition Classes
    Selection
  29. lazy val mayHaveSideEffects: Boolean

    Tries to determine if the selected code contains side effects.

    Tries to determine if the selected code contains side effects.

    Caution: mayHaveSideEffects == false does not guarantee that selection has no side effects.

    The current implementation does check if the selection contains a reference to a symbol that has a type that is somehow related to Unit.

    Definition Classes
    Selection
  30. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  31. final def notify(): Unit

    Definition Classes
    AnyRef
  32. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  33. lazy val outboundLocalDeps: List[nsc.Global.Symbol]

    Returns a list of symbols that are defined inside the selection and used outside of it.

    Returns a list of symbols that are defined inside the selection and used outside of it.

    This implementation does not use index lookups and therefore returns only outbound dependencies that are used in the same compilation unit. However, this affects only class member definitions.

    It also does not cover outbound dependencies that are imported through an import statement in the selected code.

    Definition Classes
    Selection
  34. val pos: RangePosition

    Definition Classes
    TreeSelectionSelection
  35. lazy val reassignedDeps: collection.immutable.List[nsc.Global.Symbol]

    All inbound dependencies that are reassigned in the selected code and used afterwards.

    All inbound dependencies that are reassigned in the selected code and used afterwards.

    Definition Classes
    Selection
  36. lazy val representsArgument: Boolean

    Definition Classes
    Selection
  37. lazy val representsParameter: Boolean

    Definition Classes
    Selection
  38. lazy val representsValue: Boolean

    Is true if the selected code could be replaced by a value.

    Is true if the selected code could be replaced by a value.

    E.g. the selected code represents a value although it consists of more than one expression: def fn = { /*(*/al a = 2 a * 100/*)*/ * } it is replaceable by 200 without changing the methods return value.

    Note, this implementation assumes that the code has no side effects.

    Definition Classes
    Selection
  39. lazy val representsValueDefinitions: Boolean

    Is true if the selected code contains only value definitions.

    Is true if the selected code contains only value definitions.

    Definition Classes
    Selection
  40. val root: nsc.Global.Tree

    Definition Classes
    TreeSelectionSelection
  41. lazy val selectedSymbolTree: Option[nsc.Global.SymTree]

    Tries to find the selected SymTree: first it is checked if the selection fully contains a SymTree, if true, the first selected is returned.

    Tries to find the selected SymTree: first it is checked if the selection fully contains a SymTree, if true, the first selected is returned. Otherwise the result of findSelectedOfType[SymTree] is returned.

    Definition Classes
    Selection
  42. lazy val selectedSymbols: collection.immutable.List[nsc.Global.Symbol]

    Returns all symbols that are either used or defined in the selected trees and their children.

    Returns all symbols that are either used or defined in the selected trees and their children.

    Definition Classes
    Selection
  43. lazy val selectedTopLevelTrees: List[nsc.Global.Tree]

    Returns all selected trees that are not children of other selected trees.

    Returns all selected trees that are not children of other selected trees.

    Definition Classes
    Selection
  44. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  45. def toString(): String

    Definition Classes
    Selection → AnyRef → Any
  46. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  47. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  48. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  49. def withPos(newPos: nsc.Global.Position): (Selections.this)#Selection

    Definition Classes
    Selection

Inherited from Serializable

Inherited from java.io.Serializable

Inherited from Product

Inherited from Equals

Inherited from (Selections.this)#Selection

Inherited from AnyRef

Inherited from Any

Ungrouped