Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
PlayWallDesktop
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
PlayWall
PlayWallDesktop
Commits
d4668c12
Commit
d4668c12
authored
5 years ago
by
Tobias Ullerich
Browse files
Options
Downloads
Patches
Plain Diff
Add update capabilities to WebAPI plugin
parent
215b079b
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
PlayWallPlugins/PlayWallPluginWebAPI/src/main/scala/de/tobias/playpad/plugin/api/WebApiPlugin.scala
+11
-3
11 additions, 3 deletions
...ain/scala/de/tobias/playpad/plugin/api/WebApiPlugin.scala
with
11 additions
and
3 deletions
PlayWallPlugins/PlayWallPluginWebAPI/src/main/scala/de/tobias/playpad/plugin/api/WebApiPlugin.scala
+
11
−
3
View file @
d4668c12
package
de.tobias.playpad.plugin.api
package
de.tobias.playpad.plugin.api
import
de.thecodelabs.logger.Logger
import
de.thecodelabs.logger.Logger
import
de.thecodelabs.plugins.
{
Plugin
,
PluginDescriptor
}
import
de.thecodelabs.plugins.
{
Plugin
Artifact
,
PluginDescriptor
}
import
de.tobias.playpad.PlayPadPlugin
import
de.tobias.playpad.PlayPadPlugin
import
de.tobias.playpad.plugin.api.websocket.WebSocketHandler
import
de.tobias.playpad.plugin.api.websocket.WebSocketHandler
import
de.tobias.playpad.plugin.api.websocket.listener.
{
PadStatusListener
,
ProjectListener
}
import
de.tobias.playpad.plugin.api.websocket.listener.
{
PadStatusListener
,
ProjectListener
}
import
de.tobias.playpad.plugin.
{
Module
,
PlayPadPluginStub
}
import
spark.Spark
import
spark.Spark
class
WebApiPlugin
extends
Plugin
{
class
WebApiPlugin
extends
PlayPadPluginStub
with
PluginArtifact
{
override
def
startup
(
pluginDescriptor
:
PluginDescriptor
)
:
Unit
=
{
private
var
module
:
Module
=
_
override
def
startup
(
descriptor
:
PluginDescriptor
)
:
Unit
=
{
module
=
new
Module
(
descriptor
.
getName
,
descriptor
.
getArtifactId
)
PlayPadPlugin
.
getInstance
().
addPadListener
(
new
PadStatusListener
)
PlayPadPlugin
.
getInstance
().
addPadListener
(
new
PadStatusListener
)
PlayPadPlugin
.
getInstance
().
addGlobalListener
(
new
ProjectListener
)
PlayPadPlugin
.
getInstance
().
addGlobalListener
(
new
ProjectListener
)
...
@@ -24,4 +30,6 @@ class WebApiPlugin extends Plugin {
...
@@ -24,4 +30,6 @@ class WebApiPlugin extends Plugin {
Spark
.
stop
()
Spark
.
stop
()
}
}
override
def
getModule
:
Module
=
module
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment