当前位置: 首页>>代码示例>>Java>>正文


Java CleanUtils.cleanSlashes方法代码示例

本文整理汇总了Java中org.mtransit.parser.CleanUtils.cleanSlashes方法的典型用法代码示例。如果您正苦于以下问题:Java CleanUtils.cleanSlashes方法的具体用法?Java CleanUtils.cleanSlashes怎么用?Java CleanUtils.cleanSlashes使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.mtransit.parser.CleanUtils的用法示例。


在下文中一共展示了CleanUtils.cleanSlashes方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: cleanStopName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanStopName(String gStopName) {
	gStopName = gStopName.toLowerCase(Locale.ENGLISH);
	gStopName = CleanUtils.cleanSlashes(gStopName);
	gStopName = BOUND.matcher(gStopName).replaceAll(SPACE);
	gStopName = CleanUtils.SAINT.matcher(gStopName).replaceAll(CleanUtils.SAINT_REPLACEMENT);
	gStopName = AT_LIKE.matcher(gStopName).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	gStopName = CleanUtils.CLEAN_AT.matcher(gStopName).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	gStopName = CleanUtils.CLEAN_AND.matcher(gStopName).replaceAll(CleanUtils.CLEAN_AND_REPLACEMENT);
	gStopName = FLAG_STOP.matcher(gStopName).replaceAll(FLAG_STOP_REPLACEMENT);
	gStopName = UNLOADING.matcher(gStopName).replaceAll(StringUtils.EMPTY);
	gStopName = ENDS_WITH_DASHES.matcher(gStopName).replaceAll(StringUtils.EMPTY);
	gStopName = EXCHANGE.matcher(gStopName).replaceAll(EXCHANGE_REPLACEMENT);
	gStopName = STATION.matcher(gStopName).replaceAll(STATION_REPLACEMENT);
	gStopName = S_F_U.matcher(gStopName).replaceAll(S_F_U_REPLACEMENT);
	gStopName = U_B_C.matcher(gStopName).replaceAll(U_B_C_REPLACEMENT);
	gStopName = V_C_C.matcher(gStopName).replaceAll(V_C_C_REPLACEMENT);
	gStopName = CENTRAL.matcher(gStopName).replaceAll(CENTER_REPLACEMENT);
	gStopName = STARTS_WITH_AT.matcher(gStopName).replaceAll(StringUtils.EMPTY);
	gStopName = CleanUtils.cleanStreetTypes(gStopName);
	return CleanUtils.cleanLabel(gStopName);
}
 
开发者ID:mtransitapps,项目名称:ca-vancouver-translink-bus-parser,代码行数:23,代码来源:VancouverTransLinkBusAgencyTools.java

示例2: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = CleanUtils.CLEAN_AT.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	tripHeadsign = CleanUtils.CLEAN_AND.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_AND_REPLACEMENT);
	tripHeadsign = CleanUtils.cleanNumbers(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypes(tripHeadsign);
	return CleanUtils.cleanLabel(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:us-everett-transit-bus-parser,代码行数:10,代码来源:EverettTransitBusAgencyTools.java

示例3: cleanStopName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanStopName(String gStopName) {
	gStopName = gStopName.toLowerCase(Locale.ENGLISH);
	gStopName = CleanUtils.SAINT.matcher(gStopName).replaceAll(CleanUtils.SAINT_REPLACEMENT);
	gStopName = CleanUtils.CLEAN_AND.matcher(gStopName).replaceAll(CleanUtils.CLEAN_AND_REPLACEMENT);
	gStopName = CleanUtils.CLEAN_AT.matcher(gStopName).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	gStopName = CleanUtils.cleanSlashes(gStopName);
	gStopName = CleanUtils.removePoints(gStopName);
	gStopName = CleanUtils.cleanStreetTypes(gStopName);
	return CleanUtils.cleanLabel(gStopName);
}
 
开发者ID:mtransitapps,项目名称:us-everett-transit-bus-parser,代码行数:12,代码来源:EverettTransitBusAgencyTools.java

示例4: getRouteLongName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String getRouteLongName(GRoute gRoute) {
	String routeLongName = gRoute.getRouteLongName();
	routeLongName = CleanUtils.cleanSlashes(routeLongName);
	routeLongName = CleanUtils.cleanNumbers(routeLongName);
	routeLongName = CleanUtils.cleanStreetTypes(routeLongName);
	return CleanUtils.cleanLabel(routeLongName);
}
 
开发者ID:mtransitapps,项目名称:ca-central-fraser-valley-transit-system-bus-parser,代码行数:9,代码来源:CentralFraserValleyTransitSystemBusAgencyTools.java

示例5: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	int indexOfVIA = tripHeadsign.toLowerCase(Locale.ENGLISH).indexOf(VIA);
	if (indexOfVIA >= 0) {
		tripHeadsign = tripHeadsign.substring(0, indexOfVIA);
	}
	tripHeadsign = CleanUtils.removePoints(tripHeadsign);
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypes(tripHeadsign);
	return CleanUtils.cleanLabel(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:ca-kingston-transit-bus-parser,代码行数:12,代码来源:KingstonTransitBusAgencyTools.java

示例6: cleanStopName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanStopName(String gStopName) {
	gStopName = CleanUtils.cleanSlashes(gStopName);
	gStopName = EXCHANGE_.matcher(gStopName).replaceAll(EXCHANGE_REPLACEMENT);
	gStopName = GOVERNMENT_CENTRE.matcher(gStopName).replaceAll(GOVERNMENT_CENTRE_REPLACEMENT);
	gStopName = UNIVERSITY_OF_ALBERTA.matcher(gStopName).replaceAll(UNIVERSITY_OF_ALBERTA_REPLACEMENT);
	gStopName = SIR_WINSTON_CHURCHILL.matcher(gStopName).replaceAll(SIR_WINSTON_CHURCHILL_REPLACEMENT);
	gStopName = AGLC.matcher(gStopName).replaceAll(AGLC_REPLACEMENT);
	gStopName = NAIT.matcher(gStopName).replaceAll(NAIT_REPLACEMENT);
	gStopName = CleanUtils.removePoints(gStopName);
	gStopName = CleanUtils.cleanStreetTypes(gStopName);
	gStopName = CleanUtils.cleanNumbers(gStopName);
	return CleanUtils.cleanLabel(gStopName);
}
 
开发者ID:mtransitapps,项目名称:ca-st-albert-transit-bus-parser,代码行数:15,代码来源:StAlbertTransitBusAgencyTools.java

示例7: cleanStopName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanStopName(String gStopName) {
	gStopName = AND.matcher(gStopName).replaceAll(AND_REPLACEMENT);
	gStopName = AT.matcher(gStopName).replaceAll(AT_REPLACEMENT);
	gStopName = CleanUtils.cleanSlashes(gStopName);
	gStopName = CleanUtils.removePoints(gStopName);
	gStopName = CleanUtils.cleanNumbers(gStopName);
	gStopName = CleanUtils.cleanStreetTypes(gStopName);
	return CleanUtils.cleanLabel(gStopName);
}
 
开发者ID:mtransitapps,项目名称:ca-fredericton-transit-bus-parser,代码行数:11,代码来源:FrederictonTransitBusAgencyTools.java

示例8: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	tripHeadsign = EXCHANGE.matcher(tripHeadsign).replaceAll(EXCHANGE_REPLACEMENT);
	tripHeadsign = ENDS_WITH_VIA.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = STARTS_WITH_TO.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = AND.matcher(tripHeadsign).replaceAll(AND_REPLACEMENT);
	tripHeadsign = CLEAN_P1.matcher(tripHeadsign).replaceAll(CLEAN_P1_REPLACEMENT);
	tripHeadsign = CLEAN_P2.matcher(tripHeadsign).replaceAll(CLEAN_P2_REPLACEMENT);
	tripHeadsign = STARTS_WITH_NUMBER.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypes(tripHeadsign);
	return CleanUtils.cleanLabel(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:ca-chilliwack-transit-system-bus-parser,代码行数:14,代码来源:ChilliwackTransitSystemBusAgencyTools.java

示例9: getRouteLongName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String getRouteLongName(GRoute gRoute) {
	String gRouteLongName = gRoute.getRouteLongName();
	gRouteLongName = CleanUtils.cleanSlashes(gRouteLongName);
	gRouteLongName = CLEAN_STREET_POINT.matcher(gRouteLongName).replaceAll(CLEAN_AVE_POINT_REPLACEMENT);
	gRouteLongName = CleanUtils.cleanStreetTypes(gRouteLongName);
	return CleanUtils.cleanLabel(gRouteLongName);
}
 
开发者ID:mtransitapps,项目名称:ca-calgary-transit-bus-parser,代码行数:9,代码来源:CalgaryTransitBusAgencyTools.java

示例10: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	tripHeadsign = tripHeadsign.toLowerCase(Locale.ENGLISH);
	tripHeadsign = BRT_.matcher(tripHeadsign).replaceAll(BRT_REPLACEMENT);
	tripHeadsign = MRU_.matcher(tripHeadsign).replaceAll(MRU_REPLACEMENT);
	tripHeadsign = STN.matcher(tripHeadsign).replaceAll(STN_REPLACEMENT);
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypes(tripHeadsign);
	tripHeadsign = CleanUtils.cleanNumbers(tripHeadsign);
	return CleanUtils.cleanLabel(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:ca-calgary-transit-bus-parser,代码行数:12,代码来源:CalgaryTransitBusAgencyTools.java

示例11: cleanRouteLongName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
private String cleanRouteLongName(String gRouteLongName) {
	gRouteLongName = gRouteLongName.toLowerCase(Locale.ENGLISH);
	gRouteLongName = CleanUtils.cleanSlashes(gRouteLongName);
	gRouteLongName = S_F_U.matcher(gRouteLongName).replaceAll(S_F_U_REPLACEMENT);
	gRouteLongName = U_B_C.matcher(gRouteLongName).replaceAll(U_B_C_REPLACEMENT);
	gRouteLongName = V_C_C.matcher(gRouteLongName).replaceAll(V_C_C_REPLACEMENT);
	return CleanUtils.cleanLabel(gRouteLongName);
}
 
开发者ID:mtransitapps,项目名称:ca-vancouver-translink-bus-parser,代码行数:9,代码来源:VancouverTransLinkBusAgencyTools.java

示例12: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	tripHeadsign = tripHeadsign.toLowerCase(Locale.ENGLISH);
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = STARTS_WITH_QUOTE.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = ENDS_WITH_QUOTE.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = STARTS_WITH_ROUTE.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = ENDS_WITH_B_LINE.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = CleanUtils.CLEAN_AND.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_AND_REPLACEMENT);
	tripHeadsign = CleanUtils.CLEAN_AT.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	tripHeadsign = AT_LIKE.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_AT_REPLACEMENT);
	tripHeadsign = CENTRAL.matcher(tripHeadsign).replaceAll(CENTER_REPLACEMENT);
	tripHeadsign = EXCHANGE.matcher(tripHeadsign).replaceAll(EXCHANGE_REPLACEMENT);
	tripHeadsign = S_F_U.matcher(tripHeadsign).replaceAll(S_F_U_REPLACEMENT);
	tripHeadsign = U_B_C.matcher(tripHeadsign).replaceAll(U_B_C_REPLACEMENT);
	tripHeadsign = V_C_C.matcher(tripHeadsign).replaceAll(V_C_C_REPLACEMENT);
	tripHeadsign = UNIVERSITY.matcher(tripHeadsign).replaceAll(UNIVERSITY_REPLACEMENT);
	tripHeadsign = PORT_COQUITLAM.matcher(tripHeadsign).replaceAll(PORT_COQUITLAM_REPLACEMENT);
	tripHeadsign = COQUITLAM.matcher(tripHeadsign).replaceAll(COQUITLAM_REPLACEMENT);
	tripHeadsign = STATION.matcher(tripHeadsign).replaceAll(STATION_REPLACEMENT);
	tripHeadsign = PORT.matcher(tripHeadsign).replaceAll(PORT_REPLACEMENT);
	tripHeadsign = NIGHTBUS.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = EXPRESS.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = SPECIAL.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = ONLY.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = REMOVE_DASH.matcher(tripHeadsign).replaceAll(StringUtils.EMPTY);
	tripHeadsign = CleanUtils.removePoints(tripHeadsign);
	tripHeadsign = CleanUtils.cleanNumbers(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypes(tripHeadsign);
	return CleanUtils.cleanLabel(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:ca-vancouver-translink-bus-parser,代码行数:32,代码来源:VancouverTransLinkBusAgencyTools.java

示例13: cleanTripHeadsign

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanTripHeadsign(String tripHeadsign) {
	tripHeadsign = tripHeadsign.toLowerCase(Locale.ENGLISH);
	Matcher matcherTO = TO.matcher(tripHeadsign);
	if (matcherTO.find()) {
		String gTripHeadsignAfterTO = tripHeadsign.substring(matcherTO.end());
		tripHeadsign = gTripHeadsignAfterTO;
	}
	Matcher matcherVIA = VIA.matcher(tripHeadsign);
	if (matcherVIA.find()) {
		String gTripHeadsignBeforeVIA = tripHeadsign.substring(0, matcherVIA.start());
		tripHeadsign = gTripHeadsignBeforeVIA;
	}
	tripHeadsign = CLEAN_STATION.matcher(tripHeadsign).replaceAll(CLEAN_STATION_REPLACEMENT);
	tripHeadsign = CEGEP_GABRIELLE_ROY_.matcher(tripHeadsign).replaceAll(CEGEP_GABRIELLE_ROY_REPLACEMENT);
	tripHeadsign = COLLEGE_SAINY_ALEXANDRE_.matcher(tripHeadsign).replaceAll(COLLEGE_SAINY_ALEXANDRE_REPLACEMENT);
	tripHeadsign = ECOLE_SECONDAIRE_DE_L_ILE_.matcher(tripHeadsign).replaceAll(ECOLE_SECONDAIRE_DE_L_ILE_REPLACEMENT);
	tripHeadsign = P_O_B.matcher(tripHeadsign).replaceAll(P_O_B_REPLACEMENT);
	tripHeadsign = PRE_TUNNEY_.matcher(tripHeadsign).replaceAll(PRE_TUNNEY__REPLACEMENT);
	tripHeadsign = MUSEE_CANADIEN_HISTOIRE_.matcher(tripHeadsign).replaceAll(MUSEE_CANADIEN_HISTOIRE_REPLACEMENT);
	tripHeadsign = CleanUtils.CLEAN_ET.matcher(tripHeadsign).replaceAll(CleanUtils.CLEAN_ET_REPLACEMENT);
	tripHeadsign = CleanUtils.cleanSlashes(tripHeadsign);
	tripHeadsign = CleanUtils.cleanNumbers(tripHeadsign);
	tripHeadsign = CleanUtils.removePoints(tripHeadsign);
	tripHeadsign = CleanUtils.cleanStreetTypesFRCA(tripHeadsign);
	return CleanUtils.cleanLabelFR(tripHeadsign);
}
 
开发者ID:mtransitapps,项目名称:ca-gatineau-sto-bus-parser,代码行数:28,代码来源:GatineauSTOBusAgencyTools.java

示例14: cleanStopName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String cleanStopName(String gStopName) {
	gStopName = gStopName.toLowerCase(Locale.ENGLISH);
	gStopName = ENDS_WITH_BOUNDS.matcher(gStopName).replaceAll(StringUtils.EMPTY);
	gStopName = STARTS_ENDS_WITH_ARRIVAL_DEPARTURE.matcher(gStopName).replaceAll(StringUtils.EMPTY);
	gStopName = CLEAN_ARRET_DE_COURTOISIE.matcher(gStopName).replaceAll(CLEAN_ARRET_DE_COURTOISIE_REPLACEMENT);
	gStopName = CleanUtils.SAINT.matcher(gStopName).replaceAll(CleanUtils.SAINT_REPLACEMENT);
	gStopName = CleanUtils.CLEAN_ET.matcher(gStopName).replaceAll(CleanUtils.CLEAN_ET_REPLACEMENT);
	gStopName = CleanUtils.cleanSlashes(gStopName);
	gStopName = CleanUtils.removePoints(gStopName);
	gStopName = CleanUtils.cleanStreetTypesFRCA(gStopName);
	return CleanUtils.cleanLabelFR(gStopName);
}
 
开发者ID:mtransitapps,项目名称:ca-gatineau-sto-bus-parser,代码行数:14,代码来源:GatineauSTOBusAgencyTools.java

示例15: getRouteLongName

import org.mtransit.parser.CleanUtils; //导入方法依赖的package包/类
@Override
public String getRouteLongName(GRoute gRoute) {
	String routeLongName = gRoute.getRouteLongName();
	routeLongName = CleanUtils.SAINT.matcher(routeLongName).replaceAll(CleanUtils.SAINT_REPLACEMENT);
	routeLongName = CleanUtils.cleanSlashes(routeLongName);
	return CleanUtils.cleanLabel(routeLongName);
}
 
开发者ID:mtransitapps,项目名称:ca-la-presqu-ile-citpi-bus-parser,代码行数:8,代码来源:LaPresquIleCITPIBusAgencyTools.java


注:本文中的org.mtransit.parser.CleanUtils.cleanSlashes方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。