类 RegistryServices

java.lang.Object
pkg.exoad.poprock.core.registry.RegistryServices

@ServiceClass(requiresArming=true) public final class RegistryServices extends Object

Regsitry Services

A registry is just a place for global properties to be accessed. Registries follows a similar structure to EventPoolService where by which children are set based on a registration system. Furthermore, all registries are public.
作者:
Jack Meng
  • 字段详细资料

  • 构造器详细资料

    • RegistryServices

      private RegistryServices()
  • 方法详细资料

    • armService

      public static void armService()
      Arms the Registry Services. Should be automatically called by Services
    • runOnArmed

      static void runOnArmed(Runnable r)
      Internal macro method
      参数:
      r - Runnable
    • registerEphemeralRegistry

      @VolatileImpl(reason="Supplied id already exists") public static void registerEphemeralRegistry(int id, EphemeralRegistry.EphemeralRegistryConfig config)
      Registers a registry as "Ephemeral".

      If this function panics, it is 99% a source issue.

      参数:
      id - The id alloted to this registry in the cache pool. THIS MUST BE UNIQUE OR ELSE THIS FUNCTION PANICKS!!
      config - The configuration to use for registering this EphemeralRegistry
      另请参阅:
    • getEphemeral

      @VolatileImpl(reason="Supplied id does not exist") public static EphemeralRegistry getEphemeral(int id)
      Acquires the ephemeral registry found from the pool.

      If this function panics, it is 99% a source issue.

      参数:
      id - The id of the registry to look for
      返回:
      The ephemeral registry that was found under the supplied ID