scala.reflect.internal.Names

Name

sealed abstract class Name extends AbsName with (Int) ⇒ Char

The name class. TODO - resolve schizophrenia regarding whether to treat Names as Strings or Strings as Names. Give names the key functions the absence of which make people want Strings all the time.

Definition Classes
Names → Names
Source
Names.scala
Linear Supertypes
(Int) ⇒ Char, AbsName, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Name
  2. Function1
  3. AbsName
  4. AnyRef
  5. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Name(index: Int, len: Int)

Type Members

  1. abstract type ThisNameType <: Name

Abstract Value Members

  1. abstract def companionName: Name

  2. abstract def isTermName: Boolean

    Definition Classes
    Name → AbsName
  3. abstract def isTypeName: Boolean

    Definition Classes
    Name → AbsName
  4. abstract def nameKind: String

  5. abstract def newName(str: String): ThisNameType

    Return a new name of the same variety.

  6. abstract def next: ThisNameType

    The next name in the same hash bucket.

  7. abstract def subName(from: Int, to: Int): ThisNameType

    Return the subname with characters from from to to-1.

  8. abstract def thisName: ThisNameType

    Attributes
    protected[this]
  9. abstract def toTermName: TermName

    Definition Classes
    Name → AbsName
  10. abstract def toTypeName: TypeName

    Definition Classes
    Name → AbsName

Concrete 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. def andThen[A](g: (Char) ⇒ A): (Int) ⇒ A

    Definition Classes
    Function1
  7. def append(suffix: Name): ThisNameType

  8. def append(suffix: String): ThisNameType

  9. def append(ch: Char): ThisNameType

    TODO - find some efficiency.

  10. final def apply(i: Int): Char

    returns

    the i'th Char of this name

    Definition Classes
    Name → Function1
  11. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  12. def bothNames: List[Name]

  13. def clone(): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  14. def compose[A](g: (A) ⇒ Int): (A) ⇒ Char

    Definition Classes
    Function1
  15. final def containsChar(ch: Char): Boolean

  16. final def containsName(subname: Name): Boolean

  17. final def containsName(subname: String): Boolean

  18. final def copyChars(cs: Array[Char], offset: Int): Unit

    Copy bytes of this name to buffer cs, starting at position offset.

  19. final def copyUTF8(bs: Array[Byte], offset: Int): Int

    Write to UTF8 representation of this name to given character array.

    Write to UTF8 representation of this name to given character array. Start copying to index to. Return index of next free byte in array. Array must have enough remaining space for all bytes (i.e. maximally 3*length bytes).

  20. def debugString: String

  21. def decode: String

    Replace $op_name by corresponding operator symbol.

  22. def decoded: String

    !!! Duplicative but consistently named.

    !!! Duplicative but consistently named.

    Definition Classes
    Name → AbsName
  23. def decodedName: ThisNameType

    Definition Classes
    Name → AbsName
  24. def drop(n: Int): ThisNameType

  25. def dropRight(n: Int): ThisNameType

  26. def encode: ThisNameType

    Replace operator symbols by corresponding $op_name.

  27. def encoded: String

    Definition Classes
    Name → AbsName
  28. def encodedName: ThisNameType

    Definition Classes
    Name → AbsName
  29. final def endChar: Char

  30. final def endsWith(name: String): Boolean

  31. final def endsWith(char: Char): Boolean

  32. final def endsWith(suffix: Name, end: Int): Boolean

    Does this name end with suffix just before given end index?

  33. final def endsWith(suffix: Name): Boolean

    Does this name end with suffix?

  34. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  35. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  36. def finalize(): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  37. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  38. final def hashCode(): Int

    returns

    the hash value of this name

    Definition Classes
    Name → AnyRef → Any
  39. val index: Int

    Attributes
    protected
  40. def indexOf(ch: Char, fromIndex: Int): Int

  41. def indexOf(ch: Char): Int

  42. final def isEmpty: Boolean

  43. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  44. def isOperatorName: Boolean

  45. def lastIndexOf(ch: Char, fromIndex: Int): Int

  46. def lastIndexOf(ch: Char): Int

  47. final def lastPos(s: String, start: Int): Int

    Returns the index of the last occurrence of string s in this name from start, -1 if not found.

    Returns the index of the last occurrence of string s in this name from start, -1 if not found.

    s

    the string

    start

    ...

    returns

    the index of the last occurrence of s

  48. final def lastPos(c: Char, start: Int): Int

    Returns the index of the last occurrence of char c in this name from start, -1 if not found.

    Returns the index of the last occurrence of char c in this name from start, -1 if not found.

    c

    the character

    start

    ...

    returns

    the index of the last occurrence of c

  49. final def lastPos(s: String): Int

  50. final def lastPos(c: Char): Int

    Returns the index of last occurrence of char c in this name, -1 if not found.

    Returns the index of last occurrence of char c in this name, -1 if not found.

    c

    the character

    returns

    the index of the last occurrence of c

  51. val len: Int

    Attributes
    protected
  52. final def length: Int

    The length of this name.

  53. def longString: String

  54. def mapName(f: (String) ⇒ String): ThisNameType

    Return a new name based on string transformation.

  55. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  56. final def nonEmpty: Boolean

  57. final def notify(): Unit

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

    Definition Classes
    AnyRef
  59. final def pos(s: String, start: Int): Int

    Returns the index of the first occurrence of nonempty string s in this name from start, length if not found.

    Returns the index of the first occurrence of nonempty string s in this name from start, length if not found.

    s

    the string

    start

    ...

    returns

    the index of the first occurrence of s

  60. final def pos(c: Char, start: Int): Int

    Returns the index of the first occurrence of character c in this name from start, length if not found.

    Returns the index of the first occurrence of character c in this name from start, length if not found.

    c

    the character

    start

    ...

    returns

    the index of the first occurrence of c

  61. final def pos(s: String): Int

    returns

    the index of first occurrence of char c in this name, length if not found

  62. final def pos(c: Char): Int

    returns

    the index of first occurrence of char c in this name, length if not found

  63. def prepend(prefix: Name): ThisNameType

  64. def prepend(prefix: String): ThisNameType

  65. def prepend(ch: Char): ThisNameType

  66. def replace(from: Char, to: Char): Name

    Replace all occurrences of from by to in name; result is always a term name.

  67. def start: Int

    Index into name table

  68. final def startChar: Char

    Some thoroughly self-explanatory convenience functions.

    Some thoroughly self-explanatory convenience functions. They assume that what they're being asked to do is known to be valid.

  69. final def startsWith(name: String): Boolean

  70. final def startsWith(char: Char): Boolean

  71. final def startsWith(prefix: Name, start: Int): Boolean

    Does this name start with prefix at given start index?

  72. final def startsWith(prefix: Name): Boolean

    Does this name start with prefix?

  73. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  74. final def toChars: Array[Char]

    returns

    the ascii representation of this name

  75. def toString(): String

    Definition Classes
    Function1 → AnyRef → Any
  76. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from (Int) ⇒ Char

Inherited from AbsName

Inherited from AnyRef

Inherited from Any