本文整理匯總了Java中java.util.concurrent.ConcurrentSkipListSet.remove方法的典型用法代碼示例。如果您正苦於以下問題:Java ConcurrentSkipListSet.remove方法的具體用法?Java ConcurrentSkipListSet.remove怎麽用?Java ConcurrentSkipListSet.remove使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類java.util.concurrent.ConcurrentSkipListSet
的用法示例。
在下文中一共展示了ConcurrentSkipListSet.remove方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: deleteIndex
import java.util.concurrent.ConcurrentSkipListSet; //導入方法依賴的package包/類
@Override
public void deleteIndex(NitriteId id, String field, String text) {
try {
NitriteMap<Comparable, ConcurrentSkipListSet<NitriteId>> indexMap
= indexMetaService.getIndexMap(field);
Set<String> words = tokenizerService.tokenize(text);
for (String word : words) {
ConcurrentSkipListSet<NitriteId> nitriteIds = indexMap.get(word);
if (nitriteIds != null) {
nitriteIds.remove(id);
}
}
} catch (IOException ioe) {
throw new IndexingException(errorMessage(
"failed to remove full-text index data for " + field + " with id " + id,
IE_REMOVE_FULL_TEXT_INDEX_FAILED));
}
}
示例2: removeProperty
import java.util.concurrent.ConcurrentSkipListSet; //導入方法依賴的package包/類
public synchronized void removeProperty(Property property) {
Map<String, ConcurrentSkipListSet<Property>> propertiesByKey = propertiesByNameAndKey.get(property.getName());
if (propertiesByKey == null) {
return;
}
ConcurrentSkipListSet<Property> properties = propertiesByKey.get(property.getKey());
if (properties == null) {
return;
}
properties.remove(property);
this.propertiesList.remove(property);
}
示例3: removeIndexEntry
import java.util.concurrent.ConcurrentSkipListSet; //導入方法依賴的package包/類
void removeIndexEntry(Document document, NitriteId nitriteId) {
Set<String> fields = getFields(document);
for (String field : fields) {
Index index = indexMetaService.findIndex(field);
if (index != null) {
Object fieldValue = getFieldValue(document, field);
if (fieldValue == null) continue;
// if dirty index and currently indexing is not running, rebuild
if (indexMetaService.isDirtyIndex(field) && !indexBuildRegistry.get(field).get()) {
// rebuild will also take care of the current document
rebuildIndex(index, true);
} else {
IndexType indexType = index.getIndexType();
if (indexType == IndexType.Fulltext && fieldValue instanceof String) {
textIndexingService.deleteIndex(nitriteId, field, (String) fieldValue);
} else {
NitriteMap<Comparable, ConcurrentSkipListSet<NitriteId>> indexMap
= indexMetaService.getIndexMap(field);
// create the nitrite list associated with the value
if (fieldValue instanceof Comparable) {
ConcurrentSkipListSet<NitriteId> nitriteIdList = indexMap.get((Comparable) fieldValue);
if (nitriteIdList != null) {
nitriteIdList.remove(nitriteId);
indexMap.put((Comparable) fieldValue, nitriteIdList);
}
}
}
}
}
}
}
示例4: removeMarket
import java.util.concurrent.ConcurrentSkipListSet; //導入方法依賴的package包/類
/**
* Remove this market data from financial market with specified market code
* This can be used when reload data
* @param category the market data search category
* @param marketCode the market code that is going to be removed
*/
public void removeMarket(String category, String marketCode) {
if (financialMarketData.get(category) != null) {
ConcurrentSkipListSet<Market> markets = financialMarketData.get(category);
Iterator<Market> iterator = markets.iterator();
while(iterator.hasNext()) {
Market market = iterator.next();
if (market.getMarketCode().compareToIgnoreCase(marketCode)==0) {
markets.remove(market);
}
}
}
}