Class QualifiedNameInterning


  • public final class QualifiedNameInterning
    extends java.lang.Object
    Provides methods for enabling and disabling the interning of strings used in QualifiedName.

    String interning is disabled by default. It can be enabled by setting the system property xtext.qn.interning to true or by calling enable().

    Caution: Setting the system property at runtime does not have an effect. Use enable() to enable String interning at runtime.

    Since:
    2.26.0
    See Also:
    QualifiedName.USE_INTERNING
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void disable()
      Disables the usage of a String pool for QualifiedName's segments.
      static void enable()
      Enables the usage of a String pool for QualifiedName's segments.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • enable

        public static void enable()
        Enables the usage of a String pool for QualifiedName's segments.

        Note: QualifiedNames which are created before enabling are not affected.

        Caution: Interning String objects may affect performance, see bug 484215.

      • disable

        public static void disable()
        Disables the usage of a String pool for QualifiedName's segments.

        Note: QualifiedNames which are created before disabling are not affected.