Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you... | 0 |
* or an {@link BasicManagedEntity entity} | 0 |
dict.put("instance.name", instance.getAttribute("name"));
| 0 |
private final Map<String, String> blockContexts;
public BlockContextURLStreamHandler(Map<String, String> blockContexts) {
@Override | 0 |
public class FtpFileNameParser extends HostFileNameParser {
public FtpFileNameParser() {
public static FileNameParser getInstance() { | 1 |
public abstract class AbstractCheckDigitTest extends TestCase { | 0 |
@Test
public void testAbortHolding() {
UnitOfWork unitOfWork = EasyMock.createMock(UnitOfWork.class);
ActionDBAccessor db = EasyMock.createMock(ActionDBAccessor.class);
ActionQueue aq = new ActionQueue();
Clusters fsm = EasyMock.createMock(Clusters.class);
Configuration conf = new Configuration(... | 0 |
/* ====================================================================
* Copyright (c) 2003-2004 The Apache Software Foundation. All rights
* @version $Revision: 1.2 $ $Date: 2004/01/14 21:43:08 $ | 0 |
} catch (final UnsupportedCharsetException ex) { | 0 |
/**
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distribu... | 0 |
@Override
@Override
@Override
@Override
@Override
@Override
@Override
@Override
@Override
@Override | 0 |
package org.apache.http.nio.impl;
import org.apache.http.nio.impl.InputBuffer;
import org.apache.http.nio.impl.OutputBuffer; | 0 |
assertEquals(propertyDefinitions.size(), 3); | 0 |
public void add(HostsType hostsType, String service,
boolean forUpgrade, boolean clientOnly, ProcessingComponent pc) { | 0 |
c.tableOperations().addSplits(table, new TreeSet<>(Lists.transform(Arrays.asList(splits), Text::new))); | 0 |
import static org.apache.beam.vendor.guava.v26_0_jre.com.google.common.base.Preconditions.checkArgument;
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.base.MoreObjects; | 0 |
// Constants used to make sure assignment logging isn't excessive in quantity or size
private static final String ASSIGNMENT_BUFFER_SEPARATOR = ", ";
private static final int ASSINGMENT_BUFFER_MAX_LENGTH = 4096;
final StringBuilder builder = new StringBuilder(64);
if (builder.length() > 0) {
... | 0 |
import static com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly;
shell = new Shell(new ConsoleReader(input, output)); | 0 |
/*
* Copyright 2016-2018 Seznam.cz, a.s. | 0 |
private class TimersImpl implements Timers { | 0 |
if (value > 0.0) {
metricCount++;
} | 0 |
import com.google.common.annotations.VisibleForTesting;
@VisibleForTesting protected DataflowPipelineRunner(DataflowPipelineOptions options) {
transform instanceof GroupByKey
? ((GroupByKey<?, ?>) transform).updateWindowingStrategy(pc.getWindowingStrategy())
: pc.getWindowingStra... | 0 |
import org.apache.accumulo.core.client.security.tokens.PasswordToken; | 1 |
for (byte b : bytes) {
out.write(b); | 0 |
* @version CVS $Id: ContextHelper.java,v 1.2 2003/05/23 12:14:04 cziegeler Exp $
public static final String CONTEXT_REQUEST_OBJECT = CONTEXT_OBJECT_MODEL + '.' + ObjectModelHelper.REQUEST_OBJECT;
public static final String CONTEXT_RESPONSE_OBJECT = CONTEXT_OBJECT_MODEL + '.' + ObjectModelHelper.RESPONSE_OBJECT... | 0 |
import org.apache.accumulo.core.client.BatchWriterConfig;
BatchWriter bw = c.createBatchWriter(Constants.METADATA_TABLE_NAME, new BatchWriterConfig());
BatchWriter bw = connector.createBatchWriter("!METADATA", new BatchWriterConfig()); | 0 |
traitPredicate = SearchPredicateUtil.getNotEmptyPredicateGenerator().generatePredicate(Constants.TRAIT_NAMES_PROPERTY_KEY, null, List.class); | 0 |
*
*
private static final String SEPARATOR = ":";
StringTokenizer tokenizer = new StringTokenizer(value.trim(), SEPARATOR);
StringBuffer constructedRgbString = new StringBuffer();
if (j > 0) {
constructedRgbString.append(SEPARATOR);
}
constructedR... | 0 |
.setIntParameter(CoreConnectionPNames.MIN_CHUNK_LIMIT, 1024)
new DefaultHttpResponseFactory(),
reqistry,
params); | 0 |
import org.apache.cocoon.forms.event.CreateEvent;
import org.apache.cocoon.forms.event.CreateListener;
import org.apache.cocoon.forms.event.WidgetEventMulticaster;
* @version $Id: AbstractWidgetDefinition.java,v 1.7 2004/06/15 07:33:44 sylvain Exp $
protected CreateListener createListener;
protected ... | 0 |
* implementation of {@link JXPathContext} also globally caches some of the
* To acquire a CompiledExpression, call {@link JXPathContext#compile
* the path by invoking an {@link AbstractFactory}, which should first be
* installed on the context by calling {@link JXPathContext#setFactory}.
* the path by ... | 1 |
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may... | 0 |
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you... | 0 |
public static <ElemT, ViewT> CreateDataflowView<ElemT, ViewT> forBatch(PCollectionView<ViewT> view) {
return new CreateDataflowView<>(view, false);
}
public static <ElemT, ViewT> CreateDataflowView<ElemT, ViewT> forStreaming(PCollectionView<ViewT> view) {
return new CreateDataflowView<>(view, true);
pr... | 0 |
* <li>{@link org.apache.http.params.CoreConnectionPNames#MAX_LINE_LENGTH}</li> | 0 |
* @author <a href="mailto:dev@felix.apache.org">Apache Felix Project</a>
} | 0 |
package aQute.bnd.osgi;
import aQute.bnd.header.*; | 0 |
*
*
*
*
*
*
* | 0 |
import java.nio.charset.Charset;
private static final Charset utf8 = Charset.forName("UTF8");
return ("" + size + "," + numEntries + "," + time).getBytes(utf8);
return ("" + size + "," + numEntries).getBytes(utf8); | 0 |
EncodingUtils.getBytes(tmp.toString(), charset), false); | 0 |
* Enumeration of the supported versions of Gremlin. | 1 |
private static final String SHELL_DESCRIPTION = "Shell - Apache Accumulo Interactive Shell"; | 0 |
@Override
public void visit(State state, Properties props) throws Exception {
String indexTableName = (String) state.get("indexTableName");
int numPartitions = (Integer) state.get("numPartitions");
Random rand = (Random) state.get("rand");
SortedSet<Text> splitSet = ShardFixture.genSplits(numPart... | 1 |
import org.apache.ambari.logsearch.common.LogSearchContext;
import org.apache.ambari.logsearch.web.model.User;
LogSearchContext context = new LogSearchContext();
User user = new User();
user.setUsername("myUserId");
context.setUser(user);
LogSearchContext.setContext(context); | 0 |
* Copyright (c) OSGi Alliance (2000, 2013). All Rights Reserved.
* @author $Id: c2d45ff158a6a19ff7bc155af3ac9941cb6a89d6 $
@Override
@Override
@Override
@Override
@Override
* Called by {@link PackagePermission#implies(Permission)}. This method is
* only called on a requested permission which cannot have a fi... | 0 |
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by ap... | 1 |
private static org.apache.bcel.util.Repository repository = SyntheticRepository.getInstance();
return repository;
repository = rep;
return repository.loadClass(class_name);
return repository.loadClass(clazz);
ClassPath path = repository.getClassPath();
repository.... | 0 |
* @version $Revision: 1.5 $ $Date: 2004/06/03 22:02:13 $
/** Serialization version */
private static final long serialVersionUID = -8304417378626543635L;
| 0 |
.addNullableField("f_string", FieldType.STRING)
.addField(fieldName, fieldType.type()) | 0 |
import org.apache.accumulo.server.tabletserver.compaction.CompactionStrategy;
import org.apache.accumulo.server.tabletserver.compaction.CompactionStrategy.Writer;
import org.apache.accumulo.server.tabletserver.compaction.DefaultWriter;
import org.apache.accumulo.server.tabletserver.compaction.MajorCompactionReason;
p... | 0 |
private final String id;
public PoolEntry(final String id, final T route, final C conn,
final long timeToLive, final TimeUnit tunit) {
this.id = id;
public PoolEntry(final String id, final T route, final C conn) {
this(id, route, conn, 0, TimeUnit.MILLISECONDS);
public String... | 0 |
* @version CVS $Id: LinkService.java,v 1.4 2004/02/28 17:26:28 cziegeler Exp $
* @param event The event to add (null is also allowed for convenience) | 0 |
import org.apache.atlas.AtlasServiceException;
import org.testng.Assert;
@Test(dependsOnMethods = "testConsumerConsumesNewMessageWithAutoCommitDisabled")
public void testConsumerRemainsAtSameMessageWithAutoCommitEnabled() throws Exception {
try {
hookConsumer.handleMessage(consumer.next());... | 0 |
* Attempts to modify it will result in an UnsupportedOperationException.
*
*
*
@SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect
* | 0 |
if (null != hostsType && !hostsType.getHosts().contains(hostName)) { | 0 |
public String repair()
{ | 0 |
/** {{@inheritDoc}}. */
/** {{@inheritDoc}}. */
/** {{@inheritDoc}}. */
/** {{@inheritDoc}}. */
/** {{@inheritDoc}}. */ | 0 |
public static final String ENC_BINARY = "binary"; | 0 |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | 0 |
throw new UnsupportedOperationException(
String.format("%s is not supported yet!", relNode.getClass().toString()));
throw new UnsupportedOperationException("Operator: " + opName + " is not supported yet!");
throw new UnsupportedOperationException(
String.format("%s is not suppo... | 0 |
package test.switches;
/**
* An enum.
*/
public enum Color {
RED, GREEN, BLUE
} | 0 |
import com.google.common.base.Splitter;
import com.google.common.collect.Lists;
combiners = new ColumnSet(Lists.newArrayList(Splitter.on(",").split(encodedColumns)));
for (String columns : Splitter.on(",").split(encodedColumns)) { | 0 |
if (shutdownExecutor && (executor != null) && (!executor.isShutdown())) {
try {
executor.shutdownNow();
} finally {
executor = null;
} | 0 |
assertEquals(KeeperException.Code.NONODE, e.code());
assertEquals(KeeperException.Code.NONODE, e.code());
assertEquals(KeeperException.Code.NONODE, e.code());
assertEquals(KeeperException.Code.NONODE, e.code());
assertEquals(KeeperException.Code.NONODE, e.code... | 0 |
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
* | 0 |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | 0 |
localServer = null; | 0 |
Copyright 2001,2003 The Apache Software Foundation
public static final
return fontBridge.createFont(ctx, fontElement, textElement,
complex = ret ? Boolean.TRUE : Boolean.FALSE; | 0 |
package org.apache.batik.ext.awt.image.codec.util; | 0 |
* $Header$
* @version $Revision$ $Date$ | 0 |
import java.util.Collections;
import java.util.Map;
final long startTime = Time.currentElapsedTime();
ServerMetrics.getMetrics().OM_PROPOSAL_PROCESS_TIME.add(Time.currentElapsedTime() - startTime);
final long startTime = Time.currentElapsedTime();
ServerMe... | 0 |
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you m... | 0 |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | 0 |
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you... | 0 |
*/
final List<InstructionHandle> Q = new ArrayList<>();
}
// default case: Fall through. | 0 |
/**
* serialVersionUID format is YYYYMMDD for the data of the last binary change.
*/
private static final long serialVersionUID = 20101208L;
| 0 |
// Note that we don't check this if the submit widget was already set, as it can cause problems
// if the user triggers submit with an input (which sets 'forms_submit_id'), then clicks back
// and submits using a regular submit button.
if (getSubmitWidget() =... | 0 |
public abstract class AbstractWindowing<T, KEY, W extends Window<KEY>>
protected W addNewWindow(W window, Triggering triggering,
UnaryFunction<Window<?>, Void> evict) { | 0 |
this.serverParams);
this.clientParams);
this.serverParams);
this.clientParams);
this.serverParams);
this.clientParams);
this.serverParams);
this.clientParams);
this.serverParam... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/test/org/apache/commons/jxpath/ri/model/dynabeans/DynaBeanModelTest.java,v 1.4 2003/10/09 21:31:44 rdonkin Exp $
* $Revision: 1.4 $
* $Date: 2003/10/09 21:31:44 $
* any, must include the following acknowledgement:
... | 0 |
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ImmutableList;
import org.apache.beam.vendor.guava.v20_0.com.google.common.net.HostAndPort;
import org.apache.beam.vendor.guava.v20_0.com.google.common.util.concurrent.Uninterruptibles; | 0 |
CoderProperties.coderConsistentWithEquals(
Coder.INSTANCE,
CoderProperties.coderDecodeEncodeEqual(
Coder.INSTANCE,
CoderProperties.structuralValueDecodeEncodeEqual(
Coder.INSTANCE, | 1 |
public static final String UPGRADE_CHECK_FAILED_DETAIL_PROPERTY_ID = PropertyHelper.getPropertyId("UpgradeChecks", "failed_detail");
UPGRADE_CHECK_FAILED_DETAIL_PROPERTY_ID,
setResourceProperty(resource, UPGRADE_CHECK_FAILED_DETAIL_PROPERTY_ID,prerequisiteCheck.getFailedDetail(), requestedIds); | 0 |
* Copyright (c) OSGi Alliance (2010, 2013). All Rights Reserved.
import org.osgi.annotation.versioning.ProviderType;
* @author $Id: 367499c4b37683c52e622f479242a9caf7e59b0f $
@ProviderType
* given namespace, the list contains the capabilities in the order
* the capabilities were specified in the m... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//beanutils/src/java/org/apache/commons/beanutils/ConvertUtils.java,v 1.11 2002/12/21 19:53:24 craigmcc Exp $
* $Revision: 1.11 $
* $Date: 2002/12/21 19:53:24 $
* @version $Revision: 1.11 $ $Date: 2002/12/21 19:53:24 $
* retur... | 0 |
String edgeLabel = graphHelper.getEdgeLabel(typedInstance, attributeInfo);
Edge currentEdge = graphHelper.getEdgeForLabel(instanceVertex, edgeLabel); | 1 |
private final int instance;
public TaskRescheduled(String role, String job, int instance) {
this.instance = instance;
public int getInstance() {
return instance;
&& Objects.equal(instance, other.instance);
return Objects.hashCode(role, job, instance); | 0 |
protected static final Map<String,String> commandMap = new HashMap<String,String>( );
StringBuffer sb = new StringBuffer();
sb.append(quotaPath);
sb.append("/" + splits[i]);
quotaPath = sb.toString(); | 0 |
String dDescription = m_configMap.getDecription(); | 0 |
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;
import com.google.common.collect.Lists;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.TemporaryFolder;
@Rule public TemporaryFolder folder = new TemporaryFolder();... | 0 |
public class ByteArrayEntity extends AbstractHttpEntity implements Cloneable {
public Object clone() throws CloneNotSupportedException {
return super.clone();
} | 0 |
.canonical(); | 0 |
for(int i = 0; i < properties.length ; i++) {
} | 0 |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | 0 |
import java.util.BitSet;
import java.util.Collections;
import java.util.EnumMap;
import java.util.EnumSet;
import java.util.HashMap;
import java.util.Map;
import org.apache.thrift.EncodingUtils;
import org.apache.thrift.protocol.TTupleProtocol;
private static final long serialVersionUID = -4659975753252858243l;
| 0 |
package org.apache.beam.runners.core.construction;
* Tests for {@link ElementAndRestrictionCoder}. | 0 |
@Override
@Override
@Override
@Override
@Override
@Override
@Override
public byte[] getBuffer() {
return seekableInput.getBuffer();
}
@Override
@Override
/**
* The byte array returned by this method is only for read optimizations, it should not be modified.
... | 0 |
static org.slf4j.Logger LOG =
LOG.warn("Test testContentRemoved skipped as necessary algorithms not available");
LOG.warn("Test testMultipleKeyInfoElements skipped as necessary algorithms not available"); | 0 |
file.println("<H4><A NAME=\"" + anchor + "\">" + attr_count + " " + Constants.getAttributeName(tag) | 0 |
for (int i = 0; (i < modes.length) && (modes[i] != PtyMode.TTY_OP_END);) {
* According to https://tools.ietf.org/html/rfc4254#section-8:
* Opcodes 160 to 255 are not yet defined, and cause parsing to stop
if ((opcode >= 160) && (opcode <= 255)) {
log.wa... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.