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 Map<Integer, LabelCategory> fillLocalMaps() {
int size = LabelCategory.size();
List<String>list_category = new ArrayList<>(size);
list_category.addAll(LabelCategory.getAllNames());
Collections.sort(list_category);
// OK, we have list of category labels ... | static Map<Integer, LabelCategory> function() { int size = LabelCategory.size(); List<String>list_category = new ArrayList<>(size); list_category.addAll(LabelCategory.getAllNames()); Collections.sort(list_category); category2id = new LinkedHashMap<>(size); Map<Integer, LabelCategory> _id2category = new LinkedHashMap<>(... | /** Load data from a LabelCategory class, sorts,
* and fills the local map 'id2category'. */ | Load data from a LabelCategory class, sorts | fillLocalMaps | {
"repo_name": "componavt/wikokit",
"path": "common_wiki_jdbc/src/wikokit/base/wikt/sql/label/TLabelCategory.java",
"license": "apache-2.0",
"size": 11497
} | [
"java.util.ArrayList",
"java.util.Collections",
"java.util.LinkedHashMap",
"java.util.List",
"java.util.Map"
] | import java.util.ArrayList; import java.util.Collections; import java.util.LinkedHashMap; import java.util.List; import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 457,789 |
@Override
public ITransformedNetwork getTransformedNetwork(String networkId, String versionID)
throws QuadrigaStorageException {
List<INetworkNodeInfo> oldNetworkTopNodesList = networkManager.getNetworkTopNodesByVersion(networkId,
Integer.parseInt(versionID));
return... | ITransformedNetwork function(String networkId, String versionID) throws QuadrigaStorageException { List<INetworkNodeInfo> oldNetworkTopNodesList = networkManager.getNetworkTopNodesByVersion(networkId, Integer.parseInt(versionID)); return transformer.transformNetwork(oldNetworkTopNodesList); } | /**
* This method returns the transformed network based on networkId and
* versionID.
*
* @param networkId
* @param versionID
* @return ITransformedNetwork
* @throws QuadrigaStorageException
*/ | This method returns the transformed network based on networkId and versionID | getTransformedNetwork | {
"repo_name": "diging/quadriga",
"path": "Quadriga/src/main/java/edu/asu/spring/quadriga/service/network/impl/NetworkTransformationManager.java",
"license": "gpl-2.0",
"size": 14831
} | [
"edu.asu.spring.quadriga.domain.network.INetworkNodeInfo",
"edu.asu.spring.quadriga.exceptions.QuadrigaStorageException",
"edu.asu.spring.quadriga.service.network.domain.ITransformedNetwork",
"java.util.List"
] | import edu.asu.spring.quadriga.domain.network.INetworkNodeInfo; import edu.asu.spring.quadriga.exceptions.QuadrigaStorageException; import edu.asu.spring.quadriga.service.network.domain.ITransformedNetwork; import java.util.List; | import edu.asu.spring.quadriga.domain.network.*; import edu.asu.spring.quadriga.exceptions.*; import edu.asu.spring.quadriga.service.network.domain.*; import java.util.*; | [
"edu.asu.spring",
"java.util"
] | edu.asu.spring; java.util; | 720,045 |
public static void tearDownMavenRepository( final java.nio.file.Path m2Folder ) {
if ( m2Folder != null ) {
try {
Files.walkFileTree( m2Folder,
new java.nio.file.SimpleFileVisitor<java.nio.file.Path>() { | static void function( final java.nio.file.Path m2Folder ) { if ( m2Folder != null ) { try { Files.walkFileTree( m2Folder, new java.nio.file.SimpleFileVisitor<java.nio.file.Path>() { | /**
* Destroy the temporary local Maven Repository and all content.
* @param m2Folder
*/ | Destroy the temporary local Maven Repository and all content | tearDownMavenRepository | {
"repo_name": "baldimir/guvnor",
"path": "guvnor-project/guvnor-project-backend/src/main/java/org/guvnor/common/services/project/backend/server/MavenLocalRepositoryUtils.java",
"license": "apache-2.0",
"size": 3111
} | [
"java.nio.file.Files"
] | import java.nio.file.Files; | import java.nio.file.*; | [
"java.nio"
] | java.nio; | 2,200,058 |
public static boolean checkSimpleDerivationOk(XSSimpleType derived, XSTypeDefinition base, short block) {
// if derived is anySimpleType, then it's valid only if the base
// is ur-type
if (derived == SchemaGrammar.fAnySimpleType) {
return (base == SchemaGrammar.fAnyType ||
... | static boolean function(XSSimpleType derived, XSTypeDefinition base, short block) { if (derived == SchemaGrammar.fAnySimpleType) { return (base == SchemaGrammar.fAnyType base == SchemaGrammar.fAnySimpleType); } if (base.getTypeCategory() == XSTypeDefinition.COMPLEX_TYPE) { if (base == SchemaGrammar.fAnyType) base = Sch... | /**
* check whether simple type derived is valid derived from base,
* given a subset of {restriction, extension}.
*/ | check whether simple type derived is valid derived from base, given a subset of {restriction, extension} | checkSimpleDerivationOk | {
"repo_name": "md-5/jdk10",
"path": "src/java.xml/share/classes/com/sun/org/apache/xerces/internal/impl/xs/XSConstraints.java",
"license": "gpl-2.0",
"size": 64814
} | [
"com.sun.org.apache.xerces.internal.impl.dv.XSSimpleType",
"com.sun.org.apache.xerces.internal.xs.XSTypeDefinition"
] | import com.sun.org.apache.xerces.internal.impl.dv.XSSimpleType; import com.sun.org.apache.xerces.internal.xs.XSTypeDefinition; | import com.sun.org.apache.xerces.internal.impl.dv.*; import com.sun.org.apache.xerces.internal.xs.*; | [
"com.sun.org"
] | com.sun.org; | 2,237,621 |
private int readToBuff(int count) throws IOException {
int offset = 0;
while (offset < count) {
int bytesRead = in.read(buff, offset, count - offset);
if (bytesRead == -1) {
return bytesRead;
}
offset += bytesRead;
}
return offset;
} | int function(int count) throws IOException { int offset = 0; while (offset < count) { int bytesRead = in.read(buff, offset, count - offset); if (bytesRead == -1) { return bytesRead; } offset += bytesRead; } return offset; } | /**
* Reads a 16-bit character value from this stream.
*
* @return the next <code>char</code> value from the source stream.
*
* @throws IOException
* If a problem occurs reading from this DataInputStream.
*
*/ | Reads a 16-bit character value from this stream | readToBuff | {
"repo_name": "ty1er/incubator-asterixdb",
"path": "asterixdb/asterix-hivecompat/src/main/java/org/apache/asterix/hivecompat/io/NonSyncDataInputBuffer.java",
"license": "apache-2.0",
"size": 14867
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 203,325 |
int readVariableByteInteger();
/**
* Reads {@code String} value written by {@link #writeString(String, java.nio.charset.CharsetEncoder)}.
*
* @param decoder the decoder of the charset which creates encoder of
* {@link #writeString(String, java.nio.charset.CharsetEncoder)} | int readVariableByteInteger(); /** * Reads {@code String} value written by {@link #writeString(String, java.nio.charset.CharsetEncoder)}. * * @param decoder the decoder of the charset which creates encoder of * {@link #writeString(String, java.nio.charset.CharsetEncoder)} | /**
* Reads {@code int} value in signed VBC form from the start index.
* The null value is returned as (negative) zero.
* @return the {@code int} value read from the buffer
*/ | Reads int value in signed VBC form from the start index. The null value is returned as (negative) zero | readVariableByteInteger | {
"repo_name": "ihiroky/niotty",
"path": "src/main/java/net/ihiroky/niotty/buffer/CodecBuffer.java",
"license": "mit",
"size": 21669
} | [
"java.nio.charset.CharsetEncoder"
] | import java.nio.charset.CharsetEncoder; | import java.nio.charset.*; | [
"java.nio"
] | java.nio; | 82,972 |
@Override
public synchronized void onVirtualClusterSubmissionFinished(String taskIdentifier,
VirtualClusterSubmissionResponse response)
{
Guard.check(taskIdentifier, response);
log_.debug(String.format("Adding virtual cluster ... | synchronized void function(String taskIdentifier, VirtualClusterSubmissionResponse response) { Guard.check(taskIdentifier, response); log_.debug(String.format(STR, taskIdentifier)); postVirtualClusterSubmission(response.getVirtualMachineMetaData()); virtualClusterResponses_.put(taskIdentifier, response); workerQueue_.p... | /**
* Adds a virtual cluster response.
*
* @param taskIdentifier The task identifier
* @param response The virtual cluster response
*/ | Adds a virtual cluster response | onVirtualClusterSubmissionFinished | {
"repo_name": "snoozesoftware/snoozenode",
"path": "src/main/java/org/inria/myriads/snoozenode/groupmanager/virtualclustermanager/VirtualClusterManager.java",
"license": "gpl-2.0",
"size": 16673
} | [
"org.inria.myriads.snoozecommon.communication.virtualcluster.submission.VirtualClusterSubmissionResponse",
"org.inria.myriads.snoozecommon.guard.Guard",
"org.inria.myriads.snoozenode.groupmanager.virtualclustermanager.worker.VirtualClusterSubmissionWorker"
] | import org.inria.myriads.snoozecommon.communication.virtualcluster.submission.VirtualClusterSubmissionResponse; import org.inria.myriads.snoozecommon.guard.Guard; import org.inria.myriads.snoozenode.groupmanager.virtualclustermanager.worker.VirtualClusterSubmissionWorker; | import org.inria.myriads.snoozecommon.communication.virtualcluster.submission.*; import org.inria.myriads.snoozecommon.guard.*; import org.inria.myriads.snoozenode.groupmanager.virtualclustermanager.worker.*; | [
"org.inria.myriads"
] | org.inria.myriads; | 1,658,906 |
protected Buffer formBuffer() {
Buffer buffer = new Buffer();
if (form == null || form.isEmpty()) {
return buffer;
}
if (!isFormMultipart()) {
String formEncoding = resolveFormEncoding();
// encode
String formQueryString = HttpUtil.buildQuery(form, formEncoding);
contentType("application/x-... | Buffer function() { Buffer buffer = new Buffer(); if (form == null form.isEmpty()) { return buffer; } if (!isFormMultipart()) { String formEncoding = resolveFormEncoding(); String formQueryString = HttpUtil.buildQuery(form, formEncoding); contentType(STR, null); contentLength(formQueryString.length()); buffer.append(fo... | /**
* Creates form {@link jodd.http.Buffer buffer} and sets few headers.
*/ | Creates form <code>jodd.http.Buffer buffer</code> and sets few headers | formBuffer | {
"repo_name": "vilmospapp/jodd",
"path": "jodd-http/src/main/java/jodd/http/HttpBase.java",
"license": "bsd-2-clause",
"size": 26018
} | [
"java.util.Map"
] | import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 2,802,145 |
EReference getTransitionTable_Rows(); | EReference getTransitionTable_Rows(); | /**
* Returns the meta object for the containment reference list '{@link org.xtuml.bp.xtext.masl.masl.structure.TransitionTable#getRows <em>Rows</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference list '<em>Rows</em>'.
* @see org.xtuml.bp.xtext.mas... | Returns the meta object for the containment reference list '<code>org.xtuml.bp.xtext.masl.masl.structure.TransitionTable#getRows Rows</code>'. | getTransitionTable_Rows | {
"repo_name": "lwriemen/bridgepoint",
"path": "src/org.xtuml.bp.xtext.masl.parent/org.xtuml.bp.xtext.masl/emf-gen/org/xtuml/bp/xtext/masl/masl/structure/StructurePackage.java",
"license": "apache-2.0",
"size": 189771
} | [
"org.eclipse.emf.ecore.EReference"
] | import org.eclipse.emf.ecore.EReference; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 1,703,249 |
Commandline cmd = setupKaffehCommand(javah);
try {
Execute.runCommand(javah, cmd.getCommandline());
return true;
} catch (BuildException e) {
if (e.getMessage().indexOf("failed with return code") == -1) {
throw e;
}
}
return... | Commandline cmd = setupKaffehCommand(javah); try { Execute.runCommand(javah, cmd.getCommandline()); return true; } catch (BuildException e) { if (e.getMessage().indexOf(STR) == -1) { throw e; } } return false; } | /**
* Performs the actual compilation.
* @param javah the calling javah task.
* @return true if the compilation was successful.
* @throws BuildException if there is an error.
* @since Ant 1.6.3
*/ | Performs the actual compilation | compile | {
"repo_name": "Mayo-WE01051879/mayosapp",
"path": "Build/src/main/org/apache/tools/ant/taskdefs/optional/javah/Kaffeh.java",
"license": "mit",
"size": 3186
} | [
"org.apache.tools.ant.BuildException",
"org.apache.tools.ant.taskdefs.Execute",
"org.apache.tools.ant.types.Commandline"
] | import org.apache.tools.ant.BuildException; import org.apache.tools.ant.taskdefs.Execute; import org.apache.tools.ant.types.Commandline; | import org.apache.tools.ant.*; import org.apache.tools.ant.taskdefs.*; import org.apache.tools.ant.types.*; | [
"org.apache.tools"
] | org.apache.tools; | 2,583,282 |
private void scan() {
BlockPoolReport blockPoolReport = new BlockPoolReport();
clear();
Collection<ScanInfoVolumeReport> volumeReports = getVolumeReports();
for (ScanInfoVolumeReport volumeReport : volumeReports) {
for (String blockPoolId : volumeReport.getBlockPoolIds()) {
List<ScanIn... | void function() { BlockPoolReport blockPoolReport = new BlockPoolReport(); clear(); Collection<ScanInfoVolumeReport> volumeReports = getVolumeReports(); for (ScanInfoVolumeReport volumeReport : volumeReports) { for (String blockPoolId : volumeReport.getBlockPoolIds()) { List<ScanInfo> scanInfos = volumeReport.getScanIn... | /**
* Scan for the differences between disk and in-memory blocks Scan only the
* "finalized blocks" lists of both disk and memory.
*/ | Scan for the differences between disk and in-memory blocks Scan only the "finalized blocks" lists of both disk and memory | scan | {
"repo_name": "ucare-uchicago/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DirectoryScanner.java",
"license": "apache-2.0",
"size": 24003
} | [
"java.util.ArrayList",
"java.util.Collection",
"java.util.Collections",
"java.util.List",
"org.apache.hadoop.fs.StorageType",
"org.apache.hadoop.hdfs.server.datanode.fsdataset.FsVolumeSpi",
"org.apache.hadoop.util.AutoCloseableLock"
] | import java.util.ArrayList; import java.util.Collection; import java.util.Collections; import java.util.List; import org.apache.hadoop.fs.StorageType; import org.apache.hadoop.hdfs.server.datanode.fsdataset.FsVolumeSpi; import org.apache.hadoop.util.AutoCloseableLock; | import java.util.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.hdfs.server.datanode.fsdataset.*; import org.apache.hadoop.util.*; | [
"java.util",
"org.apache.hadoop"
] | java.util; org.apache.hadoop; | 1,226,512 |
public static void main(String[] args) throws Exception {
Options options = new Options();
options.addOption(O_HELP, false, "print usage");
options.addOption(O_SLEEP, true,
"upon hitting an Exception, minutes to wait until exiting the program. " +
"If not ... | static void function(String[] args) throws Exception { Options options = new Options(); options.addOption(O_HELP, false, STR); options.addOption(O_SLEEP, true, STR + STR); options.addOption(O_URI, true, STRbind DNSTRpasswordSTRSTRldap: } if (cl.hasOption(O_BINDDN)) { bindDN = cl.getOptionValue(O_BINDDN); } else { bindD... | /**
* /Users/pshao/dev/workspace/sandbox/sandbox/bin>/System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home/bin/java LdapReadTimeout
* /System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home/bin/java LdapReadTimeout
*
* zmjava com.zimbra.qa.unittest.TestLdapReadTimeout -s 5
* zmj... | Users/pshao/dev/workspace/sandbox/sandbox/bin>/System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home/bin/java LdapReadTimeout System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home/bin/java LdapReadTimeout zmjava com.zimbra.qa.unittest.TestLdapReadTimeout -s 5 zmjava com.zimbra.qa.unittest.TestLdapReadTime... | main | {
"repo_name": "nico01f/z-pec",
"path": "ZimbraServer/src/java/com/zimbra/qa/unittest/prov/ldap/TestLdapReadTimeout.java",
"license": "mit",
"size": 15093
} | [
"java.text.SimpleDateFormat",
"java.util.Date",
"org.apache.commons.cli.Options"
] | import java.text.SimpleDateFormat; import java.util.Date; import org.apache.commons.cli.Options; | import java.text.*; import java.util.*; import org.apache.commons.cli.*; | [
"java.text",
"java.util",
"org.apache.commons"
] | java.text; java.util; org.apache.commons; | 1,546,666 |
public void closeConnection(WsOutbound outbound, GuacamoleStatus guac_status) {
try {
byte[] message = Integer.toString(guac_status.getGuacamoleStatusCode()).getBytes("UTF-8");
outbound.close(guac_status.getWebSocketCode(), ByteBuffer.wrap(message));
}
catch (IOExcep... | void function(WsOutbound outbound, GuacamoleStatus guac_status) { try { byte[] message = Integer.toString(guac_status.getGuacamoleStatusCode()).getBytes("UTF-8"); outbound.close(guac_status.getWebSocketCode(), ByteBuffer.wrap(message)); } catch (IOException e) { logger.debug(STR, e); } } | /**
* Sends the given status on the given WebSocket connection and closes the
* connection.
*
* @param outbound The outbound WebSocket connection to close.
* @param guac_status The status to send.
*/ | Sends the given status on the given WebSocket connection and closes the connection | closeConnection | {
"repo_name": "softpymesJeffer/incubator-guacamole-client",
"path": "guacamole/src/main/java/org/apache/guacamole/tunnel/websocket/tomcat/GuacamoleWebSocketTunnelServlet.java",
"license": "apache-2.0",
"size": 10103
} | [
"java.io.IOException",
"java.nio.ByteBuffer",
"org.apache.catalina.websocket.WsOutbound",
"org.apache.guacamole.protocol.GuacamoleStatus"
] | import java.io.IOException; import java.nio.ByteBuffer; import org.apache.catalina.websocket.WsOutbound; import org.apache.guacamole.protocol.GuacamoleStatus; | import java.io.*; import java.nio.*; import org.apache.catalina.websocket.*; import org.apache.guacamole.protocol.*; | [
"java.io",
"java.nio",
"org.apache.catalina",
"org.apache.guacamole"
] | java.io; java.nio; org.apache.catalina; org.apache.guacamole; | 611,932 |
@Theory(nullsAccepted = false)
public final void isSerializable(Object x) throws IOException, ClassNotFoundException {
if (x instanceof Serializable) {
Object copy = CloneHelper.clone(x);
Assert.assertThat(x.equals(copy), CoreMatchers.is(true));
}
} | @Theory(nullsAccepted = false) final void function(Object x) throws IOException, ClassNotFoundException { if (x instanceof Serializable) { Object copy = CloneHelper.clone(x); Assert.assertThat(x.equals(copy), CoreMatchers.is(true)); } } | /**
* Checks that all objects are survive a full round trip serialization.
*
* @param x primary object instance.
* @throws IOException if any I/O problem occurs on the stream.
* @throws ClassNotFoundException if class cannot be found.
*/ | Checks that all objects are survive a full round trip serialization | isSerializable | {
"repo_name": "gwynlavin/jactors-junit",
"path": "src/main/java/org/jactors/junit/theory/ObjectTheory.java",
"license": "mit",
"size": 11071
} | [
"java.io.IOException",
"java.io.Serializable",
"org.hamcrest.CoreMatchers",
"org.jactors.junit.helper.CloneHelper",
"org.junit.Assert",
"org.junit.experimental.theories.Theory"
] | import java.io.IOException; import java.io.Serializable; import org.hamcrest.CoreMatchers; import org.jactors.junit.helper.CloneHelper; import org.junit.Assert; import org.junit.experimental.theories.Theory; | import java.io.*; import org.hamcrest.*; import org.jactors.junit.helper.*; import org.junit.*; import org.junit.experimental.theories.*; | [
"java.io",
"org.hamcrest",
"org.jactors.junit",
"org.junit",
"org.junit.experimental"
] | java.io; org.hamcrest; org.jactors.junit; org.junit; org.junit.experimental; | 1,399,619 |
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono<PagedResponse<TableInner>> listNextSinglePageAsync(String nextLink, Context context) {
if (nextLink == null) {
return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
}
if ... | @ServiceMethod(returns = ReturnType.SINGLE) Mono<PagedResponse<TableInner>> function(String nextLink, Context context) { if (nextLink == null) { return Mono.error(new IllegalArgumentException(STR)); } if (this.client.getEndpoint() == null) { return Mono .error( new IllegalArgumentException( STR)); } final String accept... | /**
* Get the next page of items.
*
* @param nextLink The nextLink parameter.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by serve... | Get the next page of items | listNextSinglePageAsync | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-storage/src/main/java/com/azure/resourcemanager/storage/implementation/TablesClientImpl.java",
"license": "mit",
"size": 61429
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.core.http.rest.PagedResponse",
"com.azure.core.http.rest.PagedResponseBase",
"com.azure.core.util.Context",
"com.azure.resourcemanager.storage.fluent.models.TableInner"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.PagedResponse; import com.azure.core.http.rest.PagedResponseBase; import com.azure.core.util.Context; import com.azure.resourcemanager.storage.fluent.models.TableInner; | import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.storage.fluent.models.*; | [
"com.azure.core",
"com.azure.resourcemanager"
] | com.azure.core; com.azure.resourcemanager; | 1,058,030 |
if (RecipeChecker.checkStack(output)) {
RecipeChecker.checkAndHandle(new ShapedOreRecipe(output, recipe));
}
} | if (RecipeChecker.checkStack(output)) { RecipeChecker.checkAndHandle(new ShapedOreRecipe(output, recipe)); } } | /**
* Adds a shaped recipe to the game
*
* @param output Output ItemStack
* @param recipe Recipe for the output ItemStack
* Example: addShaped(new ItemStack(ModItems.diamond),"AAA", "ABA", "AAA", 'A', new ItemStack(ModItems.apple), 'B',new ItemStack(ModItems.nether_star))
*/ | Adds a shaped recipe to the game | addShaped | {
"repo_name": "Wurmcraft/WurmTweaks",
"path": "src/main/java/wurmcraft/wurmatron/common/recipes/RecipeHelper.java",
"license": "mit",
"size": 12766
} | [
"net.minecraftforge.oredict.ShapedOreRecipe"
] | import net.minecraftforge.oredict.ShapedOreRecipe; | import net.minecraftforge.oredict.*; | [
"net.minecraftforge.oredict"
] | net.minecraftforge.oredict; | 1,378,674 |
private long restoreSnapshot(final SnapshotDescription reqSnapshot, final TableName tableName,
final SnapshotDescription snapshot, final TableDescriptor snapshotTableDesc,
final NonceKey nonceKey, final boolean restoreAcl) throws IOException {
MasterCoprocessorHost cpHost = master.getMasterCoprocessor... | long function(final SnapshotDescription reqSnapshot, final TableName tableName, final SnapshotDescription snapshot, final TableDescriptor snapshotTableDesc, final NonceKey nonceKey, final boolean restoreAcl) throws IOException { MasterCoprocessorHost cpHost = master.getMasterCoprocessorHost(); StoreFileTrackerValidatio... | /**
* Restore the specified snapshot. The restore will fail if the destination table has a snapshot
* or restore in progress.
* @param reqSnapshot Snapshot Descriptor from request
* @param tableName table to restore
* @param snapshot Snapshot Descriptor
* @param snapshotTableDesc Table Descriptor
*... | Restore the specified snapshot. The restore will fail if the destination table has a snapshot or restore in progress | restoreSnapshot | {
"repo_name": "apurtell/hbase",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/master/snapshot/SnapshotManager.java",
"license": "apache-2.0",
"size": 54021
} | [
"java.io.IOException",
"org.apache.hadoop.hbase.TableName",
"org.apache.hadoop.hbase.client.TableDescriptor",
"org.apache.hadoop.hbase.client.TableState",
"org.apache.hadoop.hbase.master.MasterCoprocessorHost",
"org.apache.hadoop.hbase.regionserver.storefiletracker.StoreFileTrackerValidationUtils",
"org... | import java.io.IOException; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.client.TableDescriptor; import org.apache.hadoop.hbase.client.TableState; import org.apache.hadoop.hbase.master.MasterCoprocessorHost; import org.apache.hadoop.hbase.regionserver.storefiletracker.StoreFileTrackerValidat... | import java.io.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.master.*; import org.apache.hadoop.hbase.regionserver.storefiletracker.*; import org.apache.hadoop.hbase.shaded.protobuf.*; import org.apache.hadoop.hbase.shaded.protobuf.generated.*; import org.a... | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 699,740 |
public static void send(InternalDistributedSystem system,
GfxdReplyMessageProcessor processor, Set<DistributedMember> members,
DDLConflatable ddl, long connId, long ddlId, LanguageConnectionContext lcc,
boolean persistOnHDFS)
throws StandardException, SQLException {
final GfxdDDLMessage ms... | static void function(InternalDistributedSystem system, GfxdReplyMessageProcessor processor, Set<DistributedMember> members, DDLConflatable ddl, long connId, long ddlId, LanguageConnectionContext lcc, boolean persistOnHDFS) throws StandardException, SQLException { final GfxdDDLMessage msg = new GfxdDDLMessage(); msg.arg... | /**
* Sends an {@link GfxdDDLMessage} for given DDL statement to all members of
* the distributed system.
*/ | Sends an <code>GfxdDDLMessage</code> for given DDL statement to all members of the distributed system | send | {
"repo_name": "gemxd/gemfirexd-oss",
"path": "gemfirexd/core/src/main/java/com/pivotal/gemfirexd/internal/engine/ddl/GfxdDDLMessage.java",
"license": "apache-2.0",
"size": 26413
} | [
"com.gemstone.gemfire.distributed.DistributedMember",
"com.gemstone.gemfire.distributed.internal.InternalDistributedSystem",
"com.pivotal.gemfirexd.internal.engine.distributed.GfxdReplyMessageProcessor",
"com.pivotal.gemfirexd.internal.iapi.error.StandardException",
"com.pivotal.gemfirexd.internal.iapi.sql.... | import com.gemstone.gemfire.distributed.DistributedMember; import com.gemstone.gemfire.distributed.internal.InternalDistributedSystem; import com.pivotal.gemfirexd.internal.engine.distributed.GfxdReplyMessageProcessor; import com.pivotal.gemfirexd.internal.iapi.error.StandardException; import com.pivotal.gemfirexd.inte... | import com.gemstone.gemfire.distributed.*; import com.gemstone.gemfire.distributed.internal.*; import com.pivotal.gemfirexd.internal.engine.distributed.*; import com.pivotal.gemfirexd.internal.iapi.error.*; import com.pivotal.gemfirexd.internal.iapi.sql.conn.*; import java.sql.*; import java.util.*; | [
"com.gemstone.gemfire",
"com.pivotal.gemfirexd",
"java.sql",
"java.util"
] | com.gemstone.gemfire; com.pivotal.gemfirexd; java.sql; java.util; | 148,461 |
@Override
public boolean initialImagePut(Object key, long lastModified, Object newValue,
boolean wasRecovered, boolean deferLRUCallback, VersionTag entryVersion,
InternalDistributedMember sender, boolean forceValue) {
throw new UnsupportedOperationException();
} | boolean function(Object key, long lastModified, Object newValue, boolean wasRecovered, boolean deferLRUCallback, VersionTag entryVersion, InternalDistributedMember sender, boolean forceValue) { throw new UnsupportedOperationException(); } | /**
* Used to modify an existing RegionEntry or create a new one when processing the values obtained
* during a getInitialImage.
*/ | Used to modify an existing RegionEntry or create a new one when processing the values obtained during a getInitialImage | initialImagePut | {
"repo_name": "smanvi-pivotal/geode",
"path": "geode-core/src/main/java/org/apache/geode/internal/cache/ProxyRegionMap.java",
"license": "apache-2.0",
"size": 31378
} | [
"org.apache.geode.distributed.internal.membership.InternalDistributedMember",
"org.apache.geode.internal.cache.versions.VersionTag"
] | import org.apache.geode.distributed.internal.membership.InternalDistributedMember; import org.apache.geode.internal.cache.versions.VersionTag; | import org.apache.geode.distributed.internal.membership.*; import org.apache.geode.internal.cache.versions.*; | [
"org.apache.geode"
] | org.apache.geode; | 1,209,915 |
@Override
public void close() {
// super cleanup
super.close();
// remove Root SVG element listeners
doc.getRootElement()
.removeEventListener(SVGConstants.SVG_KEYPRESS_EVENT_TYPE,
domEventListener, false);
// Remove other mouse/k... | void function() { super.close(); doc.getRootElement() .removeEventListener(SVGConstants.SVG_KEYPRESS_EVENT_TYPE, domEventListener, false); final SVGElement[] mouseElements = SVGUtils .idFinderSVG(layerMap.get(LAYER_MOUSE)); for (SVGElement mouseElement : mouseElements) { if (mouseElement instanceof EventTarget) { final... | /**
* Close the MapRenderer, releasing all resources.
* <p>
* WARNING: render events must not be processed after or
* during a call to this method.
*/ | Close the MapRenderer, releasing all resources. during a call to this method | close | {
"repo_name": "takaki/jdip",
"path": "src/main/java/dip/gui/map/DefaultMapRenderer2.java",
"license": "gpl-2.0",
"size": 57087
} | [
"org.apache.batik.util.SVGConstants",
"org.w3c.dom.events.EventTarget",
"org.w3c.dom.svg.SVGElement"
] | import org.apache.batik.util.SVGConstants; import org.w3c.dom.events.EventTarget; import org.w3c.dom.svg.SVGElement; | import org.apache.batik.util.*; import org.w3c.dom.events.*; import org.w3c.dom.svg.*; | [
"org.apache.batik",
"org.w3c.dom"
] | org.apache.batik; org.w3c.dom; | 2,063,899 |
public Mapper parse(ParseContext context) throws IOException {
final List<IndexableField> fields = new ArrayList<>(2);
try {
parseCreateField(context, fields);
for (IndexableField field : fields) {
context.doc().add(field);
}
} catch (Excep... | Mapper function(ParseContext context) throws IOException { final List<IndexableField> fields = new ArrayList<>(2); try { parseCreateField(context, fields); for (IndexableField field : fields) { context.doc().add(field); } } catch (Exception e) { throw new MapperParsingException(STR + fieldType().name() + "]", e); } mul... | /**
* Parse using the provided {@link ParseContext} and return a mapping
* update if dynamic mappings modified the mappings, or {@code null} if
* mappings were not modified.
*/ | Parse using the provided <code>ParseContext</code> and return a mapping update if dynamic mappings modified the mappings, or null if mappings were not modified | parse | {
"repo_name": "qwerty4030/elasticsearch",
"path": "server/src/main/java/org/elasticsearch/index/mapper/FieldMapper.java",
"license": "apache-2.0",
"size": 26801
} | [
"java.io.IOException",
"java.util.ArrayList",
"java.util.List",
"org.apache.lucene.index.IndexableField"
] | import java.io.IOException; import java.util.ArrayList; import java.util.List; import org.apache.lucene.index.IndexableField; | import java.io.*; import java.util.*; import org.apache.lucene.index.*; | [
"java.io",
"java.util",
"org.apache.lucene"
] | java.io; java.util; org.apache.lucene; | 873,808 |
protected String normalize(String value) {
if (value != null) {
if (!caseSensitive) {
return StringUtils.trimToNull(value.toUpperCase());
} else {
return StringUtils.trimToNull(value);
}
}
return value;
} | String function(String value) { if (value != null) { if (!caseSensitive) { return StringUtils.trimToNull(value.toUpperCase()); } else { return StringUtils.trimToNull(value); } } return value; } | /**
* Normalisation of a value used both by adding to the internal dictionary and parsing values.
* The default does trim and uppercase the value for Strings, but leaves other types unaltered.
* Override this method to provide specific normalisations for parsers.
*
* @param value the value to be normalis... | Normalisation of a value used both by adding to the internal dictionary and parsing values. The default does trim and uppercase the value for Strings, but leaves other types unaltered. Override this method to provide specific normalisations for parsers | normalize | {
"repo_name": "gbif/parsers",
"path": "src/main/java/org/gbif/common/parsers/core/DictionaryBackedParser.java",
"license": "apache-2.0",
"size": 3789
} | [
"org.apache.commons.lang3.StringUtils"
] | import org.apache.commons.lang3.StringUtils; | import org.apache.commons.lang3.*; | [
"org.apache.commons"
] | org.apache.commons; | 2,695,025 |
@PreAuthorize("hasPermission('string', 'ALL', new org.jasig.portal.spring.security.evaluator.AuthorizableActivity('UP_PERMISSIONS', 'VIEW_PERMISSIONS'))")
@RequestMapping(value="/permissions/owners.json", method = RequestMethod.GET)
public ModelAndView getOwners(
HttpServletRequest req, HttpServ... | @PreAuthorize(STR) @RequestMapping(value=STR, method = RequestMethod.GET) ModelAndView function( HttpServletRequest req, HttpServletResponse response) throws Exception { List<IPermissionOwner> owners = permissionOwnerDao.getAllPermissionOwners(); ModelAndView mv = new ModelAndView(); mv.addObject(STR, owners); mv.setVi... | /**
* Provide a JSON view of all known permission owners registered with uPortal.
*
* @param req
* @param response
* @return
* @throws Exception
*/ | Provide a JSON view of all known permission owners registered with uPortal | getOwners | {
"repo_name": "pspaude/uPortal",
"path": "uportal-war/src/main/java/org/jasig/portal/rest/permissions/PermissionsRESTController.java",
"license": "apache-2.0",
"size": 23133
} | [
"java.util.List",
"javax.servlet.http.HttpServletRequest",
"javax.servlet.http.HttpServletResponse",
"org.jasig.portal.permission.IPermissionOwner",
"org.springframework.security.access.prepost.PreAuthorize",
"org.springframework.web.bind.annotation.RequestMapping",
"org.springframework.web.bind.annotat... | import java.util.List; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.jasig.portal.permission.IPermissionOwner; import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.web.bind.annotation.RequestMapping; import org.springframew... | import java.util.*; import javax.servlet.http.*; import org.jasig.portal.permission.*; import org.springframework.security.access.prepost.*; import org.springframework.web.bind.annotation.*; import org.springframework.web.servlet.*; | [
"java.util",
"javax.servlet",
"org.jasig.portal",
"org.springframework.security",
"org.springframework.web"
] | java.util; javax.servlet; org.jasig.portal; org.springframework.security; org.springframework.web; | 130,314 |
public String getModifyColumnStatement(String tablename, ValueMetaInterface v, String tk, boolean use_autoinc, String pk, boolean semicolon)
{
return "ALTER TABLE "+tablename+" ALTER COLUMN "+getFieldDefinition(v, tk, pk, use_autoinc, true, false);
}
| String function(String tablename, ValueMetaInterface v, String tk, boolean use_autoinc, String pk, boolean semicolon) { return STR+tablename+STR+getFieldDefinition(v, tk, pk, use_autoinc, true, false); } | /**
* Generates the SQL statement to modify a column in the specified table
* @param tablename The table to add
* @param v The column defined as a value
* @param tk the name of the technical key field
* @param use_autoinc whether or not this field uses auto increment
* @param pk the name of the primar... | Generates the SQL statement to modify a column in the specified table | getModifyColumnStatement | {
"repo_name": "icholy/geokettle-2.0",
"path": "src-db/org/pentaho/di/core/database/MSSQLServerDatabaseMeta.java",
"license": "lgpl-2.1",
"size": 14236
} | [
"org.pentaho.di.core.row.ValueMetaInterface"
] | import org.pentaho.di.core.row.ValueMetaInterface; | import org.pentaho.di.core.row.*; | [
"org.pentaho.di"
] | org.pentaho.di; | 2,110,663 |
void await(long timeout, TimeUnit unit) throws InterruptedException,
TimeoutException; | void await(long timeout, TimeUnit unit) throws InterruptedException, TimeoutException; | /**
* Waits until the event is dispatched to all listeners
*
* @param timeout
* the timeout
* @param unit
* the timeout unit
*
* @throws InterruptedException
* if the thread has been interrupted while waiting
* @throws TimeoutException
* if timeout w... | Waits until the event is dispatched to all listeners | await | {
"repo_name": "l2jserver2/l2jserver2",
"path": "l2jserver2-gameserver/l2jserver2-gameserver-core/src/main/java/com/l2jserver/service/game/world/event/WorldEventFuture.java",
"license": "gpl-3.0",
"size": 2489
} | [
"java.util.concurrent.TimeUnit",
"java.util.concurrent.TimeoutException"
] | import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; | import java.util.concurrent.*; | [
"java.util"
] | java.util; | 35,271 |
public static HasVpcId hasVpcId(String expectedVpcId) {
return new HasVpcId(equalTo(expectedVpcId));
} | static HasVpcId function(String expectedVpcId) { return new HasVpcId(equalTo(expectedVpcId)); } | /**
* Provides a matcher that matches when {@code expectedVpcId} is equal to the {@link
* org.batfish.representation.aws.ElasticsearchDomain}'s VPC Id.
*/ | Provides a matcher that matches when expectedVpcId is equal to the <code>org.batfish.representation.aws.ElasticsearchDomain</code>'s VPC Id | hasVpcId | {
"repo_name": "arifogel/batfish",
"path": "projects/batfish/src/test/java/org/batfish/representation/aws/matchers/ElasticsearchDomainMatchers.java",
"license": "apache-2.0",
"size": 3757
} | [
"org.batfish.representation.aws.matchers.ElasticsearchDomainMatchersImpl"
] | import org.batfish.representation.aws.matchers.ElasticsearchDomainMatchersImpl; | import org.batfish.representation.aws.matchers.*; | [
"org.batfish.representation"
] | org.batfish.representation; | 1,019,921 |
Observable<ServiceResponse<Void>> delete204SucceededWithServiceResponseAsync(); | Observable<ServiceResponse<Void>> delete204SucceededWithServiceResponseAsync(); | /**
* Long running delete request, service returns a 204 to the initial request, indicating success.
*
* @return the {@link ServiceResponse} object if successful.
*/ | Long running delete request, service returns a 204 to the initial request, indicating success | delete204SucceededWithServiceResponseAsync | {
"repo_name": "anudeepsharma/autorest",
"path": "src/generator/AutoRest.Java.Azure.Tests/src/main/java/fixtures/lro/LROSADs.java",
"license": "mit",
"size": 129422
} | [
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.rest.ServiceResponse; | import com.microsoft.rest.*; | [
"com.microsoft.rest"
] | com.microsoft.rest; | 890,256 |
public void addMapRecord(MapRecord mapRecord); | void function(MapRecord mapRecord); | /**
* Adds the map record.
*
* @param mapRecord the map record
*/ | Adds the map record | addMapRecord | {
"repo_name": "IHTSDO/OTF-Mapping-Service",
"path": "model/src/main/java/org/ihtsdo/otf/mapping/helpers/MapRecordList.java",
"license": "apache-2.0",
"size": 770
} | [
"org.ihtsdo.otf.mapping.model.MapRecord"
] | import org.ihtsdo.otf.mapping.model.MapRecord; | import org.ihtsdo.otf.mapping.model.*; | [
"org.ihtsdo.otf"
] | org.ihtsdo.otf; | 50,042 |
List<IObject> createObjects(SecurityContext ctx, List<IObject> objects,
String userName)
throws DSOutOfServiceException, DSAccessException
{
try {
return saveAndReturnObject(ctx, objects, null, userName);
} catch (Throwable t) {
handleException(t, "Cannot create the objects.");
}
return new Array... | List<IObject> createObjects(SecurityContext ctx, List<IObject> objects, String userName) throws DSOutOfServiceException, DSAccessException { try { return saveAndReturnObject(ctx, objects, null, userName); } catch (Throwable t) { handleException(t, STR); } return new ArrayList<IObject>(); } | /**
* Creates the specified objects.
*
* @param ctx The security context.
* @param objects The objects to create.
* @param options Options to create the data.
* @param userName The name of the user.s
* @return See above.
* @throws DSOutOfServiceException If the connection is broken, or logged in
* @th... | Creates the specified objects | createObjects | {
"repo_name": "jballanc/openmicroscopy",
"path": "components/insight/SRC/org/openmicroscopy/shoola/env/data/OMEROGateway.java",
"license": "gpl-2.0",
"size": 286379
} | [
"java.util.ArrayList",
"java.util.List",
"org.openmicroscopy.shoola.env.data.util.SecurityContext"
] | import java.util.ArrayList; import java.util.List; import org.openmicroscopy.shoola.env.data.util.SecurityContext; | import java.util.*; import org.openmicroscopy.shoola.env.data.util.*; | [
"java.util",
"org.openmicroscopy.shoola"
] | java.util; org.openmicroscopy.shoola; | 2,598,133 |
// TODO We may need a different requirement on when we can add an Entry to
// the selected tree or where we can add it.
private DataComponent canAdd(TreeComposite tree) {
DataComponent dataNode = null;
// Look for the active data node. If there is no active data node, get
// the first available data... | DataComponent function(TreeComposite tree) { DataComponent dataNode = null; if (tree != null) { dataNode = (DataComponent) tree.getActiveDataNode(); if (dataNode == null && !tree.getDataNodes().isEmpty()) { dataNode = (DataComponent) tree.getDataNodes().get(0); } } return dataNode; } | /**
* Gets whether or not the specified <code>TreeComposite</code> can have an
* <code>Entry</code> (aka property or parameter) added to it. The
* <code>DataComponent</code> that can receive the new <code>Entry</code> is
* returned.
*
* @param tree
* The tree to which we would like to a... | Gets whether or not the specified <code>TreeComposite</code> can have an <code>Entry</code> (aka property or parameter) added to it. The <code>DataComponent</code> that can receive the new <code>Entry</code> is returned | canAdd | {
"repo_name": "SmithRWORNL/ice",
"path": "src/org.eclipse.ice.client.widgets/src/org/eclipse/ice/client/widgets/TreePropertySection.java",
"license": "epl-1.0",
"size": 34861
} | [
"org.eclipse.ice.datastructures.form.DataComponent",
"org.eclipse.ice.datastructures.form.TreeComposite"
] | import org.eclipse.ice.datastructures.form.DataComponent; import org.eclipse.ice.datastructures.form.TreeComposite; | import org.eclipse.ice.datastructures.form.*; | [
"org.eclipse.ice"
] | org.eclipse.ice; | 1,112,306 |
public static void printHelp(String cmdLineSyntax, String header,
Options options, String footer) {
HelpFormatter hf=new HelpFormatter();
if (CommUtil.isBlank(cmdLineSyntax)) {
cmdLineSyntax = "Command [options]...";
}
header = header +SysUtil.LINE_SEPARATOR+"Options:";
footer = SysUtil.LINE_SEPAR... | static void function(String cmdLineSyntax, String header, Options options, String footer) { HelpFormatter hf=new HelpFormatter(); if (CommUtil.isBlank(cmdLineSyntax)) { cmdLineSyntax = STR; } header = header +SysUtil.LINE_SEPARATOR+STR; footer = SysUtil.LINE_SEPARATOR + footer; hf.printHelp(cmdLineSyntax, header, optio... | /**
* Print the help for <code>options</code> with the specified command line
* syntax. This method prints help information to System.out.
*
* @param cmdLineSyntax
* the syntax for this application
* @param header
* the banner to display at the begining of the help
* @param option... | Print the help for <code>options</code> with the specified command line syntax. This method prints help information to System.out | printHelp | {
"repo_name": "rockagen/commons-lib",
"path": "src/main/java/com/rockagen/commons/util/CmdUtil.java",
"license": "apache-2.0",
"size": 7893
} | [
"org.apache.commons.cli.HelpFormatter",
"org.apache.commons.cli.Options"
] | import org.apache.commons.cli.HelpFormatter; import org.apache.commons.cli.Options; | import org.apache.commons.cli.*; | [
"org.apache.commons"
] | org.apache.commons; | 1,056,462 |
private AclStatus createAclStatus(JSONObject json) {
AclStatus.Builder aclStatusBuilder = new AclStatus.Builder()
.owner((String) json.get(OWNER_JSON))
.group((String) json.get(GROUP_JSON))
.stickyBit((Boolean) json.get(ACL_STICKY_BIT_JSON));
JSONArray entries = (JSONArray)... | AclStatus function(JSONObject json) { AclStatus.Builder aclStatusBuilder = new AclStatus.Builder() .owner((String) json.get(OWNER_JSON)) .group((String) json.get(GROUP_JSON)) .stickyBit((Boolean) json.get(ACL_STICKY_BIT_JSON)); JSONArray entries = (JSONArray) json.get(ACL_ENTRIES_JSON); for ( Object e : entries ) { acl... | /**
* Convert the given JSON object into an AclStatus
* @param json Input JSON representing the ACLs
* @return Resulting AclStatus
*/ | Convert the given JSON object into an AclStatus | createAclStatus | {
"repo_name": "ronny-macmaster/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs-httpfs/src/main/java/org/apache/hadoop/fs/http/client/HttpFSFileSystem.java",
"license": "apache-2.0",
"size": 57804
} | [
"org.apache.hadoop.fs.permission.AclEntry",
"org.apache.hadoop.fs.permission.AclStatus",
"org.json.simple.JSONArray",
"org.json.simple.JSONObject"
] | import org.apache.hadoop.fs.permission.AclEntry; import org.apache.hadoop.fs.permission.AclStatus; import org.json.simple.JSONArray; import org.json.simple.JSONObject; | import org.apache.hadoop.fs.permission.*; import org.json.simple.*; | [
"org.apache.hadoop",
"org.json.simple"
] | org.apache.hadoop; org.json.simple; | 2,405,451 |
void preModifyTableHandler(
final ObserverContext<MasterCoprocessorEnvironment> ctx,
final byte[] tableName, HTableDescriptor htd) throws IOException; | void preModifyTableHandler( final ObserverContext<MasterCoprocessorEnvironment> ctx, final byte[] tableName, HTableDescriptor htd) throws IOException; | /**
* Called prior to modifying a table's properties. Called as part of modify
* table handler and it is async to the modify table RPC call.
* It can't bypass the default action, e.g., ctx.bypass() won't have effect.
* @param ctx the environment to interact with the framework and master
* @param tableNa... | Called prior to modifying a table's properties. Called as part of modify table handler and it is async to the modify table RPC call. It can't bypass the default action, e.g., ctx.bypass() won't have effect | preModifyTableHandler | {
"repo_name": "daidong/DominoHBase",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/coprocessor/MasterObserver.java",
"license": "apache-2.0",
"size": 21042
} | [
"java.io.IOException",
"org.apache.hadoop.hbase.HTableDescriptor"
] | import java.io.IOException; import org.apache.hadoop.hbase.HTableDescriptor; | import java.io.*; import org.apache.hadoop.hbase.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 459,967 |
private void addZipArtifact(PrintWriter writer, String connectorPath, ZipArtifact zip) {
String artifactHash = Util.sha1Prefix(zip.getUrl());
String artifactDir = connectorPath + "/" + artifactHash;
String archivePath = connectorPath + "/" + artifactHash + ".zip";
String downloadCmd... | void function(PrintWriter writer, String connectorPath, ZipArtifact zip) { String artifactHash = Util.sha1Prefix(zip.getUrl()); String artifactDir = connectorPath + "/" + artifactHash; String archivePath = connectorPath + "/" + artifactHash + ".zip"; String downloadCmd = STR + archivePath + " " + zip.getUrl(); String u... | /**
* Add command sequence for downloading and unpacking TAR.ZIP archives and checking their checksums.
*
* @param writer Writer for printing the Docker commands
* @param connectorPath Path where the connector to which this artifact belongs should be downloaded
* @param zip ... | Add command sequence for downloading and unpacking TAR.ZIP archives and checking their checksums | addZipArtifact | {
"repo_name": "scholzj/barnabas",
"path": "cluster-operator/src/main/java/io/strimzi/operator/cluster/model/KafkaConnectDockerfile.java",
"license": "apache-2.0",
"size": 14520
} | [
"io.strimzi.api.kafka.model.connect.build.ZipArtifact",
"io.strimzi.operator.common.Util",
"java.io.PrintWriter"
] | import io.strimzi.api.kafka.model.connect.build.ZipArtifact; import io.strimzi.operator.common.Util; import java.io.PrintWriter; | import io.strimzi.api.kafka.model.connect.build.*; import io.strimzi.operator.common.*; import java.io.*; | [
"io.strimzi.api",
"io.strimzi.operator",
"java.io"
] | io.strimzi.api; io.strimzi.operator; java.io; | 2,004,440 |
public void removeRaid(int n) throws IncoherentNumberException {
if (n < 0 || n >= this.raids.size())
throw new IncoherentNumberException();
else
this.raids.remove(n);
} | void function(int n) throws IncoherentNumberException { if (n < 0 n >= this.raids.size()) throw new IncoherentNumberException(); else this.raids.remove(n); } | /**
* Remove the nth raid in the list (starting at 0)
* @param n
*/ | Remove the nth raid in the list (starting at 0) | removeRaid | {
"repo_name": "LogicalKip/BitingDeath",
"path": "src/structure/RaidManagingDialog.java",
"license": "agpl-3.0",
"size": 7088
} | [
"com.logicalkip.bitingdeath.exceptions.IncoherentNumberException"
] | import com.logicalkip.bitingdeath.exceptions.IncoherentNumberException; | import com.logicalkip.bitingdeath.exceptions.*; | [
"com.logicalkip.bitingdeath"
] | com.logicalkip.bitingdeath; | 1,087,026 |
private void handleLongOptionWithEqual(String token) throws ParseException
{
int pos = token.indexOf('=');
String value = token.substring(pos + 1);
String opt = token.substring(0, pos);
List<String> matchingOpts = options.getMatchingOptions(opt);
if (matchingOpts.isEmp... | void function(String token) throws ParseException { int pos = token.indexOf('='); String value = token.substring(pos + 1); String opt = token.substring(0, pos); List<String> matchingOpts = options.getMatchingOptions(opt); if (matchingOpts.isEmpty()) { handleUnknownToken(currentToken); } else if (matchingOpts.size() > 1... | /**
* Handles the following tokens:
*
* --L=V
* -L=V
* --l=V
* -l=V
*
* @param token the command line token to handle
*/ | Handles the following tokens: --L=V -L=V --l=V -l=V | handleLongOptionWithEqual | {
"repo_name": "trivium-io/trivium-core",
"path": "src/io/trivium/dep/org/apache/commons/cli/DefaultParser.java",
"license": "apache-2.0",
"size": 20398
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,432,699 |
Observable<ServiceResponse<Void>> getIntNegativeOneMillionWithServiceResponseAsync(); | Observable<ServiceResponse<Void>> getIntNegativeOneMillionWithServiceResponseAsync(); | /**
* Get '-1000000' integer value.
*
* @return the {@link ServiceResponse} object if successful.
*/ | Get '-1000000' integer value | getIntNegativeOneMillionWithServiceResponseAsync | {
"repo_name": "yugangw-msft/autorest",
"path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/url/Paths.java",
"license": "mit",
"size": 26061
} | [
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.rest.ServiceResponse; | import com.microsoft.rest.*; | [
"com.microsoft.rest"
] | com.microsoft.rest; | 924,998 |
public ImmutableTriple<String, String, ContextElement> doMap(String originalService, String originalServicePath,
ContextElement originalCE) {
if (nameMappings == null) {
LOGGER.info("[nmi] No namemappings to map entity " + originalCE.toString());
return new ImmutableTripl... | ImmutableTriple<String, String, ContextElement> function(String originalService, String originalServicePath, ContextElement originalCE) { if (nameMappings == null) { LOGGER.info(STR + originalCE.toString()); return new ImmutableTriple(originalService, originalServicePath, originalCE); } String newService = originalServ... | /**
* Applies the mappings to the input NotifyContextRequest object.
*
* @param originalService
* @param originalServicePath
* @param originalCE
* @return The input NotifyContextRequest object with maps applied
*/ | Applies the mappings to the input NotifyContextRequest object | doMap | {
"repo_name": "telefonicaid/fiware-cygnus",
"path": "cygnus-ngsi/src/main/java/com/telefonica/iot/cygnus/interceptors/NGSINameMappingsInterceptor.java",
"license": "agpl-3.0",
"size": 21777
} | [
"com.telefonica.iot.cygnus.containers.NameMappings",
"com.telefonica.iot.cygnus.containers.NotifyContextRequest",
"org.apache.commons.lang3.tuple.ImmutableTriple"
] | import com.telefonica.iot.cygnus.containers.NameMappings; import com.telefonica.iot.cygnus.containers.NotifyContextRequest; import org.apache.commons.lang3.tuple.ImmutableTriple; | import com.telefonica.iot.cygnus.containers.*; import org.apache.commons.lang3.tuple.*; | [
"com.telefonica.iot",
"org.apache.commons"
] | com.telefonica.iot; org.apache.commons; | 1,228,479 |
private Node parseParamTypeExpressionAnnotation(JsDocToken token) {
Preconditions.checkArgument(token == JsDocToken.LC);
skipEOLs();
boolean restArg = false;
token = next();
if (token == JsDocToken.ELLIPSIS) {
token = next();
if (token == JsDocToken.RC) {
// EMPTY represents ... | Node function(JsDocToken token) { Preconditions.checkArgument(token == JsDocToken.LC); skipEOLs(); boolean restArg = false; token = next(); if (token == JsDocToken.ELLIPSIS) { token = next(); if (token == JsDocToken.RC) { return wrapNode(Token.ELLIPSIS, new Node(Token.EMPTY)); } restArg = true; } Node typeNode = parseT... | /**
* ParamTypeExpressionAnnotation :=
* '{' OptionalParameterType '}' |
* '{' TopLevelTypeExpression '}' |
* '{' '...' TopLevelTypeExpression '}'
*
* OptionalParameterType :=
* TopLevelTypeExpression '='
*/ | ParamTypeExpressionAnnotation := '{' OptionalParameterType '}' | '{' TopLevelTypeExpression '}' | '{' '...' TopLevelTypeExpression '}' OptionalParameterType := TopLevelTypeExpression '=' | parseParamTypeExpressionAnnotation | {
"repo_name": "JonathanWalsh/Granule-Closure-Compiler",
"path": "src/com/google/javascript/jscomp/parsing/JsDocInfoParser.java",
"license": "apache-2.0",
"size": 73655
} | [
"com.google.common.base.Preconditions",
"com.google.javascript.rhino.Node",
"com.google.javascript.rhino.Token"
] | import com.google.common.base.Preconditions; import com.google.javascript.rhino.Node; import com.google.javascript.rhino.Token; | import com.google.common.base.*; import com.google.javascript.rhino.*; | [
"com.google.common",
"com.google.javascript"
] | com.google.common; com.google.javascript; | 1,274,206 |
protected FileSplit makeSplit(Path file, long start, long length,
String[] hosts, String[] inMemoryHosts) {
return new FileSplit(file, start, length, hosts, inMemoryHosts);
}
| FileSplit function(Path file, long start, long length, String[] hosts, String[] inMemoryHosts) { return new FileSplit(file, start, length, hosts, inMemoryHosts); } | /**
* A factory that makes the split for this class. It can be overridden
* by sub-classes to make sub-types
*/ | A factory that makes the split for this class. It can be overridden by sub-classes to make sub-types | makeSplit | {
"repo_name": "robgil/Aleph2-contrib",
"path": "aleph2_analytic_services_hadoop/src/main/java/com/ikanow/aleph2/analytics/hadoop/assets/UpdatedFileInputFormat.java",
"license": "apache-2.0",
"size": 21716
} | [
"org.apache.hadoop.fs.Path",
"org.apache.hadoop.mapreduce.lib.input.FileSplit"
] | import org.apache.hadoop.fs.Path; import org.apache.hadoop.mapreduce.lib.input.FileSplit; | import org.apache.hadoop.fs.*; import org.apache.hadoop.mapreduce.lib.input.*; | [
"org.apache.hadoop"
] | org.apache.hadoop; | 1,764,839 |
@Test(enabled = false)
public final void testExactlyOne() throws TTXPathException {
final String query = "fn:exactly-one(\"a\")";
final String result = "a";
XPathStringChecker.testIAxisConventions(holder.getNRtx(), new XPathAxis(holder.getNRtx(), query),
new String[] {
... | @Test(enabled = false) final void function() throws TTXPathException { final String query = STRa\")"; final String result = "a"; XPathStringChecker.testIAxisConventions(holder.getNRtx(), new XPathAxis(holder.getNRtx(), query), new String[] { result }); } | /**
* Test function exactly-one().
*
* @throws TTXPathException
*/ | Test function exactly-one() | testExactlyOne | {
"repo_name": "sebastiangraf/treetank",
"path": "interfacemodules/xml/src/test/java/org/treetank/service/xml/xpath/FunctionsTest.java",
"license": "bsd-3-clause",
"size": 17598
} | [
"org.testng.annotations.Test",
"org.treetank.exception.TTXPathException"
] | import org.testng.annotations.Test; import org.treetank.exception.TTXPathException; | import org.testng.annotations.*; import org.treetank.exception.*; | [
"org.testng.annotations",
"org.treetank.exception"
] | org.testng.annotations; org.treetank.exception; | 447,166 |
public static boolean isNullConversion(MethodType call, MethodType recv) {
if (call == recv) return true;
int len = call.parameterCount();
if (len != recv.parameterCount()) return false;
for (int i = 0; i < len; i++)
if (!isNullConversion(call.parameterType(i), recv.par... | static boolean function(MethodType call, MethodType recv) { if (call == recv) return true; int len = call.parameterCount(); if (len != recv.parameterCount()) return false; for (int i = 0; i < len; i++) if (!isNullConversion(call.parameterType(i), recv.parameterType(i))) return false; return isNullConversion(recv.return... | /**
* True if a method handle can receive a call under a slightly different
* method type, without moving or reformatting any stack elements.
*
* @param call the type of call being made
* @param recv the type of the method handle receiving the call
* @return whether the retyping can be don... | True if a method handle can receive a call under a slightly different method type, without moving or reformatting any stack elements | isNullConversion | {
"repo_name": "TheTypoMaster/Scaper",
"path": "openjdk/jdk/src/share/classes/sun/dyn/util/VerifyType.java",
"license": "gpl-2.0",
"size": 9315
} | [
"java.dyn.MethodType"
] | import java.dyn.MethodType; | import java.dyn.*; | [
"java.dyn"
] | java.dyn; | 1,259,477 |
@NonNull
@Headers("accept: application/json; charset=utf-8; "
+ "profile=\"https://www.mediawiki.org/wiki/Specs/aggregated-feed/0.5.0\"")
@GET("feed/featured/{year}/{month}/{day}")
Call<AggregatedFeedContent> get(@Path("year") String year,
... | @Headers(STR + STRhttps: @GET(STR) Call<AggregatedFeedContent> get(@Path("year") String year, @Path("month") String month, @Path("day") String day); } private static class CallbackAdapter implements retrofit2.Callback<AggregatedFeedContent> { @NonNull private final Callback cb; @NonNull private final WikiSite wiki; pri... | /**
* Gets aggregated content for the feed for the date provided.
*
* @param year four-digit year
* @param month two-digit month
* @param day two-digit day
*/ | Gets aggregated content for the feed for the date provided | get | {
"repo_name": "SAGROUP2/apps-android-wikipedia",
"path": "app/src/main/java/org/wikipedia/feed/aggregated/AggregatedFeedContentClient.java",
"license": "apache-2.0",
"size": 4174
} | [
"android.support.annotation.NonNull",
"org.wikipedia.dataclient.WikiSite"
] | import android.support.annotation.NonNull; import org.wikipedia.dataclient.WikiSite; | import android.support.annotation.*; import org.wikipedia.dataclient.*; | [
"android.support",
"org.wikipedia.dataclient"
] | android.support; org.wikipedia.dataclient; | 1,211,868 |
KickstartCommand cmd = new KickstartCommand();
cmd.setCreated(new Date());
cmd.setCommandName(findCommandName(KickstartData.SELINUX_MODE_COMMAND));
cmd.setArguments("--" + mode.getValue());
cmd.setKickstartData(ksdata);
ksdata.removeCommand(KickstartData.SELINUX_MODE_COMMAND, fal... | KickstartCommand cmd = new KickstartCommand(); cmd.setCreated(new Date()); cmd.setCommandName(findCommandName(KickstartData.SELINUX_MODE_COMMAND)); cmd.setArguments("--" + mode.getValue()); cmd.setKickstartData(ksdata); ksdata.removeCommand(KickstartData.SELINUX_MODE_COMMAND, false); ksdata.getCommands().add(cmd); } | /**
* Sets the se linux mode of the kick start profile..
* @param mode the selinux mode enforcing/permissive/disabled
*/ | Sets the se linux mode of the kick start profile. | setMode | {
"repo_name": "colloquium/spacewalk",
"path": "java/code/src/com/redhat/rhn/manager/kickstart/SystemDetailsCommand.java",
"license": "gpl-2.0",
"size": 5725
} | [
"com.redhat.rhn.domain.kickstart.KickstartCommand",
"com.redhat.rhn.domain.kickstart.KickstartData",
"java.util.Date"
] | import com.redhat.rhn.domain.kickstart.KickstartCommand; import com.redhat.rhn.domain.kickstart.KickstartData; import java.util.Date; | import com.redhat.rhn.domain.kickstart.*; import java.util.*; | [
"com.redhat.rhn",
"java.util"
] | com.redhat.rhn; java.util; | 2,465,206 |
public int getPenetratingPower(ItemStack stack); | int function(ItemStack stack); | /**
* The amount of damage bypassing armor
* @param stack The {@link net.minecraft.item.ItemStack} representative of the item dealing the hit.
* @return the amount of damage that bypasses armour
*/ | The amount of damage bypassing armor | getPenetratingPower | {
"repo_name": "TheAwesomeGem/MineFantasy",
"path": "src/main/java/mods/battlegear2/api/weapons/IPenetrateWeapon.java",
"license": "lgpl-2.1",
"size": 372
} | [
"net.minecraft.item.ItemStack"
] | import net.minecraft.item.ItemStack; | import net.minecraft.item.*; | [
"net.minecraft.item"
] | net.minecraft.item; | 91,477 |
final RexToDrill visitor = new RexToDrill(context, input);
return expr.accept(visitor);
}
private static class RexToDrill extends RexVisitorImpl<LogicalExpression> {
private final RelNode input;
private final DrillParseContext context;
RexToDrill(DrillParseContext context, RelNode input) {
s... | final RexToDrill visitor = new RexToDrill(context, input); return expr.accept(visitor); } private static class RexToDrill extends RexVisitorImpl<LogicalExpression> { private final RelNode input; private final DrillParseContext context; RexToDrill(DrillParseContext context, RelNode input) { super(true); this.context = c... | /**
* Converts a tree of {@link RexNode} operators into a scalar expression in Drill syntax.
*/ | Converts a tree of <code>RexNode</code> operators into a scalar expression in Drill syntax | toDrill | {
"repo_name": "zzy6395/drill",
"path": "exec/java-exec/src/main/java/org/apache/drill/exec/planner/logical/DrillOptiq.java",
"license": "apache-2.0",
"size": 21032
} | [
"org.apache.drill.common.expression.LogicalExpression",
"org.eigenbase.rel.RelNode",
"org.eigenbase.rex.RexVisitorImpl"
] | import org.apache.drill.common.expression.LogicalExpression; import org.eigenbase.rel.RelNode; import org.eigenbase.rex.RexVisitorImpl; | import org.apache.drill.common.expression.*; import org.eigenbase.rel.*; import org.eigenbase.rex.*; | [
"org.apache.drill",
"org.eigenbase.rel",
"org.eigenbase.rex"
] | org.apache.drill; org.eigenbase.rel; org.eigenbase.rex; | 1,762,979 |
public void setListView(ListView listView) {
this.listView = listView;
}
| void function(ListView listView) { this.listView = listView; } | /**
* Sets the list view.
*
* @param listView the new list view
*/ | Sets the list view | setListView | {
"repo_name": "JinBuHanLin/eshow-android",
"path": "eshow_framwork/src/cn/org/eshow/framwork/view/sample/AbLetterFilterListView.java",
"license": "apache-2.0",
"size": 7358
} | [
"android.widget.ListView"
] | import android.widget.ListView; | import android.widget.*; | [
"android.widget"
] | android.widget; | 1,356,693 |
public HttpUriBuilder appendPath(String path)
{
Preconditions.checkNotNull(path, "path is null");
StringBuilder builder = new StringBuilder(this.path);
if (!this.path.endsWith("/")) {
builder.append('/');
}
if (path.startsWith("/")) {
path = path... | HttpUriBuilder function(String path) { Preconditions.checkNotNull(path, STR); StringBuilder builder = new StringBuilder(this.path); if (!this.path.endsWith("/")) { builder.append('/'); } if (path.startsWith("/")) { path = path.substring(1); } builder.append(path); this.path = builder.toString(); return this; } | /**
* Append an unencoded path.
*
* All reserved characters except '/' will be percent-encoded. '/' are considered as path separators and
* appended verbatim.
*/ | Append an unencoded path. All reserved characters except '/' will be percent-encoded. '/' are considered as path separators and appended verbatim | appendPath | {
"repo_name": "daququ/airlift",
"path": "http-client/src/main/java/io/airlift/http/client/HttpUriBuilder.java",
"license": "apache-2.0",
"size": 9759
} | [
"com.google.common.base.Preconditions"
] | import com.google.common.base.Preconditions; | import com.google.common.base.*; | [
"com.google.common"
] | com.google.common; | 344,650 |
public void render(String template, int width, int height) {
render(WXPerformance.DEFAULT, template, null, null, width, height, mRenderStrategy);
} | void function(String template, int width, int height) { render(WXPerformance.DEFAULT, template, null, null, width, height, mRenderStrategy); } | /**
* Render template asynchronously, use {@link WXRenderStrategy#APPEND_ASYNC} as render strategy
* @param template bundle js
* @param width default match_parent
* @param height default match_parent
*/ | Render template asynchronously, use <code>WXRenderStrategy#APPEND_ASYNC</code> as render strategy | render | {
"repo_name": "lzyzsd/weex",
"path": "android/sdk/src/main/java/com/taobao/weex/WXSDKInstance.java",
"license": "apache-2.0",
"size": 41288
} | [
"com.taobao.weex.common.WXPerformance"
] | import com.taobao.weex.common.WXPerformance; | import com.taobao.weex.common.*; | [
"com.taobao.weex"
] | com.taobao.weex; | 258,466 |
public Adapter createOperatorAdapter() {
return null;
} | Adapter function() { return null; } | /**
* Creates a new adapter for an object of class '{@link fr.lip6.move.pnml.hlpn.terms.Operator <em>Operator</em>}'.
* <!-- begin-user-doc -->
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!--... | Creates a new adapter for an object of class '<code>fr.lip6.move.pnml.hlpn.terms.Operator Operator</code>'. This default implementation returns null so that we can easily ignore cases; it's useful to ignore a case when inheritance will catch all the cases anyway. | createOperatorAdapter | {
"repo_name": "lhillah/pnmlframework",
"path": "pnmlFw-HLPN/src/fr/lip6/move/pnml/hlpn/lists/util/ListsAdapterFactory.java",
"license": "epl-1.0",
"size": 13561
} | [
"org.eclipse.emf.common.notify.Adapter"
] | import org.eclipse.emf.common.notify.Adapter; | import org.eclipse.emf.common.notify.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 1,668,028 |
public boolean isEqualJob(TaskFlowJob job1, TaskFlowJob job2) throws IOException, ClassNotFoundException {
stack = new Stack<>();
stack.push("job");
stack.push("Job attributes");
if (!isEqualCommonAttribute(job1, job2))
return false;
stack.pop(); // job attribu... | boolean function(TaskFlowJob job1, TaskFlowJob job2) throws IOException, ClassNotFoundException { stack = new Stack<>(); stack.push("job"); stack.push(STR); if (!isEqualCommonAttribute(job1, job2)) return false; stack.pop(); if (!isEqualString(job1.getProjectName(), job2.getProjectName(), false)) { stack.push(STR); ret... | /**
*
* We state that: For any jobs (TaskFlowJob) job1 and job2 such that job1
* serialized to xml produces job1.xml job1.xml loaded in java produces job2
* then isEqual(job1,job2) == true
*
* @throws ClassNotFoundException
* @throws IOException
*/ | We state that: For any jobs (TaskFlowJob) job1 and job2 such that job1 serialized to xml produces job1.xml job1.xml loaded in java produces job2 then isEqual(job1,job2) == true | isEqualJob | {
"repo_name": "tobwiens/scheduling",
"path": "scheduler/scheduler-api/src/main/java/org/ow2/proactive/scheduler/common/job/factories/JobComparator.java",
"license": "agpl-3.0",
"size": 22342
} | [
"java.io.IOException",
"java.util.Stack",
"org.ow2.proactive.scheduler.common.job.TaskFlowJob"
] | import java.io.IOException; import java.util.Stack; import org.ow2.proactive.scheduler.common.job.TaskFlowJob; | import java.io.*; import java.util.*; import org.ow2.proactive.scheduler.common.job.*; | [
"java.io",
"java.util",
"org.ow2.proactive"
] | java.io; java.util; org.ow2.proactive; | 688,529 |
private boolean validateScreensSelectedToApplyScreens()
{
boolean valid = true;
if( CollectionUtils.isNotEmpty( this.showListSelectedRule ) )
{
if( CollectionUtils.isNotEmpty( this.bookingTOsSelected ) )
{
for( SpecialEventTO specialEventTO : this.bookingTOsSelected )
{
... | boolean function() { boolean valid = true; if( CollectionUtils.isNotEmpty( this.showListSelectedRule ) ) { if( CollectionUtils.isNotEmpty( this.bookingTOsSelected ) ) { for( SpecialEventTO specialEventTO : this.bookingTOsSelected ) { if( CollectionUtils.isEmpty( specialEventTO.getScreensSelected() ) ) { valid = false; ... | /**
* metodo para validar que al momento de aplicar reglas(copies,notes,dates,etc) tenga selecionado theater, y screens
*
* @return
*/ | metodo para validar que al momento de aplicar reglas(copies,notes,dates,etc) tenga selecionado theater, y screens | validateScreensSelectedToApplyScreens | {
"repo_name": "sidlors/digital-booking",
"path": "digital-booking-web/src/main/java/mx/com/cinepolis/digital/booking/web/beans/booking/PreReleaseBookingBean.java",
"license": "epl-1.0",
"size": 49794
} | [
"mx.com.cinepolis.digital.booking.commons.exception.DigitalBookingExceptionCode",
"mx.com.cinepolis.digital.booking.commons.to.SpecialEventTO",
"mx.com.cinepolis.digital.booking.commons.utils.DigitalBookingExceptionBuilder",
"org.apache.commons.collections.CollectionUtils"
] | import mx.com.cinepolis.digital.booking.commons.exception.DigitalBookingExceptionCode; import mx.com.cinepolis.digital.booking.commons.to.SpecialEventTO; import mx.com.cinepolis.digital.booking.commons.utils.DigitalBookingExceptionBuilder; import org.apache.commons.collections.CollectionUtils; | import mx.com.cinepolis.digital.booking.commons.exception.*; import mx.com.cinepolis.digital.booking.commons.to.*; import mx.com.cinepolis.digital.booking.commons.utils.*; import org.apache.commons.collections.*; | [
"mx.com.cinepolis",
"org.apache.commons"
] | mx.com.cinepolis; org.apache.commons; | 603,461 |
@GET
@Path("/{collection}/functions")
public View getActiveView(
@PathParam("collection") String collection,
@DefaultValue("false") @QueryParam("hideInactive") boolean hideInactive) throws Exception {
ThirdEyeAnomalyDetectionConfiguration config = collectionToConfigMap.get(collection);
switch ... | @Path(STR) View function( @PathParam(STR) String collection, @DefaultValue("false") @QueryParam(STR) boolean hideInactive) throws Exception { ThirdEyeAnomalyDetectionConfiguration config = collectionToConfigMap.get(collection); switch (config.getMode()) { case GENERIC: return getActiveGenericView(config, hideInactive);... | /**
* Show the functions defined for the collection.
*/ | Show the functions defined for the collection | getActiveView | {
"repo_name": "fjy/pinot",
"path": "thirdeye/thirdeye-anomaly/src/main/java/com/linkedin/thirdeye/anomaly/server/resources/FunctionTableResource.java",
"license": "apache-2.0",
"size": 19265
} | [
"com.linkedin.thirdeye.anomaly.ThirdEyeAnomalyDetectionConfiguration",
"io.dropwizard.views.View",
"javax.ws.rs.DefaultValue",
"javax.ws.rs.Path",
"javax.ws.rs.PathParam",
"javax.ws.rs.QueryParam"
] | import com.linkedin.thirdeye.anomaly.ThirdEyeAnomalyDetectionConfiguration; import io.dropwizard.views.View; import javax.ws.rs.DefaultValue; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.QueryParam; | import com.linkedin.thirdeye.anomaly.*; import io.dropwizard.views.*; import javax.ws.rs.*; | [
"com.linkedin.thirdeye",
"io.dropwizard.views",
"javax.ws"
] | com.linkedin.thirdeye; io.dropwizard.views; javax.ws; | 1,642,206 |
public void image_4(String p_testFileName, File fileList)
{
//setup
File inputFolder = setup(p_testFileName);
//embed
String[] embed = new String[]{"--embed",
"-I", fileList.getPath(),
"-a", DEFAULT_IMAGE_PRESET,
"-o", OUTPUT_FOLDER.getPath(),
"-k", KEY_FILE.getPath()};
Imagine.... | void function(String p_testFileName, File fileList) { File inputFolder = setup(p_testFileName); String[] embed = new String[]{STR, "-I", fileList.getPath(), "-a", DEFAULT_IMAGE_PRESET, "-o", OUTPUT_FOLDER.getPath(), "-k", KEY_FILE.getPath()}; Imagine.run(embed); String[] extract = new String[]{STR, "-i", OUTPUT_FOLDER.... | /**
* Input file list
*/ | Input file list | image_4 | {
"repo_name": "telgin/Imagine",
"path": "src/testing/highlevel/CmdUITest.java",
"license": "mit",
"size": 24015
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 1,542,324 |
public static EvalTemplateItem makeTemplateItem(EvalItem item) {
if (item == null) {
throw new IllegalArgumentException("Cannot create template item from null item");
}
EvalTemplateItem templateItem = new EvalTemplateItem(item.getOwner(), null, item, new Integer(0),
... | static EvalTemplateItem function(EvalItem item) { if (item == null) { throw new IllegalArgumentException(STR); } EvalTemplateItem templateItem = new EvalTemplateItem(item.getOwner(), null, item, new Integer(0), item.getCategory(), EvalConstants.HIERARCHY_LEVEL_TOP, EvalConstants.HIERARCHY_NODE_ID_NONE); templateItem.se... | /**
* Creates an {@link EvalTemplateItem} object from an {@link EvalItem} object by inferring
* the necessary parameters for previewing or rendering when only an item is available,
* does NOT create a persistent object<br/>
* NOTE: template is set to null
*
* @param item any item object ... | Creates an <code>EvalTemplateItem</code> object from an <code>EvalItem</code> object by inferring the necessary parameters for previewing or rendering when only an item is available, does NOT create a persistent object | makeTemplateItem | {
"repo_name": "marktriggs/nyu-sakai-10.4",
"path": "evaluation/api/src/java/org/sakaiproject/evaluation/utils/TemplateItemUtils.java",
"license": "apache-2.0",
"size": 34468
} | [
"org.sakaiproject.evaluation.constant.EvalConstants",
"org.sakaiproject.evaluation.model.EvalItem",
"org.sakaiproject.evaluation.model.EvalTemplateItem"
] | import org.sakaiproject.evaluation.constant.EvalConstants; import org.sakaiproject.evaluation.model.EvalItem; import org.sakaiproject.evaluation.model.EvalTemplateItem; | import org.sakaiproject.evaluation.constant.*; import org.sakaiproject.evaluation.model.*; | [
"org.sakaiproject.evaluation"
] | org.sakaiproject.evaluation; | 1,923,426 |
@Override
public boolean validate(List<String> warnings) {
return true;
} | boolean function(List<String> warnings) { return true; } | /**
* This plugin is always valid - no properties are required
*/ | This plugin is always valid - no properties are required | validate | {
"repo_name": "gdtlf/msg",
"path": "msg-platform/src/main/java/org/mybatis/generator/plugins/MySQLPaginationPlugin.java",
"license": "apache-2.0",
"size": 14520
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 496,542 |
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono<Response<ExpressRouteCircuitInner>> getByResourceGroupWithResponseAsync(
String resourceGroupName, String circuitName, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
... | @ServiceMethod(returns = ReturnType.SINGLE) Mono<Response<ExpressRouteCircuitInner>> function( String resourceGroupName, String circuitName, Context context) { if (this.client.getEndpoint() == null) { return Mono .error( new IllegalArgumentException( STR)); } if (resourceGroupName == null) { return Mono .error(new Ille... | /**
* Gets information about the specified express route circuit.
*
* @param resourceGroupName The name of the resource group.
* @param circuitName The name of express route circuit.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if... | Gets information about the specified express route circuit | getByResourceGroupWithResponseAsync | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-network/src/main/java/com/azure/resourcemanager/network/implementation/ExpressRouteCircuitsClientImpl.java",
"license": "mit",
"size": 143721
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.core.http.rest.Response",
"com.azure.core.util.Context",
"com.azure.resourcemanager.network.fluent.models.ExpressRouteCircuitInner"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.network.fluent.models.ExpressRouteCircuitInner; | import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.network.fluent.models.*; | [
"com.azure.core",
"com.azure.resourcemanager"
] | com.azure.core; com.azure.resourcemanager; | 2,427,383 |
private JdbcResult sendFile(JdbcBulkLoadAckResult cmdRes) throws SQLException {
String fileName = cmdRes.params().localFileName();
int batchSize = cmdRes.params().packetSize();
int batchNum = 0;
try {
try (InputStream input = new BufferedInputStream(new FileInputStream(... | JdbcResult function(JdbcBulkLoadAckResult cmdRes) throws SQLException { String fileName = cmdRes.params().localFileName(); int batchSize = cmdRes.params().packetSize(); int batchNum = 0; try { try (InputStream input = new BufferedInputStream(new FileInputStream(fileName))) { byte[] buf = new byte[batchSize]; int readBy... | /**
* Sends a file to server in batches via multiple {@link JdbcBulkLoadBatchRequest}s.
*
* @param cmdRes Result of invoking COPY command: contains server-parsed
* bulk load parameters, such as file name and batch size.
* @return Bulk load result.
* @throws SQLException On error.
*... | Sends a file to server in batches via multiple <code>JdbcBulkLoadBatchRequest</code>s | sendFile | {
"repo_name": "amirakhmedov/ignite",
"path": "modules/core/src/main/java/org/apache/ignite/internal/jdbc/thin/JdbcThinStatement.java",
"license": "apache-2.0",
"size": 26957
} | [
"java.io.BufferedInputStream",
"java.io.FileInputStream",
"java.io.InputStream",
"java.sql.SQLException",
"java.util.Arrays",
"org.apache.ignite.internal.processors.odbc.SqlStateCode",
"org.apache.ignite.internal.processors.odbc.jdbc.JdbcBulkLoadAckResult",
"org.apache.ignite.internal.processors.odbc.... | import java.io.BufferedInputStream; import java.io.FileInputStream; import java.io.InputStream; import java.sql.SQLException; import java.util.Arrays; import org.apache.ignite.internal.processors.odbc.SqlStateCode; import org.apache.ignite.internal.processors.odbc.jdbc.JdbcBulkLoadAckResult; import org.apache.ignite.in... | import java.io.*; import java.sql.*; import java.util.*; import org.apache.ignite.internal.processors.odbc.*; import org.apache.ignite.internal.processors.odbc.jdbc.*; | [
"java.io",
"java.sql",
"java.util",
"org.apache.ignite"
] | java.io; java.sql; java.util; org.apache.ignite; | 2,386,536 |
@GET
@Path("ports/{deviceId}")
@Produces(MediaType.APPLICATION_JSON)
public Response getPortStatisticsByDeviceId(@PathParam("deviceId") String deviceId) {
final DeviceService service = get(DeviceService.class);
final Iterable<PortStatistics> portStatsEntries =
service.get... | @Path(STR) @Produces(MediaType.APPLICATION_JSON) Response function(@PathParam(STR) String deviceId) { final DeviceService service = get(DeviceService.class); final Iterable<PortStatistics> portStatsEntries = service.getPortStatistics(DeviceId.deviceId(deviceId)); final ObjectNode root = mapper().createObjectNode(); fin... | /**
* Gets port statistics of a specified devices.
* @onos.rsModel StatisticsPorts
* @param deviceId device ID
* @return 200 OK with JSON encoded array of port statistics
*/ | Gets port statistics of a specified devices | getPortStatisticsByDeviceId | {
"repo_name": "osinstom/onos",
"path": "web/api/src/main/java/org/onosproject/rest/resources/StatisticsWebResource.java",
"license": "apache-2.0",
"size": 15112
} | [
"com.fasterxml.jackson.databind.node.ArrayNode",
"com.fasterxml.jackson.databind.node.ObjectNode",
"javax.ws.rs.Path",
"javax.ws.rs.PathParam",
"javax.ws.rs.Produces",
"javax.ws.rs.core.MediaType",
"javax.ws.rs.core.Response",
"org.onosproject.net.DeviceId",
"org.onosproject.net.device.DeviceService... | import com.fasterxml.jackson.databind.node.ArrayNode; import com.fasterxml.jackson.databind.node.ObjectNode; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; import org.onosproject.net.DeviceId; import org.onosprojec... | import com.fasterxml.jackson.databind.node.*; import javax.ws.rs.*; import javax.ws.rs.core.*; import org.onosproject.net.*; import org.onosproject.net.device.*; | [
"com.fasterxml.jackson",
"javax.ws",
"org.onosproject.net"
] | com.fasterxml.jackson; javax.ws; org.onosproject.net; | 1,682,637 |
public long length() throws IOException {
return length(userCreds);
} | long function() throws IOException { return length(userCreds); } | /**
* get file size
* @return the files size in bytes, or 0L if it does not exist
* @throws IOException
*/ | get file size | length | {
"repo_name": "kleingeist/xtreemfs",
"path": "java/servers/src/org/xtreemfs/common/clients/File.java",
"license": "bsd-3-clause",
"size": 19416
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,487,126 |
String key = String.valueOf(System.currentTimeMillis() / 1000);
Object result = null;
if (jedis instanceof Jedis) {
result = ((Jedis) this.jedis)
.eval(script, Collections.singletonList(key), Collections.singletonList(String.valueOf(limit)));
} else if (jedis instance... | String key = String.valueOf(System.currentTimeMillis() / 1000); Object result = null; if (jedis instanceof Jedis) { result = ((Jedis) this.jedis) .eval(script, Collections.singletonList(key), Collections.singletonList(String.valueOf(limit))); } else if (jedis instanceof JedisCluster) { result = ((JedisCluster) this.jed... | /**
* limit traffic
*
* @return if true
*/ | limit traffic | limit | {
"repo_name": "liuzyw/study-hello",
"path": "study-redis/src/main/java/com/study/redis/RedisLimit.java",
"license": "apache-2.0",
"size": 1965
} | [
"java.util.Collections",
"redis.clients.jedis.Jedis",
"redis.clients.jedis.JedisCluster"
] | import java.util.Collections; import redis.clients.jedis.Jedis; import redis.clients.jedis.JedisCluster; | import java.util.*; import redis.clients.jedis.*; | [
"java.util",
"redis.clients.jedis"
] | java.util; redis.clients.jedis; | 2,302,124 |
public ChainIterator<T> add(Iterator<T> another) {
return (ChainIterator<T>)super.add(another);
} | ChainIterator<T> function(Iterator<T> another) { return (ChainIterator<T>)super.add(another); } | /**
* Adds another iterator to the chain. Values from this iterator will follow the values of the iterator passed to the constructor.
* Adding after the iteration has started is safe.
* @param another iterator to add to the end of the chain.
* @return self, for easy chaining.
*/ | Adds another iterator to the chain. Values from this iterator will follow the values of the iterator passed to the constructor. Adding after the iteration has started is safe | add | {
"repo_name": "Lekanich/intellij-community",
"path": "python/src/com/jetbrains/python/toolbox/ChainIterator.java",
"license": "apache-2.0",
"size": 2057
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 499,901 |
public void addAttribute(Attribute attribute) {
if (attributes == null) {
attributes = new ArrayList<Attribute>();
}
attributes.add(attribute);
} | void function(Attribute attribute) { if (attributes == null) { attributes = new ArrayList<Attribute>(); } attributes.add(attribute); } | /**
* Add a new attribute.
*
* @param attribute
* the attribute
*/ | Add a new attribute | addAttribute | {
"repo_name": "hmunfru/fiware-sdc",
"path": "model/src/main/java/com/telefonica/euro_iaas/sdc/model/Artifact.java",
"license": "apache-2.0",
"size": 6295
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 1,687,205 |
public ISelection getSelection() {
return editorSelection;
} | ISelection function() { return editorSelection; } | /**
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | This implements <code>org.eclipse.jface.viewers.ISelectionProvider</code> to return this editor's overall selection. | getSelection | {
"repo_name": "unicesi/QD-SPL",
"path": "Generation/co.shift.modeling.m2m.editor/src/domainmetamodelm2m/presentation/Domainmetamodelm2mEditor.java",
"license": "lgpl-3.0",
"size": 54218
} | [
"org.eclipse.jface.viewers.ISelection"
] | import org.eclipse.jface.viewers.ISelection; | import org.eclipse.jface.viewers.*; | [
"org.eclipse.jface"
] | org.eclipse.jface; | 1,480,309 |
public ActionForward execute(
final ActionMapping mapping, final ActionForm form,
final HttpServletRequest request,
final HttpServletResponse response
) throws Exception {
// Get all organisms and attach to request
List<Organism> organisms = this.getDbService().loadAllO... | ActionForward function( final ActionMapping mapping, final ActionForm form, final HttpServletRequest request, final HttpServletResponse response ) throws Exception { List<Organism> organisms = this.getDbService().loadAllOrganisms(); request.setAttribute(STR, organisms); Set<Organism> organismsWithGeneData = this.getAnn... | /**
* Execute action.
* @param mapping Routing information for downstream actions
* @param form Form data
* @param request Servlet request object
* @param response Servlet response object
* @return Identification of downstream action as configured in the
* struts-config.xml file
... | Execute action | execute | {
"repo_name": "NCIP/webgenome",
"path": "tags/WEBGENOME_R3.2_6MAR2009_BUILD1/java/webui/src/org/rti/webgenome/webui/struts/admin/LoadGenesFormSetupAction.java",
"license": "bsd-3-clause",
"size": 2134
} | [
"java.util.List",
"java.util.Set",
"javax.servlet.http.HttpServletRequest",
"javax.servlet.http.HttpServletResponse",
"org.apache.struts.action.ActionForm",
"org.apache.struts.action.ActionForward",
"org.apache.struts.action.ActionMapping",
"org.rti.webgenome.domain.Organism"
] | import java.util.List; import java.util.Set; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.apache.struts.action.ActionForm; import org.apache.struts.action.ActionForward; import org.apache.struts.action.ActionMapping; import org.rti.webgenome.domain.Organism; | import java.util.*; import javax.servlet.http.*; import org.apache.struts.action.*; import org.rti.webgenome.domain.*; | [
"java.util",
"javax.servlet",
"org.apache.struts",
"org.rti.webgenome"
] | java.util; javax.servlet; org.apache.struts; org.rti.webgenome; | 2,839,593 |
public static String[] getArrayFromXDelimitedString( String xDelimitedString, String x ) {
List<String> list = getListFromXDelimitedString( xDelimitedString, x );
if ( list != null ) {
return list.toArray( new String[list.size()] );
}
else {
return... | static String[] function( String xDelimitedString, String x ) { List<String> list = getListFromXDelimitedString( xDelimitedString, x ); if ( list != null ) { return list.toArray( new String[list.size()] ); } else { return null; } } | /**
* Creates an array from a given String using the specified delimiter.
*
* @param xDelimitedString the complete String.
* @param x the delimiter for the complete String.
* @return array of Strings or null if the xDelimitedString is null
*/ | Creates an array from a given String using the specified delimiter | getArrayFromXDelimitedString | {
"repo_name": "metova/metova-android-sdk",
"path": "metova-android-core/src/com/metova/android/util/text/Strings.java",
"license": "apache-2.0",
"size": 36228
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,806,386 |
public static Path getHFileFromBackReference(final Configuration conf, final Path linkRefPath)
throws IOException {
return getHFileFromBackReference(FSUtils.getRootDir(conf), linkRefPath);
} | static Path function(final Configuration conf, final Path linkRefPath) throws IOException { return getHFileFromBackReference(FSUtils.getRootDir(conf), linkRefPath); } | /**
* Get the full path of the HFile referenced by the back reference
*
* @param conf {@link Configuration} to read for the archive directory name
* @param linkRefPath Link Back Reference path
* @return full path of the referenced hfile
* @throws IOException on unexpected error.
*/ | Get the full path of the HFile referenced by the back reference | getHFileFromBackReference | {
"repo_name": "francisliu/hbase_namespace",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/io/HFileLink.java",
"license": "apache-2.0",
"size": 14785
} | [
"java.io.IOException",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.fs.Path",
"org.apache.hadoop.hbase.util.FSUtils"
] | import java.io.IOException; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hbase.util.FSUtils; | import java.io.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.hbase.util.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 1,709,117 |
public static Class<?> detectClass(Object obj) {
assert obj != null;
if (obj instanceof GridPeerDeployAware)
return ((GridPeerDeployAware)obj).deployClass();
if (U.isPrimitiveArray(obj))
return obj.getClass();
if (!U.isJdk(obj.getClass()))
retur... | static Class<?> function(Object obj) { assert obj != null; if (obj instanceof GridPeerDeployAware) return ((GridPeerDeployAware)obj).deployClass(); if (U.isPrimitiveArray(obj)) return obj.getClass(); if (!U.isJdk(obj.getClass())) return obj.getClass(); if (obj instanceof Iterable<?>) { Object o = F.first((Iterable<?>)o... | /**
* Tries to detect user class from passed in object inspecting
* collections, arrays or maps.
*
* @param obj Object.
* @return First non-JDK or deployment aware class or passed in object class.
*/ | Tries to detect user class from passed in object inspecting collections, arrays or maps | detectClass | {
"repo_name": "shurun19851206/ignite",
"path": "modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java",
"license": "apache-2.0",
"size": 289056
} | [
"java.lang.reflect.Array",
"java.util.Map",
"org.apache.ignite.internal.util.lang.GridPeerDeployAware",
"org.apache.ignite.internal.util.typedef.F",
"org.apache.ignite.internal.util.typedef.internal.U"
] | import java.lang.reflect.Array; import java.util.Map; import org.apache.ignite.internal.util.lang.GridPeerDeployAware; import org.apache.ignite.internal.util.typedef.F; import org.apache.ignite.internal.util.typedef.internal.U; | import java.lang.reflect.*; import java.util.*; import org.apache.ignite.internal.util.lang.*; import org.apache.ignite.internal.util.typedef.*; import org.apache.ignite.internal.util.typedef.internal.*; | [
"java.lang",
"java.util",
"org.apache.ignite"
] | java.lang; java.util; org.apache.ignite; | 1,743,041 |
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
switch (requestCode) {
case REQUEST_PICK_STRUCTURE:
// Make sure the request was successful
if (resultCode... | void function(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); switch (requestCode) { case REQUEST_PICK_STRUCTURE: if (resultCode == RESULT_OK) { Uri structureUri = data.getData(); StructuresBean structuresBean = StructuresUpdate.getStructureId(this, structureUri); ... | /**
* Handles Google Play Services resolution callbacks.
*/ | Handles Google Play Services resolution callbacks | onActivityResult | {
"repo_name": "rmceoin/cominghome",
"path": "app/src/main/java/net/mceoin/cominghome/MainActivity.java",
"license": "apache-2.0",
"size": 43298
} | [
"android.content.Intent",
"android.content.SharedPreferences",
"android.net.Uri",
"android.util.Log",
"net.mceoin.cominghome.structures.StructuresBean",
"net.mceoin.cominghome.structures.StructuresUpdate"
] | import android.content.Intent; import android.content.SharedPreferences; import android.net.Uri; import android.util.Log; import net.mceoin.cominghome.structures.StructuresBean; import net.mceoin.cominghome.structures.StructuresUpdate; | import android.content.*; import android.net.*; import android.util.*; import net.mceoin.cominghome.structures.*; | [
"android.content",
"android.net",
"android.util",
"net.mceoin.cominghome"
] | android.content; android.net; android.util; net.mceoin.cominghome; | 692,238 |
private void processForwardDeclare(NodeTraversal t, Node n, Node parent) {
CodingConvention convention = compiler.getCodingConvention();
String typeDeclaration = null;
try {
typeDeclaration = Iterables.getOnlyElement(
convention.identifyTypeDeclarationCall(n));
} catch (NullPointerExc... | void function(NodeTraversal t, Node n, Node parent) { CodingConvention convention = compiler.getCodingConvention(); String typeDeclaration = null; try { typeDeclaration = Iterables.getOnlyElement( convention.identifyTypeDeclarationCall(n)); } catch (NullPointerException NoSuchElementException IllegalArgumentException e... | /**
* Process a goog.forwardDeclare() call and record the specified forward
* declaration.
*/ | Process a goog.forwardDeclare() call and record the specified forward declaration | processForwardDeclare | {
"repo_name": "Dominator008/closure-compiler",
"path": "src/com/google/javascript/jscomp/ProcessClosurePrimitives.java",
"license": "apache-2.0",
"size": 55575
} | [
"com.google.common.collect.Iterables",
"com.google.javascript.rhino.Node",
"java.util.NoSuchElementException"
] | import com.google.common.collect.Iterables; import com.google.javascript.rhino.Node; import java.util.NoSuchElementException; | import com.google.common.collect.*; import com.google.javascript.rhino.*; import java.util.*; | [
"com.google.common",
"com.google.javascript",
"java.util"
] | com.google.common; com.google.javascript; java.util; | 496,658 |
public void setButtonPosition(RelativeLayout.LayoutParams layoutParams) {
mEndButton.setLayoutParams(layoutParams);
} | void function(RelativeLayout.LayoutParams layoutParams) { mEndButton.setLayoutParams(layoutParams); } | /**
* Change the position of the ShowcaseView's button from the default bottom-right position.
*
* @param layoutParams a {@link android.widget.RelativeLayout.LayoutParams} representing
* the new position of the button
*/ | Change the position of the ShowcaseView's button from the default bottom-right position | setButtonPosition | {
"repo_name": "xiaoyanit/cgeo",
"path": "showcaseview/java/com/github/amlcurran/showcaseview/ShowcaseView.java",
"license": "apache-2.0",
"size": 19749
} | [
"android.widget.RelativeLayout"
] | import android.widget.RelativeLayout; | import android.widget.*; | [
"android.widget"
] | android.widget; | 2,179,615 |
public BigDecimal getPlannedPrice ()
{
BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_PlannedPrice);
if (bd == null)
return Env.ZERO;
return bd;
} | BigDecimal function () { BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_PlannedPrice); if (bd == null) return Env.ZERO; return bd; } | /** Get Planned Price.
@return Planned price for this project line
*/ | Get Planned Price | getPlannedPrice | {
"repo_name": "arthurmelo88/palmetalADP",
"path": "adempiere_360/base/src/org/compiere/model/X_C_ProjectLine.java",
"license": "gpl-2.0",
"size": 15068
} | [
"java.math.BigDecimal",
"org.compiere.util.Env"
] | import java.math.BigDecimal; import org.compiere.util.Env; | import java.math.*; import org.compiere.util.*; | [
"java.math",
"org.compiere.util"
] | java.math; org.compiere.util; | 2,646,851 |
protected Set<Long> load(Type fileType) {
return deleteTargets.get(fileType.toString());
} | Set<Long> function(Type fileType) { return deleteTargets.get(fileType.toString()); } | /**
* Lookup the ids which are scheduled for deletion.
* @param fileType non-null
* @return the IDs for that file type
*/ | Lookup the ids which are scheduled for deletion | load | {
"repo_name": "knabar/openmicroscopy",
"path": "components/server/src/ome/services/delete/files/FileDeleter.java",
"license": "gpl-2.0",
"size": 4028
} | [
"java.util.Set"
] | import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 2,149,019 |
public static ClosableIterator<org.ontoware.rdf2go.model.node.Node> getAllImports_asNode(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource) {
return Base.getAll_asNode(model, instanceResource, IMPORTS);
}
| static ClosableIterator<org.ontoware.rdf2go.model.node.Node> function(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource) { return Base.getAll_asNode(model, instanceResource, IMPORTS); } | /**
* Get all values of property Imports as an Iterator over RDF2Go nodes
* @param model an RDF2Go model
* @param resource an RDF2Go resource
* @return a ClosableIterator of RDF2Go Nodes
*
* [Generated from RDFReactor template rule #get7static]
*/ | Get all values of property Imports as an Iterator over RDF2Go nodes | getAllImports_asNode | {
"repo_name": "josectoledo/semweb4j",
"path": "org.semweb4j.rdfreactor.runtime/src/main/java/org/ontoware/rdfreactor/schema/owl/Ontology.java",
"license": "bsd-2-clause",
"size": 50761
} | [
"org.ontoware.aifbcommons.collection.ClosableIterator",
"org.ontoware.rdf2go.model.Model",
"org.ontoware.rdfreactor.runtime.Base"
] | import org.ontoware.aifbcommons.collection.ClosableIterator; import org.ontoware.rdf2go.model.Model; import org.ontoware.rdfreactor.runtime.Base; | import org.ontoware.aifbcommons.collection.*; import org.ontoware.rdf2go.model.*; import org.ontoware.rdfreactor.runtime.*; | [
"org.ontoware.aifbcommons",
"org.ontoware.rdf2go",
"org.ontoware.rdfreactor"
] | org.ontoware.aifbcommons; org.ontoware.rdf2go; org.ontoware.rdfreactor; | 84,522 |
public static String encodeBase64(String data) {
byte[] bytes = data.getBytes(StandardCharsets.UTF_8);
return encodeBase64(bytes);
} | static String function(String data) { byte[] bytes = data.getBytes(StandardCharsets.UTF_8); return encodeBase64(bytes); } | /**
* Encodes a String as a base64 String.
*
* @param data a String to encode.
* @return a base64 encoded String.
*/ | Encodes a String as a base64 String | encodeBase64 | {
"repo_name": "zhouluoyang/openfire",
"path": "src/java/org/jivesoftware/util/StringUtils.java",
"license": "apache-2.0",
"size": 40539
} | [
"java.nio.charset.StandardCharsets"
] | import java.nio.charset.StandardCharsets; | import java.nio.charset.*; | [
"java.nio"
] | java.nio; | 785,344 |
public static Uri buildMediaScratchSpaceUri(final String extension) {
final Uri uri = buildFileUri(AUTHORITY, extension);
final File file = getFileWithExtension(uri.getPath(), extension);
if (!ensureFileExists(file)) {
Log.e(TAG, "Failed to create temp file " + file.getAbsolutePa... | static Uri function(final String extension) { final Uri uri = buildFileUri(AUTHORITY, extension); final File file = getFileWithExtension(uri.getPath(), extension); if (!ensureFileExists(file)) { Log.e(TAG, STR + file.getAbsolutePath()); } return uri; } | /**
* Returns a uri that can be used to access a raw mms file.
*
* @return the URI for an raw mms file
*/ | Returns a uri that can be used to access a raw mms file | buildMediaScratchSpaceUri | {
"repo_name": "NickAndroid/Screencast",
"path": "app/src/main/java/dev/nick/app/screencast/camera/MediaScratchFileProvider.java",
"license": "mit",
"size": 4942
} | [
"android.net.Uri",
"android.util.Log",
"java.io.File"
] | import android.net.Uri; import android.util.Log; import java.io.File; | import android.net.*; import android.util.*; import java.io.*; | [
"android.net",
"android.util",
"java.io"
] | android.net; android.util; java.io; | 2,472,537 |
public ServiceFuture<ExpressRouteCrossConnectionInner> updateTagsAsync(String resourceGroupName, String crossConnectionName, Map<String, String> tags, final ServiceCallback<ExpressRouteCrossConnectionInner> serviceCallback) {
return ServiceFuture.fromResponse(updateTagsWithServiceResponseAsync(resourceGroup... | ServiceFuture<ExpressRouteCrossConnectionInner> function(String resourceGroupName, String crossConnectionName, Map<String, String> tags, final ServiceCallback<ExpressRouteCrossConnectionInner> serviceCallback) { return ServiceFuture.fromResponse(updateTagsWithServiceResponseAsync(resourceGroupName, crossConnectionName,... | /**
* Updates an express route cross connection tags.
*
* @param resourceGroupName The name of the resource group.
* @param crossConnectionName The name of the cross connection.
* @param tags Resource tags.
* @param serviceCallback the async ServiceCallback to handle successful and failed ... | Updates an express route cross connection tags | updateTagsAsync | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2019_08_01/src/main/java/com/microsoft/azure/management/network/v2019_08_01/implementation/ExpressRouteCrossConnectionsInner.java",
"license": "mit",
"size": 110099
} | [
"com.microsoft.rest.ServiceCallback",
"com.microsoft.rest.ServiceFuture",
"java.util.Map"
] | import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture; import java.util.Map; | import com.microsoft.rest.*; import java.util.*; | [
"com.microsoft.rest",
"java.util"
] | com.microsoft.rest; java.util; | 865,066 |
Color color() {
return (Color)noStroke.get(Chunk.COLOR);
}
| Color color() { return (Color)noStroke.get(Chunk.COLOR); } | /**
* Returns the color of this <CODE>Chunk</CODE>.
*
* @return a <CODE>Color</CODE>
*/ | Returns the color of this <code>Chunk</code> | color | {
"repo_name": "shitalm/jsignpdf2",
"path": "src/main/java/com/lowagie/text/pdf/PdfChunk.java",
"license": "gpl-2.0",
"size": 28344
} | [
"com.lowagie.text.Chunk",
"java.awt.Color"
] | import com.lowagie.text.Chunk; import java.awt.Color; | import com.lowagie.text.*; import java.awt.*; | [
"com.lowagie.text",
"java.awt"
] | com.lowagie.text; java.awt; | 2,446,068 |
@Override public boolean visit(JsWhile x, JsContext ctx) {
resetPosition();
x.setCondition(accept(x.getCondition()));
accept(x.getBody());
return false;
} | @Override boolean function(JsWhile x, JsContext ctx) { resetPosition(); x.setCondition(accept(x.getCondition())); accept(x.getBody()); return false; } | /**
* Similar to JsFor, this resets the current location information before
* evaluating the condition.
*/ | Similar to JsFor, this resets the current location information before evaluating the condition | visit | {
"repo_name": "syntelos/gwtcc",
"path": "src/com/google/gwt/dev/js/CoverageVisitor.java",
"license": "apache-2.0",
"size": 5162
} | [
"com.google.gwt.dev.js.ast.JsContext",
"com.google.gwt.dev.js.ast.JsWhile"
] | import com.google.gwt.dev.js.ast.JsContext; import com.google.gwt.dev.js.ast.JsWhile; | import com.google.gwt.dev.js.ast.*; | [
"com.google.gwt"
] | com.google.gwt; | 1,193,944 |
public static KeyValue nextShallowCopy(final ByteBuffer bb, final boolean includesMvccVersion,
boolean includesTags) {
if (bb.isDirect()) {
throw new IllegalArgumentException("only supports heap buffers");
}
if (bb.remaining() < 1) {
return null;
}
KeyValue keyValue = null;
... | static KeyValue function(final ByteBuffer bb, final boolean includesMvccVersion, boolean includesTags) { if (bb.isDirect()) { throw new IllegalArgumentException(STR); } if (bb.remaining() < 1) { return null; } KeyValue keyValue = null; int underlyingArrayOffset = bb.arrayOffset() + bb.position(); int keyLength = bb.get... | /**
* Creates a new KeyValue object positioned in the supplied ByteBuffer and sets the ByteBuffer's
* position to the start of the next KeyValue. Does not allocate a new array or copy data.
* @param bb
* @param includesMvccVersion
* @param includesTags
*/ | Creates a new KeyValue object positioned in the supplied ByteBuffer and sets the ByteBuffer's position to the start of the next KeyValue. Does not allocate a new array or copy data | nextShallowCopy | {
"repo_name": "ultratendency/hbase",
"path": "hbase-common/src/main/java/org/apache/hadoop/hbase/KeyValueUtil.java",
"license": "apache-2.0",
"size": 32481
} | [
"java.nio.ByteBuffer",
"org.apache.hadoop.hbase.util.ByteBufferUtils"
] | import java.nio.ByteBuffer; import org.apache.hadoop.hbase.util.ByteBufferUtils; | import java.nio.*; import org.apache.hadoop.hbase.util.*; | [
"java.nio",
"org.apache.hadoop"
] | java.nio; org.apache.hadoop; | 2,728,575 |
@NonNull
List<ResourceItem> parseFile() throws MergingException {
Document document = parseDocument(mFile);
// get the root node
Node rootNode = document.getDocumentElement();
if (rootNode == null) {
return Collections.emptyList();
}
NodeList nodes = ... | List<ResourceItem> parseFile() throws MergingException { Document document = parseDocument(mFile); Node rootNode = document.getDocumentElement(); if (rootNode == null) { return Collections.emptyList(); } NodeList nodes = rootNode.getChildNodes(); final int count = nodes.getLength(); List<ResourceItem> resources = Lists... | /**
* Parses the file and returns a list of {@link ResourceItem} objects.
* @return a list of resources.
*
* @throws MergingException if a merging exception happens
*/ | Parses the file and returns a list of <code>ResourceItem</code> objects | parseFile | {
"repo_name": "tranleduy2000/javaide",
"path": "aosp/sdk-common/src/main/java/com/android/ide/common/res2/ValueResourceParser2.java",
"license": "gpl-3.0",
"size": 9573
} | [
"com.android.resources.ResourceType",
"com.google.common.collect.Lists",
"com.google.common.collect.Maps",
"java.util.Collections",
"java.util.List",
"java.util.Map",
"java.util.Set",
"org.w3c.dom.Document",
"org.w3c.dom.Node",
"org.w3c.dom.NodeList"
] | import com.android.resources.ResourceType; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import java.util.Collections; import java.util.List; import java.util.Map; import java.util.Set; import org.w3c.dom.Document; import org.w3c.dom.Node; import org.w3c.dom.NodeList; | import com.android.resources.*; import com.google.common.collect.*; import java.util.*; import org.w3c.dom.*; | [
"com.android.resources",
"com.google.common",
"java.util",
"org.w3c.dom"
] | com.android.resources; com.google.common; java.util; org.w3c.dom; | 551,682 |
private static MidiDevice getNamedDevice(String deviceName,
List providers,
Class deviceClass) {
MidiDevice device;
// try to get MIDI port
device = getNamedDevice(deviceName, providers, deviceClass,
... | static MidiDevice function(String deviceName, List providers, Class deviceClass) { MidiDevice device; device = getNamedDevice(deviceName, providers, deviceClass, false, false); if (device != null) { return device; } if (deviceClass == Receiver.class) { device = getNamedDevice(deviceName, providers, deviceClass, true, f... | /** Return a MidiDevice with a given name from a list of
MidiDeviceProviders.
@param deviceName The name of the MidiDevice to be returned.
@param providers The List of MidiDeviceProviders to check for
MidiDevices.
@param deviceClass The requested device type, one of Synthesizer.c... | Return a MidiDevice with a given name from a list of | getNamedDevice | {
"repo_name": "andreagenso/java2scala",
"path": "test/J2s/java/openjdk-6-src-b27/jdk/src/share/classes/javax/sound/midi/MidiSystem.java",
"license": "apache-2.0",
"size": 58684
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,314,818 |
public static Intent createIntent(List<Gist> gists, int position) {
String[] ids = new String[gists.size()];
int index = 0;
for (Gist gist : gists)
ids[index++] = gist.getId();
return new Builder("gists.VIEW")
.add(EXTRA_GIST_IDS, (Serializable) ids)
... | static Intent function(List<Gist> gists, int position) { String[] ids = new String[gists.size()]; int index = 0; for (Gist gist : gists) ids[index++] = gist.getId(); return new Builder(STR) .add(EXTRA_GIST_IDS, (Serializable) ids) .add(EXTRA_POSITION, position).toIntent(); } private ViewPager pager; private String[] gi... | /**
* Create an intent to show gists with an initial selected Gist
*
* @param gists
* @param position
* @return intent
*/ | Create an intent to show gists with an initial selected Gist | createIntent | {
"repo_name": "gmyboy/android",
"path": "app/src/main/java/com/github/mobile/ui/gist/GistsViewActivity.java",
"license": "apache-2.0",
"size": 7044
} | [
"android.content.Intent",
"com.github.mobile.Intents",
"com.github.mobile.core.gist.GistStore",
"com.github.mobile.ui.ViewPager",
"com.github.mobile.util.AvatarLoader",
"java.io.Serializable",
"java.util.List",
"org.eclipse.egit.github.core.Gist"
] | import android.content.Intent; import com.github.mobile.Intents; import com.github.mobile.core.gist.GistStore; import com.github.mobile.ui.ViewPager; import com.github.mobile.util.AvatarLoader; import java.io.Serializable; import java.util.List; import org.eclipse.egit.github.core.Gist; | import android.content.*; import com.github.mobile.*; import com.github.mobile.core.gist.*; import com.github.mobile.ui.*; import com.github.mobile.util.*; import java.io.*; import java.util.*; import org.eclipse.egit.github.core.*; | [
"android.content",
"com.github.mobile",
"java.io",
"java.util",
"org.eclipse.egit"
] | android.content; com.github.mobile; java.io; java.util; org.eclipse.egit; | 2,628,643 |
@NonNull
public static List<String> getAppSignaturesMD5(final String packageName) {
return getAppSignaturesHash(packageName, "MD5");
} | static List<String> function(final String packageName) { return getAppSignaturesHash(packageName, "MD5"); } | /**
* Return the application's signature for MD5 value.
*
* @param packageName The name of the package.
* @return the application's signature for MD5 value
*/ | Return the application's signature for MD5 value | getAppSignaturesMD5 | {
"repo_name": "didi/DoraemonKit",
"path": "Android/dokit-util/src/main/java/com/didichuxing/doraemonkit/util/AppUtils.java",
"license": "apache-2.0",
"size": 28606
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 720,655 |
public List<I_CmsResourceWrapper> getWrappers() {
return m_wrappers;
} | List<I_CmsResourceWrapper> function() { return m_wrappers; } | /**
* Gets the resource wrappers which have been configured for this repository.<p>
*
* @return the resource wrappers which have been configured
*/ | Gets the resource wrappers which have been configured for this repository | getWrappers | {
"repo_name": "ggiudetti/opencms-core",
"path": "src/org/opencms/jlan/CmsJlanRepository.java",
"license": "lgpl-2.1",
"size": 12277
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 68,081 |
private void fireExceptionListener(final int errorCode, final String errorMessage)
{
ActiveMQJournalLogger.LOGGER.ioError(errorCode, errorMessage);
if (ioExceptionListener != null)
{
ioExceptionListener.onIOException(ActiveMQExceptionType.getType(errorCode).createException(errorMessage)... | void function(final int errorCode, final String errorMessage) { ActiveMQJournalLogger.LOGGER.ioError(errorCode, errorMessage); if (ioExceptionListener != null) { ioExceptionListener.onIOException(ActiveMQExceptionType.getType(errorCode).createException(errorMessage), errorMessage); } } | /**
* This is called by the native layer
*
* @param errorCode
* @param errorMessage
*/ | This is called by the native layer | fireExceptionListener | {
"repo_name": "ryanemerson/activemq-artemis",
"path": "artemis-journal/src/main/java/org/apache/activemq/artemis/core/asyncio/impl/AsynchronousFileImpl.java",
"license": "apache-2.0",
"size": 21727
} | [
"org.apache.activemq.artemis.api.core.ActiveMQExceptionType",
"org.apache.activemq.artemis.journal.ActiveMQJournalLogger"
] | import org.apache.activemq.artemis.api.core.ActiveMQExceptionType; import org.apache.activemq.artemis.journal.ActiveMQJournalLogger; | import org.apache.activemq.artemis.api.core.*; import org.apache.activemq.artemis.journal.*; | [
"org.apache.activemq"
] | org.apache.activemq; | 625,154 |
protected HttpServletRequest getCurrentHttpRequest() {
HttpServletRequest request = RequestContextListener.getRequest();
if (request == null) {
throw new PetiteException("No HTTP request bound to the current thread. Is RequestContextListener registered?");
}
return request;
} | HttpServletRequest function() { HttpServletRequest request = RequestContextListener.getRequest(); if (request == null) { throw new PetiteException(STR); } return request; } | /**
* Returns request from current thread.
*/ | Returns request from current thread | getCurrentHttpRequest | {
"repo_name": "Artemish/jodd",
"path": "jodd-petite/src/main/java/jodd/petite/scope/RequestScope.java",
"license": "bsd-3-clause",
"size": 3031
} | [
"javax.servlet.http.HttpServletRequest"
] | import javax.servlet.http.HttpServletRequest; | import javax.servlet.http.*; | [
"javax.servlet"
] | javax.servlet; | 2,850,415 |
public void initializeRedisConnection(final String host) {
// jedis = new Jedis(host);
// LOW: Configure Jedis Pool options
// JedisPoolConfig poolConfig = new JedisPoolConfig();
// poolConfig.setMaxTotal(128);
// jedisPool = new JedisPool(poolConfig, RedisDBConfig.HOST, RedisDBConfig.PORT,
// RedisDBCo... | void function(final String host) { jedisPool = new JedisPool(new JedisPoolConfig(), host); jedis = jedisPool.getResource(); this.host = host; } | /**
* Initialize Redis connection.
*
* @param host
* the host
*/ | Initialize Redis connection | initializeRedisConnection | {
"repo_name": "OpenSimulationSystems/CABSF_Java",
"path": "CommonSimulationFramework/src/org/simulationsystems/csf/common/internal/messaging/interfaces/redis/RedisConnectionManager.java",
"license": "mit",
"size": 3906
} | [
"redis.clients.jedis.JedisPool",
"redis.clients.jedis.JedisPoolConfig"
] | import redis.clients.jedis.JedisPool; import redis.clients.jedis.JedisPoolConfig; | import redis.clients.jedis.*; | [
"redis.clients.jedis"
] | redis.clients.jedis; | 2,650,236 |
public void testNotSpecialCase() {
byte aBytes[] = {-1, -1, -1, -1};
int aSign = 1;
byte rBytes[] = {-1, 0, 0, 0, 0};
BigInteger aNumber = new BigInteger(aSign, aBytes);
BigInteger result = aNumber.not();
byte resBytes[] = new byte[rBytes.length];
resBy... | void function() { byte aBytes[] = {-1, -1, -1, -1}; int aSign = 1; byte rBytes[] = {-1, 0, 0, 0, 0}; BigInteger aNumber = new BigInteger(aSign, aBytes); BigInteger result = aNumber.not(); byte resBytes[] = new byte[rBytes.length]; resBytes = result.toByteArray(); for(int i = 0; i < resBytes.length; i++) { assertTrue(re... | /**
* Not for a negative number
*/ | Not for a negative number | testNotSpecialCase | {
"repo_name": "skyHALud/codenameone",
"path": "Ports/iOSPort/xmlvm/apache-harmony-6.0-src-r991881/classlib/modules/math/src/test/java/org/apache/harmony/tests/java/math/BigIntegerNotTest.java",
"license": "gpl-2.0",
"size": 7641
} | [
"java.math.BigInteger"
] | import java.math.BigInteger; | import java.math.*; | [
"java.math"
] | java.math; | 2,260,296 |
public void setExpressionSetID( Long expressionSetID ) {
this.expressionSetID = expressionSetID;
if ( !isEmpty() ) {
LoadableBioSample bioSample = null;
for ( Iterator iter = iterator(); iter.hasNext(); ) {
bioSample = (LoadableBioSample) iter.next();
bioSample.set_expression_set_id( expressionSetI... | void function( Long expressionSetID ) { this.expressionSetID = expressionSetID; if ( !isEmpty() ) { LoadableBioSample bioSample = null; for ( Iterator iter = iterator(); iter.hasNext(); ) { bioSample = (LoadableBioSample) iter.next(); bioSample.set_expression_set_id( expressionSetID ); } } } | /**
* Sets expression set id for all bio samples in collection. This is
* used when creating new bio samples for a new expression set.
*
* @param expressionSetID Expression set id to set for all bio samples
* in collection
*/ | Sets expression set id for all bio samples in collection. This is used when creating new bio samples for a new expression set | setExpressionSetID | {
"repo_name": "tair/tairwebapp",
"path": "src/org/tair/processor/microarray/data/LoadableBioSampleCollection.java",
"license": "gpl-3.0",
"size": 8611
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 946,701 |
public void fromPNML(OMElement subRoot, IdRefLinker idr)
throws InnerBuildException, InvalidIDException, VoidRepositoryException {
item.fromPNML(subRoot, idr);
} | void function(OMElement subRoot, IdRefLinker idr) throws InnerBuildException, InvalidIDException, VoidRepositoryException { item.fromPNML(subRoot, idr); } | /**
* creates an object from the xml nodes.(symetric work of toPNML)
*/ | creates an object from the xml nodes.(symetric work of toPNML) | fromPNML | {
"repo_name": "lhillah/pnmlframework",
"path": "pnmlFw-PT-HLPNG/src/fr/lip6/move/pnml/pthlpng/integers/hlapi/GreaterThanHLAPI.java",
"license": "epl-1.0",
"size": 69869
} | [
"fr.lip6.move.pnml.framework.utils.IdRefLinker",
"fr.lip6.move.pnml.framework.utils.exception.InnerBuildException",
"fr.lip6.move.pnml.framework.utils.exception.InvalidIDException",
"fr.lip6.move.pnml.framework.utils.exception.VoidRepositoryException",
"org.apache.axiom.om.OMElement"
] | import fr.lip6.move.pnml.framework.utils.IdRefLinker; import fr.lip6.move.pnml.framework.utils.exception.InnerBuildException; import fr.lip6.move.pnml.framework.utils.exception.InvalidIDException; import fr.lip6.move.pnml.framework.utils.exception.VoidRepositoryException; import org.apache.axiom.om.OMElement; | import fr.lip6.move.pnml.framework.utils.*; import fr.lip6.move.pnml.framework.utils.exception.*; import org.apache.axiom.om.*; | [
"fr.lip6.move",
"org.apache.axiom"
] | fr.lip6.move; org.apache.axiom; | 2,833,737 |
@GET
@Path("/storage{group: (/[^/]+?)*}-plugins.json")
@Produces(MediaType.APPLICATION_JSON)
public List<PluginConfigWrapper> getConfigsFor(@PathParam("group") String pluginGroup) {
PluginFilter filter;
switch (pluginGroup.trim()) {
case ALL_PLUGINS:
filter = PluginFilter.ALL;
break;
... | @Path(STR) @Produces(MediaType.APPLICATION_JSON) List<PluginConfigWrapper> function(@PathParam("group") String pluginGroup) { PluginFilter filter; switch (pluginGroup.trim()) { case ALL_PLUGINS: filter = PluginFilter.ALL; break; case ENABLED_PLUGINS: filter = PluginFilter.ENABLED; break; case DISABLED_PLUGINS: filter =... | /**
* Regex allows the following paths:<pre><code>
* /storage.json
* /storage/{group}-plugins.json</code></pre>
* Allowable groups:
* <ul>
* <li>"all" {@link #ALL_PLUGINS}</li>
* <li>"enabled" {@link #ENABLED_PLUGINS}</li>
* <li>"disabled" {@link #DISABLED_PLUGINS}</li>
* </ul>
* Any other... | Regex allows the following paths:<code><code> storage.json storage/{group}-plugins.json</code></code> Allowable groups: "all" <code>#ALL_PLUGINS</code> "enabled" <code>#ENABLED_PLUGINS</code> "disabled" <code>#DISABLED_PLUGINS</code> Any other group value results in an empty list. Note: for the second case the group in... | getConfigsFor | {
"repo_name": "johnnywale/drill",
"path": "exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java",
"license": "apache-2.0",
"size": 13657
} | [
"java.util.Collections",
"java.util.List",
"java.util.Spliterator",
"java.util.Spliterators",
"java.util.stream.Collectors",
"java.util.stream.StreamSupport",
"javax.ws.rs.Path",
"javax.ws.rs.PathParam",
"javax.ws.rs.Produces",
"javax.ws.rs.core.MediaType",
"org.apache.commons.lang3.StringUtils"... | import java.util.Collections; import java.util.List; import java.util.Spliterator; import java.util.Spliterators; import java.util.stream.Collectors; import java.util.stream.StreamSupport; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.core.MediaType; import org.a... | import java.util.*; import java.util.stream.*; import javax.ws.rs.*; import javax.ws.rs.core.*; import org.apache.commons.lang3.*; import org.apache.drill.exec.store.*; | [
"java.util",
"javax.ws",
"org.apache.commons",
"org.apache.drill"
] | java.util; javax.ws; org.apache.commons; org.apache.drill; | 557,272 |
@Override
public void nodeCrashed(GfManagerAgent source, GemFireVM crashed) {
try {
// SystemMember application has left...
SystemMember member = findSystemMember(crashed, false);
super.nodeCrashed(source, crashed);
if (logger.isDebugEnabled()) {
logger.debug("Processing node cra... | void function(GfManagerAgent source, GemFireVM crashed) { try { SystemMember member = findSystemMember(crashed, false); super.nodeCrashed(source, crashed); if (logger.isDebugEnabled()) { logger.debug(STR, member); } try { this.modelMBean.sendNotification(new Notification( NOTIF_MEMBER_CRASHED, ((ManagedResource)member)... | /**
* Listener callback for when a member of this DistributedSystem has crashed.
* <p>
* Also fires a Notification with the internal Id of the member VM.
*
* @param source the distributed system that fired nodeCrashed
* @param crashed the VM that crashed
* @see com.gemstone.gemfire.internal.admin... | Listener callback for when a member of this DistributedSystem has crashed. Also fires a Notification with the internal Id of the member VM | nodeCrashed | {
"repo_name": "ysung-pivotal/incubator-geode",
"path": "gemfire-core/src/main/java/com/gemstone/gemfire/admin/jmx/internal/AdminDistributedSystemJmxImpl.java",
"license": "apache-2.0",
"size": 85240
} | [
"com.gemstone.gemfire.SystemFailure",
"com.gemstone.gemfire.admin.SystemMember",
"com.gemstone.gemfire.admin.SystemMemberType",
"com.gemstone.gemfire.internal.admin.GemFireVM",
"com.gemstone.gemfire.internal.admin.GfManagerAgent",
"com.gemstone.gemfire.internal.i18n.LocalizedStrings",
"javax.management.... | import com.gemstone.gemfire.SystemFailure; import com.gemstone.gemfire.admin.SystemMember; import com.gemstone.gemfire.admin.SystemMemberType; import com.gemstone.gemfire.internal.admin.GemFireVM; import com.gemstone.gemfire.internal.admin.GfManagerAgent; import com.gemstone.gemfire.internal.i18n.LocalizedStrings; impo... | import com.gemstone.gemfire.*; import com.gemstone.gemfire.admin.*; import com.gemstone.gemfire.internal.admin.*; import com.gemstone.gemfire.internal.i18n.*; import javax.management.*; | [
"com.gemstone.gemfire",
"javax.management"
] | com.gemstone.gemfire; javax.management; | 2,551,808 |
public ChannelFuture close() {
return close(ctx.newPromise());
}
/**
* See {@link #close()} | ChannelFuture function() { return close(ctx.newPromise()); } /** * See {@link #close()} | /**
* Sends an SSL {@code close_notify} message to the specified channel and
* destroys the underlying {@link SSLEngine}.
*/ | Sends an SSL close_notify message to the specified channel and destroys the underlying <code>SSLEngine</code> | close | {
"repo_name": "DavidAlphaFox/netty",
"path": "handler/src/main/java/io/netty/handler/ssl/SslHandler.java",
"license": "apache-2.0",
"size": 49386
} | [
"io.netty.channel.ChannelFuture"
] | import io.netty.channel.ChannelFuture; | import io.netty.channel.*; | [
"io.netty.channel"
] | io.netty.channel; | 483,512 |
public boolean hasNotes() {
return diagsCollector.diagsByKind.containsKey(Diagnostic.Kind.NOTE);
} | boolean function() { return diagsCollector.diagsByKind.containsKey(Diagnostic.Kind.NOTE); } | /**
* Did this task generate any note diagnostics?
*/ | Did this task generate any note diagnostics | hasNotes | {
"repo_name": "google/error-prone-javac",
"path": "test/tools/javac/lib/combo/ComboTask.java",
"license": "gpl-2.0",
"size": 16900
} | [
"javax.tools.Diagnostic"
] | import javax.tools.Diagnostic; | import javax.tools.*; | [
"javax.tools"
] | javax.tools; | 2,459,199 |
public static SystemTimeIdGenerator getInstance()
{
return instance;
}
private final AtomicInteger atomicId;
private SystemTimeIdGenerator()
{
atomicId = new AtomicInteger((int)System.currentTimeMillis());
}
/**
* {@inheritDoc}
| static SystemTimeIdGenerator function() { return instance; } private final AtomicInteger atomicId; private SystemTimeIdGenerator() { atomicId = new AtomicInteger((int)System.currentTimeMillis()); } /** * {@inheritDoc} | /**
* Gets the single instance of SystemTimeIdGenerator.
*
* @return single instance of SystemTimeIdGenerator
*/ | Gets the single instance of SystemTimeIdGenerator | getInstance | {
"repo_name": "lightblueseas/jcommons-lang",
"path": "src/main/java/de/alpharogroup/id/generator/SystemTimeIdGenerator.java",
"license": "mit",
"size": 2173
} | [
"java.util.concurrent.atomic.AtomicInteger"
] | import java.util.concurrent.atomic.AtomicInteger; | import java.util.concurrent.atomic.*; | [
"java.util"
] | java.util; | 1,261,441 |
public File getDataDir() {
return this.dataDir;
} | File function() { return this.dataDir; } | /**
* get the datadir used by this filetxn
* snap log
* @return the data dir
*/ | get the datadir used by this filetxn snap log | getDataDir | {
"repo_name": "breed/zookeeper",
"path": "src/java/main/org/apache/zookeeper/server/persistence/FileTxnSnapLog.java",
"license": "apache-2.0",
"size": 13248
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 765,044 |
void fillFilm(IFilmFormBean fb); | void fillFilm(IFilmFormBean fb); | /**
* Fill the form bean.
*
* @param fb The form bean to fill.
*/ | Fill the form bean | fillFilm | {
"repo_name": "wichtounet/jtheque-films-module",
"path": "src/main/java/org/jtheque/films/view/able/IInfosPersoView.java",
"license": "apache-2.0",
"size": 1632
} | [
"org.jtheque.films.view.impl.fb.IFilmFormBean"
] | import org.jtheque.films.view.impl.fb.IFilmFormBean; | import org.jtheque.films.view.impl.fb.*; | [
"org.jtheque.films"
] | org.jtheque.films; | 198,154 |
void delete(String resourceGroupName, String profileName, Context context); | void delete(String resourceGroupName, String profileName, Context context); | /**
* Deletes an NetworkExperiment Profile by ProfileName.
*
* @param resourceGroupName Name of the Resource group within the Azure subscription.
* @param profileName The Profile identifier associated with the Tenant and Partner.
* @param context The context to associate with this operation.
... | Deletes an NetworkExperiment Profile by ProfileName | delete | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/frontdoor/azure-resourcemanager-frontdoor/src/main/java/com/azure/resourcemanager/frontdoor/models/NetworkExperimentProfiles.java",
"license": "mit",
"size": 8109
} | [
"com.azure.core.util.Context"
] | import com.azure.core.util.Context; | import com.azure.core.util.*; | [
"com.azure.core"
] | com.azure.core; | 935,160 |
@Test
public void testSystemCacheTx() throws Exception {
final Ignite ignite = grid(0);
final IgniteInternalCache<Object, Object> utilCache = getSystemCache(ignite, CU.UTILITY_CACHE_NAME);
checkImplicitTxSuccess(utilCache);
checkStartTxSuccess(utilCache);
} | void function() throws Exception { final Ignite ignite = grid(0); final IgniteInternalCache<Object, Object> utilCache = getSystemCache(ignite, CU.UTILITY_CACHE_NAME); checkImplicitTxSuccess(utilCache); checkStartTxSuccess(utilCache); } | /**
* Success if system caches weren't timed out.
*
* @throws Exception If failed.
*/ | Success if system caches weren't timed out | testSystemCacheTx | {
"repo_name": "BiryukovVA/ignite",
"path": "modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxConfigCacheSelfTest.java",
"license": "apache-2.0",
"size": 9465
} | [
"org.apache.ignite.Ignite"
] | import org.apache.ignite.Ignite; | import org.apache.ignite.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 2,777,496 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.