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 boolean initForJUnitTest(String adjMethod, String rowOrdering, CompressionMethod[] cmpMethods, Arithmetic arithmetic) { final Config defCfg = new Config( arithmetic.getDefaultZero(), adjMethod, rowOrdering, cmpMethods, true, false, false, Runtime.getRuntime().availableProcessors(), arithme...
static boolean function(String adjMethod, String rowOrdering, CompressionMethod[] cmpMethods, Arithmetic arithmetic) { final Config defCfg = new Config( arithmetic.getDefaultZero(), adjMethod, rowOrdering, cmpMethods, true, false, false, Runtime.getRuntime().availableProcessors(), arithmetic, -1, Generator.Efm, Normali...
/** * Initializes elementary flux mode calculation for junit tests. If there is * already a configuration, false is returned. Otherwise, binary nullspace * implementation is initalized with the specified configuration values and * defaults for missing values. * * @return true if configured as specified,...
Initializes elementary flux mode calculation for junit tests. If there is already a configuration, false is returned. Otherwise, binary nullspace implementation is initalized with the specified configuration values and defaults for missing values
initForJUnitTest
{ "repo_name": "mpgerstl/tEFMA", "path": "ch/javasoft/metabolic/efm/config/Config.java", "license": "bsd-2-clause", "size": 37828 }
[ "ch.javasoft.metabolic.compress.CompressionMethod", "ch.javasoft.metabolic.efm.progress.ProgressType" ]
import ch.javasoft.metabolic.compress.CompressionMethod; import ch.javasoft.metabolic.efm.progress.ProgressType;
import ch.javasoft.metabolic.compress.*; import ch.javasoft.metabolic.efm.progress.*;
[ "ch.javasoft.metabolic" ]
ch.javasoft.metabolic;
101,172
Webhook updateWebhook(Webhook webhook) throws SmartsheetException;
Webhook updateWebhook(Webhook webhook) throws SmartsheetException;
/** * <p>Updates the webhooks specified in the URL.</p> * * <p>It mirrors to the following Smartsheet REST API method: PUT /webhooks/{webhookId}</p> * * @param webhook the webhook to update * @return the updated webhook resource. * @throws IllegalArgumentException if any argument is n...
Updates the webhooks specified in the URL. It mirrors to the following Smartsheet REST API method: PUT /webhooks/{webhookId}
updateWebhook
{ "repo_name": "smartsheet-platform/smartsheet-java-sdk", "path": "src/main/java/com/smartsheet/api/WebhookResources.java", "license": "apache-2.0", "size": 6649 }
[ "com.smartsheet.api.models.Webhook" ]
import com.smartsheet.api.models.Webhook;
import com.smartsheet.api.models.*;
[ "com.smartsheet.api" ]
com.smartsheet.api;
2,883,474
public void assertCookiePresentByName(final String cookieName) { Set<Cookie> cookies = driver.manage().getCookies(); for (Cookie cookie : cookies) { if (cookie.getName().equals(cookieName)) { LOG.info("Cookie: " + cookieName + " was found with value: " + cookie.getValue()); Assert.assertEquals(...
void function(final String cookieName) { Set<Cookie> cookies = driver.manage().getCookies(); for (Cookie cookie : cookies) { if (cookie.getName().equals(cookieName)) { LOG.info(STR + cookieName + STR + cookie.getValue()); Assert.assertEquals(cookieName, cookie.getName()); return; } } Assert.fail(STR + cookieName + STR)...
/** * Checks if the given cookie name exists in the current session. This * method is also logging the result. The match is CASE SENSITIVE. Please * not that the method will do a JUNIT Assert causing the test to fail. * * @param cookieName * the name of the cookie * */
Checks if the given cookie name exists in the current session. This method is also logging the result. The match is CASE SENSITIVE. Please not that the method will do a JUNIT Assert causing the test to fail
assertCookiePresentByName
{ "repo_name": "ludovicianul/selenium-on-steroids", "path": "src/main/java/com/insidecoding/sos/webdriver/WebDriverHelper.java", "license": "apache-2.0", "size": 38225 }
[ "java.util.Set", "junit.framework.Assert", "org.openqa.selenium.Cookie" ]
import java.util.Set; import junit.framework.Assert; import org.openqa.selenium.Cookie;
import java.util.*; import junit.framework.*; import org.openqa.selenium.*;
[ "java.util", "junit.framework", "org.openqa.selenium" ]
java.util; junit.framework; org.openqa.selenium;
2,238,767
private static String getObjectAttributeSQLStatement(ObjectAttribute objectAttribute) { return "insert into OBJECT_ATTRIBUTE (OBJECT_ATTRIBUTE_ID,ATTRIBUTE, PREVIOUS_VALUE, CURRENT_VALUE) values (NULL" +",'"+StringUtils.initString(objectAttribute.getAttributeName()) +"','"+StringUtils.initString(objectAtt...
static String function(ObjectAttribute objectAttribute) { return STR +",'"+StringUtils.initString(objectAttribute.getAttributeName()) +"','"+StringUtils.initString(objectAttribute.getPreviousValue()) +"','"+StringUtils.initString(objectAttribute.getCurrentValue()) +"')"; }
/** * Returns a SQL Insert statement based on an ObjectAttribute Object instance. * * @param objectAttribute * @return a string consisting an SQL insert statement for ObjectAttribute object. */
Returns a SQL Insert statement based on an ObjectAttribute Object instance
getObjectAttributeSQLStatement
{ "repo_name": "NCIP/common-logging-module", "path": "software/api/src/gov/nih/nci/logging/api/appender/jdbc/SQLGeneratorOracle.java", "license": "bsd-3-clause", "size": 6057 }
[ "gov.nih.nci.logging.api.domain.ObjectAttribute", "gov.nih.nci.logging.api.util.StringUtils" ]
import gov.nih.nci.logging.api.domain.ObjectAttribute; import gov.nih.nci.logging.api.util.StringUtils;
import gov.nih.nci.logging.api.domain.*; import gov.nih.nci.logging.api.util.*;
[ "gov.nih.nci" ]
gov.nih.nci;
2,654,326
@Deprecated public static String toString(final URL url) throws IOException { return toString(url, Charset.defaultCharset()); }
static String function(final URL url) throws IOException { return toString(url, Charset.defaultCharset()); }
/** * Gets the contents at the given URL. * * @param url The URL source. * @return The contents of the URL as a String. * @throws IOException if an I/O exception occurs. * @since 2.1 * @deprecated 2.5 use {@link #toString(URL, Charset)} instead */
Gets the contents at the given URL
toString
{ "repo_name": "krosenvold/commons-io", "path": "src/main/java/org/apache/commons/io/IOUtils.java", "license": "apache-2.0", "size": 125142 }
[ "java.io.IOException", "java.nio.charset.Charset" ]
import java.io.IOException; import java.nio.charset.Charset;
import java.io.*; import java.nio.charset.*;
[ "java.io", "java.nio" ]
java.io; java.nio;
2,548,563
public static String toString(byte[] array, String encoding) throws UnsupportedEncodingException { return encoding==null ? new String(array) : new String(array,encoding); }
static String function(byte[] array, String encoding) throws UnsupportedEncodingException { return encoding==null ? new String(array) : new String(array,encoding); }
/** * Creates a string from byte array using specified encoding. * Note: in apache commons a similar method is provided in * the 'StringUtils' class. That makes sense when putting methods * to utility classes corresponding to return type. * * @param array the array to convert to a string * @param encodi...
Creates a string from byte array using specified encoding. Note: in apache commons a similar method is provided in the 'StringUtils' class. That makes sense when putting methods to utility classes corresponding to return type
toString
{ "repo_name": "htwg/lib", "path": "util/src/main/java/de/fhkn/in/util/ByteUtils.java", "license": "gpl-3.0", "size": 6628 }
[ "java.io.UnsupportedEncodingException" ]
import java.io.UnsupportedEncodingException;
import java.io.*;
[ "java.io" ]
java.io;
2,813,475
public List<byte[]> hmget(final byte[] key, final byte[]... fields) { checkIsInMulti(); client.hmget(key, fields); return client.getBinaryMultiBulkReply(); }
List<byte[]> function(final byte[] key, final byte[]... fields) { checkIsInMulti(); client.hmget(key, fields); return client.getBinaryMultiBulkReply(); }
/** * Retrieve the values associated to the specified fields. * <p> * If some of the specified fields do not exist, nil values are returned. Non existing keys are * considered like empty hashes. * <p> * <b>Time complexity:</b> O(N) (with N being the number of fields) * @param key * @param fields...
Retrieve the values associated to the specified fields. If some of the specified fields do not exist, nil values are returned. Non existing keys are considered like empty hashes. Time complexity: O(N) (with N being the number of fields)
hmget
{ "repo_name": "flasheryu/RedisTest", "path": "src/main/java/redis/clients/jedis/BinaryJedis.java", "license": "mit", "size": 117913 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,683,813
protected void procProcessExit(SMBSrvPacket smbPkt) throws java.io.IOException, SMBSrvException { // Check that the received packet looks like a valid process exit request if ( smbPkt.checkPacketIsValid(0, 0) == false) { m_sess.sendErrorResponseSMB( smbPkt, SMBStatus.SRVUnrecognizedCommand, SMBStatus.ErrS...
void function(SMBSrvPacket smbPkt) throws java.io.IOException, SMBSrvException { if ( smbPkt.checkPacketIsValid(0, 0) == false) { m_sess.sendErrorResponseSMB( smbPkt, SMBStatus.SRVUnrecognizedCommand, SMBStatus.ErrSrv); return; } VirtualCircuit vc = m_sess.findVirtualCircuit( smbPkt.getUserId()); if ( vc == null) { m_s...
/** * Process exit, close all open files. * * @param smbPkt SMBSrvPacket * @exception java.io.IOException The exception description. * @exception org.alfresco.aifs.smb.server.SMBSrvException The exception description. */
Process exit, close all open files
procProcessExit
{ "repo_name": "arcusys/Liferay-CIFS", "path": "source/java/org/alfresco/jlan/smb/server/CoreProtocolHandler.java", "license": "gpl-3.0", "size": 106242 }
[ "java.io.IOException", "org.alfresco.jlan.debug.Debug", "org.alfresco.jlan.server.filesys.TreeConnection", "org.alfresco.jlan.smb.SMBStatus" ]
import java.io.IOException; import org.alfresco.jlan.debug.Debug; import org.alfresco.jlan.server.filesys.TreeConnection; import org.alfresco.jlan.smb.SMBStatus;
import java.io.*; import org.alfresco.jlan.debug.*; import org.alfresco.jlan.server.filesys.*; import org.alfresco.jlan.smb.*;
[ "java.io", "org.alfresco.jlan" ]
java.io; org.alfresco.jlan;
87,633
@Test public void testGetPassword2() { try { URI uri = new URI( "blp://sdcote@linkage.bralyn.net:5529/root/home/stuff" ); String password = UriUtil.getPassword( uri ); assertTrue( password == null ); } catch ( URISyntaxException e ) { fail( e.getMessage() ); } } ...
void function() { try { URI uri = new URI( "blp: String password = UriUtil.getPassword( uri ); assertTrue( password == null ); } catch ( URISyntaxException e ) { fail( e.getMessage() ); } }
/** * Method testGetPassword2 */
Method testGetPassword2
testGetPassword2
{ "repo_name": "sdcote/loader", "path": "src/test/java/coyote/commons/UriUtilTest.java", "license": "mit", "size": 14105 }
[ "java.net.URISyntaxException", "org.junit.Assert" ]
import java.net.URISyntaxException; import org.junit.Assert;
import java.net.*; import org.junit.*;
[ "java.net", "org.junit" ]
java.net; org.junit;
123,222
public MetaProperty<SecurityId> securityId() { return securityId; }
MetaProperty<SecurityId> function() { return securityId; }
/** * The meta-property for the {@code securityId} property. * @return the meta-property, not null */
The meta-property for the securityId property
securityId
{ "repo_name": "OpenGamma/Strata", "path": "modules/product/src/main/java/com/opengamma/strata/product/etd/EtdOptionPosition.java", "license": "apache-2.0", "size": 24965 }
[ "com.opengamma.strata.product.SecurityId", "org.joda.beans.MetaProperty" ]
import com.opengamma.strata.product.SecurityId; import org.joda.beans.MetaProperty;
import com.opengamma.strata.product.*; import org.joda.beans.*;
[ "com.opengamma.strata", "org.joda.beans" ]
com.opengamma.strata; org.joda.beans;
2,504,697
String encode(String data, Optional<RegisteredService> service);
String encode(String data, Optional<RegisteredService> service);
/** * Encode string. * * @param data the data * @param service the service * @return the encoded string or null */
Encode string
encode
{ "repo_name": "GIP-RECIA/cas", "path": "api/cas-server-core-api-services/src/main/java/org/apereo/cas/services/RegisteredServiceCipherExecutor.java", "license": "apache-2.0", "size": 1235 }
[ "java.util.Optional" ]
import java.util.Optional;
import java.util.*;
[ "java.util" ]
java.util;
2,328,071
@NonNull public static <T extends Collection<?>> T checkCollectionNotEmpty( T collection, @Nullable Object errorMessage) { checkNotNull(collection, errorMessage); checkArgument(!collection.isEmpty(), errorMessage); return collection; }
static <T extends Collection<?>> T function( T collection, @Nullable Object errorMessage) { checkNotNull(collection, errorMessage); checkArgument(!collection.isEmpty(), errorMessage); return collection; }
/** * Ensures that a collection is not null or empty. */
Ensures that a collection is not null or empty
checkCollectionNotEmpty
{ "repo_name": "openid/AppAuth-Android", "path": "library/java/net/openid/appauth/Preconditions.java", "license": "apache-2.0", "size": 5033 }
[ "androidx.annotation.Nullable", "java.util.Collection" ]
import androidx.annotation.Nullable; import java.util.Collection;
import androidx.annotation.*; import java.util.*;
[ "androidx.annotation", "java.util" ]
androidx.annotation; java.util;
452,621
public void changeCursor(Cursor cursor) { Cursor old = swapCursor(cursor); if (old != null) { old.close(); } }
void function(Cursor cursor) { Cursor old = swapCursor(cursor); if (old != null) { old.close(); } }
/** * Change the underlying cursor to a new cursor. If there is an existing cursor it will be * closed. * * @param cursor The new cursor to be used */
Change the underlying cursor to a new cursor. If there is an existing cursor it will be closed
changeCursor
{ "repo_name": "aint/gnucash-android", "path": "app/src/main/java/org/gnucash/android/ui/util/CursorRecyclerAdapter.java", "license": "apache-2.0", "size": 12589 }
[ "android.database.Cursor" ]
import android.database.Cursor;
import android.database.*;
[ "android.database" ]
android.database;
2,549,366
public boolean setflat(Env env, double flatness) { env.stub("setflat"); return false; }
boolean function(Env env, double flatness) { env.stub(STR); return false; }
/** * Sets the flatness */
Sets the flatness
setflat
{ "repo_name": "dlitz/resin", "path": "modules/quercus/src/com/caucho/quercus/lib/pdf/PDF.java", "license": "gpl-2.0", "size": 21718 }
[ "com.caucho.quercus.env.Env" ]
import com.caucho.quercus.env.Env;
import com.caucho.quercus.env.*;
[ "com.caucho.quercus" ]
com.caucho.quercus;
2,627,132
@Override public void zoomRangeAxes(double factor, PlotRenderingInfo info, Point2D source, boolean useAnchor) { // perform the zoom on each range axis for (ValueAxis yAxis : this.rangeAxes.values()) { if (yAxis == null) { continue; ...
void function(double factor, PlotRenderingInfo info, Point2D source, boolean useAnchor) { for (ValueAxis yAxis : this.rangeAxes.values()) { if (yAxis == null) { continue; } if (useAnchor) { double sourceY = source.getY(); if (this.orientation == PlotOrientation.HORIZONTAL) { sourceY = source.getX(); } double anchorY = ...
/** * Multiplies the range on the range axis/axes by the specified factor. * * @param factor the zoom factor. * @param info the plot rendering info. * @param source the source point. * @param useAnchor a flag that controls whether or not the source point * is used for the ...
Multiplies the range on the range axis/axes by the specified factor
zoomRangeAxes
{ "repo_name": "GitoMat/jfreechart", "path": "src/main/java/org/jfree/chart/plot/XYPlot.java", "license": "lgpl-2.1", "size": 197216 }
[ "java.awt.geom.Point2D", "org.jfree.chart.axis.ValueAxis" ]
import java.awt.geom.Point2D; import org.jfree.chart.axis.ValueAxis;
import java.awt.geom.*; import org.jfree.chart.axis.*;
[ "java.awt", "org.jfree.chart" ]
java.awt; org.jfree.chart;
1,415,485
Collection<OAuthTokenLifecycleListener> getLifecycleListeners();
Collection<OAuthTokenLifecycleListener> getLifecycleListeners();
/** * The collection of lifecycle listeners for this registry. * * @return The collection of lifecycle listeners for this registry. */
The collection of lifecycle listeners for this registry
getLifecycleListeners
{ "repo_name": "xiangzhuyuan/spring-security-oauth", "path": "spring-security-oauth/src/main/java/org/springframework/security/oauth/provider/token/OAuthTokenLifecycleRegistry.java", "license": "apache-2.0", "size": 756 }
[ "java.util.Collection" ]
import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
2,733,972
protected void ensureAvailableBytes(int amount) throws IOException { if (!this.seekEnabled && amount > this.buffer.remaining()) { this.bufferPosition += this.buffer.position(); this.buffer.compact(); int limit = this.buffer.position(); final int read = this.stream.read(this.buffer); if (read < 0) { ...
void function(int amount) throws IOException { if (!this.seekEnabled && amount > this.buffer.remaining()) { this.bufferPosition += this.buffer.position(); this.buffer.compact(); int limit = this.buffer.position(); final int read = this.stream.read(this.buffer); if (read < 0) { if (limit == 0) { throw new EOFException()...
/** Ensure that the reading buffer is containing enoug bytes to read. * * @param amount is the count of expected bytes * @throws IOException in case of error. * @throws EOFException if the end of the file was reached. */
Ensure that the reading buffer is containing enoug bytes to read
ensureAvailableBytes
{ "repo_name": "gallandarakhneorg/afc", "path": "advanced/shapefile/src/main/java/org/arakhne/afc/io/shape/AbstractCommonShapeFileReader.java", "license": "apache-2.0", "size": 21118 }
[ "java.io.EOFException", "java.io.IOException" ]
import java.io.EOFException; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,359,543
String scheme = url.getScheme() == null ? "" : url.getScheme(); String authority = ""; if (url.getHost() != null) { authority = url.getHost(); if (url.getPort() > 0) { authority += ":" + url.getPort(); } } return new Path( (new URI(scheme, authority, url.getFi...
String scheme = url.getScheme() == null ? STRSTR:" + url.getPort(); } } return new Path( (new URI(scheme, authority, url.getFile(), null, null)).normalize()); }
/** * return a hadoop path from a given url * * @param url * url to convert * @return path from {@link URL} * @throws URISyntaxException */
return a hadoop path from a given url
getPathFromYarnURL
{ "repo_name": "ict-carch/hadoop-plus", "path": "hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/util/ConverterUtils.java", "license": "apache-2.0", "size": 7976 }
[ "org.apache.hadoop.fs.Path" ]
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.fs.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
1,337,996
public static boolean isIdentifier(String s) { return Tokenizer.isExternalName(s); }
static boolean function(String s) { return Tokenizer.isExternalName(s); }
/** * Tests whether or not the given string is valid identifier. Valid identifiers have a length greater than zero, * start with a letter or underscore followed by letters, digits or underscores. * * @param s the string to test * @return <code>true</code> if the s is a valid node ifentifier, <c...
Tests whether or not the given string is valid identifier. Valid identifiers have a length greater than zero, start with a letter or underscore followed by letters, digits or underscores
isIdentifier
{ "repo_name": "bcdev/beam", "path": "beam-core/src/main/java/org/esa/beam/util/StringUtils.java", "license": "gpl-3.0", "size": 33173 }
[ "com.bc.jexp.impl.Tokenizer" ]
import com.bc.jexp.impl.Tokenizer;
import com.bc.jexp.impl.*;
[ "com.bc.jexp" ]
com.bc.jexp;
446,248
public void testSerialization() { XYAreaRenderer r1 = new XYAreaRenderer(); XYAreaRenderer r2 = null; try { ByteArrayOutputStream buffer = new ByteArrayOutputStream(); ObjectOutput out = new ObjectOutputStream(buffer); out.writeObject(r1); ou...
void function() { XYAreaRenderer r1 = new XYAreaRenderer(); XYAreaRenderer r2 = null; try { ByteArrayOutputStream buffer = new ByteArrayOutputStream(); ObjectOutput out = new ObjectOutputStream(buffer); out.writeObject(r1); 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/renderer/xy/junit/XYAreaRendererTests.java", "license": "lgpl-3.0", "size": 4348 }
[ "java.io.ByteArrayInputStream", "java.io.ByteArrayOutputStream", "java.io.ObjectInput", "java.io.ObjectInputStream", "java.io.ObjectOutput", "java.io.ObjectOutputStream", "org.jfree.chart.renderer.xy.XYAreaRenderer" ]
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.renderer.xy.XYAreaRenderer;
import java.io.*; import org.jfree.chart.renderer.xy.*;
[ "java.io", "org.jfree.chart" ]
java.io; org.jfree.chart;
924,614
public void writeRecord(byte[] buf, int offset) throws IOException { if (logger.isLoggable(Level.FINEST)) { logger.log(Level.FINEST, "WriteRecord: recIdx = " + this.currRecIdx + " blkIdx = " + this.currBlkIdx); } if (this.outStream == null) { throw new IOException("writing to an input buffer"); ...
void function(byte[] buf, int offset) throws IOException { if (logger.isLoggable(Level.FINEST)) { logger.log(Level.FINEST, STR + this.currRecIdx + STR + this.currBlkIdx); } if (this.outStream == null) { throw new IOException(STR); } if (offset + this.recordSize > buf.length) { throw new IOException(STR + buf.length + S...
/** * Write an archive record to the archive, where the record may be inside of * a larger array buffer. The buffer must be "offset plus record size" long. * * @param buf * The buffer containing the record data to write. * @param offset * The offset of the record data within buf. ...
Write an archive record to the archive, where the record may be inside of a larger array buffer. The buffer must be "offset plus record size" long
writeRecord
{ "repo_name": "ISCPIF/PSEExperiments", "path": "openmole-src/openmole/third-parties/com.ice.tar/src/main/java/com/ice/tar/TarBuffer.java", "license": "agpl-3.0", "size": 12272 }
[ "java.io.IOException", "java.util.logging.Level" ]
import java.io.IOException; import java.util.logging.Level;
import java.io.*; import java.util.logging.*;
[ "java.io", "java.util" ]
java.io; java.util;
547,130
public static final SourceModel.Expr LitInteger(SourceModel.Expr value) { return SourceModel.Expr.Application.make( new SourceModel.Expr[] {SourceModel.Expr.DataCons.make(DataConstructors.LitInteger), value}); } public static final QualifiedName LitInteger = QualifiedName.make( ...
static final SourceModel.Expr function(SourceModel.Expr value) { return SourceModel.Expr.Application.make( new SourceModel.Expr[] {SourceModel.Expr.DataCons.make(DataConstructors.LitInteger), value}); } static final QualifiedName function = QualifiedName.make( CAL_Optimizer_Expression_internal.MODULE_NAME, STR); static...
/** * Binding for DataConstructor: Cal.Internal.Optimizer_Expression.LitInteger. * @param value * @return the SourceModule.Expr representing an application of Cal.Internal.Optimizer_Expression.LitInteger */
Binding for DataConstructor: Cal.Internal.Optimizer_Expression.LitInteger
LitInteger
{ "repo_name": "levans/Open-Quark", "path": "src/CAL_Platform/src/org/openquark/cal/internal/module/Cal/Internal/CAL_Optimizer_Expression_internal.java", "license": "bsd-3-clause", "size": 265925 }
[ "org.openquark.cal.compiler.QualifiedName", "org.openquark.cal.compiler.SourceModel" ]
import org.openquark.cal.compiler.QualifiedName; import org.openquark.cal.compiler.SourceModel;
import org.openquark.cal.compiler.*;
[ "org.openquark.cal" ]
org.openquark.cal;
1,092,211
public com.mozu.api.contracts.mzdb.EntityList createEntityList(com.mozu.api.contracts.mzdb.EntityList entityList, String responseFields) throws Exception { MozuClient<com.mozu.api.contracts.mzdb.EntityList> client = com.mozu.api.clients.platform.EntityListClient.createEntityListClient( entityList, responseFields...
com.mozu.api.contracts.mzdb.EntityList function(com.mozu.api.contracts.mzdb.EntityList entityList, String responseFields) throws Exception { MozuClient<com.mozu.api.contracts.mzdb.EntityList> client = com.mozu.api.clients.platform.EntityListClient.createEntityListClient( entityList, responseFields); client.setContext(_...
/** * Create a new EntityList for a specific tenant. * <p><pre><code> * EntityList entitylist = new EntityList(); * EntityList entityList = entitylist.createEntityList( entityList, responseFields); * </code></pre></p> * @param responseFields Use this field to include those fields which are not included by ...
Create a new EntityList for a specific tenant. <code><code> EntityList entitylist = new EntityList(); EntityList entityList = entitylist.createEntityList( entityList, responseFields); </code></code>
createEntityList
{ "repo_name": "lakshmi-nair/mozu-java", "path": "mozu-javaasync-core/src/main/java/com/mozu/api/resources/platform/EntityListResource.java", "license": "mit", "size": 20632 }
[ "com.mozu.api.MozuClient" ]
import com.mozu.api.MozuClient;
import com.mozu.api.*;
[ "com.mozu.api" ]
com.mozu.api;
575,926
@Override public void setModel(String path, double[][] matrix) throws IOException, InvalidFormatException { this.matrix = matrix; HSSFWorkbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet("Simulyn"); for (int i = 0; i < this.matrix.length; i++) { ...
void function(String path, double[][] matrix) throws IOException, InvalidFormatException { this.matrix = matrix; HSSFWorkbook wb = new HSSFWorkbook(); Sheet sheet = wb.createSheet(STR); for (int i = 0; i < this.matrix.length; i++) { sheet.createRow(i); for (int j = 0; j < this.matrix[i].length; j++) { sheet.getRow(i).c...
/** * Set the path to the file that defines the new Model. * @param path to the file containing the model data */
Set the path to the file that defines the new Model
setModel
{ "repo_name": "KEOpenSource/SimulynIO", "path": "src/file/save/spreadsheet/model/SaveXlsFileModel.java", "license": "apache-2.0", "size": 2745 }
[ "java.io.FileOutputStream", "java.io.IOException", "org.apache.poi.hssf.usermodel.HSSFWorkbook", "org.apache.poi.openxml4j.exceptions.InvalidFormatException", "org.apache.poi.ss.usermodel.Cell", "org.apache.poi.ss.usermodel.Sheet" ]
import java.io.FileOutputStream; import java.io.IOException; import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.openxml4j.exceptions.InvalidFormatException; import org.apache.poi.ss.usermodel.Cell; import org.apache.poi.ss.usermodel.Sheet;
import java.io.*; import org.apache.poi.hssf.usermodel.*; import org.apache.poi.openxml4j.exceptions.*; import org.apache.poi.ss.usermodel.*;
[ "java.io", "org.apache.poi" ]
java.io; org.apache.poi;
329,375
private ServerBootstrap createServerBootStrap() { if (workerThreads == 0) { execFactory = new NioServerSocketChannelFactory( Executors.newCachedThreadPool(groupedThreads("onos/pcep", "boss-%d")), Executors.newCachedThreadPool(groupedThreads("onos/pcep", "w...
ServerBootstrap function() { if (workerThreads == 0) { execFactory = new NioServerSocketChannelFactory( Executors.newCachedThreadPool(groupedThreads(STR, STR)), Executors.newCachedThreadPool(groupedThreads(STR, STR))); return new ServerBootstrap(execFactory); } else { execFactory = new NioServerSocketChannelFactory( Ex...
/** * Creates server boot strap. * * @return ServerBootStrap */
Creates server boot strap
createServerBootStrap
{ "repo_name": "VinodKumarS-Huawei/ietf96yang", "path": "protocols/pcep/ctl/src/main/java/org/onosproject/pcep/controller/impl/Controller.java", "license": "apache-2.0", "size": 6144 }
[ "java.util.concurrent.Executors", "org.jboss.netty.bootstrap.ServerBootstrap", "org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory" ]
import java.util.concurrent.Executors; import org.jboss.netty.bootstrap.ServerBootstrap; import org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory;
import java.util.concurrent.*; import org.jboss.netty.bootstrap.*; import org.jboss.netty.channel.socket.nio.*;
[ "java.util", "org.jboss.netty" ]
java.util; org.jboss.netty;
1,601,157
public Role getById(int id) throws DataAccException { return super.getByPk(Role.class, id); }
Role function(int id) throws DataAccException { return super.getByPk(Role.class, id); }
/** * Retrieve a Role object from database given its id * * @param id primary key of Role object * @return the Role object identified by the id * @throws DataAccException on error */
Retrieve a Role object from database given its id
getById
{ "repo_name": "terrex/tntconcept-materials-testing", "path": "src/main/java/com/autentia/intra/dao/hibernate/RoleDAO.java", "license": "gpl-2.0", "size": 4178 }
[ "com.autentia.intra.businessobject.Role", "com.autentia.intra.dao.DataAccException" ]
import com.autentia.intra.businessobject.Role; import com.autentia.intra.dao.DataAccException;
import com.autentia.intra.businessobject.*; import com.autentia.intra.dao.*;
[ "com.autentia.intra" ]
com.autentia.intra;
1,462,664
protected void initViews(View layout) { Log.i(TAG, "recycler view setup"); if (layout == null) return; recyclerView = (RecyclerView) layout.findViewById(getRecyclerLayoutId()); if (recyclerView != null) { recyclerView.setHasFixedSize(recyclerHasFixedSize()); ...
void function(View layout) { Log.i(TAG, STR); if (layout == null) return; recyclerView = (RecyclerView) layout.findViewById(getRecyclerLayoutId()); if (recyclerView != null) { recyclerView.setHasFixedSize(recyclerHasFixedSize()); layoutManager = getLayoutManager(); if (layoutManager != null) recyclerView.setLayoutManag...
/** * <p>Setup views with layout root view * Override this function and write the code after call super.initViews(layout) method if you * want to initializer your others views reference on your own class derived of this * base class<p/> * * @param layout View root */
Setup views with layout root view Override this function and write the code after call super.initViews(layout) method if you want to initializer your others views reference on your own class derived of this base class
initViews
{ "repo_name": "fvasquezjatar/fermat-unused", "path": "fermat-android-api/src/main/java/com/bitdubai/fermat_android_api/ui/fragments/FermatListFragment.java", "license": "mit", "size": 5104 }
[ "android.graphics.Color", "android.support.v4.widget.SwipeRefreshLayout", "android.support.v7.widget.RecyclerView", "android.util.Log", "android.view.View" ]
import android.graphics.Color; import android.support.v4.widget.SwipeRefreshLayout; import android.support.v7.widget.RecyclerView; import android.util.Log; import android.view.View;
import android.graphics.*; import android.support.v4.widget.*; import android.support.v7.widget.*; import android.util.*; import android.view.*;
[ "android.graphics", "android.support", "android.util", "android.view" ]
android.graphics; android.support; android.util; android.view;
2,149,326
private void addModuleNameToDisambiguationMap(ModuleName moduleName) { addNameToGenericDisambiguationMap(disambiguationMapForModuleNames, moduleName.toSourceText()); }
void function(ModuleName moduleName) { addNameToGenericDisambiguationMap(disambiguationMapForModuleNames, moduleName.toSourceText()); }
/** * Adds a module name to the module name disambiguation map. * @param moduleName the module name to be added. */
Adds a module name to the module name disambiguation map
addModuleNameToDisambiguationMap
{ "repo_name": "levans/Open-Quark", "path": "src/CAL_Platform/src/org/openquark/cal/caldoc/HTMLDocumentationGenerator.java", "license": "bsd-3-clause", "size": 414134 }
[ "org.openquark.cal.compiler.ModuleName" ]
import org.openquark.cal.compiler.ModuleName;
import org.openquark.cal.compiler.*;
[ "org.openquark.cal" ]
org.openquark.cal;
669,396
public void testSetSeriesURLGenerator() { CategoryPlot plot = (CategoryPlot) this.chart.getPlot(); CategoryItemRenderer renderer = plot.getRenderer(); StandardCategoryURLGenerator url1 = new StandardCategoryURLGenerator(); renderer.setSeriesItemURLGenerator(0, url1); ...
void function() { CategoryPlot plot = (CategoryPlot) this.chart.getPlot(); CategoryItemRenderer renderer = plot.getRenderer(); StandardCategoryURLGenerator url1 = new StandardCategoryURLGenerator(); renderer.setSeriesItemURLGenerator(0, url1); CategoryURLGenerator url2 = renderer.getItemURLGenerator(0, 0); assertTrue(u...
/** * Check that setting a URL generator for a series does override the * default generator. */
Check that setting a URL generator for a series does override the default generator
testSetSeriesURLGenerator
{ "repo_name": "raedle/univis", "path": "lib/jfreechart-1.0.1/src/org/jfree/chart/junit/StackedAreaChartTests.java", "license": "lgpl-2.1", "size": 7268 }
[ "org.jfree.chart.plot.CategoryPlot", "org.jfree.chart.renderer.category.CategoryItemRenderer", "org.jfree.chart.urls.CategoryURLGenerator", "org.jfree.chart.urls.StandardCategoryURLGenerator" ]
import org.jfree.chart.plot.CategoryPlot; import org.jfree.chart.renderer.category.CategoryItemRenderer; import org.jfree.chart.urls.CategoryURLGenerator; import org.jfree.chart.urls.StandardCategoryURLGenerator;
import org.jfree.chart.plot.*; import org.jfree.chart.renderer.category.*; import org.jfree.chart.urls.*;
[ "org.jfree.chart" ]
org.jfree.chart;
2,092,745
private Result pLexerScala$xmlPIChar(final int yyStart) throws IOException { int yyC; Result yyResult; int yyPredIndex; boolean yyPredMatched; Void yyValue; ParseError yyError = ParseError.DUMMY; // Alternative 1. yyPredMatched = false; yyC = character...
private Result pLexerScala$xmlPIChar(final int yyStart) throws IOException { int yyC; Result yyResult; int yyPredIndex; boolean yyPredMatched; Void yyValue; ParseError yyError = ParseError.DUMMY; yyPredMatched = false; yyC = character(yyStart); if ('?' == yyC) { yyPredIndex = yyStart + 1; yyC = character(yyPredIndex); ...
/** * Parse nonterminal * org.netbeans.modules.scala.core.rats.LexerScala.xmlPIChar. * * @param yyStart The index. * @return The result. * @throws IOException Signals an I/O error. */
Parse nonterminal org.netbeans.modules.scala.core.rats.LexerScala.xmlPIChar
pLexerScala$xmlPIChar
{ "repo_name": "vnkmr7620/kojo", "path": "ScalaEditorLite/src/org/netbeans/modules/scala/core/rats/LexerScala.java", "license": "gpl-3.0", "size": 391546 }
[ "java.io.IOException", "xtc.parser.ParseError", "xtc.parser.Result" ]
import java.io.IOException; import xtc.parser.ParseError; import xtc.parser.Result;
import java.io.*; import xtc.parser.*;
[ "java.io", "xtc.parser" ]
java.io; xtc.parser;
1,635,059
public List<TreeNode<E>> getChildren() { List<TreeNode<E>> returnValue; this.childLock.lock(); returnValue = Collections.unmodifiableList( new ArrayList<>(this.children)); this.childLock.unlock(); return returnValue; } protected TreeNode(final...
List<TreeNode<E>> function() { List<TreeNode<E>> returnValue; this.childLock.lock(); returnValue = Collections.unmodifiableList( new ArrayList<>(this.children)); this.childLock.unlock(); return returnValue; } protected TreeNode(final E element) { this(element, null); } protected TreeNode(final E element, final TreeNode...
/** * Returns the tree node's children. * * @return the children. */
Returns the tree node's children
getChildren
{ "repo_name": "aftenkap/jutility-common", "path": "src/main/java/org/jutility/common/datatype/tree/TreeNode.java", "license": "apache-2.0", "size": 10106 }
[ "java.util.ArrayList", "java.util.Collections", "java.util.LinkedList", "java.util.List", "java.util.concurrent.locks.ReentrantLock" ]
import java.util.ArrayList; import java.util.Collections; import java.util.LinkedList; import java.util.List; import java.util.concurrent.locks.ReentrantLock;
import java.util.*; import java.util.concurrent.locks.*;
[ "java.util" ]
java.util;
2,290,181
public static Range iterateRangeBounds(XYDataset dataset, boolean includeInterval) { double minimum = Double.POSITIVE_INFINITY; double maximum = Double.NEGATIVE_INFINITY; int seriesCount = dataset.getSeriesCount(); // handle three cases by dataset type if ...
static Range function(XYDataset dataset, boolean includeInterval) { double minimum = Double.POSITIVE_INFINITY; double maximum = Double.NEGATIVE_INFINITY; int seriesCount = dataset.getSeriesCount(); if (includeInterval && dataset instanceof IntervalXYDataset) { IntervalXYDataset ixyd = (IntervalXYDataset) dataset; for (...
/** * Iterates over the data items of the xy dataset to find * the range bounds. * * @param dataset the dataset (<code>null</code> not permitted). * @param includeInterval a flag that determines, for an * {@link IntervalXYDataset}, whether the y-interval or just the ...
Iterates over the data items of the xy dataset to find the range bounds
iterateRangeBounds
{ "repo_name": "sebkur/JFreeChart", "path": "src/main/java/org/jfree/data/general/DatasetUtilities.java", "license": "lgpl-3.0", "size": 97375 }
[ "org.jfree.data.Range", "org.jfree.data.xy.IntervalXYDataset", "org.jfree.data.xy.OHLCDataset", "org.jfree.data.xy.XYDataset" ]
import org.jfree.data.Range; import org.jfree.data.xy.IntervalXYDataset; import org.jfree.data.xy.OHLCDataset; import org.jfree.data.xy.XYDataset;
import org.jfree.data.*; import org.jfree.data.xy.*;
[ "org.jfree.data" ]
org.jfree.data;
2,137,954
public void addCommand(final Cmd cmd) { this.commands.put(cmd.getName(), cmd); }
void function(final Cmd cmd) { this.commands.put(cmd.getName(), cmd); }
/** * Add a command. * <p/> * @param cmd The command to add. */
Add a command.
addCommand
{ "repo_name": "ladygagapowerbot/bachelor-thesis-implementation", "path": "lib/Encog/src/main/java/org/encog/app/analyst/EncogAnalyst.java", "license": "mit", "size": 25071 }
[ "org.encog.app.analyst.commands.Cmd" ]
import org.encog.app.analyst.commands.Cmd;
import org.encog.app.analyst.commands.*;
[ "org.encog.app" ]
org.encog.app;
2,571,377
public List<ClassifiedClass> getClasses() { return classes; }
List<ClassifiedClass> function() { return classes; }
/** * Gets the classes. * * <p>An array of up to ten class-confidence pairs sorted in descending order of confidence. * * @return the classes */
Gets the classes. An array of up to ten class-confidence pairs sorted in descending order of confidence
getClasses
{ "repo_name": "watson-developer-cloud/java-sdk", "path": "natural-language-classifier/src/main/java/com/ibm/watson/natural_language_classifier/v1/model/CollectionItem.java", "license": "apache-2.0", "size": 1632 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,767,650
public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z) { modelRenderer.rotateAngleX = x; modelRenderer.rotateAngleY = y; modelRenderer.rotateAngleZ = z; }
void function(ModelRenderer modelRenderer, float x, float y, float z) { modelRenderer.rotateAngleX = x; modelRenderer.rotateAngleY = y; modelRenderer.rotateAngleZ = z; }
/** * This is a helper function from Tabula to set the rotation of model parts */
This is a helper function from Tabula to set the rotation of model parts
setRotateAngle
{ "repo_name": "Suatae/MechinasMagickOld", "path": "src/main/java/com/suatae/mechinasmagick/client/models/Casing.java", "license": "gpl-2.0", "size": 2375 }
[ "net.minecraft.client.model.ModelRenderer" ]
import net.minecraft.client.model.ModelRenderer;
import net.minecraft.client.model.*;
[ "net.minecraft.client" ]
net.minecraft.client;
1,866,308
int updateByPrimaryKeyWithBLOBs(DBLogBooks record);
int updateByPrimaryKeyWithBLOBs(DBLogBooks record);
/** * This method was generated by MyBatis Generator. * This method corresponds to the database table logbooks * * @mbggenerated Tue May 26 15:53:09 CST 2015 */
This method was generated by MyBatis Generator. This method corresponds to the database table logbooks
updateByPrimaryKeyWithBLOBs
{ "repo_name": "wolabs/womano", "path": "main/java/com/culabs/unicomportal/dao/DBLogBooksMapper.java", "license": "apache-2.0", "size": 1791 }
[ "com.culabs.unicomportal.model.db.DBLogBooks" ]
import com.culabs.unicomportal.model.db.DBLogBooks;
import com.culabs.unicomportal.model.db.*;
[ "com.culabs.unicomportal" ]
com.culabs.unicomportal;
1,521,007
protected User getScanUser(){ return this.scanUser; }
User function(){ return this.scanUser; }
/** * Gets the user that will be used in the scanning. * * @return the scan user */
Gets the user that will be used in the scanning
getScanUser
{ "repo_name": "profjrr/zaproxy", "path": "src/org/zaproxy/zap/spider/Spider.java", "license": "apache-2.0", "size": 20698 }
[ "org.zaproxy.zap.users.User" ]
import org.zaproxy.zap.users.User;
import org.zaproxy.zap.users.*;
[ "org.zaproxy.zap" ]
org.zaproxy.zap;
431,862
@Override public String getProperty(String key, String defaultValue) throws SecurityException, IllegalStateException { return decrypt(super.getProperty(key, defaultValue)); } /** * Set a property {@see java.util.Properties#setProperty(java.lang.String, java.lang.String)}
String function(String key, String defaultValue) throws SecurityException, IllegalStateException { return decrypt(super.getProperty(key, defaultValue)); } /** * Set a property {@see java.util.Properties#setProperty(java.lang.String, java.lang.String)}
/** * Obtains the property value for the specified key {@see java.util.Properties.getProperty(java.lang.String)}, * decrypting it if needed. * * @param key the property key * @param defaultValue the default value to return * * @throws IllegalStateException if the TextCryptoProvider is...
Obtains the property value for the specified key java.util.Properties.getProperty(java.lang.String), decrypting it if needed
getProperty
{ "repo_name": "crawlik/ezbake-common-java", "path": "common/src/main/java/ezbake/common/properties/EzProperties.java", "license": "apache-2.0", "size": 16973 }
[ "java.util.Properties", "java.util.Set" ]
import java.util.Properties; import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
29,515
public void contextInitialized(ServletContextEvent event) { try { final ServletContext context = event.getServletContext();
void function(ServletContextEvent event) { try { final ServletContext context = event.getServletContext();
/** * Creates the sole instance of {@link jenkins.model.Jenkins} and register it to the {@link ServletContext}. */
Creates the sole instance of <code>jenkins.model.Jenkins</code> and register it to the <code>ServletContext</code>
contextInitialized
{ "repo_name": "IsCoolEntertainment/debpkg_jenkins", "path": "core/src/main/java/hudson/WebAppMain.java", "license": "mit", "size": 15947 }
[ "javax.servlet.ServletContext", "javax.servlet.ServletContextEvent" ]
import javax.servlet.ServletContext; import javax.servlet.ServletContextEvent;
import javax.servlet.*;
[ "javax.servlet" ]
javax.servlet;
500
private String[] getColors() { Field[] names = Color.class.getFields(); String[] list = new String[names.length]; for (int i = 0; i < list.length; i++) { list[i] = names[i].getName(); } return list; }
String[] function() { Field[] names = Color.class.getFields(); String[] list = new String[names.length]; for (int i = 0; i < list.length; i++) { list[i] = names[i].getName(); } return list; }
/** * Get a array of the colors in the Color class. Note that the EV3 does not * support all of these colors. The colors it supports are: NONE, BLACK, * BLUE, GREEN, YELLOW, RED, WHITE and BROWN. * @return array of the colors */
Get a array of the colors in the Color class. Note that the EV3 does not support all of these colors. The colors it supports are: NONE, BLACK, BLUE, GREEN, YELLOW, RED, WHITE and BROWN
getColors
{ "repo_name": "magnusbae/ThreadedLejosSumoBot", "path": "src/no/itera/lego/util/EV3Helper.java", "license": "mit", "size": 6624 }
[ "java.lang.reflect.Field" ]
import java.lang.reflect.Field;
import java.lang.reflect.*;
[ "java.lang" ]
java.lang;
600,828
public void setAnonymousAuth() { // Anonymous users have a full JID. Use the random resource as the JID's node String resource = getAddress().getResource(); setAddress(new JID(resource, getServerName(), resource, true)); setStatus(Session.STATUS_AUTHENTICATED); if (authToken ...
void function() { String resource = getAddress().getResource(); setAddress(new JID(resource, getServerName(), resource, true)); setStatus(Session.STATUS_AUTHENTICATED); if (authToken == null) { authToken = new AuthToken(resource, true); } sessionManager.addSession(this); }
/** * Initialize the session as an anonymous login. This automatically upgrades the session's * status to authenticated and enables many features that are not available until * authenticated (obtaining managers for example).<p> */
Initialize the session as an anonymous login. This automatically upgrades the session's status to authenticated and enables many features that are not available until authenticated (obtaining managers for example)
setAnonymousAuth
{ "repo_name": "trimnguye/JavaChatServer", "path": "src/java/org/jivesoftware/openfire/session/LocalClientSession.java", "license": "apache-2.0", "size": 36257 }
[ "org.jivesoftware.openfire.auth.AuthToken" ]
import org.jivesoftware.openfire.auth.AuthToken;
import org.jivesoftware.openfire.auth.*;
[ "org.jivesoftware.openfire" ]
org.jivesoftware.openfire;
862,328
@Override protected AWSGlobalAccelerator build(AwsSyncClientParams params) { return new AWSGlobalAcceleratorClient(params); }
AWSGlobalAccelerator function(AwsSyncClientParams params) { return new AWSGlobalAcceleratorClient(params); }
/** * Construct a synchronous implementation of AWSGlobalAccelerator using the current builder configuration. * * @param params * Current builder configuration represented as a parameter object. * @return Fully configured implementation of AWSGlobalAccelerator. */
Construct a synchronous implementation of AWSGlobalAccelerator using the current builder configuration
build
{ "repo_name": "aws/aws-sdk-java", "path": "aws-java-sdk-globalaccelerator/src/main/java/com/amazonaws/services/globalaccelerator/AWSGlobalAcceleratorClientBuilder.java", "license": "apache-2.0", "size": 2444 }
[ "com.amazonaws.client.AwsSyncClientParams" ]
import com.amazonaws.client.AwsSyncClientParams;
import com.amazonaws.client.*;
[ "com.amazonaws.client" ]
com.amazonaws.client;
2,057,893
@Deprecated public static List<String> preferredTestCiphers() { String[] ciphers; try { ciphers = SSLContext.getDefault().getDefaultSSLParameters().getCipherSuites(); } catch (NoSuchAlgorithmException ex) { throw new RuntimeException(ex); } List<String> ciphersMinusGcm = new ArrayLis...
static List<String> function() { String[] ciphers; try { ciphers = SSLContext.getDefault().getDefaultSSLParameters().getCipherSuites(); } catch (NoSuchAlgorithmException ex) { throw new RuntimeException(ex); } List<String> ciphersMinusGcm = new ArrayList<String>(); for (String cipher : ciphers) { if (cipher.contains("_...
/** * Returns the ciphers preferred to use during tests. They may be chosen because they are widely * available or because they are fast. There is no requirement that they provide confidentiality * or integrity. * * @deprecated Not for public use */
Returns the ciphers preferred to use during tests. They may be chosen because they are widely available or because they are fast. There is no requirement that they provide confidentiality or integrity
preferredTestCiphers
{ "repo_name": "pieterjanpintens/grpc-java", "path": "testing/src/main/java/io/grpc/testing/TestUtils.java", "license": "apache-2.0", "size": 8172 }
[ "java.security.NoSuchAlgorithmException", "java.util.ArrayList", "java.util.Collections", "java.util.List", "javax.net.ssl.SSLContext" ]
import java.security.NoSuchAlgorithmException; import java.util.ArrayList; import java.util.Collections; import java.util.List; import javax.net.ssl.SSLContext;
import java.security.*; import java.util.*; import javax.net.ssl.*;
[ "java.security", "java.util", "javax.net" ]
java.security; java.util; javax.net;
2,067,673
public boolean dropCatalogFunction( UnresolvedIdentifier unresolvedIdentifier, boolean ignoreIfNotExist) { final ObjectIdentifier identifier = catalogManager.qualifyIdentifier(unresolvedIdentifier); final ObjectIdentifier normalizedIdentifier = FunctionIdentifier.normaliz...
boolean function( UnresolvedIdentifier unresolvedIdentifier, boolean ignoreIfNotExist) { final ObjectIdentifier identifier = catalogManager.qualifyIdentifier(unresolvedIdentifier); final ObjectIdentifier normalizedIdentifier = FunctionIdentifier.normalizeObjectIdentifier(identifier); final Catalog catalog = catalogMana...
/** * Drops a catalog function by also considering temporary catalog functions. Returns true if a * function was dropped. */
Drops a catalog function by also considering temporary catalog functions. Returns true if a function was dropped
dropCatalogFunction
{ "repo_name": "xccui/flink", "path": "flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/catalog/FunctionCatalog.java", "license": "apache-2.0", "size": 30886 }
[ "org.apache.flink.table.api.TableException", "org.apache.flink.table.api.ValidationException", "org.apache.flink.table.functions.FunctionIdentifier" ]
import org.apache.flink.table.api.TableException; import org.apache.flink.table.api.ValidationException; import org.apache.flink.table.functions.FunctionIdentifier;
import org.apache.flink.table.api.*; import org.apache.flink.table.functions.*;
[ "org.apache.flink" ]
org.apache.flink;
873,738
@Transactional(readOnly=true) public Map<String, AppdefEntityID> findControllableResourceNames(int sessionID, AppdefEntityTypeID aetid) throws SessionNotFoundException, SessionException, PermissionException { AuthzSubject subject = sessionManager.getSubject(sessionID); Map<String, Appdef...
@Transactional(readOnly=true) Map<String, AppdefEntityID> function(int sessionID, AppdefEntityTypeID aetid) throws SessionNotFoundException, SessionException, PermissionException { AuthzSubject subject = sessionManager.getSubject(sessionID); Map<String, AppdefEntityID> result; int groupType; switch (aetid.getType()) { ...
/** * Find names of all controllable resources of a given type. * * @return A map of Service names and AppdefEntityIDs. * @throws PermissionException */
Find names of all controllable resources of a given type
findControllableResourceNames
{ "repo_name": "cc14514/hq6", "path": "hq-server/src/main/java/org/hyperic/hq/bizapp/server/session/ControlBossImpl.java", "license": "unlicense", "size": 22025 }
[ "java.util.Iterator", "java.util.List", "java.util.Map", "org.hyperic.hq.appdef.shared.AppdefEntityConstants", "org.hyperic.hq.appdef.shared.AppdefEntityID", "org.hyperic.hq.appdef.shared.AppdefEntityNotFoundException", "org.hyperic.hq.appdef.shared.AppdefEntityTypeID", "org.hyperic.hq.appdef.shared.A...
import java.util.Iterator; import java.util.List; import java.util.Map; import org.hyperic.hq.appdef.shared.AppdefEntityConstants; import org.hyperic.hq.appdef.shared.AppdefEntityID; import org.hyperic.hq.appdef.shared.AppdefEntityNotFoundException; import org.hyperic.hq.appdef.shared.AppdefEntityTypeID; import org.hyp...
import java.util.*; import org.hyperic.hq.appdef.shared.*; import org.hyperic.hq.auth.shared.*; import org.hyperic.hq.authz.server.session.*; import org.hyperic.hq.authz.shared.*; import org.hyperic.util.pager.*; import org.springframework.transaction.annotation.*;
[ "java.util", "org.hyperic.hq", "org.hyperic.util", "org.springframework.transaction" ]
java.util; org.hyperic.hq; org.hyperic.util; org.springframework.transaction;
992,295
public void setFtlImports(List<FtlImport> ftlImports) { this.ftlImports = ftlImports; }
void function(List<FtlImport> ftlImports) { this.ftlImports = ftlImports; }
/** * The freemarker templates to import for this suite. * * @param ftlImports The freemarker templates to import for this suite. */
The freemarker templates to import for this suite
setFtlImports
{ "repo_name": "bridje/bridje-framework", "path": "bridje-web-srcgen/src/main/java/org/bridje/web/srcgen/uisuite/UISuiteBase.java", "license": "apache-2.0", "size": 15472 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
189,563
@NonNull ImmutableList<File> getRepositories();
ImmutableList<File> getRepositories();
/** * Returns the location of artifact repositories built-in the SDK. * @return a non null list of repository folders. */
Returns the location of artifact repositories built-in the SDK
getRepositories
{ "repo_name": "consulo/consulo-android", "path": "tools-base/build-system/builder/src/main/java/com/android/builder/sdk/SdkLoader.java", "license": "apache-2.0", "size": 2143 }
[ "com.google.common.collect.ImmutableList", "java.io.File" ]
import com.google.common.collect.ImmutableList; import java.io.File;
import com.google.common.collect.*; import java.io.*;
[ "com.google.common", "java.io" ]
com.google.common; java.io;
1,598,419
@Reference( name = "org.wso2.carbon.siddhi.extensions.installer.core.internal.SiddhiExtensionsInstallerMicroservice", service = SiddhiAppDeploymentListener.class, cardinality = ReferenceCardinality.MANDATORY, policy = ReferencePolicy.DYNAMIC, unbind = "unsubscribeExtensionsIn...
@Reference( name = STR, service = SiddhiAppDeploymentListener.class, cardinality = ReferenceCardinality.MANDATORY, policy = ReferencePolicy.DYNAMIC, unbind = STR ) void function(SiddhiAppDeploymentListener extensionsInstallerListener) { StreamProcessorDataHolder.addSiddhiAppDeploymentListener(extensionsInstallerListene...
/** * The bind method, which gets called for the Extensions Installer listener. * * @param extensionsInstallerListener Extensions Installer listener. */
The bind method, which gets called for the Extensions Installer listener
subscribeExtensionsInstallerListener
{ "repo_name": "wso2/carbon-analytics", "path": "components/org.wso2.carbon.streaming.integrator.core/src/main/java/org/wso2/carbon/streaming/integrator/core/internal/StreamProcessorDeployer.java", "license": "apache-2.0", "size": 25702 }
[ "org.osgi.service.component.annotations.Reference", "org.osgi.service.component.annotations.ReferenceCardinality", "org.osgi.service.component.annotations.ReferencePolicy", "org.wso2.carbon.streaming.integrator.common.SiddhiAppDeploymentListener" ]
import org.osgi.service.component.annotations.Reference; import org.osgi.service.component.annotations.ReferenceCardinality; import org.osgi.service.component.annotations.ReferencePolicy; import org.wso2.carbon.streaming.integrator.common.SiddhiAppDeploymentListener;
import org.osgi.service.component.annotations.*; import org.wso2.carbon.streaming.integrator.common.*;
[ "org.osgi.service", "org.wso2.carbon" ]
org.osgi.service; org.wso2.carbon;
2,388,800
@Override protected PropertyValue getValueFromQueryResult(Object result, StaticListClass propertyDefinition) { PropertyValue value = super.getValueFromQueryResult(result, propertyDefinition); if (value != null && value.getValue() instanceof String) { Map<String, ListItem> valueM...
PropertyValue function(Object result, StaticListClass propertyDefinition) { PropertyValue value = super.getValueFromQueryResult(result, propertyDefinition); if (value != null && value.getValue() instanceof String) { Map<String, ListItem> valueMap = StaticListClass.getMapFromString(propertyDefinition.getValues()); addLa...
/** * Constructs a property value from the given result of the given static list class. * * @param result The result of a database query or the value from a REST query * @param propertyDefinition The definition of the static list class * @return The property value, possibly including a label fr...
Constructs a property value from the given result of the given static list class
getValueFromQueryResult
{ "repo_name": "xwiki/xwiki-platform", "path": "xwiki-platform-core/xwiki-platform-rest/xwiki-platform-rest-server/src/main/java/org/xwiki/rest/internal/resources/classes/StaticListClassPropertyValuesProvider.java", "license": "lgpl-2.1", "size": 4456 }
[ "com.xpn.xwiki.objects.classes.ListItem", "com.xpn.xwiki.objects.classes.StaticListClass", "java.util.Map", "org.xwiki.rest.model.jaxb.PropertyValue" ]
import com.xpn.xwiki.objects.classes.ListItem; import com.xpn.xwiki.objects.classes.StaticListClass; import java.util.Map; import org.xwiki.rest.model.jaxb.PropertyValue;
import com.xpn.xwiki.objects.classes.*; import java.util.*; import org.xwiki.rest.model.jaxb.*;
[ "com.xpn.xwiki", "java.util", "org.xwiki.rest" ]
com.xpn.xwiki; java.util; org.xwiki.rest;
1,134,927
private String selectDataPool(Path path, int repl_wanted) throws IOException { TreeMap<Integer, String> pools = new TreeMap<Integer, String>(); int fd = ceph.__open(new Path("/"), CephMount.O_RDONLY, 0); String pool_name = ceph.get_file_pool_name(fd); ceph.close(fd); int replication = g...
String function(Path path, int repl_wanted) throws IOException { TreeMap<Integer, String> pools = new TreeMap<Integer, String>(); int fd = ceph.__open(new Path("/"), CephMount.O_RDONLY, 0); String pool_name = ceph.get_file_pool_name(fd); ceph.close(fd); int replication = getPoolReplication(pool_name); pools.put(new Int...
/** * Select a data pool given the requested replication factor. */
Select a data pool given the requested replication factor
selectDataPool
{ "repo_name": "ceph/cephfs-hadoop", "path": "src/main/java/org/apache/hadoop/fs/ceph/CephFileSystem.java", "license": "lgpl-2.1", "size": 20819 }
[ "com.ceph.fs.CephMount", "java.io.IOException", "java.util.Map", "java.util.TreeMap", "org.apache.hadoop.fs.Path" ]
import com.ceph.fs.CephMount; import java.io.IOException; import java.util.Map; import java.util.TreeMap; import org.apache.hadoop.fs.Path;
import com.ceph.fs.*; import java.io.*; import java.util.*; import org.apache.hadoop.fs.*;
[ "com.ceph.fs", "java.io", "java.util", "org.apache.hadoop" ]
com.ceph.fs; java.io; java.util; org.apache.hadoop;
1,479,427
public void showPresence(boolean showPresence) { mPresenceView.setVisibility(showPresence ? View.VISIBLE : View.GONE); }
void function(boolean showPresence) { mPresenceView.setVisibility(showPresence ? View.VISIBLE : View.GONE); }
/** * Turn on/off showing the presence. * @hide this is here for consistency with setStared/showStar and should be public */
Turn on/off showing the presence
showPresence
{ "repo_name": "rex-xxx/mt6572_x201", "path": "packages/experimental/LoaderApp/src/com/android/loaderapp/ContactHeaderWidget.java", "license": "gpl-2.0", "size": 25603 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
1,779,751
private Component instantiateComponent(Node node) { String tag = node.nodeName(); ComponentMapper componentMapper = Design.getComponentMapper(); Component component = componentMapper.tagToComponent(tag, Design.getComponentFactory(), this); assert tag.equals(componen...
Component function(Node node) { String tag = node.nodeName(); ComponentMapper componentMapper = Design.getComponentMapper(); Component component = componentMapper.tagToComponent(tag, Design.getComponentFactory(), this); assert tag.equals(componentMapper.componentToTag(component, this)); return component; }
/** * Creates a Component corresponding to the given node. Does not set the * attributes for the created object. * * @param node * a node of an html tree * @return a Component corresponding to node, with no attributes set. */
Creates a Component corresponding to the given node. Does not set the attributes for the created object
instantiateComponent
{ "repo_name": "carrchang/vaadin", "path": "server/src/com/vaadin/ui/declarative/DesignContext.java", "license": "apache-2.0", "size": 27543 }
[ "com.vaadin.ui.Component", "com.vaadin.ui.declarative.Design", "org.jsoup.nodes.Node" ]
import com.vaadin.ui.Component; import com.vaadin.ui.declarative.Design; import org.jsoup.nodes.Node;
import com.vaadin.ui.*; import com.vaadin.ui.declarative.*; import org.jsoup.nodes.*;
[ "com.vaadin.ui", "org.jsoup.nodes" ]
com.vaadin.ui; org.jsoup.nodes;
2,214,441
public void warn(String msg, Object arg0, Object arg1, Object arg2) { logIfEnabled(Level.WARNING, null, msg, arg0, arg1, arg2, null); }
void function(String msg, Object arg0, Object arg1, Object arg2) { logIfEnabled(Level.WARNING, null, msg, arg0, arg1, arg2, null); }
/** * Log a warning message. */
Log a warning message
warn
{ "repo_name": "dankito/ormlite-jpa-core", "path": "src/main/java/com/j256/ormlite/logger/Logger.java", "license": "isc", "size": 17794 }
[ "com.j256.ormlite.logger.Log" ]
import com.j256.ormlite.logger.Log;
import com.j256.ormlite.logger.*;
[ "com.j256.ormlite" ]
com.j256.ormlite;
1,024,527
public PainterChain prependPainter(Painter p) { Painter[] newChain = new Painter[chain.length + 1]; System.arraycopy(chain, 1, newChain, 0, chain.length); newChain[0] = p; return new PainterChain(newChain); } /** * {@inheritDoc}
PainterChain function(Painter p) { Painter[] newChain = new Painter[chain.length + 1]; System.arraycopy(chain, 1, newChain, 0, chain.length); newChain[0] = p; return new PainterChain(newChain); } /** * {@inheritDoc}
/** * Creates a new chain based on the existing chain with the new element added * at the beginning * * @param p new painter * @return new chain element */
Creates a new chain based on the existing chain with the new element added at the beginning
prependPainter
{ "repo_name": "JrmyDev/CodenameOne", "path": "CodenameOne/src/com/codename1/ui/painter/PainterChain.java", "license": "gpl-2.0", "size": 5886 }
[ "com.codename1.ui.Painter" ]
import com.codename1.ui.Painter;
import com.codename1.ui.*;
[ "com.codename1.ui" ]
com.codename1.ui;
2,284,202
public static void getAllPrivateEndpointConnections( com.azure.resourcemanager.videoanalyzer.VideoAnalyzerManager manager) { manager.privateEndpointConnections().listWithResponse("contoso", "contososports", Context.NONE); }
static void function( com.azure.resourcemanager.videoanalyzer.VideoAnalyzerManager manager) { manager.privateEndpointConnections().listWithResponse(STR, STR, Context.NONE); }
/** * Sample code: Get all private endpoint connections. * * @param manager Entry point to VideoAnalyzerManager. */
Sample code: Get all private endpoint connections
getAllPrivateEndpointConnections
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/videoanalyzer/azure-resourcemanager-videoanalyzer/src/samples/java/com/azure/resourcemanager/videoanalyzer/generated/PrivateEndpointConnectionsListSamples.java", "license": "mit", "size": 947 }
[ "com.azure.core.util.Context" ]
import com.azure.core.util.Context;
import com.azure.core.util.*;
[ "com.azure.core" ]
com.azure.core;
2,866,829
public static int getConfigIntegerValue(ConfigType configType) { String value = getConfigStringValue(configType); return Integer.parseInt(value); }
static int function(ConfigType configType) { String value = getConfigStringValue(configType); return Integer.parseInt(value); }
/** * Returns the integer value of a configuration parameter. * * @param configType Type of the configuration parameter * @return Integer value of the configuration parameter * @throws IllegalStateException Configuration parameter undefined */
Returns the integer value of a configuration parameter
getConfigIntegerValue
{ "repo_name": "sismics/docs", "path": "docs-core/src/main/java/com/sismics/docs/core/util/ConfigUtil.java", "license": "gpl-2.0", "size": 2522 }
[ "com.sismics.docs.core.constant.ConfigType" ]
import com.sismics.docs.core.constant.ConfigType;
import com.sismics.docs.core.constant.*;
[ "com.sismics.docs" ]
com.sismics.docs;
1,889,793
public static void sqluser(StringBuilder buf, List<? extends CharSequence> parsedArgs) throws SQLException { zeroArgumentFunctionCall(buf, "user", "user", parsedArgs); }
static void function(StringBuilder buf, List<? extends CharSequence> parsedArgs) throws SQLException { zeroArgumentFunctionCall(buf, "user", "user", parsedArgs); }
/** * user translation * * @param buf The buffer to append into * @param parsedArgs arguments * @throws SQLException if something wrong happens */
user translation
sqluser
{ "repo_name": "golovnin/pgjdbc", "path": "pgjdbc/src/main/java/org/postgresql/jdbc/EscapedFunctions2.java", "license": "bsd-2-clause", "size": 25169 }
[ "java.sql.SQLException", "java.util.List" ]
import java.sql.SQLException; import java.util.List;
import java.sql.*; import java.util.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
1,012,333
private boolean shallPerformScrollPositionChecks(AccessibilityEvent event) { if (event.getEventType() != AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED && event.getEventType() != AccessibilityEvent.TYPE_VIEW_SCROLLED) return false; if (event.getFromIndex() < 0 || event.ge...
boolean function(AccessibilityEvent event) { if (event.getEventType() != AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED && event.getEventType() != AccessibilityEvent.TYPE_VIEW_SCROLLED) return false; if (event.getFromIndex() < 0 event.getToIndex() < 0 event.getItemCount() < 0) return false; if (!performInteractionCheck...
/** * Returns true iff a scroll position check shall be performed * @param event * @return */
Returns true iff a scroll position check shall be performed
shallPerformScrollPositionChecks
{ "repo_name": "simonlang7/coastdove-core", "path": "app/src/main/java/simonlang/coastdove/core/detection/AppDetectionData.java", "license": "gpl-3.0", "size": 22695 }
[ "android.view.accessibility.AccessibilityEvent" ]
import android.view.accessibility.AccessibilityEvent;
import android.view.accessibility.*;
[ "android.view" ]
android.view;
2,464,110
public Collection<CacheClientProxy> getClientProxies() { return Collections.unmodifiableCollection(_clientProxies.values()); }
Collection<CacheClientProxy> function() { return Collections.unmodifiableCollection(_clientProxies.values()); }
/** * Returns an unmodifiable Collection of known {@code CacheClientProxy} instances. The * collection is not static so its contents may change. * * @return the collection of known {@code CacheClientProxy} instances */
Returns an unmodifiable Collection of known CacheClientProxy instances. The collection is not static so its contents may change
getClientProxies
{ "repo_name": "davinash/geode", "path": "geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/CacheClientNotifier.java", "license": "apache-2.0", "size": 82063 }
[ "java.util.Collection", "java.util.Collections" ]
import java.util.Collection; import java.util.Collections;
import java.util.*;
[ "java.util" ]
java.util;
581,069
public static void assertOneSnapshotThatMatches(Admin admin, SnapshotProtos.SnapshotDescription snapshot) throws IOException { assertOneSnapshotThatMatches(admin, snapshot.getName(), TableName.valueOf(snapshot.getTable())); }
static void function(Admin admin, SnapshotProtos.SnapshotDescription snapshot) throws IOException { assertOneSnapshotThatMatches(admin, snapshot.getName(), TableName.valueOf(snapshot.getTable())); }
/** * Make sure that there is only one snapshot returned from the master */
Make sure that there is only one snapshot returned from the master
assertOneSnapshotThatMatches
{ "repo_name": "ChinmaySKulkarni/hbase", "path": "hbase-server/src/test/java/org/apache/hadoop/hbase/snapshot/SnapshotTestingUtils.java", "license": "apache-2.0", "size": 36762 }
[ "java.io.IOException", "org.apache.hadoop.hbase.TableName", "org.apache.hadoop.hbase.client.Admin", "org.apache.hadoop.hbase.client.SnapshotDescription", "org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos" ]
import java.io.IOException; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.client.Admin; import org.apache.hadoop.hbase.client.SnapshotDescription; import org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos;
import java.io.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.shaded.protobuf.generated.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
1,227,043
List<Player> getPlayers();
List<Player> getPlayers();
/** * Gets a list of all valid players from the player cache. * * @return a list of all players */
Gets a list of all valid players from the player cache
getPlayers
{ "repo_name": "Sethtroll/runelite", "path": "runelite-api/src/main/java/net/runelite/api/Client.java", "license": "bsd-2-clause", "size": 40333 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,078,482
public boolean isWrapperFor(Class<?> interfaces) throws SQLException { return interfaces.isInstance(this); }
boolean function(Class<?> interfaces) throws SQLException { return interfaces.isInstance(this); }
/** * Returns false unless <code>interfaces</code> is implemented * * @param interfaces a Class defining an interface. * @return true if this implements the interface or * directly or indirectly wraps an object * ...
Returns false unless <code>interfaces</code> is implemented
isWrapperFor
{ "repo_name": "scnakandala/derby", "path": "java/client/org/apache/derby/client/am/ClientDatabaseMetaData.java", "license": "apache-2.0", "size": 111642 }
[ "java.sql.SQLException" ]
import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
240,073
public static DataType[] initDataType(CarbonTable carbonTable, String tableName, int measureCount) { DataType[] type = new DataType[measureCount]; for (int i = 0; i < type.length; i++) { type[i] = DataType.DOUBLE; } List<CarbonMeasure> measures = carbonTable.getMeasureByTableName(tableName...
static DataType[] function(CarbonTable carbonTable, String tableName, int measureCount) { DataType[] type = new DataType[measureCount]; for (int i = 0; i < type.length; i++) { type[i] = DataType.DOUBLE; } List<CarbonMeasure> measures = carbonTable.getMeasureByTableName(tableName); for (int i = 0; i < measureCount; i++)...
/** * initialise data type for measures for their storage format */
initialise data type for measures for their storage format
initDataType
{ "repo_name": "nehabhardwaj01/incubator-carbondata", "path": "processing/src/main/java/org/apache/carbondata/processing/util/CarbonDataProcessorUtil.java", "license": "apache-2.0", "size": 24754 }
[ "java.util.List", "org.apache.carbondata.core.metadata.datatype.DataType", "org.apache.carbondata.core.metadata.schema.table.CarbonTable", "org.apache.carbondata.core.metadata.schema.table.column.CarbonMeasure" ]
import java.util.List; import org.apache.carbondata.core.metadata.datatype.DataType; import org.apache.carbondata.core.metadata.schema.table.CarbonTable; import org.apache.carbondata.core.metadata.schema.table.column.CarbonMeasure;
import java.util.*; import org.apache.carbondata.core.metadata.datatype.*; import org.apache.carbondata.core.metadata.schema.table.*; import org.apache.carbondata.core.metadata.schema.table.column.*;
[ "java.util", "org.apache.carbondata" ]
java.util; org.apache.carbondata;
2,697,137
public static void createParameterizedQueryRegion() { try { if (logger.isDebugEnabled()) { logger.debug("Starting creation of __ParameterizedQueries__ region"); } InternalCache cache = (InternalCache) CacheFactory.getAnyInstance(); if (cache != null) { final InternalRegion...
static void function() { try { if (logger.isDebugEnabled()) { logger.debug(STR); } InternalCache cache = (InternalCache) CacheFactory.getAnyInstance(); if (cache != null) { final InternalRegionArguments regionArguments = new InternalRegionArguments(); regionArguments.setIsUsedForMetaRegion(true); final AttributesFactor...
/** * This method will create a REPLICATED region named _ParameterizedQueries__. In developer REST * APIs, this region will be used to store the queryId and queryString as a key and value * respectively. */
This method will create a REPLICATED region named _ParameterizedQueries__. In developer REST APIs, this region will be used to store the queryId and queryString as a key and value respectively
createParameterizedQueryRegion
{ "repo_name": "prasi-in/geode", "path": "geode-core/src/main/java/org/apache/geode/management/internal/RestAgent.java", "license": "apache-2.0", "size": 9579 }
[ "org.apache.geode.cache.AttributesFactory", "org.apache.geode.cache.CacheFactory", "org.apache.geode.cache.DataPolicy", "org.apache.geode.cache.RegionAttributes", "org.apache.geode.cache.Scope", "org.apache.geode.internal.cache.InternalCache", "org.apache.geode.internal.cache.InternalRegionArguments" ]
import org.apache.geode.cache.AttributesFactory; import org.apache.geode.cache.CacheFactory; import org.apache.geode.cache.DataPolicy; import org.apache.geode.cache.RegionAttributes; import org.apache.geode.cache.Scope; import org.apache.geode.internal.cache.InternalCache; import org.apache.geode.internal.cache.Interna...
import org.apache.geode.cache.*; import org.apache.geode.internal.cache.*;
[ "org.apache.geode" ]
org.apache.geode;
1,631,807
@SuppressWarnings("PMD.JUnit4TestShouldUseTestAnnotation") private List<IMonitoringRecord> testIt(final List<IMonitoringRecord> eventsToWrite, final boolean keepLoggingTimestamps) throws Exception { final AnalysisController analysisController = new AnalysisController(); final ListReader<IMonitoringRecord> read...
@SuppressWarnings(STR) List<IMonitoringRecord> function(final List<IMonitoringRecord> eventsToWrite, final boolean keepLoggingTimestamps) throws Exception { final AnalysisController analysisController = new AnalysisController(); final ListReader<IMonitoringRecord> reader = new ListReader<IMonitoringRecord>(new Configur...
/** * The actual (parameterized) Test. * * @param eventsToWrite * * @return * * @throws Exception * If something went wrong during the test. */
The actual (parameterized) Test
testIt
{ "repo_name": "HaStr/kieker", "path": "kieker-tools/test/kieker/tools/logReplayer/filter/TestMonitoringRecordLoggerFilter.java", "license": "apache-2.0", "size": 10279 }
[ "java.io.File", "java.util.List", "org.junit.Assert" ]
import java.io.File; import java.util.List; import org.junit.Assert;
import java.io.*; import java.util.*; import org.junit.*;
[ "java.io", "java.util", "org.junit" ]
java.io; java.util; org.junit;
2,523,843
public final XPathContext getXPathContext() { return m_execContext; }
final XPathContext function() { return m_execContext; }
/** * The XPath execution context we are operating on. * * @return XPath execution context this iterator is operating on, * or null if setRoot has not been called. */
The XPath execution context we are operating on
getXPathContext
{ "repo_name": "haikuowuya/android_system_code", "path": "src/com/sun/org/apache/xpath/internal/axes/LocPathIterator.java", "license": "apache-2.0", "size": 28898 }
[ "com.sun.org.apache.xpath.internal.XPathContext" ]
import com.sun.org.apache.xpath.internal.XPathContext;
import com.sun.org.apache.xpath.internal.*;
[ "com.sun.org" ]
com.sun.org;
1,657,387
public HashSet<String> getAttributes() { if (attributes.isEmpty()) { for (Stop stop : Stop.values()) { attributes.add(stop.toString()); } } return attributes; }
HashSet<String> function() { if (attributes.isEmpty()) { for (Stop stop : Stop.values()) { attributes.add(stop.toString()); } } return attributes; }
/** * Returns all Attributes of this action. * * @return attributes */
Returns all Attributes of this action
getAttributes
{ "repo_name": "midoblgsm/occi4java", "path": "infrastructure/src/main/java/occi/infrastructure/compute/actions/StopAction.java", "license": "lgpl-3.0", "size": 3589 }
[ "java.util.HashSet" ]
import java.util.HashSet;
import java.util.*;
[ "java.util" ]
java.util;
1,963,423
static String getTServersZkPath(ClientContext context) { requireNonNull(context); return context.getZooKeeperRoot() + Constants.ZTSERVERS; }
static String getTServersZkPath(ClientContext context) { requireNonNull(context); return context.getZooKeeperRoot() + Constants.ZTSERVERS; }
/** * Get the parent ZNode for tservers for the given instance * * @param context * ClientContext * @return The tservers znode for the instance */
Get the parent ZNode for tservers for the given instance
getTServersZkPath
{ "repo_name": "lstav/accumulo", "path": "server/base/src/main/java/org/apache/accumulo/server/util/Admin.java", "license": "apache-2.0", "size": 24374 }
[ "java.util.Objects", "org.apache.accumulo.core.Constants", "org.apache.accumulo.core.clientImpl.ClientContext" ]
import java.util.Objects; import org.apache.accumulo.core.Constants; import org.apache.accumulo.core.clientImpl.ClientContext;
import java.util.*; import org.apache.accumulo.core.*;
[ "java.util", "org.apache.accumulo" ]
java.util; org.apache.accumulo;
2,730,344
public static java.util.Set extractPatTreatmentPlanSet(ims.domain.ILightweightDomainFactory domainFactory, ims.oncology.vo.PatTreatmentPlanRadiotherapyDialogVoCollection voCollection) { return extractPatTreatmentPlanSet(domainFactory, voCollection, null, new HashMap()); }
static java.util.Set function(ims.domain.ILightweightDomainFactory domainFactory, ims.oncology.vo.PatTreatmentPlanRadiotherapyDialogVoCollection voCollection) { return extractPatTreatmentPlanSet(domainFactory, voCollection, null, new HashMap()); }
/** * Create the ims.oncology.domain.objects.PatTreatmentPlan set from the value object collection. * @param domainFactory - used to create existing (persistent) domain objects. * @param voCollection - the collection of value objects */
Create the ims.oncology.domain.objects.PatTreatmentPlan set from the value object collection
extractPatTreatmentPlanSet
{ "repo_name": "open-health-hub/openmaxims-linux", "path": "openmaxims_workspace/ValueObjects/src/ims/oncology/vo/domain/PatTreatmentPlanRadiotherapyDialogVoAssembler.java", "license": "agpl-3.0", "size": 22528 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
611,762
public static void root( ComplexPolar64F a , int N , int k , ComplexPolar64F result ) { result.r = Math.pow(a.r,1.0/N); result.theta = (a.theta + 2.0*k*Math.PI)/N; }
static void function( ComplexPolar64F a , int N , int k , ComplexPolar64F result ) { result.r = Math.pow(a.r,1.0/N); result.theta = (a.theta + 2.0*k*Math.PI)/N; }
/** * Computes the N<sup>th</sup> root of a complex number in polar notation. There are * N distinct N<sup>th</sup> roots. * * @param a Complex number * @param N The root's magnitude * @param k Specifies which root. 0 &le; k < N * @param result Computed root */
Computes the Nth root of a complex number in polar notation. There are N distinct Nth roots
root
{ "repo_name": "MarkLeong1997/ejml", "path": "main/core/src/org/ejml/ops/ComplexMath64F.java", "license": "apache-2.0", "size": 6449 }
[ "org.ejml.data.ComplexPolar64F" ]
import org.ejml.data.ComplexPolar64F;
import org.ejml.data.*;
[ "org.ejml.data" ]
org.ejml.data;
616,800
public ConferenceRoomsPage clickOnSave() { int count = 0; do { if (ExplicitWait.waitForElement(OutOfOrderMap.SAVE_BUTTON, 10)) { saveButton.click(); LogManager .info("The changes on the OutOfOrder has been saved - SaveButton"); count++; if (count == 3) { UIActions.clickAt(BrowserManager.getD...
ConferenceRoomsPage function() { int count = 0; do { if (ExplicitWait.waitForElement(OutOfOrderMap.SAVE_BUTTON, 10)) { saveButton.click(); LogManager .info(STR); count++; if (count == 3) { UIActions.clickAt(BrowserManager.getDriver().findElement( By.xpath(RoomInfoMap.CANCEL_BUTTON))); } } else { count = 4; } } while (c...
/** * This method performs a click on save button. * * @return ConferenceRoomsPage */
This method performs a click on save button
clickOnSave
{ "repo_name": "luisa0110/RMAutomationUIFramework", "path": "Projects/RMAutomationUIFramework/src/main/java/org/fundacionjala/automation/framework/pages/admin/conferencerooms/OutOfOrderPage.java", "license": "cc0-1.0", "size": 7808 }
[ "org.fundacionjala.automation.framework.maps.admin.conferencerooms.OutOfOrderMap", "org.fundacionjala.automation.framework.maps.admin.conferencerooms.RoomInfoMap", "org.fundacionjala.automation.framework.utils.common.BrowserManager", "org.fundacionjala.automation.framework.utils.common.ExplicitWait", "org.f...
import org.fundacionjala.automation.framework.maps.admin.conferencerooms.OutOfOrderMap; import org.fundacionjala.automation.framework.maps.admin.conferencerooms.RoomInfoMap; import org.fundacionjala.automation.framework.utils.common.BrowserManager; import org.fundacionjala.automation.framework.utils.common.ExplicitWait...
import org.fundacionjala.automation.framework.maps.admin.conferencerooms.*; import org.fundacionjala.automation.framework.utils.common.*; import org.openqa.selenium.*; import org.openqa.selenium.support.*;
[ "org.fundacionjala.automation", "org.openqa.selenium" ]
org.fundacionjala.automation; org.openqa.selenium;
2,484,405
private static int[] reorderVisual(byte[] levels) { return BidiLine.reorderVisual(levels); } private static final int INTERNAL_DIRECTION_DEFAULT_LEFT_TO_RIGHT = 0x7e; private static final int INTERMAL_DIRECTION_DEFAULT_RIGHT_TO_LEFT = 0x7f; public BidiBase(char[] text, ...
static int[] function(byte[] levels) { return BidiLine.reorderVisual(levels); } private static final int INTERNAL_DIRECTION_DEFAULT_LEFT_TO_RIGHT = 0x7e; private static final int INTERMAL_DIRECTION_DEFAULT_RIGHT_TO_LEFT = 0x7f; public BidiBase(char[] text, int textStart, byte[] embeddings, int embStart, int paragraphLe...
/** * This is a convenience method that does not use a <code>Bidi</code> object. * It is intended to be used for when an application has determined the levels * of objects (character sequences) and just needs to have them reordered (L2). * This is equivalent to using <code>getVisualMap()</code> on a...
This is a convenience method that does not use a <code>Bidi</code> object. It is intended to be used for when an application has determined the levels of objects (character sequences) and just needs to have them reordered (L2). This is equivalent to using <code>getVisualMap()</code> on a <code>Bidi</code> object
reorderVisual
{ "repo_name": "ohpauleez/soymacchiato", "path": "src/jdk/src/share/classes/sun/text/bidi/BidiBase.java", "license": "gpl-2.0", "size": 152384 }
[ "com.ibm.icu.text.Bidi", "java.text.Bidi" ]
import com.ibm.icu.text.Bidi; import java.text.Bidi;
import com.ibm.icu.text.*; import java.text.*;
[ "com.ibm.icu", "java.text" ]
com.ibm.icu; java.text;
1,353,128
private void initContent(CmsPreviewInfo previewInfo) { setSitePath(previewInfo.getSitePath()); HTML content = new HTML(); Style style = content.getElement().getStyle(); int height = DIALOG_HEIGHT; int width = DIALOG_WIDTH; if (previewInfo.hasPreviewContent()) ...
void function(CmsPreviewInfo previewInfo) { setSitePath(previewInfo.getSitePath()); HTML content = new HTML(); Style style = content.getElement().getStyle(); int height = DIALOG_HEIGHT; int width = DIALOG_WIDTH; if (previewInfo.hasPreviewContent()) { content.setHTML(previewInfo.getPreviewContent()); style.setOverflow(O...
/** * Initializes the preview content.<p> * * @param previewInfo the preview info */
Initializes the preview content
initContent
{ "repo_name": "mediaworx/opencms-core", "path": "src-gwt/org/opencms/gwt/client/ui/CmsPreviewDialog.java", "license": "lgpl-2.1", "size": 11730 }
[ "com.google.gwt.dom.client.Style", "com.google.gwt.user.client.Window", "com.google.gwt.user.client.ui.RootPanel", "org.opencms.gwt.shared.CmsPreviewInfo" ]
import com.google.gwt.dom.client.Style; import com.google.gwt.user.client.Window; import com.google.gwt.user.client.ui.RootPanel; import org.opencms.gwt.shared.CmsPreviewInfo;
import com.google.gwt.dom.client.*; import com.google.gwt.user.client.*; import com.google.gwt.user.client.ui.*; import org.opencms.gwt.shared.*;
[ "com.google.gwt", "org.opencms.gwt" ]
com.google.gwt; org.opencms.gwt;
1,364,340
void removeExperimenter(ExperimenterData exp, TreeImageDisplay refNode) { if (model.getBrowserType() == Browser.ADMIN_EXPLORER) return; if (refNode == null) refNode = getTreeRoot(); List<TreeImageDisplay> nodesToKeep; List l = refNode.getChildrenDisplay(); if (l == null || l.size() == 0) return; Iterat...
void removeExperimenter(ExperimenterData exp, TreeImageDisplay refNode) { if (model.getBrowserType() == Browser.ADMIN_EXPLORER) return; if (refNode == null) refNode = getTreeRoot(); List<TreeImageDisplay> nodesToKeep; List l = refNode.getChildrenDisplay(); if (l == null l.size() == 0) return; Iterator j = l.iterator();...
/** * Removes the specified experimenter from the tree. * * @param exp The experimenter data to remove. * @param refNode The node to remove the experimenter from. */
Removes the specified experimenter from the tree
removeExperimenter
{ "repo_name": "ximenesuk/openmicroscopy", "path": "components/insight/SRC/org/openmicroscopy/shoola/agents/treeviewer/browser/BrowserUI.java", "license": "gpl-2.0", "size": 79520 }
[ "java.util.ArrayList", "java.util.Iterator", "java.util.List", "javax.swing.tree.DefaultTreeModel", "org.openmicroscopy.shoola.agents.util.browser.TreeImageDisplay", "org.openmicroscopy.shoola.agents.util.browser.TreeImageSet" ]
import java.util.ArrayList; import java.util.Iterator; import java.util.List; import javax.swing.tree.DefaultTreeModel; import org.openmicroscopy.shoola.agents.util.browser.TreeImageDisplay; import org.openmicroscopy.shoola.agents.util.browser.TreeImageSet;
import java.util.*; import javax.swing.tree.*; import org.openmicroscopy.shoola.agents.util.browser.*;
[ "java.util", "javax.swing", "org.openmicroscopy.shoola" ]
java.util; javax.swing; org.openmicroscopy.shoola;
1,066,583
public FetchType getFetch() { return FetchType.getFromStringValue(childNode.getAttribute("fetch")); }
FetchType function() { return FetchType.getFromStringValue(childNode.getAttribute("fetch")); }
/** * Returns the <code>fetch</code> attribute * @return the value defined for the attribute <code>fetch</code> */
Returns the <code>fetch</code> attribute
getFetch
{ "repo_name": "forge/javaee-descriptors", "path": "impl/src/main/java/org/jboss/shrinkwrap/descriptor/impl/orm20/ManyToOneImpl.java", "license": "epl-1.0", "size": 15506 }
[ "org.jboss.shrinkwrap.descriptor.api.orm20.FetchType" ]
import org.jboss.shrinkwrap.descriptor.api.orm20.FetchType;
import org.jboss.shrinkwrap.descriptor.api.orm20.*;
[ "org.jboss.shrinkwrap" ]
org.jboss.shrinkwrap;
1,442,580
public void updateItem(int position) { if (mListView != null) { int visiblePosition = mListView.getFirstVisiblePosition(); View view = mListView.getChildAt(position - visiblePosition); multiManager.getView(listData.get(position), position, view, mListView); } else...
void function(int position) { if (mListView != null) { int visiblePosition = mListView.getFirstVisiblePosition(); View view = mListView.getChildAt(position - visiblePosition); multiManager.getView(listData.get(position), position, view, mListView); } else { throw new NullPointerException( STR); } }
/** * update single item by position * @param position */
update single item by position
updateItem
{ "repo_name": "jarlen/RichCommon", "path": "richcommon/src/main/java/cn/jarlen/richcommon/adapter/multiple/MultiAdapter.java", "license": "apache-2.0", "size": 4206 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
39,862
@CheckResult @SuppressWarnings("unchecked") public RequestBuilder<TranscodeType> load(@Nullable Object model) { return loadGeneric(model); }
@SuppressWarnings(STR) RequestBuilder<TranscodeType> function(@Nullable Object model) { return loadGeneric(model); }
/** * Sets the specific model to load data for. * * <p> This method must be called at least once before * {@link #into(com.bumptech.glide.request.target.Target)} is called. </p> * * @param model The model to load data for, or null. * @return This request builder. */
Sets the specific model to load data for. This method must be called at least once before <code>#into(com.bumptech.glide.request.target.Target)</code> is called.
load
{ "repo_name": "weiwenqiang/GitHub", "path": "expert/glide/library/src/main/java/com/bumptech/glide/RequestBuilder.java", "license": "apache-2.0", "size": 39695 }
[ "android.support.annotation.Nullable" ]
import android.support.annotation.Nullable;
import android.support.annotation.*;
[ "android.support" ]
android.support;
633,994
public File downloadFile(SecurityContext ctx, File file, long fileID) throws DSOutOfServiceException, DSAccessException;
File function(SecurityContext ctx, File file, long fileID) throws DSOutOfServiceException, DSAccessException;
/** * Downloads a file previously uploaded to the server. * * @param ctx The security context. * @param file The file to write the data into. * @param fileID The id of the file to download. * @return See above. * @throws DSOutOfServiceException If the connection is broken, or logged * ...
Downloads a file previously uploaded to the server
downloadFile
{ "repo_name": "stelfrich/openmicroscopy", "path": "components/insight/SRC/org/openmicroscopy/shoola/env/data/OmeroMetadataService.java", "license": "gpl-2.0", "size": 31596 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
2,612,260
public void lockSettingsCodeSnippet() { ConfigurationAsyncClient client = getAsyncClient(); // BEGIN: com.azure.data.appconfiguration.configurationasyncclient.setReadOnly#string-string-boolean client.setReadOnly("prodDBConnection", "westUS", true) .subscribe(response -> System.ou...
void function() { ConfigurationAsyncClient client = getAsyncClient(); client.setReadOnly(STR, STR, true) .subscribe(response -> System.out.printf(STR, response.getKey(), response.getLabel(), response.getValue())); client.setReadOnly(new ConfigurationSetting().setKey(STR).setLabel(STR), true) .subscribe(response -> Syst...
/** * Code snippets for {@link ConfigurationAsyncClient#setReadOnly(String, String, boolean)} set to read-only setting */
Code snippets for <code>ConfigurationAsyncClient#setReadOnly(String, String, boolean)</code> set to read-only setting
lockSettingsCodeSnippet
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/appconfiguration/azure-data-appconfiguration/src/samples/java/com/azure/data/appconfiguration/ConfigurationAsyncClientJavaDocCodeSnippets.java", "license": "mit", "size": 16992 }
[ "com.azure.data.appconfiguration.models.ConfigurationSetting" ]
import com.azure.data.appconfiguration.models.ConfigurationSetting;
import com.azure.data.appconfiguration.models.*;
[ "com.azure.data" ]
com.azure.data;
1,814,490
Group getParentGroup(PerunSession sess, Group group) throws ParentGroupNotExistsException;
Group getParentGroup(PerunSession sess, Group group) throws ParentGroupNotExistsException;
/** * Get parent group. * * @param sess * @param group * @return parent group * @throws InternalErrorException * @throws ParentGroupNotExistsException */
Get parent group
getParentGroup
{ "repo_name": "mvocu/perun", "path": "perun-core/src/main/java/cz/metacentrum/perun/core/implApi/GroupsManagerImplApi.java", "license": "bsd-2-clause", "size": 27084 }
[ "cz.metacentrum.perun.core.api.Group", "cz.metacentrum.perun.core.api.PerunSession", "cz.metacentrum.perun.core.api.exceptions.ParentGroupNotExistsException" ]
import cz.metacentrum.perun.core.api.Group; import cz.metacentrum.perun.core.api.PerunSession; import cz.metacentrum.perun.core.api.exceptions.ParentGroupNotExistsException;
import cz.metacentrum.perun.core.api.*; import cz.metacentrum.perun.core.api.exceptions.*;
[ "cz.metacentrum.perun" ]
cz.metacentrum.perun;
2,029,576
public File getDirectory() { return directory; }
File function() { return directory; }
/** * Returns the directory where this cache stores its data. */
Returns the directory where this cache stores its data
getDirectory
{ "repo_name": "trongnhan68/ClipForKidAnroid", "path": "KidMovies/src/main/java/com/nhannlt/kidmovie/util/DiskLruCache.java", "license": "apache-2.0", "size": 34072 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
562,030
protected Color getBackgroundColor(String argb) throws BuildException { int a; // Value of the alpha channel. int r; // Value of the red channel. int g; // Value of the green channel. int b; // Value of the blue channel. ...
Color function(String argb) throws BuildException { int a; int r; int g; int b; String token; StringTokenizer tokenizer = new StringTokenizer(argb, STR); try { if(tokenizer.countTokens() == 3) { a = 255; } else if(tokenizer.countTokens() == 4) { a = Integer.parseInt(tokenizer.nextToken()); } else { throw new BuildExcep...
/** * Returns a valid background color object. * * @param argb String containing color channel values. * * @return A valid background color. * * @throws BuildException Input value is invalid. */
Returns a valid background color object
getBackgroundColor
{ "repo_name": "apache/batik", "path": "contrib/rasterizertask/sources/org/apache/tools/ant/taskdefs/optional/RasterizerTask.java", "license": "apache-2.0", "size": 25319 }
[ "java.awt.Color", "java.util.StringTokenizer", "org.apache.tools.ant.BuildException" ]
import java.awt.Color; import java.util.StringTokenizer; import org.apache.tools.ant.BuildException;
import java.awt.*; import java.util.*; import org.apache.tools.ant.*;
[ "java.awt", "java.util", "org.apache.tools" ]
java.awt; java.util; org.apache.tools;
1,854,393
public List<String> getLiveNodes();
List<String> function();
/** * Retrieve the list of live nodes in the cluster, where "liveness" is * determined by the failure detector of the node being queried. * * @return set of IP addresses, as Strings */
Retrieve the list of live nodes in the cluster, where "liveness" is determined by the failure detector of the node being queried
getLiveNodes
{ "repo_name": "Jollyplum/cassandra", "path": "src/java/org/apache/cassandra/service/StorageServiceMBean.java", "license": "apache-2.0", "size": 24519 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,057,595
private Map<String, Set<String>> getDependencies(Pattern pattern) { Map<String, Set<String>> result = new HashMap<String, Set<String>>(); for (PatternNode node : pattern.aliasToNode.values()) { Set<String> currentDependencies = new HashSet<String>(); OWhereClause filter = aliasFilters.get(node.a...
Map<String, Set<String>> function(Pattern pattern) { Map<String, Set<String>> result = new HashMap<String, Set<String>>(); for (PatternNode node : pattern.aliasToNode.values()) { Set<String> currentDependencies = new HashSet<String>(); OWhereClause filter = aliasFilters.get(node.alias); if (filter != null && filter.get...
/** * Calculate the set of dependency aliases for each alias in the pattern. * * @param pattern * @return map of alias to the set of aliases it depends on */
Calculate the set of dependency aliases for each alias in the pattern
getDependencies
{ "repo_name": "orientechnologies/orientdb", "path": "core/src/main/java/com/orientechnologies/orient/core/sql/executor/OMatchExecutionPlanner.java", "license": "apache-2.0", "size": 35928 }
[ "com.orientechnologies.orient.core.sql.parser.OWhereClause", "com.orientechnologies.orient.core.sql.parser.Pattern", "java.util.HashMap", "java.util.HashSet", "java.util.List", "java.util.Map", "java.util.Set" ]
import com.orientechnologies.orient.core.sql.parser.OWhereClause; import com.orientechnologies.orient.core.sql.parser.Pattern; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set;
import com.orientechnologies.orient.core.sql.parser.*; import java.util.*;
[ "com.orientechnologies.orient", "java.util" ]
com.orientechnologies.orient; java.util;
6,327
checkState(SwingUtilities.isEventDispatchThread()); showDownloadMapsWindowAndDownload(List.of()); }
checkState(SwingUtilities.isEventDispatchThread()); showDownloadMapsWindowAndDownload(List.of()); }
/** * Shows the Download Maps window. * * @throws IllegalStateException If this method is not called from the EDT. */
Shows the Download Maps window
showDownloadMapsWindow
{ "repo_name": "triplea-game/triplea", "path": "game-app/game-core/src/main/java/games/strategy/engine/framework/map/download/DownloadMapsWindow.java", "license": "gpl-3.0", "size": 18001 }
[ "java.util.List", "javax.swing.SwingUtilities" ]
import java.util.List; import javax.swing.SwingUtilities;
import java.util.*; import javax.swing.*;
[ "java.util", "javax.swing" ]
java.util; javax.swing;
192,863
@Benchmark public byte[] decrypt() throws IllegalBlockSizeException, BadPaddingException { return decryptCipher.doFinal(encryptedBytes); }
byte[] function() throws IllegalBlockSizeException, BadPaddingException { return decryptCipher.doFinal(encryptedBytes); }
/** * Decrypt byte array * * @return decrypted byte array * @throws javax.crypto.IllegalBlockSizeException * @throws javax.crypto.BadPaddingException */
Decrypt byte array
decrypt
{ "repo_name": "md-5/jdk10", "path": "test/micro/org/openjdk/bench/javax/crypto/Crypto.java", "license": "gpl-2.0", "size": 4146 }
[ "javax.crypto.BadPaddingException", "javax.crypto.IllegalBlockSizeException" ]
import javax.crypto.BadPaddingException; import javax.crypto.IllegalBlockSizeException;
import javax.crypto.*;
[ "javax.crypto" ]
javax.crypto;
2,157,631
public List getRangeCrosshairs() { return new ArrayList(this.yCrosshairs); }
List function() { return new ArrayList(this.yCrosshairs); }
/** * Returns a new list containing the range crosshairs for this overlay. * * @return A list of crosshairs. */
Returns a new list containing the range crosshairs for this overlay
getRangeCrosshairs
{ "repo_name": "hongliangpan/manydesigns.cn", "path": "trunk/portofino-chart/jfreechat.src/org/jfree/chart/panel/CrosshairOverlay.java", "license": "lgpl-3.0", "size": 21353 }
[ "java.util.ArrayList", "java.util.List" ]
import java.util.ArrayList; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,277,937
public ServiceFuture<CheckNameResultInner> checkNameAvailabilityAsync(String resourceGroupName, String clusterName, String name, final ServiceCallback<CheckNameResultInner> serviceCallback) { return ServiceFuture.fromResponse(checkNameAvailabilityWithServiceResponseAsync(resourceGroupName, clusterName, name...
ServiceFuture<CheckNameResultInner> function(String resourceGroupName, String clusterName, String name, final ServiceCallback<CheckNameResultInner> serviceCallback) { return ServiceFuture.fromResponse(checkNameAvailabilityWithServiceResponseAsync(resourceGroupName, clusterName, name), serviceCallback); }
/** * Checks that the database name is valid and is not already in use. * * @param resourceGroupName The name of the resource group containing the Kusto cluster. * @param clusterName The name of the Kusto cluster. * @param name Database name. * @param serviceCallback the async ServiceCallb...
Checks that the database name is valid and is not already in use
checkNameAvailabilityAsync
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/kusto/mgmt-v2019_05_15/src/main/java/com/microsoft/azure/management/kusto/v2019_05_15/implementation/DatabasesInner.java", "license": "mit", "size": 87420 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
2,125,995
Object getValue(Object data, Object id); } private static Hashtable<Class<?>, IPropertyTypeHandler> propHandlerMap; static { // Create the property value handler for polygons IPropertyTypeHandler polygonPropertyHandler = new IPropertyTypeHandler() { @Override public Object getValue(Object ...
Object getValue(Object data, Object id); } static Hashtable<Class<?>, IPropertyTypeHandler> propHandlerMap; static { IPropertyTypeHandler polygonPropertyHandler = new IPropertyTypeHandler() { public Object function(Object data, Object id) { Polygon polygon = (Polygon) data; ArrayList<String> propertySet = new ArrayList...
/** * This function retrieves the property value of the given id from the * given data object. * * @param data * The PropertySource to extract the property value from * * @param id * The id for the requested value * * @return The property value requested */
This function retrieves the property value of the given id from the given data object
getValue
{ "repo_name": "SmithRWORNL/ice", "path": "src/org.eclipse.ice.client.widgets/src/org/eclipse/ice/client/widgets/MeshElementTreeViewPropertySource.java", "license": "epl-1.0", "size": 8498 }
[ "java.util.ArrayList", "java.util.Hashtable", "org.eclipse.ice.datastructures.form.mesh.Edge", "org.eclipse.ice.datastructures.form.mesh.IMeshPart", "org.eclipse.ice.datastructures.form.mesh.Polygon", "org.eclipse.ice.datastructures.form.mesh.Vertex" ]
import java.util.ArrayList; import java.util.Hashtable; import org.eclipse.ice.datastructures.form.mesh.Edge; import org.eclipse.ice.datastructures.form.mesh.IMeshPart; import org.eclipse.ice.datastructures.form.mesh.Polygon; import org.eclipse.ice.datastructures.form.mesh.Vertex;
import java.util.*; import org.eclipse.ice.datastructures.form.mesh.*;
[ "java.util", "org.eclipse.ice" ]
java.util; org.eclipse.ice;
2,467,888
private String _dynOrder(int o, int l) { String t; switch (o) { case Consts.DYN_OLDEST: t = "c.mod"; break; case Consts.DYN_RANDOM: t = "random()"; break; case Consts.DYN_SMALLINT: t =...
String function(int o, int l) { String t; switch (o) { case Consts.DYN_OLDEST: t = "c.mod"; break; case Consts.DYN_RANDOM: t = STR; break; case Consts.DYN_SMALLINT: t = "ivl"; break; case Consts.DYN_BIGINT: t = STR; break; case Consts.DYN_LAPSES: t = STR; break; case Consts.DYN_ADDED: t = "n.id"; break; case Consts.DYN...
/** * Generates the required SQL for order by and limit clauses, for dynamic decks. * * @param o deck["order"] * @param l deck["limit"] * @return The generated SQL to be suffixed to "select ... from ... order by " */
Generates the required SQL for order by and limit clauses, for dynamic decks
_dynOrder
{ "repo_name": "leekyounghie/Anki-Android-develop", "path": "AnkiDroid/src/main/java/com/ichi2/libanki/Sched.java", "license": "gpl-3.0", "size": 90848 }
[ "java.util.Locale" ]
import java.util.Locale;
import java.util.*;
[ "java.util" ]
java.util;
2,270,559
try { commandLine = new GnuParser().parse(options, argv); } catch (ParseException ex) { System.err.println(ex.getMessage()); //NOSONAR printUsage(); return false; } return true; }
try { commandLine = new GnuParser().parse(options, argv); } catch (ParseException ex) { System.err.println(ex.getMessage()); printUsage(); return false; } return true; }
/** * Parses the command line arguments. * * @param argv the command line arguments * @return true, if successful */
Parses the command line arguments
parse
{ "repo_name": "sashadidukh/kaa", "path": "server/common/thrift-cli-client/src/main/java/org/kaaproject/kaa/server/common/thrift/cli/client/OptionsProcessor.java", "license": "apache-2.0", "size": 4345 }
[ "org.apache.commons.cli.GnuParser", "org.apache.commons.cli.ParseException" ]
import org.apache.commons.cli.GnuParser; import org.apache.commons.cli.ParseException;
import org.apache.commons.cli.*;
[ "org.apache.commons" ]
org.apache.commons;
763,029
public static final Uri getContentUri(String volumeName, long rowId) { return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName + "/file/" + rowId); }
static final Uri function(String volumeName, long rowId) { return Uri.parse(CONTENT_AUTHORITY_SLASH + volumeName + STR + rowId); }
/** * Get the content:// style URI for a single row in the files table on the * given volume. * * @param volumeName the name of the volume to get the URI for * @param rowId the file to get the URI for * @return the URI to the files table on the given volume ...
Get the content:// style URI for a single row in the files table on the given volume
getContentUri
{ "repo_name": "indashnet/InDashNet.Open.UN2000", "path": "android/frameworks/base/core/java/android/provider/MediaStore.java", "license": "apache-2.0", "size": 88441 }
[ "android.net.Uri" ]
import android.net.Uri;
import android.net.*;
[ "android.net" ]
android.net;
1,498,744
public final JpaTemplate getJpaTemplate() { return jpaTemplate; }
final JpaTemplate function() { return jpaTemplate; }
/** * Return the JpaTemplate for this DAO, pre-initialized * with the EntityManagerFactory or set explicitly. */
Return the JpaTemplate for this DAO, pre-initialized with the EntityManagerFactory or set explicitly
getJpaTemplate
{ "repo_name": "kingtang/spring-learn", "path": "spring-orm/src/main/java/org/springframework/orm/jpa/support/JpaDaoSupport.java", "license": "gpl-3.0", "size": 4551 }
[ "org.springframework.orm.jpa.JpaTemplate" ]
import org.springframework.orm.jpa.JpaTemplate;
import org.springframework.orm.jpa.*;
[ "org.springframework.orm" ]
org.springframework.orm;
954,726
public Set<String> getTemplateNames() { return getTemplates().keySet(); }
Set<String> function() { return getTemplates().keySet(); }
/** * Get the names of the templates to which the current user has access. * @return The names of the available templates. */
Get the names of the templates to which the current user has access
getTemplateNames
{ "repo_name": "drhee/toxoMine", "path": "intermine/webservice/client/main/src/org/intermine/webservice/client/services/TemplateService.java", "license": "lgpl-2.1", "size": 23676 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
615,484
@Nullable public ParcelUuid getServiceSolicitationUuidMask() { return mServiceSolicitationUuidMask; }
ParcelUuid function() { return mServiceSolicitationUuidMask; }
/** * Returns the filter set on the service Solicitation uuid mask. */
Returns the filter set on the service Solicitation uuid mask
getServiceSolicitationUuidMask
{ "repo_name": "Polidea/RxAndroidBle", "path": "rxandroidble/src/main/java/com/polidea/rxandroidble2/scan/ScanFilter.java", "license": "apache-2.0", "size": 29181 }
[ "android.os.ParcelUuid" ]
import android.os.ParcelUuid;
import android.os.*;
[ "android.os" ]
android.os;
1,328,206
private static String response(Node node, ParseState ps) { // AIML 2.0 int index=getIndexValue(node, ps); return ps.chatSession.responseHistory.getString(index).trim(); }
static String function(Node node, ParseState ps) { int index=getIndexValue(node, ps); return ps.chatSession.responseHistory.getString(index).trim(); }
/** * implements {@code <response index="N"/>} tag * * @param node current XML parse node * @param ps AIML parse state * @return the bot's Nth last multi-sentence response. */
implements tag
response
{ "repo_name": "jimfinnis/ChatCitizen", "path": "ChatCitizen/src/org/alicebot/ab/AIMLProcessor.java", "license": "gpl-3.0", "size": 66635 }
[ "org.w3c.dom.Node" ]
import org.w3c.dom.Node;
import org.w3c.dom.*;
[ "org.w3c.dom" ]
org.w3c.dom;
2,847,046
public void broadcastServerPacket(PacketContainer packet);
void function(PacketContainer packet);
/** * Broadcast a given packet to every connected player on the server. * @param packet - the packet to broadcast. * @throws FieldAccessException If we were unable to send the packet due to reflection problems. */
Broadcast a given packet to every connected player on the server
broadcastServerPacket
{ "repo_name": "HolodeckOne-Minecraft/ProtocolLib", "path": "modules/API/src/main/java/com/comphenix/protocol/ProtocolManager.java", "license": "gpl-2.0", "size": 11149 }
[ "com.comphenix.protocol.events.PacketContainer" ]
import com.comphenix.protocol.events.PacketContainer;
import com.comphenix.protocol.events.*;
[ "com.comphenix.protocol" ]
com.comphenix.protocol;
1,313,223
public boolean getEnableSessionCreation() { if (_socket_ instanceof SSLSocket) { return ((SSLSocket) _socket_).getEnableSessionCreation(); } return false; }
boolean function() { if (_socket_ instanceof SSLSocket) { return ((SSLSocket) _socket_).getEnableSessionCreation(); } return false; }
/** * Returns true if new SSL sessions may be established by this socket. * When the underlying {@link Socket} instance is not SSL-enabled (i.e. an * instance of {@link SSLSocket} with {@link SSLSocket}{@link #getEnableSessionCreation()}) * enabled, * this returns False. * * @return true - Indicate...
Returns true if new SSL sessions may be established by this socket. When the underlying <code>Socket</code> instance is not SSL-enabled (i.e. an instance of <code>SSLSocket</code> with <code>SSLSocket</code><code>#getEnableSessionCreation()</code>) enabled, this returns False
getEnableSessionCreation
{ "repo_name": "AriaLyy/Aria", "path": "FtpComponent/src/main/java/aria/apache/commons/net/ftp/FTPSClient.java", "license": "apache-2.0", "size": 31017 }
[ "javax.net.ssl.SSLSocket" ]
import javax.net.ssl.SSLSocket;
import javax.net.ssl.*;
[ "javax.net" ]
javax.net;
767,362
@Test public void testDecimalLiteral() { final RelDataTypeFactory typeFactory = new SqlTypeFactoryImpl(RelDataTypeSystem.DEFAULT); final RelDataType type = typeFactory.createSqlType(SqlTypeName.DECIMAL); final RexBuilder builder = new RexBuilder(typeFactory); final RexLiteral literal = builder...
@Test void function() { final RelDataTypeFactory typeFactory = new SqlTypeFactoryImpl(RelDataTypeSystem.DEFAULT); final RelDataType type = typeFactory.createSqlType(SqlTypeName.DECIMAL); final RexBuilder builder = new RexBuilder(typeFactory); final RexLiteral literal = builder.makeExactLiteral(null, type); assertThat(l...
/** Test case for * <a href="https://issues.apache.org/jira/browse/CALCITE-2306">[CALCITE-2306] * AssertionError in {@link RexLiteral#getValue3} with null literal of type * DECIMAL</a>. */
Test case for [CALCITE-2306] AssertionError in <code>RexLiteral#getValue3</code> with null literal of type
testDecimalLiteral
{ "repo_name": "arina-ielchiieva/calcite", "path": "core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java", "license": "apache-2.0", "size": 21071 }
[ "org.apache.calcite.rel.type.RelDataType", "org.apache.calcite.rel.type.RelDataTypeFactory", "org.apache.calcite.rel.type.RelDataTypeSystem", "org.apache.calcite.sql.type.SqlTypeFactoryImpl", "org.apache.calcite.sql.type.SqlTypeName", "org.hamcrest.CoreMatchers", "org.junit.Assert", "org.junit.Test" ]
import org.apache.calcite.rel.type.RelDataType; import org.apache.calcite.rel.type.RelDataTypeFactory; import org.apache.calcite.rel.type.RelDataTypeSystem; import org.apache.calcite.sql.type.SqlTypeFactoryImpl; import org.apache.calcite.sql.type.SqlTypeName; import org.hamcrest.CoreMatchers; import org.junit.Assert; i...
import org.apache.calcite.rel.type.*; import org.apache.calcite.sql.type.*; import org.hamcrest.*; import org.junit.*;
[ "org.apache.calcite", "org.hamcrest", "org.junit" ]
org.apache.calcite; org.hamcrest; org.junit;
1,106,807
private @NonNull Set<ThreadUpdate> incrementReceiptCountInternal(SyncMessageId syncMessageId, long timestamp, MessageDatabase.ReceiptType receiptType) { Set<ThreadUpdate> threadUpdates = new HashSet<>(); threadUpdates.addAll(DatabaseFactory.getSmsDatabase(context).incrementReceiptCount(syncMessageId, timesta...
@NonNull Set<ThreadUpdate> function(SyncMessageId syncMessageId, long timestamp, MessageDatabase.ReceiptType receiptType) { Set<ThreadUpdate> threadUpdates = new HashSet<>(); threadUpdates.addAll(DatabaseFactory.getSmsDatabase(context).incrementReceiptCount(syncMessageId, timestamp, receiptType)); threadUpdates.addAll(...
/** * Doesn't do any transactions or updates, so we can re-use the method safely. */
Doesn't do any transactions or updates, so we can re-use the method safely
incrementReceiptCountInternal
{ "repo_name": "WhisperSystems/Signal-Android", "path": "app/src/main/java/org/thoughtcrime/securesms/database/MmsSmsDatabase.java", "license": "gpl-3.0", "size": 44339 }
[ "androidx.annotation.NonNull", "java.util.HashSet", "java.util.Set", "org.thoughtcrime.securesms.database.MessageDatabase" ]
import androidx.annotation.NonNull; import java.util.HashSet; import java.util.Set; import org.thoughtcrime.securesms.database.MessageDatabase;
import androidx.annotation.*; import java.util.*; import org.thoughtcrime.securesms.database.*;
[ "androidx.annotation", "java.util", "org.thoughtcrime.securesms" ]
androidx.annotation; java.util; org.thoughtcrime.securesms;
2,189,607