X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Ffcp%2FVersionCommand.java;h=7220fc8d2ea133b32e5378cf1c90d220dbfec26e;hb=0ae4db6f172db754840808595719c595dcc7b7bc;hp=681747661dcfc30e715196c92144700b101759cf;hpb=45208b1b2ce354f252ef5278bf165395c806c765;p=Sone.git diff --git a/src/main/java/net/pterodactylus/sone/fcp/VersionCommand.java b/src/main/java/net/pterodactylus/sone/fcp/VersionCommand.java index 6817476..7220fc8 100644 --- a/src/main/java/net/pterodactylus/sone/fcp/VersionCommand.java +++ b/src/main/java/net/pterodactylus/sone/fcp/VersionCommand.java @@ -1,5 +1,5 @@ /* - * Sone - VersionCommand.java - Copyright © 2011 David Roden + * Sone - VersionCommand.java - Copyright © 2011–2013 David Roden * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -17,8 +17,8 @@ package net.pterodactylus.sone.fcp; +import net.pterodactylus.sone.core.Core; import net.pterodactylus.sone.freenet.SimpleFieldSetBuilder; -import net.pterodactylus.sone.freenet.fcp.Command; import net.pterodactylus.sone.main.SonePlugin; import freenet.support.SimpleFieldSet; import freenet.support.api.Bucket; @@ -28,11 +28,18 @@ import freenet.support.api.Bucket; * * @author David ‘Bombe’ Roden */ -public class VersionCommand implements Command { +public class VersionCommand extends AbstractSoneCommand { /** - * {@inheritDoc} + * Creates a new “Version” FCP command. + * + * @param core + * The Sone core */ + protected VersionCommand(Core core) { + super(core); + } + @Override public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) { return new Response("Version", new SimpleFieldSetBuilder().put("Version", SonePlugin.VERSION.toString()).put("ProtocolVersion", 1).get());