Package yapion.utils

Class ReferenceIDUtils


  • public class ReferenceIDUtils
    extends java.lang.Object
    • Method Summary

      Modifier and Type Method Description
      static void discardCache()
      Discard the cache used by referenceOld(String)
      static java.lang.String format​(long l)
      Formats the input to the standard reference ID structure.
      • Methods inherited from class java.lang.Object

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

      • REFERENCE_FUNCTION

        public static final ReferenceFunction REFERENCE_FUNCTION
        Calculates the reference ID of a given String, primarily used for variable names. This method caches the last 256 inputs for faster reference ID calculation. Use discardCache() to discard this Cache.
      • REFERENCE_FUNCTION_OLD

        @Deprecated
        public static final ReferenceFunction REFERENCE_FUNCTION_OLD
        Deprecated.
        since 0.23.0
        Calculates the reference ID of a given String, primarily used for variable names. This method caches the last 256 inputs for faster reference ID calculation. Use discardCache() to discard this Cache.
    • Constructor Detail

      • ReferenceIDUtils

        public ReferenceIDUtils()
    • Method Detail

      • discardCache

        public static void discardCache()
        Discard the cache used by referenceOld(String)
      • format

        public static java.lang.String format​(long l)
        Formats the input to the standard reference ID structure.
        Parameters:
        l - the input to format
        Returns:
        the formatted input