test_class.declarator: EXISTING_TEMPLATE = MacKeyTemplates.HMAC_SHA256_128BITTAG
test_class.modifier: private static final
test_class.original_string: private static final KeyTemplate EXISTING_TEMPLATE = MacKeyTemplates.HMAC_SHA256_128BITTAG;
test_class.type: KeyTemplate
test_class.var_name: EXISTING_TEMPLATE
test_class.declarator: NEW_TEMPLATE = MacKeyTemplates.HMAC_SHA256_256BITTAG
test_class.modifier: private static final
test_class.original_string: private static final KeyTemplate NEW_TEMPLATE = MacKeyTemplates.HMAC_SHA256_256BITTAG;
test_class.type: KeyTemplate
test_class.var_name: NEW_TEMPLATE
test_class.declarator: OUTPUT_FORMAT = "json"
test_class.modifier: private static final
test_class.original_string: private static final String OUTPUT_FORMAT = "json";
test_class.type: String
test_class.var_name: OUTPUT_FORMAT
test_class.declarator: INPUT_FORMAT = "json"
test_class.modifier: private static final
test_class.original_string: private static final String INPUT_FORMAT = "json";
test_class.type: String
test_class.var_name: INPUT_FORMAT
test_class.file: tools/tinkey/src/test/java/com/google/crypto/tink/tinkey/RotateKeysetCommandTest.java
test_class.identifier: RotateKeysetCommandTest
test_case.body: @Test
    public void testRotateCleartext_shouldThrowExceptionIfExistingKeysetIsEmpty() throws Exception {
      InputStream emptyStream = new ByteArrayInputStream(new byte[0]);
      String masterKeyUri = null; // This ensures that the keyset won't be encrypted.
      String credentialPath = null;
      ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
  
      try {
        RotateKeysetCommand.rotate(
            outputStream, OUTPUT_FORMAT,
            emptyStream, INPUT_FORMAT,
            masterKeyUri, credentialPath, NEW_TEMPLATE);
        fail("Expected IOException");
      } catch (IOException e) {
        // expected
      }
    }
test_case.class_method_signature: RotateKeysetCommandTest.testRotateCleartext_shouldThrowExceptionIfExistingKeysetIsEmpty()
test_case.full_signature: @Test public void testRotateCleartext_shouldThrowExceptionIfExistingKeysetIsEmpty()
test_case.identifier: testRotateCleartext_shouldThrowExceptionIfExistingKeysetIsEmpty
test_case.invocations: rotate fail
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testRotateCleartext_shouldThrowExceptionIfExistingKeysetIsEmpty()
focal_class.file: tools/tinkey/src/main/java/com/google/crypto/tink/tinkey/RotateKeysetCommand.java
focal_class.identifier: RotateKeysetCommand
focal_class.interfaces: implements Command
focal_class.class_method_signature: RotateKeysetCommand.run()
focal_class.full_signature: @Override public void run()
focal_class.identifier: run
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void run()
focal_class.class_method_signature: RotateKeysetCommand.rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_class.full_signature: public static void rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_class.identifier: rotate
focal_class.modifiers: public static
focal_class.parameters: (OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_class.return: void
focal_class.signature: void rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_class.superclass: extends AddRotateOptions
focal_method.body: public static void rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate) throws Exception {
      TinkeyUtil.createKey(TinkeyUtil.CommandType.ROTATE_KEYSET, outputStream, outFormat,
          inputStream, inFormat, masterKeyUri, credentialPath, keyTemplate);
    }
focal_method.class_method_signature: RotateKeysetCommand.rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_method.full_signature: public static void rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_method.identifier: rotate
focal_method.invocations: createKey
focal_method.modifiers: public static
focal_method.parameters: (OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)
focal_method.return: void
focal_method.signature: void rotate(OutputStream outputStream, String outFormat,
        InputStream inputStream, String inFormat,
        String masterKeyUri, String credentialPath,
        KeyTemplate keyTemplate)