/** * Gets the {@link NucleusHomeService}, if it exists. * * <p> * Requires the "home" module. * </p> * * @return The {@link NucleusHomeService} */ public static Optional<NucleusHomeService> getHomeService() { return getService(NucleusHomeService.class); }
/** * Gets the {@link NucleusNicknameService}, if it exists. * * <p> * Requires the "nickname" module. * </p> * * @return The {@link NucleusNicknameService} */ public static Optional<NucleusNicknameService> getNicknameService() { return getService(NucleusNicknameService.class); }
/** * Gets the {@link NucleusInvulnerabilityService}, if it exists. * * <p> * Requires the "misc" module. * </p> * * @return The {@link NucleusInvulnerabilityService} */ public static Optional<NucleusInvulnerabilityService> getInvulnerabilityService() { return getService(NucleusInvulnerabilityService.class); }
/** * Gets the {@link NucleusNoteService}, if it exists. * * <p> * Requires the "note" module. * </p> * * @return The {@link NucleusNoteService} */ public static Optional<NucleusNoteService> getNoteService() { return getService(NucleusNoteService.class); }
/** * Gets the {@link NucleusRTPService}, if it exists. * * <p> * Requires the "rtp" module. * </p> * * @return The {@link NucleusRTPService} */ public static Optional<NucleusRTPService> getRTPService() { return getService(NucleusRTPService.class); }
/** * Gets the {@link NucleusSeenService}, if it exists. * * <p> * Requires the "playerinfo" module. * </p> * * @return The {@link NucleusSeenService} */ public static Optional<NucleusSeenService> getSeenService() { return getService(NucleusSeenService.class); }
/** * Gets the {@link NucleusPrivateMessagingService}, if it exists. * * <p> * Requires the "message" module. * </p> * * @return The {@link NucleusPrivateMessagingService} */ public static Optional<NucleusPrivateMessagingService> getPrivateMessagingService() { return getService(NucleusPrivateMessagingService.class); }
/** * Gets the {@link NucleusWarningService}, if it exists. * * <p> * Requires the "warning" module. * </p> * * @return The {@link NucleusWarningService} */ public static Optional<NucleusWarningService> getWarningService() { return getService(NucleusWarningService.class); }
/** * Gets the {@link NucleusAFKService}, if it exists. * * <p> * Requires the "afk" module. * </p> * * @return The {@link NucleusAFKService} */ public static Optional<NucleusAFKService> getAFKService() { return getService(NucleusAFKService.class); }
/** * Gets the {@link NucleusServerShopService}, if it exists. * * <p> * Requires the "servershop" module. * </p> * * @return The {@link NucleusServerShopService} */ public static Optional<NucleusServerShopService> getServerShopService() { return getService(NucleusServerShopService.class); }
/** * Gets the {@link NucleusStaffChatService}, if it exists. * * <p> * Requires the "staff-chat" module. * </p> * * @return The {@link NucleusStaffChatService} */ public static Optional<NucleusStaffChatService> getStaffChatService() { return getService(NucleusStaffChatService.class); }
/** * Gets the {@link NucleusBackService}, if it exists. * * <p> * Requires the "back" module. * </p> * * @return The {@link NucleusBackService} */ public static Optional<NucleusBackService> getBackService() { return getService(NucleusBackService.class); }
/** * Gets the {@link NucleusJailService}, if it exists. * * <p> * Requires the "jail" module. * </p> * * @return The {@link NucleusJailService} */ public static Optional<NucleusJailService> getJailService() { return getService(NucleusJailService.class); }
/** * Gets the {@link NucleusKitService}, if it exists. * * <p> * Requires the "kit" module. * </p> * * @return The {@link NucleusKitService} */ public static Optional<NucleusKitService> getKitService() { return getService(NucleusKitService.class); }
/** * Gets the {@link NucleusMailService}, if it exists. * * <p> * Requires the "mail" module. * </p> * * @return The {@link NucleusMailService} */ public static Optional<NucleusMailService> getMailService() { return getService(NucleusMailService.class); }
/** * Gets the {@link NucleusMuteService}, if it exists. * * <p> * Requires the "mute" module. * </p> * * @return The {@link NucleusMuteService} */ public static Optional<NucleusMuteService> getMuteService() { return getService(NucleusMuteService.class); }
/** * Gets the {@link NucleusNameBanService}, if it exists. * * <p> * Requires the "nameban" module. * </p> * * @return The {@link NucleusNameBanService} */ public static Optional<NucleusNameBanService> getNameBanService() { return getService(NucleusNameBanService.class); }
/** * Gets the {@link NucleusWarpService}, if it exists. * * <p> * Requires the "warp" module. * </p> * * @return The {@link NucleusWarpService} */ public static Optional<NucleusWarpService> getWarpService() { return getService(NucleusWarpService.class); }
/** * Gets the API Player Metadata service, which contains the player metadata information. * @return The {@link NucleusPlayerMetadataService} * @throws IllegalStateException if Nucleus hasn't completed post init yet. */ public static NucleusPlayerMetadataService getPlayerMetadataService() { return getService(NucleusPlayerMetadataService.class).orElseThrow(() -> new IllegalStateException("Nucleus API has not started registering yet")); }
/** * Gets the {@link NucleusModuleService} service, which contains the module information, as well as a way to disable the modules during * pre-init or init. * @return The {@link NucleusAPIMetaService} * @throws IllegalStateException if Nucleus hasn't completed pre init yet. */ public static NucleusModuleService getModuleService() { return getService(NucleusModuleService.class).orElseThrow(() -> new IllegalStateException("Nucleus Modules have not been discovered yet")); }