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 MOB fetchInhabitant(String inhabitantID); public List<MOB> fetchInhabitants(String inhabitantID); public Enumeration<MOB> inhabitants(); public void addInhabitant(MOB mob); public void delInhabitant(MOB mob); public void delAllInhabitants(boolean destroy); public int numInhabitants(); public boolean isIn...
MOB fetchInhabitant(String inhabitantID); public List<MOB> fetchInhabitants(String inhabitantID); public Enumeration<MOB> inhabitants(); public void addInhabitant(MOB mob); public void delInhabitant(MOB mob); public void delAllInhabitants(boolean destroy); public int numInhabitants(); public boolean isInhabitant(MOB mo...
/** * Applies the given code to each mob in this room * @param applier code to execute against each object */
Applies the given code to each mob in this room
eachInhabitant
{ "repo_name": "ConsecroMUD/ConsecroMUD", "path": "com/suscipio_solutions/consecro_mud/Locales/interfaces/Room.java", "license": "apache-2.0", "size": 8100 }
[ "com.suscipio_solutions.consecro_mud.core.interfaces.EachApplicable", "java.util.Enumeration", "java.util.List" ]
import com.suscipio_solutions.consecro_mud.core.interfaces.EachApplicable; import java.util.Enumeration; import java.util.List;
import com.suscipio_solutions.consecro_mud.core.interfaces.*; import java.util.*;
[ "com.suscipio_solutions.consecro_mud", "java.util" ]
com.suscipio_solutions.consecro_mud; java.util;
709,288
public synchronized void run() { if (fullInit == true) {// run already ran, or the file didn't // exist return; } try { fullInit = true; finishInitialization(); // finish initialization of table // The list isn't be closed as it's...
synchronized void function() { if (fullInit == true) { return; } try { fullInit = true; finishInitialization(); } catch (FormatException f) { } close(); }
/** * Complete the initialization of the FeatureClassInfo. This function can be * called more than once. */
Complete the initialization of the FeatureClassInfo. This function can be called more than once
run
{ "repo_name": "d2fn/passage", "path": "src/main/java/com/bbn/openmap/layer/vpf/FeatureClassInfo.java", "license": "mit", "size": 16577 }
[ "com.bbn.openmap.io.FormatException" ]
import com.bbn.openmap.io.FormatException;
import com.bbn.openmap.io.*;
[ "com.bbn.openmap" ]
com.bbn.openmap;
2,140,309
void setIcon(@DrawableRes int resourceId);
void setIcon(@DrawableRes int resourceId);
/** * Sets the icon of the dialog. * * @param resourceId * The resource id of the icon, which should be set, as an {@link Integer} value. The * resource id must correspond to a valid drawable resource */
Sets the icon of the dialog
setIcon
{ "repo_name": "michael-rapp/AndroidMaterialDialog", "path": "library/src/main/java/de/mrapp/android/dialog/model/MaterialDialogDecorator.java", "license": "apache-2.0", "size": 29588 }
[ "androidx.annotation.DrawableRes" ]
import androidx.annotation.DrawableRes;
import androidx.annotation.*;
[ "androidx.annotation" ]
androidx.annotation;
2,788,958
public long contentLength() throws IOException { return -1; }
long function() throws IOException { return -1; }
/** * Returns the number of bytes that will be written to {@code out} in a call * to {@link #writeTo}, or -1 if that count is unknown. */
Returns the number of bytes that will be written to out in a call to <code>#writeTo</code>, or -1 if that count is unknown
contentLength
{ "repo_name": "iooly/okhttp", "path": "okhttp/src/main/java/com/squareup/okhttp/RequestBody.java", "license": "apache-2.0", "size": 3503 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
810,998
public String jsGet_statusText() throws ScriptException { return this.statusLine.getReasonPhrase(); }
String function() throws ScriptException { return this.statusLine.getReasonPhrase(); }
/** * This corresponds to the readyonly statusText property of XHR. * * @return * @throws ScriptException */
This corresponds to the readyonly statusText property of XHR
jsGet_statusText
{ "repo_name": "wso2/jaggery", "path": "components/hostobjects/org.jaggeryjs.hostobjects.xhr/src/main/java/org/jaggeryjs/hostobjects/xhr/XMLHttpRequestHostObject.java", "license": "apache-2.0", "size": 30017 }
[ "org.jaggeryjs.scriptengine.exceptions.ScriptException" ]
import org.jaggeryjs.scriptengine.exceptions.ScriptException;
import org.jaggeryjs.scriptengine.exceptions.*;
[ "org.jaggeryjs.scriptengine" ]
org.jaggeryjs.scriptengine;
1,106,313
@Generated @Selector("initWithNode:bus:") public native AVAudioConnectionPoint initWithNodeBus(AVAudioNode node, @NUInt long bus);
@Selector(STR) native AVAudioConnectionPoint function(AVAudioNode node, @NUInt long bus);
/** * initWithNode:bus: * <p> * Create a connection point object. * <p> * If the node is nil, this method fails (returns nil). * * @param node the source or destination node * @param bus the output or input bus on the node */
initWithNode:bus: Create a connection point object. If the node is nil, this method fails (returns nil)
initWithNodeBus
{ "repo_name": "multi-os-engine/moe-core", "path": "moe.apple/moe.platform.ios/src/main/java/apple/avfaudio/AVAudioConnectionPoint.java", "license": "apache-2.0", "size": 5342 }
[ "org.moe.natj.general.ann.NUInt", "org.moe.natj.objc.ann.Selector" ]
import org.moe.natj.general.ann.NUInt; import org.moe.natj.objc.ann.Selector;
import org.moe.natj.general.ann.*; import org.moe.natj.objc.ann.*;
[ "org.moe.natj" ]
org.moe.natj;
228,909
public static SafeImplicitOutputsFunction fromTemplates(String... templates) { return fromTemplates(Arrays.asList(templates)); } /** * The implicit output function that generates files based on a set of * template substitutions using rule attribute values. * * @param templates The templates used ...
static SafeImplicitOutputsFunction function(String... templates) { return fromTemplates(Arrays.asList(templates)); } /** * The implicit output function that generates files based on a set of * template substitutions using rule attribute values. * * @param templates The templates used to construct the name of the implic...
/** * A convenience wrapper for {@link #fromTemplates(Iterable)}. */
A convenience wrapper for <code>#fromTemplates(Iterable)</code>
fromTemplates
{ "repo_name": "damienmg/bazel", "path": "src/main/java/com/google/devtools/build/lib/packages/ImplicitOutputsFunction.java", "license": "apache-2.0", "size": 17049 }
[ "java.util.Arrays" ]
import java.util.Arrays;
import java.util.*;
[ "java.util" ]
java.util;
763,022
public Adapter createToolInfoAdapter() { return null; }
Adapter function() { return null; }
/** * Creates a new adapter for an object of class '{@link fr.lip6.move.pnml.pnmlcoremodel.ToolInfo <em>Tool Info</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.pnmlcoremodel.ToolInfo Tool Info</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.
createToolInfoAdapter
{ "repo_name": "lhillah/pnmlframework", "path": "pnmlFw-CoreModel/src/fr/lip6/move/pnml/pnmlcoremodel/util/PnmlcoremodelAdapterFactory.java", "license": "epl-1.0", "size": 22786 }
[ "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;
2,275,216
public Properties getCurrentProperties() throws Exception { try { setUpSocket(); writeCommandHeader(COMMAND_PROPERTIES); send(); byte[] val = readBytesReply("DRDA_PropertyError.S"); Properties p = new Properties(); try {...
Properties function() throws Exception { try { setUpSocket(); writeCommandHeader(COMMAND_PROPERTIES); send(); byte[] val = readBytesReply(STR); Properties p = new Properties(); try { ByteArrayInputStream bs = new ByteArrayInputStream(val); p.load(bs); } catch (IOException io) { consolePropertyMessage(STR, io.getMessage...
/** * Get current properties * * @return Properties object containing properties * @exception Exception throws an exception if an error occurs */
Get current properties
getCurrentProperties
{ "repo_name": "gemxd/gemfirexd-oss", "path": "gemfirexd/core/src/drda/java/com/pivotal/gemfirexd/internal/impl/drda/NetworkServerControlImpl.java", "license": "apache-2.0", "size": 138102 }
[ "java.io.ByteArrayInputStream", "java.io.IOException", "java.util.Properties" ]
import java.io.ByteArrayInputStream; import java.io.IOException; import java.util.Properties;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
784,826
public Map<TypeWID,Double> getWorkerReliabilityMap() { assert hasWorkerReliabilityMap():"Worker Reliability Map not initiliazed"; return workerReliabilityMap;}
Map<TypeWID,Double> function() { assert hasWorkerReliabilityMap():STR; return workerReliabilityMap;}
/** * Get worker reliability * @return worker reliability as a Map from workers to doubles */
Get worker reliability
getWorkerReliabilityMap
{ "repo_name": "utir/square-2.0", "path": "SQUARE/src/main/java/org/square/qa/utilities/constructs/Models.java", "license": "mit", "size": 24464 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,549,856
protected void cleanup( TestParameters tParam, PrintWriter log ) { log.println( " disposing xDrawDoc " ); util.DesktopTools.closeDoc(xDrawDoc); }
void function( TestParameters tParam, PrintWriter log ) { log.println( STR ); util.DesktopTools.closeDoc(xDrawDoc); }
/** * in general this method disposes the testenvironment and document * * @param tParam class which contains additional test parameters * @param log class to log the test state and result * * * @see TestParameters * @see PrintWriter * */
in general this method disposes the testenvironment and document
cleanup
{ "repo_name": "qt-haiku/LibreOffice", "path": "qadevOOo/tests/java/mod/_svx/SvxShapeCollection.java", "license": "gpl-3.0", "size": 4614 }
[ "java.io.PrintWriter" ]
import java.io.PrintWriter;
import java.io.*;
[ "java.io" ]
java.io;
1,447,110
public void setLoginTimeout(int seconds) throws SQLException { }
void function(int seconds) throws SQLException { }
/** * DOCUMENT ME! * * @param seconds * DOCUMENT ME! * * @throws SQLException * DOCUMENT ME! */
DOCUMENT ME
setLoginTimeout
{ "repo_name": "suthat/signal", "path": "vendor/mysql-connector-java-5.1.26/src/com/mysql/jdbc/jdbc2/optional/MysqlDataSource.java", "license": "apache-2.0", "size": 10364 }
[ "java.sql.SQLException" ]
import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
880,485
StringBuffer buf = new StringBuffer(); buf.append("("); if (flags.contains(Flags.Flag.ANSWERED)) { buf.append("\\Answered "); } if (flags.contains(Flags.Flag.DELETED)) { buf.append("\\Deleted "); } if (flags.contains(Flags.Flag.DRAFT)) { ...
StringBuffer buf = new StringBuffer(); buf.append("("); if (flags.contains(Flags.Flag.ANSWERED)) { buf.append(STR); } if (flags.contains(Flags.Flag.DELETED)) { buf.append(STR); } if (flags.contains(Flags.Flag.DRAFT)) { buf.append(STR); } if (flags.contains(Flags.Flag.FLAGGED)) { buf.append(STR); } if (flags.contains(Fl...
/** * Returns IMAP formatted String of MessageFlags for named user */
Returns IMAP formatted String of MessageFlags for named user
format
{ "repo_name": "nguyentienlong/community-edition", "path": "projects/3rd-party/greenmail/source/java/com/icegreen/greenmail/store/MessageFlags.java", "license": "lgpl-3.0", "size": 2460 }
[ "javax.mail.Flags" ]
import javax.mail.Flags;
import javax.mail.*;
[ "javax.mail" ]
javax.mail;
1,535,378
public void addNewEQPreset(String presetName, int fiftyHertz, int oneThirtyHertz, int threeTwentyHertz, int eightHundredHertz, int twoKilohertz, int fiveKilohertz, int twelvePointFiveKilohertz, short virtualizer,...
void function(String presetName, int fiftyHertz, int oneThirtyHertz, int threeTwentyHertz, int eightHundredHertz, int twoKilohertz, int fiveKilohertz, int twelvePointFiveKilohertz, short virtualizer, short bassBoost, short reverb) { ContentValues values = new ContentValues(); values.put(PRESET_NAME, presetName); values...
/** * Adds a new EQ preset to the table. */
Adds a new EQ preset to the table
addNewEQPreset
{ "repo_name": "yongjiliu/MusicPlayer", "path": "ACEMusicPlayer/src/main/java/com/aniruddhc/acemusic/player/DBHelpers/DBAccessHelper.java", "license": "gpl-2.0", "size": 72380 }
[ "android.content.ContentValues" ]
import android.content.ContentValues;
import android.content.*;
[ "android.content" ]
android.content;
1,180,956
DatanodeCommand[] handleHeartbeat(DatanodeRegistration nodeReg, long capacity, long dfsUsed, long remaining, int xceiverCount, int xmitsInProgress) throws IOException { DatanodeCommand cmd = null; synchronized (heartbeats) { synchronized (datanodeMap) { DatanodeDescriptor nodeinfo = ...
DatanodeCommand[] handleHeartbeat(DatanodeRegistration nodeReg, long capacity, long dfsUsed, long remaining, int xceiverCount, int xmitsInProgress) throws IOException { DatanodeCommand cmd = null; synchronized (heartbeats) { synchronized (datanodeMap) { DatanodeDescriptor nodeinfo = null; try { nodeinfo = getDatanode(n...
/** * The given node has reported in. This method should: * 1) Record the heartbeat, so the datanode isn't timed out * 2) Adjust usage stats for future block allocation * * If a substantial amount of time passed since the last datanode * heartbeat then request an immediate block report. * ...
The given node has reported in. This method should: 1) Record the heartbeat, so the datanode isn't timed out 2) Adjust usage stats for future block allocation If a substantial amount of time passed since the last datanode heartbeat then request an immediate block report
handleHeartbeat
{ "repo_name": "andy8788/hadoop-hdfs", "path": "src/hdfs/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java", "license": "apache-2.0", "size": 214042 }
[ "java.io.IOException", "java.util.ArrayList", "org.apache.hadoop.hdfs.protocol.UnregisteredDatanodeException", "org.apache.hadoop.hdfs.server.protocol.BalancerBandwidthCommand", "org.apache.hadoop.hdfs.server.protocol.DatanodeCommand", "org.apache.hadoop.hdfs.server.protocol.DatanodeRegistration", "org....
import java.io.IOException; import java.util.ArrayList; import org.apache.hadoop.hdfs.protocol.UnregisteredDatanodeException; import org.apache.hadoop.hdfs.server.protocol.BalancerBandwidthCommand; import org.apache.hadoop.hdfs.server.protocol.DatanodeCommand; import org.apache.hadoop.hdfs.server.protocol.DatanodeRegis...
import java.io.*; import java.util.*; import org.apache.hadoop.hdfs.protocol.*; import org.apache.hadoop.hdfs.server.protocol.*;
[ "java.io", "java.util", "org.apache.hadoop" ]
java.io; java.util; org.apache.hadoop;
1,530,282
public final OperationsClient getOperationsClient() { return operationsClient; } // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Lists Certificates in a given project and location. * * <p>Sample code: * * <pre>{@code * try (CertificateManagerClient certificateManagerClient = Certificate...
final OperationsClient function() { return operationsClient; } /** * Lists Certificates in a given project and location. * * <p>Sample code: * * <pre>{ * try (CertificateManagerClient certificateManagerClient = CertificateManagerClient.create()) { * LocationName parent = LocationName.of(STR, STR); * for (Certificate el...
/** * Returns the OperationsClient that can be used to query the status of a long-running operation * returned by another API method call. */
Returns the OperationsClient that can be used to query the status of a long-running operation returned by another API method call
getOperationsClient
{ "repo_name": "googleapis/java-certificate-manager", "path": "google-cloud-certificate-manager/src/main/java/com/google/cloud/certificatemanager/v1/CertificateManagerClient.java", "license": "apache-2.0", "size": 122857 }
[ "com.google.longrunning.OperationsClient" ]
import com.google.longrunning.OperationsClient;
import com.google.longrunning.*;
[ "com.google.longrunning" ]
com.google.longrunning;
221,386
@BeforeClass protected void createFilter() throws IOException { injector = ContextBuilder .newBuilder("azureblob") .endpoint("https://${jclouds.identity}.blob.core.windows.net") .credentials(ACCOUNT, "credential") .modules(ImmutableSet.<Module> of(new MockModu...
void function() throws IOException { injector = ContextBuilder .newBuilder(STR) .endpoint(STRcredential") .modules(ImmutableSet.<Module> of(new MockModule(), new NullLoggingModule())) .buildInjector(); filter = injector.getInstance(SharedKeyLiteAuthentication.class); }
/** * before class, as we need to ensure that the filter is threadsafe. * * @throws IOException * */
before class, as we need to ensure that the filter is threadsafe
createFilter
{ "repo_name": "yanzhijun/jclouds-aliyun", "path": "providers/azureblob/src/test/java/org/jclouds/azure/storage/filters/SharedKeyLiteAuthenticationTest.java", "license": "apache-2.0", "size": 5613 }
[ "com.google.common.collect.ImmutableSet", "com.google.inject.Module", "java.io.IOException", "org.jclouds.ContextBuilder", "org.jclouds.logging.config.NullLoggingModule", "org.jclouds.rest.internal.BaseRestApiTest" ]
import com.google.common.collect.ImmutableSet; import com.google.inject.Module; import java.io.IOException; import org.jclouds.ContextBuilder; import org.jclouds.logging.config.NullLoggingModule; import org.jclouds.rest.internal.BaseRestApiTest;
import com.google.common.collect.*; import com.google.inject.*; import java.io.*; import org.jclouds.*; import org.jclouds.logging.config.*; import org.jclouds.rest.internal.*;
[ "com.google.common", "com.google.inject", "java.io", "org.jclouds", "org.jclouds.logging", "org.jclouds.rest" ]
com.google.common; com.google.inject; java.io; org.jclouds; org.jclouds.logging; org.jclouds.rest;
687,833
public void test_doAs_02() { Subject subj = new Subject(); PrivilegedExceptionAction<Object> pea = new myPrivilegedExceptionAction(); PrivilegedExceptionAction<Object> peaNull = null; try { Object obj = Subject.doAs(null, pea); } catch (Exception e) { ...
void function() { Subject subj = new Subject(); PrivilegedExceptionAction<Object> pea = new myPrivilegedExceptionAction(); PrivilegedExceptionAction<Object> peaNull = null; try { Object obj = Subject.doAs(null, pea); } catch (Exception e) { fail(STR + e); } try { Object obj = Subject.doAs(subj, pea); } catch (Exception...
/** * javax.security.auth.Subject#doAs(Subject subject, PrivilegedExceptionAction action) */
javax.security.auth.Subject#doAs(Subject subject, PrivilegedExceptionAction action)
test_doAs_02
{ "repo_name": "mirego/j2objc", "path": "jre_emul/android/platform/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/security/auth/SubjectTest.java", "license": "apache-2.0", "size": 10808 }
[ "java.security.PrivilegedExceptionAction", "javax.security.auth.Subject" ]
import java.security.PrivilegedExceptionAction; import javax.security.auth.Subject;
import java.security.*; import javax.security.auth.*;
[ "java.security", "javax.security" ]
java.security; javax.security;
2,841,533
List<BusinessEventEntity> findBySupplierIdAndPendingIsTrueAndPaymentResponsibleAndStartTimeBetween(String supplierId, String paymentResponsible, Date startTime, Date endTime, Pageable pageable);
List<BusinessEventEntity> findBySupplierIdAndPendingIsTrueAndPaymentResponsibleAndStartTimeBetween(String supplierId, String paymentResponsible, Date startTime, Date endTime, Pageable pageable);
/** * Returns entities for a supplier and payment responsible, and where start time is within a period of time. * * @param supplierId the supplier id. * @param paymentResponsible the payment responsible. * @param startTime the period start time. * @param endTime the period end time. ...
Returns entities for a supplier and payment responsible, and where start time is within a period of time
findBySupplierIdAndPendingIsTrueAndPaymentResponsibleAndStartTimeBetween
{ "repo_name": "KentorJava/sll-invoice-data-tmp", "path": "invoice-data/invoice-data-core/src/main/java/se/sll/invoicedata/core/model/repository/BusinessEventRepository.java", "license": "lgpl-3.0", "size": 4667 }
[ "java.util.Date", "java.util.List", "org.springframework.data.domain.Pageable", "se.sll.invoicedata.core.model.entity.BusinessEventEntity" ]
import java.util.Date; import java.util.List; import org.springframework.data.domain.Pageable; import se.sll.invoicedata.core.model.entity.BusinessEventEntity;
import java.util.*; import org.springframework.data.domain.*; import se.sll.invoicedata.core.model.entity.*;
[ "java.util", "org.springframework.data", "se.sll.invoicedata" ]
java.util; org.springframework.data; se.sll.invoicedata;
1,186,984
public final Point getCentroid() { return this.centroid; }
final Point function() { return this.centroid; }
/** * Return the center of the polygon. * @return centroid The center of the polygon. */
Return the center of the polygon
getCentroid
{ "repo_name": "Nantes1900/Nantes-1900-PGROU-IHM", "path": "src/fr/nantes1900/view/display3d/PolygonView.java", "license": "gpl-3.0", "size": 4892 }
[ "fr.nantes1900.models.basis.Point" ]
import fr.nantes1900.models.basis.Point;
import fr.nantes1900.models.basis.*;
[ "fr.nantes1900.models" ]
fr.nantes1900.models;
115,535
public ColourNames getBorderLeftColor$() { return borderLeftColor$; }
public ColourNames getBorderLeftColor$() { return borderLeftColor$; }
/** * Gets the colour of the left border * * @return */
Gets the colour of the left border
getBorderLeftColor$
{ "repo_name": "GedMarc/JWebSwing", "path": "src/main/java/com/jwebmp/core/htmlbuilder/css/borders/BorderLeftCSSImpl.java", "license": "gpl-3.0", "size": 3852 }
[ "com.jwebmp.core.htmlbuilder.css.colours.ColourNames" ]
import com.jwebmp.core.htmlbuilder.css.colours.ColourNames;
import com.jwebmp.core.htmlbuilder.css.colours.*;
[ "com.jwebmp.core" ]
com.jwebmp.core;
2,547,964
protected void setPageRange(int firstPage, int lastPage) { if(firstPage >= 0 && lastPage >= 0) { mFirstPage = firstPage; mLastPage = lastPage; if(mLastPage < mFirstPage) mLastPage = mFirstPage; } else { mFirstPage = Pageable.UNKNOWN_NUMBER_OF_PAGES; ...
void function(int firstPage, int lastPage) { if(firstPage >= 0 && lastPage >= 0) { mFirstPage = firstPage; mLastPage = lastPage; if(mLastPage < mFirstPage) mLastPage = mFirstPage; } else { mFirstPage = Pageable.UNKNOWN_NUMBER_OF_PAGES; mLastPage = Pageable.UNKNOWN_NUMBER_OF_PAGES; } }
/** * Set the range of pages from a Book to be printed. * Both 'firstPage' and 'lastPage' are zero based * page indices. If either parameter is less than * zero then the page range is set to be from the * first page to the last. */
Set the range of pages from a Book to be printed. Both 'firstPage' and 'lastPage' are zero based page indices. If either parameter is less than zero then the page range is set to be from the first page to the last
setPageRange
{ "repo_name": "md-5/jdk10", "path": "src/java.desktop/share/classes/sun/print/RasterPrinterJob.java", "license": "gpl-2.0", "size": 98245 }
[ "java.awt.print.Pageable" ]
import java.awt.print.Pageable;
import java.awt.print.*;
[ "java.awt" ]
java.awt;
2,041,525
@Override protected void visitSoyNode(SoyNode node) { if (node instanceof ExprHolderNode) { for (ExprUnion exprUnion : ((ExprHolderNode) node).getAllExprUnions()) { if (exprUnion.getExpr() == null) { continue; } new CheckFunctionCallsExprVisitor().exec(exprUnion.getExpr()...
@Override void function(SoyNode node) { if (node instanceof ExprHolderNode) { for (ExprUnion exprUnion : ((ExprHolderNode) node).getAllExprUnions()) { if (exprUnion.getExpr() == null) { continue; } new CheckFunctionCallsExprVisitor().exec(exprUnion.getExpr()); } } if (node instanceof ParentSoyNode<?>) { visitChildren((...
/** * Recursively identifies all Soy nodes that contain expressions, and recurse to * each expression. */
Recursively identifies all Soy nodes that contain expressions, and recurse to each expression
visitSoyNode
{ "repo_name": "SerkanSipahi/closure-templates", "path": "java/src/com/google/template/soy/parsepasses/CheckFunctionCallsVisitor.java", "license": "apache-2.0", "size": 7661 }
[ "com.google.template.soy.exprtree.AbstractExprNodeVisitor", "com.google.template.soy.soytree.ExprUnion", "com.google.template.soy.soytree.SoyNode" ]
import com.google.template.soy.exprtree.AbstractExprNodeVisitor; import com.google.template.soy.soytree.ExprUnion; import com.google.template.soy.soytree.SoyNode;
import com.google.template.soy.exprtree.*; import com.google.template.soy.soytree.*;
[ "com.google.template" ]
com.google.template;
1,706,760
private ReplicaInfo getReplicaInfo(String bpid, long blkid) throws ReplicaNotFoundException { ReplicaInfo info = volumeMap.get(bpid, blkid); if (info == null) { throw new ReplicaNotFoundException( ReplicaNotFoundException.NON_EXISTENT_REPLICA + bpid + ":" + blkid); } return info;...
ReplicaInfo function(String bpid, long blkid) throws ReplicaNotFoundException { ReplicaInfo info = volumeMap.get(bpid, blkid); if (info == null) { throw new ReplicaNotFoundException( ReplicaNotFoundException.NON_EXISTENT_REPLICA + bpid + ":" + blkid); } return info; }
/** * Get the meta info of a block stored in volumeMap. Block is looked up * without matching the generation stamp. * @param bpid block pool Id * @param blkid block Id * @return the meta replica information; null if block was not found * @throws ReplicaNotFoundException if no entry is in the map or ...
Get the meta info of a block stored in volumeMap. Block is looked up without matching the generation stamp
getReplicaInfo
{ "repo_name": "xuchenCN/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java", "license": "apache-2.0", "size": 100444 }
[ "org.apache.hadoop.hdfs.server.datanode.ReplicaInfo", "org.apache.hadoop.hdfs.server.datanode.ReplicaNotFoundException" ]
import org.apache.hadoop.hdfs.server.datanode.ReplicaInfo; import org.apache.hadoop.hdfs.server.datanode.ReplicaNotFoundException;
import org.apache.hadoop.hdfs.server.datanode.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
1,790,099
public void clearPlayerData() { player.getInventory().clear(); player.getInventory().setArmorContents(null); player.setExp(0f); player.setLevel(0); double maxHealth; if (is1_9) { AttributeUtil.resetPlayerAttributes(player); maxHealth = pla...
void function() { player.getInventory().clear(); player.getInventory().setArmorContents(null); player.setExp(0f); player.setLevel(0); double maxHealth; if (is1_9) { AttributeUtil.resetPlayerAttributes(player); maxHealth = player.getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue(); } else { maxHealth = player.getMaxHe...
/** * Clear the player's inventory, potion effects etc. * <p> * Does NOT handle flight. */
Clear the player's inventory, potion effects etc. Does NOT handle flight
clearPlayerData
{ "repo_name": "DRE2N/DungeonsXL", "path": "core/src/main/java/de/erethon/dungeonsxl/player/DInstancePlayer.java", "license": "gpl-3.0", "size": 4329 }
[ "de.erethon.dungeonsxl.util.AttributeUtil", "org.bukkit.attribute.Attribute", "org.bukkit.potion.PotionEffect" ]
import de.erethon.dungeonsxl.util.AttributeUtil; import org.bukkit.attribute.Attribute; import org.bukkit.potion.PotionEffect;
import de.erethon.dungeonsxl.util.*; import org.bukkit.attribute.*; import org.bukkit.potion.*;
[ "de.erethon.dungeonsxl", "org.bukkit.attribute", "org.bukkit.potion" ]
de.erethon.dungeonsxl; org.bukkit.attribute; org.bukkit.potion;
1,162,476
public void setDefaultAction(Action a);
void function(Action a);
/** * Set the default action to fire if a key is typed. * * @param a the action */
Set the default action to fire if a key is typed
setDefaultAction
{ "repo_name": "TheTypoMaster/Scaper", "path": "openjdk/jdk/src/share/classes/javax/swing/text/Keymap.java", "license": "gpl-2.0", "size": 4289 }
[ "javax.swing.Action" ]
import javax.swing.Action;
import javax.swing.*;
[ "javax.swing" ]
javax.swing;
1,264,301
@CalledByNative private void requestRemotePlayback() { if (mDebug) Log.i(TAG, "requestRemotePlayback"); if (mRouteController == null) return; // Clear out the state mPauseRequested = false; mSeekRequested = false; RemoteMediaPlayerController.instance().requestRemo...
void function() { if (mDebug) Log.i(TAG, STR); if (mRouteController == null) return; mPauseRequested = false; mSeekRequested = false; RemoteMediaPlayerController.instance().requestRemotePlayback( mMediaStateListener, mRouteController); }
/** * Called when a lower layer requests that a video be cast. This will typically be a request * from Blink when the cast button is pressed on the default video controls. */
Called when a lower layer requests that a video be cast. This will typically be a request from Blink when the cast button is pressed on the default video controls
requestRemotePlayback
{ "repo_name": "Bysmyyr/chromium-crosswalk", "path": "chrome/android/java/src/org/chromium/chrome/browser/media/remote/RemoteMediaPlayerBridge.java", "license": "bsd-3-clause", "size": 13522 }
[ "android.util.Log" ]
import android.util.Log;
import android.util.*;
[ "android.util" ]
android.util;
1,893,373
@Override public void notifyChanged(Notification notification) { updateChildren(notification); super.notifyChanged(notification); }
void function(Notification notification) { updateChildren(notification); super.notifyChanged(notification); }
/** * This handles model notifications by calling {@link #updateChildren} to update any cached * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
This handles model notifications by calling <code>#updateChildren</code> to update any cached children and by creating a viewer notification, which it passes to <code>#fireNotifyChanged</code>.
notifyChanged
{ "repo_name": "BaSys-PC1/models", "path": "de.dfki.iui.basys.model.domain.edit/src/de/dfki/iui/basys/model/domain/resourcetype/provider/RobotItemProvider.java", "license": "epl-1.0", "size": 2628 }
[ "org.eclipse.emf.common.notify.Notification" ]
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,528,879
private static Map<String, OptionDetails> computeOptionsMap(BuildOptions buildOptions, Iterable<Fragment> fragments) { // Collect from our fragments "alternative defaults" for options where the default // should be something other than what's specified in Option.defaultValue. Map<String, Object> lat...
static Map<String, OptionDetails> function(BuildOptions buildOptions, Iterable<Fragment> fragments) { Map<String, Object> lateBoundDefaults = Maps.newHashMap(); for (Fragment fragment : fragments) { lateBoundDefaults.putAll(fragment.lateBoundOptionDefaults()); } ImmutableMap.Builder<String, OptionDetails> map = Immutab...
/** * Computes and returns the transitive optionName -> "option info" map for * this configuration. */
Computes and returns the transitive optionName -> "option info" map for this configuration
computeOptionsMap
{ "repo_name": "bitemyapp/bazel", "path": "src/main/java/com/google/devtools/build/lib/analysis/config/BuildConfiguration.java", "license": "apache-2.0", "size": 73993 }
[ "com.google.common.collect.ImmutableMap", "com.google.common.collect.Maps", "com.google.devtools.common.options.Option", "java.lang.reflect.Field", "java.util.Map" ]
import com.google.common.collect.ImmutableMap; import com.google.common.collect.Maps; import com.google.devtools.common.options.Option; import java.lang.reflect.Field; import java.util.Map;
import com.google.common.collect.*; import com.google.devtools.common.options.*; import java.lang.reflect.*; import java.util.*;
[ "com.google.common", "com.google.devtools", "java.lang", "java.util" ]
com.google.common; com.google.devtools; java.lang; java.util;
1,908,722
@Override public void loadConfig() { try { properties.setProperty("description", ""); properties.setProperty("title", ""); properties.setProperty("persistent", "false"); properties.setProperty("defaultmodel", "model.jam"); properties.setPropert...
void function() { try { properties.setProperty(STR, STRtitle", STRpersistentSTRfalseSTRdefaultmodelSTRmodel.jamSTRINPUT_DIR_NAMESTROUTPUT_DIR_NAMESTRTEMP_DIR_NAMESTRLOCAL_INDIR_NAMESTRDUMP_DIR_NAMESTREXPLORER_DIR_NAMESTRreadonlySTRreadonly")); } } catch (IOException ioe) { runtime.handle(ioe); } }
/** * Loads the workspace config from the config file in the root of the * workspace directory */
Loads the workspace config from the config file in the root of the workspace directory
loadConfig
{ "repo_name": "kralisch/jams", "path": "JAMSmain/src/jams/workspace/JAMSWorkspace.java", "license": "lgpl-3.0", "size": 34353 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,024,041
public void scale(double scaleFactor) { checkArgument(scaleFactor > 0, "scale factor must be > 0"); // Compress the scaled digest. compress(); // Scale all the counts. for (int i = 0; i < weight.length; i++) { weight[i] *= scaleFactor; } total...
void function(double scaleFactor) { checkArgument(scaleFactor > 0, STR); compress(); for (int i = 0; i < weight.length; i++) { weight[i] *= scaleFactor; } totalWeight *= scaleFactor; }
/** * Scale all the counts by the given scale factor. */
Scale all the counts by the given scale factor
scale
{ "repo_name": "zzhao0/presto", "path": "presto-main/src/main/java/com/facebook/presto/tdigest/TDigest.java", "license": "apache-2.0", "size": 26231 }
[ "com.google.common.base.Preconditions" ]
import com.google.common.base.Preconditions;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
1,414,900
public void lDelete(int itemNum, Item deleteditem) { // if the previous item has new line after, or the next item has // new line before, and it's not the last item, // than we could just mark the next item as actualBoundsInvalid[Y] if (itemNum < (numOfLFs-1)) { if (((it...
void function(int itemNum, Item deleteditem) { if (itemNum < (numOfLFs-1)) { if (((itemNum > 0) && (itemLFs[itemNum-1].equateNLA()) itemLFs[itemNum+1].equateNLB()) && itemLFs[itemNum+1].isNewLine) { if (Logging.REPORT_LEVEL <= Logging.INFORMATION) { Logging.report(Logging.INFORMATION, LogChannels.LC_HIGHUI_FORM_LAYOUT,...
/** * Notifies look&amp;feel object of an item deleted in the corresponding * <code>Form</code>. * * @param itemNum the index of the deleted item * @param deleteditem the item deleted in the corresponding form */
Notifies look&amp;feel object of an item deleted in the corresponding <code>Form</code>
lDelete
{ "repo_name": "tommythorn/yari", "path": "shared/cacao-related/phoneme_feature/midp/src/highlevelui/lcdlf/lfplatform/classes/javax/microedition/lcdui/FormLFImpl.java", "license": "gpl-2.0", "size": 84531 }
[ "com.sun.midp.log.LogChannels", "com.sun.midp.log.Logging" ]
import com.sun.midp.log.LogChannels; import com.sun.midp.log.Logging;
import com.sun.midp.log.*;
[ "com.sun.midp" ]
com.sun.midp;
612,970
public boolean execute(String action, JSONArray args, CallbackContext callbackContext) throws JSONException { currentContext = callbackContext; try { if (action.equals("switchToSettings")){ switchToAppSettings(); callbackContext.success(); } e...
boolean function(String action, JSONArray args, CallbackContext callbackContext) throws JSONException { currentContext = callbackContext; try { if (action.equals(STR)){ switchToAppSettings(); callbackContext.success(); } else if (action.equals(STR)){ switchToLocationSettings(); callbackContext.success(); } else if (act...
/** * Executes the request and returns PluginResult. * * @param action The action to execute. * @param args JSONArry of arguments for the plugin. * @param callbackContext The callback id used when calling back into JavaScript. * @return True if th...
Executes the request and returns PluginResult
execute
{ "repo_name": "OZhurbenko/ESIT-web", "path": "ios/plugins/cordova.plugins.diagnostic/src/android/Diagnostic.java", "license": "mit", "size": 36654 }
[ "org.apache.cordova.CallbackContext", "org.json.JSONArray", "org.json.JSONException" ]
import org.apache.cordova.CallbackContext; import org.json.JSONArray; import org.json.JSONException;
import org.apache.cordova.*; import org.json.*;
[ "org.apache.cordova", "org.json" ]
org.apache.cordova; org.json;
2,544,689
public LabelBuilder setShadowOffsetY(int shadowOffsetY) { IsBuilder.checkIfValid(getOptionsBuilder()); label.setShadowOffsetY(shadowOffsetY); return this; }
LabelBuilder function(int shadowOffsetY) { IsBuilder.checkIfValid(getOptionsBuilder()); label.setShadowOffsetY(shadowOffsetY); return this; }
/** * Sets the text shadow Y offset. * * @param shadowOffsetY the text shadow Y offset. * @return builder instance */
Sets the text shadow Y offset
setShadowOffsetY
{ "repo_name": "pepstock-org/Charba", "path": "src/org/pepstock/charba/client/labels/LabelBuilder.java", "license": "apache-2.0", "size": 9629 }
[ "org.pepstock.charba.client.commons.IsBuilder" ]
import org.pepstock.charba.client.commons.IsBuilder;
import org.pepstock.charba.client.commons.*;
[ "org.pepstock.charba" ]
org.pepstock.charba;
2,221,709
@Pure public XBlockExpression getXBlockExpression() { return this.builder.getXBlockExpression(); }
XBlockExpression function() { return this.builder.getXBlockExpression(); }
/** An empty block expression. * @return the block expression. */
An empty block expression
getXBlockExpression
{ "repo_name": "sarl/sarl", "path": "main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/appenders/BlockExpressionSourceAppender.java", "license": "apache-2.0", "size": 5235 }
[ "org.eclipse.xtext.xbase.XBlockExpression" ]
import org.eclipse.xtext.xbase.XBlockExpression;
import org.eclipse.xtext.xbase.*;
[ "org.eclipse.xtext" ]
org.eclipse.xtext;
1,198,356
public ClassInfoList getClassesWithMethodParameterAnnotation() { // Get all classes that have a method annotated or meta-annotated with this annotation final Set<ClassInfo> classesWithMethodParameterAnnotation = new HashSet<>( getClassesWithFieldOrMethodAnnotation(RelType.CLASSES_WIT...
ClassInfoList function() { final Set<ClassInfo> classesWithMethodParameterAnnotation = new HashSet<>( getClassesWithFieldOrMethodAnnotation(RelType.CLASSES_WITH_METHOD_PARAMETER_ANNOTATION)); for (final ClassInfo classWithNonprivateMethodParameterAnnotationOrMetaAnnotation : classesWithMethodParameterAnnotation .addAll...
/** * Get all classes that have this class as a method parameter annotation, and their subclasses, if the method is * non-private. * * @return A list of classes that have a declared method with a parameter that is annotated with this annotation * or meta-annotation, or the empty list if...
Get all classes that have this class as a method parameter annotation, and their subclasses, if the method is non-private
getClassesWithMethodParameterAnnotation
{ "repo_name": "classgraph/classgraph", "path": "src/main/java/io/github/classgraph/ClassInfo.java", "license": "mit", "size": 140633 }
[ "java.util.HashSet", "java.util.Set" ]
import java.util.HashSet; import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
1,885,132
public StorageDomainStaticDAO getStorageDomainStaticDao() { return getDao(StorageDomainStaticDAO.class); }
StorageDomainStaticDAO function() { return getDao(StorageDomainStaticDAO.class); }
/** * Returns the singleton instance of {@link StorageDomainDAO}. * * @return the dao */
Returns the singleton instance of <code>StorageDomainDAO</code>
getStorageDomainStaticDao
{ "repo_name": "halober/ovirt-engine", "path": "backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dal/dbbroker/DbFacade.java", "license": "apache-2.0", "size": 34736 }
[ "org.ovirt.engine.core.dao.StorageDomainStaticDAO" ]
import org.ovirt.engine.core.dao.StorageDomainStaticDAO;
import org.ovirt.engine.core.dao.*;
[ "org.ovirt.engine" ]
org.ovirt.engine;
2,509,162
public synchronized Timestamp getTimestamp( int parameterIndex) throws SQLException { TimestampData t = (TimestampData) getColumnInType(parameterIndex, Type.SQL_TIMESTAMP); if (t == null) { return null; } return (Timestamp) Type.SQL_TIMESTAMP.co...
synchronized Timestamp function( int parameterIndex) throws SQLException { TimestampData t = (TimestampData) getColumnInType(parameterIndex, Type.SQL_TIMESTAMP); if (t == null) { return null; } return (Timestamp) Type.SQL_TIMESTAMP.convertSQLToJava(session, t); }
/** * <!-- start generic documentation --> * * Retrieves the value of the designated JDBC <code>TIMESTAMP</code> * parameter as a <code>java.sql.Timestamp</code> object. <p> * * <!-- end generic documentation --> * * <!-- start release-specific documentation --> * <div class...
Retrieves the value of the designated JDBC <code>TIMESTAMP</code> parameter as a <code>java.sql.Timestamp</code> object. HSQLDB-Specific Information: HSQLDB supports this feature.
getTimestamp
{ "repo_name": "ifcharming/voltdb2.0", "path": "src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCCallableStatement.java", "license": "gpl-3.0", "size": 185755 }
[ "java.sql.SQLException", "java.sql.Timestamp", "org.hsqldb_voltpatches.types.TimestampData", "org.hsqldb_voltpatches.types.Type" ]
import java.sql.SQLException; import java.sql.Timestamp; import org.hsqldb_voltpatches.types.TimestampData; import org.hsqldb_voltpatches.types.Type;
import java.sql.*; import org.hsqldb_voltpatches.types.*;
[ "java.sql", "org.hsqldb_voltpatches.types" ]
java.sql; org.hsqldb_voltpatches.types;
2,458,740
public DatasetGraph set(DatasetGraph dsg) { return dsgx.getAndSet(dsg); }
DatasetGraph function(DatasetGraph dsg) { return dsgx.getAndSet(dsg); }
/** Set the base {@link DatasetGraph}. * Returns the old value. */
Set the base <code>DatasetGraph</code>. Returns the old value
set
{ "repo_name": "apache/jena", "path": "jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/store/DatasetGraphSwitchable.java", "license": "apache-2.0", "size": 4400 }
[ "org.apache.jena.sparql.core.DatasetGraph" ]
import org.apache.jena.sparql.core.DatasetGraph;
import org.apache.jena.sparql.core.*;
[ "org.apache.jena" ]
org.apache.jena;
1,482,585
public void setMatchHighlighter(AbstractHighlighter hl) { removeHighlighter(matchHighlighter); matchHighlighter = hl; if (markByHighlighter()) { moveMatchMarker(); } }
void function(AbstractHighlighter hl) { removeHighlighter(matchHighlighter); matchHighlighter = hl; if (markByHighlighter()) { moveMatchMarker(); } }
/** * Sets the AbstractHighlighter to use as match marker, if enabled. A null value * will re-install the default. * * @param hl the Highlighter to use as match marker. */
Sets the AbstractHighlighter to use as match marker, if enabled. A null value will re-install the default
setMatchHighlighter
{ "repo_name": "trejkaz/swingx", "path": "swingx-core/src/main/java/org/jdesktop/swingx/search/AbstractSearchable.java", "license": "lgpl-2.1", "size": 23818 }
[ "org.jdesktop.swingx.decorator.AbstractHighlighter" ]
import org.jdesktop.swingx.decorator.AbstractHighlighter;
import org.jdesktop.swingx.decorator.*;
[ "org.jdesktop.swingx" ]
org.jdesktop.swingx;
1,966,983
private void endSceneDescription() { switch (outputFormat) { case X3D: endX3dDescription(false); break; case X3DOM: endX3dDescription(true); break; case VRML: endVrmlDescription(); break; case KML: endKmlDescription(); break; default: throw new T3dException("The output format ...
void function() { switch (outputFormat) { case X3D: endX3dDescription(false); break; case X3DOM: endX3dDescription(true); break; case VRML: endVrmlDescription(); break; case KML: endKmlDescription(); break; default: throw new T3dException(STR + outputFormat.toString() + STR); } }
/** * Used to end a concrete scene-description (e.g. an X3D- or X3DOM-file). */
Used to end a concrete scene-description (e.g. an X3D- or X3DOM-file)
endSceneDescription
{ "repo_name": "cDanowski/worldviz", "path": "src/main/java/org/n52/v3d/worldviz/worldscene/VsAbstractWorldScene.java", "license": "gpl-2.0", "size": 10980 }
[ "org.n52.v3d.triturus.core.T3dException" ]
import org.n52.v3d.triturus.core.T3dException;
import org.n52.v3d.triturus.core.*;
[ "org.n52.v3d" ]
org.n52.v3d;
1,074,155
@Override public void gotDeSelected() { joystick_.unsetJoystick(Joystick.Keys.JOYSTICK, (JSAxisData) joystickBox_.getSelectedItem()); joystick_.unsetJoystick(Joystick.Keys.RIGHT_WHEEL, (JSAxisData) rightWheelBox_.getSelectedItem()); joystick_.unsetJoystick(Joystick.Keys.LEFT_WHEEL, (JSAxisData) ...
void function() { joystick_.unsetJoystick(Joystick.Keys.JOYSTICK, (JSAxisData) joystickBox_.getSelectedItem()); joystick_.unsetJoystick(Joystick.Keys.RIGHT_WHEEL, (JSAxisData) rightWheelBox_.getSelectedItem()); joystick_.unsetJoystick(Joystick.Keys.LEFT_WHEEL, (JSAxisData) leftWheelBox_.getSelectedItem()); }
/** * Should be called when enclosing panel loses focus. */
Should be called when enclosing panel loses focus
gotDeSelected
{ "repo_name": "kmdouglass/Micro-Manager", "path": "plugins/ASIdiSPIM/src/org/micromanager/asidispim/JoystickSubPanel.java", "license": "mit", "size": 10341 }
[ "org.micromanager.asidispim.Data" ]
import org.micromanager.asidispim.Data;
import org.micromanager.asidispim.*;
[ "org.micromanager.asidispim" ]
org.micromanager.asidispim;
1,006,423
public ServiceFuture<Void> deleteAsync(String resourceGroupName, String accountName, String assetName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, accountName, assetName), serviceCallback); }
ServiceFuture<Void> function(String resourceGroupName, String accountName, String assetName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, accountName, assetName), serviceCallback); }
/** * Delete an Asset. * Deletes an Asset in the Media Services account. * * @param resourceGroupName The name of the resource group within the Azure subscription. * @param accountName The Media Services account name. * @param assetName The Asset name. * @param serviceCallback the asy...
Delete an Asset. Deletes an Asset in the Media Services account
deleteAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/mediaservices/mgmt-v2018_03_30_preview/src/main/java/com/microsoft/azure/management/mediaservices/v2018_03_30_preview/implementation/AssetsInner.java", "license": "mit", "size": 64209 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
171,378
JPopupMenu createBugPopupMenu() { JPopupMenu popupMenu = new JPopupMenu(); JMenuItem filterMenuItem = MainFrameHelper.newJMenuItem("menu.filterBugsLikeThis", "Filter bugs like this"); filterMenuItem.addActionListener(evt -> { new NewFilterFromBug(new FilterFromBugPicker(current...
JPopupMenu createBugPopupMenu() { JPopupMenu popupMenu = new JPopupMenu(); JMenuItem filterMenuItem = MainFrameHelper.newJMenuItem(STR, STR); filterMenuItem.addActionListener(evt -> { new NewFilterFromBug(new FilterFromBugPicker(currentSelectedBugLeaf.getBug(), Arrays.asList(mainFrame.getAvailableSortables())), new App...
/** * Creates popup menu for bugs on tree. */
Creates popup menu for bugs on tree
createBugPopupMenu
{ "repo_name": "sewe/spotbugs", "path": "spotbugs/src/gui/edu/umd/cs/findbugs/gui2/MainFrameTree.java", "license": "lgpl-2.1", "size": 23104 }
[ "edu.umd.cs.findbugs.gui2.FilterActivity", "java.util.Arrays", "javax.swing.JMenuItem", "javax.swing.JPopupMenu" ]
import edu.umd.cs.findbugs.gui2.FilterActivity; import java.util.Arrays; import javax.swing.JMenuItem; import javax.swing.JPopupMenu;
import edu.umd.cs.findbugs.gui2.*; import java.util.*; import javax.swing.*;
[ "edu.umd.cs", "java.util", "javax.swing" ]
edu.umd.cs; java.util; javax.swing;
2,155,361
void receivedReply(ValidateMemoryReply reply);
void receivedReply(ValidateMemoryReply reply);
/** * Invoked after a Validate Memory reply was received from the debug client. * * @param reply The received reply. */
Invoked after a Validate Memory reply was received from the debug client
receivedReply
{ "repo_name": "google/binnavi", "path": "src/main/java/com/google/security/zynamics/binnavi/debug/debugger/interfaces/IDebugEventListener.java", "license": "apache-2.0", "size": 13661 }
[ "com.google.security.zynamics.binnavi.debug.connection.packets.replies.ValidateMemoryReply" ]
import com.google.security.zynamics.binnavi.debug.connection.packets.replies.ValidateMemoryReply;
import com.google.security.zynamics.binnavi.debug.connection.packets.replies.*;
[ "com.google.security" ]
com.google.security;
1,628,009
private long runLoop(ExtendedBlock suspectBlock) { long bytesScanned = -1; boolean scanError = false; ExtendedBlock block = null; try { long monotonicMs = Time.monotonicNow(); expireOldScannedBytesRecords(monotonicMs); if (!calculateShouldScan(volume.getStorageID(), conf.targetBytes...
long function(ExtendedBlock suspectBlock) { long bytesScanned = -1; boolean scanError = false; ExtendedBlock block = null; try { long monotonicMs = Time.monotonicNow(); expireOldScannedBytesRecords(monotonicMs); if (!calculateShouldScan(volume.getStorageID(), conf.targetBytesPerSec, scannedBytesSum, startMinute, curMin...
/** * Run an iteration of the VolumeScanner loop. * * @param suspectBlock A suspect block which we should scan, or null to * scan the next regularly scheduled block. * * @return The number of milliseconds to delay before running the loop * again, or 0 to re...
Run an iteration of the VolumeScanner loop
runLoop
{ "repo_name": "dennishuo/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/VolumeScanner.java", "license": "apache-2.0", "size": 26086 }
[ "java.io.IOException", "org.apache.hadoop.hdfs.protocol.ExtendedBlock", "org.apache.hadoop.util.Time" ]
import java.io.IOException; import org.apache.hadoop.hdfs.protocol.ExtendedBlock; import org.apache.hadoop.util.Time;
import java.io.*; import org.apache.hadoop.hdfs.protocol.*; import org.apache.hadoop.util.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
84,969
public void setSafe(int index, int isSet, long value) { handleSafe(index); set(index, isSet, value); } /** * Construct a TransferPair comprising of this and and a target vector of * the same type. * * @param ref name of the target vector * @param allocator allocator for the target vect...
void function(int index, int isSet, long value) { handleSafe(index); set(index, isSet, value); } /** * Construct a TransferPair comprising of this and and a target vector of * the same type. * * @param ref name of the target vector * @param allocator allocator for the target vector * @return {@link TransferPair}
/** * Same as {@link #set(int, int, long)} except that it handles the case * when index is greater than or equal to current value capacity of the * vector. * * @param index position of the new value * @param isSet 0 for NULL value, 1 otherwise * @param value The duration value (in the timeunit asso...
Same as <code>#set(int, int, long)</code> except that it handles the case when index is greater than or equal to current value capacity of the vector
setSafe
{ "repo_name": "majetideepak/arrow", "path": "java/vector/src/main/java/org/apache/arrow/vector/DurationVector.java", "license": "apache-2.0", "size": 12859 }
[ "org.apache.arrow.vector.util.TransferPair" ]
import org.apache.arrow.vector.util.TransferPair;
import org.apache.arrow.vector.util.*;
[ "org.apache.arrow" ]
org.apache.arrow;
564,721
public boolean injectOfMessage(IOFSwitch sw, OFMessage msg);
boolean function(IOFSwitch sw, OFMessage msg);
/** * Re-injects an OFMessage back into the packet processing chain * @param sw The switch to use for the message * @param msg the message to inject * @return True if successfully re-injected, false otherwise */
Re-injects an OFMessage back into the packet processing chain
injectOfMessage
{ "repo_name": "fbotelho-university-code/poseidon", "path": "src/main/java/net/floodlightcontroller/core/IFloodlightProviderService.java", "license": "apache-2.0", "size": 6929 }
[ "org.openflow.protocol.OFMessage" ]
import org.openflow.protocol.OFMessage;
import org.openflow.protocol.*;
[ "org.openflow.protocol" ]
org.openflow.protocol;
1,981,449
public static NativeCalls getInstance() { return instance; } private static class POSIXNativeCalls extends NativeCalls { static { Native.register("c"); }
static NativeCalls function() { return instance; } private static class POSIXNativeCalls extends NativeCalls { static { Native.register("c"); }
/** * Get an instance of JNA based implementation of {@link NativeCalls} for the current platform. */
Get an instance of JNA based implementation of <code>NativeCalls</code> for the current platform
getInstance
{ "repo_name": "smanvi-pivotal/geode", "path": "geode-core/src/main/java/org/apache/geode/internal/shared/NativeCallsJNAImpl.java", "license": "apache-2.0", "size": 34202 }
[ "com.sun.jna.Native" ]
import com.sun.jna.Native;
import com.sun.jna.*;
[ "com.sun.jna" ]
com.sun.jna;
2,414,642
public static Resource subtractFromNonNegative(Resource lhs, Resource rhs) { subtractFrom(lhs, rhs); if (lhs.getMemorySize() < 0) { lhs.setMemorySize(0); } if (lhs.getVirtualCores() < 0) { lhs.setVirtualCores(0); } return lhs; }
static Resource function(Resource lhs, Resource rhs) { subtractFrom(lhs, rhs); if (lhs.getMemorySize() < 0) { lhs.setMemorySize(0); } if (lhs.getVirtualCores() < 0) { lhs.setVirtualCores(0); } return lhs; }
/** * Subtract <code>rhs</code> from <code>lhs</code> and reset any negative * values to zero. * @param lhs {@link Resource} to subtract from * @param rhs {@link Resource} to subtract * @return the value of lhs after subtraction */
Subtract <code>rhs</code> from <code>lhs</code> and reset any negative values to zero
subtractFromNonNegative
{ "repo_name": "wenxinhe/hadoop", "path": "hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/util/resource/Resources.java", "license": "apache-2.0", "size": 16480 }
[ "org.apache.hadoop.yarn.api.records.Resource" ]
import org.apache.hadoop.yarn.api.records.Resource;
import org.apache.hadoop.yarn.api.records.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
1,821,277
public ServiceFuture<Void> beginDeleteAsync(String resourceGroupName, String routeTableName, String routeName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(beginDeleteWithServiceResponseAsync(resourceGroupName, routeTableName, routeName), serviceCallback); }
ServiceFuture<Void> function(String resourceGroupName, String routeTableName, String routeName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(beginDeleteWithServiceResponseAsync(resourceGroupName, routeTableName, routeName), serviceCallback); }
/** * Deletes the specified route from a route table. * * @param resourceGroupName The name of the resource group. * @param routeTableName The name of the route table. * @param routeName The name of the route. * @param serviceCallback the async ServiceCallback to handle successful and fail...
Deletes the specified route from a route table
beginDeleteAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/network/mgmt-v2019_07_01/src/main/java/com/microsoft/azure/management/network/v2019_07_01/implementation/RoutesInner.java", "license": "mit", "size": 43032 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
989,045
private void ensureLocationPermissions() { //Check if we have the right permissions to use location Boolean i = ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) == PackageManager.PERMISSION_GRANTED; if (i) { mMap.setMyLocationEnabled(true); ...
void function() { Boolean i = ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) == PackageManager.PERMISSION_GRANTED; if (i) { mMap.setMyLocationEnabled(true); } else { ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, 0); } }
/** * A quick permission check to ensure that we location services enabled */
A quick permission check to ensure that we location services enabled
ensureLocationPermissions
{ "repo_name": "CMPUT301F16T11/a2b", "path": "app/src/main/java/com/cmput301f16t11/a2b/RiderLocationActivity.java", "license": "apache-2.0", "size": 30140 }
[ "android.content.pm.PackageManager", "android.support.v4.app.ActivityCompat", "android.support.v4.content.ContextCompat" ]
import android.content.pm.PackageManager; import android.support.v4.app.ActivityCompat; import android.support.v4.content.ContextCompat;
import android.content.pm.*; import android.support.v4.app.*; import android.support.v4.content.*;
[ "android.content", "android.support" ]
android.content; android.support;
2,183,261
public ViewResultSet execute(Connection cn, String query, String dataBaseProductName) { ViewResultSet viewResultSet = null; viewResultSet = createDatabasebyKey(dataBaseProductName).execute(query, cn); return viewResultSet; }
ViewResultSet function(Connection cn, String query, String dataBaseProductName) { ViewResultSet viewResultSet = null; viewResultSet = createDatabasebyKey(dataBaseProductName).execute(query, cn); return viewResultSet; }
/** * Create explain plan for trainee query * * @param cn * @param query * @param dataBaseProductName * @return ViewResultSet */
Create explain plan for trainee query
execute
{ "repo_name": "bschiefer/sqlcoach", "path": "sqlcoach-persistence/src/main/java/de/sqlcoach/db/executionPlan/Facade.java", "license": "agpl-3.0", "size": 2949 }
[ "de.sqlcoach.util.ViewResultSet", "java.sql.Connection" ]
import de.sqlcoach.util.ViewResultSet; import java.sql.Connection;
import de.sqlcoach.util.*; import java.sql.*;
[ "de.sqlcoach.util", "java.sql" ]
de.sqlcoach.util; java.sql;
2,887,371
public String collectDeviceData(Activity activity, BraintreeEnvironment environment) { return collectDeviceData(activity, environment.getMerchantId(), environment.getCollectorUrl()); }
String function(Activity activity, BraintreeEnvironment environment) { return collectDeviceData(activity, environment.getMerchantId(), environment.getCollectorUrl()); }
/** * Collect device information for fraud identification purposes. * * @param activity The currently visible activity. * @param environment The Braintree environment to use. * @return device_id String to send to Braintree. * @see com.braintreepayments.api.data.BraintreeData */
Collect device information for fraud identification purposes
collectDeviceData
{ "repo_name": "lgvalle/braintree_android", "path": "BraintreeApi/src/main/java/com/braintreepayments/api/BraintreeApi.java", "license": "mit", "size": 17197 }
[ "android.app.Activity", "com.braintreepayments.api.data.BraintreeEnvironment" ]
import android.app.Activity; import com.braintreepayments.api.data.BraintreeEnvironment;
import android.app.*; import com.braintreepayments.api.data.*;
[ "android.app", "com.braintreepayments.api" ]
android.app; com.braintreepayments.api;
2,528,279
@Operation(desc = "Destroy a queue", impact = MBeanOperationInfo.ACTION) void destroyQueue(@Parameter(name = "name", desc = "Name of the queue to destroy") String name) throws Exception;
@Operation(desc = STR, impact = MBeanOperationInfo.ACTION) void destroyQueue(@Parameter(name = "name", desc = STR) String name) throws Exception;
/** * Destroys the queue corresponding to the specified name. */
Destroys the queue corresponding to the specified name
destroyQueue
{ "repo_name": "johnament/activemq-artemis", "path": "artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/management/ActiveMQServerControl.java", "license": "apache-2.0", "size": 58028 }
[ "javax.management.MBeanOperationInfo" ]
import javax.management.MBeanOperationInfo;
import javax.management.*;
[ "javax.management" ]
javax.management;
1,356,574
public static String getUserUuid() { Authentication authentication = getAuthentication(); UserDetails springSecurityUser = null; String userName = null; if (authentication != null) { if (authentication.getPrincipal() instanceof UserDetails) { springSecurit...
static String function() { Authentication authentication = getAuthentication(); UserDetails springSecurityUser = null; String userName = null; if (authentication != null) { if (authentication.getPrincipal() instanceof UserDetails) { springSecurityUser = (UserDetails) authentication.getPrincipal(); userName = springSecu...
/** * Get the login of the current user. */
Get the login of the current user
getUserUuid
{ "repo_name": "esutoniagodesu/egd-web", "path": "src/main/java/ee/esutoniagodesu/security/SecurityUtils.java", "license": "gpl-2.0", "size": 2669 }
[ "org.springframework.security.core.Authentication", "org.springframework.security.core.userdetails.UserDetails" ]
import org.springframework.security.core.Authentication; import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.*; import org.springframework.security.core.userdetails.*;
[ "org.springframework.security" ]
org.springframework.security;
2,536,063
public static List<Tuple<int[],Double>> distanceSortedEdges(List<String> cells, Point point) { final List<BoundingBox> boxes = new ArrayList<BoundingBox>(); for(final String cell : cells) { boxes.add(computeBox(cell)); } double maxNorth = Double.NEGATIVE_INFINITY; ...
static List<Tuple<int[],Double>> function(List<String> cells, Point point) { final List<BoundingBox> boxes = new ArrayList<BoundingBox>(); for(final String cell : cells) { boxes.add(computeBox(cell)); } double maxNorth = Double.NEGATIVE_INFINITY; double maxEast = Double.NEGATIVE_INFINITY; double maxSouth = Double.POSIT...
/** * Returns the edges of the rectangular region containing all of the given geocells, sorted by distance from the given point, along with the actual distances from the point to these edges. * * @param cells: The cells (should be adjacent) defining the rectangular region ...
Returns the edges of the rectangular region containing all of the
distanceSortedEdges
{ "repo_name": "mitmel/Locast-Core-Android", "path": "src/com/beoui/geocell/GeocellUtils.java", "license": "gpl-2.0", "size": 22325 }
[ "com.beoui.geocell.comparator.DoubleTupleComparator", "com.beoui.geocell.model.BoundingBox", "com.beoui.geocell.model.Point", "com.beoui.geocell.model.Tuple", "java.util.ArrayList", "java.util.Collections", "java.util.List" ]
import com.beoui.geocell.comparator.DoubleTupleComparator; import com.beoui.geocell.model.BoundingBox; import com.beoui.geocell.model.Point; import com.beoui.geocell.model.Tuple; import java.util.ArrayList; import java.util.Collections; import java.util.List;
import com.beoui.geocell.comparator.*; import com.beoui.geocell.model.*; import java.util.*;
[ "com.beoui.geocell", "java.util" ]
com.beoui.geocell; java.util;
1,431,559
public void call(String name, Writable json) throws IOException { writeName(name); verifyValue(); if(json instanceof GString) { writer.write(generator.toJson(json.toString())); } else { json.writeTo(writer); ...
void function(String name, Writable json) throws IOException { writeName(name); verifyValue(); if(json instanceof GString) { writer.write(generator.toJson(json.toString())); } else { json.writeTo(writer); } }
/** * Writes the given Writable as the value of the given attribute name * * @param name The attribute name * @param json The writable value * @throws IOException */
Writes the given Writable as the value of the given attribute name
call
{ "repo_name": "russel/incubator-groovy", "path": "subprojects/groovy-json/src/main/java/groovy/json/StreamingJsonBuilder.java", "license": "apache-2.0", "size": 31416 }
[ "groovy.lang.GString", "groovy.lang.Writable", "java.io.IOException" ]
import groovy.lang.GString; import groovy.lang.Writable; import java.io.IOException;
import groovy.lang.*; import java.io.*;
[ "groovy.lang", "java.io" ]
groovy.lang; java.io;
2,044,414
public void removeWay( OverlayWay overlayWay ) { synchronized (this.overlayWays) { this.overlayWays.remove(overlayWay); } populate(); }
void function( OverlayWay overlayWay ) { synchronized (this.overlayWays) { this.overlayWays.remove(overlayWay); } populate(); }
/** * Removes the given way from the overlay. * * @param overlayWay * the way that should be removed from the overlay. */
Removes the given way from the overlay
removeWay
{ "repo_name": "gabrielmancilla/mtisig", "path": "geopaparazzi.app/src/eu/hydrologis/geopaparazzi/maps/overlays/ArrayGeopaparazziOverlay.java", "license": "gpl-3.0", "size": 5265 }
[ "org.mapsforge.android.maps.overlay.OverlayWay" ]
import org.mapsforge.android.maps.overlay.OverlayWay;
import org.mapsforge.android.maps.overlay.*;
[ "org.mapsforge.android" ]
org.mapsforge.android;
2,436,201
public void testTwoOutOfThreeSamePriorTherapy() throws Exception { ExpeditedAdverseEventReport aeReport = createAEReport(); aeReport.addSaeReportPriorTherapies(aeReport.getSaeReportPriorTherapies().get(1)); ValidationErrors errors = fireRules(aeReport); assertCorrectErrorCode(errors,...
void function() throws Exception { ExpeditedAdverseEventReport aeReport = createAEReport(); aeReport.addSaeReportPriorTherapies(aeReport.getSaeReportPriorTherapies().get(1)); ValidationErrors errors = fireRules(aeReport); assertCorrectErrorCode(errors, STR); assertSameErrorCount(errors, 1); assertEquals(STR, 3, errors....
/** * RuleName : PTY_UK_CHK Logic : Prior Therapy must be unique Error Code : PTY_UK_ERR Error * Message : PRIOR_THERAPY must be unique */
RuleName : PTY_UK_CHK Logic : Prior Therapy must be unique Error Code : PTY_UK_ERR Error Message : PRIOR_THERAPY must be unique
testTwoOutOfThreeSamePriorTherapy
{ "repo_name": "CBIIT/caaers", "path": "caAERS/software/core/src/test/java/gov/nih/nci/cabig/caaers/rules/deploy/PriorTherapyBusinessRulesTest.java", "license": "bsd-3-clause", "size": 21550 }
[ "gov.nih.nci.cabig.caaers.domain.ExpeditedAdverseEventReport", "gov.nih.nci.cabig.caaers.validation.ValidationErrors" ]
import gov.nih.nci.cabig.caaers.domain.ExpeditedAdverseEventReport; import gov.nih.nci.cabig.caaers.validation.ValidationErrors;
import gov.nih.nci.cabig.caaers.domain.*; import gov.nih.nci.cabig.caaers.validation.*;
[ "gov.nih.nci" ]
gov.nih.nci;
1,637,429
public Properties toProperties() { return toProperties(false ); }
Properties function() { return toProperties(false ); }
/** * Converts the contents of this config to a property instance. * * @return contents of this config as java.util.Properties */
Converts the contents of this config to a property instance
toProperties
{ "repo_name": "davebarnes97/geode", "path": "geode-core/src/main/java/org/apache/geode/admin/jmx/internal/AgentConfigImpl.java", "license": "apache-2.0", "size": 65588 }
[ "java.util.Properties" ]
import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
92,786
protected void addOutput__oAnalogScaledPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_CtrlUnit10_Output__oAnalogScaled_feature"), get...
void function(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), WTSpecPackage.eINSTANCE.getCtrlUnit10_Output__oAnalogScaled(), true, false, true, null, null, nul...
/** * This adds a property descriptor for the Output oAnalog Scaled feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
This adds a property descriptor for the Output oAnalog Scaled feature.
addOutput__oAnalogScaledPropertyDescriptor
{ "repo_name": "FTSRG/mondo-collab-framework", "path": "archive/workspaceTracker/VA/ikerlanEMF.edit/src/eu/mondo/collaboration/operationtracemodel/example/WTSpec/provider/CtrlUnit10ItemProvider.java", "license": "epl-1.0", "size": 10941 }
[ "eu.mondo.collaboration.operationtracemodel.example.WTSpec", "org.eclipse.emf.edit.provider.ComposeableAdapterFactory" ]
import eu.mondo.collaboration.operationtracemodel.example.WTSpec; import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
import eu.mondo.collaboration.operationtracemodel.example.*; import org.eclipse.emf.edit.provider.*;
[ "eu.mondo.collaboration", "org.eclipse.emf" ]
eu.mondo.collaboration; org.eclipse.emf;
2,327,193
public final MetaProperty<BusinessDayConvention> businessDayConvention() { return _businessDayConvention; }
final MetaProperty<BusinessDayConvention> function() { return _businessDayConvention; }
/** * The meta-property for the {@code businessDayConvention} property. * @return the meta-property, not null */
The meta-property for the businessDayConvention property
businessDayConvention
{ "repo_name": "McLeodMoores/starling", "path": "projects/financial-types/src/main/java/com/opengamma/financial/convention/BondConvention.java", "license": "apache-2.0", "size": 15941 }
[ "com.opengamma.financial.convention.businessday.BusinessDayConvention", "org.joda.beans.MetaProperty" ]
import com.opengamma.financial.convention.businessday.BusinessDayConvention; import org.joda.beans.MetaProperty;
import com.opengamma.financial.convention.businessday.*; import org.joda.beans.*;
[ "com.opengamma.financial", "org.joda.beans" ]
com.opengamma.financial; org.joda.beans;
1,282,969
private boolean isNewer(JsonObject release) { if (!release.has("tag_name")) { return false; } Version releaseVer = new Version(release.get("tag_name").getAsString()); Version installedVer = new Version(currentVersion); return releaseVer.isNewerThan(installedVer)...
boolean function(JsonObject release) { if (!release.has(STR)) { return false; } Version releaseVer = new Version(release.get(STR).getAsString()); Version installedVer = new Version(currentVersion); return releaseVer.isNewerThan(installedVer); }
/** * True if release version differs from current version. */
True if release version differs from current version
isNewer
{ "repo_name": "tmc-cli/tmc-cli", "path": "src/main/java/fi/helsinki/cs/tmc/cli/updater/AutoUpdater.java", "license": "mit", "size": 7911 }
[ "com.google.gson.JsonObject" ]
import com.google.gson.JsonObject;
import com.google.gson.*;
[ "com.google.gson" ]
com.google.gson;
747,874
public static boolean delQuota(ZooKeeper zk, String path, boolean bytes, boolean numNodes) throws KeeperException, IOException, InterruptedException { String parentPath = Quotas.quotaZookeeper + path; String quotaPath = Quotas.quotaZookeeper + path + "/" + Quotas.limitNode; ...
static boolean function(ZooKeeper zk, String path, boolean bytes, boolean numNodes) throws KeeperException, IOException, InterruptedException { String parentPath = Quotas.quotaZookeeper + path; String quotaPath = Quotas.quotaZookeeper + path + "/" + Quotas.limitNode; if (zk.exists(quotaPath, false) == null) { System.ou...
/** * this method deletes quota for a node. * @param zk the zookeeper client * @param path the path to delete quota for * @param bytes true if number of bytes needs to * be unset * @param numNodes true if number of nodes needs * to be unset * @return true if quota deletion is suc...
this method deletes quota for a node
delQuota
{ "repo_name": "apurtell/zookeeper", "path": "src/java/main/org/apache/zookeeper/ZooKeeperMain.java", "license": "apache-2.0", "size": 32750 }
[ "java.io.IOException", "java.util.List", "org.apache.zookeeper.data.Stat" ]
import java.io.IOException; import java.util.List; import org.apache.zookeeper.data.Stat;
import java.io.*; import java.util.*; import org.apache.zookeeper.data.*;
[ "java.io", "java.util", "org.apache.zookeeper" ]
java.io; java.util; org.apache.zookeeper;
1,127,238
EClass getState();
EClass getState();
/** * Returns the meta object for class '{@link simplefsmtest.timedfsmmt.fsm.State <em>State</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>State</em>'. * @see simplefsmtest.timedfsmmt.fsm.State * @generated */
Returns the meta object for class '<code>simplefsmtest.timedfsmmt.fsm.State State</code>'.
getState
{ "repo_name": "diverse-project/melange", "path": "tests/fr.inria.diverse.melange.tests/src/main/java/simplefsmtest/timedfsmmt/fsm/FsmPackage.java", "license": "epl-1.0", "size": 15500 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
851,906
public void testPositionOffsetGapDeprecation() throws Exception { // test deprecation exceptions on newly created indexes String mapping = XContentFactory.jsonBuilder().startObject().startObject("type") .startObject("properties") .startObject("field1") ...
void function() throws Exception { String mapping = XContentFactory.jsonBuilder().startObject().startObject("type") .startObject(STR) .startObject(STR) .field("type", STR) .field(STR, 10) .endObject() .startObject(STR) .field("type", STR) .field(STR, 50) .field(STR, STR) .endObject().endObject().endObject().endObject()...
/** * Test that expected exceptions are thrown when creating a new index with position_offset_gap */
Test that expected exceptions are thrown when creating a new index with position_offset_gap
testPositionOffsetGapDeprecation
{ "repo_name": "wbowling/elasticsearch", "path": "core/src/test/java/org/elasticsearch/index/mapper/string/SimpleStringMappingTests.java", "license": "apache-2.0", "size": 27327 }
[ "org.elasticsearch.common.xcontent.XContentFactory", "org.elasticsearch.index.mapper.MapperParsingException" ]
import org.elasticsearch.common.xcontent.XContentFactory; import org.elasticsearch.index.mapper.MapperParsingException;
import org.elasticsearch.common.xcontent.*; import org.elasticsearch.index.mapper.*;
[ "org.elasticsearch.common", "org.elasticsearch.index" ]
org.elasticsearch.common; org.elasticsearch.index;
2,749,808
public static ClosableIterator<Resource> getAllMember(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource) { return Base.getAll(model, instanceResource, MEMBER, Resource.class); }
static ClosableIterator<Resource> function(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource) { return Base.getAll(model, instanceResource, MEMBER, Resource.class); }
/** * Get all values of property Member * * @param model an RDF2Go model * * @param instanceResource an RDF2Go resource * @return a ClosableIterator of $type * * [Generated from RDFReactor template rule #get11static] */
Get all values of property Member
getAllMember
{ "repo_name": "semweb4j/semweb4j", "path": "org.semweb4j.rdfreactor.generator/src/main/java/org/ontoware/rdfreactor/schema/bootstrap/Resource.java", "license": "bsd-2-clause", "size": 83665 }
[ "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;
1,541,686
protected static LocaleContext buildLocaleContext(final HttpServletRequest request) { Locale locale = localeResolver.resolveLocale(request); return new SimpleLocaleContext(locale); }
static LocaleContext function(final HttpServletRequest request) { Locale locale = localeResolver.resolveLocale(request); return new SimpleLocaleContext(locale); }
/** * Build a LocaleContext for the given request, exposing the request's * primary locale as current locale. * <p>The default implementation uses the dispatcher's LocaleResolver * to obtain the current locale, which might change during a request. * @param request current HTTP request * @return the co...
Build a LocaleContext for the given request, exposing the request's primary locale as current locale. The default implementation uses the dispatcher's LocaleResolver to obtain the current locale, which might change during a request
buildLocaleContext
{ "repo_name": "shufudong/bboss", "path": "bboss-mvc/src/org/frameworkset/web/servlet/DispatchServlet.java", "license": "apache-2.0", "size": 72693 }
[ "java.util.Locale", "javax.servlet.http.HttpServletRequest", "org.frameworkset.spi.support.LocaleContext", "org.frameworkset.spi.support.SimpleLocaleContext" ]
import java.util.Locale; import javax.servlet.http.HttpServletRequest; import org.frameworkset.spi.support.LocaleContext; import org.frameworkset.spi.support.SimpleLocaleContext;
import java.util.*; import javax.servlet.http.*; import org.frameworkset.spi.support.*;
[ "java.util", "javax.servlet", "org.frameworkset.spi" ]
java.util; javax.servlet; org.frameworkset.spi;
922,278
@Override public void run() { long nextSequence; boolean processedSequence = true; try { //while(processor.alive() && processor.upstreamSubscription == null); Thread.currentThread() .setContextClassLoader(processor.contextClassLoader); subscriber.onSubscribe(this); long cach...
void function() { long nextSequence; boolean processedSequence = true; try { Thread.currentThread() .setContextClassLoader(processor.contextClassLoader); subscriber.onSubscribe(this); long cachedAvailableSequence = Long.MIN_VALUE; nextSequence = sequence.getAsLong(); Slot<T> event = null; final boolean unbounded = pend...
/** * It is ok to have another thread rerun this method after a halt(). */
It is ok to have another thread rerun this method after a halt()
run
{ "repo_name": "reactor/reactor-extensions", "path": "reactor-extra/src/main/java/reactor/extra/processor/WorkQueueProcessor.java", "license": "apache-2.0", "size": 22641 }
[ "java.util.concurrent.locks.LockSupport" ]
import java.util.concurrent.locks.LockSupport;
import java.util.concurrent.locks.*;
[ "java.util" ]
java.util;
195,607
private void loadHistory(final int itemToLoad, RevWalk walk) { if (itemToLoad == INITIAL_ITEM) { job = new GenerateHistoryJob(this, graph.getControl(), walk, resources); job.setRule(this); } job.setLoadHint(itemToLoad); if (trace) GitTraceLocation.getTrace().trace( GitTraceLocation.HISTORY...
void function(final int itemToLoad, RevWalk walk) { if (itemToLoad == INITIAL_ITEM) { job = new GenerateHistoryJob(this, graph.getControl(), walk, resources); job.setRule(this); } job.setLoadHint(itemToLoad); if (trace) GitTraceLocation.getTrace().trace( GitTraceLocation.HISTORYVIEW.getLocation(), STR); schedule(job); ...
/** * Load history items incrementally * @param itemToLoad hint for index of item that should be loaded * @param walk the revwalk, used only if itemToLoad == INITIAL_ITEM */
Load history items incrementally
loadHistory
{ "repo_name": "blizzy78/egit", "path": "org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/history/GitHistoryPage.java", "license": "epl-1.0", "size": 71372 }
[ "org.eclipse.egit.ui.internal.trace.GitTraceLocation", "org.eclipse.jgit.revwalk.RevWalk" ]
import org.eclipse.egit.ui.internal.trace.GitTraceLocation; import org.eclipse.jgit.revwalk.RevWalk;
import org.eclipse.egit.ui.internal.trace.*; import org.eclipse.jgit.revwalk.*;
[ "org.eclipse.egit", "org.eclipse.jgit" ]
org.eclipse.egit; org.eclipse.jgit;
1,975,743
@SuppressWarnings("unchecked") public Set<V> getValuesByKey(final K key, final int numberOfValues, final Set<V> _blackListedIDs) { if (key == null) { throw new RuntimeException("invalid arguments k=" + key); } // define the result Set<V> result = new HashSet<V>(); // determine the curren...
@SuppressWarnings(STR) Set<V> function(final K key, final int numberOfValues, final Set<V> _blackListedIDs) { if (key == null) { throw new RuntimeException(STR + key); } Set<V> result = new HashSet<V>(); int[] temp = this.listIndexByKey.get(key); if (temp != null){ int currentIndex = temp[0]; for (int i = 0; i < 3 * nu...
/** * Get some values from the ring buffer. * This method is NOT synchronized and may return inconsistent values. * This method does not block. It always returns an HashSet (might be empty) * values refer to all items which are in the publisher's item list * * @param key * @param numberOfValues ...
Get some values from the ring buffer. This method is NOT synchronized and may return inconsistent values. This method does not block. It always returns an HashSet (might be empty) values refer to all items which are in the publisher's item list
getValuesByKey
{ "repo_name": "andreas-dai/NewsREEL-Template", "path": "src/main/java/de/dailab/plistacontest/client/DirtyRingBuffer.java", "license": "mit", "size": 6593 }
[ "java.util.HashSet", "java.util.Set" ]
import java.util.HashSet; import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
1,366,324
public String decryptAsNeeded(final String value) { try { // Try a decryption return decrypt(value); } catch (final EncryptionOperationNotPossibleException e) { // NOSONAR - Ignore raw value // Value could be encrypted, but was not return value; } }
String function(final String value) { try { return decrypt(value); } catch (final EncryptionOperationNotPossibleException e) { return value; } }
/** * Decrypt a potentially encrypted value. * * @param value The encrypted value to decrypt if not <code>null</code>. * @return the decrypted value. */
Decrypt a potentially encrypted value
decryptAsNeeded
{ "repo_name": "ligoj/bootstrap", "path": "bootstrap-core/src/main/java/org/ligoj/bootstrap/core/crypto/CryptoHelper.java", "license": "mit", "size": 2605 }
[ "org.jasypt.exceptions.EncryptionOperationNotPossibleException" ]
import org.jasypt.exceptions.EncryptionOperationNotPossibleException;
import org.jasypt.exceptions.*;
[ "org.jasypt.exceptions" ]
org.jasypt.exceptions;
203,643
public void testCanonicalize() throws EncodingException { System.out.println("canonicalize"); ArrayList<String> list = new ArrayList<String>(); list.add( "HTMLEntityCodec" ); list.add( "PercentCodec" ); Encoder instance = new DefaultEncoder( list ); // Test null paths assert...
void function() throws EncodingException { System.out.println(STR); ArrayList<String> list = new ArrayList<String>(); list.add( STR ); list.add( STR ); Encoder instance = new DefaultEncoder( list ); assertEquals( null, instance.canonicalize(null)); assertEquals( null, instance.canonicalize(null, true)); assertEquals( n...
/** * Test of canonicalize method, of class org.owasp.esapi.Encoder. * * @throws EncodingException */
Test of canonicalize method, of class org.owasp.esapi.Encoder
testCanonicalize
{ "repo_name": "marylinh/ESAPI_JAVA_ALL", "path": "src/test/java/org/owasp/esapi/reference/EncoderTest.java", "license": "bsd-3-clause", "size": 35801 }
[ "java.util.ArrayList", "org.owasp.esapi.Encoder", "org.owasp.esapi.errors.EncodingException" ]
import java.util.ArrayList; import org.owasp.esapi.Encoder; import org.owasp.esapi.errors.EncodingException;
import java.util.*; import org.owasp.esapi.*; import org.owasp.esapi.errors.*;
[ "java.util", "org.owasp.esapi" ]
java.util; org.owasp.esapi;
2,119,786
@PublicEvolving public ResourceSpec getMinResources() { return transformation.getMinResources(); }
ResourceSpec function() { return transformation.getMinResources(); }
/** * Gets the minimum resources for this operator. * * @return The minimum resources set for this operator. */
Gets the minimum resources for this operator
getMinResources
{ "repo_name": "darionyaphet/flink", "path": "flink-streaming-java/src/main/java/org/apache/flink/streaming/api/datastream/DataStream.java", "license": "apache-2.0", "size": 51499 }
[ "org.apache.flink.api.common.operators.ResourceSpec" ]
import org.apache.flink.api.common.operators.ResourceSpec;
import org.apache.flink.api.common.operators.*;
[ "org.apache.flink" ]
org.apache.flink;
2,783,790
Chunk getChunk();
Chunk getChunk();
/** * Gets the chunk which contains this block * * @return Containing Chunk */
Gets the chunk which contains this block
getChunk
{ "repo_name": "Scrik/Cauldron-1", "path": "eclipse/cauldron/src/main/java/org/bukkit/block/Block.java", "license": "gpl-3.0", "size": 9885 }
[ "org.bukkit.Chunk" ]
import org.bukkit.Chunk;
import org.bukkit.*;
[ "org.bukkit" ]
org.bukkit;
1,166,666
@ApiModelProperty(value = "The postal code for the billing address.") public String getPreviousUri() { return previousUri; }
@ApiModelProperty(value = STR) String function() { return previousUri; }
/** * The postal code for the billing address.. * @return previousUri **/
The postal code for the billing address.
getPreviousUri
{ "repo_name": "docusign/docusign-java-client", "path": "src/main/java/com/docusign/esign/model/BillingPaymentsResponse.java", "license": "mit", "size": 4576 }
[ "io.swagger.annotations.ApiModelProperty" ]
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.*;
[ "io.swagger.annotations" ]
io.swagger.annotations;
2,916,090
public static java.util.Set extractPathwayHistorySet(ims.domain.ILightweightDomainFactory domainFactory, ims.pathways.vo.PathwayHistoryVoCollection voCollection) { return extractPathwayHistorySet(domainFactory, voCollection, null, new HashMap()); }
static java.util.Set function(ims.domain.ILightweightDomainFactory domainFactory, ims.pathways.vo.PathwayHistoryVoCollection voCollection) { return extractPathwayHistorySet(domainFactory, voCollection, null, new HashMap()); }
/** * Create the ims.pathways.domain.objects.PathwayHistory set from the value object collection. * @param domainFactory - used to create existing (persistent) domain objects. * @param voCollection - the collection of value objects */
Create the ims.pathways.domain.objects.PathwayHistory set from the value object collection
extractPathwayHistorySet
{ "repo_name": "FreudianNM/openMAXIMS", "path": "Source Library/openmaxims_workspace/ValueObjects/src/ims/pathways/vo/domain/PathwayHistoryVoAssembler.java", "license": "agpl-3.0", "size": 17981 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
979,832
private static AnalyticsInfoDTO toAnalyticsDTO(RegistrationSummary registrationSummary) { AnalyticsInfoDTO analyticsInfoDTO = new AnalyticsInfoDTO(); analyticsInfoDTO.serverURL(registrationSummary.getAnalyticsInfo().getDasServerURL()); analyticsInfoDTO.setEnabled(registrationSummary.getAnaly...
static AnalyticsInfoDTO function(RegistrationSummary registrationSummary) { AnalyticsInfoDTO analyticsInfoDTO = new AnalyticsInfoDTO(); analyticsInfoDTO.serverURL(registrationSummary.getAnalyticsInfo().getDasServerURL()); analyticsInfoDTO.setEnabled(registrationSummary.getAnalyticsInfo().isEnabled()); CredentialsDTO an...
/** * Converts RegistrationSummary analytics information into AnalyticsInfoDTO * * @param registrationSummary the registration summary required by gateway * @return AnalyticsInfoDTO */
Converts RegistrationSummary analytics information into AnalyticsInfoDTO
toAnalyticsDTO
{ "repo_name": "abimarank/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.rest.api.core/src/main/java/org/wso2/carbon/apimgt/rest/api/core/utils/MappingUtil.java", "license": "apache-2.0", "size": 15421 }
[ "org.wso2.carbon.apimgt.core.models.RegistrationSummary", "org.wso2.carbon.apimgt.rest.api.core.dto.AnalyticsInfoDTO", "org.wso2.carbon.apimgt.rest.api.core.dto.CredentialsDTO" ]
import org.wso2.carbon.apimgt.core.models.RegistrationSummary; import org.wso2.carbon.apimgt.rest.api.core.dto.AnalyticsInfoDTO; import org.wso2.carbon.apimgt.rest.api.core.dto.CredentialsDTO;
import org.wso2.carbon.apimgt.core.models.*; import org.wso2.carbon.apimgt.rest.api.core.dto.*;
[ "org.wso2.carbon" ]
org.wso2.carbon;
2,327,843
protected static List<File> getExpectedOutputFile( File dir, String baseName ) { List<File> files = new ArrayList<File>(); File expected = new File( dir, baseName + ".fail.txt" ); if ( expected.exists() ) { files.add( expected ); } for ( String extension : new String[] { ".txt", ".csv", "....
static List<File> function( File dir, String baseName ) { List<File> files = new ArrayList<File>(); File expected = new File( dir, baseName + STR ); if ( expected.exists() ) { files.add( expected ); } for ( String extension : new String[] { ".txt", ".csv", ".xml" } ) { expected = new File( dir, baseName + STR + extensi...
/** * Tries to find an output file to match a transformation or job file * * @param dir * The directory to look in * @param baseName * Name of the transformation or the job without the extension * @return list of output files */
Tries to find an output file to match a transformation or job file
getExpectedOutputFile
{ "repo_name": "apratkin/pentaho-kettle", "path": "test/org/pentaho/di/blackbox/BlackBoxTests.java", "license": "apache-2.0", "size": 13564 }
[ "java.io.File", "java.util.ArrayList", "java.util.List" ]
import java.io.File; import java.util.ArrayList; import java.util.List;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
684,437
interface UpdateStages { interface WithTags { Update withTags(Map<String, String> tags); } }
interface UpdateStages { interface WithTags { Update withTags(Map<String, String> tags); } }
/** * Specifies the tags property: Resource tags. * * @param tags Resource tags. * @return the next definition stage. */
Specifies the tags property: Resource tags
withTags
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/deviceprovisioningservices/azure-resourcemanager-deviceprovisioningservices/src/main/java/com/azure/resourcemanager/deviceprovisioningservices/models/ProvisioningServiceDescription.java", "license": "mit", "size": 10004 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
1,256,567
public Map<IndexDescriptor, IndexConditionInfo> getFirstKeyIndexConditionMap() { Map<IndexDescriptor, IndexConditionInfo> indexInfoMap = Maps.newLinkedHashMap(); RexNode initCondition = condition; for (IndexDescriptor index : indexes) { List<LogicalExpression> leadingColumns = new ArrayL...
Map<IndexDescriptor, IndexConditionInfo> function() { Map<IndexDescriptor, IndexConditionInfo> indexInfoMap = Maps.newLinkedHashMap(); RexNode initCondition = condition; for (IndexDescriptor index : indexes) { List<LogicalExpression> leadingColumns = new ArrayList<>(); if (initCondition.isAlwaysTrue()) { break; } leadi...
/** * Get a map of Index=>IndexConditionInfo, each IndexConditionInfo has the separated condition and remainder condition. * The map is ordered, so the last IndexDescriptor will have the final remainderCondition after separating conditions * that are relevant to this.indexes. The conditions are separated...
Get a map of Index=>IndexConditionInfo, each IndexConditionInfo has the separated condition and remainder condition. The map is ordered, so the last IndexDescriptor will have the final remainderCondition after separating conditions that are relevant to this.indexes. The conditions are separated on LEADING index columns
getFirstKeyIndexConditionMap
{ "repo_name": "apache/drill", "path": "exec/java-exec/src/main/java/org/apache/drill/exec/planner/index/IndexConditionInfo.java", "license": "apache-2.0", "size": 10612 }
[ "java.util.ArrayList", "java.util.List", "java.util.Map", "org.apache.calcite.rex.RexNode", "org.apache.drill.common.expression.LogicalExpression", "org.apache.drill.shaded.guava.com.google.common.collect.Maps" ]
import java.util.ArrayList; import java.util.List; import java.util.Map; import org.apache.calcite.rex.RexNode; import org.apache.drill.common.expression.LogicalExpression; import org.apache.drill.shaded.guava.com.google.common.collect.Maps;
import java.util.*; import org.apache.calcite.rex.*; import org.apache.drill.common.expression.*; import org.apache.drill.shaded.guava.com.google.common.collect.*;
[ "java.util", "org.apache.calcite", "org.apache.drill" ]
java.util; org.apache.calcite; org.apache.drill;
1,548,614
void addException(String word, ArrayList hyphenatedword);
void addException(String word, ArrayList hyphenatedword);
/** * Add a hyphenation exception. An exception replaces the * result obtained by the algorithm for cases for which this * fails or the user wants to provide his own hyphenation. * A hyphenatedword is a vector of alternating String's and * {@link Hyphen Hyphen} instances */
Add a hyphenation exception. An exception replaces the result obtained by the algorithm for cases for which this fails or the user wants to provide his own hyphenation. A hyphenatedword is a vector of alternating String's and <code>Hyphen Hyphen</code> instances
addException
{ "repo_name": "venanciolm/afirma-ui-miniapplet_x_x", "path": "afirma_ui_miniapplet/src/main/java/com/lowagie/text/pdf/hyphenation/PatternConsumer.java", "license": "mit", "size": 1765 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
2,895,351
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller<PollResult<Void>, Void> beginRestoreFiles( String resourceGroupName, String accountName, String poolName, String volumeName, String snapshotName, SnapshotRestoreFiles body, Context cont...
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller<PollResult<Void>, Void> beginRestoreFiles( String resourceGroupName, String accountName, String poolName, String volumeName, String snapshotName, SnapshotRestoreFiles body, Context context);
/** * Restore the specified files from the specified snapshot to the active filesystem. * * @param resourceGroupName The name of the resource group. * @param accountName The name of the NetApp account. * @param poolName The name of the capacity pool. * @param volumeName The name of the vol...
Restore the specified files from the specified snapshot to the active filesystem
beginRestoreFiles
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/netapp/azure-resourcemanager-netapp/src/main/java/com/azure/resourcemanager/netapp/fluent/SnapshotsClient.java", "license": "mit", "size": 21515 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.management.polling.PollResult", "com.azure.core.util.Context", "com.azure.core.util.polling.SyncPoller", "com.azure.resourcemanager.netapp.models.SnapshotRestoreFiles" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.netapp.models.SnapshotRestoreFiles;
import com.azure.core.annotation.*; import com.azure.core.management.polling.*; import com.azure.core.util.*; import com.azure.core.util.polling.*; import com.azure.resourcemanager.netapp.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
2,073,388
@ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable<ReservationSummaryInner> list(String scope, Datagrain grain) { final String startDate = null; final String endDate = null; final String filter = null; final String reservationId = null; final String rese...
@ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable<ReservationSummaryInner> function(String scope, Datagrain grain) { final String startDate = null; final String endDate = null; final String filter = null; final String reservationId = null; final String reservationOrderId = null; return new PagedIterable<>( ...
/** * Lists the reservations summaries for the defined scope daily or monthly grain. * * @param scope The scope associated with reservations summaries operations. This includes * '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for BillingAccount scope (legacy), and * '...
Lists the reservations summaries for the defined scope daily or monthly grain
list
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/consumption/azure-resourcemanager-consumption/src/main/java/com/azure/resourcemanager/consumption/implementation/ReservationsSummariesClientImpl.java", "license": "mit", "size": 53960 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.PagedIterable", "com.azure.resourcemanager.consumption.fluent.models.ReservationSummaryInner", "com.azure.resourcemanager.consumption.models.Datagrain" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.PagedIterable; import com.azure.resourcemanager.consumption.fluent.models.ReservationSummaryInner; import com.azure.resourcemanager.consumption.models.Datagrain;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.resourcemanager.consumption.fluent.models.*; import com.azure.resourcemanager.consumption.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
589,492
@Deprecated @JsonProperty("booleanDataTypeRefsetIdentifier") public String getBooleanDatatypeRefsetIdentifier() { return booleanDatatypeRefsetIdentifier; }
@JsonProperty(STR) String function() { return booleanDatatypeRefsetIdentifier; }
/** * The ID of the boolean datatype reference set identifier concept * * @return the booleanDatatypeRefsetIdentifier */
The ID of the boolean datatype reference set identifier concept
getBooleanDatatypeRefsetIdentifier
{ "repo_name": "b2ihealthcare/snow-owl", "path": "snomed/com.b2international.snowowl.snomed.datastore/src/com/b2international/snowowl/snomed/datastore/config/SnomedCoreConfiguration.java", "license": "apache-2.0", "size": 7645 }
[ "com.fasterxml.jackson.annotation.JsonProperty" ]
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.*;
[ "com.fasterxml.jackson" ]
com.fasterxml.jackson;
1,160,681
@XmlElementWrapper(name = "epcs") @XmlElement(name = "epc") public List<ElectronicProductCode> getEpcEntry() { return epcEntry; }
@XmlElementWrapper(name = "epcs") @XmlElement(name = "epc") List<ElectronicProductCode> function() { return epcEntry; }
/** * Method description * * * @return */
Method description
getEpcEntry
{ "repo_name": "Fosstrak/fosstrak-webadapters", "path": "src/main/java/org/fosstrak/webadapters/epcis/model/events/ObjectEvent.java", "license": "gpl-3.0", "size": 6128 }
[ "java.util.List", "javax.xml.bind.annotation.XmlElement", "javax.xml.bind.annotation.XmlElementWrapper", "org.fosstrak.webadapters.epcis.model.epc.ElectronicProductCode" ]
import java.util.List; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlElementWrapper; import org.fosstrak.webadapters.epcis.model.epc.ElectronicProductCode;
import java.util.*; import javax.xml.bind.annotation.*; import org.fosstrak.webadapters.epcis.model.epc.*;
[ "java.util", "javax.xml", "org.fosstrak.webadapters" ]
java.util; javax.xml; org.fosstrak.webadapters;
1,633,670
public final Rectangle mouseDragged(final MouseEvent e) { if (resizeDirection == RESIZE_NONE) { Point p = keepPointInsideOfDragArea(e); p.translate(-start.x, -start.y); Rectangle r = oldBounds.getBounds(); r.translate(p.x, p.y); return r; ...
final Rectangle function(final MouseEvent e) { if (resizeDirection == RESIZE_NONE) { Point p = keepPointInsideOfDragArea(e); p.translate(-start.x, -start.y); Rectangle r = oldBounds.getBounds(); r.translate(p.x, p.y); return r; } return getNewBounds(e); }
/** * This function is called when the mouse is dragged during * resizing/moving operation. It receives the <code>MOUSE_DRAGGED</code> * event and returns the new bounds of the component being dragged/resized. * * @param e the <code>MOUSE_DRAGGED</code> event * * @return the ne...
This function is called when the mouse is dragged during resizing/moving operation. It receives the <code>MOUSE_DRAGGED</code> event and returns the new bounds of the component being dragged/resized
mouseDragged
{ "repo_name": "skyHALud/codenameone", "path": "Ports/iOSPort/xmlvm/apache-harmony-6.0-src-r991881/classlib/modules/swing/src/main/java/common/org/apache/harmony/x/swing/ComponentDragImplHelper.java", "license": "gpl-2.0", "size": 15198 }
[ "java.awt.Point", "java.awt.Rectangle", "java.awt.event.MouseEvent" ]
import java.awt.Point; import java.awt.Rectangle; import java.awt.event.MouseEvent;
import java.awt.*; import java.awt.event.*;
[ "java.awt" ]
java.awt;
834,528
public Path getPathToAllLibsDir() { return getBinPath(); }
Path function() { return getBinPath(); }
/** * Returns the path that is the immediate parent of {@link #getPathToNativeLibsAssetsDir()} and * {@link #getPathToNativeLibsDir()}. */
Returns the path that is the immediate parent of <code>#getPathToNativeLibsAssetsDir()</code> and <code>#getPathToNativeLibsDir()</code>
getPathToAllLibsDir
{ "repo_name": "raviagarwal7/buck", "path": "src/com/facebook/buck/android/CopyNativeLibraries.java", "license": "apache-2.0", "size": 13826 }
[ "java.nio.file.Path" ]
import java.nio.file.Path;
import java.nio.file.*;
[ "java.nio" ]
java.nio;
2,220,383
try { ResourceBundle resourceBundle; resourceBundle = ResourceBundle.getBundle(bundleName, locale); return MessageFormat.format(resourceBundle.getString(key), param); } catch (MissingResourceException e) { return "!!" + key + "!!"; } }
try { ResourceBundle resourceBundle; resourceBundle = ResourceBundle.getBundle(bundleName, locale); return MessageFormat.format(resourceBundle.getString(key), param); } catch (MissingResourceException e) { return "!!" + key + "!!"; } }
/** * Return the corresponding value of a given key and string parameter. * @param key the given key * @param bundleName the bundle name * @param params the parameter * @return the corresponding key value */
Return the corresponding value of a given key and string parameter
getString
{ "repo_name": "jph-axelor/axelor-business-suite", "path": "axelor-account/src/main/java/com/axelor/apps/account/ebics/messages/Messages.java", "license": "agpl-3.0", "size": 5057 }
[ "java.text.MessageFormat", "java.util.MissingResourceException", "java.util.ResourceBundle" ]
import java.text.MessageFormat; import java.util.MissingResourceException; import java.util.ResourceBundle;
import java.text.*; import java.util.*;
[ "java.text", "java.util" ]
java.text; java.util;
647,117
public void render(Graphics g){ //draw box g.setColor(cBg); g.fillRect(x, y, width, height); //write string g.setColor(cText); g.drawString(getText(), x+4, y+14); }
void function(Graphics g){ g.setColor(cBg); g.fillRect(x, y, width, height); g.setColor(cText); g.drawString(getText(), x+4, y+14); }
/** * Render the button * @param g */
Render the button
render
{ "repo_name": "wcecil/colony-game", "path": "src/colonygame/ui/UIButton.java", "license": "cc0-1.0", "size": 1996 }
[ "java.awt.Graphics" ]
import java.awt.Graphics;
import java.awt.*;
[ "java.awt" ]
java.awt;
1,355,590
public int getPrecision(int column) throws SQLException { Field f = getField(column); if (f.getMysqlType().isDecimal()) { if (f.getDecimals() > 0) { return clampedGetLength(f) - 1 + getPrecisionAdjustFactor(f); } return clampedGetLength(f) + getP...
int function(int column) throws SQLException { Field f = getField(column); if (f.getMysqlType().isDecimal()) { if (f.getDecimals() > 0) { return clampedGetLength(f) - 1 + getPrecisionAdjustFactor(f); } return clampedGetLength(f) + getPrecisionAdjustFactor(f); } switch (f.getMysqlType()) { case TINYBLOB: case BLOB: case...
/** * What is a column's number of decimal digits. * * @param column * the first column is 1, the second is 2... * * @return the precision * * @throws SQLException * if a database access error occurs */
What is a column's number of decimal digits
getPrecision
{ "repo_name": "lamsfoundation/lams", "path": "3rdParty_sources/mysql-connector/com/mysql/cj/jdbc/result/ResultSetMetaData.java", "license": "gpl-2.0", "size": 20084 }
[ "com.mysql.cj.result.Field", "java.sql.SQLException" ]
import com.mysql.cj.result.Field; import java.sql.SQLException;
import com.mysql.cj.result.*; import java.sql.*;
[ "com.mysql.cj", "java.sql" ]
com.mysql.cj; java.sql;
261,710
@Function(name = "next", arity = 0, nativeId = SetIteratorPrototypeNext.class) public static Object next(ExecutionContext cx, Object thisValue) { if (!(thisValue instanceof SetIteratorObject)) { throw newTypeError(cx, Messages.Key.IncompatibleThis, "%SetIteratorP...
@Function(name = "next", arity = 0, nativeId = SetIteratorPrototypeNext.class) static Object function(ExecutionContext cx, Object thisValue) { if (!(thisValue instanceof SetIteratorObject)) { throw newTypeError(cx, Messages.Key.IncompatibleThis, STR, Type.of(thisValue).toString()); } SetIteratorObject o = (SetIteratorO...
/** * 23.2.5.2.1 %SetIteratorPrototype%.next( ) * * @param cx * the execution context * @param thisValue * the function this-value * @return the next iterator result object */
23.2.5.2.1 %SetIteratorPrototype%.next( )
next
{ "repo_name": "anba/es6draft", "path": "src/main/java/com/github/anba/es6draft/runtime/objects/collection/SetIteratorPrototype.java", "license": "mit", "size": 6551 }
[ "com.github.anba.es6draft.runtime.AbstractOperations", "com.github.anba.es6draft.runtime.ExecutionContext", "com.github.anba.es6draft.runtime.internal.Errors", "com.github.anba.es6draft.runtime.internal.Messages", "com.github.anba.es6draft.runtime.internal.Properties", "com.github.anba.es6draft.runtime.ob...
import com.github.anba.es6draft.runtime.AbstractOperations; import com.github.anba.es6draft.runtime.ExecutionContext; import com.github.anba.es6draft.runtime.internal.Errors; import com.github.anba.es6draft.runtime.internal.Messages; import com.github.anba.es6draft.runtime.internal.Properties; import com.github.anba.es...
import com.github.anba.es6draft.runtime.*; import com.github.anba.es6draft.runtime.internal.*; import com.github.anba.es6draft.runtime.objects.collection.*; import com.github.anba.es6draft.runtime.types.*; import java.util.*;
[ "com.github.anba", "java.util" ]
com.github.anba; java.util;
2,487,055
boolean loadReader(Configuration.Item item, Reader reader) throws InterruptedException { int count = 0; try { Log.d(TAG, "loadBlockedHosts: Reading: " + item.location); try (BufferedReader br = new BufferedReader(reader)) { String line; while (...
boolean loadReader(Configuration.Item item, Reader reader) throws InterruptedException { int count = 0; try { Log.d(TAG, STR + item.location); try (BufferedReader br = new BufferedReader(reader)) { String line; while ((line = br.readLine()) != null) { if (Thread.interrupted()) throw new InterruptedException(STR); Strin...
/** * Load a single file * * @param item The configuration item referencing the file * @param reader A reader to read lines from * @throws InterruptedException If thread was interrupted */
Load a single file
loadReader
{ "repo_name": "julian-klode/dns66", "path": "app/src/main/java/org/jak_linux/dns66/db/RuleDatabase.java", "license": "gpl-3.0", "size": 7267 }
[ "android.util.Log", "java.io.BufferedReader", "java.io.IOException", "java.io.Reader", "org.jak_linux.dns66.Configuration", "org.jak_linux.dns66.FileHelper" ]
import android.util.Log; import java.io.BufferedReader; import java.io.IOException; import java.io.Reader; import org.jak_linux.dns66.Configuration; import org.jak_linux.dns66.FileHelper;
import android.util.*; import java.io.*; import org.jak_linux.dns66.*;
[ "android.util", "java.io", "org.jak_linux.dns66" ]
android.util; java.io; org.jak_linux.dns66;
1,150,377
void setTableProperties(Properties tableProperties) { this.tableProperties = tableProperties; }
void setTableProperties(Properties tableProperties) { this.tableProperties = tableProperties; }
/** * Set the table properties for this table. * * @param tableProperties The new table properties. */
Set the table properties for this table
setTableProperties
{ "repo_name": "apache/derby", "path": "java/org.apache.derby.engine/org/apache/derby/impl/sql/compile/FromBaseTable.java", "license": "apache-2.0", "size": 160988 }
[ "java.util.Properties" ]
import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
2,490,631
public boolean checkCertificate(byte[] certificate) throws AS400SecurityException, ErrorCompletingRequestException, ExtendedIOException, InterruptedException, IOException, ObjectDoesNotExistException { int rc; if (null == certificate) ...
boolean function(byte[] certificate) throws AS400SecurityException, ErrorCompletingRequestException, ExtendedIOException, InterruptedException, IOException, ObjectDoesNotExistException { int rc; if (null == certificate) { Trace.log(Trace.ERROR, STR); throw new NullPointerException(STR); } if (isConnected() == false) co...
/** * Determines if the certificate is in the validation list. * * @param certificate The ASN.1 encoded X.509 certificate to search for in the validation list. * * @return true if the certificate is found in the validation list; false otherwise. * * @exception AS400SecurityException If a security ...
Determines if the certificate is in the validation list
checkCertificate
{ "repo_name": "devjunix/libjt400-java", "path": "src/com/ibm/as400/access/AS400CertificateVldlUtil.java", "license": "epl-1.0", "size": 17731 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
27,412
public HtmlData getInquiryUrlForGeneralLedgerEntryDocumentNumber(Entry entry);
HtmlData function(Entry entry);
/** * When handed a GeneralLedger, determines and returns the url which will point to the labor ledger entries "inquiry" related to the given entry. * The url will be linked via the document number * @param entry an entry to find a labor ledger inquiry on the document number was * @return the inquir...
When handed a GeneralLedger, determines and returns the url which will point to the labor ledger entries "inquiry" related to the given entry. The url will be linked via the document number
getInquiryUrlForGeneralLedgerEntryDocumentNumber
{ "repo_name": "bhutchinson/kfs", "path": "kfs-core/src/main/java/org/kuali/kfs/integration/ld/LaborModuleService.java", "license": "agpl-3.0", "size": 10774 }
[ "org.kuali.kfs.gl.businessobject.Entry", "org.kuali.rice.kns.lookup.HtmlData" ]
import org.kuali.kfs.gl.businessobject.Entry; import org.kuali.rice.kns.lookup.HtmlData;
import org.kuali.kfs.gl.businessobject.*; import org.kuali.rice.kns.lookup.*;
[ "org.kuali.kfs", "org.kuali.rice" ]
org.kuali.kfs; org.kuali.rice;
1,421,560
protected BusinessObjectDefinitionEntity createBusinessObjectDefinitionEntity(String namespaceCode, String businessObjectDefinitionName, String dataProviderName, String businessObjectDefinitionDescription) { return createBusinessObjectDefinitionEntity(namespaceCode, businessObjectDefinitionName,...
BusinessObjectDefinitionEntity function(String namespaceCode, String businessObjectDefinitionName, String dataProviderName, String businessObjectDefinitionDescription) { return createBusinessObjectDefinitionEntity(namespaceCode, businessObjectDefinitionName, dataProviderName, businessObjectDefinitionDescription, null);...
/** * Creates and persists a new business object definition. * * @return the newly created business object definition. */
Creates and persists a new business object definition
createBusinessObjectDefinitionEntity
{ "repo_name": "seoj/herd", "path": "herd-code/herd-dao/src/test/java/org/finra/herd/dao/AbstractDaoTest.java", "license": "apache-2.0", "size": 127305 }
[ "org.finra.herd.model.jpa.BusinessObjectDefinitionEntity" ]
import org.finra.herd.model.jpa.BusinessObjectDefinitionEntity;
import org.finra.herd.model.jpa.*;
[ "org.finra.herd" ]
org.finra.herd;
1,538,460
Node n1 = testRootNode.addNode(nodeName1, testNodeType); testRootNode.save(); assertEquals("Wrong node name.", n1.getName(), nodeName1); }
Node n1 = testRootNode.addNode(nodeName1, testNodeType); testRootNode.save(); assertEquals(STR, n1.getName(), nodeName1); }
/** * Tests if the name of the created node is correct. */
Tests if the name of the created node is correct
testName
{ "repo_name": "jalkanen/Priha", "path": "tests/tck/org/apache/jackrabbit/test/api/AddNodeTest.java", "license": "apache-2.0", "size": 7928 }
[ "javax.jcr.Node" ]
import javax.jcr.Node;
import javax.jcr.*;
[ "javax.jcr" ]
javax.jcr;
150,594
public synchronized <K, V> MappingType createMap(IDType fromIDType, IDType toIDType, boolean isMultiMap, boolean createReverseMap) { MappingType mappingType = MappingType.registerMappingType(fromIDType, toIDType, isMultiMap, createReverseMap); if (hashMappingType2Map.containsKey(mappingType)) return mappi...
synchronized <K, V> MappingType function(IDType fromIDType, IDType toIDType, boolean isMultiMap, boolean createReverseMap) { MappingType mappingType = MappingType.registerMappingType(fromIDType, toIDType, isMultiMap, createReverseMap); if (hashMappingType2Map.containsKey(mappingType)) return mappingType; if (!mappingGr...
/** * <p> * Adds a new map for the specified mapping type. To fill that map with elements, use the * {@link #addMapping(MappingType, Object, Object)} method. * </p> * <p> * </p> * * @param <K> * Type of Keys of the map * @param <V> * Type of Values of the map * @param fromI...
Adds a new map for the specified mapping type. To fill that map with elements, use the <code>#addMapping(MappingType, Object, Object)</code> method.
createMap
{ "repo_name": "Caleydo/caleydo", "path": "org.caleydo.core/src/org/caleydo/core/id/IDMappingManager.java", "license": "bsd-3-clause", "size": 31084 }
[ "java.util.HashMap", "java.util.Map", "org.caleydo.core.util.collection.MultiHashMap" ]
import java.util.HashMap; import java.util.Map; import org.caleydo.core.util.collection.MultiHashMap;
import java.util.*; import org.caleydo.core.util.collection.*;
[ "java.util", "org.caleydo.core" ]
java.util; org.caleydo.core;
2,691,111