method
stringlengths
13
441k
clean_method
stringlengths
7
313k
doc
stringlengths
17
17.3k
comment
stringlengths
3
1.42k
method_name
stringlengths
1
273
extra
dict
imports
list
imports_info
stringlengths
19
34.8k
cluster_imports_info
stringlengths
15
3.66k
libraries
list
libraries_info
stringlengths
6
661
id
int64
0
2.92M
void setRelatedAssociation(DEAssociation value);
void setRelatedAssociation(DEAssociation value);
/** * Sets the value of the '{@link fr.unice.spinefm.ConfigurationModel.Link#getRelatedAssociation <em>Related Association</em>}' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Related Association</em>' reference. * @see #getRelatedAssociation() * @gene...
Sets the value of the '<code>fr.unice.spinefm.ConfigurationModel.Link#getRelatedAssociation Related Association</code>' reference.
setRelatedAssociation
{ "repo_name": "surli/spinefm", "path": "spinefm-eclipseplugins-root/spinefm-core/src-gen/fr/unice/spinefm/ConfigurationModel/Link.java", "license": "mit", "size": 4702 }
[ "fr.unice.spinefm.MSPLModel" ]
import fr.unice.spinefm.MSPLModel;
import fr.unice.spinefm.*;
[ "fr.unice.spinefm" ]
fr.unice.spinefm;
1,446,857
public ActionForward saveDaiaForm(final ActionMapping mp, final ActionForm fm, final HttpServletRequest rq, final HttpServletResponse rp) { final Auth auth = new Auth(); // make sure the user is logged in if (!auth.isLogin(rq)) { return mp.findForward(Result.ER...
ActionForward function(final ActionMapping mp, final ActionForm fm, final HttpServletRequest rq, final HttpServletResponse rp) { final Auth auth = new Auth(); if (!auth.isLogin(rq)) { return mp.findForward(Result.ERROR_TIMEOUT.getValue()); } if (!auth.isBibliothekar(rq) && !auth.isAdmin(rq)) { return mp.findForward(Res...
/** * Save an external order form. */
Save an external order form
saveDaiaForm
{ "repo_name": "gbv/doctor-doc", "path": "source/ch/dbs/actions/bestellung/BestellformAction.java", "license": "gpl-2.0", "size": 84477 }
[ "ch.dbs.entity.BestellFormParam", "ch.dbs.entity.DaiaParam", "ch.dbs.entity.Text", "ch.dbs.form.Message", "ch.dbs.form.UserInfo", "java.util.List", "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse", "org.apache.struts.action.ActionForm", "org.apache.struts.action.Ac...
import ch.dbs.entity.BestellFormParam; import ch.dbs.entity.DaiaParam; import ch.dbs.entity.Text; import ch.dbs.form.Message; import ch.dbs.form.UserInfo; import java.util.List; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.apache.struts.action.ActionForm; impor...
import ch.dbs.entity.*; import ch.dbs.form.*; import java.util.*; import javax.servlet.http.*; import org.apache.struts.action.*;
[ "ch.dbs.entity", "ch.dbs.form", "java.util", "javax.servlet", "org.apache.struts" ]
ch.dbs.entity; ch.dbs.form; java.util; javax.servlet; org.apache.struts;
2,098,906
static Type extractBoundForTypeVariable(TypeVariable typeVariable) { Type[] bounds = typeVariable.getBounds(); if (bounds.length == 0) { return Object.class; } Type bound = bounds[0]; if (bound instanceof TypeVariable) { bound = extractBoundForTypeVariable((TypeVariable) bound); } return bound; ...
static Type extractBoundForTypeVariable(TypeVariable typeVariable) { Type[] bounds = typeVariable.getBounds(); if (bounds.length == 0) { return Object.class; } Type bound = bounds[0]; if (bound instanceof TypeVariable) { bound = extractBoundForTypeVariable((TypeVariable) bound); } return bound; }
/** * Extracts the bound <code>Type</code> for a given {@link TypeVariable}. */
Extracts the bound <code>Type</code> for a given <code>TypeVariable</code>
extractBoundForTypeVariable
{ "repo_name": "cbeams-archive/spring-framework-2.5.x", "path": "src/org/springframework/core/GenericTypeResolver.java", "license": "apache-2.0", "size": 9688 }
[ "java.lang.reflect.Type", "java.lang.reflect.TypeVariable" ]
import java.lang.reflect.Type; import java.lang.reflect.TypeVariable;
import java.lang.reflect.*;
[ "java.lang" ]
java.lang;
469,214
public static int getApisPerPageInPublisher() { String paginationLimit = ServiceReferenceHolder.getInstance().getAPIManagerConfigurationService() .getAPIManagerConfiguration().getFirstProperty(APIConstants.API_PUBLISHER_APIS_PER_PAGE); if (paginationLimit != null) { retu...
static int function() { String paginationLimit = ServiceReferenceHolder.getInstance().getAPIManagerConfigurationService() .getAPIManagerConfiguration().getFirstProperty(APIConstants.API_PUBLISHER_APIS_PER_PAGE); if (paginationLimit != null) { return Integer.parseInt(paginationLimit); } return 0; }
/** * Used to get the custom pagination limit for publisher * * @return returns the publisher pagination value from api-manager.xml */
Used to get the custom pagination limit for publisher
getApisPerPageInPublisher
{ "repo_name": "tharikaGitHub/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.impl/src/main/java/org/wso2/carbon/apimgt/impl/utils/APIUtil.java", "license": "apache-2.0", "size": 563590 }
[ "org.wso2.carbon.apimgt.impl.APIConstants", "org.wso2.carbon.apimgt.impl.internal.ServiceReferenceHolder" ]
import org.wso2.carbon.apimgt.impl.APIConstants; import org.wso2.carbon.apimgt.impl.internal.ServiceReferenceHolder;
import org.wso2.carbon.apimgt.impl.*; import org.wso2.carbon.apimgt.impl.internal.*;
[ "org.wso2.carbon" ]
org.wso2.carbon;
1,323,843
private void shutdownTaskProcess(ForkingTaskRunnerWorkItem taskInfo) { if (taskInfo.processHolder != null) { // Will trigger normal failure mechanisms due to process exit LOGGER.info("Closing output stream to task[%s].", taskInfo.getTask().getId()); try { taskInfo.processHolder.process...
void function(ForkingTaskRunnerWorkItem taskInfo) { if (taskInfo.processHolder != null) { LOGGER.info(STR, taskInfo.getTask().getId()); try { taskInfo.processHolder.process.getOutputStream().close(); } catch (Exception e) { LOGGER.warn(e, STR, taskInfo.getTask().getId()); taskInfo.processHolder.process.destroy(); } } }...
/** * Close task output stream (input stream of process) sending EOF telling process to terminate, destroying the process * if an exception is encountered. */
Close task output stream (input stream of process) sending EOF telling process to terminate, destroying the process if an exception is encountered
shutdownTaskProcess
{ "repo_name": "himanshug/druid", "path": "indexing-service/src/main/java/org/apache/druid/indexing/overlord/ForkingTaskRunner.java", "license": "apache-2.0", "size": 27573 }
[ "com.google.common.util.concurrent.ListenableFuture", "org.apache.druid.indexer.TaskStatus", "org.apache.druid.indexing.common.task.Task" ]
import com.google.common.util.concurrent.ListenableFuture; import org.apache.druid.indexer.TaskStatus; import org.apache.druid.indexing.common.task.Task;
import com.google.common.util.concurrent.*; import org.apache.druid.indexer.*; import org.apache.druid.indexing.common.task.*;
[ "com.google.common", "org.apache.druid" ]
com.google.common; org.apache.druid;
2,558,493
@XmlElement(name="well") @XmlElementWrapper(name="wells") public void setWells(List<SimpleWellXMLInteger> wells) { this.wells = wells; }
@XmlElement(name="well") @XmlElementWrapper(name="wells") void function(List<SimpleWellXMLInteger> wells) { this.wells = wells; }
/** * Sets the list of set wells. * @param List<SimpleWellXMLInteger> the list of set wells */
Sets the list of set wells
setWells
{ "repo_name": "jessemull/MicroFlex", "path": "src/main/java/com/github/jessemull/microflex/integerflex/io/WellSetXMLInteger.java", "license": "apache-2.0", "size": 4578 }
[ "java.util.List", "javax.xml.bind.annotation.XmlElement", "javax.xml.bind.annotation.XmlElementWrapper" ]
import java.util.List; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlElementWrapper;
import java.util.*; import javax.xml.bind.annotation.*;
[ "java.util", "javax.xml" ]
java.util; javax.xml;
2,673,243
public void setLongNull( int nIndex ) { try { _statement.setNull( nIndex, Types.BIGINT ); logParameter( nIndex, "null" ); } catch( SQLException e ) { free( ); throw new AppException( getErrorMessage( e ), e ); } ...
void function( int nIndex ) { try { _statement.setNull( nIndex, Types.BIGINT ); logParameter( nIndex, "null" ); } catch( SQLException e ) { free( ); throw new AppException( getErrorMessage( e ), e ); } }
/** * Sets null value for a "long" column * * @param nIndex * the index */
Sets null value for a "long" column
setLongNull
{ "repo_name": "rzara/lutece-core", "path": "src/java/fr/paris/lutece/util/sql/DAOUtil.java", "license": "bsd-3-clause", "size": 83663 }
[ "fr.paris.lutece.portal.service.util.AppException", "java.sql.SQLException", "java.sql.Types" ]
import fr.paris.lutece.portal.service.util.AppException; import java.sql.SQLException; import java.sql.Types;
import fr.paris.lutece.portal.service.util.*; import java.sql.*;
[ "fr.paris.lutece", "java.sql" ]
fr.paris.lutece; java.sql;
860,027
public byte[][] getRegionSplitStartKeys(byte[] startKey, byte[] endKey, int numRegions){ assertTrue(numRegions>3); byte [][] tmpSplitKeys = Bytes.split(startKey, endKey, numRegions - 3); byte [][] result = new byte[tmpSplitKeys.length+1][]; System.arraycopy(tmpSplitKeys, 0, result, 1, tmpSplitKeys.len...
byte[][] function(byte[] startKey, byte[] endKey, int numRegions){ assertTrue(numRegions>3); byte [][] tmpSplitKeys = Bytes.split(startKey, endKey, numRegions - 3); byte [][] result = new byte[tmpSplitKeys.length+1][]; System.arraycopy(tmpSplitKeys, 0, result, 1, tmpSplitKeys.length); result[0] = HConstants.EMPTY_BYTE_...
/** * Create region split keys between startkey and endKey * * @param startKey * @param endKey * @param numRegions the number of regions to be created. it has to be greater than 3. * @return resulting split keys */
Create region split keys between startkey and endKey
getRegionSplitStartKeys
{ "repo_name": "francisliu/hbase", "path": "hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java", "license": "apache-2.0", "size": 169730 }
[ "org.apache.hadoop.hbase.util.Bytes", "org.junit.Assert" ]
import org.apache.hadoop.hbase.util.Bytes; import org.junit.Assert;
import org.apache.hadoop.hbase.util.*; import org.junit.*;
[ "org.apache.hadoop", "org.junit" ]
org.apache.hadoop; org.junit;
1,283,472
boolean checkStructuralEquivalenceHelper( ObjectType otherObject, EquivalenceMethod eqMethod, EqCache eqCache) { if (this.isTemplatizedType() && this.toMaybeTemplatizedType().wrapsSameRawType(otherObject)) { return this.getTemplateTypeMap().checkEquivalenceHelper( otherObject.getTemplateType...
boolean checkStructuralEquivalenceHelper( ObjectType otherObject, EquivalenceMethod eqMethod, EqCache eqCache) { if (this.isTemplatizedType() && this.toMaybeTemplatizedType().wrapsSameRawType(otherObject)) { return this.getTemplateTypeMap().checkEquivalenceHelper( otherObject.getTemplateTypeMap(), eqMethod, eqCache, Su...
/** * Check for structural equivalence with {@code that}. * (e.g. two @record types with the same prototype properties) */
Check for structural equivalence with that. (e.g. two @record types with the same prototype properties)
checkStructuralEquivalenceHelper
{ "repo_name": "Pimm/closure-compiler", "path": "src/com/google/javascript/rhino/jstype/ObjectType.java", "license": "apache-2.0", "size": 26312 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
2,314,599
private float[] getMapWorldBounds() { float[] nswe = getMapWorldBoundsE6(); float n = nswe[0] / LibraryConstants.E6; float s = nswe[1] / LibraryConstants.E6; float w = nswe[2] / LibraryConstants.E6; float e = nswe[3] / LibraryConstants.E6; return new float[]{n, s, w, ...
float[] function() { float[] nswe = getMapWorldBoundsE6(); float n = nswe[0] / LibraryConstants.E6; float s = nswe[1] / LibraryConstants.E6; float w = nswe[2] / LibraryConstants.E6; float e = nswe[3] / LibraryConstants.E6; return new float[]{n, s, w, e}; }
/** * Retrieves the map world bounds in degrees. * * @return the [n,s,w,e] in degrees. */
Retrieves the map world bounds in degrees
getMapWorldBounds
{ "repo_name": "integracaomt/MTISIG4", "path": "geopaparazzi.app/src/eu/hydrologis/geopaparazzi/maps/MapsActivity.java", "license": "gpl-3.0", "size": 68324 }
[ "eu.geopaparazzi.library.util.LibraryConstants" ]
import eu.geopaparazzi.library.util.LibraryConstants;
import eu.geopaparazzi.library.util.*;
[ "eu.geopaparazzi.library" ]
eu.geopaparazzi.library;
2,677,472
@Test public void testReportGauge_withJSONHavingIntValueAtLocationAndDynamicPrefix() throws Exception { final StatsDClient client = Mockito.mock(StatsDClient.class); StatsdExtractedMetricsReporterConfiguration cfg = new StatsdExtractedMetricsReporterConfiguration("host", 8125, "prefix"); cfg.addMetricConfig(n...
void function() throws Exception { final StatsDClient client = Mockito.mock(StatsDClient.class); StatsdExtractedMetricsReporterConfiguration cfg = new StatsdExtractedMetricsReporterConfiguration("host", 8125, STR); cfg.addMetricConfig(new StatsdMetricConfig(STR, new JsonContentReference(new String[]{STR}, JsonContentTy...
/** * Test case for {@link StatsdExtractedMetricsReporter#reportGauge(StatsdMetricConfig, JSONObject)} being provided a json which has a value at the referenced location and * a dynamic prefix is requested */
Test case for <code>StatsdExtractedMetricsReporter#reportGauge(StatsdMetricConfig, JSONObject)</code> being provided a json which has a value at the referenced location and a dynamic prefix is requested
testReportGauge_withJSONHavingIntValueAtLocationAndDynamicPrefix
{ "repo_name": "ottogroup/flink-operator-library", "path": "src/test/java/com/ottogroup/bi/streaming/operator/json/statsd/StatsdExtractedMetricsReporterTest.java", "license": "apache-2.0", "size": 58212 }
[ "com.ottogroup.bi.streaming.operator.json.JsonContentReference", "com.ottogroup.bi.streaming.operator.json.JsonContentType", "com.timgroup.statsd.StatsDClient", "org.apache.sling.commons.json.JSONObject", "org.mockito.Mockito" ]
import com.ottogroup.bi.streaming.operator.json.JsonContentReference; import com.ottogroup.bi.streaming.operator.json.JsonContentType; import com.timgroup.statsd.StatsDClient; import org.apache.sling.commons.json.JSONObject; import org.mockito.Mockito;
import com.ottogroup.bi.streaming.operator.json.*; import com.timgroup.statsd.*; import org.apache.sling.commons.json.*; import org.mockito.*;
[ "com.ottogroup.bi", "com.timgroup.statsd", "org.apache.sling", "org.mockito" ]
com.ottogroup.bi; com.timgroup.statsd; org.apache.sling; org.mockito;
2,243,257
public void setInternationalCurrencySymbol(String value) { if (value == null) { currency = null; intlCurrencySymbol = null; return; } if (value.equals(intlCurrencySymbol)) { return; } try { currency = Currency.getI...
void function(String value) { if (value == null) { currency = null; intlCurrencySymbol = null; return; } if (value.equals(intlCurrencySymbol)) { return; } try { currency = Currency.getInstance(value); currencySymbol = currency.getSymbol(locale); } catch (IllegalArgumentException e) { currency = null; } intlCurrencySymb...
/** * Sets the international currency symbol. * <p> * The currency and currency symbol are also updated if {@code value} is a * valid ISO4217 currency code. * <p> * The min and max number of fraction digits stay the same. * * @param value * the currency code. ...
Sets the international currency symbol. The currency and currency symbol are also updated if value is a valid ISO4217 currency code. The min and max number of fraction digits stay the same
setInternationalCurrencySymbol
{ "repo_name": "freeVM/freeVM", "path": "enhanced/java/classlib/modules/text/src/main/java/java/text/DecimalFormatSymbols.java", "license": "apache-2.0", "size": 18965 }
[ "java.util.Currency" ]
import java.util.Currency;
import java.util.*;
[ "java.util" ]
java.util;
1,210,585
private NameInformation getEnclosingFunctionDependencyScope(NodeTraversal t) { Node function = t.getEnclosingFunction(); if (function == null) { return null; } NameInformation ref = scopes.get(function); if (ref != null) { return ref; } // Function expression. try to get a n...
NameInformation function(NodeTraversal t) { Node function = t.getEnclosingFunction(); if (function == null) { return null; } NameInformation ref = scopes.get(function); if (ref != null) { return ref; } Node parent = function.getParent(); if (parent != null) { while (parent.getType() == Token.HOOK) { parent = parent.get...
/** * Get dependency scope defined by the enclosing function, or null. * If enclosing function is a function expression, determine scope based on * its parent if the parent node is a variable declaration or * assignment. */
Get dependency scope defined by the enclosing function, or null. If enclosing function is a function expression, determine scope based on its parent if the parent node is a variable declaration or assignment
getEnclosingFunctionDependencyScope
{ "repo_name": "Dandandan/wikiprogramming", "path": "jsrepl/tools/closure-compiler/trunk/src/com/google/javascript/jscomp/NameAnalyzer.java", "license": "mit", "size": 60058 }
[ "com.google.javascript.rhino.Node", "com.google.javascript.rhino.Token" ]
import com.google.javascript.rhino.Node; import com.google.javascript.rhino.Token;
import com.google.javascript.rhino.*;
[ "com.google.javascript" ]
com.google.javascript;
332,661
@Test public void testReloadFeed() throws Exception { BookMarkLoadListener listener = null; try { final IFeed feed = DynamicDAO.save(new Feed(new URI("http://www.rssowl.org/rssowl2dg/tests/manager/rss_2_0.xml"))); //$NON-NLS-1$ IBookMark bookmark = createBookMark(feed); final Atomi...
void function() throws Exception { BookMarkLoadListener listener = null; try { final IFeed feed = DynamicDAO.save(new Feed(new URI("http: IBookMark bookmark = createBookMark(feed); final AtomicBoolean bool1 = new AtomicBoolean(false); final AtomicBoolean bool2 = new AtomicBoolean(false); assertTrue(bookmark.getNewsRefs...
/** * Reload a Feed. * * @throws Exception */
Reload a Feed
testReloadFeed
{ "repo_name": "YixingCheng/RSSOwl", "path": "org.rssowl.core.tests/src/org/rssowl/core/tests/controller/ControllerTestNetwork.java", "license": "epl-1.0", "size": 11380 }
[ "java.util.concurrent.atomic.AtomicBoolean", "org.junit.Assert", "org.rssowl.core.internal.persist.Feed", "org.rssowl.core.persist.IBookMark", "org.rssowl.core.persist.IFeed", "org.rssowl.core.persist.INews", "org.rssowl.core.persist.dao.DynamicDAO", "org.rssowl.ui.internal.Controller" ]
import java.util.concurrent.atomic.AtomicBoolean; import org.junit.Assert; import org.rssowl.core.internal.persist.Feed; import org.rssowl.core.persist.IBookMark; import org.rssowl.core.persist.IFeed; import org.rssowl.core.persist.INews; import org.rssowl.core.persist.dao.DynamicDAO; import org.rssowl.ui.internal.Cont...
import java.util.concurrent.atomic.*; import org.junit.*; import org.rssowl.core.internal.persist.*; import org.rssowl.core.persist.*; import org.rssowl.core.persist.dao.*; import org.rssowl.ui.internal.*;
[ "java.util", "org.junit", "org.rssowl.core", "org.rssowl.ui" ]
java.util; org.junit; org.rssowl.core; org.rssowl.ui;
54,616
@Test public void noAdditionalMutationRequired() throws Exception { Map<Replica, Mutation> repairs = new HashMap<>(); repairs.put(replica1, mutation(cell2)); repairs.put(replica2, mutation(cell1)); InstrumentedReadRepairHandler handler = createRepairHandler(repairs, 2); ...
void function() throws Exception { Map<Replica, Mutation> repairs = new HashMap<>(); repairs.put(replica1, mutation(cell2)); repairs.put(replica2, mutation(cell1)); InstrumentedReadRepairHandler handler = createRepairHandler(repairs, 2); handler.sendInitialRepairs(); handler.ack(target1); handler.ack(target2); handler....
/** * If we've received enough acks, we shouldn't send any additional mutations */
If we've received enough acks, we shouldn't send any additional mutations
noAdditionalMutationRequired
{ "repo_name": "spodkowinski/cassandra", "path": "test/unit/org/apache/cassandra/service/reads/repair/BlockingReadRepairTest.java", "license": "apache-2.0", "size": 11637 }
[ "java.util.HashMap", "java.util.Map", "java.util.concurrent.TimeUnit", "org.apache.cassandra.db.Mutation", "org.apache.cassandra.locator.Replica", "org.junit.Assert" ]
import java.util.HashMap; import java.util.Map; import java.util.concurrent.TimeUnit; import org.apache.cassandra.db.Mutation; import org.apache.cassandra.locator.Replica; import org.junit.Assert;
import java.util.*; import java.util.concurrent.*; import org.apache.cassandra.db.*; import org.apache.cassandra.locator.*; import org.junit.*;
[ "java.util", "org.apache.cassandra", "org.junit" ]
java.util; org.apache.cassandra; org.junit;
859,676
protected void decorate() { setBorderPainted(false); setOpaque(true); setContentAreaFilled(false); setMargin(new Insets(1, 1, 1, 1));
void function() { setBorderPainted(false); setOpaque(true); setContentAreaFilled(false); setMargin(new Insets(1, 1, 1, 1));
/** * Decorates the button with the approriate UI configurations. */
Decorates the button with the approriate UI configurations
decorate
{ "repo_name": "vipinraj/Spark", "path": "core/src/main/java/org/jivesoftware/spark/component/RolloverButton.java", "license": "apache-2.0", "size": 2619 }
[ "java.awt.Insets" ]
import java.awt.Insets;
import java.awt.*;
[ "java.awt" ]
java.awt;
1,291,806
public byte[] getPolicyQualifier() { if (qualifier == null) { return null; } return (byte[])qualifier.clone(); } /** * Return a printable representation of this * <code>PolicyQualifierInfo</code>.<br /> * <br /> * Uses {@link org.bouncyca...
byte[] function() { if (qualifier == null) { return null; } return (byte[])qualifier.clone(); } /** * Return a printable representation of this * <code>PolicyQualifierInfo</code>.<br /> * <br /> * Uses {@link org.bouncycastle.asn1.ASN1InputStream ASN1InputStream}, * {@link org.bouncycastle.asn1.ASN1Object ASN1Object}
/** * Returns the ASN.1 DER encoded form of the <code>qualifier</code> field * of this <code>PolicyQualifierInfo</code>. * * @return the ASN.1 DER encoded bytes of the <code>qualifier</code> * field. Note that a copy is returned, so the data is cloned each * time this meth...
Returns the ASN.1 DER encoded form of the <code>qualifier</code> field of this <code>PolicyQualifierInfo</code>
getPolicyQualifier
{ "repo_name": "GaloisInc/hacrypto", "path": "src/Java/BouncyCastle/BouncyCastle-1.50/core/src/main/jdk1.1/java/security/cert/PolicyQualifierInfo.java", "license": "bsd-3-clause", "size": 7476 }
[ "org.bouncycastle.asn1.ASN1InputStream", "org.bouncycastle.asn1.ASN1Object" ]
import org.bouncycastle.asn1.ASN1InputStream; import org.bouncycastle.asn1.ASN1Object;
import org.bouncycastle.asn1.*;
[ "org.bouncycastle.asn1" ]
org.bouncycastle.asn1;
2,733,198
@Test(timeout = 60000) public void testListEncryptionZonesAsNonSuperUser() throws Exception { final UserGroupInformation user = UserGroupInformation. createUserForTesting("user", new String[] { "mygroup" }); final Path testRoot = new Path("/tmp/TestEncryptionZones"); final Path superPath = new...
@Test(timeout = 60000) void function() throws Exception { final UserGroupInformation user = UserGroupInformation. createUserForTesting("user", new String[] { STR }); final Path testRoot = new Path(STR); final Path superPath = new Path(testRoot, STR); final Path allPath = new Path(testRoot, STR); fsWrapper.mkdir(superPa...
/** * Test listing encryption zones as a non super user. */
Test listing encryption zones as a non super user
testListEncryptionZonesAsNonSuperUser
{ "repo_name": "korrelate/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestEncryptionZones.java", "license": "apache-2.0", "size": 52301 }
[ "org.apache.hadoop.fs.Path", "org.apache.hadoop.fs.permission.FsPermission", "org.apache.hadoop.security.UserGroupInformation", "org.junit.Test" ]
import org.apache.hadoop.fs.Path; import org.apache.hadoop.fs.permission.FsPermission; import org.apache.hadoop.security.UserGroupInformation; import org.junit.Test;
import org.apache.hadoop.fs.*; import org.apache.hadoop.fs.permission.*; import org.apache.hadoop.security.*; import org.junit.*;
[ "org.apache.hadoop", "org.junit" ]
org.apache.hadoop; org.junit;
173,784
ServiceCall<Void> getBooleanTrueAsync(final ServiceCallback<Void> serviceCallback);
ServiceCall<Void> getBooleanTrueAsync(final ServiceCallback<Void> serviceCallback);
/** * Get true Boolean value on path. * * @param serviceCallback the async ServiceCallback to handle successful and failed responses. * @return the {@link ServiceCall} object */
Get true Boolean value on path
getBooleanTrueAsync
{ "repo_name": "yugangw-msft/autorest", "path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/url/Queries.java", "license": "mit", "size": 53223 }
[ "com.microsoft.rest.ServiceCall", "com.microsoft.rest.ServiceCallback" ]
import com.microsoft.rest.ServiceCall; import com.microsoft.rest.ServiceCallback;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
1,955,277
public List<Exception> getWarnings() { return this.warnings == null ? Collections.<Exception>emptyList() : this.warnings; }
List<Exception> function() { return this.warnings == null ? Collections.<Exception>emptyList() : this.warnings; }
/** * Gets the complete list of exceptions returned from all flush operations invoked upon this loader. * * @return errors that occurred during flushes */
Gets the complete list of exceptions returned from all flush operations invoked upon this loader
getWarnings
{ "repo_name": "amir20/jpile", "path": "src/main/java/com/opower/persistence/jpile/loader/InfileObjectLoader.java", "license": "mit", "size": 6115 }
[ "java.util.Collections", "java.util.List" ]
import java.util.Collections; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
192,285
public GenericUDTF getGenericUDTF() { // GenericUDTF is stateful too, copy if (genericUDTF == null) { return null; } return FunctionRegistry.cloneGenericUDTF(genericUDTF); }
GenericUDTF function() { if (genericUDTF == null) { return null; } return FunctionRegistry.cloneGenericUDTF(genericUDTF); }
/** * Get a new GenericUDTF object for the function. */
Get a new GenericUDTF object for the function
getGenericUDTF
{ "repo_name": "vergilchiu/hive", "path": "ql/src/java/org/apache/hadoop/hive/ql/exec/FunctionInfo.java", "license": "apache-2.0", "size": 8331 }
[ "org.apache.hadoop.hive.ql.udf.generic.GenericUDTF" ]
import org.apache.hadoop.hive.ql.udf.generic.GenericUDTF;
import org.apache.hadoop.hive.ql.udf.generic.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
836,132
@NotNull Optional<TableHandle> getTableHandle(QualifiedTableName tableName);
Optional<TableHandle> getTableHandle(QualifiedTableName tableName);
/** * Returns a table handle for the specified table name. */
Returns a table handle for the specified table name
getTableHandle
{ "repo_name": "ddd332/presto-0.54", "path": "presto-main/src/main/java/com/facebook/presto/metadata/Metadata.java", "license": "apache-2.0", "size": 3947 }
[ "com.facebook.presto.spi.TableHandle", "com.google.common.base.Optional" ]
import com.facebook.presto.spi.TableHandle; import com.google.common.base.Optional;
import com.facebook.presto.spi.*; import com.google.common.base.*;
[ "com.facebook.presto", "com.google.common" ]
com.facebook.presto; com.google.common;
1,503,766
public final double[ ][ ][ ] forward( double[ ][ ][ ] spaceTime ) { double[ ][ ][ ] spaceHilb = null; try { spaceHilb = _basicTransform.forward( spaceTime ); } catch( JWaveException e ) { e.showMessage( ); e.printStackTrace( ); } // try return spaceHilb; } // forward
final double[ ][ ][ ] function( double[ ][ ][ ] spaceTime ) { double[ ][ ][ ] spaceHilb = null; try { spaceHilb = _basicTransform.forward( spaceTime ); } catch( JWaveException e ) { e.showMessage( ); e.printStackTrace( ); } return spaceHilb; }
/** * Performs the 3-D forward transform of the specified BasicWave object. * * @date 10.07.2010 18:15:22 * @author Christian Scheiblich (cscheiblich@gmail.com) * @param matrixTime * coefficients of 2-D time domain; internal M(i),N(j),O(k) * @return coefficients of 2-D frequency or Hilber...
Performs the 3-D forward transform of the specified BasicWave object
forward
{ "repo_name": "RaineForest/ECG-Viewer", "path": "JWave/src/math/jwave/Transform.java", "license": "gpl-2.0", "size": 16283 }
[ "math.jwave.exceptions.JWaveException" ]
import math.jwave.exceptions.JWaveException;
import math.jwave.exceptions.*;
[ "math.jwave.exceptions" ]
math.jwave.exceptions;
1,433,989
public WorldMap getWorldMap(int id) { WorldMap map = worldMaps.get(id); if (map == null) { throw new WorldMapNotExistException("Map: " + id + " not exist!"); } return map; }
WorldMap function(int id) { WorldMap map = worldMaps.get(id); if (map == null) { throw new WorldMapNotExistException(STR + id + STR); } return map; }
/** * Return World Map by id * * @param id - id of world map. * @return World map. */
Return World Map by id
getWorldMap
{ "repo_name": "GiGatR00n/Aion-Core-v4.7.5", "path": "AC-Game/src/com/aionemu/gameserver/world/World.java", "license": "gpl-2.0", "size": 17978 }
[ "com.aionemu.gameserver.world.exceptions.WorldMapNotExistException" ]
import com.aionemu.gameserver.world.exceptions.WorldMapNotExistException;
import com.aionemu.gameserver.world.exceptions.*;
[ "com.aionemu.gameserver" ]
com.aionemu.gameserver;
1,753,707
public void debugLegalMoves(Object o, List<Move> moves) { String sender = o.getClass().getCanonicalName(); if(debug || isWhiteListed(sender)) { System.out.print(sender + ": "); System.out.println("Legal moves: "); for(int i=0; i<moves.size(); i++) { System.out.print("card -> " + moves.get(i)....
void function(Object o, List<Move> moves) { String sender = o.getClass().getCanonicalName(); if(debug isWhiteListed(sender)) { System.out.print(sender + STR); System.out.println(STR); for(int i=0; i<moves.size(); i++) { System.out.print(STR + moves.get(i).getCard() + STR); System.out.print(STR); for(int j=0; j<moves.ge...
/** * prints the moves in a human readable form * @param o the object which sent the message * @param moves to be shown */
prints the moves in a human readable form
debugLegalMoves
{ "repo_name": "retoo/bodesuri", "path": "src/intelliDOG/ai/utils/DebugMsg.java", "license": "gpl-2.0", "size": 7188 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,067,717
@Generated @Selector("setMinFreeDiskSpaceLimit:") public native void setMinFreeDiskSpaceLimit(long value);
@Selector(STR) native void function(long value);
/** * [@property] minFreeDiskSpaceLimit * <p> * Specifies the minimum amount of free space, in bytes, required for recording to continue on a given volume. * <p> * This property specifies a hard lower limit on the amount of free space that must remain on a target volume for recording to continu...
[@property] minFreeDiskSpaceLimit Specifies the minimum amount of free space, in bytes, required for recording to continue on a given volume.
setMinFreeDiskSpaceLimit
{ "repo_name": "multi-os-engine/moe-core", "path": "moe.apple/moe.platform.ios/src/main/java/apple/avfoundation/AVCaptureFileOutput.java", "license": "apache-2.0", "size": 15277 }
[ "org.moe.natj.objc.ann.Selector" ]
import org.moe.natj.objc.ann.Selector;
import org.moe.natj.objc.ann.*;
[ "org.moe.natj" ]
org.moe.natj;
960,372
public static LinkProperties loadPropertiesIntoOMGraphic(DataInput dis, OMGraphic omg, LinkProperties propertiesBuffer) throws IOException { LinkProperties readProperties = (LinkProperties) read(dis, propertiesBuffer).clone(); ...
static LinkProperties function(DataInput dis, OMGraphic omg, LinkProperties propertiesBuffer) throws IOException { LinkProperties readProperties = (LinkProperties) read(dis, propertiesBuffer).clone(); readProperties.setProperties(omg); return readProperties; }
/** * New, static method for more efficient property handling and loading the * properties into the OMGraphic. * * @param dis * @param omg * @return if there are no properties, the EMPTY_PROPERTIES object is * returned. If there are properties and props == null, then a new ...
New, static method for more efficient property handling and loading the properties into the OMGraphic
loadPropertiesIntoOMGraphic
{ "repo_name": "d2fn/passage", "path": "src/main/java/com/bbn/openmap/layer/link/LinkProperties.java", "license": "mit", "size": 15581 }
[ "com.bbn.openmap.omGraphics.OMGraphic", "java.io.DataInput", "java.io.IOException" ]
import com.bbn.openmap.omGraphics.OMGraphic; import java.io.DataInput; import java.io.IOException;
import com.bbn.openmap.*; import java.io.*;
[ "com.bbn.openmap", "java.io" ]
com.bbn.openmap; java.io;
1,707,949
public void processFile(File file) { if (configurationFile == null) { throw new BuildException("configurationFile not set"); } try { Model model = getDirectDataLoader().getIntegrationWriter().getModel(); DelimitedFileConfiguration dfc; try {...
void function(File file) { if (configurationFile == null) { throw new BuildException(STR); } try { Model model = getDirectDataLoader().getIntegrationWriter().getModel(); DelimitedFileConfiguration dfc; try { dfc = new DelimitedFileConfiguration(model, new FileInputStream(configurationFile)); } catch (Exception e) { thr...
/** * Query all objects of the class given by the className specified in the configurationFile. * Set fields in the objects by using the tab separated files as input. * @param file the File to process * @throws BuildException if an ObjectStore method fails */
Query all objects of the class given by the className specified in the configurationFile. Set fields in the objects by using the tab separated files as input
processFile
{ "repo_name": "joshkh/intermine", "path": "intermine/integrate/main/src/org/intermine/task/TSVFileReaderTask.java", "license": "lgpl-2.1", "size": 5175 }
[ "java.io.File", "java.io.FileInputStream", "org.apache.tools.ant.BuildException", "org.intermine.metadata.Model", "org.intermine.objectstore.ObjectStoreException" ]
import java.io.File; import java.io.FileInputStream; import org.apache.tools.ant.BuildException; import org.intermine.metadata.Model; import org.intermine.objectstore.ObjectStoreException;
import java.io.*; import org.apache.tools.ant.*; import org.intermine.metadata.*; import org.intermine.objectstore.*;
[ "java.io", "org.apache.tools", "org.intermine.metadata", "org.intermine.objectstore" ]
java.io; org.apache.tools; org.intermine.metadata; org.intermine.objectstore;
2,751,895
public Collection getPropertyNames() { return Collections.unmodifiableCollection(this.properties.keySet()); }
Collection function() { return Collections.unmodifiableCollection(this.properties.keySet()); }
/** * Get the names of all properties defined for this BlockState */
Get the names of all properties defined for this BlockState
getPropertyNames
{ "repo_name": "kelthalorn/ConquestCraft", "path": "build/tmp/recompSrc/net/minecraft/block/state/BlockState.java", "license": "lgpl-2.1", "size": 9735 }
[ "java.util.Collection", "java.util.Collections" ]
import java.util.Collection; import java.util.Collections;
import java.util.*;
[ "java.util" ]
java.util;
340,869
MessageT compose(Context context, String source, Object... inputs);
MessageT compose(Context context, String source, Object... inputs);
/** * Composes a message. * * @param context The compose context. * @param source The source message. * @param inputs The message parameters. * * @return the composed message. */
Composes a message
compose
{ "repo_name": "CubeEngine/Dirigent", "path": "src/main/java/org/cubeengine/dirigent/Dirigent.java", "license": "mit", "size": 3074 }
[ "org.cubeengine.dirigent.context.Context" ]
import org.cubeengine.dirigent.context.Context;
import org.cubeengine.dirigent.context.*;
[ "org.cubeengine.dirigent" ]
org.cubeengine.dirigent;
81,998
public ColorStateList getColorStateList(int id) throws NotFoundException { TypedValue value; synchronized (mAccessLock) { value = mTmpValue; if (value == null) { value = new TypedValue(); } else { mTmpValue = null; } ...
ColorStateList function(int id) throws NotFoundException { TypedValue value; synchronized (mAccessLock) { value = mTmpValue; if (value == null) { value = new TypedValue(); } else { mTmpValue = null; } getValue(id, value, true); } ColorStateList res = loadColorStateList(value, id); synchronized (mAccessLock) { if (mTmpV...
/** * Return a color state list associated with a particular resource ID. The * resource may contain either a single raw color value, or a complex * {@link android.content.res.ColorStateList} holding multiple possible colors. * * @param id The desired resource identifier of a {@link ColorState...
Return a color state list associated with a particular resource ID. The resource may contain either a single raw color value, or a complex <code>android.content.res.ColorStateList</code> holding multiple possible colors
getColorStateList
{ "repo_name": "indashnet/InDashNet.Open.UN2000", "path": "android/frameworks/base/core/java/android/content/res/Resources.java", "license": "apache-2.0", "size": 101025 }
[ "android.util.TypedValue" ]
import android.util.TypedValue;
import android.util.*;
[ "android.util" ]
android.util;
1,335,166
public boolean isCovered(List<TestCase> tests) { for (TestCase test : tests) { if (isCovered(test)) return true; } return false; }
boolean function(List<TestCase> tests) { for (TestCase test : tests) { if (isCovered(test)) return true; } return false; }
/** * Determine if there is an existing test case covering this goal * * @param tests * a {@link java.util.List} object. * @return a boolean. */
Determine if there is an existing test case covering this goal
isCovered
{ "repo_name": "claudejin/evosuite", "path": "client/src/main/java/org/evosuite/testcase/TestFitnessFunction.java", "license": "lgpl-3.0", "size": 5622 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,879,137
public synchronized void unregisterIndex( String index, String hostName, int port, AsyncMethodCallback<Void> resultHandler) { final String hostAndPortKey = hostName + port; StreamingClientServiceClient client = clientsByHostAndPort.get...
synchronized void function( String index, String hostName, int port, AsyncMethodCallback<Void> resultHandler) { final String hostAndPortKey = hostName + port; StreamingClientServiceClient client = clientsByHostAndPort.get(hostAndPortKey); if (client != null) { Set<String> indices = indicesByClient.get(client); indices....
/** * Unregisters a client from receiving a statistics stream * * @param index * Index of the statistics of the stream * @param hostName * Hostname of the client * @param port * Port number at which the StreamingServer at the client side is ...
Unregisters a client from receiving a statistics stream
unregisterIndex
{ "repo_name": "Completionary/completionProxy", "path": "src/main/java/de/completionary/proxy/analytics/StatisticsStreamDispatcher.java", "license": "gpl-2.0", "size": 10924 }
[ "de.completionary.proxy.thrift.clients.StreamingClientServiceClient", "java.util.Set", "org.apache.thrift.async.AsyncMethodCallback" ]
import de.completionary.proxy.thrift.clients.StreamingClientServiceClient; import java.util.Set; import org.apache.thrift.async.AsyncMethodCallback;
import de.completionary.proxy.thrift.clients.*; import java.util.*; import org.apache.thrift.async.*;
[ "de.completionary.proxy", "java.util", "org.apache.thrift" ]
de.completionary.proxy; java.util; org.apache.thrift;
1,100,483
private static double getZeroXOfControlPoligon(final NubSpline nubSpline) { final Iterator<PolarCP> iter = nubSpline.controlPoints.iterator(); // the CPs we are working with. PolarCP firstCP, secondCP; // Determines if one of the CPs is bigger than zero. boolean firstIsPositi...
static double function(final NubSpline nubSpline) { final Iterator<PolarCP> iter = nubSpline.controlPoints.iterator(); PolarCP firstCP, secondCP; boolean firstIsPositive, secondIsPositive; boolean firstIsNegative, secondIsNegative; double firstX = 0.0, secondX; secondCP = iter.next(); secondX = secondCP.getCp().x; seco...
/** * Returns a progression value (t) of the first zero (X-value) in the control polygon. If the polygon * starts at zero, this zero is ignored and the next zero is returned. If there is no zero found, * 0.0 is returned. * * @param nubSpline The NubSpline those zero of control polygon to calc...
Returns a progression value (t) of the first zero (X-value) in the control polygon. If the polygon starts at zero, this zero is ignored and the next zero is returned. If there is no zero found, 0.0 is returned
getZeroXOfControlPoligon
{ "repo_name": "ExplorViz/ExplorViz", "path": "src-external/de/cau/cs/kieler/klay/layered/p5edges/splines/NubSpline.java", "license": "apache-2.0", "size": 43267 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
474,288
@CheckForNull public DistributionRequestType getRequestType() { return get(PROPERTY_REQUEST_TYPE, DistributionRequestType.class); }
DistributionRequestType function() { return get(PROPERTY_REQUEST_TYPE, DistributionRequestType.class); }
/** * get the request type associated to the package holding this info * * @return the request type */
get the request type associated to the package holding this info
getRequestType
{ "repo_name": "plutext/sling", "path": "contrib/extensions/distribution/core/src/main/java/org/apache/sling/distribution/packaging/DistributionPackageInfo.java", "license": "apache-2.0", "size": 4091 }
[ "org.apache.sling.distribution.DistributionRequestType" ]
import org.apache.sling.distribution.DistributionRequestType;
import org.apache.sling.distribution.*;
[ "org.apache.sling" ]
org.apache.sling;
620,834
@MethodStats public AuthenticationContext authenticate(SignedJWTInfo signedJWTInfo, MessageContext synCtx) throws APISecurityException { String apiContext = (String) synCtx.getProperty(RESTConstants.REST_API_CONTEXT); String apiVersion = (String) synCtx.getProperty(RESTConstants.SYN...
AuthenticationContext function(SignedJWTInfo signedJWTInfo, MessageContext synCtx) throws APISecurityException { String apiContext = (String) synCtx.getProperty(RESTConstants.REST_API_CONTEXT); String apiVersion = (String) synCtx.getProperty(RESTConstants.SYNAPSE_REST_API_VERSION); org.apache.axis2.context.MessageConte...
/** * Authenticates the given request with a JWT token to see if an API consumer is allowed to access * a particular API or not. * * @param signedJWTInfo The JWT token sent with the API request * @param synCtx The message to be authenticated * @return an AuthenticationContext object whic...
Authenticates the given request with a JWT token to see if an API consumer is allowed to access a particular API or not
authenticate
{ "repo_name": "fazlan-nazeem/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.gateway/src/main/java/org/wso2/carbon/apimgt/gateway/handlers/security/jwt/JWTValidator.java", "license": "apache-2.0", "size": 32132 }
[ "javax.security.cert.X509Certificate", "org.apache.axis2.Constants", "org.apache.commons.lang.StringUtils", "org.apache.synapse.MessageContext", "org.apache.synapse.core.axis2.Axis2MessageContext", "org.apache.synapse.rest.RESTConstants", "org.wso2.carbon.apimgt.api.APIManagementException", "org.wso2....
import javax.security.cert.X509Certificate; import org.apache.axis2.Constants; import org.apache.commons.lang.StringUtils; import org.apache.synapse.MessageContext; import org.apache.synapse.core.axis2.Axis2MessageContext; import org.apache.synapse.rest.RESTConstants; import org.wso2.carbon.apimgt.api.APIManagementExce...
import javax.security.cert.*; import org.apache.axis2.*; import org.apache.commons.lang.*; import org.apache.synapse.*; import org.apache.synapse.core.axis2.*; import org.apache.synapse.rest.*; import org.wso2.carbon.apimgt.api.*; import org.wso2.carbon.apimgt.common.gateway.dto.*; import org.wso2.carbon.apimgt.gateway...
[ "javax.security", "org.apache.axis2", "org.apache.commons", "org.apache.synapse", "org.wso2.carbon" ]
javax.security; org.apache.axis2; org.apache.commons; org.apache.synapse; org.wso2.carbon;
1,860,669
@Test public void testDeleteKeys() throws Exception { Key key = makeKey("bird", "finch").build(); DeleteKeyFn deleteKeyFn = new DeleteKeyFn(); Mutation exceptedMutation = makeDelete(key).build(); assertEquals(deleteKeyFn.apply(key), exceptedMutation); }
void function() throws Exception { Key key = makeKey("bird", "finch").build(); DeleteKeyFn deleteKeyFn = new DeleteKeyFn(); Mutation exceptedMutation = makeDelete(key).build(); assertEquals(deleteKeyFn.apply(key), exceptedMutation); }
/** * Test that valid keys are transformed to delete mutations. */
Test that valid keys are transformed to delete mutations
testDeleteKeys
{ "repo_name": "amitsela/incubator-beam", "path": "sdks/java/io/google-cloud-platform/src/test/java/org/apache/beam/sdk/io/gcp/datastore/DatastoreV1Test.java", "license": "apache-2.0", "size": 40238 }
[ "com.google.datastore.v1.Key", "com.google.datastore.v1.Mutation", "com.google.datastore.v1.client.DatastoreHelper", "org.apache.beam.sdk.io.gcp.datastore.DatastoreV1", "org.junit.Assert" ]
import com.google.datastore.v1.Key; import com.google.datastore.v1.Mutation; import com.google.datastore.v1.client.DatastoreHelper; import org.apache.beam.sdk.io.gcp.datastore.DatastoreV1; import org.junit.Assert;
import com.google.datastore.v1.*; import com.google.datastore.v1.client.*; import org.apache.beam.sdk.io.gcp.datastore.*; import org.junit.*;
[ "com.google.datastore", "org.apache.beam", "org.junit" ]
com.google.datastore; org.apache.beam; org.junit;
634,633
@Test public void testInsertRepoFileAndFetchItAgain() { RepoFileMetaData newRepoFileMap = getNewIsoRepoFile(); repoFileMetaDataDao.addRepoFileMap(newRepoFileMap); List<RepoFileMetaData> listOfRepoFiles = repoFileMetaDataDao .getRepoListForStorageDomain(FixturesTool.STORA...
void function() { RepoFileMetaData newRepoFileMap = getNewIsoRepoFile(); repoFileMetaDataDao.addRepoFileMap(newRepoFileMap); List<RepoFileMetaData> listOfRepoFiles = repoFileMetaDataDao .getRepoListForStorageDomain(FixturesTool.STORAGE_DOAMIN_NFS_ISO, FileTypeExtension.ISO); assertNotNull(listOfRepoFiles); assertSame(t...
/** * Test when insert row and fetching it later. */
Test when insert row and fetching it later
testInsertRepoFileAndFetchItAgain
{ "repo_name": "derekhiggins/ovirt-engine", "path": "backend/manager/modules/dal/src/test/java/org/ovirt/engine/core/dao/RepoFileMetaDataDAOTest.java", "license": "apache-2.0", "size": 13014 }
[ "java.util.List", "org.junit.Assert", "org.ovirt.engine.core.common.businessentities.FileTypeExtension", "org.ovirt.engine.core.common.businessentities.RepoFileMetaData" ]
import java.util.List; import org.junit.Assert; import org.ovirt.engine.core.common.businessentities.FileTypeExtension; import org.ovirt.engine.core.common.businessentities.RepoFileMetaData;
import java.util.*; import org.junit.*; import org.ovirt.engine.core.common.businessentities.*;
[ "java.util", "org.junit", "org.ovirt.engine" ]
java.util; org.junit; org.ovirt.engine;
86,176
public void killTask(TaskAttemptID taskId) throws IOException { ensureState(JobState.RUNNING); info.killTask(org.apache.hadoop.mapred.TaskAttemptID.downgrade(taskId), false); }
void function(TaskAttemptID taskId) throws IOException { ensureState(JobState.RUNNING); info.killTask(org.apache.hadoop.mapred.TaskAttemptID.downgrade(taskId), false); }
/** * Kill indicated task attempt. * * @param taskId the id of the task to be terminated. * @throws IOException */
Kill indicated task attempt
killTask
{ "repo_name": "YuMatsuzawa/HadoopEclipseProject", "path": "src/mapred/org/apache/hadoop/mapreduce/Job.java", "license": "apache-2.0", "size": 18269 }
[ "java.io.IOException", "org.apache.hadoop.mapreduce.TaskAttemptID" ]
import java.io.IOException; import org.apache.hadoop.mapreduce.TaskAttemptID;
import java.io.*; import org.apache.hadoop.mapreduce.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
1,188,122
@Override public Response getAPIDocumentContentByDocumentId(String apiId, String documentId, String ifNoneMatch, MessageContext messageContext) { try { APIProvider apiProvider = RestApiCommonUtil.getLoggedInUserProvider(); ...
Response function(String apiId, String documentId, String ifNoneMatch, MessageContext messageContext) { try { APIProvider apiProvider = RestApiCommonUtil.getLoggedInUserProvider(); String tenantDomain = RestApiCommonUtil.getLoggedInUserTenantDomain(); DocumentationContent docContent = apiProvider.getDocumentationConten...
/** * Retrieves the content of a document * * @param apiId API identifier * @param documentId document identifier * @param ifNoneMatch If-None-Match header value * @return Content of the document/ either inline/file or source url as a redirection */
Retrieves the content of a document
getAPIDocumentContentByDocumentId
{ "repo_name": "Rajith90/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.rest.api.publisher.v1/src/main/java/org/wso2/carbon/apimgt/rest/api/publisher/v1/impl/ApisApiServiceImpl.java", "license": "apache-2.0", "size": 253126 }
[ "javax.ws.rs.core.Response", "org.apache.cxf.jaxrs.ext.MessageContext", "org.wso2.carbon.apimgt.api.APIProvider", "org.wso2.carbon.apimgt.api.model.DocumentationContent", "org.wso2.carbon.apimgt.rest.api.common.RestApiCommonUtil", "org.wso2.carbon.apimgt.rest.api.common.RestApiConstants", "org.wso2.carb...
import javax.ws.rs.core.Response; import org.apache.cxf.jaxrs.ext.MessageContext; import org.wso2.carbon.apimgt.api.APIProvider; import org.wso2.carbon.apimgt.api.model.DocumentationContent; import org.wso2.carbon.apimgt.rest.api.common.RestApiCommonUtil; import org.wso2.carbon.apimgt.rest.api.common.RestApiConstants; ...
import javax.ws.rs.core.*; import org.apache.cxf.jaxrs.ext.*; import org.wso2.carbon.apimgt.api.*; import org.wso2.carbon.apimgt.api.model.*; import org.wso2.carbon.apimgt.rest.api.common.*; import org.wso2.carbon.apimgt.rest.api.util.utils.*;
[ "javax.ws", "org.apache.cxf", "org.wso2.carbon" ]
javax.ws; org.apache.cxf; org.wso2.carbon;
1,753,098
public Transition inflateTransition(int resource) { XmlResourceParser parser = mContext.getResources().getXml(resource); try { return createTransitionFromXml(parser, Xml.asAttributeSet(parser), null); } catch (XmlPullParserException e) { throw new InflateException(e.g...
Transition function(int resource) { XmlResourceParser parser = mContext.getResources().getXml(resource); try { return createTransitionFromXml(parser, Xml.asAttributeSet(parser), null); } catch (XmlPullParserException e) { throw new InflateException(e.getMessage(), e); } catch (IOException e) { throw new InflateExceptio...
/** * Loads a {@link Transition} object from a resource * * @param resource The resource id of the transition to load * @return The loaded Transition object * @throws android.content.res.Resources.NotFoundException when the * transiti...
Loads a <code>Transition</code> object from a resource
inflateTransition
{ "repo_name": "AndroidX/androidx", "path": "transition/transition/src/main/java/androidx/transition/TransitionInflater.java", "license": "apache-2.0", "size": 14661 }
[ "android.content.res.XmlResourceParser", "android.util.Xml", "android.view.InflateException", "java.io.IOException", "org.xmlpull.v1.XmlPullParserException" ]
import android.content.res.XmlResourceParser; import android.util.Xml; import android.view.InflateException; import java.io.IOException; import org.xmlpull.v1.XmlPullParserException;
import android.content.res.*; import android.util.*; import android.view.*; import java.io.*; import org.xmlpull.v1.*;
[ "android.content", "android.util", "android.view", "java.io", "org.xmlpull.v1" ]
android.content; android.util; android.view; java.io; org.xmlpull.v1;
1,678,806
public void exitResetMode() throws IOException { inReset = false; if (clearMarkFlag ) { // If a flag was set to clear mark, do the reinit now. // See clearMark() reinitialize(); return; } if (!fileCache.isActive) { memCache.reinitialize(false); } }
void function() throws IOException { inReset = false; if (clearMarkFlag ) { reinitialize(); return; } if (!fileCache.isActive) { memCache.reinitialize(false); } }
/** * This function is called the ValuesIterator when a mark is called * outside of a reset zone. */
This function is called the ValuesIterator when a mark is called outside of a reset zone
exitResetMode
{ "repo_name": "dennishuo/hadoop", "path": "hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/BackupStore.java", "license": "apache-2.0", "size": 18966 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,285,960
public ArrayList<Block> createBlocks(int textStart, int textEnd, int minNode, int maxNode) { ArrayList<Block> blocks = new ArrayList<Block>(); int startNode = Math.max(getBlockStart(textStart), minNode); int endNode = Math.min(getBlockEnd(textEnd), maxNode); if (DEBUG) { debug("Creating block:...
ArrayList<Block> function(int textStart, int textEnd, int minNode, int maxNode) { ArrayList<Block> blocks = new ArrayList<Block>(); int startNode = Math.max(getBlockStart(textStart), minNode); int endNode = Math.min(getBlockEnd(textEnd), maxNode); if (DEBUG) { debug(STR + STR + textStart + "-" + textEnd + "\n" + STR + ...
/** * Creates a list of Blocks, given a text-range. * We may create multiple blocks if one single well-formed Block cannot be * created. * * @param textStart beginning plain-text offset * @param textEnd beginning plain-text offset * @param minNode the smallest node number * @param maxNode the la...
Creates a list of Blocks, given a text-range. We may create multiple blocks if one single well-formed Block cannot be created
createBlocks
{ "repo_name": "s20121035/rk3288_android5.1_repo", "path": "packages/apps/UnifiedEmail/src/com/google/android/mail/common/html/parser/HtmlTree.java", "license": "gpl-3.0", "size": 33618 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
595,614
private static String getPatternForCategory( String category ) { String pattern; if ( DesignChoiceConstants.STRING_FORMAT_TYPE_UPPERCASE.equals( category ) ) { pattern = ">"; //$NON-NLS-1$ } else if ( DesignChoiceConstants.STRING_FORMAT_TYPE_LOWERCASE.equals( category ) ) { pattern = "<"; //$NON-...
static String function( String category ) { String pattern; if ( DesignChoiceConstants.STRING_FORMAT_TYPE_UPPERCASE.equals( category ) ) { pattern = ">"; } else if ( DesignChoiceConstants.STRING_FORMAT_TYPE_LOWERCASE.equals( category ) ) { pattern = "<"; } else if ( DesignChoiceConstants.STRING_FORMAT_TYPE_ZIP_CODE.equ...
/** * Retrieves format pattern from arrays given format type categorys. * * @param category * Given format type category. * @return The corresponding format pattern string. */
Retrieves format pattern from arrays given format type categorys
getPatternForCategory
{ "repo_name": "sguan-actuate/birt", "path": "UI/org.eclipse.birt.report.designer.core/src/org/eclipse/birt/report/designer/util/FormatStringPattern.java", "license": "epl-1.0", "size": 3979 }
[ "org.eclipse.birt.report.designer.nls.Messages", "org.eclipse.birt.report.model.api.elements.DesignChoiceConstants" ]
import org.eclipse.birt.report.designer.nls.Messages; import org.eclipse.birt.report.model.api.elements.DesignChoiceConstants;
import org.eclipse.birt.report.designer.nls.*; import org.eclipse.birt.report.model.api.elements.*;
[ "org.eclipse.birt" ]
org.eclipse.birt;
1,546,100
public void processingInstruction(String target, String data) throws SAXException { if (m_firstTagNotEmitted) { flush(); } m_handler.processingInstruction(target, data); }
void function(String target, String data) throws SAXException { if (m_firstTagNotEmitted) { flush(); } m_handler.processingInstruction(target, data); }
/** * Pass the call on to the underlying handler * @see org.xml.sax.ContentHandler#processingInstruction(String, String) */
Pass the call on to the underlying handler
processingInstruction
{ "repo_name": "mirkosertic/Bytecoder", "path": "classlib/java.xml/src/main/resources/META-INF/modules/java.xml/classes/com/sun/org/apache/xml/internal/serializer/ToUnknownStream.java", "license": "apache-2.0", "size": 38096 }
[ "org.xml.sax.SAXException" ]
import org.xml.sax.SAXException;
import org.xml.sax.*;
[ "org.xml.sax" ]
org.xml.sax;
584,594
interface UpdateStages { interface WithTags { Update withTags(Map<String, String> tags); } }
interface UpdateStages { interface WithTags { Update withTags(Map<String, String> tags); } }
/** * Specifies the tags property: The resource tags.. * * @param tags The resource tags. * @return the next definition stage. */
Specifies the tags property: The resource tags.
withTags
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/delegatednetwork/azure-resourcemanager-delegatednetwork/src/main/java/com/azure/resourcemanager/delegatednetwork/models/DelegatedController.java", "license": "mit", "size": 6920 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,731,214
public void testOneDest(Connection conn, Session sess, Destination cons_dest, String prod_broker_url, String cons_broker_url, int num_msg) throws Exception { int echo_id; EchoService echo_svc; String echo_queue_name; Destination prod_dest; MessageProducer msg_prod; ...
void function(Connection conn, Session sess, Destination cons_dest, String prod_broker_url, String cons_broker_url, int num_msg) throws Exception { int echo_id; EchoService echo_svc; String echo_queue_name; Destination prod_dest; MessageProducer msg_prod; synchronized (this) { echo_id = this.nextEchoId; this.nextEchoId...
/** * Test one destination between the given "producer broker" and * "consumer broker" specified. */
Test one destination between the given "producer broker" and "consumer broker" specified
testOneDest
{ "repo_name": "ryanemerson/activemq-artemis", "path": "tests/activemq5-unit-tests/src/test/java/org/apache/activemq/bugs/AMQ3274Test.java", "license": "apache-2.0", "size": 23419 }
[ "javax.jms.Connection", "javax.jms.Destination", "javax.jms.MessageProducer", "javax.jms.Session" ]
import javax.jms.Connection; import javax.jms.Destination; import javax.jms.MessageProducer; import javax.jms.Session;
import javax.jms.*;
[ "javax.jms" ]
javax.jms;
149,292
public static <V, T> MutableMap<V, BigDecimal> sumByBigDecimal(Iterable<T> iterable, Function<T, V> groupBy, Function<? super T, BigDecimal> function) { if (iterable instanceof List) { return ListIterate.sumByBigDecimal((List<T>) iterable, groupBy, function); } if (it...
static <V, T> MutableMap<V, BigDecimal> function(Iterable<T> iterable, Function<T, V> groupBy, Function<? super T, BigDecimal> function) { if (iterable instanceof List) { return ListIterate.sumByBigDecimal((List<T>) iterable, groupBy, function); } if (iterable != null) { return IterableIterate.sumByBigDecimal(iterable,...
/** * Groups and sums the values of the iterable using the two specified functions. * * @since 6.0 */
Groups and sums the values of the iterable using the two specified functions
sumByBigDecimal
{ "repo_name": "bhav0904/eclipse-collections", "path": "eclipse-collections/src/main/java/org/eclipse/collections/impl/utility/Iterate.java", "license": "bsd-3-clause", "size": 139941 }
[ "java.math.BigDecimal", "java.util.List", "org.eclipse.collections.api.block.function.Function", "org.eclipse.collections.api.map.MutableMap", "org.eclipse.collections.impl.utility.internal.IterableIterate" ]
import java.math.BigDecimal; import java.util.List; import org.eclipse.collections.api.block.function.Function; import org.eclipse.collections.api.map.MutableMap; import org.eclipse.collections.impl.utility.internal.IterableIterate;
import java.math.*; import java.util.*; import org.eclipse.collections.api.block.function.*; import org.eclipse.collections.api.map.*; import org.eclipse.collections.impl.utility.internal.*;
[ "java.math", "java.util", "org.eclipse.collections" ]
java.math; java.util; org.eclipse.collections;
18,035
public Set<PlayerClientInfo> getPlayerList() { return playerList; }
Set<PlayerClientInfo> function() { return playerList; }
/** * Gets the list of players from the current server. * * @return List of players */
Gets the list of players from the current server
getPlayerList
{ "repo_name": "benruijl/WalledIn", "path": "src/main/java/walledin/game/network/client/Client.java", "license": "gpl-3.0", "size": 18543 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
331,435
@ServiceMethod(returns = ReturnType.SINGLE) private Mono<Void> deleteAsync(String resourceGroupName, String serviceName, String opid, String ifMatch) { return deleteWithResponseAsync(resourceGroupName, serviceName, opid, ifMatch) .flatMap((Response<Void> res) -> Mono.empty()); }
@ServiceMethod(returns = ReturnType.SINGLE) Mono<Void> function(String resourceGroupName, String serviceName, String opid, String ifMatch) { return deleteWithResponseAsync(resourceGroupName, serviceName, opid, ifMatch) .flatMap((Response<Void> res) -> Mono.empty()); }
/** * Deletes specific OpenID Connect Provider of the API Management service instance. * * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param opid Identifier of the OpenID Connect Provider. * @param ifMatch ETag of...
Deletes specific OpenID Connect Provider of the API Management service instance
deleteAsync
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/apimanagement/azure-resourcemanager-apimanagement/src/main/java/com/azure/resourcemanager/apimanagement/implementation/OpenIdConnectProvidersClientImpl.java", "license": "mit", "size": 80530 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.Response" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*;
[ "com.azure.core" ]
com.azure.core;
2,761,483
public static boolean equals(JRPropertiesMap p1, JRPropertiesMap p2) { // treating null and empty as the same if (p1 == null || !p1.hasProperties()) { return p2 == null || !p2.hasProperties(); } if (p2 == null || !p2.hasProperties()) { return false; } String[] names1 = p1.getPropertyName...
static boolean function(JRPropertiesMap p1, JRPropertiesMap p2) { if (p1 == null !p1.hasProperties()) { return p2 == null !p2.hasProperties(); } if (p2 == null !p2.hasProperties()) { return false; } String[] names1 = p1.getPropertyNames(); String[] names2 = p2.getPropertyNames(); if (names1.length != names2.length) { r...
/** * Determines whether two property sets are identical. * * @param p1 * @param p2 * @return whether the two property sets are identical */
Determines whether two property sets are identical
equals
{ "repo_name": "aleatorio12/ProVentasConnector", "path": "jasperreports-6.2.1-project/jasperreports-6.2.1/src/net/sf/jasperreports/engine/util/ObjectUtils.java", "license": "gpl-3.0", "size": 8191 }
[ "net.sf.jasperreports.engine.JRPropertiesMap" ]
import net.sf.jasperreports.engine.JRPropertiesMap;
import net.sf.jasperreports.engine.*;
[ "net.sf.jasperreports" ]
net.sf.jasperreports;
107,726
public static Bitmap rotateBitmapByDegree(Bitmap bm, int degree) { if(degree == 0 || degree == -1){ return bm; } Bitmap returnBm = null; // generate the matrix Matrix matrix = new Matrix(); matrix.postRotate(degree); try { returnBm = Bitmap.createBitmap(bm, 0, 0, bm.getWidth(), bm.getHeight(), m...
static Bitmap function(Bitmap bm, int degree) { if(degree == 0 degree == -1){ return bm; } Bitmap returnBm = null; Matrix matrix = new Matrix(); matrix.postRotate(degree); try { returnBm = Bitmap.createBitmap(bm, 0, 0, bm.getWidth(), bm.getHeight(), matrix, true); } catch (OutOfMemoryError e) { e.printStackTrace(); } i...
/** * rotate bitmap * * @param bm * @param degree * @return new bitmap which is rotate from bm */
rotate bitmap
rotateBitmapByDegree
{ "repo_name": "cowthan/AyoWeibo", "path": "ayoimageloader/src/main/java/org/ayo/imageloader/VanGogh.java", "license": "apache-2.0", "size": 5964 }
[ "android.graphics.Bitmap", "android.graphics.Matrix" ]
import android.graphics.Bitmap; import android.graphics.Matrix;
import android.graphics.*;
[ "android.graphics" ]
android.graphics;
1,671,368
@Bean @DependsOn("jobRepository") public JobLauncherWithAdditionalRestartCapabilities jobLauncher() { this.jobLauncher = new JobLauncherWithAdditionalRestartCapabilities(); try { this.jobLauncher.setJobRepository(this.jobRepository.getObject()); } catch (Exception e) { throw new...
@DependsOn(STR) JobLauncherWithAdditionalRestartCapabilities function() { this.jobLauncher = new JobLauncherWithAdditionalRestartCapabilities(); try { this.jobLauncher.setJobRepository(this.jobRepository.getObject()); } catch (Exception e) { throw new BeanCreationException(STR, e); } return this.jobLauncher; }
/** * This method is creating jobLauncher bean * * @return SimpleJobLauncher */
This method is creating jobLauncher bean
jobLauncher
{ "repo_name": "SimonHuber/oasp4j", "path": "samples/core/src/main/java/io/oasp/gastronomy/restaurant/general/configuration/BeansBatchConfig.java", "license": "apache-2.0", "size": 5711 }
[ "io.oasp.module.batch.common.impl.JobLauncherWithAdditionalRestartCapabilities", "org.springframework.beans.factory.BeanCreationException", "org.springframework.context.annotation.DependsOn" ]
import io.oasp.module.batch.common.impl.JobLauncherWithAdditionalRestartCapabilities; import org.springframework.beans.factory.BeanCreationException; import org.springframework.context.annotation.DependsOn;
import io.oasp.module.batch.common.impl.*; import org.springframework.beans.factory.*; import org.springframework.context.annotation.*;
[ "io.oasp.module", "org.springframework.beans", "org.springframework.context" ]
io.oasp.module; org.springframework.beans; org.springframework.context;
404,489
public void testGetTreatingPhysicianFullName() throws Exception{ studySubject.setOtherTreatingPhysician("Steven Chang"); assertEquals("Wrong other treating physician","Steven Chang",studySubject.getTreatingPhysicianFullName()); Investigator investigator = registerMockFor(Investigator.class); ...
void function() throws Exception{ studySubject.setOtherTreatingPhysician(STR); assertEquals(STR,STR,studySubject.getTreatingPhysicianFullName()); Investigator investigator = registerMockFor(Investigator.class); HealthcareSiteInvestigator healthcareSiteInvestigator = registerMockFor(HealthcareSiteInvestigator.class); he...
/** * Test get treating physician full name. * * @throws Exception the exception */
Test get treating physician full name
testGetTreatingPhysicianFullName
{ "repo_name": "NCIP/c3pr", "path": "codebase/projects/core/test/src/java/edu/duke/cabig/c3pr/domain/StudySubjectTest.java", "license": "bsd-3-clause", "size": 170087 }
[ "org.easymock.classextension.EasyMock" ]
import org.easymock.classextension.EasyMock;
import org.easymock.classextension.*;
[ "org.easymock.classextension" ]
org.easymock.classextension;
2,022,585
protected void invokeCustomInitMethod( String beanName, Object bean, String initMethodName, boolean enforceInitMethod) throws Throwable { Method initMethod = BeanUtils.findMethod(bean.getClass(), initMethodName, null); if (initMethod == null) { if (enforceInitMethod) { throw new NoSuchMethodException(...
void function( String beanName, Object bean, String initMethodName, boolean enforceInitMethod) throws Throwable { Method initMethod = BeanUtils.findMethod(bean.getClass(), initMethodName, null); if (initMethod == null) { if (enforceInitMethod) { throw new NoSuchMethodException(STR + initMethodName + STR + beanName + "'...
/** * Invoke the specified custom init method on the given bean. * Called by invokeInitMethods. * <p>Can be overridden in subclasses for custom resolution of init * methods with arguments. * @param beanName the bean name in the factory (for debugging purposes) * @param bean the new bean instance we may need...
Invoke the specified custom init method on the given bean. Called by invokeInitMethods. Can be overridden in subclasses for custom resolution of init methods with arguments
invokeCustomInitMethod
{ "repo_name": "cbeams-archive/spring-framework-2.5.x", "path": "src/org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.java", "license": "apache-2.0", "size": 59184 }
[ "java.lang.reflect.InvocationTargetException", "java.lang.reflect.Method", "org.springframework.beans.BeanUtils", "org.springframework.util.ReflectionUtils" ]
import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import org.springframework.beans.BeanUtils; import org.springframework.util.ReflectionUtils;
import java.lang.reflect.*; import org.springframework.beans.*; import org.springframework.util.*;
[ "java.lang", "org.springframework.beans", "org.springframework.util" ]
java.lang; org.springframework.beans; org.springframework.util;
647,886
public java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI> getSubterm_multisets_ScalarProductHLAPI(){ java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI> retour = new ArrayList<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI>(); for (Term elemnt : getSubt...
java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI> function(){ java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI> retour = new ArrayList<fr.lip6.move.pnml.hlpn.multisets.hlapi.ScalarProductHLAPI>(); for (Term elemnt : getSubterm()) { if(elemnt.getClass().equals(fr.lip6.move...
/** * This accessor return a list of encapsulated subelement, only of ScalarProductHLAPI kind. * WARNING : this method can creates a lot of new object in memory. */
This accessor return a list of encapsulated subelement, only of ScalarProductHLAPI kind. WARNING : this method can creates a lot of new object in memory
getSubterm_multisets_ScalarProductHLAPI
{ "repo_name": "lhillah/pnmlframework", "path": "pnmlFw-HLPN/src/fr/lip6/move/pnml/hlpn/lists/hlapi/SublistHLAPI.java", "license": "epl-1.0", "size": 111755 }
[ "fr.lip6.move.pnml.hlpn.terms.Term", "java.util.ArrayList", "java.util.List" ]
import fr.lip6.move.pnml.hlpn.terms.Term; import java.util.ArrayList; import java.util.List;
import fr.lip6.move.pnml.hlpn.terms.*; import java.util.*;
[ "fr.lip6.move", "java.util" ]
fr.lip6.move; java.util;
283,809
private void makeGithubSearchQuery() { String githubQuery = mSearchBoxEditText.getText().toString(); // TODO (17) If no search was entered, indicate that there isn't anything to search for and return if (githubQuery.isEmpty() || githubQuery == null) { return; } ...
void function() { String githubQuery = mSearchBoxEditText.getText().toString(); if (githubQuery.isEmpty() githubQuery == null) { return; } URL githubSearchUrl = NetworkUtils.buildUrl(githubQuery); mUrlDisplayTextView.setText(githubSearchUrl.toString()); Bundle queryBundle = new Bundle(); queryBundle.putString(SEARCH_QU...
/** * This method retrieves the search text from the EditText, constructs the * URL (using {@link NetworkUtils}) for the github repository you'd like to find, displays * that URL in a TextView, and finally request that an AsyncTaskLoader performs the GET request. */
This method retrieves the search text from the EditText, constructs the URL (using <code>NetworkUtils</code>) for the github repository you'd like to find, displays that URL in a TextView, and finally request that an AsyncTaskLoader performs the GET request
makeGithubSearchQuery
{ "repo_name": "jerrykuo7727/ud851-Exercises", "path": "Lesson05b-Smarter-GitHub-Repo-Search/T05b.02-Exercise-AddAsyncTaskLoader/app/src/main/java/com/example/android/asynctaskloader/MainActivity.java", "license": "apache-2.0", "size": 9309 }
[ "android.os.Bundle", "android.support.v4.app.LoaderManager", "android.support.v4.content.Loader", "com.example.android.asynctaskloader.utilities.NetworkUtils" ]
import android.os.Bundle; import android.support.v4.app.LoaderManager; import android.support.v4.content.Loader; import com.example.android.asynctaskloader.utilities.NetworkUtils;
import android.os.*; import android.support.v4.app.*; import android.support.v4.content.*; import com.example.android.asynctaskloader.utilities.*;
[ "android.os", "android.support", "com.example.android" ]
android.os; android.support; com.example.android;
2,907,809
UserAccount createFor(String username, String password, Person person, List<SimpleGrantedAuthority> authorities, boolean encrypted); /** * Searches for a user account * * @param username the user name * @return the account or an empty {@link Optional}
UserAccount createFor(String username, String password, Person person, List<SimpleGrantedAuthority> authorities, boolean encrypted); /** * Searches for a user account * * @param username the user name * @return the account or an empty {@link Optional}
/** * Creates a new user account for the given person * * @param username the person's username * @param password the person's password * @param person the person the account is created for * @param authorities the authorities the account should possess * @param encrypted whether the password is a...
Creates a new user account for the given person
createFor
{ "repo_name": "portux/NAJU-Adebar", "path": "src/main/java/de/naju/adebar/app/security/user/UserAccountManager.java", "license": "gpl-3.0", "size": 3454 }
[ "de.naju.adebar.model.human.Person", "java.util.List", "java.util.Optional", "org.springframework.security.core.authority.SimpleGrantedAuthority" ]
import de.naju.adebar.model.human.Person; import java.util.List; import java.util.Optional; import org.springframework.security.core.authority.SimpleGrantedAuthority;
import de.naju.adebar.model.human.*; import java.util.*; import org.springframework.security.core.authority.*;
[ "de.naju.adebar", "java.util", "org.springframework.security" ]
de.naju.adebar; java.util; org.springframework.security;
126,455
public boolean onKeyUp(int keyCode, KeyEvent event) { if (keyCode == KeyEvent.KEYCODE_BACK && mSlidingMenu.isMenuShowing()) { showContent(); return true; } return false; }
boolean function(int keyCode, KeyEvent event) { if (keyCode == KeyEvent.KEYCODE_BACK && mSlidingMenu.isMenuShowing()) { showContent(); return true; } return false; }
/** * On key up. * * @param keyCode the key code * @param event the event * @return true, if successful */
On key up
onKeyUp
{ "repo_name": "liangdas/showapp", "path": "SlidingMenuLib/src/com/slidingmenu/lib/app/SlidingActivityHelper.java", "license": "apache-2.0", "size": 6373 }
[ "android.view.KeyEvent" ]
import android.view.KeyEvent;
import android.view.*;
[ "android.view" ]
android.view;
2,353,162
public Optional<OperatorBackPressureStats> getOperatorBackPressureStats(ExecutionJobVertex vertex) { synchronized (lock) { final OperatorBackPressureStats stats = operatorStatsCache.getIfPresent(vertex); if (stats == null || backPressureStatsRefreshInterval <= System.currentTimeMillis() - stats.getEndTimesta...
Optional<OperatorBackPressureStats> function(ExecutionJobVertex vertex) { synchronized (lock) { final OperatorBackPressureStats stats = operatorStatsCache.getIfPresent(vertex); if (stats == null backPressureStatsRefreshInterval <= System.currentTimeMillis() - stats.getEndTimestamp()) { triggerBackPressureRequestInterna...
/** * Returns back pressure statistics for a operator. Automatically triggers task back pressure * sampling if statistics are not available or outdated. * * @param vertex Operator to get the stats for. * @return Back pressure statistics for an operator */
Returns back pressure statistics for a operator. Automatically triggers task back pressure sampling if statistics are not available or outdated
getOperatorBackPressureStats
{ "repo_name": "tzulitai/flink", "path": "flink-runtime/src/main/java/org/apache/flink/runtime/rest/handler/legacy/backpressure/BackPressureStatsTrackerImpl.java", "license": "apache-2.0", "size": 9120 }
[ "java.util.Optional", "org.apache.flink.runtime.executiongraph.ExecutionJobVertex" ]
import java.util.Optional; import org.apache.flink.runtime.executiongraph.ExecutionJobVertex;
import java.util.*; import org.apache.flink.runtime.executiongraph.*;
[ "java.util", "org.apache.flink" ]
java.util; org.apache.flink;
760,710
public List<Number> getDataValues() { if (dataColumn.getDataType() == DataTypes.Double) { return ((List<Number>) data); } else { List<Number> values = new ArrayList<>(); switch (dataColumn.getDataType()) { case Integer: f...
List<Number> function() { if (dataColumn.getDataType() == DataTypes.Double) { return ((List<Number>) data); } else { List<Number> values = new ArrayList<>(); switch (dataColumn.getDataType()) { case Integer: for (int v : (List<Integer>) data) { values.add(v); } break; case Float: for (Object v : (List<Object>) data) { ...
/** * Get number data list * * @return Number data list */
Get number data list
getDataValues
{ "repo_name": "meteoinfo/meteoinfolib", "path": "src/org/meteoinfo/table/ColumnData.java", "license": "lgpl-3.0", "size": 44765 }
[ "java.util.ArrayList", "java.util.Date", "java.util.List", "org.meteoinfo.data.DataTypes", "org.meteoinfo.global.util.DateUtil" ]
import java.util.ArrayList; import java.util.Date; import java.util.List; import org.meteoinfo.data.DataTypes; import org.meteoinfo.global.util.DateUtil;
import java.util.*; import org.meteoinfo.data.*; import org.meteoinfo.global.util.*;
[ "java.util", "org.meteoinfo.data", "org.meteoinfo.global" ]
java.util; org.meteoinfo.data; org.meteoinfo.global;
659,109
ApplicationDto application = createApplication(); LogSchemaDto logSchema = createLogSchema(application.getId()); FileData library = client.generateRecordStructureLibrary(application.getId(), logSchema.getMajorVersion()); Assert.assertNotNull(library); Assert.assertFalse(strIsEmpty(libra...
ApplicationDto application = createApplication(); LogSchemaDto logSchema = createLogSchema(application.getId()); FileData library = client.generateRecordStructureLibrary(application.getId(), logSchema.getMajorVersion()); Assert.assertNotNull(library); Assert.assertFalse(strIsEmpty(library.getFileName())); Assert.assert...
/** * Test generate record library. * * @throws TException the t exception * @throws IOException Signals that an I/O exception has occurred. */
Test generate record library
testGenerateRecordLibrary
{ "repo_name": "kallelzied/kaa", "path": "server/control/src/test/java/org/kaaproject/kaa/server/control/ControlServerRecordLibraryIT.java", "license": "apache-2.0", "size": 3086 }
[ "org.junit.Assert", "org.kaaproject.kaa.common.dto.ApplicationDto", "org.kaaproject.kaa.common.dto.logs.LogSchemaDto", "org.kaaproject.kaa.server.common.thrift.gen.control.FileData" ]
import org.junit.Assert; import org.kaaproject.kaa.common.dto.ApplicationDto; import org.kaaproject.kaa.common.dto.logs.LogSchemaDto; import org.kaaproject.kaa.server.common.thrift.gen.control.FileData;
import org.junit.*; import org.kaaproject.kaa.common.dto.*; import org.kaaproject.kaa.common.dto.logs.*; import org.kaaproject.kaa.server.common.thrift.gen.control.*;
[ "org.junit", "org.kaaproject.kaa" ]
org.junit; org.kaaproject.kaa;
465,097
@NonNull Set<String> getAvailableCameraIds();
Set<String> getAvailableCameraIds();
/** * Gets the ids of all available cameras. * * @return the list of available cameras */
Gets the ids of all available cameras
getAvailableCameraIds
{ "repo_name": "AndroidX/androidx", "path": "camera/camera-core/src/main/java/androidx/camera/core/impl/CameraFactory.java", "license": "apache-2.0", "size": 3147 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
2,415,598
public static ImageDescriptor getImageDescriptor(String path) { return imageDescriptorFromPlugin(PLUGIN_ID, path); } public ScriptingUIPlugin() { }
static ImageDescriptor function(String path) { return imageDescriptorFromPlugin(PLUGIN_ID, path); } public ScriptingUIPlugin() { }
/** * Returns an image descriptor for the image file at the given plug-in relative path * * @param path * the path * @return the image descriptor */
Returns an image descriptor for the image file at the given plug-in relative path
getImageDescriptor
{ "repo_name": "shakaran/studio3", "path": "plugins/com.aptana.scripting.ui/src/com/aptana/scripting/ui/ScriptingUIPlugin.java", "license": "gpl-3.0", "size": 3376 }
[ "org.eclipse.jface.resource.ImageDescriptor" ]
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.resource.*;
[ "org.eclipse.jface" ]
org.eclipse.jface;
57,493
@VisibleForTesting static void configureBlockSize( Table table, Configuration conf) throws IOException { StringBuilder blockSizeConfigValue = new StringBuilder(); HTableDescriptor tableDescriptor = table.getTableDescriptor(); if (tableDescriptor == null) { // could happen with mock table ins...
static void configureBlockSize( Table table, Configuration conf) throws IOException { StringBuilder blockSizeConfigValue = new StringBuilder(); HTableDescriptor tableDescriptor = table.getTableDescriptor(); if (tableDescriptor == null) { return; } Collection<HColumnDescriptor> families = tableDescriptor.getFamilies(); ...
/** * Serialize column family to block size map to configuration. * Invoked while configuring the MR job for incremental load. * * @param table to read the properties from * @param conf to persist serialized values into * @throws IOException * on failure to read column family descriptors ...
Serialize column family to block size map to configuration. Invoked while configuring the MR job for incremental load
configureBlockSize
{ "repo_name": "baishuo/hbase-1.0.0-cdh5.4.7_baishuo", "path": "hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/HFileOutputFormat2.java", "license": "apache-2.0", "size": 29732 }
[ "java.io.IOException", "java.net.URLEncoder", "java.util.Collection", "org.apache.hadoop.conf.Configuration", "org.apache.hadoop.hbase.HColumnDescriptor", "org.apache.hadoop.hbase.HTableDescriptor", "org.apache.hadoop.hbase.client.Table" ]
import java.io.IOException; import java.net.URLEncoder; import java.util.Collection; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.hbase.HColumnDescriptor; import org.apache.hadoop.hbase.HTableDescriptor; import org.apache.hadoop.hbase.client.Table;
import java.io.*; import java.net.*; import java.util.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.client.*;
[ "java.io", "java.net", "java.util", "org.apache.hadoop" ]
java.io; java.net; java.util; org.apache.hadoop;
1,596,595
@NonNull public LiveData<PreviewView.StreamState> getPreviewStreamState() { return mPreviewView.getPreviewStreamState(); }
LiveData<PreviewView.StreamState> function() { return mPreviewView.getPreviewStreamState(); }
/** * Gets the {@link LiveData} of the underlying {@link PreviewView}'s * {@link PreviewView.StreamState}. * * @return A {@link LiveData} containing the {@link PreviewView.StreamState}. Apps can either * get current value by {@link LiveData#getValue()} or register a observer by * {@link LiveData#obser...
Gets the <code>LiveData</code> of the underlying <code>PreviewView</code>'s <code>PreviewView.StreamState</code>
getPreviewStreamState
{ "repo_name": "WhisperSystems/TextSecure", "path": "app/src/main/java/androidx/camera/view/SignalCameraView.java", "license": "gpl-3.0", "size": 27646 }
[ "androidx.lifecycle.LiveData" ]
import androidx.lifecycle.LiveData;
import androidx.lifecycle.*;
[ "androidx.lifecycle" ]
androidx.lifecycle;
2,089,131
public java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI> getSubterm_multisets_CardinalityHLAPI(){ java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI> retour = new ArrayList<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI>(); for (Term elemnt : getSubterm()) {...
java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI> function(){ java.util.List<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI> retour = new ArrayList<fr.lip6.move.pnml.hlpn.multisets.hlapi.CardinalityHLAPI>(); for (Term elemnt : getSubterm()) { if(elemnt.getClass().equals(fr.lip6.move.pnml....
/** * This accessor return a list of encapsulated subelement, only of CardinalityHLAPI kind. * WARNING : this method can creates a lot of new object in memory. */
This accessor return a list of encapsulated subelement, only of CardinalityHLAPI kind. WARNING : this method can creates a lot of new object in memory
getSubterm_multisets_CardinalityHLAPI
{ "repo_name": "lhillah/pnmlframework", "path": "pnmlFw-HLPN/src/fr/lip6/move/pnml/hlpn/finiteIntRanges/hlapi/LessThanOrEqualHLAPI.java", "license": "epl-1.0", "size": 108879 }
[ "fr.lip6.move.pnml.hlpn.terms.Term", "java.util.ArrayList", "java.util.List" ]
import fr.lip6.move.pnml.hlpn.terms.Term; import java.util.ArrayList; import java.util.List;
import fr.lip6.move.pnml.hlpn.terms.*; import java.util.*;
[ "fr.lip6.move", "java.util" ]
fr.lip6.move; java.util;
914,902
public Path[] getSelectedRowUUIDs() { Set<T> selectedRows = selectionModel.getSelectedSet(); // Compatibility with existing API if ( selectedRows.size() == 0 ) { return null; } // Create the array of Paths Path[] uuids = new PathImpl[selectedRows.size()]...
Path[] function() { Set<T> selectedRows = selectionModel.getSelectedSet(); if ( selectedRows.size() == 0 ) { return null; } Path[] uuids = new PathImpl[selectedRows.size()]; int rowCount = 0; for (T row : selectedRows) { uuids[rowCount++] = row.getPath(); } return uuids; }
/** * Return an array of selected Paths. API is maintained for backwards * compatibility of legacy code with AssetItemGrid's implementation * * @return */
Return an array of selected Paths. API is maintained for backwards compatibility of legacy code with AssetItemGrid's implementation
getSelectedRowUUIDs
{ "repo_name": "psiroky/guvnor", "path": "guvnor-webapp-core/src/main/java/org/drools/guvnor/client/widgets/tables/AbstractAssetPagedTable.java", "license": "apache-2.0", "size": 10018 }
[ "java.util.Set", "org.drools.guvnor.client.rpc.Path", "org.drools.guvnor.client.rpc.PathImpl" ]
import java.util.Set; import org.drools.guvnor.client.rpc.Path; import org.drools.guvnor.client.rpc.PathImpl;
import java.util.*; import org.drools.guvnor.client.rpc.*;
[ "java.util", "org.drools.guvnor" ]
java.util; org.drools.guvnor;
2,728,288
private static void setMethodAccessible(Method method) { try { // // XXX Default access superclass workaround // // When a public class has a default access superclass // with public methods, these methods are accessible. // Calling the...
static void function(Method method) { try { } catch (SecurityException se) { if (!loggedAccessibleWarning) { boolean vulnerableJVM = false; try { String specVersion = System.getProperty(STR); if (specVersion.charAt(0) == '1' && (specVersion.charAt(2) == '0' specVersion.charAt(2) == '1' specVersion.charAt(2) == '2' spec...
/** * Try to make the method accessible * @param method The source arguments */
Try to make the method accessible
setMethodAccessible
{ "repo_name": "OpenSoftwareSolutions/PDFReporter", "path": "pdfreporter-extensions/src/org/oss/pdfreporter/uses/org/apache/commons/beanutils/MethodUtils.java", "license": "lgpl-3.0", "size": 50544 }
[ "java.lang.reflect.Method" ]
import java.lang.reflect.Method;
import java.lang.reflect.*;
[ "java.lang" ]
java.lang;
1,731,807
public LifecycleCallbackType<InterceptorType<T>> createPostConstruct() { return new LifecycleCallbackTypeImpl<InterceptorType<T>>(this, "post-construct", childNode); }
LifecycleCallbackType<InterceptorType<T>> function() { return new LifecycleCallbackTypeImpl<InterceptorType<T>>(this, STR, childNode); }
/** * Creates a new <code>post-construct</code> element * @return the new created instance of <code>LifecycleCallbackType<InterceptorType<T>></code> */
Creates a new <code>post-construct</code> element
createPostConstruct
{ "repo_name": "forge/javaee-descriptors", "path": "impl/src/main/java/org/jboss/shrinkwrap/descriptor/impl/ejbjar32/InterceptorTypeImpl.java", "license": "epl-1.0", "size": 60039 }
[ "org.jboss.shrinkwrap.descriptor.api.ejbjar32.InterceptorType", "org.jboss.shrinkwrap.descriptor.api.javaee7.LifecycleCallbackType", "org.jboss.shrinkwrap.descriptor.impl.javaee7.LifecycleCallbackTypeImpl" ]
import org.jboss.shrinkwrap.descriptor.api.ejbjar32.InterceptorType; import org.jboss.shrinkwrap.descriptor.api.javaee7.LifecycleCallbackType; import org.jboss.shrinkwrap.descriptor.impl.javaee7.LifecycleCallbackTypeImpl;
import org.jboss.shrinkwrap.descriptor.api.ejbjar32.*; import org.jboss.shrinkwrap.descriptor.api.javaee7.*; import org.jboss.shrinkwrap.descriptor.impl.javaee7.*;
[ "org.jboss.shrinkwrap" ]
org.jboss.shrinkwrap;
2,413,894
public interface OnClose extends Callback<ShardLock> { OnClose EMPTY = new OnClose() { @Override public void handle(ShardLock Lock) { } }; } private static class StoreStatsCache extends SingleObjectCache<StoreStats> { private final Di...
interface OnClose extends Callback<ShardLock> { OnClose EMPTY = new OnClose() { public void function(ShardLock Lock) { } }; } private static class StoreStatsCache extends SingleObjectCache<StoreStats> { private final Directory directory; public StoreStatsCache(TimeValue refreshInterval, Directory directory) throws IOEx...
/** * This method is called while the provided {@link org.elasticsearch.env.ShardLock} is held. * This method is only called once after all resources for a store are released. */
This method is called while the provided <code>org.elasticsearch.env.ShardLock</code> is held. This method is only called once after all resources for a store are released
handle
{ "repo_name": "yanjunh/elasticsearch", "path": "core/src/main/java/org/elasticsearch/index/store/Store.java", "license": "apache-2.0", "size": 64125 }
[ "java.io.IOException", "org.apache.lucene.store.Directory", "org.apache.lucene.store.Lock", "org.elasticsearch.common.unit.TimeValue", "org.elasticsearch.common.util.Callback", "org.elasticsearch.common.util.SingleObjectCache", "org.elasticsearch.env.ShardLock" ]
import java.io.IOException; import org.apache.lucene.store.Directory; import org.apache.lucene.store.Lock; import org.elasticsearch.common.unit.TimeValue; import org.elasticsearch.common.util.Callback; import org.elasticsearch.common.util.SingleObjectCache; import org.elasticsearch.env.ShardLock;
import java.io.*; import org.apache.lucene.store.*; import org.elasticsearch.common.unit.*; import org.elasticsearch.common.util.*; import org.elasticsearch.env.*;
[ "java.io", "org.apache.lucene", "org.elasticsearch.common", "org.elasticsearch.env" ]
java.io; org.apache.lucene; org.elasticsearch.common; org.elasticsearch.env;
2,364,023
public void updateItem(long identifier) { if (mDrawer != null && mAdapter != null && mItemAdapter.getAdapterItems() != null && identifier != -1) { IDrawerItem drawerItem = DrawerUtils.getDrawerItem(getDrawerItems(), identifier); for (int i = 0; i < mItemAdapter.getAdapterItems().size...
void function(long identifier) { if (mDrawer != null && mAdapter != null && mItemAdapter.getAdapterItems() != null && identifier != -1) { IDrawerItem drawerItem = DrawerUtils.getDrawerItem(getDrawerItems(), identifier); for (int i = 0; i < mItemAdapter.getAdapterItems().size(); i++) { if (mItemAdapter.getAdapterItems()...
/** * update a MiniDrawerItem (after updating the main Drawer) via its identifier * * @param identifier the identifier of the item which was updated */
update a MiniDrawerItem (after updating the main Drawer) via its identifier
updateItem
{ "repo_name": "natodemon/Lunary-Ethereum-Wallet", "path": "materialdrawer/src/main/java/com/mikepenz/materialdrawer/MiniDrawer.java", "license": "gpl-3.0", "size": 19246 }
[ "com.mikepenz.materialdrawer.model.interfaces.IDrawerItem" ]
import com.mikepenz.materialdrawer.model.interfaces.IDrawerItem;
import com.mikepenz.materialdrawer.model.interfaces.*;
[ "com.mikepenz.materialdrawer" ]
com.mikepenz.materialdrawer;
2,279,253
public void setForeColor(Color c) { LayoutNorthArrow.this.setForeColor(c); }
void function(Color c) { LayoutNorthArrow.this.setForeColor(c); }
/** * Set foreground color * * @param c Foreground color */
Set foreground color
setForeColor
{ "repo_name": "meteoinfo/meteoinfolib", "path": "src/org/meteoinfo/layout/LayoutNorthArrow.java", "license": "lgpl-3.0", "size": 12864 }
[ "java.awt.Color" ]
import java.awt.Color;
import java.awt.*;
[ "java.awt" ]
java.awt;
624,226
EAttribute getBeforeCode__Code_1();
EAttribute getBeforeCode__Code_1();
/** * Returns the meta object for the attribute '{@link cruise.umple.umple.BeforeCode_#getCode_1 <em>Code 1</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the attribute '<em>Code 1</em>'. * @see cruise.umple.umple.BeforeCode_#getCode_1() * @see #getBeforeCode_(...
Returns the meta object for the attribute '<code>cruise.umple.umple.BeforeCode_#getCode_1 Code 1</code>'.
getBeforeCode__Code_1
{ "repo_name": "ahmedvc/umple", "path": "cruise.umple.xtext/src-gen/cruise/umple/umple/UmplePackage.java", "license": "mit", "size": 485842 }
[ "org.eclipse.emf.ecore.EAttribute" ]
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
392,213
public static TransactionContent<String, Vault<BookableSection>, Set<Seat>> getSeatPrebookCancelContent(final HashSet<Seat> seats) { TransactionContent<String, Vault<BookableSection>, Set<Seat>> content = new TransactionContent<String, Vault<BookableSection>, Set<Seat>>() { /**/ private static final lon...
static TransactionContent<String, Vault<BookableSection>, Set<Seat>> function(final HashSet<Seat> seats) { TransactionContent<String, Vault<BookableSection>, Set<Seat>> content = new TransactionContent<String, Vault<BookableSection>, Set<Seat>>() { /**/ private static final long serialVersionUID = -5015419185790185115L...
/** * Get the {@link TransactionContent} for cancelling prebookings * @param sections The seats we wish to cancel * @return The generated transaction content */
Get the <code>TransactionContent</code> for cancelling prebookings
getSeatPrebookCancelContent
{ "repo_name": "balazspete/multi-hop-train-journey-booking", "path": "src/node/company/TransactionContentGenerator.java", "license": "mit", "size": 7143 }
[ "java.util.HashSet", "java.util.Set" ]
import java.util.HashSet; import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
2,279,759
public T caseAnnotation(Annotation object) { return null; }
T function(Annotation object) { return null; }
/** * Returns the result of interpreting the object as an instance of '<em>Annotation</em>'. * <!-- begin-user-doc --> * This implementation returns null; * returning a non-null result will terminate the switch. * <!-- end-user-doc --> * * @param object the target of the switch. * @retu...
Returns the result of interpreting the object as an instance of 'Annotation'. This implementation returns null; returning a non-null result will terminate the switch.
caseAnnotation
{ "repo_name": "sourcepit/common-modeling", "path": "gen/main/emf/org/sourcepit/common/modeling/util/CommonModelingSwitch.java", "license": "apache-2.0", "size": 10248 }
[ "org.sourcepit.common.modeling.Annotation" ]
import org.sourcepit.common.modeling.Annotation;
import org.sourcepit.common.modeling.*;
[ "org.sourcepit.common" ]
org.sourcepit.common;
2,176,317
String getAvailablekey() throws UnexplainableDatabaseServiceException;
String getAvailablekey() throws UnexplainableDatabaseServiceException;
/** * Get a brand new random available key. * @return */
Get a brand new random available key
getAvailablekey
{ "repo_name": "clement-elbaz/somedamnmusic", "path": "src/main/java/com/somedamnmusic/apis/DatabaseService.java", "license": "apache-2.0", "size": 1038 }
[ "com.somedamnmusic.database.UnexplainableDatabaseServiceException" ]
import com.somedamnmusic.database.UnexplainableDatabaseServiceException;
import com.somedamnmusic.database.*;
[ "com.somedamnmusic.database" ]
com.somedamnmusic.database;
1,652,274
public Map<String, Double> toNormalizedMap() { Map<String, Double> ret = this.normalizedResources.toNormalizedMap(); ret.put(Constants.COMMON_OFFHEAP_MEMORY_RESOURCE_NAME, offHeap); ret.put(Constants.COMMON_ONHEAP_MEMORY_RESOURCE_NAME, onHeap); return ret; }
Map<String, Double> function() { Map<String, Double> ret = this.normalizedResources.toNormalizedMap(); ret.put(Constants.COMMON_OFFHEAP_MEMORY_RESOURCE_NAME, offHeap); ret.put(Constants.COMMON_ONHEAP_MEMORY_RESOURCE_NAME, onHeap); return ret; }
/** * Convert to a map that is used by configuration and the UI. * @return a map with the key as the resource name and the value the resource amount. */
Convert to a map that is used by configuration and the UI
toNormalizedMap
{ "repo_name": "hmcl/storm-apache", "path": "storm-server/src/main/java/org/apache/storm/scheduler/resource/normalization/NormalizedResourceRequest.java", "license": "apache-2.0", "size": 11203 }
[ "java.util.Map", "org.apache.storm.Constants" ]
import java.util.Map; import org.apache.storm.Constants;
import java.util.*; import org.apache.storm.*;
[ "java.util", "org.apache.storm" ]
java.util; org.apache.storm;
2,074,477
@PublicEvolving public RestartStrategies.RestartStrategyConfiguration getRestartStrategy() { return config.getRestartStrategy(); }
RestartStrategies.RestartStrategyConfiguration function() { return config.getRestartStrategy(); }
/** * Returns the specified restart strategy configuration. * * @return The restart strategy configuration to be used */
Returns the specified restart strategy configuration
getRestartStrategy
{ "repo_name": "bowenli86/flink", "path": "flink-java/src/main/java/org/apache/flink/api/java/ExecutionEnvironment.java", "license": "apache-2.0", "size": 60087 }
[ "org.apache.flink.api.common.restartstrategy.RestartStrategies" ]
import org.apache.flink.api.common.restartstrategy.RestartStrategies;
import org.apache.flink.api.common.restartstrategy.*;
[ "org.apache.flink" ]
org.apache.flink;
1,116,149
public static Field[] getClassFields(Class<?> cls) { List<Field> fields = new ArrayList<Field>(); for (Class<?> c = cls; c != null; c = c.getSuperclass()) { fields.addAll(Arrays.asList(c.getDeclaredFields())); } return fields.toArray(new Field[fields.size()]); }
static Field[] function(Class<?> cls) { List<Field> fields = new ArrayList<Field>(); for (Class<?> c = cls; c != null; c = c.getSuperclass()) { fields.addAll(Arrays.asList(c.getDeclaredFields())); } return fields.toArray(new Field[fields.size()]); }
/** * Returns all fields declared in the specified class (including inherited). * * @param cls * the class which fields need to be returned. * @return the declared fields. */
Returns all fields declared in the specified class (including inherited)
getClassFields
{ "repo_name": "SHAF-WORK/shaf", "path": "core/src/main/java/org/shaf/core/util/ClassUtils.java", "license": "apache-2.0", "size": 21199 }
[ "java.lang.reflect.Field", "java.util.ArrayList", "java.util.Arrays", "java.util.List" ]
import java.lang.reflect.Field; import java.util.ArrayList; import java.util.Arrays; import java.util.List;
import java.lang.reflect.*; import java.util.*;
[ "java.lang", "java.util" ]
java.lang; java.util;
2,062,375
public List<RoleName> getRoles() { List<RoleName> roleNames = new ArrayList<RoleName>(); List<RuleTemplateAttributeBo> templateAttributes = getRuleTemplateAttributes(); for (RuleTemplateAttributeBo templateAttribute : templateAttributes) { if (!templateAttribute.isWorkflowAttribu...
List<RoleName> function() { List<RoleName> roleNames = new ArrayList<RoleName>(); List<RuleTemplateAttributeBo> templateAttributes = getRuleTemplateAttributes(); for (RuleTemplateAttributeBo templateAttribute : templateAttributes) { if (!templateAttribute.isWorkflowAttribute()) { continue; } roleNames.addAll(KEWService...
/** * Returns a List of Roles from all RoleAttributes attached to this template. * * @return list of roles */
Returns a List of Roles from all RoleAttributes attached to this template
getRoles
{ "repo_name": "bhutchinson/rice", "path": "rice-middleware/impl/src/main/java/org/kuali/rice/kew/rule/bo/RuleTemplateBo.java", "license": "apache-2.0", "size": 13080 }
[ "java.util.ArrayList", "java.util.List", "org.kuali.rice.kew.api.rule.RoleName", "org.kuali.rice.kew.service.KEWServiceLocator" ]
import java.util.ArrayList; import java.util.List; import org.kuali.rice.kew.api.rule.RoleName; import org.kuali.rice.kew.service.KEWServiceLocator;
import java.util.*; import org.kuali.rice.kew.api.rule.*; import org.kuali.rice.kew.service.*;
[ "java.util", "org.kuali.rice" ]
java.util; org.kuali.rice;
1,046,243
public MailText getMessage(Locale locale) { MailText texts = message.get(locale); if(texts==null) { texts = new MailText(); message.put(locale,texts); } return texts; }
MailText function(Locale locale) { MailText texts = message.get(locale); if(texts==null) { texts = new MailText(); message.put(locale,texts); } return texts; }
/** * Return message in specific language * (empty message if not present) * * @param locale language * @return the message */
Return message in specific language (empty message if not present)
getMessage
{ "repo_name": "zlamalp/perun", "path": "perun-base/src/main/java/cz/metacentrum/perun/registrar/model/ApplicationMail.java", "license": "bsd-2-clause", "size": 6440 }
[ "java.util.Locale" ]
import java.util.Locale;
import java.util.*;
[ "java.util" ]
java.util;
943,709
public static void writeFile(Pointer image, String fileName) throws NIVisionException { Pointer p = new Pointer(fileName.length() + 1); p.setString(0, fileName); setWriteFileAllowed(true); try { assertCleanStatus(imaqWriteFileFn.call3(image, p, 0)); //zero is unused color...
static void function(Pointer image, String fileName) throws NIVisionException { Pointer p = new Pointer(fileName.length() + 1); p.setString(0, fileName); setWriteFileAllowed(true); try { assertCleanStatus(imaqWriteFileFn.call3(image, p, 0)); } finally { p.free(); } }
/** * Write an image to the given file. * * Supported extensions: * .aipd or .apd AIPD * .bmp BMP * .jpg or .jpeg JPEG * .jp2 JPEG2000 * .png PNG * .tif or .tiff TIFF * * @param image The image to write to a file. * @param fileName The name of the destination ...
Write an image to the given file. Supported extensions: .aipd or .apd AIPD .bmp BMP .jpg or .jpeg JPEG .jp2 JPEG2000 .png PNG .tif or .tiff TIFF
writeFile
{ "repo_name": "1684Chimeras/2014Robot", "path": "2014CompetitionRobot/src/org/chimeras1684/year2014/vision/ARVision.java", "license": "mit", "size": 92379 }
[ "com.sun.cldc.jna.Pointer", "edu.wpi.first.wpilibj.image.NIVisionException" ]
import com.sun.cldc.jna.Pointer; import edu.wpi.first.wpilibj.image.NIVisionException;
import com.sun.cldc.jna.*; import edu.wpi.first.wpilibj.image.*;
[ "com.sun.cldc", "edu.wpi.first" ]
com.sun.cldc; edu.wpi.first;
1,315,267
public Object authenticate( Request request ) { for( AuthenticationHandler h : authenticationHandlers ) { if( h.supports( null, request ) ) { Object o = h.authenticate( null, request ); if( o == null ) { log.warn( "authentication failed by...
Object function( Request request ) { for( AuthenticationHandler h : authenticationHandlers ) { if( h.supports( null, request ) ) { Object o = h.authenticate( null, request ); if( o == null ) { log.warn( STR + h.getClass() ); } return o; } } if( request.getAuthorization() == null ) { if( log.isTraceEnabled() ) { log.tra...
/** * Looks for an AuthenticationHandler which supports the given resource and * authorization header, and then returns the result of that handler's * authenticate method. * * Returns null if no handlers support the request * * @param request * @return */
Looks for an AuthenticationHandler which supports the given resource and authorization header, and then returns the result of that handler's authenticate method. Returns null if no handlers support the request
authenticate
{ "repo_name": "skoulouzis/lobcder", "path": "milton2/milton-server-ce/src/main/java/io/milton/http/http11/auth/PreAuthenticationFilter.java", "license": "apache-2.0", "size": 5899 }
[ "io.milton.http.AuthenticationHandler", "io.milton.http.Request" ]
import io.milton.http.AuthenticationHandler; import io.milton.http.Request;
import io.milton.http.*;
[ "io.milton.http" ]
io.milton.http;
1,236,394
public GeneratedValue<T> strategy(String strategy) { childNode.attribute("strategy", strategy); return this; }
GeneratedValue<T> function(String strategy) { childNode.attribute(STR, strategy); return this; }
/** * Sets the <code>strategy</code> attribute * @param strategy the value for the attribute <code>strategy</code> * @return the current instance of <code>GeneratedValue<T></code> */
Sets the <code>strategy</code> attribute
strategy
{ "repo_name": "forge/javaee-descriptors", "path": "impl/src/main/java/org/jboss/shrinkwrap/descriptor/impl/orm10/GeneratedValueImpl.java", "license": "epl-1.0", "size": 4454 }
[ "org.jboss.shrinkwrap.descriptor.api.orm10.GeneratedValue" ]
import org.jboss.shrinkwrap.descriptor.api.orm10.GeneratedValue;
import org.jboss.shrinkwrap.descriptor.api.orm10.*;
[ "org.jboss.shrinkwrap" ]
org.jboss.shrinkwrap;
1,800,650
private void hideNativeScrollbars() { m_nativeScrollbarWidth = AbstractNativeScrollbar.getNativeScrollbarWidth(); getScrollableElement().getStyle().setMarginRight(-(m_nativeScrollbarWidth + 10), Unit.PX); }
void function() { m_nativeScrollbarWidth = AbstractNativeScrollbar.getNativeScrollbarWidth(); getScrollableElement().getStyle().setMarginRight(-(m_nativeScrollbarWidth + 10), Unit.PX); }
/** * Hide the native scrollbars. We call this after attaching to ensure that we * inherit the direction (rtl or ltr). */
Hide the native scrollbars. We call this after attaching to ensure that we inherit the direction (rtl or ltr)
hideNativeScrollbars
{ "repo_name": "it-tavis/opencms-core", "path": "src-gwt/org/opencms/gwt/client/ui/CmsScrollPanelImpl.java", "license": "lgpl-2.1", "size": 15710 }
[ "com.google.gwt.dom.client.Style", "com.google.gwt.user.client.ui.AbstractNativeScrollbar" ]
import com.google.gwt.dom.client.Style; import com.google.gwt.user.client.ui.AbstractNativeScrollbar;
import com.google.gwt.dom.client.*; import com.google.gwt.user.client.ui.*;
[ "com.google.gwt" ]
com.google.gwt;
1,375,588
private NativeObject onLabelPointStyleCallback(NativeObject item) { // gets callback TooltipLabelCallback callback = getLabelCallback(); // gets the items TooltipItem tooltipItem = TooltipItem.FACTORY.create(item); // checks if callback is consistent if (callback != null) { // invokes callback Tool...
NativeObject function(NativeObject item) { TooltipLabelCallback callback = getLabelCallback(); TooltipItem tooltipItem = TooltipItem.FACTORY.create(item); if (callback != null) { TooltipLabelPointStyle result = callback.onLabelPointStyle(getChart(), tooltipItem); if (result != null) { return result.getObject(); } } Too...
/** * Manage the LABEL callback invocation * * @param item tooltip item * @return label color object to apply to tooltip item */
Manage the LABEL callback invocation
onLabelPointStyleCallback
{ "repo_name": "pepstock-org/Charba", "path": "src/org/pepstock/charba/client/configuration/TooltipsCallbacks.java", "license": "apache-2.0", "size": 22247 }
[ "org.pepstock.charba.client.Defaults", "org.pepstock.charba.client.callbacks.TooltipLabelCallback", "org.pepstock.charba.client.commons.NativeObject", "org.pepstock.charba.client.items.TooltipItem", "org.pepstock.charba.client.items.TooltipLabelPointStyle" ]
import org.pepstock.charba.client.Defaults; import org.pepstock.charba.client.callbacks.TooltipLabelCallback; import org.pepstock.charba.client.commons.NativeObject; import org.pepstock.charba.client.items.TooltipItem; import org.pepstock.charba.client.items.TooltipLabelPointStyle;
import org.pepstock.charba.client.*; import org.pepstock.charba.client.callbacks.*; import org.pepstock.charba.client.commons.*; import org.pepstock.charba.client.items.*;
[ "org.pepstock.charba" ]
org.pepstock.charba;
2,271,189
protected void update() { synchronized (taskTrackerManager) { synchronized (this) { ClusterStatus clusterStatus = taskTrackerManager.getClusterStatus(); // Recompute locality delay from JobTracker heartbeat interval if enabled. // This will also lock the JT, so do it outside of a fa...
void function() { synchronized (taskTrackerManager) { synchronized (this) { ClusterStatus clusterStatus = taskTrackerManager.getClusterStatus(); if (autoComputeLocalityDelay) { JobTracker jobTracker = (JobTracker) taskTrackerManager; localityDelay = Math.min(MAX_AUTOCOMPUTED_LOCALITY_DELAY, (long) (1.5 * jobTracker.get...
/** * Recompute the internal variables used by the scheduler - per-job weights, * fair shares, deficits, minimum slot allocations, and numbers of running * and needed tasks of each type. */
Recompute the internal variables used by the scheduler - per-job weights, fair shares, deficits, minimum slot allocations, and numbers of running and needed tasks of each type
update
{ "repo_name": "InMobi/hadoop", "path": "src/contrib/fairscheduler/src/java/org/apache/hadoop/mapred/FairScheduler.java", "license": "apache-2.0", "size": 40286 }
[ "java.util.ArrayList", "java.util.List", "org.apache.hadoop.mapreduce.TaskType" ]
import java.util.ArrayList; import java.util.List; import org.apache.hadoop.mapreduce.TaskType;
import java.util.*; import org.apache.hadoop.mapreduce.*;
[ "java.util", "org.apache.hadoop" ]
java.util; org.apache.hadoop;
2,625,323
public void flush() throws IOException { }
void function() throws IOException { }
/** * Flush blob; dummy to satisfy OutputStream class. */
Flush blob; dummy to satisfy OutputStream class
flush
{ "repo_name": "hyc/BerkeleyDB", "path": "lang/sql/jdbc/SQLite/Blob.java", "license": "agpl-3.0", "size": 5973 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,599,840
public void stopMusicPlayer() { if (player == null) return; player.stop(); player.release(); player = null; Log.w(TAG, "stopMusicPlayer"); }
void function() { if (player == null) return; player.stop(); player.release(); player = null; Log.w(TAG, STR); }
/** * Cleans resources from Android's native MediaPlayer. * * @note According to the MediaPlayer guide, you should release * the MediaPlayer as often as possible. * For example, when losing Audio Focus for an extended * period of time. */
Cleans resources from Android's native MediaPlayer
stopMusicPlayer
{ "repo_name": "alexdantas/kure-music-player", "path": "app/src/main/java/com/kure/musicplayer/services/ServicePlayMusic.java", "license": "gpl-3.0", "size": 34886 }
[ "android.util.Log" ]
import android.util.Log;
import android.util.*;
[ "android.util" ]
android.util;
2,878,791
private static void autodetectProcessor( CSVColumnConf csvConf, Class<?> type, String prefix ) { if( String.class.isAssignableFrom(type) ) return; final CSVFieldProcessorConf processor = new CSVFieldProcessorConf(); final CSVFieldConverterConf converter = new CSVFieldCo...
static void function( CSVColumnConf csvConf, Class<?> type, String prefix ) { if( String.class.isAssignableFrom(type) ) return; final CSVFieldProcessorConf processor = new CSVFieldProcessorConf(); final CSVFieldConverterConf converter = new CSVFieldConverterConf(); if( Enum.class.isAssignableFrom(type) ) { converter.se...
/** * Tries to detect the processor that fits the given property type. * If the given type is an instance of one of the registered types * it creates the related processor. * * @param csvConf configuration to populate. * @param type type to use for auto detection. * @param prefix...
Tries to detect the processor that fits the given property type. If the given type is an instance of one of the registered types it creates the related processor
autodetectProcessor
{ "repo_name": "nerd4j/nerd4j-csv", "path": "src/main/java/org/nerd4j/csv/conf/mapping/ann/AnnotatedConfigurationFactory.java", "license": "lgpl-3.0", "size": 24697 }
[ "org.nerd4j.csv.conf.mapping.CSVColumnConf", "org.nerd4j.csv.conf.mapping.CSVFieldConverterConf", "org.nerd4j.csv.conf.mapping.CSVFieldProcessorConf" ]
import org.nerd4j.csv.conf.mapping.CSVColumnConf; import org.nerd4j.csv.conf.mapping.CSVFieldConverterConf; import org.nerd4j.csv.conf.mapping.CSVFieldProcessorConf;
import org.nerd4j.csv.conf.mapping.*;
[ "org.nerd4j.csv" ]
org.nerd4j.csv;
2,501,922
@Test public void whenInvokeDoFilterThenInvokeGetSessionAndChainDoFilter() throws IOException, ServletException { AuthFilter filter = new AuthFilter(); HttpServletRequest req = mock(HttpServletRequest.class); HttpServletResponse resp = mock(HttpServletResponse.class); FilterChain...
void function() throws IOException, ServletException { AuthFilter filter = new AuthFilter(); HttpServletRequest req = mock(HttpServletRequest.class); HttpServletResponse resp = mock(HttpServletResponse.class); FilterChain chain = mock(FilterChain.class); HttpSession session = mock(HttpSession.class); String login = "lo...
/** * Test doFilter(ServletRequest, ServletResponse, FilterChain) method. * @throws IOException - IOException. * @throws ServletException - ServletException. */
Test doFilter(ServletRequest, ServletResponse, FilterChain) method
whenInvokeDoFilterThenInvokeGetSessionAndChainDoFilter
{ "repo_name": "MironovVadim/vmironov", "path": "chapter_009/src/test/java/ru/job4j/servlets/AuthFilterTest.java", "license": "apache-2.0", "size": 3533 }
[ "java.io.IOException", "javax.servlet.FilterChain", "javax.servlet.ServletException", "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse", "javax.servlet.http.HttpSession", "org.mockito.Mockito" ]
import java.io.IOException; import javax.servlet.FilterChain; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; import org.mockito.Mockito;
import java.io.*; import javax.servlet.*; import javax.servlet.http.*; import org.mockito.*;
[ "java.io", "javax.servlet", "org.mockito" ]
java.io; javax.servlet; org.mockito;
590,387
private TradingDayPrices[] createIncreasingPrices() { final LocalDate[] dates = { LocalDate.of(2017, 9, 18), LocalDate.of(2017, 9, 19), LocalDate.of(2017, 9, 20), LocalDate.of(2017, 9, 21), LocalDate.of(2017, 9, 22), LocalDate.of(2017, 9, 25), LocalDate.of(2017, 9, 26), LocalDate.of(2017, 9, 2...
TradingDayPrices[] function() { final LocalDate[] dates = { LocalDate.of(2017, 9, 18), LocalDate.of(2017, 9, 19), LocalDate.of(2017, 9, 20), LocalDate.of(2017, 9, 21), LocalDate.of(2017, 9, 22), LocalDate.of(2017, 9, 25), LocalDate.of(2017, 9, 26), LocalDate.of(2017, 9, 27), LocalDate.of(2017, 9, 28), LocalDate.of(2017...
/** * Ten closing prices that start increasing after the forth entry, starting at * LocalDate.of(2017, 9, 18). */
Ten closing prices that start increasing after the forth entry, starting at LocalDate.of(2017, 9, 18)
createIncreasingPrices
{ "repo_name": "CjHare/systematic-trading", "path": "systematic-trading-maths/src/test/java/com/systematic/trading/maths/indicator/rs/ClosingPriceRelativeStrengthCalculatorTest.java", "license": "mit", "size": 13772 }
[ "com.systematic.trading.model.price.TradingDayPrices", "java.time.LocalDate" ]
import com.systematic.trading.model.price.TradingDayPrices; import java.time.LocalDate;
import com.systematic.trading.model.price.*; import java.time.*;
[ "com.systematic.trading", "java.time" ]
com.systematic.trading; java.time;
336,057
public static CamelExecutionException wrapCamelExecutionException(Exchange exchange, Throwable e) { if (e instanceof CamelExecutionException) { // don't double wrap return (CamelExecutionException)e; } else { return new CamelExecutionException("Exception occurred ...
static CamelExecutionException function(Exchange exchange, Throwable e) { if (e instanceof CamelExecutionException) { return (CamelExecutionException)e; } else { return new CamelExecutionException(STR, exchange, e); } }
/** * Wraps the caused exception in a {@link CamelExecutionException} if its not * already such an exception. * * @param e the caused exception * @return the wrapper exception */
Wraps the caused exception in a <code>CamelExecutionException</code> if its not already such an exception
wrapCamelExecutionException
{ "repo_name": "jonmcewen/camel", "path": "camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java", "license": "apache-2.0", "size": 79778 }
[ "org.apache.camel.CamelExecutionException", "org.apache.camel.Exchange" ]
import org.apache.camel.CamelExecutionException; import org.apache.camel.Exchange;
import org.apache.camel.*;
[ "org.apache.camel" ]
org.apache.camel;
1,080,822
public static void reduceArrivalRateListNoise(List<ArrivalRateTuple> arrivalRates, double period) { ExtractionDataContainer reductionContainer = new ExtractionDataContainer(arrivalRates, period, 0, null, null, null); reduceArrivalRateListNoise(reductionContainer, true); }
static void function(List<ArrivalRateTuple> arrivalRates, double period) { ExtractionDataContainer reductionContainer = new ExtractionDataContainer(arrivalRates, period, 0, null, null, null); reduceArrivalRateListNoise(reductionContainer, true); }
/** * Reduces noise of a given arrival rate list with an expected seasonal period. * @param arrivalRates The arrival rates for which to reduce noise. * @param period Seasonal period within the arrival rate list. */
Reduces noise of a given arrival rate list with an expected seasonal period
reduceArrivalRateListNoise
{ "repo_name": "joakimkistowski/LIMBO", "path": "dlim.generator/src/tools/descartes/dlim/extractor/ModelExtractor.java", "license": "epl-1.0", "size": 25846 }
[ "java.util.List", "tools.descartes.dlim.extractor.utils.ExtractionDataContainer", "tools.descartes.dlim.generator.ArrivalRateTuple" ]
import java.util.List; import tools.descartes.dlim.extractor.utils.ExtractionDataContainer; import tools.descartes.dlim.generator.ArrivalRateTuple;
import java.util.*; import tools.descartes.dlim.extractor.utils.*; import tools.descartes.dlim.generator.*;
[ "java.util", "tools.descartes.dlim" ]
java.util; tools.descartes.dlim;
1,882,516
public Participant getParticipant ( String root ) { return service_.getParticipant ( root ); }
Participant function ( String root ) { return service_.getParticipant ( root ); }
/** * Get the participant for the given root. Needed for recovery of JCA * inbound transactions. * * @param root * @return The participant. */
Get the participant for the given root. Needed for recovery of JCA inbound transactions
getParticipant
{ "repo_name": "hmalphettes/atomikos-essentials-3.5.8-osgified-sandbox", "path": "com.atomikos.transactions/src/com/atomikos/icatch/imp/BaseTransactionManager.java", "license": "apache-2.0", "size": 15492 }
[ "com.atomikos.icatch.Participant" ]
import com.atomikos.icatch.Participant;
import com.atomikos.icatch.*;
[ "com.atomikos.icatch" ]
com.atomikos.icatch;
1,689,250
protected void removeServices(final OperationContext context, final ServiceName parentService, final ModelNode parentModel) throws OperationFailedException { context.removeService(parentService); }
void function(final OperationContext context, final ServiceName parentService, final ModelNode parentModel) throws OperationFailedException { context.removeService(parentService); }
/** * Removes services. This default implementation simply * {@link OperationContext#removeService(ServiceController) instructs the context to remove the parentService}. * Subclasses could use the provided {@code parentModel} to identify and remove other services. * * @param context the operati...
Removes services. This default implementation simply <code>OperationContext#removeService(ServiceController) instructs the context to remove the parentService</code>. Subclasses could use the provided parentModel to identify and remove other services
removeServices
{ "repo_name": "jamezp/wildfly-core", "path": "controller/src/main/java/org/jboss/as/controller/RestartParentResourceHandlerBase.java", "license": "lgpl-2.1", "size": 9803 }
[ "org.jboss.dmr.ModelNode", "org.jboss.msc.service.ServiceName" ]
import org.jboss.dmr.ModelNode; import org.jboss.msc.service.ServiceName;
import org.jboss.dmr.*; import org.jboss.msc.service.*;
[ "org.jboss.dmr", "org.jboss.msc" ]
org.jboss.dmr; org.jboss.msc;
1,362,320
private int getEndIndentations(Region prevLine, Region line, Region nextLine) { int compareToPrevLineEnd = compareLinePositions(prevLine, line, true); int compareToNextLineEnd = compareLinePositions(line, nextLine, true); int comparePrevToNextLineEnd = compareLinePositions(prevLine, nextLine, ...
int function(Region prevLine, Region line, Region nextLine) { int compareToPrevLineEnd = compareLinePositions(prevLine, line, true); int compareToNextLineEnd = compareLinePositions(line, nextLine, true); int comparePrevToNextLineEnd = compareLinePositions(prevLine, nextLine, true); if (compareToPrevLineEnd == 0 && comp...
/** * Compares the end indentations of three line. The return value have to be * considered as binary value. If the return value is 6 = 110, the previous * and the current line are intended (but not the next line). * * @param prevLine * the previous line. * @param line * the l...
Compares the end indentations of three line. The return value have to be considered as binary value. If the return value is 6 = 110, the previous and the current line are intended (but not the next line)
getEndIndentations
{ "repo_name": "ckorzen/icecite", "path": "pdf-machine/src/main/java/de/freiburg/iif/extraction/references/ReferencesMetadataMatcher.java", "license": "apache-2.0", "size": 55410 }
[ "de.freiburg.iif.model.Region" ]
import de.freiburg.iif.model.Region;
import de.freiburg.iif.model.*;
[ "de.freiburg.iif" ]
de.freiburg.iif;
2,900,781
public final synchronized void requestCompleted(final HttpContext context) { if (this.completed) { return; } this.completed = true; try { this.result = buildResult(context); } catch (final Exception ex) { this.ex = ex; } fi...
final synchronized void function(final HttpContext context) { if (this.completed) { return; } this.completed = true; try { this.result = buildResult(context); } catch (final Exception ex) { this.ex = ex; } finally { releaseResources(); } }
/** * Use {@link #buildResult(HttpContext)} instead. */
Use <code>#buildResult(HttpContext)</code> instead
requestCompleted
{ "repo_name": "vuzzan/openclinic", "path": "src/org/apache/http/nio/protocol/AbstractAsyncRequestConsumer.java", "license": "apache-2.0", "size": 6599 }
[ "org.apache.http.protocol.HttpContext" ]
import org.apache.http.protocol.HttpContext;
import org.apache.http.protocol.*;
[ "org.apache.http" ]
org.apache.http;
1,130,819
void invoke(ClientType clientType) { try { LOGGER.info("Starting service."); ExecutorService service = ClientServiceFactory.startClientService(_system, clientType, _jobCounter); LOGGER.info("Service started."); Thread currentThread = Thread.currentThread();...
void invoke(ClientType clientType) { try { LOGGER.info(STR); ExecutorService service = ClientServiceFactory.startClientService(_system, clientType, _jobCounter); LOGGER.info(STR); Thread currentThread = Thread.currentThread(); while (!currentThread.isInterrupted()) { try { Thread.sleep(500); } catch (InterruptedExcepti...
/** * This method creates multiple threads to dequeue messages from message queue and push into TSDB. One thread is created for every type. Depending on * message queue connection count, multiple threads may be created for Metric type * * @param clientType The type of client to invoke. * ...
This method creates multiple threads to dequeue messages from message queue and push into TSDB. One thread is created for every type. Depending on message queue connection count, multiple threads may be created for Metric type
invoke
{ "repo_name": "SalesforceEng/Argus", "path": "ArgusClient/src/main/java/com/salesforce/dva/argus/client/Main.java", "license": "bsd-3-clause", "size": 10947 }
[ "com.salesforce.dva.argus.system.SystemException", "java.util.concurrent.ExecutorService", "java.util.concurrent.TimeUnit" ]
import com.salesforce.dva.argus.system.SystemException; import java.util.concurrent.ExecutorService; import java.util.concurrent.TimeUnit;
import com.salesforce.dva.argus.system.*; import java.util.concurrent.*;
[ "com.salesforce.dva", "java.util" ]
com.salesforce.dva; java.util;
660,580