Class OreSession

  • All Implemented Interfaces:
    java.lang.AutoCloseable

    public class OreSession
    extends java.lang.Object
    implements java.lang.AutoCloseable
    Represents a session with the Ore API
    • Field Detail

      • GSON

        public static final com.google.gson.Gson GSON
    • Method Detail

      • connect

        public static java.util.concurrent.CompletableFuture<OreSession> connect​(java.util.concurrent.Executor executor,
                                                                                 java.lang.String apiKey,
                                                                                 java.lang.String apiBase,
                                                                                 long sessionDurationSeconds)
      • terminate

        public java.util.concurrent.CompletableFuture<OreResponse<java.lang.Void>> terminate()
      • publishVersion

        public java.util.concurrent.CompletableFuture<Version> publishVersion​(java.lang.String pluginId,
                                                                              DeployVersionInfo info,
                                                                              java.nio.file.Path pluginFile)
      • globalPermissions

        public java.util.concurrent.CompletableFuture<KeyPermissions> globalPermissions()
      • projectPermissions

        public java.util.concurrent.CompletableFuture<KeyPermissions> projectPermissions​(@NotNull
                                                                                         @NotNull java.lang.String pluginId)
      • organizationPermissions

        public java.util.concurrent.CompletableFuture<KeyPermissions> organizationPermissions​(@NotNull
                                                                                              @NotNull java.lang.String organizationName)
      • close

        public void close()
                   throws java.io.IOException
        Specified by:
        close in interface java.lang.AutoCloseable
        Throws:
        java.io.IOException