minor changes:

*) added annotations
*) set svn properties and added keywords to comments of parser classes
*) made a variable final to prevent (theoretical case of) change of object instance in synchronized block

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@6179 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
low012 16 years ago
parent ba7905aaa8
commit 11dfb2d54f

@ -6,7 +6,11 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//
//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
@ -118,6 +122,7 @@ public class bzipParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 24.04.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -101,6 +104,7 @@ public class docParser extends AbstractParser implements Parser {
return docParser.SUPPORTED_MIME_TYPES;
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 24.04.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -107,6 +110,7 @@ public class mimeTypeParser extends AbstractParser implements Parser {
}
@SuppressWarnings("unchecked")
@Override
public plasmaParserDocument parse(final yacyURL location, String mimeType, final String charset, final File sourceFile) throws ParserException, InterruptedException {
final String orgMimeType = mimeType;
@ -186,6 +190,7 @@ public class mimeTypeParser extends AbstractParser implements Parser {
return mimeTypeParser.SUPPORTED_MIME_TYPES;
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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

@ -1,4 +1,4 @@
//zipParser.java
//odtParser.java
//------------------------
//part of YaCy
//(C) by Michael Peter Christen; mc@yacy.net
@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -82,6 +85,7 @@ public class odtParser extends AbstractParser implements Parser {
return SUPPORTED_MIME_TYPES;
}
@Override
public plasmaParserDocument parse(final yacyURL location, final String mimeType, final String charset, final File dest) throws ParserException, InterruptedException {
Writer writer = null;
@ -226,6 +230,7 @@ public class odtParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 24.04.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -190,6 +193,7 @@ public class pdfParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -11,7 +11,6 @@
// $LastChangedRevision$
// $LastChangedBy$
//
//
//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
//the Free Software Foundation; either version 2 of the License, or
@ -90,7 +89,7 @@ public class pptParser extends AbstractParser implements Parser {
if (title.length() == l) break;
l = title.length();
}
/*
* create the plasmaParserDocument for the database
* and set shortText and bodyText properly

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2007
//
//this file is contributed by Martin Thelian
//last major change: 15.09.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -58,7 +61,7 @@ public class psParser extends AbstractParser implements Parser {
*/
private static final String[] LIBX_DEPENDENCIES = new String[] {};
private static Object modeScan = new Object();
private final static Object modeScan = new Object();
private static boolean modeScanDone = false;
private static String parserMode = "java";
@ -96,6 +99,7 @@ public class psParser extends AbstractParser implements Parser {
}
@Override
public plasmaParserDocument parse(final yacyURL location, final String mimeType, final String charset, final File sourceFile) throws ParserException, InterruptedException {
File outputFile = null;
@ -261,6 +265,7 @@ public class psParser extends AbstractParser implements Parser {
if (execCode != 0) throw new Exception("Unable to convert ps to ascii. ps2ascii returned statuscode " + execCode + "\n" + procErr.toString());
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 20.11.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -90,6 +93,7 @@ public class rpmParser extends AbstractParser implements Parser {
}
}
@Override
public plasmaParserDocument parse(final yacyURL location, final String mimeType, final String charset, final File sourceFile) throws ParserException, InterruptedException {
RPMFile rpmFile = null;
try {
@ -155,6 +159,7 @@ public class rpmParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -182,6 +185,7 @@ public class rssParser extends AbstractParser implements Parser {
return SUPPORTED_MIME_TYPES;
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -102,6 +105,7 @@ public class rtfParser extends AbstractParser implements Parser {
return rtfParser.SUPPORTED_MIME_TYPES;
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,6 +6,10 @@
// Frankfurt, Germany, 2004
//
// This file ist contributed by Franz Brausze
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
// 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
@ -61,6 +65,7 @@ public class ByteArrayIInStream extends IInStream {
return this.sbais.read();
}
@Override
public int read(final byte[] b, final int off, final int len) throws IOException {
return this.sbais.read(b, off, len);
}

@ -6,6 +6,10 @@
// Frankfurt, Germany, 2004
//
// This file ist contributed by Franz Brausze
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
// 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
@ -58,6 +62,7 @@ public class SZParserExtractCallback extends ArchiveExtractCallback {
this.prefix = prefix;
}
@Override
public void PrepareOperation(final int arg0) {
this.extractMode = (arg0 == IInArchive.NExtract_NAskMode_kExtract);
switch (arg0) {
@ -73,6 +78,7 @@ public class SZParserExtractCallback extends ArchiveExtractCallback {
}
}
@Override
public void SetOperationResult(final int arg0) throws IOException {
if (arg0 != IInArchive.NExtract_NOperationResult_kOK) {
this.NumErrors++;
@ -136,6 +142,7 @@ public class SZParserExtractCallback extends ArchiveExtractCallback {
}
}
@Override
public OutputStream GetStream(final int index, final int askExtractMode) throws IOException {
final SevenZipEntry item = super.archiveHandler.getEntry(index);
super.filePath = item.getName();

@ -6,6 +6,10 @@
// Frankfurt, Germany, 2004
//
// This file ist contributed by Franz Brausze
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
// 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
@ -91,11 +95,13 @@ public class sevenzipParser extends AbstractParser implements Parser {
}
}
@Override
public plasmaParserDocument parse(final yacyURL location, final String mimeType, final String charset,
final byte[] source) throws ParserException, InterruptedException {
return parse(location, mimeType, charset, new ByteArrayIInStream(source), Parser.MAX_KEEP_IN_MEMORY_SIZE - source.length);
}
@Override
public plasmaParserDocument parse(final yacyURL location, final String mimeType, final String charset,
final File sourceFile) throws ParserException, InterruptedException {
try {

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -230,6 +233,7 @@ public class tarParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 20.11.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$
//
//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
@ -244,6 +247,7 @@ public class vcfParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

@ -6,7 +6,10 @@
//Frankfurt, Germany, 2005
//
//this file is contributed by Martin Thelian
//last major change: 16.05.2005
//
// $LastChangedDate$
// $LastChangedRevision$
// $LastChangedBy$//last major change: 16.05.2005
//
//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
@ -214,6 +217,7 @@ public class zipParser extends AbstractParser implements Parser {
}
}
@Override
public void reset() {
// Nothing todo here at the moment
super.reset();

Loading…
Cancel
Save