test_class.file: jhove-ext-modules/src/test/java/edu/harvard/hul/ois/jhove/module/WarcModuleTest.java
test_class.identifier: WarcModuleTest
test_case.body: @Test
      public void parseInvalidEmptyFile() throws Exception {
  		File warcFile = new File("src/test/resources/warc/invalid-empty.warc");
  
  		WarcModule wm = new WarcModule();
          RepInfo info = new RepInfo(warcFile.getAbsolutePath());
          wm.parse(new FileInputStream(warcFile), info, 0);
          
          invalidCheck(info);
          
          assertEquals(1, info.getMessage().size());
          Map<String, Integer> messages = extractMessages(info.getMessage());
          assertEquals(1, messages.size());
          assertEquals(1, messages.get(DiagnosisType.ERROR_EXPECTED.name()).intValue());
  	}
test_case.class_method_signature: WarcModuleTest.parseInvalidEmptyFile()
test_case.full_signature: @Test public void parseInvalidEmptyFile()
test_case.identifier: parseInvalidEmptyFile
test_case.invocations: getAbsolutePath parse invalidCheck assertEquals size getMessage extractMessages getMessage assertEquals size assertEquals intValue get name
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void parseInvalidEmptyFile()
focal_class.declarator: KB_AGENT = new Builder(
              "Royal Library of Denmark", AgentType.STANDARD)
              .address("Søren Kierkegaards Plads 1, 1219 København K, Denmark")
              .fax("+45 3393 2218")
              .web("http://kb.dk").build()
focal_class.modifier: private static final
focal_class.original_string: private static final Agent KB_AGENT = new Builder(
              "Royal Library of Denmark", AgentType.STANDARD)
              .address("Søren Kierkegaards Plads 1, 1219 København K, Denmark")
              .fax("+45 3393 2218")
              .web("http://kb.dk").build();
focal_class.type: Agent
focal_class.var_name: KB_AGENT
focal_class.declarator: NAME = "WARC-kb"
focal_class.modifier: private static final
focal_class.original_string: private static final String NAME = "WARC-kb";
focal_class.type: String
focal_class.var_name: NAME
focal_class.declarator: RELEASE = "1.0"
focal_class.modifier: private static final
focal_class.original_string: private static final String RELEASE = "1.0";
focal_class.type: String
focal_class.var_name: RELEASE
focal_class.declarator: DATE = {2015, 12, 07}
focal_class.modifier: private static final
focal_class.original_string: private static final int[] DATE = {2015, 12, 07};
focal_class.type: int[]
focal_class.var_name: DATE
focal_class.declarator: FORMAT = {
              "WARC", "WARC, Web ARChive file format"
      }
focal_class.modifier: private static final
focal_class.original_string: private static final String[] FORMAT = {
              "WARC", "WARC, Web ARChive file format"
      };
focal_class.type: String[]
focal_class.var_name: FORMAT
focal_class.declarator: COVERAGE = "WARC, 28500:2009"
focal_class.modifier: private static final
focal_class.original_string: private static final String COVERAGE = "WARC, 28500:2009";
focal_class.type: String
focal_class.var_name: COVERAGE
focal_class.declarator: MIMETYPE = {"application/warc", "application/warc-fields"}
focal_class.modifier: private static final
focal_class.original_string: private static final String[] MIMETYPE = {"application/warc", "application/warc-fields"};
focal_class.type: String[]
focal_class.var_name: MIMETYPE
focal_class.declarator: WELLFORMED = ""
focal_class.modifier: private static final
focal_class.original_string: private static final String WELLFORMED = "";
focal_class.type: String
focal_class.var_name: WELLFORMED
focal_class.declarator: VALIDITY = "The file is well-formed"
focal_class.modifier: private static final
focal_class.original_string: private static final String VALIDITY = "The file is well-formed";
focal_class.type: String
focal_class.var_name: VALIDITY
focal_class.declarator: REPINFO = ""
focal_class.modifier: private static final
focal_class.original_string: private static final String REPINFO = "";
focal_class.type: String
focal_class.var_name: REPINFO
focal_class.declarator: NOTE = ""
focal_class.modifier: private static final
focal_class.original_string: private static final String NOTE = "";
focal_class.type: String
focal_class.var_name: NOTE
focal_class.declarator: RIGHTS = "Copyright 2015 by The Royal Library of Denmark. " +
              "Released under the GNU Lesser General Public License."
focal_class.modifier: private static final
focal_class.original_string: private static final String RIGHTS = "Copyright 2015 by The Royal Library of Denmark. " +
              "Released under the GNU Lesser General Public License.";
focal_class.type: String
focal_class.var_name: RIGHTS
focal_class.declarator: DEFAULT_COMPUTE_BLOCK_DIGEST = Boolean.TRUE
focal_class.modifier: private static final
focal_class.original_string: private static final Boolean DEFAULT_COMPUTE_BLOCK_DIGEST = Boolean.TRUE;
focal_class.type: Boolean
focal_class.var_name: DEFAULT_COMPUTE_BLOCK_DIGEST
focal_class.declarator: DEFAULT_BLOCK_DIGEST_ALGORITHM = "sha1"
focal_class.modifier: private static final
focal_class.original_string: private static final String DEFAULT_BLOCK_DIGEST_ALGORITHM = "sha1";
focal_class.type: String
focal_class.var_name: DEFAULT_BLOCK_DIGEST_ALGORITHM
focal_class.declarator: DEFAULT_BLOCK_DIGEST_ENCODING = "base32"
focal_class.modifier: private static final
focal_class.original_string: private static final String DEFAULT_BLOCK_DIGEST_ENCODING = "base32";
focal_class.type: String
focal_class.var_name: DEFAULT_BLOCK_DIGEST_ENCODING
focal_class.declarator: DEFAULT_COMPUTE_PAYLOAD_DIGEST = Boolean.TRUE
focal_class.modifier: private static final
focal_class.original_string: private static final Boolean DEFAULT_COMPUTE_PAYLOAD_DIGEST = Boolean.TRUE;
focal_class.type: Boolean
focal_class.var_name: DEFAULT_COMPUTE_PAYLOAD_DIGEST
focal_class.declarator: DEFAULT_PAYLOAD_DIGEST_ALGORITHM = "sha1"
focal_class.modifier: private static final
focal_class.original_string: private static final String DEFAULT_PAYLOAD_DIGEST_ALGORITHM = "sha1";
focal_class.type: String
focal_class.var_name: DEFAULT_PAYLOAD_DIGEST_ALGORITHM
focal_class.declarator: DEFAULT_PAYLOAD_DIGEST_ENCODING = "base32"
focal_class.modifier: private static final
focal_class.original_string: private static final String DEFAULT_PAYLOAD_DIGEST_ENCODING = "base32";
focal_class.type: String
focal_class.var_name: DEFAULT_PAYLOAD_DIGEST_ENCODING
focal_class.declarator: DEFAULT_STRICT_TARGET_URI_VALIDATION = Boolean.FALSE
focal_class.modifier: private static final
focal_class.original_string: private static final Boolean DEFAULT_STRICT_TARGET_URI_VALIDATION = Boolean.FALSE;
focal_class.type: Boolean
focal_class.var_name: DEFAULT_STRICT_TARGET_URI_VALIDATION
focal_class.declarator: DEFAULT_STRICT_URI_VALIDATION = Boolean.FALSE
focal_class.modifier: private static final
focal_class.original_string: private static final Boolean DEFAULT_STRICT_URI_VALIDATION = Boolean.FALSE;
focal_class.type: Boolean
focal_class.var_name: DEFAULT_STRICT_URI_VALIDATION
focal_class.declarator: bComputeBlockDigest
focal_class.modifier: private
focal_class.original_string: private boolean bComputeBlockDigest;
focal_class.type: boolean
focal_class.var_name: bComputeBlockDigest
focal_class.declarator: blockDigestAlgorithm
focal_class.modifier: private
focal_class.original_string: private String blockDigestAlgorithm;
focal_class.type: String
focal_class.var_name: blockDigestAlgorithm
focal_class.declarator: blockDigestEncoding
focal_class.modifier: private
focal_class.original_string: private String blockDigestEncoding;
focal_class.type: String
focal_class.var_name: blockDigestEncoding
focal_class.declarator: bComputePayloadDigest
focal_class.modifier: private
focal_class.original_string: private boolean bComputePayloadDigest;
focal_class.type: boolean
focal_class.var_name: bComputePayloadDigest
focal_class.declarator: payloadDigestAlgorithm
focal_class.modifier: private
focal_class.original_string: private String payloadDigestAlgorithm;
focal_class.type: String
focal_class.var_name: payloadDigestAlgorithm
focal_class.declarator: payloadDigestEncoding
focal_class.modifier: private
focal_class.original_string: private String payloadDigestEncoding;
focal_class.type: String
focal_class.var_name: payloadDigestEncoding
focal_class.declarator: bStrictTargetUriValidation
focal_class.modifier: private
focal_class.original_string: private boolean bStrictTargetUriValidation;
focal_class.type: boolean
focal_class.var_name: bStrictTargetUriValidation
focal_class.declarator: bStrictUriValidation
focal_class.modifier: private
focal_class.original_string: private boolean bStrictUriValidation;
focal_class.type: boolean
focal_class.var_name: bStrictUriValidation
focal_class.declarator: versions
focal_class.modifier: private
focal_class.original_string: private Map<String, Integer> versions;
focal_class.type: Map<String, Integer>
focal_class.var_name: versions
focal_class.declarator: recordProperties
focal_class.modifier: private
focal_class.original_string: private List<Property> recordProperties;
focal_class.type: List<Property>
focal_class.var_name: recordProperties
focal_class.file: jhove-ext-modules/src/main/java/edu/harvard/hul/ois/jhove/module/WarcModule.java
focal_class.identifier: WarcModule
focal_class.class_method_signature: WarcModule.WarcModule()
focal_class.full_signature: public  WarcModule()
focal_class.identifier: WarcModule
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  WarcModule()
focal_class.class_method_signature: WarcModule.setVendorAndSpecification()
focal_class.full_signature: private void setVendorAndSpecification()
focal_class.identifier: setVendorAndSpecification
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void setVendorAndSpecification()
focal_class.class_method_signature: WarcModule.initialiseVariables()
focal_class.full_signature: private void initialiseVariables()
focal_class.identifier: initialiseVariables
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void initialiseVariables()
focal_class.class_method_signature: WarcModule.resetParams()
focal_class.full_signature: @Override public void resetParams()
focal_class.identifier: resetParams
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void resetParams()
focal_class.class_method_signature: WarcModule.checkSignatures(File file,
              InputStream stream,
              RepInfo info)
focal_class.full_signature: @Override public void checkSignatures(File file,
              InputStream stream,
              RepInfo info)
focal_class.identifier: checkSignatures
focal_class.modifiers: @Override public
focal_class.parameters: (File file,
              InputStream stream,
              RepInfo info)
focal_class.return: void
focal_class.signature: void checkSignatures(File file,
              InputStream stream,
              RepInfo info)
focal_class.class_method_signature: WarcModule.checkSignatures(File file,
              RandomAccessFile raf,
              RepInfo info)
focal_class.full_signature: @Override public void checkSignatures(File file,
              RandomAccessFile raf,
              RepInfo info)
focal_class.identifier: checkSignatures
focal_class.modifiers: @Override public
focal_class.parameters: (File file,
              RandomAccessFile raf,
              RepInfo info)
focal_class.return: void
focal_class.signature: void checkSignatures(File file,
              RandomAccessFile raf,
              RepInfo info)
focal_class.class_method_signature: WarcModule.parse(RandomAccessFile file, RepInfo info)
focal_class.full_signature: @Override public void parse(RandomAccessFile file, RepInfo info)
focal_class.identifier: parse
focal_class.modifiers: @Override public
focal_class.parameters: (RandomAccessFile file, RepInfo info)
focal_class.return: void
focal_class.signature: void parse(RandomAccessFile file, RepInfo info)
focal_class.class_method_signature: WarcModule.parse(InputStream stream, RepInfo info, int parseIndex)
focal_class.full_signature: @Override public int parse(InputStream stream, RepInfo info, int parseIndex)
focal_class.identifier: parse
focal_class.modifiers: @Override public
focal_class.parameters: (InputStream stream, RepInfo info, int parseIndex)
focal_class.return: int
focal_class.signature: int parse(InputStream stream, RepInfo info, int parseIndex)
focal_class.class_method_signature: WarcModule.setReaderOptions(WarcReader reader)
focal_class.full_signature: protected void setReaderOptions(WarcReader reader)
focal_class.identifier: setReaderOptions
focal_class.modifiers: protected
focal_class.parameters: (WarcReader reader)
focal_class.return: void
focal_class.signature: void setReaderOptions(WarcReader reader)
focal_class.class_method_signature: WarcModule.parseRecords(WarcReader reader)
focal_class.full_signature: protected void parseRecords(WarcReader reader)
focal_class.identifier: parseRecords
focal_class.modifiers: protected
focal_class.parameters: (WarcReader reader)
focal_class.return: void
focal_class.signature: void parseRecords(WarcReader reader)
focal_class.class_method_signature: WarcModule.processRecord(WarcRecord record)
focal_class.full_signature: protected void processRecord(WarcRecord record)
focal_class.identifier: processRecord
focal_class.modifiers: protected
focal_class.parameters: (WarcRecord record)
focal_class.return: void
focal_class.signature: void processRecord(WarcRecord record)
focal_class.class_method_signature: WarcModule.reportResults(WarcReader reader, RepInfo repInfo)
focal_class.full_signature: private void reportResults(WarcReader reader, RepInfo repInfo)
focal_class.identifier: reportResults
focal_class.modifiers: private
focal_class.parameters: (WarcReader reader, RepInfo repInfo)
focal_class.return: void
focal_class.signature: void reportResults(WarcReader reader, RepInfo repInfo)
focal_class.class_method_signature: WarcModule.extractDiagnosisType(Diagnosis d)
focal_class.full_signature: private static String extractDiagnosisType(Diagnosis d)
focal_class.identifier: extractDiagnosisType
focal_class.modifiers: private static
focal_class.parameters: (Diagnosis d)
focal_class.return: String
focal_class.signature: String extractDiagnosisType(Diagnosis d)
focal_class.class_method_signature: WarcModule.extractDiagnosisMessage(Diagnosis d)
focal_class.full_signature: private static String extractDiagnosisMessage(Diagnosis d)
focal_class.identifier: extractDiagnosisMessage
focal_class.modifiers: private static
focal_class.parameters: (Diagnosis d)
focal_class.return: String
focal_class.signature: String extractDiagnosisMessage(Diagnosis d)
focal_class.superclass: extends ModuleBase
focal_method.body: @Override
      public void parse(RandomAccessFile file, RepInfo info) throws IOException {
          try (InputStream stream = new RandomAccessFileInputStream(file)) {
              parse(stream, info, 0);
          }
      }
focal_method.class_method_signature: WarcModule.parse(RandomAccessFile file, RepInfo info)
focal_method.full_signature: @Override public void parse(RandomAccessFile file, RepInfo info)
focal_method.identifier: parse
focal_method.invocations: parse
focal_method.modifiers: @Override public
focal_method.parameters: (RandomAccessFile file, RepInfo info)
focal_method.return: void
focal_method.signature: void parse(RandomAccessFile file, RepInfo info)