@Test public void testToListOfLowerCaseValues() { List<String> output; output = DPSArchive.toListOfLowerCaseValues("HTML Serial Type 1 - eJournals, HTML Serial Type 2 - Manuscripts , HTML Serial Type 3 - Blogs "); assertNotNull(output); assertEquals(3, output.size()); assertEquals("html serial type 1 - ejournals", output.get(0)); assertEquals("html serial type 2 - manuscripts", output.get(1)); assertEquals("html serial type 3 - blogs", output.get(2)); output = DPSArchive.toListOfLowerCaseValues("Electronic Journals and Serials"); assertNotNull(output); assertEquals(1, output.size()); assertEquals("electronic journals and serials", output.get(0)); output = DPSArchive.toListOfLowerCaseValues(" Electronic Journals and Serials "); assertNotNull(output); assertEquals(1, output.size()); assertEquals("electronic journals and serials", output.get(0)); output = DPSArchive.toListOfLowerCaseValues(null); assertNotNull(output); assertEquals(0, output.size()); output = DPSArchive.toListOfLowerCaseValues(" "); assertNotNull(output); assertEquals(0, output.size()); output = DPSArchive.toListOfLowerCaseValues(" , , "); assertNotNull(output); assertEquals(0, output.size()); }
protected static List<String> toListOfLowerCaseValues(String commaSeparatedString) { List<String> theList = new ArrayList<String>(); if (commaSeparatedString == null) return theList; String[] tokens = commaSeparatedString.split("[,]"); for (int i = 0; i< tokens.length; i++) { String token = tokens[i]; if (token == null || token.trim().length() <= 0) continue; theList.add(token.trim().toLowerCase()); } return theList; }
DPSArchive extends BaseArchive { protected static List<String> toListOfLowerCaseValues(String commaSeparatedString) { List<String> theList = new ArrayList<String>(); if (commaSeparatedString == null) return theList; String[] tokens = commaSeparatedString.split("[,]"); for (int i = 0; i< tokens.length; i++) { String token = tokens[i]; if (token == null || token.trim().length() <= 0) continue; theList.add(token.trim().toLowerCase()); } return theList; } }
DPSArchive extends BaseArchive { protected static List<String> toListOfLowerCaseValues(String commaSeparatedString) { List<String> theList = new ArrayList<String>(); if (commaSeparatedString == null) return theList; String[] tokens = commaSeparatedString.split("[,]"); for (int i = 0; i< tokens.length; i++) { String token = tokens[i]; if (token == null || token.trim().length() <= 0) continue; theList.add(token.trim().toLowerCase()); } return theList; }  }
DPSArchive extends BaseArchive { protected static List<String> toListOfLowerCaseValues(String commaSeparatedString) { List<String> theList = new ArrayList<String>(); if (commaSeparatedString == null) return theList; String[] tokens = commaSeparatedString.split("[,]"); for (int i = 0; i< tokens.length; i++) { String token = tokens[i]; if (token == null || token.trim().length() <= 0) continue; theList.add(token.trim().toLowerCase()); } return theList; }  @SuppressWarnings("unchecked") String submitToArchive(String targetInstanceOID, String SIP, Map xAttributes, List<ArchiveFile> fileList); CustomDepositFormResultDTO getCustomDepositFormDetails(CustomDepositFormCriteriaDTO criteria); boolean validateProducerAgentName(String producerAgent); boolean isLoginSuccessful(String producerAgent, String agentPassword); DepData[] getProducer(String producerAgentUserId, boolean fromCache); DepData getProducer(String producerAgentUserId, String producerId); DepData[] getMaterialFlows(String producerID); boolean validateMaterialFlowAssociation(String producerId, String targetDcType); void setPdsUrl(String pdsUrl); void setFtpHost(String ftpHost); void setFtpUserName(String ftpUserName); void setFtpPassword(String ftpPassword); void setFtpDirectory(String ftpDirectory); void setDepositServerBaseUrl(String depositServerBaseUrl); void setDpsUserInstitution(String dpsUserInstitution); void setDpsUserName(String dpsUserName); void setDpsUserPassword(String dpsUserPassword); void setMaterialFlowId(String materialFlowId); void setProducerId(String producerId); void setProducerWsdlRelativePath(String producerWsdlRelativePath); void setDepositWsdlRelativePath(String depositWsdlRelativePath); void setAgenciesResponsibleForHtmlSerials(String agenciesResponsibleForHtmlSerials); void setTargetDCTypesOfHtmlSerials(String targetDCTypesOfHtmlSerials); void setMaterialFlowsOfHtmlSerials(String materialFlowsOfHtmlSerials); void setProducerIdsOfHtmlSerials(String producerIdsOfHtmlSerials); void setIeEntityTypesOfHtmlSerials(String ieEntityTypesOfHtmlSerials); void setCustomDepositFormURLsForHtmlSerialIngest(String customDepositFormURLsForHtmlSerialIngest); void setRestrictHTMLSerialAgenciesToHTMLSerialTypes(String restrictHTMLSerialAgenciesToHTMLSerialTypes); void setTargetDCTypesOfCustomWebHarvest(String targetDCTypesOfCustomWebHarvest); void setMaterialFlowsOfCustomWebHarvest(String materialFlowsOfCustomWebHarvest); void setProducerIdsOfCustomWebHarvest(String producerIdsOfCustomWebHarvest); void setIeEntityTypesOfCustomWebHarvest(String ieEntityTypesOfCustomWebHarvest); void setDCTitleSourceOfCustomWebHarvest(String DCTitleSourceOfCustomWebHarvest); void setOmsOpenAccess(String omsOpenAccess); void setOmsPublishedRestricted(String omsPublishedRestricted); void setOmsUnpublishedRestrictedByLocation(String omsUnpublishedRestrictedByLocation); void setOmsUnpublishedRestrictedByPersion(String omsUnpublishedRestrictedByPersion); void setCmsSection(String cmsSection); void setCmsSystem(String cmsSystem); void setCustomDepositFormMapping(CustomDepositFormMapping customDepositFormMapping); }
DPSArchive extends BaseArchive { protected static List<String> toListOfLowerCaseValues(String commaSeparatedString) { List<String> theList = new ArrayList<String>(); if (commaSeparatedString == null) return theList; String[] tokens = commaSeparatedString.split("[,]"); for (int i = 0; i< tokens.length; i++) { String token = tokens[i]; if (token == null || token.trim().length() <= 0) continue; theList.add(token.trim().toLowerCase()); } return theList; }  @SuppressWarnings("unchecked") String submitToArchive(String targetInstanceOID, String SIP, Map xAttributes, List<ArchiveFile> fileList); CustomDepositFormResultDTO getCustomDepositFormDetails(CustomDepositFormCriteriaDTO criteria); boolean validateProducerAgentName(String producerAgent); boolean isLoginSuccessful(String producerAgent, String agentPassword); DepData[] getProducer(String producerAgentUserId, boolean fromCache); DepData getProducer(String producerAgentUserId, String producerId); DepData[] getMaterialFlows(String producerID); boolean validateMaterialFlowAssociation(String producerId, String targetDcType); void setPdsUrl(String pdsUrl); void setFtpHost(String ftpHost); void setFtpUserName(String ftpUserName); void setFtpPassword(String ftpPassword); void setFtpDirectory(String ftpDirectory); void setDepositServerBaseUrl(String depositServerBaseUrl); void setDpsUserInstitution(String dpsUserInstitution); void setDpsUserName(String dpsUserName); void setDpsUserPassword(String dpsUserPassword); void setMaterialFlowId(String materialFlowId); void setProducerId(String producerId); void setProducerWsdlRelativePath(String producerWsdlRelativePath); void setDepositWsdlRelativePath(String depositWsdlRelativePath); void setAgenciesResponsibleForHtmlSerials(String agenciesResponsibleForHtmlSerials); void setTargetDCTypesOfHtmlSerials(String targetDCTypesOfHtmlSerials); void setMaterialFlowsOfHtmlSerials(String materialFlowsOfHtmlSerials); void setProducerIdsOfHtmlSerials(String producerIdsOfHtmlSerials); void setIeEntityTypesOfHtmlSerials(String ieEntityTypesOfHtmlSerials); void setCustomDepositFormURLsForHtmlSerialIngest(String customDepositFormURLsForHtmlSerialIngest); void setRestrictHTMLSerialAgenciesToHTMLSerialTypes(String restrictHTMLSerialAgenciesToHTMLSerialTypes); void setTargetDCTypesOfCustomWebHarvest(String targetDCTypesOfCustomWebHarvest); void setMaterialFlowsOfCustomWebHarvest(String materialFlowsOfCustomWebHarvest); void setProducerIdsOfCustomWebHarvest(String producerIdsOfCustomWebHarvest); void setIeEntityTypesOfCustomWebHarvest(String ieEntityTypesOfCustomWebHarvest); void setDCTitleSourceOfCustomWebHarvest(String DCTitleSourceOfCustomWebHarvest); void setOmsOpenAccess(String omsOpenAccess); void setOmsPublishedRestricted(String omsPublishedRestricted); void setOmsUnpublishedRestrictedByLocation(String omsUnpublishedRestrictedByLocation); void setOmsUnpublishedRestrictedByPersion(String omsUnpublishedRestrictedByPersion); void setCmsSection(String cmsSection); void setCmsSystem(String cmsSystem); void setCustomDepositFormMapping(CustomDepositFormMapping customDepositFormMapping);  }