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
public static RuntimeCamelException wrapRuntimeCamelException(Throwable e) { if (e instanceof RuntimeCamelException) { // don't double wrap return (RuntimeCamelException)e; } else { return new RuntimeCamelException(e); } }
static RuntimeCamelException function(Throwable e) { if (e instanceof RuntimeCamelException) { return (RuntimeCamelException)e; } else { return new RuntimeCamelException(e); } }
/** * Wraps the caused exception in a {@link RuntimeCamelException} if its not * already such an exception. * * @param e the caused exception * @return the wrapper exception */
Wraps the caused exception in a <code>RuntimeCamelException</code> if its not already such an exception
wrapRuntimeCamelException
{ "repo_name": "onders86/camel", "path": "camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java", "license": "apache-2.0", "size": 79581 }
[ "org.apache.camel.RuntimeCamelException" ]
import org.apache.camel.RuntimeCamelException;
import org.apache.camel.*;
[ "org.apache.camel" ]
org.apache.camel;
2,615,928
public Level getLogLevel();
Level function();
/** * The current log level. Default is {@link Level#INFO}. Be sure to log everything in your * implementation regardless of the log level, as the filtering on the selected log level is * done automatically by the {@link LogViewer}. * * @return the log level */
The current log level. Default is <code>Level#INFO</code>. Be sure to log everything in your implementation regardless of the log level, as the filtering on the selected log level is done automatically by the <code>LogViewer</code>
getLogLevel
{ "repo_name": "transwarpio/rapidminer", "path": "rapidMiner/rapidminer-studio-core/src/main/java/com/rapidminer/gui/tools/logging/LogModel.java", "license": "gpl-3.0", "size": 4742 }
[ "java.util.logging.Level" ]
import java.util.logging.Level;
import java.util.logging.*;
[ "java.util" ]
java.util;
1,436,530
private InetAddress getHostAddress() { if (__activeExternalHost != null) { return __activeExternalHost; } else { // default local address return getLocalAddress(); } }
InetAddress function() { if (__activeExternalHost != null) { return __activeExternalHost; } else { return getLocalAddress(); } }
/** * Get the host address for active mode; allows the local address to be overridden. * * @return __activeExternalHost if non-null, else getLocalAddress() * @see #setActiveExternalIPAddress(String) */
Get the host address for active mode; allows the local address to be overridden
getHostAddress
{ "repo_name": "AriaLyy/DownloadUtil", "path": "AriaFtpPlug/src/main/java/aria/apache/commons/net/ftp/FTPClient.java", "license": "apache-2.0", "size": 152886 }
[ "java.net.InetAddress" ]
import java.net.InetAddress;
import java.net.*;
[ "java.net" ]
java.net;
2,541,541
boolean initialize(JdbcDatastore datastore);
boolean initialize(JdbcDatastore datastore);
/** * Initializes the presenter with data from a given datastore. * * @param datastore * @return true if the datastore is accepted and presentable by this * {@link DatabaseConnectionPresenter}, or false if the presenter is * not able to present it. */
Initializes the presenter with data from a given datastore
initialize
{ "repo_name": "datacleaner/DataCleaner", "path": "desktop/ui/src/main/java/org/datacleaner/widgets/database/DatabaseConnectionPresenter.java", "license": "lgpl-3.0", "size": 1777 }
[ "org.datacleaner.connection.JdbcDatastore" ]
import org.datacleaner.connection.JdbcDatastore;
import org.datacleaner.connection.*;
[ "org.datacleaner.connection" ]
org.datacleaner.connection;
2,704,576
ApiResponse<ChannelList> searchChannels(String teamId, ChannelSearch search);
ApiResponse<ChannelList> searchChannels(String teamId, ChannelSearch search);
/** * returns the channels on a team matching the provided search term. */
returns the channels on a team matching the provided search term
searchChannels
{ "repo_name": "maruTA-bis5/mattermost4j", "path": "mattermost4j-core/src/main/java/net/bis5/mattermost/client4/api/ChannelApi.java", "license": "apache-2.0", "size": 10269 }
[ "net.bis5.mattermost.client4.ApiResponse", "net.bis5.mattermost.model.ChannelList", "net.bis5.mattermost.model.ChannelSearch" ]
import net.bis5.mattermost.client4.ApiResponse; import net.bis5.mattermost.model.ChannelList; import net.bis5.mattermost.model.ChannelSearch;
import net.bis5.mattermost.client4.*; import net.bis5.mattermost.model.*;
[ "net.bis5.mattermost" ]
net.bis5.mattermost;
2,625,780
private void requestSucceeded(final @NonNull ResponseModel responseModel) { try { if (responseModel.isComplete()) { status.append("Completed in %sms with status %s\nDigest:\n\t%s" , responseModel.getElaspedTimeMilli() , ...
void function(final @NonNull ResponseModel responseModel) { try { if (responseModel.isComplete()) { status.append(STR , responseModel.getElaspedTimeMilli() , responseModel.getStatus() , responseModel.getDigest().replaceAll("\n", "\n\t")); headers.setText(responseModel.getHeaders()); response.setText(responseModel.getBo...
/** * Handler for succeed task events * <p> * Update the window status and provide output */
Handler for succeed task events Update the window status and provide output
requestSucceeded
{ "repo_name": "technosf/Posterer", "path": "App/src/main/java/com/github/technosf/posterer/ui/controllers/impl/ResponseController.java", "license": "apache-2.0", "size": 12428 }
[ "com.github.technosf.posterer.models.ResponseModel", "java.util.concurrent.ExecutionException", "org.eclipse.jdt.annotation.NonNull" ]
import com.github.technosf.posterer.models.ResponseModel; import java.util.concurrent.ExecutionException; import org.eclipse.jdt.annotation.NonNull;
import com.github.technosf.posterer.models.*; import java.util.concurrent.*; import org.eclipse.jdt.annotation.*;
[ "com.github.technosf", "java.util", "org.eclipse.jdt" ]
com.github.technosf; java.util; org.eclipse.jdt;
2,578,013
public static Integer evalInteger(String attrName, String attrValue, Tag tagObject, PageContext pageContext) throws JspException { Object result = null; if (attrValue != null) { result = ExpressionEvaluatorManager.evaluate(attrName, attrValue, Integ...
static Integer function(String attrName, String attrValue, Tag tagObject, PageContext pageContext) throws JspException { Object result = null; if (attrValue != null) { result = ExpressionEvaluatorManager.evaluate(attrName, attrValue, Integer.class, tagObject, pageContext); } return (Integer) result; }
/** * Evaluates the attribute value in the JSTL EL engine, assuming the * resulting value is an Integer object. If the original expression is null, * or the resulting value is null, it will return null. */
Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is an Integer object. If the original expression is null, or the resulting value is null, it will return null
evalInteger
{ "repo_name": "YangYongZhi/csims", "path": "src/com/gtm/csims/webs/taglib/EvalHelper.java", "license": "apache-2.0", "size": 3214 }
[ "javax.servlet.jsp.JspException", "javax.servlet.jsp.PageContext", "javax.servlet.jsp.tagext.Tag", "org.apache.taglibs.standard.lang.support.ExpressionEvaluatorManager" ]
import javax.servlet.jsp.JspException; import javax.servlet.jsp.PageContext; import javax.servlet.jsp.tagext.Tag; import org.apache.taglibs.standard.lang.support.ExpressionEvaluatorManager;
import javax.servlet.jsp.*; import javax.servlet.jsp.tagext.*; import org.apache.taglibs.standard.lang.support.*;
[ "javax.servlet", "org.apache.taglibs" ]
javax.servlet; org.apache.taglibs;
419,715
public void addMapper(Mapper mapper) { synchronized(mappers) { if (mappers.get(mapper.getProtocol()) != null) throw new IllegalArgumentException("addMapper: Protocol '" + mapper.getProtocol() + ...
void function(Mapper mapper) { synchronized(mappers) { if (mappers.get(mapper.getProtocol()) != null) throw new IllegalArgumentException(STR + mapper.getProtocol() + STR); mapper.setContainer((Container) this); if (started && (mapper instanceof Lifecycle)) { try { ((Lifecycle) mapper).start(); } catch (LifecycleExcepti...
/** * Add the specified Mapper associated with this Container. * * @param mapper The corresponding Mapper implementation * * @exception IllegalArgumentException if this exception is thrown by * the <code>setContainer()</code> method of the Mapper */
Add the specified Mapper associated with this Container
addMapper
{ "repo_name": "devjin24/howtomcatworks", "path": "bookrefer/jakarta-tomcat-4.1.12-src/catalina/src/share/org/apache/catalina/core/ContainerBase.java", "license": "apache-2.0", "size": 44660 }
[ "org.apache.catalina.Container", "org.apache.catalina.Lifecycle", "org.apache.catalina.LifecycleException", "org.apache.catalina.Mapper" ]
import org.apache.catalina.Container; import org.apache.catalina.Lifecycle; import org.apache.catalina.LifecycleException; import org.apache.catalina.Mapper;
import org.apache.catalina.*;
[ "org.apache.catalina" ]
org.apache.catalina;
2,070,204
GetTaskRequestBuilder prepareGetTask(String taskId);
GetTaskRequestBuilder prepareGetTask(String taskId);
/** * Fetch a task by id. */
Fetch a task by id
prepareGetTask
{ "repo_name": "coding0011/elasticsearch", "path": "server/src/main/java/org/elasticsearch/client/ClusterAdminClient.java", "license": "apache-2.0", "size": 26995 }
[ "org.elasticsearch.action.admin.cluster.node.tasks.get.GetTaskRequestBuilder" ]
import org.elasticsearch.action.admin.cluster.node.tasks.get.GetTaskRequestBuilder;
import org.elasticsearch.action.admin.cluster.node.tasks.get.*;
[ "org.elasticsearch.action" ]
org.elasticsearch.action;
2,036,602
public Observable<ServiceResponse<Void>> deleteWithServiceResponseAsync(String resourceGroupName, String virtualNetworkName) { if (resourceGroupName == null) { throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); } if (virtualNetworkN...
Observable<ServiceResponse<Void>> function(String resourceGroupName, String virtualNetworkName) { if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (virtualNetworkName == null) { throw new IllegalArgumentException(STR); } if (this.client.subscriptionId() == null) { throw new IllegalArgument...
/** * Deletes the specified virtual network. * * @param resourceGroupName The name of the resource group. * @param virtualNetworkName The name of the virtual network. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the observable for the request *...
Deletes the specified virtual network
deleteWithServiceResponseAsync
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/network/mgmt-v2019_04_01/src/main/java/com/microsoft/azure/management/network/v2019_04_01/implementation/VirtualNetworksInner.java", "license": "mit", "size": 98691 }
[ "com.google.common.reflect.TypeToken", "com.microsoft.rest.ServiceResponse" ]
import com.google.common.reflect.TypeToken; import com.microsoft.rest.ServiceResponse;
import com.google.common.reflect.*; import com.microsoft.rest.*;
[ "com.google.common", "com.microsoft.rest" ]
com.google.common; com.microsoft.rest;
368,076
public static String getDropBoxPath() throws IOException { Diodable diode = null; if (SystemUtils.IS_OS_WINDOWS) { diode = new WindowsDiode(); } else if (SystemUtils.IS_OS_LINUX || SystemUtils.IS_OS_MAC) { diode = new NixDiode(); } return diode != null ? d...
static String function() throws IOException { Diodable diode = null; if (SystemUtils.IS_OS_WINDOWS) { diode = new WindowsDiode(); } else if (SystemUtils.IS_OS_LINUX SystemUtils.IS_OS_MAC) { diode = new NixDiode(); } return diode != null ? diode.getDropBoxPath() : null; }
/** * Get Dropbox path of the system * @return path of dropbox folder * @throws IOException */
Get Dropbox path of the system
getDropBoxPath
{ "repo_name": "geniussoftlk/brainiac", "path": "src/main/java/com/officialgenius/brainiac/Brainiac.java", "license": "apache-2.0", "size": 1393 }
[ "com.officialgenius.brainiac.diodes.Diodable", "com.officialgenius.brainiac.diodes.NixDiode", "com.officialgenius.brainiac.diodes.WindowsDiode", "java.io.IOException", "org.apache.commons.lang3.SystemUtils" ]
import com.officialgenius.brainiac.diodes.Diodable; import com.officialgenius.brainiac.diodes.NixDiode; import com.officialgenius.brainiac.diodes.WindowsDiode; import java.io.IOException; import org.apache.commons.lang3.SystemUtils;
import com.officialgenius.brainiac.diodes.*; import java.io.*; import org.apache.commons.lang3.*;
[ "com.officialgenius.brainiac", "java.io", "org.apache.commons" ]
com.officialgenius.brainiac; java.io; org.apache.commons;
243,863
public static int readEnum(int iParentNode, String sName, String[] saEnumNames, int[] iaEnumValues, int iDefaultValue) throws XMLException { if (saEnumNames.length != iaEnumValues.length) { throw new IllegalArgumentExceptio...
static int function(int iParentNode, String sName, String[] saEnumNames, int[] iaEnumValues, int iDefaultValue) throws XMLException { if (saEnumNames.length != iaEnumValues.length) { throw new IllegalArgumentException(STR); } if (saEnumNames.length == 0) { throw new IllegalArgumentException(STR); } String sValue = read...
/** * Reads an enumerated value from the node text. * * @param iParentNode Current node. * @param sName Element name. * @param saEnumNames Enum names. * @param iaEnumValues Enum values. * @param iDefaultValue Default enum value. * * @retu...
Reads an enumerated value from the node text
readEnum
{ "repo_name": "MatthiasEberl/cordysfilecon", "path": "src/cws/FileConnector/com-cordys-coe/fileconnector/java/source/com/cordys/coe/ac/fileconnector/utils/XMLSerializer.java", "license": "apache-2.0", "size": 13701 }
[ "com.eibus.xml.nom.XMLException" ]
import com.eibus.xml.nom.XMLException;
import com.eibus.xml.nom.*;
[ "com.eibus.xml" ]
com.eibus.xml;
1,981,338
public void shutdown() { BBoxDBInstanceManager.getInstance().removeListener(distributedEventConsumer); unregisterTreeChangeListener(); }
void function() { BBoxDBInstanceManager.getInstance().removeListener(distributedEventConsumer); unregisterTreeChangeListener(); }
/** * Shutdown the GUI model */
Shutdown the GUI model
shutdown
{ "repo_name": "jnidzwetzki/bboxdb", "path": "bboxdb-tools/src/main/java/org/bboxdb/tools/gui/GuiModel.java", "license": "apache-2.0", "size": 9353 }
[ "org.bboxdb.distribution.membership.BBoxDBInstanceManager" ]
import org.bboxdb.distribution.membership.BBoxDBInstanceManager;
import org.bboxdb.distribution.membership.*;
[ "org.bboxdb.distribution" ]
org.bboxdb.distribution;
2,024,448
@SuppressWarnings("unchecked") @AuraTestLabels("auraSanity") public void testVerifyPostWithoutToken() throws Exception { Map<String, String> params = makeBasePostParams(); params.put("aura.context", String.format("{\"mode\":\"FTEST\",\"fwuid\":\"%s\"}", Aura.getConfigAdapter(...
@SuppressWarnings(STR) @AuraTestLabels(STR) void function() throws Exception { Map<String, String> params = makeBasePostParams(); params.put(STR, String.format("{\"mode\":\"FTEST\",\"fwuid\":\"%s\"}", Aura.getConfigAdapter().getAuraFrameworkNonce())); HttpPost post = obtainPostMethod("/aura", params); HttpResponse http...
/** * Test to post a request to aura servlet without a CSRF token. This test * tries to request a action defined on a controller. But the request does * not have a valid CSRF token, hence the request should fail to fetch the * def. */
Test to post a request to aura servlet without a CSRF token. This test tries to request a action defined on a controller. But the request does not have a valid CSRF token, hence the request should fail to fetch the def
testVerifyPostWithoutToken
{ "repo_name": "igor-sfdc/aura", "path": "aura/src/test/java/org/auraframework/impl/security/CSRFTokenValidationHttpTest.java", "license": "apache-2.0", "size": 6299 }
[ "java.util.Map", "org.apache.http.HttpResponse", "org.apache.http.HttpStatus", "org.apache.http.client.methods.HttpPost", "org.auraframework.Aura", "org.auraframework.test.annotation.AuraTestLabels", "org.auraframework.util.json.JsFunction" ]
import java.util.Map; import org.apache.http.HttpResponse; import org.apache.http.HttpStatus; import org.apache.http.client.methods.HttpPost; import org.auraframework.Aura; import org.auraframework.test.annotation.AuraTestLabels; import org.auraframework.util.json.JsFunction;
import java.util.*; import org.apache.http.*; import org.apache.http.client.methods.*; import org.auraframework.*; import org.auraframework.test.annotation.*; import org.auraframework.util.json.*;
[ "java.util", "org.apache.http", "org.auraframework", "org.auraframework.test", "org.auraframework.util" ]
java.util; org.apache.http; org.auraframework; org.auraframework.test; org.auraframework.util;
2,306,816
public QuotaCounterCollectionInner withValue(List<QuotaCounterContractInner> value) { this.value = value; return this; }
QuotaCounterCollectionInner function(List<QuotaCounterContractInner> value) { this.value = value; return this; }
/** * Set quota counter values. * * @param value the value value to set * @return the QuotaCounterCollectionInner object itself. */
Set quota counter values
withValue
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/apimanagement/mgmt-v2019_12_01/src/main/java/com/microsoft/azure/management/apimanagement/v2019_12_01/implementation/QuotaCounterCollectionInner.java", "license": "mit", "size": 2274 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,421,805
//@Override public void run() { logger.info("Begin " + Thread.currentThread().getName()); try { while (true) { if (Thread.interrupted()) { return; } try { c...
logger.info(STR + Thread.currentThread().getName()); try { while (true) { if (Thread.interrupted()) { return; } try { connectAndProcess(); } catch (SocketTimeoutException ex) { logger.log(Level.WARNING, credentials.getUserName() + STR + baseUrl, ex); tcpBackOff.backOff(); } catch (InterruptedException ex) { return; } c...
/** * Connects to twitter and processes the streams. On * exception, backs off and reconnects. Runs until the thread * is interrupted. */
Connects to twitter and processes the streams. On exception, backs off and reconnects. Runs until the thread is interrupted
run
{ "repo_name": "jenkinjk/TwitterClient", "path": "src/com/gist/twitter/TwitterClient.java", "license": "apache-2.0", "size": 17886 }
[ "java.io.IOException", "java.io.InterruptedIOException", "java.net.SocketTimeoutException", "java.util.logging.Level", "org.apache.commons.httpclient.HttpException" ]
import java.io.IOException; import java.io.InterruptedIOException; import java.net.SocketTimeoutException; import java.util.logging.Level; import org.apache.commons.httpclient.HttpException;
import java.io.*; import java.net.*; import java.util.logging.*; import org.apache.commons.httpclient.*;
[ "java.io", "java.net", "java.util", "org.apache.commons" ]
java.io; java.net; java.util; org.apache.commons;
2,533,207
protected void fireBaseAttributeListeners(String pn) { if (targetListeners != null) { LinkedList ll = (LinkedList) targetListeners.get(pn); if (ll != null) { for (Object aLl : ll) { AnimationTargetListener l = (Animation...
void function(String pn) { if (targetListeners != null) { LinkedList ll = (LinkedList) targetListeners.get(pn); if (ll != null) { for (Object aLl : ll) { AnimationTargetListener l = (AnimationTargetListener) aLl; l.baseValueChanged((AnimationTarget) e, null, pn, true); } } } }
/** * Fires the listeners registered for changes to the base value of the * given CSS property. */
Fires the listeners registered for changes to the base value of the given CSS property
fireBaseAttributeListeners
{ "repo_name": "apache/batik", "path": "batik-bridge/src/main/java/org/apache/batik/bridge/AnimatableSVGBridge.java", "license": "apache-2.0", "size": 3102 }
[ "java.util.LinkedList", "org.apache.batik.anim.dom.AnimationTarget", "org.apache.batik.anim.dom.AnimationTargetListener" ]
import java.util.LinkedList; import org.apache.batik.anim.dom.AnimationTarget; import org.apache.batik.anim.dom.AnimationTargetListener;
import java.util.*; import org.apache.batik.anim.dom.*;
[ "java.util", "org.apache.batik" ]
java.util; org.apache.batik;
1,149,409
public void report(I_CmsReport report, CmsMessageContainer message, Throwable throwable) throws CmsVfsException, CmsException { if (report != null) { if (message != null) { report.println(message, I_CmsReport.FORMAT_ERROR); } if (throwable != n...
void function(I_CmsReport report, CmsMessageContainer message, Throwable throwable) throws CmsVfsException, CmsException { if (report != null) { if (message != null) { report.println(message, I_CmsReport.FORMAT_ERROR); } if (throwable != null) { report.println(throwable); } } throwException(message, throwable); }
/** * Reports an error to the given report (if available) and to the OpenCms log file.<p> * * @param report the report to write the error to * @param message the message to write to the report / log * @param throwable the exception to write to the report / log * * @throws Cm...
Reports an error to the given report (if available) and to the OpenCms log file
report
{ "repo_name": "comundus/opencms-comundus", "path": "src/main/java/org/opencms/db/CmsDbContext.java", "license": "lgpl-2.1", "size": 7640 }
[ "org.opencms.file.CmsVfsException", "org.opencms.i18n.CmsMessageContainer", "org.opencms.main.CmsException" ]
import org.opencms.file.CmsVfsException; import org.opencms.i18n.CmsMessageContainer; import org.opencms.main.CmsException;
import org.opencms.file.*; import org.opencms.i18n.*; import org.opencms.main.*;
[ "org.opencms.file", "org.opencms.i18n", "org.opencms.main" ]
org.opencms.file; org.opencms.i18n; org.opencms.main;
1,767,309
public void testSerialization() { CompassPlot p1 = new CompassPlot(null); CompassPlot p2 = null; try { ByteArrayOutputStream buffer = new ByteArrayOutputStream(); ObjectOutput out = new ObjectOutputStream(buffer); out.writeObject(p1); out.clo...
void function() { CompassPlot p1 = new CompassPlot(null); CompassPlot p2 = null; try { ByteArrayOutputStream buffer = new ByteArrayOutputStream(); ObjectOutput out = new ObjectOutputStream(buffer); out.writeObject(p1); out.close(); ObjectInput in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); ...
/** * Serialize an instance, restore it, and check for equality. */
Serialize an instance, restore it, and check for equality
testSerialization
{ "repo_name": "simeshev/parabuild-ci", "path": "3rdparty/jfreechart0921/source/org/jfree/chart/plot/junit/CompassPlotTests.java", "license": "lgpl-3.0", "size": 3594 }
[ "java.io.ByteArrayInputStream", "java.io.ByteArrayOutputStream", "java.io.ObjectInput", "java.io.ObjectInputStream", "java.io.ObjectOutput", "java.io.ObjectOutputStream", "org.jfree.chart.plot.CompassPlot" ]
import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.ObjectInput; import java.io.ObjectInputStream; import java.io.ObjectOutput; import java.io.ObjectOutputStream; import org.jfree.chart.plot.CompassPlot;
import java.io.*; import org.jfree.chart.plot.*;
[ "java.io", "org.jfree.chart" ]
java.io; org.jfree.chart;
1,852,050
@Override public void close() throws IOException { if (SecurityUtil.isPackageProtectionEnabled()){ try{ AccessController.doPrivileged( new PrivilegedExceptionAction<Void>(){
void function() throws IOException { if (SecurityUtil.isPackageProtectionEnabled()){ try{ AccessController.doPrivileged( new PrivilegedExceptionAction<Void>(){
/** * Close the stream * Since we re-cycle, we can't allow the call to super.close() * which would permanently disable us. */
Close the stream Since we re-cycle, we can't allow the call to super.close() which would permanently disable us
close
{ "repo_name": "plumer/codana", "path": "tomcat_files/7.0.0/CoyoteInputStream.java", "license": "mit", "size": 7241 }
[ "java.io.IOException", "java.security.AccessController", "java.security.PrivilegedExceptionAction", "org.apache.catalina.security.SecurityUtil" ]
import java.io.IOException; import java.security.AccessController; import java.security.PrivilegedExceptionAction; import org.apache.catalina.security.SecurityUtil;
import java.io.*; import java.security.*; import org.apache.catalina.security.*;
[ "java.io", "java.security", "org.apache.catalina" ]
java.io; java.security; org.apache.catalina;
2,340,989
@Test public final void test_that_a_Message_lines_retain_their_indentation() { final Iterator<String> lineIt = message.iterator(); assertEquals(" Hello", lineIt.next()); assertEquals("World", lineIt.next()); assertFalse(lineIt.hasNext()); }
final void function() { final Iterator<String> lineIt = message.iterator(); assertEquals(STR, lineIt.next()); assertEquals("World", lineIt.next()); assertFalse(lineIt.hasNext()); }
/** * Tests that a {@code Message}'s lines retain their indentation. */
Tests that a Message's lines retain their indentation
test_that_a_Message_lines_retain_their_indentation
{ "repo_name": "Hilco-Wijbenga/blueprint", "path": "terminals/src/test/java/org/cavebeetle/blueprint/MessageTest.java", "license": "apache-2.0", "size": 4641 }
[ "java.util.Iterator", "org.junit.Assert" ]
import java.util.Iterator; import org.junit.Assert;
import java.util.*; import org.junit.*;
[ "java.util", "org.junit" ]
java.util; org.junit;
1,623,392
Class<T> configurationClass = (Class<T>) configurationObject.getClass(); List<Method> methods = getGetMethods(configurationClass); StringBuffer out = new StringBuffer(); for (Method method : methods) { out.append(String.format( "%1$-20s" , method.getName().substring(3) ) + " : "); ...
Class<T> configurationClass = (Class<T>) configurationObject.getClass(); List<Method> methods = getGetMethods(configurationClass); StringBuffer out = new StringBuffer(); for (Method method : methods) { out.append(String.format( STR , method.getName().substring(3) ) + STR); try { out.append( "\"STR\STR\n"); } return out...
/** * * This method will iterate over the getMethods defined in T and call * them on the configurationObject. The results are summarised in a table * which is returned as a string. * * @param configurationObject * @return A string summarising the contents of the configuration object. * */
This method will iterate over the getMethods defined in T and call them on the configurationObject. The results are summarised in a table which is returned as a string
dump
{ "repo_name": "Ensembl/ensj-healthcheck", "path": "src/org/ensembl/healthcheck/configurationmanager/ConfigurationDumper.java", "license": "apache-2.0", "size": 2431 }
[ "java.lang.reflect.Method", "java.util.List" ]
import java.lang.reflect.Method; import java.util.List;
import java.lang.reflect.*; import java.util.*;
[ "java.lang", "java.util" ]
java.lang; java.util;
1,718,408
private void workOnChangeSet(IndexWriter indexWriter, SVNLogEntry logEntry) { Set<?> changedPathsSet = logEntry.getChangedPaths().keySet(); TagBranchRecognition tbr = new TagBranchRecognition(getRepository()); TagBranch res = null; // Check if we have a Tag, Branch, Maven Tag...
void function(IndexWriter indexWriter, SVNLogEntry logEntry) { Set<?> changedPathsSet = logEntry.getChangedPaths().keySet(); TagBranchRecognition tbr = new TagBranchRecognition(getRepository()); TagBranch res = null; if (changedPathsSet.size() == 1) { res = tbr.checkForTagOrBranch(logEntry, changedPathsSet); } else { r...
/** * Here we have a single ChangeSet which will be analyzed separate. * * @param indexWriter * @param logEntry */
Here we have a single ChangeSet which will be analyzed separate
workOnChangeSet
{ "repo_name": "khmarbaise/supose", "path": "supose-core/src/main/java/com/soebes/supose/core/scan/ScanRepository.java", "license": "gpl-2.0", "size": 19842 }
[ "com.soebes.supose.core.recognition.TagBranch", "com.soebes.supose.core.recognition.TagBranchRecognition", "java.util.Iterator", "java.util.Set", "org.apache.lucene.index.IndexWriter", "org.tmatesoft.svn.core.SVNLogEntry", "org.tmatesoft.svn.core.SVNLogEntryPath" ]
import com.soebes.supose.core.recognition.TagBranch; import com.soebes.supose.core.recognition.TagBranchRecognition; import java.util.Iterator; import java.util.Set; import org.apache.lucene.index.IndexWriter; import org.tmatesoft.svn.core.SVNLogEntry; import org.tmatesoft.svn.core.SVNLogEntryPath;
import com.soebes.supose.core.recognition.*; import java.util.*; import org.apache.lucene.index.*; import org.tmatesoft.svn.core.*;
[ "com.soebes.supose", "java.util", "org.apache.lucene", "org.tmatesoft.svn" ]
com.soebes.supose; java.util; org.apache.lucene; org.tmatesoft.svn;
1,569,399
void updateDepartment(DepartmentDTO department) throws IllegalArgumentException;
void updateDepartment(DepartmentDTO department) throws IllegalArgumentException;
/** * Method updates given DepartmentDTO inside database via DAO layer call. * @param department to be updated * @throws IllegalArgumentException when ID is null */
Method updates given DepartmentDTO inside database via DAO layer call
updateDepartment
{ "repo_name": "empt-ak/bis", "path": "bis-api/src/main/java/cz/muni/ics/phil/bis/api/DepartmentService.java", "license": "apache-2.0", "size": 2667 }
[ "cz.muni.ics.phil.bis.api.domain.DepartmentDTO" ]
import cz.muni.ics.phil.bis.api.domain.DepartmentDTO;
import cz.muni.ics.phil.bis.api.domain.*;
[ "cz.muni.ics" ]
cz.muni.ics;
1,966,029
public BeanDefinitionBuilder addPropertyValue(String name, Object value) { this.beanDefinition.getPropertyValues().addPropertyValue(new PropertyValue(name, value)); return this; }
BeanDefinitionBuilder function(String name, Object value) { this.beanDefinition.getPropertyValues().addPropertyValue(new PropertyValue(name, value)); return this; }
/** * Add the supplied property value under the given name. */
Add the supplied property value under the given name
addPropertyValue
{ "repo_name": "codeApeFromChina/resource", "path": "frame_packages/java_libs/spring-2.5.6-src/src/org/springframework/beans/factory/support/BeanDefinitionBuilder.java", "license": "unlicense", "size": 11485 }
[ "org.springframework.beans.PropertyValue" ]
import org.springframework.beans.PropertyValue;
import org.springframework.beans.*;
[ "org.springframework.beans" ]
org.springframework.beans;
978,998
public JsonDataSource subDataSource(String selectExpression) throws JRException { if(currentJsonNode == null) { throw new JRException("No node available. Iterate or rewind the data source."); } try { return new JsonDataSource(new ByteArrayInputStream(currentJsonNode.toString().getBytes("UTF-8...
JsonDataSource function(String selectExpression) throws JRException { if(currentJsonNode == null) { throw new JRException(STR); } try { return new JsonDataSource(new ByteArrayInputStream(currentJsonNode.toString().getBytes("UTF-8")), selectExpression); } catch(UnsupportedEncodingException e) { throw new JRRuntimeExcept...
/** * Creates a sub data source using the current node as the base for its input stream. * An additional expression specifies the select criteria that will be applied to the * JSON tree node. * * @param selectExpression * @return the JSON sub data source * @throws JRException */
Creates a sub data source using the current node as the base for its input stream. An additional expression specifies the select criteria that will be applied to the JSON tree node
subDataSource
{ "repo_name": "sikachu/jasperreports", "path": "src/net/sf/jasperreports/engine/data/JsonDataSource.java", "license": "lgpl-3.0", "size": 14638 }
[ "java.io.ByteArrayInputStream", "java.io.UnsupportedEncodingException", "net.sf.jasperreports.engine.JRException", "net.sf.jasperreports.engine.JRRuntimeException" ]
import java.io.ByteArrayInputStream; import java.io.UnsupportedEncodingException; import net.sf.jasperreports.engine.JRException; import net.sf.jasperreports.engine.JRRuntimeException;
import java.io.*; import net.sf.jasperreports.engine.*;
[ "java.io", "net.sf.jasperreports" ]
java.io; net.sf.jasperreports;
1,477,375
URL publicKey = PrimitiveInjectionTest.class.getResource("/publicKey.pem"); WebArchive webArchive = ShrinkWrap .create(WebArchive.class, "PrimitiveInjectionTest.war") .addAsManifestResource(new StringAsset(MpJwtTestVersion.MPJWT_V_1_0.name()), MpJwtTestVersion.MANIFEST_NAME) ...
URL publicKey = PrimitiveInjectionTest.class.getResource(STR); WebArchive webArchive = ShrinkWrap .create(WebArchive.class, STR) .addAsManifestResource(new StringAsset(MpJwtTestVersion.MPJWT_V_1_0.name()), MpJwtTestVersion.MANIFEST_NAME) .addAsResource(publicKey, STR) .addClass(PrimitiveInjectionEndpoint.class) .addCla...
/** * Create a CDI aware base web application archive * @return the base base web application archive * @throws IOException - on resource failure */
Create a CDI aware base web application archive
createDeployment
{ "repo_name": "MicroProfileJWT/microprofile-jwt-auth", "path": "tck/src/test/java/org/eclipse/microprofile/jwt/tck/container/jaxrs/PrimitiveInjectionTest.java", "license": "apache-2.0", "size": 14776 }
[ "org.eclipse.microprofile.jwt.tck.util.MpJwtTestVersion", "org.jboss.shrinkwrap.api.ShrinkWrap", "org.jboss.shrinkwrap.api.asset.StringAsset", "org.jboss.shrinkwrap.api.spec.WebArchive" ]
import org.eclipse.microprofile.jwt.tck.util.MpJwtTestVersion; import org.jboss.shrinkwrap.api.ShrinkWrap; import org.jboss.shrinkwrap.api.asset.StringAsset; import org.jboss.shrinkwrap.api.spec.WebArchive;
import org.eclipse.microprofile.jwt.tck.util.*; import org.jboss.shrinkwrap.api.*; import org.jboss.shrinkwrap.api.asset.*; import org.jboss.shrinkwrap.api.spec.*;
[ "org.eclipse.microprofile", "org.jboss.shrinkwrap" ]
org.eclipse.microprofile; org.jboss.shrinkwrap;
245,917
public Form infoAdicional() { if(info == null) { info = new Form("Info Adicional"); info.addCommand(new Command("Voltar", Command.BACK, 1)); infoAdicional = new StringItem("", ""); infoAnexos = new StringItem("", ""); ...
Form function() { if(info == null) { info = new Form(STR); info.addCommand(new Command(STR, Command.BACK, 1)); infoAdicional = new StringItem(STR"); infoAnexos = new StringItem(STR"); info.append(infoAdicional); info.append(infoAnexos); } return info; }
/** * o formulario onde e mostrada a informacao adicional de um mail * @return o form */
o formulario onde e mostrada a informacao adicional de um mail
infoAdicional
{ "repo_name": "rvelhote/university", "path": "bluetooth/bluetooth.cliente/src/bluetooth/cliente/gui/MailsGUI.java", "license": "unlicense", "size": 5058 }
[ "javax.microedition.lcdui.Command", "javax.microedition.lcdui.Form", "javax.microedition.lcdui.StringItem" ]
import javax.microedition.lcdui.Command; import javax.microedition.lcdui.Form; import javax.microedition.lcdui.StringItem;
import javax.microedition.lcdui.*;
[ "javax.microedition" ]
javax.microedition;
1,540,777
protected void addHistoryEntry(HostDynamicWorkload host, double metric) { int hostId = host.getId(); if (!getTimeHistory().containsKey(hostId)) { getTimeHistory().put(hostId, new LinkedList<Double>()); } if (!getUtilizationHistory().containsKey(hostId)) { getUtilizationHistory().put(hostId, new L...
void function(HostDynamicWorkload host, double metric) { int hostId = host.getId(); if (!getTimeHistory().containsKey(hostId)) { getTimeHistory().put(hostId, new LinkedList<Double>()); } if (!getUtilizationHistory().containsKey(hostId)) { getUtilizationHistory().put(hostId, new LinkedList<Double>()); } if (!getMetricHi...
/** * Adds the history value. * * @param host the host * @param metric the metric */
Adds the history value
addHistoryEntry
{ "repo_name": "hieuvt/tccloudsim", "path": "sources/org/cloudbus/cloudsim/power/PowerVmAllocationPolicyMigrationAbstract.java", "license": "lgpl-3.0", "size": 20796 }
[ "java.util.LinkedList", "org.cloudbus.cloudsim.HostDynamicWorkload", "org.cloudbus.cloudsim.core.CloudSim" ]
import java.util.LinkedList; import org.cloudbus.cloudsim.HostDynamicWorkload; import org.cloudbus.cloudsim.core.CloudSim;
import java.util.*; import org.cloudbus.cloudsim.*; import org.cloudbus.cloudsim.core.*;
[ "java.util", "org.cloudbus.cloudsim" ]
java.util; org.cloudbus.cloudsim;
121,583
@RequestMapping("/doGetAOIParam") public ModelAndView doGetAOIParam( @RequestParam("serviceUrl") String serviceUrl, @RequestParam("featureType") String featureType) throws IOException, PortalServiceException { JSONArray dataItems = new JSONArray(); String group = ""; ...
@RequestMapping(STR) ModelAndView function( @RequestParam(STR) String serviceUrl, @RequestParam(STR) String featureType) throws IOException, PortalServiceException { JSONArray dataItems = new JSONArray(); String group = STRclassifierSTRpref_nameSTRminSTRmaxSTR"); }
/** * Handler for the download of the hydrochemistry data in CSV format * * @param serviceUrl * the url of the service to query * @param featureType * The grouping of the dataset correlate to the featureType. * @return ModelAndView * @throws IOException ...
Handler for the download of the hydrochemistry data in CSV format
doGetAOIParam
{ "repo_name": "GeoscienceAustralia/geoscience-portal", "path": "src/main/java/org/auscope/portal/server/web/controllers/CapdfHydroGeoChemController.java", "license": "lgpl-3.0", "size": 24200 }
[ "java.io.IOException", "net.sf.json.JSONArray", "org.auscope.portal.core.services.PortalServiceException", "org.springframework.web.bind.annotation.RequestMapping", "org.springframework.web.bind.annotation.RequestParam", "org.springframework.web.servlet.ModelAndView" ]
import java.io.IOException; import net.sf.json.JSONArray; import org.auscope.portal.core.services.PortalServiceException; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.servlet.ModelAndView;
import java.io.*; import net.sf.json.*; import org.auscope.portal.core.services.*; import org.springframework.web.bind.annotation.*; import org.springframework.web.servlet.*;
[ "java.io", "net.sf.json", "org.auscope.portal", "org.springframework.web" ]
java.io; net.sf.json; org.auscope.portal; org.springframework.web;
1,903,771
protected RegisterApplicationMasterResponse registerApplicationMaster( final int testAppId) throws Exception, YarnException, IOException { final ApplicationUserInfo ugi = getApplicationUserInfo(testAppId);
RegisterApplicationMasterResponse function( final int testAppId) throws Exception, YarnException, IOException { final ApplicationUserInfo ugi = getApplicationUserInfo(testAppId);
/** * Helper method to register an application master using specified testAppId * as the application identifier and return the response * * @param testAppId * @return * @throws Exception * @throws YarnException * @throws IOException */
Helper method to register an application master using specified testAppId as the application identifier and return the response
registerApplicationMaster
{ "repo_name": "ronny-macmaster/hadoop", "path": "hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-nodemanager/src/test/java/org/apache/hadoop/yarn/server/nodemanager/amrmproxy/BaseAMRMProxyTest.java", "license": "apache-2.0", "size": 25566 }
[ "java.io.IOException", "org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse", "org.apache.hadoop.yarn.exceptions.YarnException" ]
import java.io.IOException; import org.apache.hadoop.yarn.api.protocolrecords.RegisterApplicationMasterResponse; import org.apache.hadoop.yarn.exceptions.YarnException;
import java.io.*; import org.apache.hadoop.yarn.api.protocolrecords.*; import org.apache.hadoop.yarn.exceptions.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
2,772,107
public void setErrorMessageProvider( @Nullable ErrorMessageProvider<? super PlaybackException> errorMessageProvider) { if (this.errorMessageProvider != errorMessageProvider) { this.errorMessageProvider = errorMessageProvider; updateErrorMessage(); } }
void function( @Nullable ErrorMessageProvider<? super PlaybackException> errorMessageProvider) { if (this.errorMessageProvider != errorMessageProvider) { this.errorMessageProvider = errorMessageProvider; updateErrorMessage(); } }
/** * Sets the optional {@link ErrorMessageProvider}. * * @param errorMessageProvider The error message provider. */
Sets the optional <code>ErrorMessageProvider</code>
setErrorMessageProvider
{ "repo_name": "google/ExoPlayer", "path": "library/ui/src/main/java/com/google/android/exoplayer2/ui/PlayerView.java", "license": "apache-2.0", "size": 60285 }
[ "androidx.annotation.Nullable", "com.google.android.exoplayer2.PlaybackException", "com.google.android.exoplayer2.util.ErrorMessageProvider" ]
import androidx.annotation.Nullable; import com.google.android.exoplayer2.PlaybackException; import com.google.android.exoplayer2.util.ErrorMessageProvider;
import androidx.annotation.*; import com.google.android.exoplayer2.*; import com.google.android.exoplayer2.util.*;
[ "androidx.annotation", "com.google.android" ]
androidx.annotation; com.google.android;
956,644
public static Version parseVersionLenient(String toParse, Version defaultValue) { return LenientParser.parse(toParse, defaultValue); }
static Version function(String toParse, Version defaultValue) { return LenientParser.parse(toParse, defaultValue); }
/** * Parses the version string lenient and returns the default value if the given string is null or empty */
Parses the version string lenient and returns the default value if the given string is null or empty
parseVersionLenient
{ "repo_name": "LeoYao/elasticsearch", "path": "core/src/main/java/org/elasticsearch/common/lucene/Lucene.java", "license": "apache-2.0", "size": 34227 }
[ "org.apache.lucene.util.Version" ]
import org.apache.lucene.util.Version;
import org.apache.lucene.util.*;
[ "org.apache.lucene" ]
org.apache.lucene;
457,138
@Override public Member updateMemberCache(final IMemberInformation inInformation) throws SQLException, VException { // intentionally left empty return null; }
Member function(final IMemberInformation inInformation) throws SQLException, VException { return null; }
/** Not applicable in this case, therefore, no implementation provided. * * @see org.hip.vif.bom.MemberHome#updateMemberCache(org.hip.vif.member.IMemberInformation) */
Not applicable in this case, therefore, no implementation provided
updateMemberCache
{ "repo_name": "aktion-hip/vif", "path": "org.hip.vif.member.ldap/src/org/hip/vif/member/ldap/LDAPMemberHome.java", "license": "gpl-2.0", "size": 6130 }
[ "java.sql.SQLException", "org.hip.kernel.exc.VException", "org.hip.vif.core.bom.Member", "org.hip.vif.core.member.IMemberInformation" ]
import java.sql.SQLException; import org.hip.kernel.exc.VException; import org.hip.vif.core.bom.Member; import org.hip.vif.core.member.IMemberInformation;
import java.sql.*; import org.hip.kernel.exc.*; import org.hip.vif.core.bom.*; import org.hip.vif.core.member.*;
[ "java.sql", "org.hip.kernel", "org.hip.vif" ]
java.sql; org.hip.kernel; org.hip.vif;
1,937,367
public Color getBrushColor() { return this.brushColor; }
Color function() { return this.brushColor; }
/** * Getter for property brushColor. * @return Value of property brushColor. */
Getter for property brushColor
getBrushColor
{ "repo_name": "Mindtoeye/Hoop", "path": "src/org/jdesktop/swingx/painter/effects/AbstractAreaEffect.java", "license": "lgpl-3.0", "size": 13731 }
[ "java.awt.Color" ]
import java.awt.Color;
import java.awt.*;
[ "java.awt" ]
java.awt;
2,006,032
public void setURIResolver(URIResolver uriResolver) { this.uriResolver = uriResolver; // entityResolver = new MyEntityResolver(uriResolver); }
void function(URIResolver uriResolver) { this.uriResolver = uriResolver; }
/** * Set the URI Resolver to use. * * @param uriResolver * The URI Resolver to use. */
Set the URI Resolver to use
setURIResolver
{ "repo_name": "angelozerr/eclipse-wtp-json", "path": "core/org.eclipse.wst.json.core/src/org/eclipse/wst/json/core/internal/validation/JSONValidator.java", "license": "mit", "size": 11133 }
[ "org.eclipse.wst.common.uriresolver.internal.provisional.URIResolver" ]
import org.eclipse.wst.common.uriresolver.internal.provisional.URIResolver;
import org.eclipse.wst.common.uriresolver.internal.provisional.*;
[ "org.eclipse.wst" ]
org.eclipse.wst;
684,632
LocalContainerEntityManagerFactoryBean newEntityManagerFactoryBean(JpaConfigurationContext config, AbstractJpaProperties jpaProperties);
LocalContainerEntityManagerFactoryBean newEntityManagerFactoryBean(JpaConfigurationContext config, AbstractJpaProperties jpaProperties);
/** * New entity manager factory bean local container entity manager factory bean. * * @param config the config * @param jpaProperties the jpa properties * @return the local container entity manager factory bean */
New entity manager factory bean local container entity manager factory bean
newEntityManagerFactoryBean
{ "repo_name": "fogbeam/cas_mirror", "path": "support/cas-server-support-jpa-util/src/main/java/org/apereo/cas/jpa/JpaBeanFactory.java", "license": "apache-2.0", "size": 2089 }
[ "org.apereo.cas.configuration.model.support.jpa.AbstractJpaProperties", "org.apereo.cas.configuration.model.support.jpa.JpaConfigurationContext", "org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean" ]
import org.apereo.cas.configuration.model.support.jpa.AbstractJpaProperties; import org.apereo.cas.configuration.model.support.jpa.JpaConfigurationContext; import org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean;
import org.apereo.cas.configuration.model.support.jpa.*; import org.springframework.orm.jpa.*;
[ "org.apereo.cas", "org.springframework.orm" ]
org.apereo.cas; org.springframework.orm;
1,688,131
private static Exception extractException(Exception e) { while (e instanceof PrivilegedActionException) { e = ((PrivilegedActionException)e).getException(); } return e; } private static class IdAndFilter { private Integer id; private NotificationFilter fi...
static Exception function(Exception e) { while (e instanceof PrivilegedActionException) { e = ((PrivilegedActionException)e).getException(); } return e; } private static class IdAndFilter { private Integer id; private NotificationFilter filter; IdAndFilter(Integer id, NotificationFilter filter) { this.id = id; this.fil...
/** * Iterate until we extract the real exception * from a stack of PrivilegedActionExceptions. */
Iterate until we extract the real exception from a stack of PrivilegedActionExceptions
extractException
{ "repo_name": "rokn/Count_Words_2015", "path": "testing/openjdk2/jdk/src/share/classes/com/sun/jmx/remote/internal/ServerNotifForwarder.java", "license": "mit", "size": 18551 }
[ "java.security.PrivilegedActionException", "javax.management.NotificationFilter" ]
import java.security.PrivilegedActionException; import javax.management.NotificationFilter;
import java.security.*; import javax.management.*;
[ "java.security", "javax.management" ]
java.security; javax.management;
2,179,726
public int smnt(String dir) throws IOException { return sendCommand(FTPCmd.SMNT, dir); }
int function(String dir) throws IOException { return sendCommand(FTPCmd.SMNT, dir); }
/*** * A convenience method to send the FTP SMNT command to the server, * receive the reply, and return the reply code. * * @param dir The directory name. * @return The reply code received from the server. * @throws FTPConnectionClosedException * If the FTP server prematurely cl...
A convenience method to send the FTP SMNT command to the server, receive the reply, and return the reply code
smnt
{ "repo_name": "grtlinux/KIEA_JAVA7", "path": "KIEA_JAVA7/src/tain/kr/com/commons/net/v01/ftp/FTP.java", "license": "gpl-3.0", "size": 77693 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,518,720
public void setRound(@Nonnull Round round) { this.round = round; }
void function(@Nonnull Round round) { this.round = round; }
/** * Sets the round associated with the event. * * @param round * The round. */
Sets the round associated with the event
setRound
{ "repo_name": "SiphonSquirrel/jepperscore", "path": "dao/src/main/java/jepperscore/dao/model/Event.java", "license": "apache-2.0", "size": 4318 }
[ "javax.annotation.Nonnull" ]
import javax.annotation.Nonnull;
import javax.annotation.*;
[ "javax.annotation" ]
javax.annotation;
93,205
public void testDefaultsToClassTransactionAttribute() throws Exception { Method method = TestBean.class.getMethod("getAge", (Class[]) null); TransactionAttribute txAtt = new DefaultTransactionAttribute(); MapAttributes ma = new MapAttributes(); AttributesTransactionAttributeSource atas = new Attributes...
void function() throws Exception { Method method = TestBean.class.getMethod(STR, (Class[]) null); TransactionAttribute txAtt = new DefaultTransactionAttribute(); MapAttributes ma = new MapAttributes(); AttributesTransactionAttributeSource atas = new AttributesTransactionAttributeSource(ma); ma.register(TestBean.class, ...
/** * Test that transaction attribute is inherited from class * if not specified on method. */
Test that transaction attribute is inherited from class if not specified on method
testDefaultsToClassTransactionAttribute
{ "repo_name": "codeApeFromChina/resource", "path": "frame_packages/java_libs/spring-2.5.6-src/test/org/springframework/transaction/interceptor/CommonsAttributesTransactionAttributeSourceTests.java", "license": "unlicense", "size": 9078 }
[ "java.lang.reflect.Method", "org.springframework.beans.TestBean", "org.springframework.metadata.support.MapAttributes" ]
import java.lang.reflect.Method; import org.springframework.beans.TestBean; import org.springframework.metadata.support.MapAttributes;
import java.lang.reflect.*; import org.springframework.beans.*; import org.springframework.metadata.support.*;
[ "java.lang", "org.springframework.beans", "org.springframework.metadata" ]
java.lang; org.springframework.beans; org.springframework.metadata;
666,259
boolean reclaimValue(K key, int hash, ValueReference<K, V> valueReference) { lock(); try { int newCount = this.count - 1; AtomicReferenceArray<ReferenceEntry<K, V>> table = this.table; int index = hash & (table.length() - 1); ReferenceEntry<K, V> first = table.get(index);...
boolean reclaimValue(K key, int hash, ValueReference<K, V> valueReference) { lock(); try { int newCount = this.count - 1; AtomicReferenceArray<ReferenceEntry<K, V>> table = this.table; int index = hash & (table.length() - 1); ReferenceEntry<K, V> first = table.get(index); for (ReferenceEntry<K, V> e = first; e != null;...
/** * Removes an entry whose value has been garbage collected. */
Removes an entry whose value has been garbage collected
reclaimValue
{ "repo_name": "DavesMan/guava", "path": "guava/src/com/google/common/cache/LocalCache.java", "license": "apache-2.0", "size": 153965 }
[ "java.util.concurrent.atomic.AtomicReferenceArray" ]
import java.util.concurrent.atomic.AtomicReferenceArray;
import java.util.concurrent.atomic.*;
[ "java.util" ]
java.util;
21,977
public int showCancelableIntent( PendingIntent intent, IntentCallback callback, Integer errorId) { Log.d(TAG, "Can't show intent as context is not an Activity: " + intent); return START_INTENT_FAILURE; }
int function( PendingIntent intent, IntentCallback callback, Integer errorId) { Log.d(TAG, STR + intent); return START_INTENT_FAILURE; }
/** * Shows an intent that could be canceled and returns the results to the callback object. * @param intent The PendingIntent that needs to be shown. * @param callback The object that will receive the results for the intent. * @param errorId The ID of error string to be show if activity is pa...
Shows an intent that could be canceled and returns the results to the callback object
showCancelableIntent
{ "repo_name": "hujiajie/chromium-crosswalk", "path": "ui/android/java/src/org/chromium/ui/base/WindowAndroid.java", "license": "bsd-3-clause", "size": 25998 }
[ "android.app.PendingIntent", "android.util.Log" ]
import android.app.PendingIntent; import android.util.Log;
import android.app.*; import android.util.*;
[ "android.app", "android.util" ]
android.app; android.util;
1,632,851
public void setAxisLinePaint(Paint paint) { ParamChecks.nullNotPermitted(paint, "paint"); this.axisLinePaint = paint; fireChangeEvent(); }
void function(Paint paint) { ParamChecks.nullNotPermitted(paint, "paint"); this.axisLinePaint = paint; fireChangeEvent(); }
/** * Sets the paint used to draw the axis line and sends an * {@link AxisChangeEvent} to all registered listeners. * * @param paint the paint (<code>null</code> not permitted). * * @see #getAxisLinePaint() */
Sets the paint used to draw the axis line and sends an <code>AxisChangeEvent</code> to all registered listeners
setAxisLinePaint
{ "repo_name": "Epsilon2/Memetic-Algorithm-for-TSP", "path": "jfreechart-1.0.16/source/org/jfree/chart/axis/Axis.java", "license": "mit", "size": 58723 }
[ "java.awt.Paint", "org.jfree.chart.util.ParamChecks" ]
import java.awt.Paint; import org.jfree.chart.util.ParamChecks;
import java.awt.*; import org.jfree.chart.util.*;
[ "java.awt", "org.jfree.chart" ]
java.awt; org.jfree.chart;
2,080,270
public KualiDecimal getTotalApplied() { KualiDecimal amount = KualiDecimal.ZERO; amount = amount.add(getSumOfInvoicePaidApplieds()); amount = amount.add(getSumOfNonInvoiceds()); amount = amount.add(getNonAppliedHoldingAmount()); return amount; }
KualiDecimal function() { KualiDecimal amount = KualiDecimal.ZERO; amount = amount.add(getSumOfInvoicePaidApplieds()); amount = amount.add(getSumOfNonInvoiceds()); amount = amount.add(getNonAppliedHoldingAmount()); return amount; }
/** * This method returns the total amount allocated against the cash control total. * * @return */
This method returns the total amount allocated against the cash control total
getTotalApplied
{ "repo_name": "quikkian-ua-devops/will-financials", "path": "kfs-ar/src/main/java/org/kuali/kfs/module/ar/document/PaymentApplicationDocument.java", "license": "agpl-3.0", "size": 79628 }
[ "org.kuali.rice.core.api.util.type.KualiDecimal" ]
import org.kuali.rice.core.api.util.type.KualiDecimal;
import org.kuali.rice.core.api.util.type.*;
[ "org.kuali.rice" ]
org.kuali.rice;
2,666,322
public static void grant(AccessControlService.BlockingInterface protocol, String userShortName, Permission.Action... actions) throws ServiceException { List<AccessControlProtos.Permission.Action> permActions = Lists.newArrayListWithCapacity(actions.length); for (Permission.Action a : actions) { ...
static void function(AccessControlService.BlockingInterface protocol, String userShortName, Permission.Action... actions) throws ServiceException { List<AccessControlProtos.Permission.Action> permActions = Lists.newArrayListWithCapacity(actions.length); for (Permission.Action a : actions) { permActions.add(ProtobufUtil...
/** * A utility used to grant a user global permissions. * <p> * It's also called by the shell, in case you want to find references. * * @param protocol the AccessControlService protocol proxy * @param userShortName the short name of the user to grant permissions * @param actions the permissions to...
A utility used to grant a user global permissions. It's also called by the shell, in case you want to find references
grant
{ "repo_name": "lshmouse/hbase", "path": "hbase-client/src/main/java/org/apache/hadoop/hbase/protobuf/ProtobufUtil.java", "license": "apache-2.0", "size": 118965 }
[ "com.google.common.collect.Lists", "com.google.protobuf.ServiceException", "java.util.List", "org.apache.hadoop.hbase.protobuf.generated.AccessControlProtos", "org.apache.hadoop.hbase.security.access.Permission" ]
import com.google.common.collect.Lists; import com.google.protobuf.ServiceException; import java.util.List; import org.apache.hadoop.hbase.protobuf.generated.AccessControlProtos; import org.apache.hadoop.hbase.security.access.Permission;
import com.google.common.collect.*; import com.google.protobuf.*; import java.util.*; import org.apache.hadoop.hbase.protobuf.generated.*; import org.apache.hadoop.hbase.security.access.*;
[ "com.google.common", "com.google.protobuf", "java.util", "org.apache.hadoop" ]
com.google.common; com.google.protobuf; java.util; org.apache.hadoop;
186,490
@ApiModelProperty(value = "") public List<String> getTargets() { return targets; }
@ApiModelProperty(value = "") List<String> function() { return targets; }
/** * Get targets * @return targets **/
Get targets
getTargets
{ "repo_name": "rswijesena/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.rest.api.publisher/src/gen/java/org/wso2/carbon/apimgt/rest/api/publisher/dto/LifecycleState_checkItemBeanListDTO.java", "license": "apache-2.0", "size": 5514 }
[ "io.swagger.annotations.ApiModelProperty", "java.util.List" ]
import io.swagger.annotations.ApiModelProperty; import java.util.List;
import io.swagger.annotations.*; import java.util.*;
[ "io.swagger.annotations", "java.util" ]
io.swagger.annotations; java.util;
1,548,527
switch (section) { case AutofillDialogConstants.SECTION_CC : return R.id.cc_spinner; case AutofillDialogConstants.SECTION_CC_BILLING : return R.id.cc_billing_spinner; case AutofillDialogConstants.SECTION_SHIPPING : return R.id.address_s...
switch (section) { case AutofillDialogConstants.SECTION_CC : return R.id.cc_spinner; case AutofillDialogConstants.SECTION_CC_BILLING : return R.id.cc_billing_spinner; case AutofillDialogConstants.SECTION_SHIPPING : return R.id.address_spinner; case AutofillDialogConstants.SECTION_BILLING : return R.id.billing_spinner; ...
/** * Returns the {@link Spinner} ID for the given section in the AutofillDialog * layout * @param section The section to return the spinner ID for. * @return The Android ID for the spinner dropdown for the given section. */
Returns the <code>Spinner</code> ID for the given section in the AutofillDialog layout
getSpinnerIDForSection
{ "repo_name": "plxaye/chromium", "path": "src/chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillDialogUtils.java", "license": "apache-2.0", "size": 10124 }
[ "org.chromium.chrome.browser.autofill.AutofillDialogConstants" ]
import org.chromium.chrome.browser.autofill.AutofillDialogConstants;
import org.chromium.chrome.browser.autofill.*;
[ "org.chromium.chrome" ]
org.chromium.chrome;
1,770,634
protected void assureSystemProperties() throws MojoExecutionException { // explicitly specify SDK root, as auto-discovery fails when // appengine-tools-api.jar is loaded from Maven repo, not SDK String sdk = System.getProperty("appengine.sdk.root"); if (sdk == null) { if (sdkDir == null) { throw new M...
void function() throws MojoExecutionException { String sdk = System.getProperty(STR); if (sdk == null) { if (sdkDir == null) { throw new MojoExecutionException(this, STR, gaeProperties .getProperty(STR)); } System.setProperty(STR, sdk = sdkDir); } if (!new File(sdk).isDirectory()) { throw new MojoExecutionException(thi...
/** * Groups alterations to System properties for the proper execution of the * actual GAE code. * * @throws MojoExecutionException * When the gae.home variable cannot be set. */
Groups alterations to System properties for the proper execution of the actual GAE code
assureSystemProperties
{ "repo_name": "phuongnd08/maven-geaForTest-plugin", "path": "src/main/java/org/seamoo/gaeForTest/EngineGoalBase.java", "license": "apache-2.0", "size": 7468 }
[ "java.io.File", "org.apache.maven.plugin.MojoExecutionException" ]
import java.io.File; import org.apache.maven.plugin.MojoExecutionException;
import java.io.*; import org.apache.maven.plugin.*;
[ "java.io", "org.apache.maven" ]
java.io; org.apache.maven;
58,078
@Test public void matrixTest2() { Dataset v = Random.rand(3); Dataset nz = Comparisons.nonZero(Comparisons.greaterThan(v, 0.5)).get(0); System.out.println("" + a.getByIndexes(null, nz)); }
void function() { Dataset v = Random.rand(3); Dataset nz = Comparisons.nonZero(Comparisons.greaterThan(v, 0.5)).get(0); System.out.println("" + a.getByIndexes(null, nz)); }
/**extract the columms of a where vector v > 0.5 a(:,find(v>0.5)) a[:,nonzero(v>0.5)[0]] a[:,nonzero(v.A>0.5)[0]] **/
extract the columms of a where vector v > 0.5
matrixTest2
{ "repo_name": "Anthchirp/dawnsci", "path": "org.eclipse.dawnsci.analysis.examples/src/org/eclipse/dawnsci/analysis/examples/dataset/NumpyExamples.java", "license": "epl-1.0", "size": 24495 }
[ "org.eclipse.dawnsci.analysis.dataset.impl.Comparisons", "org.eclipse.dawnsci.analysis.dataset.impl.Dataset", "org.eclipse.dawnsci.analysis.dataset.impl.Random" ]
import org.eclipse.dawnsci.analysis.dataset.impl.Comparisons; import org.eclipse.dawnsci.analysis.dataset.impl.Dataset; import org.eclipse.dawnsci.analysis.dataset.impl.Random;
import org.eclipse.dawnsci.analysis.dataset.impl.*;
[ "org.eclipse.dawnsci" ]
org.eclipse.dawnsci;
2,679,389
@Override public void removeTaskStatus(final JobId jobId) throws InterruptedException { taskStatuses.remove(jobId.toString()); }
void function(final JobId jobId) throws InterruptedException { taskStatuses.remove(jobId.toString()); }
/** * Remove the {@link TaskStatus} for the job identified by {@code jobId}. */
Remove the <code>TaskStatus</code> for the job identified by jobId
removeTaskStatus
{ "repo_name": "mavenraven/helios", "path": "helios-services/src/main/java/com/spotify/helios/agent/ZooKeeperAgentModel.java", "license": "apache-2.0", "size": 8625 }
[ "com.spotify.helios.common.descriptors.JobId" ]
import com.spotify.helios.common.descriptors.JobId;
import com.spotify.helios.common.descriptors.*;
[ "com.spotify.helios" ]
com.spotify.helios;
2,820,363
protected static boolean insertTreeNode(PO po) { // // services final IPOTreeSupportFactory treeSupportFactory = Services.get(IPOTreeSupportFactory.class); // TODO: check self contained tree final int AD_Table_ID = po.get_Table_ID(); if (!MTree.hasTree(AD_Table_ID)) { return false; } final ...
static boolean function(PO po) { final IPOTreeSupportFactory treeSupportFactory = Services.get(IPOTreeSupportFactory.class); final int AD_Table_ID = po.get_Table_ID(); if (!MTree.hasTree(AD_Table_ID)) { return false; } final int id = po.get_ID(); final int AD_Client_ID = po.getAD_Client_ID(); final String treeTableName...
/************************************************************************** * Insert id data into Tree * * @return true if inserted */
Insert id data into Tree
insertTreeNode
{ "repo_name": "klst-com/metasfresh", "path": "de.metas.adempiere.adempiere/base/src/main/java-legacy/org/compiere/model/MTree_Base.java", "license": "gpl-2.0", "size": 28656 }
[ "org.adempiere.model.tree.IPOTreeSupportFactory", "org.adempiere.model.tree.spi.IPOTreeSupport", "org.adempiere.util.Services", "org.slf4j.Logger" ]
import org.adempiere.model.tree.IPOTreeSupportFactory; import org.adempiere.model.tree.spi.IPOTreeSupport; import org.adempiere.util.Services; import org.slf4j.Logger;
import org.adempiere.model.tree.*; import org.adempiere.model.tree.spi.*; import org.adempiere.util.*; import org.slf4j.*;
[ "org.adempiere.model", "org.adempiere.util", "org.slf4j" ]
org.adempiere.model; org.adempiere.util; org.slf4j;
948,517
private InsightsContentDetail countTrendResult(List<InsightsKPIResultDetails> inferenceResults) { InsightsContentDetail inferenceContentResult = null; Map<String, Object> resultValuesMap = new HashMap<>(); double resultValue = 0.0; try { long startTime = System.nanoTime(); ReportEngineEnum.KPISentiment...
InsightsContentDetail function(List<InsightsKPIResultDetails> inferenceResults) { InsightsContentDetail inferenceContentResult = null; Map<String, Object> resultValuesMap = new HashMap<>(); double resultValue = 0.0; try { long startTime = System.nanoTime(); ReportEngineEnum.KPISentiment sentiment = ReportEngineEnum.KPI...
/** * Process KPI result to create content text using count and precentage method * * @param inferenceResults * @return */
Process KPI result to create content text using count and precentage method
countTrendResult
{ "repo_name": "CognizantOneDevOps/Insights", "path": "PlatformReports/src/main/java/com/cognizant/devops/platformreports/assessment/content/TrendCategoryImpl.java", "license": "apache-2.0", "size": 11573 }
[ "com.cognizant.devops.platformreports.assessment.datamodel.InsightsContentDetail", "com.cognizant.devops.platformreports.assessment.datamodel.InsightsKPIResultDetails", "com.cognizant.devops.platformreports.assessment.util.ReportEngineEnum", "com.cognizant.devops.platformreports.exception.InsightsJobFailedExc...
import com.cognizant.devops.platformreports.assessment.datamodel.InsightsContentDetail; import com.cognizant.devops.platformreports.assessment.datamodel.InsightsKPIResultDetails; import com.cognizant.devops.platformreports.assessment.util.ReportEngineEnum; import com.cognizant.devops.platformreports.exception.InsightsJ...
import com.cognizant.devops.platformreports.assessment.datamodel.*; import com.cognizant.devops.platformreports.assessment.util.*; import com.cognizant.devops.platformreports.exception.*; import java.util.*; import java.util.concurrent.*;
[ "com.cognizant.devops", "java.util" ]
com.cognizant.devops; java.util;
2,362,146
@Test public void testWrongCreation() { // Build not allowed string String wrongString = Strings.repeat("x", 1025); // Define expected exception exceptionWrongId.expect(IllegalArgumentException.class); // Create policer id PolicerId.policerId(wrongString); }
void function() { String wrongString = Strings.repeat("x", 1025); exceptionWrongId.expect(IllegalArgumentException.class); PolicerId.policerId(wrongString); }
/** * Test wrong creation of a policer id. */
Test wrong creation of a policer id
testWrongCreation
{ "repo_name": "gkatsikas/onos", "path": "core/api/src/test/java/org/onosproject/net/behaviour/trafficcontrol/PolicerIdTest.java", "license": "apache-2.0", "size": 4560 }
[ "com.google.common.base.Strings" ]
import com.google.common.base.Strings;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
1,166,765
public List<String> getCustomFeaturesList() { return customFeatures; }
List<String> function() { return customFeatures; }
/** * A list of features enabled when the selected profile is CUSTOM. The - method returns the set of * features that can be specified in this list. This field must be empty if the profile is not * CUSTOM. */
A list of features enabled when the selected profile is CUSTOM. The - method returns the set of features that can be specified in this list. This field must be empty if the profile is not CUSTOM
getCustomFeaturesList
{ "repo_name": "vam-google/google-cloud-java", "path": "google-cloud-clients/google-cloud-compute/src/main/java/com/google/cloud/compute/v1/SslPolicy.java", "license": "apache-2.0", "size": 21500 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
601,767
public static Process compile( final String command, final String[] env, final File outputFile, final File directory, final Action onSuccess, final Action onFailure, final MessageList compilationOutput, boolean synchronous) throws Exception { Pattern p = Pattern.c...
static Process function( final String command, final String[] env, final File outputFile, final File directory, final Action onSuccess, final Action onFailure, final MessageList compilationOutput, boolean synchronous) throws Exception { Pattern p = Pattern.compile(STR']+ \"[^\"]*\STR); Matcher m = p.matcher(command); A...
/** * Executes a Contiki compilation command. * * @param command Command * @param env (Optional) Environment. May be null. * @param outputFile Expected output. May be null. * @param directory Directory in which to execute command * @param onSuccess Action called if compilation succeeds * @param ...
Executes a Contiki compilation command
compile
{ "repo_name": "CaptFrank/Contiki-Sensor-Node", "path": "Contiki/contiki/tools/cooja/java/se/sics/cooja/dialogs/CompileContiki.java", "license": "gpl-2.0", "size": 20397 }
[ "java.io.File", "java.util.ArrayList", "java.util.regex.Matcher", "java.util.regex.Pattern", "javax.swing.Action" ]
import java.io.File; import java.util.ArrayList; import java.util.regex.Matcher; import java.util.regex.Pattern; import javax.swing.Action;
import java.io.*; import java.util.*; import java.util.regex.*; import javax.swing.*;
[ "java.io", "java.util", "javax.swing" ]
java.io; java.util; javax.swing;
272,743
public RectF getDestinyRect() { return mDstRect; }
RectF function() { return mDstRect; }
/** * Gets the rect that will take the scene when a Ken Burns transition ends. * @return the rect that ends the transition. */
Gets the rect that will take the scene when a Ken Burns transition ends
getDestinyRect
{ "repo_name": "Koteczeg/WarsawCityGame", "path": "WarsawCityGame/WarsawCityGames.App/src/main/java/com/warsawcitygame/Transitions/Transition.java", "license": "mit", "size": 3703 }
[ "android.graphics.RectF" ]
import android.graphics.RectF;
import android.graphics.*;
[ "android.graphics" ]
android.graphics;
402,478
@Test public void testPostMultipartSharedTextFileMimeTypeNotInAccepts() { ShareTargetBuilder shareTargetBuilder = new ShareTargetBuilder("/share.html"); shareTargetBuilder.setMethod(ShareTarget.METHOD_POST); shareTargetBuilder.setEncodingType(ShareTarget.ENCODING_TYPE_MULTIPART); ...
void function() { ShareTargetBuilder shareTargetBuilder = new ShareTargetBuilder(STR); shareTargetBuilder.setMethod(ShareTarget.METHOD_POST); shareTargetBuilder.setEncodingType(ShareTarget.ENCODING_TYPE_MULTIPART); shareTargetBuilder.addParamFile("name", new String[] {STRshare-textSTRtext-file-mock-uriSTRSTRtext/plain"...
/** * Test that when SHARE_PARAM_ACCEPTS doesn't accept text, but we receive a text file, and that * we don't receive shared text, that we send the text file as shared text. */
Test that when SHARE_PARAM_ACCEPTS doesn't accept text, but we receive a text file, and that we don't receive shared text, that we send the text file as shared text
testPostMultipartSharedTextFileMimeTypeNotInAccepts
{ "repo_name": "ric2b/Vivaldi-browser", "path": "chromium/chrome/android/junit/src/org/chromium/chrome/browser/webapps/WebApkShareTargetUtilTest.java", "license": "bsd-3-clause", "size": 22950 }
[ "androidx.browser.trusted.sharing.ShareTarget" ]
import androidx.browser.trusted.sharing.ShareTarget;
import androidx.browser.trusted.sharing.*;
[ "androidx.browser" ]
androidx.browser;
2,200,215
public void finishWrite(FileOutputStream stream) throws IOException { try { stream.close(); } catch (IOException e) { failWrite(stream); throw e; } if (!workFile.renameTo(activeFile)) { failWrite(stream); throw new IOExcept...
void function(FileOutputStream stream) throws IOException { try { stream.close(); } catch (IOException e) { failWrite(stream); throw e; } if (!workFile.renameTo(activeFile)) { failWrite(stream); throw new IOException(STR); } }
/** * Atomically replaces the active file with the work file, and closes the stream. * @param stream * @throws IOException */
Atomically replaces the active file with the work file, and closes the stream
finishWrite
{ "repo_name": "KevinSJ/dns66", "path": "app/src/main/java/org/jak_linux/dns66/SingleWriterMultipleReaderFile.java", "license": "gpl-3.0", "size": 3005 }
[ "java.io.FileOutputStream", "java.io.IOException" ]
import java.io.FileOutputStream; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,522,498
protected void parseColumnsAndConstraints( DdlTokenStream tokens, AstNode tableNode ) throws ParsingException { assert tokens != null; assert tableNode != null; if (!tokens.matches(L_PAREN)) { return; } String table...
void function( DdlTokenStream tokens, AstNode tableNode ) throws ParsingException { assert tokens != null; assert tableNode != null; if (!tokens.matches(L_PAREN)) { return; } String tableElementString = getTableElementsString(tokens, false); DdlTokenStream localTokens = new DdlTokenStream(tableElementString, DdlTokenSt...
/** * Utility method to parse columns and table constraints within either a CREATE TABLE statement. Method first parses and * copies the text enclosed within the bracketed "( xxxx )" statement. Then the individual column definition or table * constraint definition sub-statements are parsed assuming they...
Utility method to parse columns and table constraints within either a CREATE TABLE statement. Method first parses and copies the text enclosed within the bracketed "( xxxx )" statement. Then the individual column definition or table constraint definition sub-statements are parsed assuming they are comma delimited
parseColumnsAndConstraints
{ "repo_name": "okulikov/modeshape", "path": "sequencers/modeshape-sequencer-ddl/src/main/java/org/modeshape/sequencer/ddl/StandardDdlParser.java", "license": "apache-2.0", "size": 125381 }
[ "org.modeshape.common.text.ParsingException", "org.modeshape.common.text.Position", "org.modeshape.sequencer.ddl.node.AstNode" ]
import org.modeshape.common.text.ParsingException; import org.modeshape.common.text.Position; import org.modeshape.sequencer.ddl.node.AstNode;
import org.modeshape.common.text.*; import org.modeshape.sequencer.ddl.node.*;
[ "org.modeshape.common", "org.modeshape.sequencer" ]
org.modeshape.common; org.modeshape.sequencer;
158,985
static void annotateRxn(Reaction rxn, List<Interaction> interacts) { List<URI> interactIdentities = new LinkedList<URI>(); for (Interaction interact : interacts) interactIdentities.add(interact.getIdentity()); SBOLAnnotation rxnAnno = new SBOLAnnotation(rxn.getMetaId(), interacts.get(0).getClass()...
static void annotateRxn(Reaction rxn, List<Interaction> interacts) { List<URI> interactIdentities = new LinkedList<URI>(); for (Interaction interact : interacts) interactIdentities.add(interact.getIdentity()); SBOLAnnotation rxnAnno = new SBOLAnnotation(rxn.getMetaId(), interacts.get(0).getClass().getSimpleName(), inte...
/** * Annotate SBML reaction with a list of SBOL interactions. * * @param rxn - The SBML reaction to be annotated with SBOL interactions * @param interacts - The SBOL Interactions to be annotated into SBML reaction. */
Annotate SBML reaction with a list of SBOL interactions
annotateRxn
{ "repo_name": "MyersResearchGroup/iBioSim", "path": "conversion/src/main/java/edu/utah/ece/async/ibiosim/conversion/SBOL2SBML.java", "license": "apache-2.0", "size": 84633 }
[ "edu.utah.ece.async.ibiosim.dataModels.biomodel.annotation.AnnotationUtility", "edu.utah.ece.async.ibiosim.dataModels.biomodel.annotation.SBOLAnnotation", "java.util.LinkedList", "java.util.List", "org.sbml.jsbml.Reaction", "org.sbolstandard.core2.Interaction" ]
import edu.utah.ece.async.ibiosim.dataModels.biomodel.annotation.AnnotationUtility; import edu.utah.ece.async.ibiosim.dataModels.biomodel.annotation.SBOLAnnotation; import java.util.LinkedList; import java.util.List; import org.sbml.jsbml.Reaction; import org.sbolstandard.core2.Interaction;
import edu.utah.ece.async.ibiosim.*; import java.util.*; import org.sbml.jsbml.*; import org.sbolstandard.core2.*;
[ "edu.utah.ece", "java.util", "org.sbml.jsbml", "org.sbolstandard.core2" ]
edu.utah.ece; java.util; org.sbml.jsbml; org.sbolstandard.core2;
382,311
public Observable<Map<String, Object>> queryToKBase(final Object javaObject, final Object... params){ if (javaObject == null) throw new NullPointerException("A query must always be about something, querying null is not possible."); // temporarly disabled caching for debugging purposes //if (subjects.co...
Observable<Map<String, Object>> function(final Object javaObject, final Object... params){ if (javaObject == null) throw new NullPointerException(STR); final Subject<Map<String, Object>,Map<String, Object>> result; result = ReplaySubject.create(); Observer o = null; Formula query = null; try { query = JSAReasoningCapab...
/** * Observer for the queryResults * @param javaObject * @param params * @return */
Observer for the queryResults
queryToKBase
{ "repo_name": "krevelen/coala", "path": "coala-adapters/coala-jsa-adapter/src/main/java/io/coala/jsa/JSAReasoningCapability.java", "license": "apache-2.0", "size": 12585 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
1,473,238
public Query makeQuery(PathQuery pathQuery, Map<String, BagQueryResult> pathToBagQueryResult, Map<String, QuerySelectable> pathToQueryNode) throws ObjectStoreException { Map<String, InterMineBag> allBags = bagManager.getBags(profile); Query q = MainHelper.makeQuery(pathQuery, allBags, ...
Query function(PathQuery pathQuery, Map<String, BagQueryResult> pathToBagQueryResult, Map<String, QuerySelectable> pathToQueryNode) throws ObjectStoreException { Map<String, InterMineBag> allBags = bagManager.getBags(profile); Query q = MainHelper.makeQuery(pathQuery, allBags, pathToQueryNode, bagQueryRunner, pathToBag...
/** * Creates an IQL query from a PathQuery. * * @param pathQuery the query to convert * @param pathToBagQueryResult will be populated with results from bag queries used in any * LOOKUP constraints * @param pathToQueryNode a Map from String path in the PathQuery to QuerySelectable in the ...
Creates an IQL query from a PathQuery
makeQuery
{ "repo_name": "joshkh/intermine", "path": "intermine/api/main/src/org/intermine/api/query/WebResultsExecutor.java", "license": "lgpl-2.1", "size": 8123 }
[ "java.util.Map", "org.intermine.api.bag.BagQueryResult", "org.intermine.api.profile.InterMineBag", "org.intermine.objectstore.ObjectStoreException", "org.intermine.objectstore.query.Query", "org.intermine.objectstore.query.QuerySelectable", "org.intermine.pathquery.PathQuery" ]
import java.util.Map; import org.intermine.api.bag.BagQueryResult; import org.intermine.api.profile.InterMineBag; import org.intermine.objectstore.ObjectStoreException; import org.intermine.objectstore.query.Query; import org.intermine.objectstore.query.QuerySelectable; import org.intermine.pathquery.PathQuery;
import java.util.*; import org.intermine.api.bag.*; import org.intermine.api.profile.*; import org.intermine.objectstore.*; import org.intermine.objectstore.query.*; import org.intermine.pathquery.*;
[ "java.util", "org.intermine.api", "org.intermine.objectstore", "org.intermine.pathquery" ]
java.util; org.intermine.api; org.intermine.objectstore; org.intermine.pathquery;
1,052,955
@ApiModelProperty( example = "Foobar", value = "(NZ Only) Optional references for the batch payment transaction. It will also show with" + " the batch payment transaction in the bank reconciliation Find & Match screen." + " Depending on your individual bank, the detai...
@ApiModelProperty( example = STR, value = STR + STR + STR + STR) String function() { return reference; }
/** * (NZ Only) Optional references for the batch payment transaction. It will also show with the * batch payment transaction in the bank reconciliation Find &amp; Match screen. Depending on your * individual bank, the detail may also show on the bank statement you import into Xero. * * @return reference...
(NZ Only) Optional references for the batch payment transaction. It will also show with the batch payment transaction in the bank reconciliation Find &amp; Match screen. Depending on your individual bank, the detail may also show on the bank statement you import into Xero
getReference
{ "repo_name": "XeroAPI/Xero-Java", "path": "src/main/java/com/xero/models/accounting/BatchPaymentDetails.java", "license": "mit", "size": 10892 }
[ "io.swagger.annotations.ApiModelProperty" ]
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.*;
[ "io.swagger.annotations" ]
io.swagger.annotations;
2,083,257
public void createSubEntry(final CmsClientSitemapEntry parent, final CmsUUID structureId) { CmsSitemapTreeItem item = CmsSitemapTreeItem.getItemById(parent.getId()); AsyncCallback<CmsClientSitemapEntry> callback = new AsyncCallback<CmsClientSitemapEntry>() {
void function(final CmsClientSitemapEntry parent, final CmsUUID structureId) { CmsSitemapTreeItem item = CmsSitemapTreeItem.getItemById(parent.getId()); AsyncCallback<CmsClientSitemapEntry> callback = new AsyncCallback<CmsClientSitemapEntry>() {
/** * Creates a new sub-entry of an existing sitemap entry.<p> * * @param parent the entry to which a new sub-entry should be added * @param structureId the structure id of the model page (if null, uses default model page) */
Creates a new sub-entry of an existing sitemap entry
createSubEntry
{ "repo_name": "sbonoc/opencms-core", "path": "src-gwt/org/opencms/ade/sitemap/client/control/CmsSitemapController.java", "license": "lgpl-2.1", "size": 64474 }
[ "com.google.gwt.user.client.rpc.AsyncCallback", "org.opencms.ade.sitemap.client.CmsSitemapTreeItem", "org.opencms.ade.sitemap.shared.CmsClientSitemapEntry", "org.opencms.util.CmsUUID" ]
import com.google.gwt.user.client.rpc.AsyncCallback; import org.opencms.ade.sitemap.client.CmsSitemapTreeItem; import org.opencms.ade.sitemap.shared.CmsClientSitemapEntry; import org.opencms.util.CmsUUID;
import com.google.gwt.user.client.rpc.*; import org.opencms.ade.sitemap.client.*; import org.opencms.ade.sitemap.shared.*; import org.opencms.util.*;
[ "com.google.gwt", "org.opencms.ade", "org.opencms.util" ]
com.google.gwt; org.opencms.ade; org.opencms.util;
1,643,024
protected void ensureClusterStateConsistency() throws IOException { if (cluster() != null && cluster().size() > 0) { final NamedWriteableRegistry namedWriteableRegistry = cluster().getNamedWriteableRegistry(); final Client masterClient = client(); ClusterState masterClust...
void function() throws IOException { if (cluster() != null && cluster().size() > 0) { final NamedWriteableRegistry namedWriteableRegistry = cluster().getNamedWriteableRegistry(); final Client masterClient = client(); ClusterState masterClusterState = masterClient.admin().cluster().prepareState().all().get().getState();...
/** * Verifies that all nodes that have the same version of the cluster state as master have same cluster state */
Verifies that all nodes that have the same version of the cluster state as master have same cluster state
ensureClusterStateConsistency
{ "repo_name": "vroyer/elassandra", "path": "test/framework/src/main/java/org/elasticsearch/test/ESIntegTestCase.java", "license": "apache-2.0", "size": 110257 }
[ "java.io.IOException", "java.util.Map", "org.elasticsearch.client.Client", "org.elasticsearch.cluster.ClusterState", "org.elasticsearch.common.io.stream.NamedWriteableRegistry", "org.elasticsearch.test.XContentTestUtils" ]
import java.io.IOException; import java.util.Map; import org.elasticsearch.client.Client; import org.elasticsearch.cluster.ClusterState; import org.elasticsearch.common.io.stream.NamedWriteableRegistry; import org.elasticsearch.test.XContentTestUtils;
import java.io.*; import java.util.*; import org.elasticsearch.client.*; import org.elasticsearch.cluster.*; import org.elasticsearch.common.io.stream.*; import org.elasticsearch.test.*;
[ "java.io", "java.util", "org.elasticsearch.client", "org.elasticsearch.cluster", "org.elasticsearch.common", "org.elasticsearch.test" ]
java.io; java.util; org.elasticsearch.client; org.elasticsearch.cluster; org.elasticsearch.common; org.elasticsearch.test;
342,046
@Override public void initialize(AbstractSession session) throws DescriptorException { getMappedKeyMapContainerPolicy().setDescriptorForKeyMapping(this.getDescriptor()); if (getKeyConverter() != null) { getKeyConverter().initialize(this, session); } super.initialize(s...
void function(AbstractSession session) throws DescriptorException { getMappedKeyMapContainerPolicy().setDescriptorForKeyMapping(this.getDescriptor()); if (getKeyConverter() != null) { getKeyConverter().initialize(this, session); } super.initialize(session); }
/** * INTERNAL: * Initialize and validate the mapping properties. */
Initialize and validate the mapping properties
initialize
{ "repo_name": "RallySoftware/eclipselink.runtime", "path": "foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/mappings/DirectMapMapping.java", "license": "epl-1.0", "size": 56004 }
[ "org.eclipse.persistence.exceptions.DescriptorException", "org.eclipse.persistence.internal.sessions.AbstractSession" ]
import org.eclipse.persistence.exceptions.DescriptorException; import org.eclipse.persistence.internal.sessions.AbstractSession;
import org.eclipse.persistence.exceptions.*; import org.eclipse.persistence.internal.sessions.*;
[ "org.eclipse.persistence" ]
org.eclipse.persistence;
920,918
public WallEditQuery edit(UserActor actor, int postId) { return new WallEditQuery(getClient(), actor, postId); }
WallEditQuery function(UserActor actor, int postId) { return new WallEditQuery(getClient(), actor, postId); }
/** * Edits a post on a user wall or community wall. * * @param actor vk actor * @param postId * @return query */
Edits a post on a user wall or community wall
edit
{ "repo_name": "VKCOM/vk-java-sdk", "path": "sdk/src/main/java/com/vk/api/sdk/actions/Wall.java", "license": "mit", "size": 17618 }
[ "com.vk.api.sdk.client.actors.UserActor", "com.vk.api.sdk.queries.wall.WallEditQuery" ]
import com.vk.api.sdk.client.actors.UserActor; import com.vk.api.sdk.queries.wall.WallEditQuery;
import com.vk.api.sdk.client.actors.*; import com.vk.api.sdk.queries.wall.*;
[ "com.vk.api" ]
com.vk.api;
1,433,501
public Object post(Map<String, Object> args) throws Exception;
Object function(Map<String, Object> args) throws Exception;
/** * execute post * @param args * @return * @throws Exception */
execute post
post
{ "repo_name": "classfoo/onyx", "path": "org.classfoo.onyx/src/main/java/org/classfoo/onyx/api/web/OnyxApi.java", "license": "gpl-3.0", "size": 1732 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
1,341,707
@Test public void ifAddTaskAndSetDescriptionCompareItWithExpected() { Tracker tracker = new Tracker(new ConsoleInput("task1\nsome desc\ntask1\ndescription")); tracker.new AddTask().action(); tracker.new AddCommentToTask().action(); tracker.getTaskManager().getAllTasks()[0].getCom...
void function() { Tracker tracker = new Tracker(new ConsoleInput(STR)); tracker.new AddTask().action(); tracker.new AddCommentToTask().action(); tracker.getTaskManager().getAllTasks()[0].getComments()[0].setDescription(STR); assertThat(STR, is(equalTo(tracker.getTaskManager().getAllTasks()[0].getComments()[0].getDescri...
/** * Add task to tracker, add comment and compare description of comment with expected. * */
Add task to tracker, add comment and compare description of comment with expected
ifAddTaskAndSetDescriptionCompareItWithExpected
{ "repo_name": "kuznetsovsergeyymailcom/homework", "path": "chapter_002/tracker/src/test/java/ru/skuznetsov/TrackerTest.java", "license": "apache-2.0", "size": 10439 }
[ "org.hamcrest.MatcherAssert", "org.hamcrest.Matchers", "ru.skuznetsov.input.ConsoleInput" ]
import org.hamcrest.MatcherAssert; import org.hamcrest.Matchers; import ru.skuznetsov.input.ConsoleInput;
import org.hamcrest.*; import ru.skuznetsov.input.*;
[ "org.hamcrest", "ru.skuznetsov.input" ]
org.hamcrest; ru.skuznetsov.input;
1,309,448
private void commitPrepared(Xid xid) throws XAException { try { // Check preconditions. The connection mustn't be used for another // other XA or local transaction, or the COMMIT PREPARED command // would mess it up. if (state != State.IDLE || conn.getTransactionState() != Transa...
void function(Xid xid) throws XAException { try { if (state != State.IDLE conn.getTransactionState() != TransactionState.IDLE) { throw new PGXAException( GT.tr(STR, xid, currentXid, state, conn.getTransactionState()), XAException.XAER_RMERR); } String s = RecoveredXid.xidToString(xid); localAutoCommitMode = conn.getAut...
/** * <p>Commits prepared transaction. Preconditions:</p> * <ol> * <li>xid must be in prepared state in the server</li> * </ol> * * <p>Implementation deficiency preconditions:</p> * <ol> * <li>Connection must be in idle state</li> * </ol> * * <p>Postconditions:</p> * <ol> ...
Commits prepared transaction. Preconditions: xid must be in prepared state in the server Implementation deficiency preconditions: Connection must be in idle state Postconditions: Transaction is committed
commitPrepared
{ "repo_name": "AlexElin/pgjdbc", "path": "pgjdbc/src/main/java/org/postgresql/xa/PGXAConnection.java", "license": "bsd-2-clause", "size": 23958 }
[ "java.sql.SQLException", "java.sql.Statement", "java.util.logging.Level", "javax.transaction.xa.XAException", "javax.transaction.xa.Xid", "org.postgresql.core.TransactionState", "org.postgresql.util.GT", "org.postgresql.util.PSQLState" ]
import java.sql.SQLException; import java.sql.Statement; import java.util.logging.Level; import javax.transaction.xa.XAException; import javax.transaction.xa.Xid; import org.postgresql.core.TransactionState; import org.postgresql.util.GT; import org.postgresql.util.PSQLState;
import java.sql.*; import java.util.logging.*; import javax.transaction.xa.*; import org.postgresql.core.*; import org.postgresql.util.*;
[ "java.sql", "java.util", "javax.transaction", "org.postgresql.core", "org.postgresql.util" ]
java.sql; java.util; javax.transaction; org.postgresql.core; org.postgresql.util;
2,433,308
@Override public Var evalVar(Env env) { Value value = _expr.evalVar(env); value = value.toAutoArray(); return value.getVar(_index.eval(env)); }
Var function(Env env) { Value value = _expr.evalVar(env); value = value.toAutoArray(); return value.getVar(_index.eval(env)); }
/** * Evaluates the expression. * * @param env the calling environment. * * @return the expression value. */
Evaluates the expression
evalVar
{ "repo_name": "christianchristensen/resin", "path": "modules/quercus/src/com/caucho/quercus/expr/ArrayGetExpr.java", "license": "gpl-2.0", "size": 5257 }
[ "com.caucho.quercus.env.Env", "com.caucho.quercus.env.Value", "com.caucho.quercus.env.Var" ]
import com.caucho.quercus.env.Env; import com.caucho.quercus.env.Value; import com.caucho.quercus.env.Var;
import com.caucho.quercus.env.*;
[ "com.caucho.quercus" ]
com.caucho.quercus;
313,259
private ArrayList getAncestors(IJavaElement element) { ArrayList parents = new ArrayList(); IJavaElement parent = element.getParent(); while (parent != null) { parents.add(parent); parent = parent.getParent(); } parents.trimToSize(); return parents; }
ArrayList function(IJavaElement element) { ArrayList parents = new ArrayList(); IJavaElement parent = element.getParent(); while (parent != null) { parents.add(parent); parent = parent.getParent(); } parents.trimToSize(); return parents; }
/** * Returns a collection of all the parents of this element * in bottom-up order. * */
Returns a collection of all the parents of this element in bottom-up order
getAncestors
{ "repo_name": "trylimits/Eclipse-Postfix-Code-Completion-Juno38", "path": "juno38/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/Region.java", "license": "epl-1.0", "size": 3785 }
[ "java.util.ArrayList", "org.eclipse.jdt.core.IJavaElement" ]
import java.util.ArrayList; import org.eclipse.jdt.core.IJavaElement;
import java.util.*; import org.eclipse.jdt.core.*;
[ "java.util", "org.eclipse.jdt" ]
java.util; org.eclipse.jdt;
2,503,023
public void removeLifecycleListener(LifecycleListener listener) { lifecycle.removeLifecycleListener(listener); }
void function(LifecycleListener listener) { lifecycle.removeLifecycleListener(listener); }
/** * Remove a lifecycle event listener from this component. * * @param listener The listener to remove */
Remove a lifecycle event listener from this component
removeLifecycleListener
{ "repo_name": "devjin24/howtomcatworks", "path": "bookrefer/jakarta-tomcat-4.1.12-src/catalina/src/share/org/apache/catalina/core/ContainerBase.java", "license": "apache-2.0", "size": 44660 }
[ "org.apache.catalina.LifecycleListener" ]
import org.apache.catalina.LifecycleListener;
import org.apache.catalina.*;
[ "org.apache.catalina" ]
org.apache.catalina;
2,070,219
Iterable<Tag> httpRequestTags(RequestEvent event);
Iterable<Tag> httpRequestTags(RequestEvent event);
/** * Provides tags to be associated with metrics for the given {@code event}. * * @param event * the request event * @return tags to associate with metrics recorded for the request */
Provides tags to be associated with metrics for the given event
httpRequestTags
{ "repo_name": "micrometer-metrics/micrometer", "path": "micrometer-binders/src/main/java/io/micrometer/binder/jersey/server/JerseyTagsProvider.java", "license": "apache-2.0", "size": 1559 }
[ "io.micrometer.core.instrument.Tag", "org.glassfish.jersey.server.monitoring.RequestEvent" ]
import io.micrometer.core.instrument.Tag; import org.glassfish.jersey.server.monitoring.RequestEvent;
import io.micrometer.core.instrument.*; import org.glassfish.jersey.server.monitoring.*;
[ "io.micrometer.core", "org.glassfish.jersey" ]
io.micrometer.core; org.glassfish.jersey;
341,209
Collection<Spec> getSpecs(SpecSearchObject specSearchObject) throws IOException;
Collection<Spec> getSpecs(SpecSearchObject specSearchObject) throws IOException;
/*** * Retrieve {@link Spec}s by {@link SpecSearchObject} from the {@link SpecStore}. * @param specSearchObject {@link SpecSearchObject} for the {@link Spec} to be retrieved. * @throws IOException Exception in retrieving the {@link Spec}. */
Retrieve <code>Spec</code>s by <code>SpecSearchObject</code> from the <code>SpecStore</code>
getSpecs
{ "repo_name": "arjun4084346/gobblin", "path": "gobblin-runtime/src/main/java/org/apache/gobblin/runtime/api/SpecStore.java", "license": "apache-2.0", "size": 5944 }
[ "java.io.IOException", "java.util.Collection" ]
import java.io.IOException; import java.util.Collection;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
1,898,185
JMeterContext context = getThreadContext(); JMeterVariables vars = context.getVariables(); SampleResult previousResult = context.getPreviousResult(); ByteArrayInputStream resultStream = new ByteArrayInputStream(previousResult.getResponseData()); vars.put(histogramNbytes, Integer.toString(previousResult....
JMeterContext context = getThreadContext(); JMeterVariables vars = context.getVariables(); SampleResult previousResult = context.getPreviousResult(); ByteArrayInputStream resultStream = new ByteArrayInputStream(previousResult.getResponseData()); vars.put(histogramNbytes, Integer.toString(previousResult.getBytes())); Bu...
/** * Grabs an image from a sampler and generates a histogram using * JAI. Then it writes all the histogram data into variables. */
Grabs an image from a sampler and generates a histogram using JAI. Then it writes all the histogram data into variables
process
{ "repo_name": "FlyingRhenquest/JmeterHistogram", "path": "src/main/java/com/flyingrhenquest/JmeterHistogram/JmeterHistogram.java", "license": "apache-2.0", "size": 5829 }
[ "java.awt.image.BufferedImage", "java.awt.image.renderable.ParameterBlock", "java.io.ByteArrayInputStream", "javax.imageio.ImageIO", "javax.media.jai.Histogram", "javax.media.jai.JAI", "javax.media.jai.RenderedOp", "org.apache.jmeter.samplers.SampleResult", "org.apache.jmeter.threads.JMeterContext",...
import java.awt.image.BufferedImage; import java.awt.image.renderable.ParameterBlock; import java.io.ByteArrayInputStream; import javax.imageio.ImageIO; import javax.media.jai.Histogram; import javax.media.jai.JAI; import javax.media.jai.RenderedOp; import org.apache.jmeter.samplers.SampleResult; import org.apache.jmet...
import java.awt.image.*; import java.awt.image.renderable.*; import java.io.*; import javax.imageio.*; import javax.media.jai.*; import org.apache.jmeter.samplers.*; import org.apache.jmeter.threads.*;
[ "java.awt", "java.io", "javax.imageio", "javax.media", "org.apache.jmeter" ]
java.awt; java.io; javax.imageio; javax.media; org.apache.jmeter;
124,296
@Deprecated public ServerBuilder port(int port, String protocol) { return port(port, SessionProtocol.of(requireNonNull(protocol, "protocol"))); }
ServerBuilder function(int port, String protocol) { return port(port, SessionProtocol.of(requireNonNull(protocol, STR))); }
/** * Adds a new {@link ServerPort} that listens to the specified {@code port} of all available network * interfaces using the specified protocol. * * @deprecated Use {@link #http(int)} or {@link #https(int)}. * @see <a href="#no_port_specified">What happens if no HTTP(S) port is specified?</a>...
Adds a new <code>ServerPort</code> that listens to the specified port of all available network interfaces using the specified protocol
port
{ "repo_name": "jmostella/armeria", "path": "core/src/main/java/com/linecorp/armeria/server/ServerBuilder.java", "license": "apache-2.0", "size": 48086 }
[ "com.linecorp.armeria.common.SessionProtocol" ]
import com.linecorp.armeria.common.SessionProtocol;
import com.linecorp.armeria.common.*;
[ "com.linecorp.armeria" ]
com.linecorp.armeria;
2,111,740
private HttpResponse ingestAclString(final String resourcePath, final String acl, final String username) throws IOException { final String aclPath = (resourcePath.endsWith("/fcr:acl") ? resourcePath : resourcePath + "/fcr:acl"); final HttpPut putReq = new HttpPut(aclPath); setAut...
HttpResponse function(final String resourcePath, final String acl, final String username) throws IOException { final String aclPath = (resourcePath.endsWith(STR) ? resourcePath : resourcePath + STR); final HttpPut putReq = new HttpPut(aclPath); setAuth(putReq, username); putReq.setHeader(STR, STR); putReq.setEntity(new...
/** * Utility function to ingest a ACL from a string. * * @param resourcePath Path to the resource if doesn't end with "/fcr:acl" it is added. * @param acl the text/turtle ACL as a string * @param username user to ingest as * @return the response from the ACL ingest. * @throws IOExcep...
Utility function to ingest a ACL from a string
ingestAclString
{ "repo_name": "robyj/fcrepo4", "path": "fcrepo-auth-webac/src/test/java/org/fcrepo/integration/auth/webac/WebACRecipesIT.java", "license": "apache-2.0", "size": 104885 }
[ "java.io.IOException", "org.apache.http.HttpResponse", "org.apache.http.client.methods.HttpPut", "org.apache.http.entity.StringEntity" ]
import java.io.IOException; import org.apache.http.HttpResponse; import org.apache.http.client.methods.HttpPut; import org.apache.http.entity.StringEntity;
import java.io.*; import org.apache.http.*; import org.apache.http.client.methods.*; import org.apache.http.entity.*;
[ "java.io", "org.apache.http" ]
java.io; org.apache.http;
818,495
public String getContentType(String outputFormat) { return servicesConfiguration.getExporter(outputFormat.toLowerCase()).getContentType(); } protected class RunReportUnitStrategy extends GenericRunReportStrategy<ReportUnit> {
String function(String outputFormat) { return servicesConfiguration.getExporter(outputFormat.toLowerCase()).getContentType(); } protected class RunReportUnitStrategy extends GenericRunReportStrategy<ReportUnit> {
/** * Get content type for resource type. * * @param outputFormat - resource output format * @return content type */
Get content type for resource type
getContentType
{ "repo_name": "leocockroach/JasperServer5.6", "path": "jasperserver-remote/src/main/java/com/jaspersoft/jasperserver/remote/services/impl/ReportExecutorImpl.java", "license": "gpl-2.0", "size": 17774 }
[ "com.jaspersoft.jasperserver.api.metadata.jasperreports.domain.ReportUnit" ]
import com.jaspersoft.jasperserver.api.metadata.jasperreports.domain.ReportUnit;
import com.jaspersoft.jasperserver.api.metadata.jasperreports.domain.*;
[ "com.jaspersoft.jasperserver" ]
com.jaspersoft.jasperserver;
1,656,528
public InterceptFromDefinition interceptFrom() { if (!getRouteCollection().getRoutes().isEmpty()) { throw new IllegalArgumentException("interceptFrom must be defined before any routes in the RouteBuilder"); } getRouteCollection().setCamelContext(getContext()); return getR...
InterceptFromDefinition function() { if (!getRouteCollection().getRoutes().isEmpty()) { throw new IllegalArgumentException(STR); } getRouteCollection().setCamelContext(getContext()); return getRouteCollection().interceptFrom(); }
/** * Adds a route for an interceptor that intercepts incoming messages on any inputs in this route * * @return the builder */
Adds a route for an interceptor that intercepts incoming messages on any inputs in this route
interceptFrom
{ "repo_name": "punkhorn/camel-upstream", "path": "core/camel-core/src/main/java/org/apache/camel/builder/RouteBuilder.java", "license": "apache-2.0", "size": 19978 }
[ "org.apache.camel.model.InterceptFromDefinition" ]
import org.apache.camel.model.InterceptFromDefinition;
import org.apache.camel.model.*;
[ "org.apache.camel" ]
org.apache.camel;
1,711,546
private boolean delete(FTPClient client, Path file, boolean recursive) throws IOException { Path workDir = new Path(client.printWorkingDirectory()); Path absolute = makeAbsolute(workDir, file); String pathName = absolute.toUri().getPath(); FileStatus fileStat = getFileStatus(client, absolute); if (!file...
boolean function(FTPClient client, Path file, boolean recursive) throws IOException { Path workDir = new Path(client.printWorkingDirectory()); Path absolute = makeAbsolute(workDir, file); String pathName = absolute.toUri().getPath(); FileStatus fileStat = getFileStatus(client, absolute); if (!fileStat.isDir()) { return...
/** * Convenience method, so that we don't open a new connection when using * this method from within another method. Otherwise every API invocation * incurs the overhead of opening/closing a TCP connection. */
Convenience method, so that we don't open a new connection when using this method from within another method. Otherwise every API invocation incurs the overhead of opening/closing a TCP connection
delete
{ "repo_name": "shot/hadoop-source-reading", "path": "src/core/org/apache/hadoop/fs/ftp/FTPFileSystem.java", "license": "apache-2.0", "size": 19410 }
[ "java.io.IOException", "org.apache.commons.net.ftp.FTPClient", "org.apache.hadoop.fs.FileStatus", "org.apache.hadoop.fs.Path" ]
import java.io.IOException; import org.apache.commons.net.ftp.FTPClient; import org.apache.hadoop.fs.FileStatus; import org.apache.hadoop.fs.Path;
import java.io.*; import org.apache.commons.net.ftp.*; import org.apache.hadoop.fs.*;
[ "java.io", "org.apache.commons", "org.apache.hadoop" ]
java.io; org.apache.commons; org.apache.hadoop;
2,405,098
@Test public void testRun5() throws Exception { blockingQueue = new ArrayBlockingQueue(5); channel = EasyMock.createMock(Channel.class); ospfArea = new OspfAreaImpl(); lsaWrapper = new LsaWrapperImpl(); routerLsa = new RouterLsa(); routerLsa.setLsType(2); ...
void function() throws Exception { blockingQueue = new ArrayBlockingQueue(5); channel = EasyMock.createMock(Channel.class); ospfArea = new OspfAreaImpl(); lsaWrapper = new LsaWrapperImpl(); routerLsa = new RouterLsa(); routerLsa.setLsType(2); lsaWrapper.addLsa(OspfLsaType.NETWORK, routerLsa); ospfInterface = new OspfIn...
/** * Tests run() method. */
Tests run() method
testRun5
{ "repo_name": "sonu283304/onos", "path": "protocols/ospf/ctl/src/test/java/org/onosproject/ospf/controller/lsdb/LsaQueueConsumerTest.java", "license": "apache-2.0", "size": 6433 }
[ "java.util.concurrent.ArrayBlockingQueue", "org.easymock.EasyMock", "org.hamcrest.CoreMatchers", "org.hamcrest.MatcherAssert", "org.jboss.netty.channel.Channel", "org.onosproject.ospf.controller.OspfLsaType", "org.onosproject.ospf.controller.area.OspfAreaImpl", "org.onosproject.ospf.controller.area.Os...
import java.util.concurrent.ArrayBlockingQueue; import org.easymock.EasyMock; import org.hamcrest.CoreMatchers; import org.hamcrest.MatcherAssert; import org.jboss.netty.channel.Channel; import org.onosproject.ospf.controller.OspfLsaType; import org.onosproject.ospf.controller.area.OspfAreaImpl; import org.onosproject....
import java.util.concurrent.*; import org.easymock.*; import org.hamcrest.*; import org.jboss.netty.channel.*; import org.onosproject.ospf.controller.*; import org.onosproject.ospf.controller.area.*; import org.onosproject.ospf.protocol.lsa.*; import org.onosproject.ospf.protocol.lsa.types.*; import org.onosproject.osp...
[ "java.util", "org.easymock", "org.hamcrest", "org.jboss.netty", "org.onosproject.ospf" ]
java.util; org.easymock; org.hamcrest; org.jboss.netty; org.onosproject.ospf;
1,996,926
@Override public void onItemClick(AdapterView<?> parent, View view, int position, long id) { if (DBG) { Log.d(LOG_TAG, "onItemClick() position " + position); } onItemClicked(position, KeyEvent.KEYCODE_UNKNOWN, null); } }; private final OnItemSelectedListener mOnItemSelectedListener = new OnItem...
void function(AdapterView<?> parent, View view, int position, long id) { if (DBG) { Log.d(LOG_TAG, STR + position); } onItemClicked(position, KeyEvent.KEYCODE_UNKNOWN, null); } }; private final OnItemSelectedListener mOnItemSelectedListener = new OnItemSelectedListener() {
/** * Implements OnItemClickListener */
Implements OnItemClickListener
onItemClick
{ "repo_name": "the-diamond-dogs-group-oss/ActionBarSherlock", "path": "actionbarsherlock/src/com/actionbarsherlock/widget/SearchView.java", "license": "apache-2.0", "size": 62724 }
[ "android.util.Log", "android.view.KeyEvent", "android.view.View", "android.widget.AdapterView" ]
import android.util.Log; import android.view.KeyEvent; import android.view.View; import android.widget.AdapterView;
import android.util.*; import android.view.*; import android.widget.*;
[ "android.util", "android.view", "android.widget" ]
android.util; android.view; android.widget;
1,668,746
public static Element resolveMapping(NabuccoMultiplicityType multiplicity, AssociationStrategyType association, XmlTemplate template) throws XmlTemplateException { if (multiplicity == null) { throw new NabuccoVisitorException("Multiplicity is not valid " + multiplicity + "."); ...
static Element function(NabuccoMultiplicityType multiplicity, AssociationStrategyType association, XmlTemplate template) throws XmlTemplateException { if (multiplicity == null) { throw new NabuccoVisitorException(STR + multiplicity + "."); } if (association == AssociationStrategyType.AGGREGATION) { if (multiplicity.isM...
/** * Copies <code>one-to-one</code>, <code>one-to-many</code>, <code>many-to-one</code> or * <code>many-to-many</code> tags from the template depending on multiplicity and association * type.</p> * * <table border=true> * <col width="10%"/> <col width="30%"/> <col width="30%"/> <thead> ...
Copies <code>one-to-one</code>, <code>one-to-many</code>, <code>many-to-one</code> or <code>many-to-many</code> tags from the template depending on multiplicity and association type. &nbsp; COMPOSITION AGGREGATION 1 1:1 * 1:N
resolveMapping
{ "repo_name": "NABUCCO/org.nabucco.framework.generator", "path": "org.nabucco.framework.generator.compiler/src/main/org/nabucco/framework/generator/compiler/transformation/xml/datatype/NabuccoToXmlDatatypeVisitorSupport.java", "license": "epl-1.0", "size": 13093 }
[ "org.nabucco.framework.generator.compiler.transformation.common.annotation.association.AssociationStrategyType", "org.nabucco.framework.generator.compiler.visitor.NabuccoVisitorException", "org.nabucco.framework.generator.parser.model.multiplicity.NabuccoMultiplicityType", "org.nabucco.framework.mda.template....
import org.nabucco.framework.generator.compiler.transformation.common.annotation.association.AssociationStrategyType; import org.nabucco.framework.generator.compiler.visitor.NabuccoVisitorException; import org.nabucco.framework.generator.parser.model.multiplicity.NabuccoMultiplicityType; import org.nabucco.framework.md...
import org.nabucco.framework.generator.compiler.transformation.common.annotation.association.*; import org.nabucco.framework.generator.compiler.visitor.*; import org.nabucco.framework.generator.parser.model.multiplicity.*; import org.nabucco.framework.mda.template.xml.*; import org.w3c.dom.*;
[ "org.nabucco.framework", "org.w3c.dom" ]
org.nabucco.framework; org.w3c.dom;
2,523,103
public Observable<Long> count() { throw new UnsupportedOperationException(); }
Observable<Long> function() { throw new UnsupportedOperationException(); }
/** * This method counts number of elements in stream and creates another * stream with that value that is consumed by the subscriber * * @return */
This method counts number of elements in stream and creates another stream with that value that is consumed by the subscriber
count
{ "repo_name": "bhatti/RxJava8", "path": "src/main/java/com/plexobject/rx/impl/ObservableNever.java", "license": "mit", "size": 3580 }
[ "com.plexobject.rx.Observable" ]
import com.plexobject.rx.Observable;
import com.plexobject.rx.*;
[ "com.plexobject.rx" ]
com.plexobject.rx;
2,657,131
@SuppressWarnings("rawtypes") @Override public Object getAdapter(Class key) { if (key.equals(IContentOutlinePage.class)) { return showOutlineView() ? getContentOutlinePage() : null; } else if (key.equals(IPropertySheetPage.class)) { return getPropertySheetPage(); } else if (key.equals(IGotoMarker.c...
@SuppressWarnings(STR) Object function(Class key) { if (key.equals(IContentOutlinePage.class)) { return showOutlineView() ? getContentOutlinePage() : null; } else if (key.equals(IPropertySheetPage.class)) { return getPropertySheetPage(); } else if (key.equals(IGotoMarker.class)) { return this; } else { return super.get...
/** * This is how the framework determines which interfaces we implement. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
This is how the framework determines which interfaces we implement.
getAdapter
{ "repo_name": "BaSys-PC1/models", "path": "de.dfki.iui.basys.model.domain.editor/src/de/dfki/iui/basys/model/domain/material/presentation/MaterialEditor.java", "license": "epl-1.0", "size": 57455 }
[ "org.eclipse.ui.ide.IGotoMarker", "org.eclipse.ui.views.contentoutline.IContentOutlinePage", "org.eclipse.ui.views.properties.IPropertySheetPage" ]
import org.eclipse.ui.ide.IGotoMarker; import org.eclipse.ui.views.contentoutline.IContentOutlinePage; import org.eclipse.ui.views.properties.IPropertySheetPage;
import org.eclipse.ui.ide.*; import org.eclipse.ui.views.contentoutline.*; import org.eclipse.ui.views.properties.*;
[ "org.eclipse.ui" ]
org.eclipse.ui;
2,657,228
public void setInterpolation(int newType) { switch(newType) { case(EditorState.INTERPOLATION_BICUBIC): { //interpolation = RenderingHints.VALUE_INTERPOLATION_BICUBIC; break; } case(EditorState.INTERPOLATION_BILINEAR): { //interpolation = RenderingHints.VALUE_INTERPOLATION_BILINEAR; ...
void function(int newType) { switch(newType) { case(EditorState.INTERPOLATION_BICUBIC): { break; } case(EditorState.INTERPOLATION_BILINEAR): { break; } case(EditorState.INTERPOLATION_NEAREST_NEIGHBOR): { break; } } }
/** * Sets the interpolation type used for drawing to the argument * (must be one of the * INTERPOLATION_xyz constants of EditorState), but does not * do a redraw. */
Sets the interpolation type used for drawing to the argument (must be one of the INTERPOLATION_xyz constants of EditorState), but does not do a redraw
setInterpolation
{ "repo_name": "juehv/DentalImageViewer", "path": "DentalImageViewer/lib/jiu-0.14.3/net/sourceforge/jiu/gui/awt/ImageCanvas.java", "license": "gpl-3.0", "size": 5096 }
[ "net.sourceforge.jiu.apps.EditorState" ]
import net.sourceforge.jiu.apps.EditorState;
import net.sourceforge.jiu.apps.*;
[ "net.sourceforge.jiu" ]
net.sourceforge.jiu;
1,736,337
public void isOnGround() { TempVars vars = TempVars.get(); Vector3f location = vars.vect1; Vector3f rayVector = vars.vect2; location.set(localUp).multLocal(getCurrentHeight()).addLocal(this.rigidBody_location); //values chosen after testing float multBy = -getCurrentH...
void function() { TempVars vars = TempVars.get(); Vector3f location = vars.vect1; Vector3f rayVector = vars.vect2; location.set(localUp).multLocal(getCurrentHeight()).addLocal(this.rigidBody_location); float multBy = -getCurrentHeight() - FastMath.ZERO_TOLERANCE; rayVector.set(localUp).multLocal(multBy).addLocal(locati...
/** * Check if the character is on the ground. This is determined by a ray test * in the center of the character and might return false even if the * character is not falling yet. * * @return */
Check if the character is on the ground. This is determined by a ray test in the center of the character and might return false even if the character is not falling yet
isOnGround
{ "repo_name": "virtualillusions/Machello", "path": "src/com/vi/machello/scene/dynamics/control/DynamicPhysicsControl.java", "license": "gpl-2.0", "size": 34742 }
[ "com.jme3.bullet.collision.PhysicsRayTestResult", "com.jme3.math.FastMath", "com.jme3.math.Vector3f", "com.jme3.util.TempVars", "java.util.List" ]
import com.jme3.bullet.collision.PhysicsRayTestResult; import com.jme3.math.FastMath; import com.jme3.math.Vector3f; import com.jme3.util.TempVars; import java.util.List;
import com.jme3.bullet.collision.*; import com.jme3.math.*; import com.jme3.util.*; import java.util.*;
[ "com.jme3.bullet", "com.jme3.math", "com.jme3.util", "java.util" ]
com.jme3.bullet; com.jme3.math; com.jme3.util; java.util;
2,461,833
public void setPositionalInfo(Calendar calendar, double latitude, double longitude, Moon moon) { double julianDate = DateTimeUtils.dateToJulianDate(calendar); setMoonPhase(calendar, moon); setAzimuthElevationZodiac(julianDate, latitude, longitude, moon); MoonDistance distance = moon...
void function(Calendar calendar, double latitude, double longitude, Moon moon) { double julianDate = DateTimeUtils.dateToJulianDate(calendar); setMoonPhase(calendar, moon); setAzimuthElevationZodiac(julianDate, latitude, longitude, moon); MoonDistance distance = moon.getDistance(); distance.setDate(Calendar.getInstance...
/** * Calculates the moon illumination and distance. */
Calculates the moon illumination and distance
setPositionalInfo
{ "repo_name": "clinique/openhab2", "path": "bundles/org.openhab.binding.astro/src/main/java/org/openhab/binding/astro/internal/calc/MoonCalc.java", "license": "epl-1.0", "size": 38554 }
[ "java.util.Calendar", "org.openhab.binding.astro.internal.model.Moon", "org.openhab.binding.astro.internal.model.MoonDistance", "org.openhab.binding.astro.internal.util.DateTimeUtils" ]
import java.util.Calendar; import org.openhab.binding.astro.internal.model.Moon; import org.openhab.binding.astro.internal.model.MoonDistance; import org.openhab.binding.astro.internal.util.DateTimeUtils;
import java.util.*; import org.openhab.binding.astro.internal.model.*; import org.openhab.binding.astro.internal.util.*;
[ "java.util", "org.openhab.binding" ]
java.util; org.openhab.binding;
589,339
public void dispatchViewUpdates(EventDispatcher eventDispatcher, int batchId) { updateViewHierarchy(eventDispatcher); mNativeViewHierarchyOptimizer.onBatchComplete(); mOperationsQueue.dispatchViewUpdates(batchId); }
void function(EventDispatcher eventDispatcher, int batchId) { updateViewHierarchy(eventDispatcher); mNativeViewHierarchyOptimizer.onBatchComplete(); mOperationsQueue.dispatchViewUpdates(batchId); }
/** * Invoked at the end of the transaction to commit any updates to the node hierarchy. */
Invoked at the end of the transaction to commit any updates to the node hierarchy
dispatchViewUpdates
{ "repo_name": "bohanapp/PropertyFinder", "path": "node_modules/react-native/ReactAndroid/src/main/java/com/facebook/react/uimanager/UIImplementation.java", "license": "mit", "size": 28698 }
[ "com.facebook.react.uimanager.events.EventDispatcher" ]
import com.facebook.react.uimanager.events.EventDispatcher;
import com.facebook.react.uimanager.events.*;
[ "com.facebook.react" ]
com.facebook.react;
2,533,238
public static MozuClient<com.mozu.api.contracts.productadmin.DiscountTarget> getDiscountTargetClient(com.mozu.api.DataViewMode dataViewMode, Integer discountId) throws Exception { return getDiscountTargetClient(dataViewMode, discountId, null); }
static MozuClient<com.mozu.api.contracts.productadmin.DiscountTarget> function(com.mozu.api.DataViewMode dataViewMode, Integer discountId) throws Exception { return getDiscountTargetClient(dataViewMode, discountId, null); }
/** * Retrieves the discount target, that is which products, categories, or shipping methods are eligible for the discount. * <p><pre><code> * MozuClient<com.mozu.api.contracts.productadmin.DiscountTarget> mozuClient=GetDiscountTargetClient(dataViewMode, discountId); * client.setBaseAddress(url); * client.ex...
Retrieves the discount target, that is which products, categories, or shipping methods are eligible for the discount. <code><code> MozuClient mozuClient=GetDiscountTargetClient(dataViewMode, discountId); client.setBaseAddress(url); client.executeRequest(); DiscountTarget discountTarget = client.Result(); </code></code>
getDiscountTargetClient
{ "repo_name": "bhewett/mozu-java", "path": "mozu-java-core/src/main/java/com/mozu/api/clients/commerce/catalog/admin/discounts/DiscountTargetClient.java", "license": "mit", "size": 6274 }
[ "com.mozu.api.DataViewMode", "com.mozu.api.MozuClient" ]
import com.mozu.api.DataViewMode; import com.mozu.api.MozuClient;
import com.mozu.api.*;
[ "com.mozu.api" ]
com.mozu.api;
897,331
public void testCloning() { ShipNeedle n1 = new ShipNeedle(); ShipNeedle n2 = null; try { n2 = (ShipNeedle) n1.clone(); } catch (CloneNotSupportedException e) { e.printStackTrace(); System.err.println("Failed to clone."); } ...
void function() { ShipNeedle n1 = new ShipNeedle(); ShipNeedle n2 = null; try { n2 = (ShipNeedle) n1.clone(); } catch (CloneNotSupportedException e) { e.printStackTrace(); System.err.println(STR); } assertTrue(n1 != n2); assertTrue(n1.getClass() == n2.getClass()); assertTrue(n1.equals(n2)); }
/** * Check that cloning works. */
Check that cloning works
testCloning
{ "repo_name": "raedle/univis", "path": "lib/jfreechart-1.0.1/src/org/jfree/chart/needle/junit/ShipNeedleTests.java", "license": "lgpl-2.1", "size": 3913 }
[ "org.jfree.chart.needle.ShipNeedle" ]
import org.jfree.chart.needle.ShipNeedle;
import org.jfree.chart.needle.*;
[ "org.jfree.chart" ]
org.jfree.chart;
617,532
public Thing getSubject() { return Base.getAll_as(this.model, this.getResource(), SUBJECT, Thing.class).firstValue(); }
Thing function() { return Base.getAll_as(this.model, this.getResource(), SUBJECT, Thing.class).firstValue(); }
/** * Get all values of property Subject * @return a ClosableIterator of $type * [Generated from RDFReactor template rule #get12dynamic] */
Get all values of property Subject [Generated from RDFReactor template rule #get12dynamic]
getSubject
{ "repo_name": "m0ep/master-thesis", "path": "source/apis/rdf2go/rdf2go-foaf/src/main/java/com/xmlns/foaf/Thing.java", "license": "mit", "size": 274766 }
[ "org.ontoware.rdfreactor.runtime.Base" ]
import org.ontoware.rdfreactor.runtime.Base;
import org.ontoware.rdfreactor.runtime.*;
[ "org.ontoware.rdfreactor" ]
org.ontoware.rdfreactor;
2,809,754
@Override public List<PropagationTask> getRoleDeleteTaskIds(final Long roleKey, final Collection<String> noPropResourceNames) throws NotFoundException, UnauthorizedRoleException { Role role = roleDAO.authFetch(roleKey); return getDeleteTaskIds(role, role.getResourceNames(), noPropRe...
List<PropagationTask> function(final Long roleKey, final Collection<String> noPropResourceNames) throws NotFoundException, UnauthorizedRoleException { Role role = roleDAO.authFetch(roleKey); return getDeleteTaskIds(role, role.getResourceNames(), noPropResourceNames); }
/** * Perform delete on each resource associated to the user. It is possible to ask for a mandatory provisioning for * some resources specifying a set of resource names. Exceptions won't be ignored and the process will be stopped if * the creation fails onto a mandatory resource. * * @param rol...
Perform delete on each resource associated to the user. It is possible to ask for a mandatory provisioning for some resources specifying a set of resource names. Exceptions won't be ignored and the process will be stopped if the creation fails onto a mandatory resource
getRoleDeleteTaskIds
{ "repo_name": "massx1/syncope", "path": "core/provisioning-java/src/main/java/org/apache/syncope/core/provisioning/java/propagation/PropagationManagerImpl.java", "license": "apache-2.0", "size": 37015 }
[ "java.util.Collection", "java.util.List", "org.apache.syncope.core.misc.security.UnauthorizedRoleException", "org.apache.syncope.core.persistence.api.dao.NotFoundException", "org.apache.syncope.core.persistence.api.entity.role.Role", "org.apache.syncope.core.persistence.api.entity.task.PropagationTask" ]
import java.util.Collection; import java.util.List; import org.apache.syncope.core.misc.security.UnauthorizedRoleException; import org.apache.syncope.core.persistence.api.dao.NotFoundException; import org.apache.syncope.core.persistence.api.entity.role.Role; import org.apache.syncope.core.persistence.api.entity.task.Pr...
import java.util.*; import org.apache.syncope.core.misc.security.*; import org.apache.syncope.core.persistence.api.dao.*; import org.apache.syncope.core.persistence.api.entity.role.*; import org.apache.syncope.core.persistence.api.entity.task.*;
[ "java.util", "org.apache.syncope" ]
java.util; org.apache.syncope;
1,971,633
public COSName getKey() { return key; }
COSName function() { return key; }
/** * Get the key for this entry. * * @return The entry's key. */
Get the key for this entry
getKey
{ "repo_name": "joansmith/pdfbox", "path": "debugger/src/main/java/org/apache/pdfbox/debugger/ui/MapEntry.java", "license": "apache-2.0", "size": 2490 }
[ "org.apache.pdfbox.cos.COSName" ]
import org.apache.pdfbox.cos.COSName;
import org.apache.pdfbox.cos.*;
[ "org.apache.pdfbox" ]
org.apache.pdfbox;
2,175,224
public void onSuccess(HttpContext context, T response);
void function(HttpContext context, T response);
/** * On Completed callback for API calls * @param context The context of the API request * @param response The response received from the API Call */
On Completed callback for API calls
onSuccess
{ "repo_name": "information-machine/information-machine-api-android", "path": "InformationMachineAPILib/src/main/java/co/iamdata/api/http/client/APICallBack.java", "license": "mit", "size": 744 }
[ "co.iamdata.api.http.client.HttpContext" ]
import co.iamdata.api.http.client.HttpContext;
import co.iamdata.api.http.client.*;
[ "co.iamdata.api" ]
co.iamdata.api;
1,212,552
public ResourceConfigInfo getResourceSystemInfoFor(VResourceSystem vrs) throws VrsException { // todo: query actual instance instead of registry. return getResourceSystemInfoFor(vrs.getServerVRL(), false); }
ResourceConfigInfo function(VResourceSystem vrs) throws VrsException { return getResourceSystemInfoFor(vrs.getServerVRL(), false); }
/** * Return actual ResourceSystemInfo used for the specified ResourceSystem. */
Return actual ResourceSystemInfo used for the specified ResourceSystem
getResourceSystemInfoFor
{ "repo_name": "NLeSC/Platinum", "path": "ptk-vbrowser-vrs/src/main/java/nl/esciencecenter/vbrowser/vrs/VRSContext.java", "license": "apache-2.0", "size": 8849 }
[ "nl.esciencecenter.vbrowser.vrs.exceptions.VrsException", "nl.esciencecenter.vbrowser.vrs.registry.ResourceConfigInfo" ]
import nl.esciencecenter.vbrowser.vrs.exceptions.VrsException; import nl.esciencecenter.vbrowser.vrs.registry.ResourceConfigInfo;
import nl.esciencecenter.vbrowser.vrs.exceptions.*; import nl.esciencecenter.vbrowser.vrs.registry.*;
[ "nl.esciencecenter.vbrowser" ]
nl.esciencecenter.vbrowser;
196,078
List<String> list() throws IOException; /** * Returns the size of the value of a user-defined attribute. * * @param name * The attribute name * * @return The size of the attribute value, in bytes. * * @throws ArithmeticException * If the size o...
List<String> list() throws IOException; /** * Returns the size of the value of a user-defined attribute. * * @param name * The attribute name * * @return The size of the attribute value, in bytes. * * @throws ArithmeticException * If the size of the attribute is larger than {@link Integer#MAX_VALUE}
/** * Returns a list containing the names of the user-defined attributes. * * @return An unmodifiable list continaing the names of the file's * user-defined * * @throws IOException * If an I/O error occurs * @throws SecurityException * In the ca...
Returns a list containing the names of the user-defined attributes
list
{ "repo_name": "rokn/Count_Words_2015", "path": "testing/openjdk/jdk/src/share/classes/java/nio/file/attribute/UserDefinedFileAttributeView.java", "license": "mit", "size": 10354 }
[ "java.io.IOException", "java.util.List" ]
import java.io.IOException; import java.util.List;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
723,896
protected HttpClientConfigurer createHttpClientConfigurer(Map<String, Object> parameters, boolean secure) throws Exception { // prefer to use endpoint configured over component configured HttpClientConfigurer configurer = resolveAndRemoveReferenceParameter(parameters, "httpClientConfigurer", HttpCli...
HttpClientConfigurer function(Map<String, Object> parameters, boolean secure) throws Exception { HttpClientConfigurer configurer = resolveAndRemoveReferenceParameter(parameters, STR, HttpClientConfigurer.class); if (configurer == null) { configurer = getHttpClientConfigurer(); } configurer = configureBasicAuthenticatio...
/** * Creates the HttpClientConfigurer based on the given parameters * * @param parameters the map of parameters * @param secure whether the endpoint is secure (eg https4) * @return the configurer * @throws Exception is thrown if error creating configurer */
Creates the HttpClientConfigurer based on the given parameters
createHttpClientConfigurer
{ "repo_name": "jonmcewen/camel", "path": "components/camel-http4/src/main/java/org/apache/camel/component/http4/HttpComponent.java", "license": "apache-2.0", "size": 29984 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,332,523