List of usage examples for java.util LinkedList iterator
Iterator<E> iterator();
From source file:net.sourceforge.msscodefactory.cfinternet.v2_0.CFInternetRam.CFInternetRamSecUserTable.java
public void deleteSecUserByIdIdx(CFInternetAuthorization Authorization, CFInternetSecUserPKey argKey) { CFInternetSecUserBuff cur;/*from w ww. jav a 2s. c om*/ LinkedList<CFInternetSecUserBuff> matchSet = new LinkedList<CFInternetSecUserBuff>(); Iterator<CFInternetSecUserBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFInternetSecUserBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteSecUser(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfinternet.v2_0.CFInternetRam.CFInternetRamSecUserTable.java
public void deleteSecUserByUEMailIdx(CFInternetAuthorization Authorization, CFInternetSecUserByUEMailIdxKey argKey) { CFInternetSecUserBuff cur;/* w ww . jav a 2 s. c o m*/ LinkedList<CFInternetSecUserBuff> matchSet = new LinkedList<CFInternetSecUserBuff>(); Iterator<CFInternetSecUserBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFInternetSecUserBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteSecUser(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfasterisk.v2_4.CFAsteriskRam.CFAsteriskRamMimeTypeTable.java
public void deleteMimeTypeByIdIdx(CFSecurityAuthorization Authorization, CFInternetMimeTypePKey argKey) { CFInternetMimeTypeBuff cur;// w w w. ja v a2 s . com LinkedList<CFInternetMimeTypeBuff> matchSet = new LinkedList<CFInternetMimeTypeBuff>(); Iterator<CFInternetMimeTypeBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFInternetMimeTypeBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteMimeType(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfasterisk.v2_4.CFAsteriskRam.CFAsteriskRamMimeTypeTable.java
public void deleteMimeTypeByUNameIdx(CFSecurityAuthorization Authorization, CFInternetMimeTypeByUNameIdxKey argKey) { CFInternetMimeTypeBuff cur;/* w w w .j a va 2 s. c om*/ LinkedList<CFInternetMimeTypeBuff> matchSet = new LinkedList<CFInternetMimeTypeBuff>(); Iterator<CFInternetMimeTypeBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFInternetMimeTypeBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteMimeType(Authorization, cur); } }
From source file:mase.spec.StochasticHybridExchanger.java
protected Individual[] selectIndividuals(Individual[] pool, int num, MergeSelection mode, EvolutionState state) {//from w w w .j a v a2 s. c om Individual[] picked = new Individual[num]; if (mode == MergeSelection.truncate) { Individual[] sorted = sortedCopy(pool); System.arraycopy(sorted, 0, picked, 0, num); } else if (mode == MergeSelection.fitnessproportionate) { double total = 0; LinkedList<Individual> poolList = new LinkedList<>(); for (Individual ind : pool) { poolList.add(ind); total += ((SimpleFitness) ind.fitness).fitness(); } int index = 0; while (index < num) { double accum = 0; double rand = state.random[0].nextDouble() * total; Iterator<Individual> iter = poolList.iterator(); while (iter.hasNext()) { Individual ind = iter.next(); accum += ((SimpleFitness) ind.fitness).fitness(); if (accum >= rand) { picked[index++] = ind; iter.remove(); total -= ((SimpleFitness) ind.fitness).fitness(); break; } } } } else if (mode == MergeSelection.random) { LinkedList<Individual> poolList = new LinkedList<>(Arrays.asList(pool)); int index = 0; while (index < num) { int rand = state.random[0].nextInt(poolList.size()); picked[index++] = poolList.get(rand); poolList.remove(rand); } } else { state.output.fatal("Unknown picking mode: " + mode); } return picked; }
From source file:net.sourceforge.msscodefactory.cfcore.v2_1.CFGenKbRam.CFGenKbRamAuditActionTable.java
public void deleteAuditActionByIdIdx(CFGenKbAuthorization Authorization, CFGenKbAuditActionPKey argKey) { CFGenKbAuditActionBuff cur;//from w w w. j av a 2s . c om LinkedList<CFGenKbAuditActionBuff> matchSet = new LinkedList<CFGenKbAuditActionBuff>(); Iterator<CFGenKbAuditActionBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFGenKbAuditActionBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteAuditAction(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfcore.v2_1.CFGenKbRam.CFGenKbRamAuditActionTable.java
public void deleteAuditActionByUDescrIdx(CFGenKbAuthorization Authorization, CFGenKbAuditActionByUDescrIdxKey argKey) { CFGenKbAuditActionBuff cur;//from w ww. j a v a 2s . co m LinkedList<CFGenKbAuditActionBuff> matchSet = new LinkedList<CFGenKbAuditActionBuff>(); Iterator<CFGenKbAuditActionBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFGenKbAuditActionBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteAuditAction(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfcore.v2_1.CFGenKbRam.CFGenKbRamServiceTypeTable.java
public void deleteServiceTypeByIdIdx(CFGenKbAuthorization Authorization, CFGenKbServiceTypePKey argKey) { CFGenKbServiceTypeBuff cur;//ww w . j a v a 2 s . c o m LinkedList<CFGenKbServiceTypeBuff> matchSet = new LinkedList<CFGenKbServiceTypeBuff>(); Iterator<CFGenKbServiceTypeBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFGenKbServiceTypeBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteServiceType(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfacc.v2_0.CFAccRam.CFAccRamAuditActionTable.java
public void deleteAuditActionByIdIdx(CFAccAuthorization Authorization, CFAccAuditActionPKey argKey) { CFAccAuditActionBuff cur;/*from w w w . java 2s . co m*/ LinkedList<CFAccAuditActionBuff> matchSet = new LinkedList<CFAccAuditActionBuff>(); Iterator<CFAccAuditActionBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFAccAuditActionBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteAuditAction(Authorization, cur); } }
From source file:net.sourceforge.msscodefactory.cfasterisk.v2_0.CFAstRam.CFAstRamAuditActionTable.java
public void deleteAuditActionByIdIdx(CFAstAuthorization Authorization, CFAstAuditActionPKey argKey) { CFAstAuditActionBuff cur;/*from w w w .j a v a 2s . co m*/ LinkedList<CFAstAuditActionBuff> matchSet = new LinkedList<CFAstAuditActionBuff>(); Iterator<CFAstAuditActionBuff> values = dictByPKey.values().iterator(); while (values.hasNext()) { cur = values.next(); if (argKey.equals(cur)) { matchSet.add(cur); } } Iterator<CFAstAuditActionBuff> iterMatch = matchSet.iterator(); while (iterMatch.hasNext()) { cur = iterMatch.next(); deleteAuditAction(Authorization, cur); } }