Class SimpleQuestService

java.lang.Object
me.kzheart.klib.script.kether.core.SimpleQuestService
All Implemented Interfaces:
AutoCloseable, QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>

public final class SimpleQuestService extends Object implements QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>, AutoCloseable
保留 Java getter 的方法和 Kotlin synthetic property 双源码入口。
  • Constructor Details

    • SimpleQuestService

      public SimpleQuestService()
    • SimpleQuestService

      public SimpleQuestService(boolean toleranceParser)
    • SimpleQuestService

      public SimpleQuestService(Executor executor)
    • SimpleQuestService

      public SimpleQuestService(Executor executor, ScheduledExecutorService asyncExecutor, boolean toleranceParser)
  • Method Details

    • load

      public Quest load(String id, String source, List<String> namespaces)
    • load

      public Quest load(String id, String source)
    • newContext

      public me.kzheart.klib.script.kether.core.SimpleQuestContext newContext(Quest quest)
    • getRegistry

      public QuestRegistry getRegistry()
      Specified by:
      getRegistry in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getQuest

      public Optional<Quest> getQuest(String id)
      Specified by:
      getQuest in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getQuestSettings

      public Map<String,Object> getQuestSettings(String id)
      Specified by:
      getQuestSettings in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getQuests

      public Map<String,Quest> getQuests()
      Specified by:
      getQuests in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • startQuest

      public void startQuest(me.kzheart.klib.script.kether.core.SimpleQuestContext context)
      Specified by:
      startQuest in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • terminateQuest

      public void terminateQuest(me.kzheart.klib.script.kether.core.SimpleQuestContext context)
      Specified by:
      terminateQuest in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getRunningQuests

      public Map<String,List<me.kzheart.klib.script.kether.core.SimpleQuestContext>> getRunningQuests()
      Specified by:
      getRunningQuests in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getRunningQuests

      public List<me.kzheart.klib.script.kether.core.SimpleQuestContext> getRunningQuests(String key)
      Specified by:
      getRunningQuests in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getExecutor

      public Executor getExecutor()
      Specified by:
      getExecutor in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getAsyncExecutor

      public ScheduledExecutorService getAsyncExecutor()
      Specified by:
      getAsyncExecutor in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getLocalizedText

      public String getLocalizedText(String node, Object... params)
      Specified by:
      getLocalizedText in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • isToleranceParser

      public boolean isToleranceParser()
      Specified by:
      isToleranceParser in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • getPropertyAccessor

      public PropertyAccessor getPropertyAccessor()
      Description copied from interface: QuestService
      属性读取简写的解析器;未安装时属性读取语句失败。
      Specified by:
      getPropertyAccessor in interface QuestService<me.kzheart.klib.script.kether.core.SimpleQuestContext>
    • setPropertyAccessor

      public void setPropertyAccessor(PropertyAccessor value)
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable