test_class.file: herd-code/herd-tools/herd-retention-expiration-destroyer/src/test/java/org/finra/herd/tools/retention/destroyer/RetentionExpirationDestroyerControllerTest.java
test_class.identifier: RetentionExpirationDestroyerControllerTest
test_class.superclass: extends AbstractRetentionExpirationDestroyerTest
test_case.body: @Test
      public void testGetBusinessObjectDataKeyInvalidBusinessObjectFormatVersion()
      {
          // Try to get business object data key when business object format version is not a valid integer.
          try
          {
              String[] line = {NAMESPACE, BUSINESS_OBJECT_DEFINITION_NAME, BUSINESS_OBJECT_FORMAT_USAGE, BUSINESS_OBJECT_FORMAT_FILE_TYPE, INVALID_INTEGER_VALUE,
                  PRIMARY_PARTITION_VALUE, SUB_PARTITION_VALUES.get(0), SUB_PARTITION_VALUES.get(1), SUB_PARTITION_VALUES.get(2), SUB_PARTITION_VALUES.get(3),
                  BUSINESS_OBJECT_DATA_VERSION.toString(), BUSINESS_OBJECT_DEFINITION_DISPLAY_NAME, BUSINESS_OBJECT_DEFINITION_URI};
              retentionExpirationDestroyerController.getBusinessObjectDataKey(line, LINE_NUMBER, new File(LOCAL_FILE));
              fail();
          }
          catch (IllegalArgumentException e)
          {
              assertEquals(String
                  .format("Line number %d of input file \"%s\" does not match the expected format. Business object format version must be an integer.",
                      LINE_NUMBER, LOCAL_FILE), e.getMessage());
          }
      }
test_case.class_method_signature: RetentionExpirationDestroyerControllerTest.testGetBusinessObjectDataKeyInvalidBusinessObjectFormatVersion()
test_case.full_signature: @Test public void testGetBusinessObjectDataKeyInvalidBusinessObjectFormatVersion()
test_case.identifier: testGetBusinessObjectDataKeyInvalidBusinessObjectFormatVersion
test_case.invocations: get get get get toString getBusinessObjectDataKey fail assertEquals format getMessage
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testGetBusinessObjectDataKeyInvalidBusinessObjectFormatVersion()
focal_class.declarator: CSV_FILE_HEADER_COLUMNS =
          {"Namespace", "Business Object Definition Name", "Business Object Format Usage", "Business Object Format File Type", "Business Object Format Version",
              "Primary Partition Value", "Sub-Partition Value 1", "Sub-Partition Value 2", "Sub-Partition Value 3", "Sub-Partition Value 4",
              "Business Object Data Version", "Business Object Definition Display Name", "Business Object Definition URI"}
focal_class.modifier: private static final
focal_class.original_string: private static final String[] CSV_FILE_HEADER_COLUMNS =
          {"Namespace", "Business Object Definition Name", "Business Object Format Usage", "Business Object Format File Type", "Business Object Format Version",
              "Primary Partition Value", "Sub-Partition Value 1", "Sub-Partition Value 2", "Sub-Partition Value 3", "Sub-Partition Value 4",
              "Business Object Data Version", "Business Object Definition Display Name", "Business Object Definition URI"};
focal_class.type: String[]
focal_class.var_name: CSV_FILE_HEADER_COLUMNS
focal_class.declarator: LOGGER = LoggerFactory.getLogger(RetentionExpirationDestroyerController.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger LOGGER = LoggerFactory.getLogger(RetentionExpirationDestroyerController.class);
focal_class.type: Logger
focal_class.var_name: LOGGER
focal_class.declarator: jsonHelper
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private JsonHelper jsonHelper;
focal_class.type: JsonHelper
focal_class.var_name: jsonHelper
focal_class.declarator: retentionExpirationDestroyerWebClient
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private RetentionExpirationDestroyerWebClient retentionExpirationDestroyerWebClient;
focal_class.type: RetentionExpirationDestroyerWebClient
focal_class.var_name: retentionExpirationDestroyerWebClient
focal_class.file: herd-code/herd-tools/herd-retention-expiration-destroyer/src/main/java/org/finra/herd/tools/retention/destroyer/RetentionExpirationDestroyerController.java
focal_class.identifier: RetentionExpirationDestroyerController
focal_class.class_method_signature: RetentionExpirationDestroyerController.performRetentionExpirationDestruction(File localInputFile, RegServerAccessParamsDto regServerAccessParamsDto)
focal_class.full_signature: public void performRetentionExpirationDestruction(File localInputFile, RegServerAccessParamsDto regServerAccessParamsDto)
focal_class.identifier: performRetentionExpirationDestruction
focal_class.modifiers: public
focal_class.parameters: (File localInputFile, RegServerAccessParamsDto regServerAccessParamsDto)
focal_class.return: void
focal_class.signature: void performRetentionExpirationDestruction(File localInputFile, RegServerAccessParamsDto regServerAccessParamsDto)
focal_class.class_method_signature: RetentionExpirationDestroyerController.getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
focal_class.full_signature: protected BusinessObjectDataKey getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
focal_class.identifier: getBusinessObjectDataKey
focal_class.modifiers: protected
focal_class.parameters: (String[] line, int lineNumber, File inputCsvFile)
focal_class.return: BusinessObjectDataKey
focal_class.signature: BusinessObjectDataKey getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
focal_class.class_method_signature: RetentionExpirationDestroyerController.getBusinessObjectDataKeys(File inputCsvFile)
focal_class.full_signature: protected List<BusinessObjectDataKey> getBusinessObjectDataKeys(File inputCsvFile)
focal_class.identifier: getBusinessObjectDataKeys
focal_class.modifiers: protected
focal_class.parameters: (File inputCsvFile)
focal_class.return: List<BusinessObjectDataKey>
focal_class.signature: List<BusinessObjectDataKey> getBusinessObjectDataKeys(File inputCsvFile)
focal_method.body: protected BusinessObjectDataKey getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
      {
          if (line.length != CSV_FILE_HEADER_COLUMNS.length)
          {
              throw new IllegalArgumentException(
                  String.format("Line number %d of input file \"%s\" does not match the expected format.", lineNumber, inputCsvFile.toString()));
          }
  
          Integer businessObjectFormatVersion;
          Integer businessObjectDataVersion;
  
          try
          {
              businessObjectFormatVersion = Integer.valueOf(line[4]);
          }
          catch (NumberFormatException e)
          {
              throw new IllegalArgumentException(String
                  .format("Line number %d of input file \"%s\" does not match the expected format. Business object format version must be an integer.",
                      lineNumber, inputCsvFile.toString()), e);
          }
  
          try
          {
              businessObjectDataVersion = Integer.valueOf(line[10]);
          }
          catch (NumberFormatException e)
          {
              throw new IllegalArgumentException(String
                  .format("Line number %d of input file \"%s\" does not match the expected format. Business object data version must be an integer.", lineNumber,
                      inputCsvFile.toString()), e);
          }
  
          // Build a list of optional sub-partition values.
          List<String> subPartitionValues = new ArrayList<>();
          for (String subPartitionValue : Arrays.asList(line[6], line[7], line[8], line[9]))
          {
              if (StringUtils.isNotBlank(subPartitionValue))
              {
                  subPartitionValues.add(subPartitionValue);
              }
              else
              {
                  break;
              }
          }
  
          return new BusinessObjectDataKey(line[0], line[1], line[2], line[3], businessObjectFormatVersion, line[5], subPartitionValues,
              businessObjectDataVersion);
      }
focal_method.class_method_signature: RetentionExpirationDestroyerController.getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
focal_method.full_signature: protected BusinessObjectDataKey getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)
focal_method.identifier: getBusinessObjectDataKey
focal_method.invocations: format toString valueOf format toString valueOf format toString asList isNotBlank add
focal_method.modifiers: protected
focal_method.parameters: (String[] line, int lineNumber, File inputCsvFile)
focal_method.return: BusinessObjectDataKey
focal_method.signature: BusinessObjectDataKey getBusinessObjectDataKey(String[] line, int lineNumber, File inputCsvFile)