Unnamed: 0 int64 0 6.45k | func stringlengths 29 253k | target class label 2
classes | project stringlengths 36 167 |
|---|---|---|---|
1,105 | @RunWith(HazelcastParallelClassRunner.class)
@Category(QuickTest.class)
public class SemaphoreConfigTest {
@Test
public void testSetInitialPermits() {
SemaphoreConfig semaphoreConfig = new SemaphoreConfig().setInitialPermits(1234);
assertTrue(semaphoreConfig.getInitialPermits() == 1234);
}
... | 0true | hazelcast_src_test_java_com_hazelcast_config_SemaphoreConfigTest.java |
3,136 | public class InternalEngineModule extends AbstractModule {
@Override
protected void configure() {
bind(Engine.class).to(InternalEngine.class).asEagerSingleton();
}
} | 0true | src_main_java_org_elasticsearch_index_engine_internal_InternalEngineModule.java |
250 | fCollapseComments= new FoldingAction(getResourceBundle(), "Projection.CollapseComments.") {
public void run() {
if (editor instanceof CeylonEditor) {
ProjectionAnnotationModel pam = ((CeylonEditor) editor).getCeylonSourceViewer()
.getPr... | 0true | plugins_com.redhat.ceylon.eclipse.ui_src_com_redhat_ceylon_eclipse_code_editor_FoldingActionGroup.java |
19 | static class ByteVertex extends Vertex {
private final LongObjectMap<ConcurrentSkipListSet<ByteEntry>> tx;
private final SortedSet<ByteEntry> set;
ByteVertex(long id, LongObjectMap<ConcurrentSkipListSet<ByteEntry>> tx) {
super(id);
this.tx = tx;
this.set... | 0true | titan-test_src_main_java_com_thinkaurelius_titan_TestByteBuffer.java |
679 | private final class EntryIterator implements Iterator<Entry<K, V>> {
private int currentIndex;
private EntryIterator(int currentIndex) {
this.currentIndex = currentIndex;
}
@Override
public boolean hasNext() {
return currentIndex < size();
}
@Override
public Entry<K, V> ... | 0true | core_src_main_java_com_orientechnologies_orient_core_index_hashindex_local_OHashIndexBucket.java |
3,516 | public class MergeContext {
private final DocumentMapper documentMapper;
private final DocumentMapper.MergeFlags mergeFlags;
private final List<String> mergeConflicts = Lists.newArrayList();
public MergeContext(DocumentMapper documentMapper, DocumentMapper.MergeFlags mergeFlags) {
this.documen... | 0true | src_main_java_org_elasticsearch_index_mapper_MergeContext.java |
1,741 | public class CompressorFactory {
private static final LZFCompressor LZF = new LZFCompressor();
private static final Compressor[] compressors;
private static final ImmutableMap<String, Compressor> compressorsByType;
private static Compressor defaultCompressor;
static {
List<Compressor> com... | 0true | src_main_java_org_elasticsearch_common_compress_CompressorFactory.java |
1,603 | Set<SystemLog> sorted = new TreeSet<SystemLog>(new Comparator<SystemLog>() {
public int compare(SystemLog o1, SystemLog o2) {
long thisVal = o1.date;
long anotherVal = o2.date;
return (thisVal < anotherVal ? -1 : (thisVal == anotherVal ? 0 : 1));
... | 0true | hazelcast_src_main_java_com_hazelcast_logging_SystemLogService.java |
1,804 | interface CreationListener {
void notify(Errors errors);
} | 0true | src_main_java_org_elasticsearch_common_inject_BindingProcessor.java |
4,680 | final static class MatchAndSort extends QueryCollector {
private final TopScoreDocCollector topDocsCollector;
MatchAndSort(ESLogger logger, PercolateContext context) {
super(logger, context);
// TODO: Use TopFieldCollector.create(...) for ascending and decending scoring?
... | 1no label | src_main_java_org_elasticsearch_percolator_QueryCollector.java |
2,173 | static class IteratorBasedIterator extends DocIdSetIterator {
final class Item {
public final DocIdSetIterator iter;
public int doc;
public Item(DocIdSetIterator iter) {
this.iter = iter;
this.doc = -1;
}
}
pr... | 0true | src_main_java_org_elasticsearch_common_lucene_docset_OrDocIdSet.java |
3,134 | public class QueueIterator<E> implements Iterator<E> {
private final Iterator<Data> iterator;
private final SerializationService serializationService;
private final boolean binary;
public QueueIterator(Iterator<Data> iterator, SerializationService serializationService, boolean binary) {
this.i... | 1no label | hazelcast_src_main_java_com_hazelcast_queue_proxy_QueueIterator.java |
158 | private final Function<String, Locker> ASTYANAX_RECIPE_LOCKER_CREATOR = new Function<String, Locker>() {
@Override
public Locker apply(String lockerName) {
String expectedManagerName = "com.thinkaurelius.titan.diskstorage.cassandra.astyanax.AstyanaxStoreManager";
String act... | 0true | titan-core_src_main_java_com_thinkaurelius_titan_diskstorage_Backend.java |
235 | .registerHookValue(profilerPrefix + "enabled", "Cache enabled", METRIC_TYPE.ENABLED, new OProfilerHookValue() {
public Object getValue() {
return isEnabled();
}
}, profilerMetadataPrefix + "enabled"); | 0true | core_src_main_java_com_orientechnologies_orient_core_cache_OAbstractRecordCache.java |
540 | public class DeleteMappingRequest extends AcknowledgedRequest<DeleteMappingRequest> {
private String[] indices;
private IndicesOptions indicesOptions = IndicesOptions.fromOptions(false, false, true, false);
private String[] types;
DeleteMappingRequest() {
}
/**
* Constructs a new delete ... | 0true | src_main_java_org_elasticsearch_action_admin_indices_mapping_delete_DeleteMappingRequest.java |
560 | public class RandomLB extends AbstractLoadBalancer {
private final Random random = new Random();
@Override
public Member next() {
Member[] members = getMembers();
if (members == null || members.length == 0) {
return null;
}
int index = random.nextInt(members.len... | 0true | hazelcast-client_src_main_java_com_hazelcast_client_util_RandomLB.java |
2,998 | public static class FilterCacheValueWeigher implements Weigher<WeightedFilterCache.FilterCacheKey, DocIdSet> {
@Override
public int weigh(FilterCacheKey key, DocIdSet value) {
int weight = (int) Math.min(DocIdSets.sizeInBytes(value), Integer.MAX_VALUE);
return weight == 0 ? ... | 0true | src_main_java_org_elasticsearch_index_cache_filter_weighted_WeightedFilterCache.java |
157 | public class ConcurrentLinkedDeque<E>
extends AbstractCollection<E>
implements Deque<E>, java.io.Serializable {
/*
* This is an implementation of a concurrent lock-free deque
* supporting interior removes but not interior insertions, as
* required to support the entire Deque interface.
... | 0true | src_main_java_jsr166y_ConcurrentLinkedDeque.java |
126 | public enum METRIC_TYPE {
CHRONO, COUNTER, STAT, SIZE, ENABLED, TEXT
} | 0true | commons_src_main_java_com_orientechnologies_common_profiler_OProfilerMBean.java |
2,642 | transportService.sendRequest(requestingNode, MulticastPingResponseRequestHandler.ACTION, multicastPingResponse, new EmptyTransportResponseHandler(ThreadPool.Names.SAME) {
@Override
public void handleException(TransportException exp) {
logge... | 0true | src_main_java_org_elasticsearch_discovery_zen_ping_multicast_MulticastZenPing.java |
918 | public class PlainActionFuture<T> extends AdapterActionFuture<T, T> {
public static <T> PlainActionFuture<T> newFuture() {
return new PlainActionFuture<T>();
}
@Override
protected T convert(T listenerResponse) {
return listenerResponse;
}
} | 0true | src_main_java_org_elasticsearch_action_support_PlainActionFuture.java |
1,596 | public class ThrottlingAllocationDecider extends AllocationDecider {
public static final String CLUSTER_ROUTING_ALLOCATION_NODE_INITIAL_PRIMARIES_RECOVERIES = "cluster.routing.allocation.node_initial_primaries_recoveries";
public static final String CLUSTER_ROUTING_ALLOCATION_NODE_CONCURRENT_RECOVERIES = "clus... | 1no label | src_main_java_org_elasticsearch_cluster_routing_allocation_decider_ThrottlingAllocationDecider.java |
274 | private final class GotoListener implements KeyListener {
@Override
public void keyReleased(KeyEvent e) {}
@Override
public void keyPressed(KeyEvent e) {
if (e.character == 0x1B) // ESC
dispose();
if (EditorUtil.triggersBinding(e, getCommandBi... | 0true | plugins_com.redhat.ceylon.eclipse.ui_src_com_redhat_ceylon_eclipse_code_editor_PeekDefinitionPopup.java |
683 | public interface CategoryProductXref extends Serializable {
/**
* Gets the category.
*
* @return the category
*/
Category getCategory();
/**
* Sets the category.
*
* @param category the new category
*/
void setCategory(Category category);
/**
* Gets ... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_catalog_domain_CategoryProductXref.java |
1,387 | @XmlRootElement(name = "categories")
@XmlAccessorType(value = XmlAccessType.FIELD)
public class CategoriesWrapper extends BaseWrapper implements APIWrapper<List<Category>> {
@XmlElement(name = "category")
protected List<CategoryWrapper> categories = new ArrayList<CategoryWrapper>();
@Override
public v... | 0true | core_broadleaf-framework-web_src_main_java_org_broadleafcommerce_core_web_api_wrapper_CategoriesWrapper.java |
822 | public class MultiSearchRequestTests extends ElasticsearchTestCase {
@Test
public void simpleAdd() throws Exception {
byte[] data = Streams.copyToBytesFromClasspath("/org/elasticsearch/action/search/simple-msearch1.json");
MultiSearchRequest request = new MultiSearchRequest().add(data, 0, data.... | 0true | src_test_java_org_elasticsearch_action_search_MultiSearchRequestTests.java |
1,472 | public class BroadleafSocialRegisterController extends BroadleafRegisterController {
//Pre-populate portions of the RegisterCustomerForm from ProviderSignInUtils.getConnection();
public String register(RegisterCustomerForm registerCustomerForm, HttpServletRequest request,
HttpServlet... | 0true | core_broadleaf-framework-web_src_main_java_org_broadleafcommerce_core_web_controller_account_BroadleafSocialRegisterController.java |
3,380 | public static class Builder implements IndexFieldData.Builder {
private NumericType numericType;
public Builder setNumericType(NumericType numericType) {
this.numericType = numericType;
return this;
}
@Override
public IndexFieldData<AtomicNumericFie... | 0true | src_main_java_org_elasticsearch_index_fielddata_plain_PackedArrayIndexFieldData.java |
440 | @Deprecated
public @interface AdminPresentationAdornedTargetCollectionOverride {
/**
* The name of the property whose AdminPresentation annotation should be overwritten
*
* @return the name of the property that should be overwritten
*/
String name();
/**
* The AdminPresentation to... | 0true | common_src_main_java_org_broadleafcommerce_common_presentation_override_AdminPresentationAdornedTargetCollectionOverride.java |
1,993 | private static class AndMatcher<T> extends AbstractMatcher<T> implements Serializable {
private final Matcher<? super T> a, b;
public AndMatcher(Matcher<? super T> a, Matcher<? super T> b) {
this.a = a;
this.b = b;
}
public boolean matches(T t) {
... | 0true | src_main_java_org_elasticsearch_common_inject_matcher_AbstractMatcher.java |
722 | @RunWith(HazelcastParallelClassRunner.class)
@Category(QuickTest.class)
public class ListTest extends HazelcastTestSupport {
@Test
@ClientCompatibleTest
public void testListMethods() throws Exception {
Config config = new Config();
final String name = "defList";
final int count = 10... | 0true | hazelcast_src_test_java_com_hazelcast_collection_ListTest.java |
3,390 | abstract class SortedSetDVAtomicFieldData {
private final AtomicReader reader;
private final String field;
private volatile IntArray hashes;
SortedSetDVAtomicFieldData(AtomicReader reader, String field) {
this.reader = reader;
this.field = field;
}
public boolean isMultiValued... | 0true | src_main_java_org_elasticsearch_index_fielddata_plain_SortedSetDVAtomicFieldData.java |
595 | public class PlotConstants {
/*
* Default Plot Properties.
*/
public static final int DEFAULT_NUMBER_OF_SUBPLOTS = 1;
public static final boolean LOCAL_CONTROLS_ENABLED_BY_DEFAULT = true;
public static final YAxisMaximumLocationSetting DEFAULT_Y_AXIS_MAX_LOCATION_SETTING = YAxisMaximumLocationSetting.MAXIMUM_A... | 1no label | fastPlotViews_src_main_java_gov_nasa_arc_mct_fastplot_bridge_PlotConstants.java |
403 | public class TransportCreateSnapshotAction extends TransportMasterNodeOperationAction<CreateSnapshotRequest, CreateSnapshotResponse> {
private final SnapshotsService snapshotsService;
@Inject
public TransportCreateSnapshotAction(Settings settings, TransportService transportService, ClusterService clusterSe... | 1no label | src_main_java_org_elasticsearch_action_admin_cluster_snapshots_create_TransportCreateSnapshotAction.java |
355 | future.andThen(new ExecutionCallback<Map<String, List<Integer>>>() {
@Override
public void onResponse(Map<String, List<Integer>> response) {
listenerResults.putAll(response);
semaphore.release();
}
@Override
public void... | 0true | hazelcast-client_src_test_java_com_hazelcast_client_mapreduce_ClientMapReduceTest.java |
3,283 | private static class OrdinalsStore {
private static final int PAGE_SIZE = 1 << 12;
/**
* Number of slots at <code>level</code>
*/
private static int numSlots(int level) {
return 1 << level;
}
private static int slotsMask(int level) {
... | 0true | src_main_java_org_elasticsearch_index_fielddata_ordinals_OrdinalsBuilder.java |
3,596 | private ThreadLocal<NumericTokenStream> tokenStream = new ThreadLocal<NumericTokenStream>() {
@Override
protected NumericTokenStream initialValue() {
return new NumericTokenStream(precisionStep);
}
}; | 0true | src_main_java_org_elasticsearch_index_mapper_core_NumberFieldMapper.java |
710 | public interface ProductOption extends Serializable {
/**
* Returns unique identifier of the product option.
* @return
*/
public Long getId();
/**
* Sets the unique identifier of the product option.
* @param id
*/
public void setId(Long id);
/**
* Returns th... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_catalog_domain_ProductOption.java |
1,692 | @Entity
@Inheritance(strategy = InheritanceType.JOINED)
@Table(name = "BLC_ADMIN_PASSWORD_TOKEN")
public class ForgotPasswordSecurityTokenImpl implements ForgotPasswordSecurityToken {
private static final long serialVersionUID = 1L;
@Id
@Column(name = "PASSWORD_TOKEN", nullable = false)
protected S... | 1no label | admin_broadleaf-open-admin-platform_src_main_java_org_broadleafcommerce_openadmin_server_security_domain_ForgotPasswordSecurityTokenImpl.java |
363 | public class HBaseIDAuthorityTest extends IDAuthorityTest {
public HBaseIDAuthorityTest(WriteConfiguration baseConfig) {
super(baseConfig);
}
@BeforeClass
public static void startHBase() throws IOException {
HBaseStorageSetup.startHBase();
}
@AfterClass
public static void ... | 0true | titan-hbase-parent_titan-hbase-core_src_test_java_com_thinkaurelius_titan_diskstorage_hbase_HBaseIDAuthorityTest.java |
3,508 | class InternalFieldMapperListener extends FieldMapperListener {
@Override
public void fieldMapper(FieldMapper fieldMapper) {
addFieldMappers(Arrays.asList(fieldMapper));
}
@Override
public void fieldMappers(Iterable<FieldMapper> fieldMappers) {
addFi... | 0true | src_main_java_org_elasticsearch_index_mapper_MapperService.java |
55 | new Visitor() {
@Override
public void visit(Tree.StaticMemberOrTypeExpression that) {
Tree.TypeArguments tal = that.getTypeArguments();
Integer startIndex = tal==null ?
null : that.getTypeArguments().getStartIndex();
... | 0true | plugins_com.redhat.ceylon.eclipse.ui_src_com_redhat_ceylon_eclipse_code_complete_TypeArgumentListCompletions.java |
653 | public class TransportGetIndexTemplatesAction extends TransportMasterNodeReadOperationAction<GetIndexTemplatesRequest, GetIndexTemplatesResponse> {
@Inject
public TransportGetIndexTemplatesAction(Settings settings, TransportService transportService, ClusterService clusterService, ThreadPool threadPool) {
... | 1no label | src_main_java_org_elasticsearch_action_admin_indices_template_get_TransportGetIndexTemplatesAction.java |
1,305 | public static final class RemoteDBRunner {
public static void main(String[] args) throws Exception {
OGlobalConfiguration.CACHE_LEVEL1_ENABLED.setValue(false);
OGlobalConfiguration.CACHE_LEVEL1_SIZE.setValue(0);
OGlobalConfiguration.CACHE_LEVEL2_ENABLED.setValue(false);
OGlobalConfiguratio... | 0true | server_src_test_java_com_orientechnologies_orient_core_storage_impl_local_paginated_LocalPaginatedStorageUpdateCrashRestore.java |
696 | class LRUEntry {
OCacheEntry cacheEntry;
long hashCode;
LRUEntry next;
LRUEntry after;
LRUEntry before;
@Override
public boolean equals(Object o) {
if (this == o)
return true;
if (o == null || getClass() != o.getClass())
return false;
LRUEntry lruEntry = (LRUEn... | 0true | core_src_main_java_com_orientechnologies_orient_core_index_hashindex_local_cache_LRUEntry.java |
1,170 | public static enum ORDER {
/**
* Used when order compared to other operator can not be evaluated or has no consequences.
*/
UNKNOWNED,
/**
* Used when this operator must be before the other one
*/
BEFORE,
/**
* Used when this operator must be after the other one
*/
... | 0true | core_src_main_java_com_orientechnologies_orient_core_sql_operator_OQueryOperator.java |
157 | public abstract class AbstractStructuredContentRuleProcessor implements StructuredContentRuleProcessor {
private static final Log LOG = LogFactory.getLog(AbstractStructuredContentRuleProcessor.class);
private Map expressionCache = Collections.synchronizedMap(new LRUMap(1000));
private ParserContext parserC... | 0true | admin_broadleaf-contentmanagement-module_src_main_java_org_broadleafcommerce_cms_structure_service_AbstractStructuredContentRuleProcessor.java |
2,248 | return new TokenStream() {
boolean finished = true;
final CharTermAttribute term = addAttribute(CharTermAttribute.class);
final PayloadAttribute payload = addAttribute(PayloadAttribute.class);
@Override
public boolean incrementT... | 0true | src_test_java_org_elasticsearch_common_lucene_uid_VersionsTests.java |
1,773 | map.addEntryListener(new EntryAdapter<Object, Object>() {
@Override
public void entryEvicted(EntryEvent<Object, Object> event) {
count.incrementAndGet();
}
}, true); | 0true | hazelcast_src_test_java_com_hazelcast_map_EvictionTest.java |
11 | static final class AsyncApply<T,U> extends Async {
final T arg;
final Fun<? super T,? extends U> fn;
final CompletableFuture<U> dst;
AsyncApply(T arg, Fun<? super T,? extends U> fn,
CompletableFuture<U> dst) {
this.arg = arg; this.fn = fn; this.dst = ds... | 0true | src_main_java_jsr166e_CompletableFuture.java |
4,876 | public class RestAllocationAction extends AbstractCatAction {
@Inject
public RestAllocationAction(Settings settings, Client client, RestController controller) {
super(settings, client);
controller.registerHandler(GET, "/_cat/allocation", this);
controller.registerHandler(GET, "/_cat/all... | 1no label | src_main_java_org_elasticsearch_rest_action_cat_RestAllocationAction.java |
395 | private final Comparator<CacheRecord<K>> comparator = new Comparator<CacheRecord<K>>() {
public int compare(CacheRecord<K> o1, CacheRecord<K> o2) {
if (EvictionPolicy.LRU.equals(evictionPolicy)) {
return ((Long) o1.lastAccessTime).compareTo((o2.lastAccessTime));
} els... | 0true | hazelcast-client_src_main_java_com_hazelcast_client_nearcache_ClientNearCache.java |
304 | public class OContextConfiguration {
private Map<String, Object> config = new HashMap<String, Object>(); ;
/**
* Empty constructor to create just a proxy for the OGlobalConfiguration. No values are setted.
*/
public OContextConfiguration() {
}
/**
* Initializes the context with custom parameters.
... | 0true | core_src_main_java_com_orientechnologies_orient_core_config_OContextConfiguration.java |
1,250 | public interface FulfillmentPricingProvider {
/**
* Calculates the total cost for this FulfillmentGroup. Specific configurations for calculating
* this cost can come from {@link FulfillmentGroup#getFulfillmentOption()}. This method is invoked
* during the pricing workflow and will only be called if ... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_pricing_service_fulfillment_provider_FulfillmentPricingProvider.java |
391 | @SuppressWarnings({ "serial" })
public class ORecordLazyList extends ORecordTrackedList implements ORecordLazyMultiValue {
protected ORecordLazyListener listener;
protected final byte recordType;
protected ORecordMultiValueHelper.MULTIVALUE_CONTENT_... | 0true | core_src_main_java_com_orientechnologies_orient_core_db_record_ORecordLazyList.java |
1,101 | public final class SSLConfig {
private boolean enabled = false;
private String factoryClassName = null;
private Object factoryImplementation = null;
private Properties properties = new Properties();
/**
* Returns the name of the {@link com.hazelcast.nio.ssl.SSLContextFactory} implementation c... | 0true | hazelcast_src_main_java_com_hazelcast_config_SSLConfig.java |
1,986 | public class ToStringBuilder {
// Linked hash map ensures ordering.
final Map<String, Object> map = new LinkedHashMap<String, Object>();
final String name;
public ToStringBuilder(String name) {
this.name = name;
}
public ToStringBuilder(Class type) {
this.name = type.getSimpl... | 0true | src_main_java_org_elasticsearch_common_inject_internal_ToStringBuilder.java |
604 | public final class IndexMetadata {
private final String name;
private final OIndexDefinition indexDefinition;
private final Set<String> clustersToIndex;
private final String type;
private final String algorithm;
private final String valueContainerAl... | 0true | core_src_main_java_com_orientechnologies_orient_core_index_OIndexInternal.java |
1,221 | public class PaymentSeed implements CompositePaymentResponse {
private Order order;
private Map<PaymentInfo, Referenced> infos;
private PaymentResponse paymentResponse;
private Money transactionAmount;
public PaymentSeed(Order order, Map<PaymentInfo, Referenced> infos, PaymentResponse paymentRespo... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_payment_service_workflow_PaymentSeed.java |
554 | public class ClientTxnQueueProxy<E> extends ClientTxnProxy implements TransactionalQueue<E> {
public ClientTxnQueueProxy(String name, TransactionContextProxy proxy) {
super(name, proxy);
}
public boolean offer(E e) {
try {
return offer(e, 0, TimeUnit.MILLISECONDS);
} ca... | 0true | hazelcast-client_src_main_java_com_hazelcast_client_txn_proxy_ClientTxnQueueProxy.java |
248 | service.submit(runnable, new ExecutionCallback() {
public void onResponse(Object response) {
result.set(response);
responseLatch.countDown();
}
public void onFailure(Throwable t) {
}
}); | 0true | hazelcast-client_src_test_java_com_hazelcast_client_executor_ClientExecutorServiceSubmitTest.java |
804 | public interface FulfillmentGroupAdjustment extends Adjustment {
public FulfillmentGroup getFulfillmentGroup();
public void init(FulfillmentGroup fulfillmentGroup, Offer offer, String reason);
public void setValue(Money value);
public void setFulfillmentGroup(FulfillmentGroup fulfillmentGroup);
... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_offer_domain_FulfillmentGroupAdjustment.java |
812 | @SuppressWarnings("unchecked")
public class OSchemaProxy extends OProxedResource<OSchemaShared> implements OSchema {
public OSchemaProxy(final OSchemaShared iDelegate, final ODatabaseRecord iDatabase) {
super(iDelegate, iDatabase);
}
public void create() {
setCurrentDatabaseInThreadLocal();
delegate.... | 0true | core_src_main_java_com_orientechnologies_orient_core_metadata_schema_OSchemaProxy.java |
2,830 | public class CharFilterTests extends ElasticsearchTokenStreamTestCase {
@Test
public void testMappingCharFilter() throws Exception {
Index index = new Index("test");
Settings settings = settingsBuilder()
.put("index.analysis.char_filter.my_mapping.type", "mapping")
... | 0true | src_test_java_org_elasticsearch_index_analysis_CharFilterTests.java |
28 | {
volatile private StateTransitionLogger logger = null;
@Override
public void listeningAt( URI me )
{
server.listeningAt( me );
if (logger == null)
{
logger = new StateTransitionLogger( logging )... | 1no label | enterprise_cluster_src_main_java_org_neo4j_cluster_client_ClusterClient.java |
1,606 | Collections.sort(lockInfos, new Comparator<LockInfo>() {
public int compare(LockInfo o1, LockInfo o2) {
int comp1 = Integer.valueOf(o2.getWaitingThreadCount()).compareTo(o1.getWaitingThreadCount());
if (comp1 == 0)
return Long.valueOf(o1.getAcquire... | 0true | hazelcast_src_main_java_com_hazelcast_management_ClusterRuntimeState.java |
1,127 | @Beta
public interface AsyncAtomicReference<E> extends IAtomicReference<E> {
ICompletableFuture<Boolean> asyncCompareAndSet(E expect, E update);
ICompletableFuture<E> asyncGet();
ICompletableFuture<Void> asyncSet(E newValue);
ICompletableFuture<E> asyncGetAndSet(E newValue);
ICompletableFuture<... | 0true | hazelcast_src_main_java_com_hazelcast_core_AsyncAtomicReference.java |
900 | threadPool.executor(ThreadPool.Names.SEARCH).execute(new Runnable() {
@Override
public void run() {
performFirstPhase(fShardIndex, shardIt);
... | 1no label | src_main_java_org_elasticsearch_action_search_type_TransportSearchTypeAction.java |
2,904 | public class NumericLongAnalyzer extends NumericAnalyzer<NumericLongTokenizer> {
private final static IntObjectOpenHashMap<NamedAnalyzer> builtIn;
static {
builtIn = new IntObjectOpenHashMap<NamedAnalyzer>();
builtIn.put(Integer.MAX_VALUE, new NamedAnalyzer("_long/max", AnalyzerScope.GLOBAL, n... | 0true | src_main_java_org_elasticsearch_index_analysis_NumericLongAnalyzer.java |
973 | public class OLinkSerializer implements OBinarySerializer<OIdentifiable> {
private static final int CLUSTER_POS_SIZE = OClusterPositionFactory.INSTANCE.getSerializedSize();
public static OLinkSerializer INSTANCE = new OLinkSerializer();
public static final byte ID = 9;
public static final int RID_SIZE = OShort... | 0true | core_src_main_java_com_orientechnologies_orient_core_serialization_serializer_binary_impl_OLinkSerializer.java |
1,271 | public static class Customer implements Serializable {
private int year;
private String name;
private byte[] field = new byte[100];
public Customer(int i, String s) {
this.year = i;
this.name = s;
}
} | 0true | hazelcast_src_main_java_com_hazelcast_examples_AllTest.java |
3,708 | public static class Defaults {
public static final String NAME = VersionFieldMapper.NAME;
public static final float BOOST = 1.0f;
public static final FieldType FIELD_TYPE = NumericDocValuesField.TYPE;
} | 0true | src_main_java_org_elasticsearch_index_mapper_internal_VersionFieldMapper.java |
1,883 | node.executeTransaction(options, new TransactionalTask<Boolean>() {
public Boolean execute(TransactionalTaskContext context) throws TransactionException {
final TransactionalMap<Object, Object> txMap = context.getMap(mapName);
PagingPredicate predicate = new PagingPre... | 0true | hazelcast_src_test_java_com_hazelcast_map_MapTransactionTest.java |
187 | public abstract class RecursiveAction extends ForkJoinTask<Void> {
private static final long serialVersionUID = 5232453952276485070L;
/**
* The main computation performed by this task.
*/
protected abstract void compute();
/**
* Always returns {@code null}.
*
* @return {@code ... | 0true | src_main_java_jsr166y_RecursiveAction.java |
3,537 | public class CompletionFieldMapperTests extends ElasticsearchTestCase {
@Test
public void testDefaultConfiguration() throws IOException {
String mapping = jsonBuilder().startObject().startObject("type1")
.startObject("properties").startObject("completion")
.field("type",... | 0true | src_test_java_org_elasticsearch_index_mapper_completion_CompletionFieldMapperTests.java |
1,652 | public class Explicit<T> {
private final T value;
private final boolean explicit;
/**
* Create a value with an indication if this was an explicit choice
* @param value a setting value
* @param explicit true if the value passed is a conscious decision, false if using some kind of default
... | 0true | src_main_java_org_elasticsearch_common_Explicit.java |
876 | threadPool.executor(ThreadPool.Names.SEARCH).execute(new Runnable() {
@Override
public void run() {
for (AtomicArray.Entry<IntArrayList> entry : docIdsToLoad.asList()) {
QuerySearchResult quer... | 0true | src_main_java_org_elasticsearch_action_search_type_TransportSearchQueryThenFetchAction.java |
2,467 | static class TieBreakingPrioritizedRunnable extends PrioritizedRunnable {
final Runnable runnable;
final long insertionOrder;
TieBreakingPrioritizedRunnable(PrioritizedRunnable runnable, long insertionOrder) {
this(runnable, runnable.priority(), insertionOrder);
}
... | 0true | src_main_java_org_elasticsearch_common_util_concurrent_PrioritizedEsThreadPoolExecutor.java |
497 | public interface Catalog extends Serializable {
Long getId();
void setId(Long id);
String getName();
void setName(String name);
List<Site> getSites();
void setSites(List<Site> sites);
} | 0true | common_src_main_java_org_broadleafcommerce_common_site_domain_Catalog.java |
3,399 | public abstract class FieldsVisitor extends StoredFieldVisitor {
protected BytesReference source;
protected Uid uid;
protected Map<String, List<Object>> fieldsValues;
public void postProcess(MapperService mapperService) {
if (uid != null) {
DocumentMapper documentMapper = mapperSer... | 0true | src_main_java_org_elasticsearch_index_fieldvisitor_FieldsVisitor.java |
1,699 | runnable = new Runnable() { public void run() { map.set(null, "value"); } }; | 0true | hazelcast_src_test_java_com_hazelcast_map_BasicMapTest.java |
63 | public interface IntByIntToInt { int apply(int a, int b); } | 0true | src_main_java_jsr166e_ConcurrentHashMapV8.java |
169 | {
@Override
public boolean matchesSafely( LogEntry.OnePhaseCommit onePC )
{
return onePC != null && onePC.getIdentifier() == identifier && onePC.getTxId() == txId;
}
@Override
public void describeTo( Description descriptio... | 0true | community_kernel_src_test_java_org_neo4j_kernel_impl_transaction_xaframework_LogMatchers.java |
2,285 | public class NoneRecycler<T> extends AbstractRecycler<T> {
public NoneRecycler(C<T> c) {
super(c);
}
@Override
public V<T> obtain(int sizing) {
return new NV<T>(c.newInstance(sizing));
}
@Override
public void close() {
}
public static class NV<T> implements Recyc... | 0true | src_main_java_org_elasticsearch_common_recycler_NoneRecycler.java |
676 | constructors[COLLECTION_ROLLBACK_BACKUP] = new ConstructorFunction<Integer, IdentifiedDataSerializable>() {
public IdentifiedDataSerializable createNew(Integer arg) {
return new CollectionRollbackBackupOperation();
}
}; | 0true | hazelcast_src_main_java_com_hazelcast_collection_CollectionDataSerializerHook.java |
2,139 | public class ObjectRecordFactory implements RecordFactory<Object> {
private final SerializationService serializationService;
private final boolean statisticsEnabled;
public ObjectRecordFactory(MapConfig config, SerializationService serializationService) {
this.serializationService = serializationS... | 1no label | hazelcast_src_main_java_com_hazelcast_map_record_ObjectRecordFactory.java |
369 | public class HBaseLockStoreTest extends LockKeyColumnValueStoreTest {
@BeforeClass
public static void startHBase() throws IOException {
HBaseStorageSetup.startHBase();
}
@AfterClass
public static void stopHBase() {
// Workaround for https://issues.apache.org/jira/browse/HBASE-10312
... | 0true | titan-hbase-parent_titan-hbase-core_src_test_java_com_thinkaurelius_titan_diskstorage_hbase_HBaseLockStoreTest.java |
1,224 | public class WorkflowPaymentContext implements ProcessContext {
public final static long serialVersionUID = 1L;
private boolean stopEntireProcess = false;
private CombinedPaymentContextSeed seedData;
public void setSeedData(Object seedObject) {
this.seedData = (CombinedPaymentContextSeed) see... | 0true | core_broadleaf-framework_src_main_java_org_broadleafcommerce_core_payment_service_workflow_WorkflowPaymentContext.java |
149 | public abstract class XaCommand
{
private boolean isRecovered = false;
/**
* Default implementation of rollback that does nothing. This method is not
* to undo any work done by the {@link #execute} method. Commands in a
* {@link XaTransaction} are either all rolled back or all executed, they're
... | 0true | community_kernel_src_main_java_org_neo4j_kernel_impl_transaction_xaframework_XaCommand.java |
456 | private static final Map<EntryMetaData,Object> metaData = new EntryMetaData.Map() {{
put(EntryMetaData.TIMESTAMP,Long.valueOf(101));
put(EntryMetaData.TTL, 42);
put(EntryMetaData.VISIBILITY,"SOS/K5a-89 SOS/sdf3");
}}; | 0true | titan-test_src_test_java_com_thinkaurelius_titan_diskstorage_keycolumnvalue_StaticArrayEntryTest.java |
3,880 | public class IndicesQueryParser implements QueryParser {
public static final String NAME = "indices";
@Nullable
private final ClusterService clusterService;
@Inject
public IndicesQueryParser(@Nullable ClusterService clusterService) {
this.clusterService = clusterService;
}
@Overr... | 1no label | src_main_java_org_elasticsearch_index_query_IndicesQueryParser.java |
1,481 | public class OSQLFunctionOutV extends OSQLFunctionMove {
public static final String NAME = "outV";
public OSQLFunctionOutV() {
super(NAME, 0, 1);
}
@Override
protected Object move(final OrientBaseGraph graph, final OIdentifiable iRecord, final String[] iLabels) {
return e2v(graph, iRecord, Direction... | 1no label | graphdb_src_main_java_com_orientechnologies_orient_graph_sql_functions_OSQLFunctionOutV.java |
2,469 | executor.execute(new Runnable() {
@Override
public void run() {
try {
block.await();
} catch (InterruptedException e) {
fail();
}
}
@Override
public String toStrin... | 0true | src_test_java_org_elasticsearch_common_util_concurrent_PrioritizedExecutorsTests.java |
1,901 | public interface SpawnModules {
Iterable<? extends Module> spawnModules();
} | 0true | src_main_java_org_elasticsearch_common_inject_SpawnModules.java |
8 | public class LabelAbbreviationsTest {
@Test
public void getAbbreviation() throws SecurityException, NoSuchFieldException, IllegalArgumentException, IllegalAccessException {
AbbreviationsImpl availableAbbreviations = new AbbreviationsImpl("value");
availableAbbreviations.addPhrase("Amps", Collections.singletonLi... | 0true | tableViews_src_test_java_gov_nasa_arc_mct_abbreviation_impl_LabelAbbreviationsTest.java |
137 | @Test
public class ByteSerializerTest {
private static final int FIELD_SIZE = 1;
private static final Byte OBJECT = 1;
private OByteSerializer byteSerializer;
byte[] stream = new byte[FIELD_SIZE];
@BeforeClass
public void beforeClass() {
byteSerializer = new OByteSerialize... | 0true | commons_src_test_java_com_orientechnologies_common_serialization_types_ByteSerializerTest.java |
1,334 | @ClusterScope(scope = SUITE)
public class AckTests extends ElasticsearchIntegrationTest {
@Override
protected Settings nodeSettings(int nodeOrdinal) {
//to test that the acknowledgement mechanism is working we better disable the wait for publish
//otherwise the operation is most likely acknowle... | 0true | src_test_java_org_elasticsearch_cluster_ack_AckTests.java |
620 | public abstract class OIndexOneValue extends OIndexAbstract<OIdentifiable> {
public OIndexOneValue(final String type, String algorithm, OIndexEngine<OIdentifiable> engine, String valueContainerAlgorithm) {
super(type, algorithm, engine, valueContainerAlgorithm);
}
public OIdentifiable get(Object iKey) {
... | 1no label | core_src_main_java_com_orientechnologies_orient_core_index_OIndexOneValue.java |
71 | public interface StaticAssetStorageDao {
StaticAssetStorage create();
StaticAssetStorage readStaticAssetStorageById(Long id);
public StaticAssetStorage readStaticAssetStorageByStaticAssetId(Long id);
StaticAssetStorage save(StaticAssetStorage assetStorage);
void delete(StaticAssetStorage assetSt... | 0true | admin_broadleaf-contentmanagement-module_src_main_java_org_broadleafcommerce_cms_file_dao_StaticAssetStorageDao.java |
41 | static final class ModuleDescriptorProposal extends CompletionProposal {
ModuleDescriptorProposal(int offset, String prefix, String moduleName) {
super(offset, prefix, MODULE,
"module " + moduleName,
"module " + moduleName + " \"1.0.0\" {}");
... | 0true | plugins_com.redhat.ceylon.eclipse.ui_src_com_redhat_ceylon_eclipse_code_complete_ModuleCompletions.java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.