Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
public class LicenseManager implements ILicenseManager
{
private HashMap<String, Pattern> licenses = new HashMap<String, Pattern>();
private HashMap<String, LicensePolicy> policies = new HashMap<String, LicensePolicy>();
private LicensePolicy defaultPolicy = new LicensePolicy( this );
public void a... | 0 |
import org.apache.beam.sdk.PipelineRunner; | 0 |
* NameFileComparator.NAME_COMPARATOR.sort(list);
* NameFileComparator.NAME_INSENSITIVE_REVERSE.sort(array);
public class NameFileComparator extends AbstractFileComparator implements Serializable { | 0 |
ModificationHandler {
* The default value producer.
*/
protected DefaultAttributeValueProducer defaultValueProducer;
/**
* @param def The default value producer.
public SVGOMAnimatedLength(SVGOMElement elt, String nsURI, String attr,
DefaultAttributeVa... | 0 |
@XmlElement(name="supportDeleteViaUI")
private Boolean supportDeleteViaUIField;
private boolean supportDeleteViaUIInternal = true;
public Boolean getSupportDeleteViaUIField(){
return supportDeleteViaUIField;
}
public void setSupportDeleteViaUIField(Boolean supportDeleteViaUIField) {
this.supportD... | 0 |
* ConditionalWriter provides the ability to do efficient, atomic read-modify-write operations on
* rows. These operations are performed on the tablet server while a row lock is held.
* If this method throws an exception, then its possible the mutation is still being actively
* processed. Therefore if code c... | 0 |
* Copyright (c) 1999 The Apache Software Foundation. All rights
* notice, this list of conditions and the following disclaimer.
* if any, must include the following acknowledgment:
* software without prior written permission. For written
* The development of this software was partly funded by the Europea... | 0 |
import static java.util.Objects.requireNonNull;
requireNonNull(className);
requireNonNull(opts); | 0 |
@Override
protected int defaultTimeoutSeconds() {
return 60;
}
@Test | 0 |
* If it is not yet {@link #open open} but {@link #announce announced}, | 0 |
/*
* Copyright (c) OSGi Alliance (2016). All Rights Reserved.
*
* 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 ... | 0 |
List<String> messages = new ArrayList<>(); | 0 |
* @version $Id: BooleanType.java,v 1.3 2004/02/11 09:53:44 antonio Exp $ | 0 |
public class PlainSocketFactory extends AbstractConnectionSocketFactory { | 0 |
package org.apache.aurora.scheduler.storage.backup;
import org.apache.aurora.codec.ThriftBinaryCodec;
import org.apache.aurora.codec.ThriftBinaryCodec.CodingException;
import org.apache.aurora.gen.storage.Snapshot;
import org.apache.aurora.scheduler.storage.SnapshotStore;
| 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 |
* e.g. x = { a$args }; x 1 2 => a1 2 and not a[1, 2] | 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.collect.ImmutableList; | 0 |
return NullableCoder.of(inputTVCoder.getValueCoder()); | 0 |
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.collect.ImmutableMap; | 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 |
* <p>
* </p>
*
* <p>
* </p>
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
*
* <p>
* </p>
* @throws IOException if failed to consume the da... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/decorators/Attic/TestTransformedList.java,v 1.3 2003/10/02 22:14:34 scolebourne Exp $
import org.apache.commons.collections.AbstractTestList;
* @version $Revision: 1.3 $ $Date: 20... | 0 |
* @version $Revision$ | 0 |
import org.osgi.util.converter.Functioning;
@Override
public Functioning function() {
return new FunctioningImpl(this);
}
| 0 |
.setConnectionTimeout(33, TimeUnit.MILLISECONDS) | 0 |
public <OutputT extends POutput, InputT extends PInput> OutputT apply(
PTransform<InputT, OutputT> transform, InputT input) { | 0 |
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
@SuppressFBWarnings(value = "PATH_TRAVERSAL_IN", justification = "paths not set by user input") | 0 |
* Annotates an Adapater service component. Adapters, like {@link AspectService}, are used to "extend"
* The AdapterService will also have the following service property: p1=v1, p2=v2 :
* interface AdapteeService {
* void method1();
* void method2();
* }
*
* @Component
* @Property(name="p1", v... | 0 |
this.connpool = new BasicNIOConnPool(this.ioReactor, new BasicNIOConnFactory(connFactory), 0); | 0 |
import java.net.ServerSocket;
import org.junit.Ignore;
private int port;
@Ignore("AES192CBC is not always available by default")
@Ignore("AES192CBC is not always available by default")
ServerSocket s = new ServerSocket(0);
port = s.getLocalPort();
s.close();
sshd.setPort(por... | 0 |
/** Properties needed when using Bigtable with the Beam SDK. */
| 1 |
Table hiveTable = setupTable(hiveClient, TEST_DB_NAME, TEST_TABLE_NAME);
String processQualifiedName = HiveMetaStoreBridge.getTableQualifiedName(CLUSTER_NAME, hiveTable);
when(atlasClient.searchByDSL(HiveMetaStoreBridge.getProcessDSLQuery(HiveDataTypes.HIVE_PROCESS.getName(),
pro... | 0 |
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
return new AppConfigurationEntry[]{
AppConfigurationEntry.LoginModuleControlFlag.REQUIRED,
new HashMap<String, Object>())
| 1 |
*
* @version $Id: FieldDefinition.java,v 1.3 2004/02/11 10:43:30 antonio Exp $ | 0 |
public Builder setExpectContinueEnabled(final boolean expectContinueEnabled) {
public Builder setStaleConnectionCheckEnabled(final boolean staleConnectionCheckEnabled) {
public Builder setRedirectsEnabled(final boolean redirectsEnabled) {
public Builder setRelativeRedirectsAllowed(final ... | 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 ... | 1 |
import javax.annotation.Nullable;
private @Nullable T nextElement; | 0 |
public <R, P> R accept( NodeVisitor<? extends R, ? super P> visitor, P data )
throws OgnlException | 0 |
if (chopped) {
if (state.equals(TabletState.HOSTED)) {
this.chopped++;
} else if (!hasWALs) {
this.chopped++;
}
}
log.info("Computing next merge state for " + info.getRange() + " which is presently " + state + " isDelete : " + info.isDelete());
log.info(... | 0 |
HashSet<String> expectedServices = new HashSet<>();
Map<String, ServiceInfo> serviceMap = new HashMap<>();
HashSet<String> expectedServices = new HashSet<>();
assertEquals(new HashSet<>(stormServiceComponents), new HashSet<>(baseStormServiceComponents));
HashSet<String> expectedServices = new HashSe... | 1 |
extends DoFnOperator<KeyedWorkItem<K, InputT>, KV<K, OutputT>> { | 0 |
import com.google.inject.Inject;
import com.google.inject.Singleton;
import org.apache.ambari.view.tez.exceptions.TezWebAppException;
import org.slf4j.LoggerFactory;
import java.util.HashMap;
import java.util.Map;
private static final Logger LOG = LoggerFactory.getLogger(ViewControllerImpl.class);
String messa... | 0 |
private static final Pattern SINGLE_QUOTED_IDENTIFIER = Pattern.compile("'(\\w[\\w\\d\\.\\s]*)'");
private static final Pattern DOUBLE_QUOTED_IDENTIFIER = Pattern.compile("\"(\\w[\\w\\d\\.\\s]*)\"");
private static final Pattern BACKTICK_QUOTED_IDENTIFIER = Pattern.compile("`(\\w[\\w\\d\\.\\s]*)`");
... | 0 |
import org.apache.felix.ipojo.composite.service.importer.ImportExportHandler;
import org.apache.felix.ipojo.composite.service.instantiator.ServiceInstantiatorHandler;
/**
* Available composite handlers in the iPOJO bundle.
*/
public static final Class[] INTERNAL_COMPOSITE_HANDLERS = new Class[] {
ServiceInstant... | 0 |
* Sets the topKey and topValue based on the top key of the source. If the column of the source top key is in the set of combiners, topKey will be the top key
* of the source and topValue will be the result of the reduce method. Otherwise, topKey and topValue will be unchanged. (They are always set to null before
... | 0 |
public class LogicalTimeIT extends SimpleMacIT { | 0 |
String testDataPath = System.getProperty("test.data.dir", "src/test/resources/data"); | 0 |
* @param object object to test
* @param toType target class
* @return boolean
* @param object object to convert
* @param toType target class
* @return resulting Object | 0 |
* Copyright 1999-2002,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 ... | 1 |
* @version CVS $Id: Environment.java,v 1.3 2003/05/04 19:03:01 stephan Exp $
String getRootContext();
String getContext();
/**
* Set the context. This is similar to changeContext()
* except that it is absolute.
*/
void setContext(String prefix, String uri, String context); | 0 |
return String.format("<a href='/trace/listType?type=%s&minutes=%d'>%s</a>", encodedType,
minutes, type);
public void pageBody(HttpServletRequest req, HttpServletResponse resp, StringBuilder sb)
throws Exception {
trace.addSortableColumn("Histogram", new HistogramType(),
"Counts of sp... | 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 |
/**
* Generated serial version ID.
*/
private static final long serialVersionUID = 4354731610923110264L; | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/test/org/apache/commons/jxpath/ri/compiler/CoreFunctionTest.java,v 1.8 2004/01/19 20:44:52 dmitri Exp $
* $Revision: 1.8 $
* $Date: 2004/01/19 20:44:52 $
* @version $Revision: 1.8 $ $Date: 2004/01/19 20:44:52 $
... | 0 |
package org.apache.accumulo.shell.commands;
import org.apache.accumulo.shell.Shell;
import org.apache.accumulo.shell.ShellExtension;
import org.apache.accumulo.shell.Shell.Command; | 0 |
public <C> int getMatchingChildrenCount(ImmutableNode node,
NodeMatcher<C> matcher, C criterion)
{
return getMatchingChildren(node, matcher, criterion).size();
/**
* {@inheritDoc} This implementation returns an immutable list with all
* child nodes accepted by the specified mat... | 0 |
ValueProvider<String> nvp = NestedValueProvider.of(svp, from -> from + "bar");
ValueProvider<String> nvp = NestedValueProvider.of(rvp, from -> from + "bar");
ValueProvider<String> doubleNvp = NestedValueProvider.of(nvp, from -> from); | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//validator/src/share/org/apache/commons/validator/Validator.java,v 1.30 2003/08/26 16:11:48 rleland Exp $
* $Revision: 1.30 $
* $Date: 2003/08/26 16:11:48 $
* @version $Revision: 1.30 $ $Date: 2003/08/26 16:11:48 $ | 0 |
extends CloseableUtils.AbstractInnerCloseable
implements Channel, ExecutorServiceConfigurer {
protected ExecutorService executor;
protected boolean shutdownExecutor;
protected final AtomicBoolean eof = new AtomicBoolean(false);
: SshConstants.SSH_MSG_CHANNEL_FAILURE;
... | 1 |
package org.apache.commons.ognl.internal;
import org.apache.commons.ognl.internal.entry.MethodAccessCacheEntryFactory;
import org.apache.commons.ognl.internal.entry.MethodAccessEntryValue;
import org.apache.commons.ognl.test.objects.Root;
import org.junit.Assert;
import org.junit.Test;
import java.lang.reflect.Method... | 0 |
if (super.validateOptions(options) == false)
return false;
try {
setEncoder(options);
} catch (Exception e) {
throw new IllegalArgumentException("bad encoder option", e);
} | 1 |
public ABlockWriter prepareMetaBlock(String name, String compressionName) throws IOException;
public ABlockWriter prepareMetaBlock(String name) throws IOException;
public ABlockWriter prepareDataBlock() throws IOException;
public void close() throws IOException; | 1 |
* any, must include the following acknowledgement:
* Alternately, this acknowledgement may appear in the software itself,
* if and wherever such third-party acknowledgements normally appear.
* permission of the Apache Software Foundation. | 0 |
public DefaultClientIdentitiesWatcher(
boolean supportedOnly, ClientIdentityLoader loader, FilePasswordProvider provider, boolean strict) { | 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 |
* @deprecated use {@link FTPCmd} instead
@Deprecated | 0 |
package cz.seznam.euphoria.operator.test.ng.junit;
import cz.seznam.euphoria.core.executor.Executor;
public interface ExecutorEnvironment {
Executor getExecutor();
void shutdown() throws Exception;
} | 0 |
final Map<TupleTag<?>, Object> sideInputCache;
this.sideInputCache = new HashMap<>();
if (!sideInputCache.containsKey(tag)) {
if (!sideInputs.has(tag)) {
throw new IllegalArgumentException(
"calling sideInput() with unknown view; " +
"did you forget to pass the view in " ... | 0 |
import org.apache.commons.jelly.parser.XMLParser;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
* @version $Revision: 1.14 $
/** The Log to which logging calls will be made. */
private static final Log log = LogFactory.getLog(XMLOutput.class);
if (lo... | 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 |
package com.twitter.aurora.scheduler.periodic;
import com.twitter.aurora.Protobufs;
import com.twitter.aurora.codec.ThriftBinaryCodec;
import com.twitter.aurora.codec.ThriftBinaryCodec.CodingException;
import com.twitter.aurora.gen.ScheduledTask;
import com.twitter.aurora.gen.comm.AdjustRetainedTasks;
import com.twitte... | 1 |
import org.apache.beam.sdk.transforms.windowing.BoundedWindow;
@Override public BeamSqlPrimitive<? extends Number> evaluate(BeamRecord inputRow,
BoundedWindow window) {
return calculate(operand.evaluate(inputRow, window)); | 0 |
package org.apache.beam.examples.complete.game;
import org.apache.beam.examples.complete.game.UserScore.GameActionInfo;
import org.apache.beam.examples.complete.game.UserScore.ParseEventFn;
import org.apache.beam.sdk.Pipeline;
import org.apache.beam.sdk.coders.StringUtf8Coder;
import org.apache.beam.sdk.testing.PAsser... | 0 |
public Object clone() {
DefaultHttpParams clone = new DefaultHttpParams(this.defaults); | 0 |
* limitations under the License. | 0 |
import static com.google.common.base.Charsets.UTF_8;
OutputStreamWriter osw = new OutputStreamWriter(dataOut, UTF_8);
BufferedWriter distcpOut = new BufferedWriter(new OutputStreamWriter(fs.create(new Path(exportDir, "distcp.txt"), false), UTF_8));
OutputStreamWriter osw = new OutputStreamWriter(dataOut,... | 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 |
* Gets the query string.
* Gets the path and query string e.g. /path/servlet?param1=true.
* Gets the path encoded suitable for url like filesystem e.g. (http, webdav).
* Creates a FileName.
* Appends query string to the uri.
* Encodes a URI. | 0 |
* }</pre>
* <p>It is up to the user to ensure that two {@code TupleTag}s with the same id actually mean the
* same tag and carry the same generic type parameter. Violating this invariant can lead to
* hard-to-diagnose runtime type errors. Consequently, this operation should be used very
* sparingly, such a... | 1 |
import org.apache.felix.sigil.common.osgi.VersionRange; | 0 |
throw new BridgeException(ctx, filteredElement,
throw new BridgeException(ctx, clippedElement,
throw new BridgeException(ctx, maskedElement, | 1 |
import org.junit.Test;
import static org.junit.Assert.*;
@Test
@Test | 0 |
private int pmg_class_index, pmg_index;
* @param pmg_class_index
*/
public final void setPMGClassIndex( int pmg_class_index ) {
this.pmg_class_index = pmg_class_index;
}
/**
* @param pmg_index
*/
public final void setPMGIndex( int pmg_index ) {
this.pmg_index = ... | 0 |
import com.google.common.cache.Cache;
import com.google.common.cache.CacheBuilder;
import com.google.common.collect.Maps;
import com.google.inject.Inject;
import com.google.inject.Singleton;
import com.google.inject.persist.Transactional;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collect... | 0 |
* Returns <code>true</code> if VFS treats the user directory as the root directory. Defaults to <code>true</code>.
*
* @param opts
* The FileSystemOptions.
* @return <code>true</code> if VFS treats the user directory as the root directory. Defaults to <code>true</code>.
retu... | 0 |
import cz.seznam.euphoria.core.client.dataset.windowing.MergingWindowing;
import cz.seznam.euphoria.guava.shaded.com.google.common.collect.Iterables;
import java.util.Random;
private boolean allowWindowBasedShuffling = false;
public InMemExecutor setReduceStateByKeyMaxKeysPerWindow(int maxKeyPerWindow) {
return... | 0 |
* @version $Revision$ $Date$ | 0 |
import org.apache.felix.ipojo.test.scenarios.configuration.service.CheckService;
Factory fact = Utils.getFactoryByName(context, "CONFIG-FieldConfigurableCheckService"); | 0 |
suite.addTest(TestBaseIOReactorSSL.suite());
suite.addTest(TestDefaultIOReactorsSSL.suite()); | 0 |
* Tests {@link org.apache.commons.ognl.ASTMethod}. | 0 |
* <p>
* <b>Note:</b> {@link org.apache.cocoon.selection.ResourceExistsSelector}
* should be preferred to this component, as the semantics of a Selector better
* match the supplied functionality.
* @version CVS $Id: ResourceExistsAction.java,v 1.2 2003/03/19 06:19:38 jefft Exp $ | 0 |
.apply(View.asIterable()); | 0 |
import com.google.inject.Inject;
import com.google.inject.Provider;
import org.apache.ambari.server.state.stack.PrereqCheckType;
} | 0 |
import org.apache.accumulo.core.cli.BatchWriterOpts;
import org.apache.accumulo.core.cli.ClientOnRequiredTable;
import com.beust.jcommander.Parameter;
static class Opts extends ClientOnRequiredTable {
@Parameter(names="--start")
long start = 0;
@Parameter(names="--num", required=true)
long num = 0... | 1 |
class CBZip2InputStream
CBZip2InputStream( final InputStream input ) | 0 |
import org.junit.Before;
@Before
public void init(){
DummyMetricsSink.clear();
}
| 0 |
repoFile = new RepositoryXml();
repoFile.setValid(false);
repoFile.setErrors("Unable to parse repo file at location: " +
repositoryFile.getAbsolutePath());
if (repoFile == null || !repoFile.isValid()) {
metaInfoXml = new StackMetainfoXml();
metaInfoXml.set... | 0 |
package org.apache.felix.ipojo.test.scenarios.component;
import org.apache.felix.ipojo.annotations.Component;
import org.apache.felix.ipojo.annotations.Controller;
import org.apache.felix.ipojo.annotations.Invalidate;
import org.apache.felix.ipojo.annotations.Validate;
@Component
public class Lifecycle {
@Control... | 0 |
public void addWorkRecord(Text file, Value v, Map<String,String> targets,
String sourceTableId) {
conn.securityOperations().grantTablePermission(conn.whoami(), ReplicationTable.NAME,
TablePermission.WRITE);
conn.securityOperations().grantTablePermission(conn.whoami(), ReplicationTable.NAME,
... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.