This method corrects subjects of verbs for which we identified an auxpass,
but didn't identify the subject as passive. It also corrects the possessive
relations for PRP$ and WP$ which weren't retrieved.

@param list List of typedDependencies to work on
967302
private static void correctSubjPassAndPoss(Collection<TypedDependency> list) {
    // put in a list verbs having an auxpass
    List<TreeGraphNode> list_auxpass = new ArrayList<TreeGraphNode>();
    for (TypedDependency td : list) {
      if (td.reln() == AUX_PASSIVE_MODIFIER) {
        list_auxpass.add(td.gov());
      }
    }
    for (TypedDependency td : list) {
      // correct nsubj
      if (td.reln() == NOMINAL_SUBJECT && list_auxpass.contains(td.gov())) {
        // System.err.println("%%% Changing subj to passive: " + td);
        td.setReln(NOMINAL_PASSIVE_SUBJECT);
      }
      if (td.reln() == CLAUSAL_SUBJECT && list_auxpass.contains(td.gov())) {
        // System.err.println("%%% Changing subj to passive: " + td);
        td.setReln(CLAUSAL_PASSIVE_SUBJECT);
      }

      // correct unretrieved poss: dep relation in which the dependent is a
      // PRP$ or WP$
      // cdm: Now done in basic rules.  The only cases that this still matches
      // are (1) tagging mistakes where PRP in dobj position is mistagged PRP$
      // or a couple of parsing errors where the dependency is wrong anyway, so
      // it's probably okay to keep it a dep.  So I'm disabling this.
      // String tag = td.dep().parent().value();
      // if (td.reln() == DEPENDENT && (tag.equals("PRP$") || tag.equals("WP$"))) {
      //  System.err.println("%%% Unrecognized basic possessive pronoun: " + td);
      //  td.setReln(POSSESSION_MODIFIER);
      // }
    }
  }
399734
def remove(self, list):
        
        xml = SP.DeleteList(SP.listName(list.id))
        self.opener.post_soap(LIST_WEBSERVICE, xml,
                              soapaction='http://schemas.microsoft.com/sharepoint/soap/DeleteList')
        self.all_lists.remove(list)
1143944
public void setAcList(StringArray v) {
    if (DBInfo_Type.featOkTst && ((DBInfo_Type)jcasType).casFeat_acList == null)
      jcasType.jcas.throwFeatMissing("acList", "de.julielab.jules.types.DBInfo");
    jcasType.ll_cas.ll_setRefValue(addr, ((DBInfo_Type)jcasType).casFeatCode_acList, jcasType.ll_cas.ll_getFSRef(v));}
940644
def resolve
      list = dependency_list.sort { |a, b| a.last.size <=> b.last.size }
      resolve_list(list)
    end
1190460
private R pushExprList(ExpressionList<T> list) {
    if (textMode) {
      textStack.push(list);
    } else {
      whereStack.push(list);
    }
    return root;
  }
210273
private static <T> void removeIdentity(List<T> list, T object) {
		Iterator<T> it = list.iterator();
		while (it.hasNext()) {
			if (object == it.next()) {
				it.remove();
			}
		}
	}
954443
protected static Object clear (
        EqualityComparator eqc, Object[] list, Object element)
    {
        int dex = indexOf(eqc, list, element);
        if (dex == -1) {
            return null;
        }
        Object elem = list[dex];
        list[dex] = null;
        return elem;
    }
441524
public List<WordTag> process(List list) {
    List<IN> featureLabels = new ArrayList<IN>();
    for (Object o : list) {
      CoreLabel wi = new CoreLabel();
      if (o instanceof HasWord) {
        wi.setWord(((HasWord) o).word());
        if (o instanceof HasTag) {
          wi.setTag(((HasTag) o).tag());
        }
      } else {
        wi.setWord(o.toString());
      }
      featureLabels.add((IN) wi);
    }
    List<IN> tagged = classify(featureLabels);
    List<WordTag> out = new ArrayList<WordTag>();
    for (CoreLabel wi : tagged) {
      out.add(new WordTag(wi.word(), wi.get(AnswerAnnotation.class)));
    }
    return out;
  }
1275284
public static boolean containsAny(final String str, final String[] list, final boolean ignoreCase) {
        
        if(str == null) {
            return false;
        }
        
        if(list == null || list.length == 0) {
            return false;
        }
        
        for(String item : list) {
            if(ignoreCase) {
                if(containsIgnoreCase(str, item)) {
                    return true;
                }
            } else {
                if(str.indexOf(item) >= 0) {
                    return true;
                }
                
            }
        }
        
        return false;
        
    }
677757
private static void collapse2WPbis(Collection<TypedDependency> list) {
    Collection<TypedDependency> newTypedDeps = new ArrayList<TypedDependency>();

    for (String[] mwp : MULTIWORD_PREPS) {

      TreeGraphNode mwp0 = null;
      TreeGraphNode mwp1 = null;
      TreeGraphNode governor = null;

      TypedDependency prep = null;
      TypedDependency dep = null;
      TypedDependency pobj = null;
      TypedDependency newtd = null;

      // first find the first part of the multi_preposition: advmod|prt(gov, mwp[0])

      for (TypedDependency td : list) {
        if (td.dep().value().equalsIgnoreCase(mwp[0]) && (td.reln() == PHRASAL_VERB_PARTICLE || td.reln() == ADVERBIAL_MODIFIER || td.reln() == DEPENDENT || td.reln() == MULTI_WORD_EXPRESSION)) {
          // we found advmod(gov, mwp0) or prt(gov, mwp0)
          governor = td.gov();
          mwp0 = td.dep();
          dep = td;
        }
      }

      // now search for the second part: prep(gov, mwp1)
      // the two words in the mwp should be next to another in the sentence
      // (difference of indexes = 1)

      for (TypedDependency td1 : list) {
        if (mwp0 != null && td1.dep().value().equalsIgnoreCase(mwp[1]) && td1.gov() == governor && td1.reln() == PREPOSITIONAL_MODIFIER && Math.abs(td1.dep().index() - mwp0.index()) == 1) {// we
          // found
          // prep(gov,
          // mwp1)
          mwp1 = td1.dep();
          prep = td1;
        }
      }

      // search for the complement: pobj|pcomp(mwp1,X)
      for (TypedDependency td2 : list) {
        if (td2.gov() == mwp1 && td2.reln() == PREPOSITIONAL_OBJECT) {
          pobj = td2;
          // create the new gr relation
          GrammaticalRelation gr = EnglishGrammaticalRelations.getPrep(mwp[0] + '_' + mwp[1]);
          if (governor != null) {
            newtd = new TypedDependency(gr, governor, pobj.dep());
          }
        }
        if (td2.gov() == mwp1 && td2.reln() == PREPOSITIONAL_COMPLEMENT) {
          pobj = td2;
          // create the new gr relation
          GrammaticalRelation gr = EnglishGrammaticalRelations.getPrepC(mwp[0] + '_' + mwp[1]);
          if (governor != null) {
            newtd = new TypedDependency(gr, governor, pobj.dep());
          }
        }
      }

      // only if we found the three parts, set to KILL and remove
      // and add the new one
      if (prep != null && pobj != null && newtd != null) {
        prep.setReln(KILL);
        dep.setReln(KILL);
        pobj.setReln(KILL);
        newTypedDeps.add(newtd);

        // now remove typed dependencies with reln "kill"
        // and promote possible orphans
        for (TypedDependency td1 : list) {
          if (td1.reln() != KILL) {
            if (td1.gov() == mwp0 || td1.gov() == mwp1) {
              td1.setGov(governor);
            }
            if (!newTypedDeps.contains(td1)) {
              newTypedDeps.add(td1);
            }
          }
        }
        list.clear();
        list.addAll(newTypedDeps);
      }
    }
  }
1106278
public static Object clearRef (Object[] list, Object element)
    {
        return clear(REFERENCE_COMP, list, element);
    }
1254475
public static void removeFromList(final Entry e) {
    e.prev.next = e.next;
    e.next.prev = e.prev;
    e.removedFromList();
  }
87693
private List<Object> normalizeList(List<Object> list) {
    	List<Object> result = new ArrayList<Object>();
    	for (Object o : list) {
    		if (o == null) {
    			result.add(nullLiteral);
    		} else if (o instanceof Boolean) {
    			result.add(((Boolean) o).toString());
    		} else if (o instanceof List<?>) {
    			result.add(normalizeList((List<Object>) o));
    		} else if (o instanceof Map<?, ?>) {
    			result.add(normalizeMap((Map<String, Object>) o));
    		} else if (!(o instanceof Number)) {
    			result.add(o);
    		}
    	}
    	return result;
    }
149998
private void toStringList(final StringBuilder sb, final List < ? > list,
            final String title) {
        sb.append(',');
        sb.append(title + ":[");
        boolean first = true;
        for (Object child : list) {
            if (!first) {
                sb.append(",");
            } else {
                first = false;
            }
            sb.append(child.toString());
        }
        sb.append("]");
    }
279973
public void setSAMLProviderList(java.util.Collection<SAMLProviderListEntry> sAMLProviderList) {
        if (sAMLProviderList == null) {
            this.sAMLProviderList = null;
            return;
        }

        this.sAMLProviderList = new com.amazonaws.internal.SdkInternalList<SAMLProviderListEntry>(sAMLProviderList);
    }
107477
public static List<String> removeDuplicates(List<String> list) {
		return list.stream().distinct().collect(Collectors.toList());
	}
1180571
function remove(item, list) {
  var i = list.indexOf(item);
  if (~i) list.splice(i, 1);
}