package net.pterodactylus.sone.fcp;
import net.pterodactylus.sone.core.Core;
-import net.pterodactylus.sone.freenet.fcp.FcpException;
import freenet.support.SimpleFieldSet;
import freenet.support.api.Bucket;
* {@inheritDoc}
*/
@Override
- public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) throws FcpException {
+ public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) {
return new Response("ListLocalSones", encodeSones(getCore().getLocalSones(), "LocalSones."));
}
import net.pterodactylus.sone.core.Core;
import net.pterodactylus.sone.data.Sone;
-import net.pterodactylus.sone.freenet.fcp.FcpException;
import freenet.support.SimpleFieldSet;
import freenet.support.api.Bucket;
* {@inheritDoc}
*/
@Override
- public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) throws FcpException {
+ public Response execute(SimpleFieldSet parameters, Bucket data, AccessType accessType) {
int startSone = getInt(parameters, "StartSone", 0);
int maxSones = getInt(parameters, "MaxSones", -1);
List<Sone> sones = new ArrayList<Sone>(getCore().getSones());
package net.pterodactylus.sone.freenet;
import java.io.ByteArrayInputStream;
-import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.nio.charset.Charset;
* {@inheritDoc}
*/
@Override
- public InputStream getInputStream() throws IOException {
+ public InputStream getInputStream() {
return new ByteArrayInputStream(string.getBytes(encoding));
}
* {@inheritDoc}
*/
@Override
- public OutputStream getOutputStream() throws IOException {
+ public OutputStream getOutputStream() {
return null;
}