test_class.file: src/de/slackspace/openkeepass/parser/KeyFileXmlParserTest.java
test_class.identifier: KeyFileXmlParserTest
test_case.body: @Test
      public void whenInputIsKeyFileShouldParseFileAndReturnCorrectData() throws IOException {
          FileInputStream fileInputStream = new FileInputStream(ResourceUtils.getResource("DatabaseWithKeyfile.key"));
          byte[] keyFileContent = StreamUtils.toByteArray(fileInputStream);
  
          SimpleXmlParser parser = new SimpleXmlParser();
          KeyFile keyFile = new KeyFileXmlParser(parser).fromXml(keyFileContent);
  
          Assert.assertEquals("RP+rYNZL4lrGtDMBPzOuctlh3NAutSG5KGsT38C+qPQ=", keyFile.getKey().getData());
      }
test_case.class_method_signature: KeyFileXmlParserTest.whenInputIsKeyFileShouldParseFileAndReturnCorrectData()
test_case.full_signature: @Test public void whenInputIsKeyFileShouldParseFileAndReturnCorrectData()
test_case.identifier: whenInputIsKeyFileShouldParseFileAndReturnCorrectData
test_case.invocations: getResource toByteArray fromXml assertEquals getData getKey
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void whenInputIsKeyFileShouldParseFileAndReturnCorrectData()
focal_class.declarator: UTF_8 = "UTF-8"
focal_class.modifier: private static final
focal_class.original_string: private static final String UTF_8 = "UTF-8";
focal_class.type: String
focal_class.var_name: UTF_8
focal_class.declarator: MSG_UTF8_NOT_SUPPORTED = "The encoding UTF-8 is not supported"
focal_class.modifier: private static final
focal_class.original_string: private static final String MSG_UTF8_NOT_SUPPORTED = "The encoding UTF-8 is not supported";
focal_class.type: String
focal_class.var_name: MSG_UTF8_NOT_SUPPORTED
focal_class.declarator: parser
focal_class.modifier: private final
focal_class.original_string: private final XmlParser parser;
focal_class.type: XmlParser
focal_class.var_name: parser
focal_class.file: src/de/slackspace/openkeepass/parser/KeyFileXmlParser.java
focal_class.identifier: KeyFileXmlParser
focal_class.interfaces: implements KeyFileParser
focal_class.class_method_signature: KeyFileXmlParser.KeyFileXmlParser(XmlParser parser)
focal_class.full_signature: public  KeyFileXmlParser(XmlParser parser)
focal_class.identifier: KeyFileXmlParser
focal_class.modifiers: public
focal_class.parameters: (XmlParser parser)
focal_class.signature:  KeyFileXmlParser(XmlParser parser)
focal_class.class_method_signature: KeyFileXmlParser.readKeyFile(byte[] keyFile)
focal_class.full_signature: @Override public KeyFileBytes readKeyFile(byte[] keyFile)
focal_class.identifier: readKeyFile
focal_class.modifiers: @Override public
focal_class.parameters: (byte[] keyFile)
focal_class.return: KeyFileBytes
focal_class.signature: KeyFileBytes readKeyFile(byte[] keyFile)
focal_class.class_method_signature: KeyFileXmlParser.fromXml(byte[] inputBytes)
focal_class.full_signature: public KeyFile fromXml(byte[] inputBytes)
focal_class.identifier: fromXml
focal_class.modifiers: public
focal_class.parameters: (byte[] inputBytes)
focal_class.return: KeyFile
focal_class.signature: KeyFile fromXml(byte[] inputBytes)
focal_class.class_method_signature: KeyFileXmlParser.getBytesFromKeyFile(KeyFile keyFile)
focal_class.full_signature: private byte[] getBytesFromKeyFile(KeyFile keyFile)
focal_class.identifier: getBytesFromKeyFile
focal_class.modifiers: private
focal_class.parameters: (KeyFile keyFile)
focal_class.return: byte[]
focal_class.signature: byte[] getBytesFromKeyFile(KeyFile keyFile)
focal_method.body: public KeyFile fromXml(byte[] inputBytes) {
          try {
              ByteArrayInputStream inputStream = new ByteArrayInputStream(inputBytes);
              return parser.fromXml(inputStream, null, KeyFile.class);
          } catch (KeePassDatabaseUnreadableException e) {
              return new KeyFile(false);
          }
      }
focal_method.class_method_signature: KeyFileXmlParser.fromXml(byte[] inputBytes)
focal_method.full_signature: public KeyFile fromXml(byte[] inputBytes)
focal_method.identifier: fromXml
focal_method.invocations: fromXml
focal_method.modifiers: public
focal_method.parameters: (byte[] inputBytes)
focal_method.return: KeyFile
focal_method.signature: KeyFile fromXml(byte[] inputBytes)