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
private List<String> getBlogClientParts(Message message) throws MessagingException { String[] recipients = MailMessageHelper.getAllRecipients(message, false, false, MailBasedPostingHelper.getClientWideBlogEmailAddressSuffix("")); if (recipients == null || recipients.length == 0) {...
List<String> function(Message message) throws MessagingException { String[] recipients = MailMessageHelper.getAllRecipients(message, false, false, MailBasedPostingHelper.getClientWideBlogEmailAddressSuffix("")); if (recipients == null recipients.length == 0) { return null; } List<String> parts = new ArrayList<String>()...
/** * Filters recipients to those matching the email address pattern. * * @param message * the message to check for recipients * @return the 'blogNameId.clientId' parts from the email addresses or null if there are no * addresses matching the email pattern * ...
Filters recipients to those matching the email address pattern
getBlogClientParts
{ "repo_name": "Communote/communote-server", "path": "communote/core/src/main/java/com/communote/server/core/blog/NoteMultipleAddressesMailMessageWorker.java", "license": "apache-2.0", "size": 12485 }
[ "com.communote.server.core.blog.helper.MailBasedPostingHelper", "com.communote.server.core.mail.MailMessageHelper", "java.util.ArrayList", "java.util.List", "javax.mail.Message", "javax.mail.MessagingException" ]
import com.communote.server.core.blog.helper.MailBasedPostingHelper; import com.communote.server.core.mail.MailMessageHelper; import java.util.ArrayList; import java.util.List; import javax.mail.Message; import javax.mail.MessagingException;
import com.communote.server.core.blog.helper.*; import com.communote.server.core.mail.*; import java.util.*; import javax.mail.*;
[ "com.communote.server", "java.util", "javax.mail" ]
com.communote.server; java.util; javax.mail;
1,918,130
public int getMouseX() { return (int) ((Mouse.getX() * scaleX)+xoffset); }
int function() { return (int) ((Mouse.getX() * scaleX)+xoffset); }
/** * Get the x position of the mouse cursor * * @return The x position of the mouse cursor */
Get the x position of the mouse cursor
getMouseX
{ "repo_name": "ScottSWu/opsu", "path": "src/org/newdawn/slick/Input.java", "license": "gpl-3.0", "size": 45136 }
[ "org.lwjgl.input.Mouse" ]
import org.lwjgl.input.Mouse;
import org.lwjgl.input.*;
[ "org.lwjgl.input" ]
org.lwjgl.input;
1,437,576
void stopRuntime(final RuntimeKey runtimeKey);
void stopRuntime(final RuntimeKey runtimeKey);
/** * Stops a runtime. * @param runtimeKey the key of the runtime to stop. */
Stops a runtime
stopRuntime
{ "repo_name": "adrielparedes/guvnor", "path": "guvnor-ala/guvnor-ala-ui/guvnor-ala-ui-api/src/main/java/org/guvnor/ala/ui/service/RuntimeService.java", "license": "apache-2.0", "size": 4438 }
[ "org.guvnor.ala.ui.model.RuntimeKey" ]
import org.guvnor.ala.ui.model.RuntimeKey;
import org.guvnor.ala.ui.model.*;
[ "org.guvnor.ala" ]
org.guvnor.ala;
327,546
boolean evaluation = false; List<Selector.Filter> filters = this.getFilters(); for (Iterator<Selector.Filter> iter = filters.iterator(); (false == evaluation) && iter.hasNext(); ) { Selector.Filter filter = iter.next(); evaluation |= filter.eval(node); } return eva...
boolean evaluation = false; List<Selector.Filter> filters = this.getFilters(); for (Iterator<Selector.Filter> iter = filters.iterator(); (false == evaluation) && iter.hasNext(); ) { Selector.Filter filter = iter.next(); evaluation = filter.eval(node); } return evaluation; }
/** * Determines if the given node matches all the filters in the composition. * @param node the node under evaluation. * @return {@code true} if the node matches all the filters, * {@code false} otherwise. */
Determines if the given node matches all the filters in the composition
eval
{ "repo_name": "nikgoodley-ibboost/forklabs-javaxpcom", "path": "src/main/java/ca/forklabs/javaxpcom/select/filter/OrFilter.java", "license": "gpl-2.0", "size": 2424 }
[ "ca.forklabs.javaxpcom.select.Selector", "java.util.Iterator", "java.util.List" ]
import ca.forklabs.javaxpcom.select.Selector; import java.util.Iterator; import java.util.List;
import ca.forklabs.javaxpcom.select.*; import java.util.*;
[ "ca.forklabs.javaxpcom", "java.util" ]
ca.forklabs.javaxpcom; java.util;
938,929
void generateLeafNode(BlockPos pos) { for (int i = 0; i < this.leafDistanceLimit; ++i) { this.crosSection(pos.up(i), this.leafSize(i), leaves); } }
void generateLeafNode(BlockPos pos) { for (int i = 0; i < this.leafDistanceLimit; ++i) { this.crosSection(pos.up(i), this.leafSize(i), leaves); } }
/** * Generates the leaves surrounding an individual entry in the leafNodes list. */
Generates the leaves surrounding an individual entry in the leafNodes list
generateLeafNode
{ "repo_name": "kenijey/harshencastle", "path": "src/main/java/kenijey/harshenuniverse/base/BaseLargeTreeGenerator.java", "license": "epl-1.0", "size": 12678 }
[ "net.minecraft.util.math.BlockPos" ]
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.*;
[ "net.minecraft.util" ]
net.minecraft.util;
883,253
@Test public void onlySuggestAssertsForVoids() { testProxy.testMethodReturnsString(); String report = suggestedAssertsReport.createReport(this, getCurrentScenario().getObservedInvocations()); assertFalse(report.contains("testMock.assertInvoked().testMethodReturnsString()")); ...
void function() { testProxy.testMethodReturnsString(); String report = suggestedAssertsReport.createReport(this, getCurrentScenario().getObservedInvocations()); assertFalse(report.contains(STR)); } public static interface TestInterface {
/** * Methods that return something are not included in the report */
Methods that return something are not included in the report
onlySuggestAssertsForVoids
{ "repo_name": "arteam/unitils", "path": "unitils-test/src/test/java/org/unitils/mock/report/impl/SuggestedAssertsReportTest.java", "license": "apache-2.0", "size": 4206 }
[ "junit.framework.Assert", "org.unitils.mock.core.MockObject" ]
import junit.framework.Assert; import org.unitils.mock.core.MockObject;
import junit.framework.*; import org.unitils.mock.core.*;
[ "junit.framework", "org.unitils.mock" ]
junit.framework; org.unitils.mock;
2,845,607
private UserIdentity doSamlLogin(String username, String samlAssertionData) { try { Document samlAssertion = DocumentUtil.getDocument(samlAssertionData); SAMLAssertionParser parser = new SAMLAssertionParser(); XMLEventReader xmlEventReader = XMLInputFactory.newInstance()....
UserIdentity function(String username, String samlAssertionData) { try { Document samlAssertion = DocumentUtil.getDocument(samlAssertionData); SAMLAssertionParser parser = new SAMLAssertionParser(); XMLEventReader xmlEventReader = XMLInputFactory.newInstance().createXMLEventReader(new StringReader(samlAssertionData)); ...
/** * Performs the SAML login by parsing the saml assertion and processing it. * @param username * @param samlAssertionData */
Performs the SAML login by parsing the saml assertion and processing it
doSamlLogin
{ "repo_name": "objectiser/overlord-commons", "path": "overlord-commons-auth-jetty8/src/main/java/org/overlord/commons/auth/jetty8/SAMLBearerTokenLoginService.java", "license": "apache-2.0", "size": 10482 }
[ "java.io.IOException", "java.io.StringReader", "java.security.KeyPair", "javax.xml.stream.XMLEventReader", "javax.xml.stream.XMLInputFactory", "org.eclipse.jetty.server.AbstractHttpConnection", "org.eclipse.jetty.server.UserIdentity", "org.overlord.commons.auth.util.SAMLBearerTokenUtil", "org.picket...
import java.io.IOException; import java.io.StringReader; import java.security.KeyPair; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; import org.eclipse.jetty.server.AbstractHttpConnection; import org.eclipse.jetty.server.UserIdentity; import org.overlord.commons.auth.util.SAMLBearerTo...
import java.io.*; import java.security.*; import javax.xml.stream.*; import org.eclipse.jetty.server.*; import org.overlord.commons.auth.util.*; import org.picketlink.identity.federation.core.parsers.saml.*; import org.picketlink.identity.federation.core.saml.v2.util.*; import org.picketlink.identity.federation.saml.v2...
[ "java.io", "java.security", "javax.xml", "org.eclipse.jetty", "org.overlord.commons", "org.picketlink.identity", "org.w3c.dom" ]
java.io; java.security; javax.xml; org.eclipse.jetty; org.overlord.commons; org.picketlink.identity; org.w3c.dom;
313,968
private ConceptName getConceptName(CWE cwe) throws HL7Exception { ST altIdentifier = cwe.getAlternateIdentifier(); ID altCodingSystem = cwe.getNameOfAlternateCodingSystem(); return getConceptName(altIdentifier, altCodingSystem); }
ConceptName function(CWE cwe) throws HL7Exception { ST altIdentifier = cwe.getAlternateIdentifier(); ID altCodingSystem = cwe.getNameOfAlternateCodingSystem(); return getConceptName(altIdentifier, altCodingSystem); }
/** * Derive a concept name from the CWE component of an hl7 message. * * @param cwe * @return * @throws HL7Exception */
Derive a concept name from the CWE component of an hl7 message
getConceptName
{ "repo_name": "milankarunarathne/openmrs-core", "path": "api/src/main/java/org/openmrs/hl7/handler/ORUR01Handler.java", "license": "mpl-2.0", "size": 47747 }
[ "ca.uhn.hl7v2.HL7Exception", "org.openmrs.ConceptName" ]
import ca.uhn.hl7v2.HL7Exception; import org.openmrs.ConceptName;
import ca.uhn.hl7v2.*; import org.openmrs.*;
[ "ca.uhn.hl7v2", "org.openmrs" ]
ca.uhn.hl7v2; org.openmrs;
2,503,424
public static int selectColor(){ Frame owner = (sketchApplet == null) ? null : sketchApplet.frame; if(chooser == null){ chooser = new JColorChooser(); AbstractColorChooserPanel[] oldPanels = chooser.getChooserPanels(); // Do not assume what panels are present LinkedList<AbstractColorChooserPanel> pan...
static int function(){ Frame owner = (sketchApplet == null) ? null : sketchApplet.frame; if(chooser == null){ chooser = new JColorChooser(); AbstractColorChooserPanel[] oldPanels = chooser.getChooserPanels(); LinkedList<AbstractColorChooserPanel> panels = new LinkedList<AbstractColorChooserPanel>(); for(AbstractColorCh...
/** * This will open a version of the Java Swing color chooser dialog. The dialog's * UI is dependent on the OS and JVM implementation running. <br> * * If you click on Cancel then it returns the last color previously selected. * * @return the ARGB colour as a 32 bit integer (as used in Processing). */
This will open a version of the Java Swing color chooser dialog. The dialog's UI is dependent on the OS and JVM implementation running. If you click on Cancel then it returns the last color previously selected
selectColor
{ "repo_name": "mjs513/FreeIMU-Updates", "path": "Experimental/Processing/Processing Libraries/G4P/src/g4p_controls/G4P.java", "license": "mit", "size": 27510 }
[ "java.awt.Frame", "java.util.LinkedList", "javax.swing.JColorChooser", "javax.swing.colorchooser.AbstractColorChooserPanel" ]
import java.awt.Frame; import java.util.LinkedList; import javax.swing.JColorChooser; import javax.swing.colorchooser.AbstractColorChooserPanel;
import java.awt.*; import java.util.*; import javax.swing.*; import javax.swing.colorchooser.*;
[ "java.awt", "java.util", "javax.swing" ]
java.awt; java.util; javax.swing;
632,347
protected void loadVoteWeights() throws ProcessorException { String filePath = getVoteWeightsPath(); try { voteWeights = VoteWeights.loadVoteWeights(filePath,recognizers); } catch (IOException e) { e.printStackTrace(); throw new ProcessorException(e.getMessage()); } }
void function() throws ProcessorException { String filePath = getVoteWeightsPath(); try { voteWeights = VoteWeights.loadVoteWeights(filePath,recognizers); } catch (IOException e) { e.printStackTrace(); throw new ProcessorException(e.getMessage()); } }
/** * Loads all the necessary weights * to allow NER voting. * * @throws ProcessorException * Problem while loading the vote weights. */
Loads all the necessary weights to allow NER voting
loadVoteWeights
{ "repo_name": "CompNet/TranspoloSearch", "path": "src/fr/univavignon/transpolosearch/processing/combiner/AbstractCombinerDelegateRecognizer.java", "license": "gpl-2.0", "size": 21195 }
[ "fr.univavignon.transpolosearch.processing.ProcessorException", "java.io.IOException" ]
import fr.univavignon.transpolosearch.processing.ProcessorException; import java.io.IOException;
import fr.univavignon.transpolosearch.processing.*; import java.io.*;
[ "fr.univavignon.transpolosearch", "java.io" ]
fr.univavignon.transpolosearch; java.io;
33,010
public DateFormat getDateFormat() { return ((DateFormulaCell) getReadFormula()).getDateFormat(); }
DateFormat function() { return ((DateFormulaCell) getReadFormula()).getDateFormat(); }
/** * Gets the DateFormat used to format this cell. This is the java * equivalent of the Excel format * * @return the DateFormat used to format the cell */
Gets the DateFormat used to format this cell. This is the java equivalent of the Excel format
getDateFormat
{ "repo_name": "stefandmn/AREasy", "path": "src/java/org/areasy/common/parser/excel/write/biff/ReadDateFormulaRecord.java", "license": "lgpl-3.0", "size": 1827 }
[ "java.text.DateFormat", "org.areasy.common.parser.excel.DateFormulaCell" ]
import java.text.DateFormat; import org.areasy.common.parser.excel.DateFormulaCell;
import java.text.*; import org.areasy.common.parser.excel.*;
[ "java.text", "org.areasy.common" ]
java.text; org.areasy.common;
1,654,478
public OMetadata getMetadata();
OMetadata function();
/** * Return the OMetadata instance. Cannot be null. * * @return The OMetadata instance. */
Return the OMetadata instance. Cannot be null
getMetadata
{ "repo_name": "nengxu/OrientDB", "path": "core/src/main/java/com/orientechnologies/orient/core/db/ODatabaseComplex.java", "license": "apache-2.0", "size": 15385 }
[ "com.orientechnologies.orient.core.metadata.OMetadata" ]
import com.orientechnologies.orient.core.metadata.OMetadata;
import com.orientechnologies.orient.core.metadata.*;
[ "com.orientechnologies.orient" ]
com.orientechnologies.orient;
691,805
private final Query getBeforeDateSqlQuery() { final Query query; query = entityManager.createQuery(findBeforeDateSql); query.setParameter("date", sqlDate); return query; }
final Query function() { final Query query; query = entityManager.createQuery(findBeforeDateSql); query.setParameter("date", sqlDate); return query; }
/** * Returns the query for the test. * * @return the query for the test */
Returns the query for the test
getBeforeDateSqlQuery
{ "repo_name": "Bernardo-MG/jpa-example", "path": "src/test/java/com/bernardomg/example/jpa/test/integration/temporal/date/ITDateEntityQueryJpql.java", "license": "mit", "size": 11746 }
[ "javax.persistence.Query" ]
import javax.persistence.Query;
import javax.persistence.*;
[ "javax.persistence" ]
javax.persistence;
2,891,197
public void zoomRangeAxes(double factor, PlotRenderingInfo info, Point2D source, boolean useAnchor) { // get the source coordinate - this plot has always a VERTICAL // orientation final double sourceX = source.getX(); for (int axisIdx = 0; axisIdx < get...
void function(double factor, PlotRenderingInfo info, Point2D source, boolean useAnchor) { final double sourceX = source.getX(); for (int axisIdx = 0; axisIdx < getAxisCount(); axisIdx++) { final ValueAxis axis = getAxis(axisIdx); if (axis != null) { if (useAnchor) { double anchorX = axis.java2DToValue(sourceX, info.get...
/** * Multiplies the range on the range axis by the specified factor. * * @param factor the zoom factor. * @param info the plot rendering info. * @param source the source point (in Java2D space). * @param useAnchor use source point as zoom anchor? * * @see #zoomDomainAxes(dou...
Multiplies the range on the range axis by the specified factor
zoomRangeAxes
{ "repo_name": "JSansalone/JFreeChart", "path": "source/org/jfree/chart/plot/PolarPlot.java", "license": "lgpl-2.1", "size": 68880 }
[ "java.awt.geom.Point2D", "org.jfree.chart.axis.ValueAxis", "org.jfree.ui.RectangleEdge" ]
import java.awt.geom.Point2D; import org.jfree.chart.axis.ValueAxis; import org.jfree.ui.RectangleEdge;
import java.awt.geom.*; import org.jfree.chart.axis.*; import org.jfree.ui.*;
[ "java.awt", "org.jfree.chart", "org.jfree.ui" ]
java.awt; org.jfree.chart; org.jfree.ui;
2,870,715
private boolean examineCSR(File fCSRFile) { if (fCSRFile == null) { fCSRFile = chooseExamineCSRFile(); } if (fCSRFile == null) { return false; } // Get the CSR contained within the file PKCS10CertificationRequest csr = openCSR(fCSRFile); m_lastDir.updateLastDir(fCSRFile); // If a CSR is...
boolean function(File fCSRFile) { if (fCSRFile == null) { fCSRFile = chooseExamineCSRFile(); } if (fCSRFile == null) { return false; } PKCS10CertificationRequest csr = openCSR(fCSRFile); m_lastDir.updateLastDir(fCSRFile); if (csr != null) { try { DViewCSR dViewCSR = new DViewCSR(this, MessageFormat.format(RB.getString(...
/** * Let the user examine the contents of a CSR file. * * @param fCSRFile File to load the CSR from; if <code>null</code>, prompt user * @return True if the user was able to examine the CSR file, false otherwise */
Let the user examine the contents of a CSR file
examineCSR
{ "repo_name": "scop/portecle", "path": "src/main/net/sf/portecle/FPortecle.java", "license": "gpl-2.0", "size": 189435 }
[ "java.io.File", "java.text.MessageFormat", "net.sf.portecle.crypto.CryptoException", "net.sf.portecle.gui.SwingHelper", "net.sf.portecle.gui.error.DThrowable", "org.bouncycastle.pkcs.PKCS10CertificationRequest" ]
import java.io.File; import java.text.MessageFormat; import net.sf.portecle.crypto.CryptoException; import net.sf.portecle.gui.SwingHelper; import net.sf.portecle.gui.error.DThrowable; import org.bouncycastle.pkcs.PKCS10CertificationRequest;
import java.io.*; import java.text.*; import net.sf.portecle.crypto.*; import net.sf.portecle.gui.*; import net.sf.portecle.gui.error.*; import org.bouncycastle.pkcs.*;
[ "java.io", "java.text", "net.sf.portecle", "org.bouncycastle.pkcs" ]
java.io; java.text; net.sf.portecle; org.bouncycastle.pkcs;
2,862,628
private String addParamsToUrl(String url, List<NameValuePair> nameValuePairs) throws UnsupportedEncodingException { if (nameValuePairs == null || nameValuePairs.isEmpty()) { return url; } final StringBuffer newUrl = new StringBuffer(url); newUrl.append(url.co...
String function(String url, List<NameValuePair> nameValuePairs) throws UnsupportedEncodingException { if (nameValuePairs == null nameValuePairs.isEmpty()) { return url; } final StringBuffer newUrl = new StringBuffer(url); newUrl.append(url.contains("?") ? '&' : '?'); for (NameValuePair param : nameValuePairs) { newUrl....
/** * Adds the parameters to the given url. * * @param url the url * @param nameValuePairs the name value pairs to be added to the url * @return the url with added parameters * @throws UnsupportedEncodingException */
Adds the parameters to the given url
addParamsToUrl
{ "repo_name": "photo/mobile-android", "path": "common/src/com/trovebox/android/common/net/ApiBase.java", "license": "apache-2.0", "size": 11153 }
[ "java.io.UnsupportedEncodingException", "java.net.URLEncoder", "java.util.List", "org.apache.http.NameValuePair" ]
import java.io.UnsupportedEncodingException; import java.net.URLEncoder; import java.util.List; import org.apache.http.NameValuePair;
import java.io.*; import java.net.*; import java.util.*; import org.apache.http.*;
[ "java.io", "java.net", "java.util", "org.apache.http" ]
java.io; java.net; java.util; org.apache.http;
1,950,525
public boolean allowBucketDrain(ItemStack stack);
boolean function(ItemStack stack);
/** * Called to determine if the {@link IFluidHandler} should be drained by buckets. * * @param stack The {@link ItemStack} being used to drain the IFluidHandler * @return True if the IFluidHandler is allowed to be drained with <tt>stack</tt> */
Called to determine if the <code>IFluidHandler</code> should be drained by buckets
allowBucketDrain
{ "repo_name": "Mazdallier/Aura-Cascade", "path": "src/api/java/cofh/api/fluid/ITankContainerBucketable.java", "license": "mit", "size": 1020 }
[ "net.minecraft.item.ItemStack" ]
import net.minecraft.item.ItemStack;
import net.minecraft.item.*;
[ "net.minecraft.item" ]
net.minecraft.item;
1,140,399
public static boolean deleteFile(String fileName, String inputDirectory){ // Now delete the old text file since it is no longer needed boolean success = false; File f = new File(inputDirectory+File.separator+fileName); success = f.delete(); if (!success) logger.error("Error trying to delete file " + ...
static boolean function(String fileName, String inputDirectory){ boolean success = false; File f = new File(inputDirectory+File.separator+fileName); success = f.delete(); if (!success) logger.error(STR + fileName); return success; }
/** * delete downloaded file * @return true is delete is successful. */
delete downloaded file
deleteFile
{ "repo_name": "NCIP/stats-application-commons", "path": "src/gov/nih/nci/caintegrator/application/download/DownloadZipHelper.java", "license": "bsd-3-clause", "size": 4067 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
1,099,123
default void removeReplicationPeer(String peerId) throws IOException { get(removeReplicationPeerAsync(peerId), getSyncWaitTimeout(), TimeUnit.MILLISECONDS); }
default void removeReplicationPeer(String peerId) throws IOException { get(removeReplicationPeerAsync(peerId), getSyncWaitTimeout(), TimeUnit.MILLISECONDS); }
/** * Remove a peer and stop the replication. * @param peerId a short name that identifies the peer * @throws IOException if a remote or network exception occurs */
Remove a peer and stop the replication
removeReplicationPeer
{ "repo_name": "ChinmaySKulkarni/hbase", "path": "hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java", "license": "apache-2.0", "size": 101053 }
[ "java.io.IOException", "java.util.concurrent.TimeUnit", "org.apache.hadoop.hbase.util.FutureUtils" ]
import java.io.IOException; import java.util.concurrent.TimeUnit; import org.apache.hadoop.hbase.util.FutureUtils;
import java.io.*; import java.util.concurrent.*; import org.apache.hadoop.hbase.util.*;
[ "java.io", "java.util", "org.apache.hadoop" ]
java.io; java.util; org.apache.hadoop;
2,553,385
public static <K, V> Map<K, V> toSynchronizedMap(final Map<K, V> map) { final Map<K, V> synch = toSynchronizedMap(); if (map != null) { synch.putAll(map); } return synch; }
static <K, V> Map<K, V> function(final Map<K, V> map) { final Map<K, V> synch = toSynchronizedMap(); if (map != null) { synch.putAll(map); } return synch; }
/** * Build a synchronized from a map. * @param <K> the key map type. * @param <V> the value map type. * @param map the map. * @return HashMap. */
Build a synchronized from a map
toSynchronizedMap
{ "repo_name": "qjafcunuas/jbromo", "path": "jbromo-lib/src/main/java/org/jbromo/common/MapUtil.java", "license": "apache-2.0", "size": 5031 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,252,525
Set<Integer> getSequenceIdsByPeptideSequence(String peptideSequence);
Set<Integer> getSequenceIdsByPeptideSequence(String peptideSequence);
/** * Returns a set of sequence IDs for a given peptide sequence * * @param peptideSequence * @return a set of sequence IDs */
Returns a set of sequence IDs for a given peptide sequence
getSequenceIdsByPeptideSequence
{ "repo_name": "compomics/compomics-sigpep", "path": "sigpep-app/src/main/java/com/compomics/sigpep/PeptideGenerator.java", "license": "apache-2.0", "size": 8810 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
1,096,653
public void configure(Properties props) { String size = props.getProperty("cache-size"); if (size == null) { size = props.getProperty("size"); } if (size != null) { cacheSize = Integer.parseInt(size); } }
void function(Properties props) { String size = props.getProperty(STR); if (size == null) { size = props.getProperty("size"); } if (size != null) { cacheSize = Integer.parseInt(size); } }
/** * Configures the cache * * @param props Optionally can contain properties [reference-type=WEAK|SOFT|STRONG] */
Configures the cache
configure
{ "repo_name": "cavajtennis/ibatis", "path": "java/mapper/mapper2/src/com/ibatis/sqlmap/engine/cache/lru/LruCacheController.java", "license": "apache-2.0", "size": 2942 }
[ "java.util.Properties" ]
import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
1,790,950
public static boolean saveDoc(Class clazz, String xmlPath, String encoding, final Document doc) { TransformerFactory xf = TransformerFactory.newInstance(); xf.setAttribute("indent-number", new Integer(1)); boolean success = false; try { Transformer xformer = xf.newTransf...
static boolean function(Class clazz, String xmlPath, String encoding, final Document doc) { TransformerFactory xf = TransformerFactory.newInstance(); xf.setAttribute(STR, new Integer(1)); boolean success = false; try { Transformer xformer = xf.newTransformer(); xformer.setOutputProperty(OutputKeys.METHOD, "xml"); xform...
/** * Saves XML files to disk * * @param clazz the class this method is invoked from * @param xmlPath the full path to save the XML to * @param encoding to encoding, such as "UTF-8", to encode the file with * @param doc the document to save * */
Saves XML files to disk
saveDoc
{ "repo_name": "raman-bt/autopsy", "path": "Core/src/org/sleuthkit/autopsy/coreutils/XMLUtil.java", "license": "apache-2.0", "size": 8031 }
[ "java.io.File", "java.io.FileNotFoundException", "java.io.FileOutputStream", "java.io.IOException", "java.io.OutputStreamWriter", "java.io.UnsupportedEncodingException", "java.util.logging.Level", "javax.xml.transform.OutputKeys", "javax.xml.transform.Result", "javax.xml.transform.Transformer", ...
import java.io.File; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStreamWriter; import java.io.UnsupportedEncodingException; import java.util.logging.Level; import javax.xml.transform.OutputKeys; import javax.xml.transform.Result; import javax.x...
import java.io.*; import java.util.logging.*; import javax.xml.transform.*; import javax.xml.transform.dom.*; import javax.xml.transform.stream.*; import org.w3c.dom.*;
[ "java.io", "java.util", "javax.xml", "org.w3c.dom" ]
java.io; java.util; javax.xml; org.w3c.dom;
2,886,141
public static DateTime copy(DateTime value) { if (value == null) { return null; } else { return new DateTime(value.getMillis(), DateTimeZone.UTC); } }
static DateTime function(DateTime value) { if (value == null) { return null; } else { return new DateTime(value.getMillis(), DateTimeZone.UTC); } }
/** * Null-safe method of copying a DateTime * <br> * NOTE: The timestamp also should be in UTC. * @return A UTC DateTime */
Null-safe method of copying a DateTime
copy
{ "repo_name": "twitter/cloudhopper-commons", "path": "ch-commons-util/src/main/java/com/cloudhopper/commons/util/DateTimeUtil.java", "license": "apache-2.0", "size": 15924 }
[ "org.joda.time.DateTime", "org.joda.time.DateTimeZone" ]
import org.joda.time.DateTime; import org.joda.time.DateTimeZone;
import org.joda.time.*;
[ "org.joda.time" ]
org.joda.time;
1,891,076
EClass getResourceImport();
EClass getResourceImport();
/** * Returns the meta object for class '{@link org.eclipse.xtext.parser.epatch.epatchTestLanguage.ResourceImport <em>Resource Import</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>Resource Import</em>'. * @see org.eclipse.xtext.parser.epatch.epatchTest...
Returns the meta object for class '<code>org.eclipse.xtext.parser.epatch.epatchTestLanguage.ResourceImport Resource Import</code>'.
getResourceImport
{ "repo_name": "miklossy/xtext-core", "path": "org.eclipse.xtext.tests/src-gen/org/eclipse/xtext/parser/epatch/epatchTestLanguage/EpatchTestLanguagePackage.java", "license": "epl-1.0", "size": 81411 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
199,342
public TileEntity createNewTileEntity(World worldIn, int meta) { return new TileEntityMobSpawner(); }
TileEntity function(World worldIn, int meta) { return new TileEntityMobSpawner(); }
/** * Returns a new instance of a block's tile entity class. Called on placing the block. */
Returns a new instance of a block's tile entity class. Called on placing the block
createNewTileEntity
{ "repo_name": "lucemans/ShapeClient-SRC", "path": "net/minecraft/block/BlockMobSpawner.java", "license": "mpl-2.0", "size": 2454 }
[ "net.minecraft.tileentity.TileEntity", "net.minecraft.tileentity.TileEntityMobSpawner", "net.minecraft.world.World" ]
import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntityMobSpawner; import net.minecraft.world.World;
import net.minecraft.tileentity.*; import net.minecraft.world.*;
[ "net.minecraft.tileentity", "net.minecraft.world" ]
net.minecraft.tileentity; net.minecraft.world;
1,937,638
public Map<Direction, Sprite> getGhostSprite(GhostColor color) { assert color != null; String resource = "/sprite/ghost_" + color.name().toLowerCase() + ".png"; return directionSprite(resource, GHOST_ANIMATION_FRAMES); }
Map<Direction, Sprite> function(GhostColor color) { assert color != null; String resource = STR + color.name().toLowerCase() + ".png"; return directionSprite(resource, GHOST_ANIMATION_FRAMES); }
/** * Returns a map of animated ghost sprites for all directions. * * @param color * The colour of the ghost. * @return The Sprite for the ghost. */
Returns a map of animated ghost sprites for all directions
getGhostSprite
{ "repo_name": "Krunsh07/jpacman-framework", "path": "src/main/java/nl/tudelft/jpacman/sprite/PacManSprites.java", "license": "apache-2.0", "size": 7053 }
[ "java.util.Map", "nl.tudelft.jpacman.board.Direction", "nl.tudelft.jpacman.npc.ghost.GhostColor" ]
import java.util.Map; import nl.tudelft.jpacman.board.Direction; import nl.tudelft.jpacman.npc.ghost.GhostColor;
import java.util.*; import nl.tudelft.jpacman.board.*; import nl.tudelft.jpacman.npc.ghost.*;
[ "java.util", "nl.tudelft.jpacman" ]
java.util; nl.tudelft.jpacman;
2,867,647
public static FunctionLib[] loadFromDirectory(Resource dir, Identification id) throws FunctionLibException { if(!dir.isDirectory())return new FunctionLib[0]; ArrayList<FunctionLib> arr=new ArrayList<FunctionLib>(); Resource[] files=dir.listResources(new ExtensionResourceFilter("fld")); for(int i=0;i<files...
static FunctionLib[] function(Resource dir, Identification id) throws FunctionLibException { if(!dir.isDirectory())return new FunctionLib[0]; ArrayList<FunctionLib> arr=new ArrayList<FunctionLib>(); Resource[] files=dir.listResources(new ExtensionResourceFilter("fld")); for(int i=0;i<files.length;i++) { if(files[i].isF...
/** * Laedt mehrere FunctionLib's die innerhalb eines Verzeichnisses liegen. * @param dir Verzeichnis im dem die FunctionLib's liegen. * @param saxParser Definition des Sax Parser mit dem die FunctionLib's eingelesen werden sollen. * @return FunctionLib's als Array * @throws FunctionLibException */
Laedt mehrere FunctionLib's die innerhalb eines Verzeichnisses liegen
loadFromDirectory
{ "repo_name": "lucee/unoffical-Lucee-no-jre", "path": "source/java/core/src/lucee/transformer/library/function/FunctionLibFactory.java", "license": "lgpl-2.1", "size": 15103 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
2,644,722
protected void emit_iHubConn_WSTerminalRuleCall_4_q(EObject semanticObject, ISynNavigable transition, List<INode> nodes) { acceptNodes(transition, nodes); }
void function(EObject semanticObject, ISynNavigable transition, List<INode> nodes) { acceptNodes(transition, nodes); }
/** * Syntax: * WS? */
Syntax: WS
emit_iHubConn_WSTerminalRuleCall_4_q
{ "repo_name": "cooked/NDT", "path": "sc.ndt.editor.bmodes.bmi/src-gen/sc/ndt/editor/bmodes/serializer/BmodesbmiSyntacticSequencer.java", "license": "gpl-3.0", "size": 75631 }
[ "java.util.List", "org.eclipse.emf.ecore.EObject", "org.eclipse.xtext.nodemodel.INode", "org.eclipse.xtext.serializer.analysis.ISyntacticSequencerPDAProvider" ]
import java.util.List; import org.eclipse.emf.ecore.EObject; import org.eclipse.xtext.nodemodel.INode; import org.eclipse.xtext.serializer.analysis.ISyntacticSequencerPDAProvider;
import java.util.*; import org.eclipse.emf.ecore.*; import org.eclipse.xtext.nodemodel.*; import org.eclipse.xtext.serializer.analysis.*;
[ "java.util", "org.eclipse.emf", "org.eclipse.xtext" ]
java.util; org.eclipse.emf; org.eclipse.xtext;
2,356,547
public void userIsAdminOrPrivileged(final String classId, final String username) throws ServiceException { try { if((! Clazz.Role.PRIVILEGED.equals(userClassQueries.getUserClassRole(classId, username))) && (! userQueries.userIsAdmin(username))) { throw new ServiceException( ErrorCode.CLAS...
void function(final String classId, final String username) throws ServiceException { try { if((! Clazz.Role.PRIVILEGED.equals(userClassQueries.getUserClassRole(classId, username))) && (! userQueries.userIsAdmin(username))) { throw new ServiceException( ErrorCode.CLASS_INSUFFICIENT_PERMISSIONS, STR); } } catch(DataAcces...
/** * Checks if the user is privileged in the class or an admin. * * @param classId The class to check if the user is privileged. * * @param username The user to check if they are privileged in the class. * * @throws ServiceException Thrown if there is an error or if the user is * not privile...
Checks if the user is privileged in the class or an admin
userIsAdminOrPrivileged
{ "repo_name": "HaiJiaoXinHeng/server-1", "path": "src/org/ohmage/service/UserClassServices.java", "license": "apache-2.0", "size": 12825 }
[ "org.ohmage.annotator.Annotator", "org.ohmage.domain.Clazz", "org.ohmage.exception.DataAccessException", "org.ohmage.exception.ServiceException" ]
import org.ohmage.annotator.Annotator; import org.ohmage.domain.Clazz; import org.ohmage.exception.DataAccessException; import org.ohmage.exception.ServiceException;
import org.ohmage.annotator.*; import org.ohmage.domain.*; import org.ohmage.exception.*;
[ "org.ohmage.annotator", "org.ohmage.domain", "org.ohmage.exception" ]
org.ohmage.annotator; org.ohmage.domain; org.ohmage.exception;
1,895,671
if (values == null || values.length == 0) { throw new IllegalArgumentException("Empty list of expressions for In predicate"); } // temporary set to remove duplicate values HashSet<TypedExpression> tmp = new HashSet<TypedExpression>(); // copy and sort expressions, check that all expressions are of...
if (values == null values.length == 0) { throw new IllegalArgumentException(STR); } HashSet<TypedExpression> tmp = new HashSet<TypedExpression>(); DataType dtype = null; for (int i = 0; i < values.length; i++) { if (dtype != null && !dtype.equals(values[i].dataType())) { throw new IllegalArgumentException(STR + dtype +...
/** * Clean up typed expressions in array, check duplicate types and sort array in * ascending order to ensure search property. */
Clean up typed expressions in array, check duplicate types and sort array in ascending order to ensure search property
cleanUp
{ "repo_name": "sadikovi/riff", "path": "format/src/main/java/com/github/sadikovi/riff/tree/node/In.java", "license": "mit", "size": 6259 }
[ "com.github.sadikovi.riff.tree.TypedExpression", "java.util.Arrays", "java.util.HashSet", "org.apache.spark.sql.types.DataType" ]
import com.github.sadikovi.riff.tree.TypedExpression; import java.util.Arrays; import java.util.HashSet; import org.apache.spark.sql.types.DataType;
import com.github.sadikovi.riff.tree.*; import java.util.*; import org.apache.spark.sql.types.*;
[ "com.github.sadikovi", "java.util", "org.apache.spark" ]
com.github.sadikovi; java.util; org.apache.spark;
2,005,409
public void setProject(String project) { String name = "Project"; this.props.put(name, new JReleaseInfoProperty(name, JReleaseInfoProperty.TYPE_OBJ_STRING, project)); }
void function(String project) { String name = STR; this.props.put(name, new JReleaseInfoProperty(name, JReleaseInfoProperty.TYPE_OBJ_STRING, project)); }
/** * Set method for the name of the project * * @param version info */
Set method for the name of the project
setProject
{ "repo_name": "srnsw/xena", "path": "plugins/xml/ext/src/jreleaseinfo-1.2.1/src/java/ch/oscg/jreleaseinfo/anttask/JReleaseInfoAntTask.java", "license": "gpl-3.0", "size": 7698 }
[ "ch.oscg.jreleaseinfo.JReleaseInfoProperty" ]
import ch.oscg.jreleaseinfo.JReleaseInfoProperty;
import ch.oscg.jreleaseinfo.*;
[ "ch.oscg.jreleaseinfo" ]
ch.oscg.jreleaseinfo;
2,777,646
private AudioFeatureSet loadFeature(AudioFeatureSet featureSet, Parameter parameter, ClusterSet clusterSet, String descriptor) throws IOException, DiarizationException { String oldDescriptor = parameter.getParameterInputFeature().getFeaturesDescriptorAsString(); parameter.getParameterInputFeature().setFeaturesDe...
AudioFeatureSet function(AudioFeatureSet featureSet, Parameter parameter, ClusterSet clusterSet, String descriptor) throws IOException, DiarizationException { String oldDescriptor = parameter.getParameterInputFeature().getFeaturesDescriptorAsString(); parameter.getParameterInputFeature().setFeaturesDescription(descript...
/** * Load feature. * * @param featureSet the feature set * @param parameter the parameter * @param clusterSet the cluster set * @param descriptor the descriptor * @return the audio feature set * @throws IOException Signals that an I/O exception has occurred. * @throws DiarizationException the diariz...
Load feature
loadFeature
{ "repo_name": "Adirockzz95/GenderDetect", "path": "src/src/fr/lium/spkDiarization/system/Diarization.java", "license": "gpl-3.0", "size": 37472 }
[ "fr.lium.spkDiarization.lib.DiarizationException", "fr.lium.spkDiarization.lib.MainTools", "fr.lium.spkDiarization.libClusteringData.ClusterSet", "fr.lium.spkDiarization.libFeature.AudioFeatureSet", "fr.lium.spkDiarization.parameter.Parameter", "java.io.IOException" ]
import fr.lium.spkDiarization.lib.DiarizationException; import fr.lium.spkDiarization.lib.MainTools; import fr.lium.spkDiarization.libClusteringData.ClusterSet; import fr.lium.spkDiarization.libFeature.AudioFeatureSet; import fr.lium.spkDiarization.parameter.Parameter; import java.io.IOException;
import fr.lium.*; import java.io.*;
[ "fr.lium", "java.io" ]
fr.lium; java.io;
1,013,737
byte[] protectedHeader; try { protectedHeader = serdes.objectToByte(jwe.getHeader()); } catch (JsonException e) { throw new JsonToJwtException(HEADER_IS_INVALID, e); } byte[] aad = encoder.encode(protectedHeader); SecretKey key = new SecretKeySpec(jwe.ge...
byte[] protectedHeader; try { protectedHeader = serdes.objectToByte(jwe.getHeader()); } catch (JsonException e) { throw new JsonToJwtException(HEADER_IS_INVALID, e); } byte[] aad = encoder.encode(protectedHeader); SecretKey key = new SecretKeySpec(jwe.getCek(), KeyAlgorithm.AES.getValue()); Cipher symmetricCipher; try ...
/** * Generates a compact JWE. * * Ignores the value for the jwe iv and generates a new one. * * The variable symmetricCipher is a propagating dependency. It cannot be reused per * encryption attempt because it requires a new iv and aad per attempt. * * @param jwe must have value...
Generates a compact JWE. Ignores the value for the jwe iv and generates a new one. The variable symmetricCipher is a propagating dependency. It cannot be reused per encryption attempt because it requires a new iv and aad per attempt
JWEToCompact
{ "repo_name": "RootServices/jwt", "path": "src/main/java/net/tokensmith/jwt/jwe/serialization/direct/JweDirectSerializer.java", "license": "mit", "size": 3840 }
[ "java.util.ArrayList", "java.util.List", "javax.crypto.BadPaddingException", "javax.crypto.Cipher", "javax.crypto.IllegalBlockSizeException", "javax.crypto.SecretKey", "javax.crypto.spec.SecretKeySpec", "net.tokensmith.jwt.jwe.Transformation", "net.tokensmith.jwt.jwe.factory.exception.CipherExceptio...
import java.util.ArrayList; import java.util.List; import javax.crypto.BadPaddingException; import javax.crypto.Cipher; import javax.crypto.IllegalBlockSizeException; import javax.crypto.SecretKey; import javax.crypto.spec.SecretKeySpec; import net.tokensmith.jwt.jwe.Transformation; import net.tokensmith.jwt.jwe.factor...
import java.util.*; import javax.crypto.*; import javax.crypto.spec.*; import net.tokensmith.jwt.jwe.*; import net.tokensmith.jwt.jwe.factory.exception.*; import net.tokensmith.jwt.jwk.*; import net.tokensmith.jwt.serialization.exception.*;
[ "java.util", "javax.crypto", "net.tokensmith.jwt" ]
java.util; javax.crypto; net.tokensmith.jwt;
536,823
public static Map<String, Object> convertExecutorStats(ExecutorStats stats) { Map<String, Object> ret = new HashMap<>(); putKV(ret, EMITTED, stats.get_emitted()); putKV(ret, TRANSFERRED, stats.get_transferred()); putKV(ret, RATE, stats.get_rate()); if (stats.get_specific()....
static Map<String, Object> function(ExecutorStats stats) { Map<String, Object> ret = new HashMap<>(); putKV(ret, EMITTED, stats.get_emitted()); putKV(ret, TRANSFERRED, stats.get_transferred()); putKV(ret, RATE, stats.get_rate()); if (stats.get_specific().is_set_bolt()) { ret.putAll(convertSpecificStats(stats.get_specif...
/** * convert thrift ExecutorStats structure into a java HashMap */
convert thrift ExecutorStats structure into a java HashMap
convertExecutorStats
{ "repo_name": "roshannaik/storm", "path": "storm-client/src/jvm/org/apache/storm/stats/StatsUtil.java", "license": "apache-2.0", "size": 111115 }
[ "java.util.HashMap", "java.util.Map", "org.apache.storm.generated.ExecutorStats" ]
import java.util.HashMap; import java.util.Map; import org.apache.storm.generated.ExecutorStats;
import java.util.*; import org.apache.storm.generated.*;
[ "java.util", "org.apache.storm" ]
java.util; org.apache.storm;
147,708
public void onUpdateWalkingPlayer() { boolean flag = this.isSprinting(); if (flag != this.serverSprintState) { if (flag) { this.sendQueue.addToSendQueue(new C0BPacketEntityAction(this, C0BPacketEntityAction.Action.START_SPRINTING)); } ...
void function() { boolean flag = this.isSprinting(); if (flag != this.serverSprintState) { if (flag) { this.sendQueue.addToSendQueue(new C0BPacketEntityAction(this, C0BPacketEntityAction.Action.START_SPRINTING)); } else { this.sendQueue.addToSendQueue(new C0BPacketEntityAction(this, C0BPacketEntityAction.Action.STOP_SP...
/** * called every tick when the player is on foot. Performs all the things that normally happen during movement. */
called every tick when the player is on foot. Performs all the things that normally happen during movement
onUpdateWalkingPlayer
{ "repo_name": "kelthalorn/ConquestCraft", "path": "build/tmp/recompSrc/net/minecraft/client/entity/EntityPlayerSP.java", "license": "lgpl-2.1", "size": 30417 }
[ "net.minecraft.network.play.client.C03PacketPlayer", "net.minecraft.network.play.client.C0BPacketEntityAction" ]
import net.minecraft.network.play.client.C03PacketPlayer; import net.minecraft.network.play.client.C0BPacketEntityAction;
import net.minecraft.network.play.client.*;
[ "net.minecraft.network" ]
net.minecraft.network;
696,133
EClass getStatementListEntry();
EClass getStatementListEntry();
/** * Returns the meta object for class '{@link org.openhealthtools.mdht.cts2.statement.StatementListEntry <em>List Entry</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @return the meta object for class '<em>List Entry</em>'. * @see org.openhealthtools.mdht.cts2.statement.StatementListEntry ...
Returns the meta object for class '<code>org.openhealthtools.mdht.cts2.statement.StatementListEntry List Entry</code>'.
getStatementListEntry
{ "repo_name": "drbgfc/mdht", "path": "cts2/plugins/org.openhealthtools.mdht.cts2.core/src/org/openhealthtools/mdht/cts2/statement/StatementPackage.java", "license": "epl-1.0", "size": 51348 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
2,669,852
validateIndexOrAliasName(index, InvalidIndexNameException::new); if (!index.toLowerCase(Locale.ROOT).equals(index)) { throw new InvalidIndexNameException(index, "must be lowercase"); } if (state.routingTable().hasIndex(index)) { throw new ResourceAlreadyExistsException(st...
validateIndexOrAliasName(index, InvalidIndexNameException::new); if (!index.toLowerCase(Locale.ROOT).equals(index)) { throw new InvalidIndexNameException(index, STR); } if (state.routingTable().hasIndex(index)) { throw new ResourceAlreadyExistsException(state.routingTable().index(index).getIndex()); } if (state.metaDat...
/** * Validate the name for an index against some static rules and a cluster state. */
Validate the name for an index against some static rules and a cluster state
validateIndexName
{ "repo_name": "wuranbo/elasticsearch", "path": "core/src/main/java/org/elasticsearch/cluster/metadata/MetaDataCreateIndexService.java", "license": "apache-2.0", "size": 35792 }
[ "java.util.Locale", "org.elasticsearch.ResourceAlreadyExistsException", "org.elasticsearch.indices.InvalidIndexNameException" ]
import java.util.Locale; import org.elasticsearch.ResourceAlreadyExistsException; import org.elasticsearch.indices.InvalidIndexNameException;
import java.util.*; import org.elasticsearch.*; import org.elasticsearch.indices.*;
[ "java.util", "org.elasticsearch", "org.elasticsearch.indices" ]
java.util; org.elasticsearch; org.elasticsearch.indices;
903,286
private CToolchain.Builder createBaseArmeabiToolchain( boolean thumb, String gccVersion, String stackProtectorFlag, CppConfiguration.Tool... excludedTools) { String toolchainName = "arm-linux-androideabi-" + gccVersion; String targetPlatform = "arm-linux-androideabi"; CToolchain.Builder tool...
CToolchain.Builder function( boolean thumb, String gccVersion, String stackProtectorFlag, CppConfiguration.Tool... excludedTools) { String toolchainName = STR + gccVersion; String targetPlatform = STR; CToolchain.Builder toolchain = CToolchain.newBuilder() .setTargetSystemName(targetPlatform) .setCompiler("gcc-" + gccV...
/** * Flags common to arm-linux-androideabi* */
Flags common to arm-linux-androideabi
createBaseArmeabiToolchain
{ "repo_name": "kamalmarhubi/bazel", "path": "src/main/java/com/google/devtools/build/lib/bazel/rules/android/ndkcrosstools/ArmCrosstools.java", "license": "apache-2.0", "size": 18157 }
[ "com.google.devtools.build.lib.rules.cpp.CppConfiguration", "com.google.devtools.build.lib.view.config.crosstool.CrosstoolConfig" ]
import com.google.devtools.build.lib.rules.cpp.CppConfiguration; import com.google.devtools.build.lib.view.config.crosstool.CrosstoolConfig;
import com.google.devtools.build.lib.rules.cpp.*; import com.google.devtools.build.lib.view.config.crosstool.*;
[ "com.google.devtools" ]
com.google.devtools;
1,293,661
public void addObligation(Obligation obligation) { if (obligation != null) { this.obligations.add(obligation); } }
void function(Obligation obligation) { if (obligation != null) { this.obligations.add(obligation); } }
/** * Adds an obligation to the set of obligations that the PEP must fulfill * * @param obligation the <code>Obligation</code> to add */
Adds an obligation to the set of obligations that the PEP must fulfill
addObligation
{ "repo_name": "GenericBreakGlass/GenericBreakGlass-XACML", "path": "src/com.sun.xacml/src/main/java/com/sun/xacml/ctx/Result.java", "license": "apache-2.0", "size": 26122 }
[ "com.sun.xacml.Obligation" ]
import com.sun.xacml.Obligation;
import com.sun.xacml.*;
[ "com.sun.xacml" ]
com.sun.xacml;
455,350
protected void execGroovy(final String txt, final PrintStream out) { log.debug("execGroovy()"); // Check and ignore empty statements if (txt.trim().isEmpty()) { return; } log.verbose("Script: " + txt); if (classpath != null) { log.debug("Expl...
void function(final String txt, final PrintStream out) { log.debug(STR); if (txt.trim().isEmpty()) { return; } log.verbose(STR + txt); if (classpath != null) { log.debug(STR + classpath.toString()); } if (fork) { log.debug(STR); try { createClasspathParts(); createNewArgs(txt); super.setFork(fork); super.setClassname(u...
/** * Exec the statement. * * @param txt the groovy source to exec * @param out not used? */
Exec the statement
execGroovy
{ "repo_name": "apache/incubator-groovy", "path": "subprojects/groovy-ant/src/main/java/org/codehaus/groovy/ant/Groovy.java", "license": "apache-2.0", "size": 27356 }
[ "groovy.ant.AntBuilder", "groovy.lang.Binding", "groovy.lang.GroovyClassLoader", "groovy.lang.GroovyShell", "java.io.PrintStream", "java.io.PrintWriter", "java.io.Writer", "java.lang.reflect.Field", "java.security.PrivilegedAction", "org.apache.groovy.io.StringBuilderWriter", "org.apache.tools.a...
import groovy.ant.AntBuilder; import groovy.lang.Binding; import groovy.lang.GroovyClassLoader; import groovy.lang.GroovyShell; import java.io.PrintStream; import java.io.PrintWriter; import java.io.Writer; import java.lang.reflect.Field; import java.security.PrivilegedAction; import org.apache.groovy.io.StringBuilderW...
import groovy.ant.*; import groovy.lang.*; import java.io.*; import java.lang.reflect.*; import java.security.*; import org.apache.groovy.io.*; import org.apache.tools.ant.*; import org.codehaus.groovy.reflection.*; import org.codehaus.groovy.runtime.*; import org.codehaus.groovy.tools.*; import org.codehaus.groovy.vmp...
[ "groovy.ant", "groovy.lang", "java.io", "java.lang", "java.security", "org.apache.groovy", "org.apache.tools", "org.codehaus.groovy" ]
groovy.ant; groovy.lang; java.io; java.lang; java.security; org.apache.groovy; org.apache.tools; org.codehaus.groovy;
194,250
private void close(ResultSet resultSet, String task) { if (resultSet != null) { try { resultSet.close(); } catch (SQLException e) { log.error("Closing result set failed after " + task, e); } } }
void function(ResultSet resultSet, String task) { if (resultSet != null) { try { resultSet.close(); } catch (SQLException e) { log.error(STR + task, e); } } }
/** * closes the result set resources * * @param resultSet * ResultSet * @param task * task that was done by the closed result set. */
closes the result set resources
close
{ "repo_name": "chanakaudaya/andes", "path": "modules/andes-core/broker/src/main/java/org/wso2/andes/store/rdbms/RDBMSStoreUtils.java", "license": "apache-2.0", "size": 18289 }
[ "java.sql.ResultSet", "java.sql.SQLException" ]
import java.sql.ResultSet; import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
1,345,551
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller<PollResult<PublicIpPrefixInner>, PublicIpPrefixInner> beginCreateOrUpdate( String resourceGroupName, String publicIpPrefixName, PublicIpPrefixInner parameters, Context context);
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller<PollResult<PublicIpPrefixInner>, PublicIpPrefixInner> beginCreateOrUpdate( String resourceGroupName, String publicIpPrefixName, PublicIpPrefixInner parameters, Context context);
/** * Creates or updates a static or dynamic public IP prefix. * * @param resourceGroupName The name of the resource group. * @param publicIpPrefixName The name of the public IP prefix. * @param parameters Parameters supplied to the create or update public IP prefix operation. * @param con...
Creates or updates a static or dynamic public IP prefix
beginCreateOrUpdate
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-network/src/main/java/com/azure/resourcemanager/network/fluent/PublicIpPrefixesClient.java", "license": "mit", "size": 24606 }
[ "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.network.fluent.models.PublicIpPrefixInner" ]
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.network.fluent.models.PublicIpPrefixInner;
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.network.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
2,452,632
interface JdbcComponentBuilder extends ComponentBuilder<JdbcComponent> { default JdbcComponentBuilder dataSource(javax.sql.DataSource dataSource) { doSetProperty("dataSource", dataSource); return this; }
interface JdbcComponentBuilder extends ComponentBuilder<JdbcComponent> { default JdbcComponentBuilder dataSource(javax.sql.DataSource dataSource) { doSetProperty(STR, dataSource); return this; }
/** * To use the DataSource instance instead of looking up the data source * by name from the registry. * * The option is a: &lt;code&gt;javax.sql.DataSource&lt;/code&gt; type. * * Group: producer * * @param dataSource the value to set ...
To use the DataSource instance instead of looking up the data source by name from the registry. The option is a: &lt;code&gt;javax.sql.DataSource&lt;/code&gt; type. Group: producer
dataSource
{ "repo_name": "nikhilvibhav/camel", "path": "core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/JdbcComponentBuilderFactory.java", "license": "apache-2.0", "size": 5239 }
[ "org.apache.camel.builder.component.ComponentBuilder", "org.apache.camel.component.jdbc.JdbcComponent" ]
import org.apache.camel.builder.component.ComponentBuilder; import org.apache.camel.component.jdbc.JdbcComponent;
import org.apache.camel.builder.component.*; import org.apache.camel.component.jdbc.*;
[ "org.apache.camel" ]
org.apache.camel;
2,581,586
@Override public int run() throws Exception { log.info("Step Start: stats"); long start = System.currentTimeMillis(); setUp(ModelStep.STATS); syncDataToHdfs(modelConfig.getDataSet().getSource()); if(modelConfig.isMapReduceRunMode()) { runMapRedStats(); ...
int function() throws Exception { log.info(STR); long start = System.currentTimeMillis(); setUp(ModelStep.STATS); syncDataToHdfs(modelConfig.getDataSet().getSource()); if(modelConfig.isMapReduceRunMode()) { runMapRedStats(); } else if(modelConfig.isLocalRunMode()) { runAkkaStats(); } else { throw new ShifuException(Shi...
/** * runner for statistics */
runner for statistics
run
{ "repo_name": "aglne/shifu", "path": "src/main/java/ml/shifu/shifu/core/processor/StatsModelProcessor.java", "license": "apache-2.0", "size": 18165 }
[ "ml.shifu.shifu.core.validator.ModelInspector", "ml.shifu.shifu.exception.ShifuErrorCode", "ml.shifu.shifu.exception.ShifuException" ]
import ml.shifu.shifu.core.validator.ModelInspector; import ml.shifu.shifu.exception.ShifuErrorCode; import ml.shifu.shifu.exception.ShifuException;
import ml.shifu.shifu.core.validator.*; import ml.shifu.shifu.exception.*;
[ "ml.shifu.shifu" ]
ml.shifu.shifu;
1,443,599
private void extractFiles(String rawJSON) { items = new ArrayList<>(); try { JSONArray users = new JSONArray(rawJSON); for(int i = 0; i < users.length(); i++){ JSONObject obj = users.getJSONObject(i); String username = obj.getString("usernam...
void function(String rawJSON) { items = new ArrayList<>(); try { JSONArray users = new JSONArray(rawJSON); for(int i = 0; i < users.length(); i++){ JSONObject obj = users.getJSONObject(i); String username = obj.getString(STR); String mode = (obj.getString("admin").equals("1")) ? "admin" : "user"; UserItem item = new Us...
/** * Extract JSONArray from server-data, convert to ArrayList and display * @param rawJSON The raw JSON-Data from the server */
Extract JSONArray from server-data, convert to ArrayList and display
extractFiles
{ "repo_name": "paranerd/simpledrive_android", "path": "app/src/main/java/org/simpledrive/activities/Users.java", "license": "mit", "size": 12818 }
[ "android.widget.Toast", "java.util.ArrayList", "org.json.JSONArray", "org.json.JSONException", "org.json.JSONObject", "org.simpledrive.models.UserItem" ]
import android.widget.Toast; import java.util.ArrayList; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import org.simpledrive.models.UserItem;
import android.widget.*; import java.util.*; import org.json.*; import org.simpledrive.models.*;
[ "android.widget", "java.util", "org.json", "org.simpledrive.models" ]
android.widget; java.util; org.json; org.simpledrive.models;
245,167
public ApiError error() { return this.error; }
ApiError function() { return this.error; }
/** * Get the error property: The errors that were encountered during execution of the operation. The details array * contains the list of them. * * @return the error value. */
Get the error property: The errors that were encountered during execution of the operation. The details array contains the list of them
error
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-compute/src/main/java/com/azure/resourcemanager/compute/fluent/models/VirtualMachineInstallPatchesResultInner.java", "license": "mit", "size": 7777 }
[ "com.azure.resourcemanager.compute.models.ApiError" ]
import com.azure.resourcemanager.compute.models.ApiError;
import com.azure.resourcemanager.compute.models.*;
[ "com.azure.resourcemanager" ]
com.azure.resourcemanager;
1,917,100
public static void exec(Environment env, Path library, String mainClass, String... args) { Path home = env.find(ENV_ASAKUSA_HOME) .filter(it -> it.isEmpty() == false) .map(Paths::get) .orElseThrow(() -> new IllegalStateException(MessageFormat.format( ...
static void function(Environment env, Path library, String mainClass, String... args) { Path home = env.find(ENV_ASAKUSA_HOME) .filter(it -> it.isEmpty() == false) .map(Paths::get) .orElseThrow(() -> new IllegalStateException(MessageFormat.format( STR{0}\STR, ENV_ASAKUSA_HOME))); Classpath classpath = new Classpath(); ...
/** * Executes the given class. * @param env the current environment variables * @param library the launcher library path * @param mainClass the main class name * @param args the program arguments */
Executes the given class
exec
{ "repo_name": "asakusafw/asakusafw", "path": "workflow/hadoop/src/main/java/com/asakusafw/workflow/hadoop/bootstrap/Bootstrap.java", "license": "apache-2.0", "size": 2641 }
[ "java.nio.file.Path", "java.nio.file.Paths", "java.text.MessageFormat" ]
import java.nio.file.Path; import java.nio.file.Paths; import java.text.MessageFormat;
import java.nio.file.*; import java.text.*;
[ "java.nio", "java.text" ]
java.nio; java.text;
1,788,212
// [TARGET listSubscriptionsAsync(String, ListOption...)] // [VARIABLE "my_topic_name"] public Page<SubscriptionId> listSubscriptionsForTopicAsync(String topicName) throws ExecutionException, InterruptedException { // [START listSubscriptionsForTopicAsync] Future<AsyncPage<SubscriptionId>> future = ...
Page<SubscriptionId> function(String topicName) throws ExecutionException, InterruptedException { Future<AsyncPage<SubscriptionId>> future = pubsub.listSubscriptionsAsync(topicName, ListOption.pageSize(100)); AsyncPage<SubscriptionId> subscriptions = future.get(); Iterator<SubscriptionId> subscriptionIterator = subscri...
/** * Example of asynchronously listing subscriptions for a topic, specifying the page size. */
Example of asynchronously listing subscriptions for a topic, specifying the page size
listSubscriptionsForTopicAsync
{ "repo_name": "tangiel/google-cloud-java", "path": "google-cloud-examples/src/main/java/com/google/cloud/examples/pubsub/snippets/PubSubSnippets.java", "license": "apache-2.0", "size": 35770 }
[ "com.google.cloud.AsyncPage", "com.google.cloud.Page", "com.google.cloud.pubsub.PubSub", "com.google.cloud.pubsub.SubscriptionId", "java.util.Iterator", "java.util.concurrent.ExecutionException", "java.util.concurrent.Future" ]
import com.google.cloud.AsyncPage; import com.google.cloud.Page; import com.google.cloud.pubsub.PubSub; import com.google.cloud.pubsub.SubscriptionId; import java.util.Iterator; import java.util.concurrent.ExecutionException; import java.util.concurrent.Future;
import com.google.cloud.*; import com.google.cloud.pubsub.*; import java.util.*; import java.util.concurrent.*;
[ "com.google.cloud", "java.util" ]
com.google.cloud; java.util;
2,755,720
private String buildURL(HttpServletRequest request) { return request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + request.getContextPath(); }
String function(HttpServletRequest request) { return request.getScheme() + STR:" + request.getServerPort() + request.getContextPath(); }
/** * The implementation of building url * * @param request HttpServletRequest * @return url */
The implementation of building url
buildURL
{ "repo_name": "illerax/jcommune", "path": "jcommune-view/jcommune-web-controller/src/main/java/org/jtalks/jcommune/web/view/RssViewer.java", "license": "lgpl-2.1", "size": 4616 }
[ "javax.servlet.http.HttpServletRequest" ]
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.*;
[ "javax.servlet" ]
javax.servlet;
2,673,169
public boolean validate(Feature complexFeature) { List childFeatures = (List) complexFeature.getValue(); for (int i = 0; i < subFeatureStructs.size(); i++) { // test if the feature was manditory, if so, mark it as such FeatureStruct baseFeatureStruct = (FeatureStruct) subFeatureStructs.get(i); St...
boolean function(Feature complexFeature) { List childFeatures = (List) complexFeature.getValue(); for (int i = 0; i < subFeatureStructs.size(); i++) { FeatureStruct baseFeatureStruct = (FeatureStruct) subFeatureStructs.get(i); String baseFeaturePath = baseFeatureStruct.getFeaturePath(); if (baseFeatureStruct.isManditor...
/** * Validates the specified feature against this feature structure definition. The feature value is valid if its child features are within their cardinality constraints as defined in the structure definition. * @return <code>true</code> it this feature is valid according to this feature structure definition. ...
Validates the specified feature against this feature structure definition. The feature value is valid if its child features are within their cardinality constraints as defined in the structure definition
validate
{ "repo_name": "knoxsp/Concept", "path": "src/cbml/cbr/types/ComplexFeatureStruct.java", "license": "gpl-2.0", "size": 6376 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,108,374
public static gpsTOWType fromPerAligned(byte[] encodedBytes) { gpsTOWType result = new gpsTOWType(); result.decodePerAligned(new BitStreamReader(encodedBytes)); return result; }
static gpsTOWType function(byte[] encodedBytes) { gpsTOWType result = new gpsTOWType(); result.decodePerAligned(new BitStreamReader(encodedBytes)); return result; }
/** * Creates a new gpsTOWType from encoded stream. */
Creates a new gpsTOWType from encoded stream
fromPerAligned
{ "repo_name": "google/supl-client", "path": "src/main/java/com/google/location/suplclient/asn1/supl2/rrlp_components/LocationInfo.java", "license": "apache-2.0", "size": 15010 }
[ "com.google.location.suplclient.asn1.base.BitStreamReader" ]
import com.google.location.suplclient.asn1.base.BitStreamReader;
import com.google.location.suplclient.asn1.base.*;
[ "com.google.location" ]
com.google.location;
1,075,155
public SliceBuilder slice() { return sliceBuilder; }
SliceBuilder function() { return sliceBuilder; }
/** * Gets the slice used to filter the search hits, the top hits and the aggregations. */
Gets the slice used to filter the search hits, the top hits and the aggregations
slice
{ "repo_name": "LeoYao/elasticsearch", "path": "core/src/main/java/org/elasticsearch/search/builder/SearchSourceBuilder.java", "license": "apache-2.0", "size": 58763 }
[ "org.elasticsearch.search.slice.SliceBuilder" ]
import org.elasticsearch.search.slice.SliceBuilder;
import org.elasticsearch.search.slice.*;
[ "org.elasticsearch.search" ]
org.elasticsearch.search;
377,675
private void addDonateOption(@LayoutRes int layout, final String uri) { LayoutInflater inflater = LayoutInflater.from(context); View option = inflater.inflate(layout, donationOptionsLayout, false); if (layout == R.layout.donate_generic) { if (!uri.toLowerCase(...
void function(@LayoutRes int layout, final String uri) { LayoutInflater inflater = LayoutInflater.from(context); View option = inflater.inflate(layout, donationOptionsLayout, false); if (layout == R.layout.donate_generic) { if (!uri.toLowerCase(Locale.ENGLISH).startsWith("https: return; } ((TextView) option).setText(ur...
/** * Show the donate button, but only if it is an HTTPS URL. The * {@code https://} is then stripped off when URLs are directly displayed. */
Show the donate button, but only if it is an HTTPS URL. The HREF is then stripped off when URLs are directly displayed
addDonateOption
{ "repo_name": "f-droid/fdroidclient", "path": "app/src/main/java/org/fdroid/fdroid/views/AppDetailsRecyclerViewAdapter.java", "license": "gpl-3.0", "size": 63516 }
[ "android.view.LayoutInflater", "android.view.View", "android.widget.TextView", "androidx.annotation.LayoutRes", "java.util.Locale" ]
import android.view.LayoutInflater; import android.view.View; import android.widget.TextView; import androidx.annotation.LayoutRes; import java.util.Locale;
import android.view.*; import android.widget.*; import androidx.annotation.*; import java.util.*;
[ "android.view", "android.widget", "androidx.annotation", "java.util" ]
android.view; android.widget; androidx.annotation; java.util;
2,571,459
public boolean isLookup() { boolean retValue = false; if (DisplayType.isLookup(m_vo.displayType)) retValue = true; else if (m_vo.IsKey) retValue = false; // else if (m_vo.ColumnName.equals("CreatedBy") || m_vo.ColumnName.equals("UpdatedBy")) // retValue = false; else if (m_vo.displayType =...
boolean function() { boolean retValue = false; if (DisplayType.isLookup(m_vo.displayType)) retValue = true; else if (m_vo.IsKey) retValue = false; else if (m_vo.displayType == DisplayType.Location m_vo.displayType == DisplayType.Locator m_vo.displayType == DisplayType.Account m_vo.displayType == DisplayType.PAttribute)...
/** * Is this field a Lookup?. * @return true if lookup field */
Is this field a Lookup?
isLookup
{ "repo_name": "arthurmelo88/palmetalADP", "path": "adempiere_360/base/src/org/compiere/model/GridField.java", "license": "gpl-2.0", "size": 49584 }
[ "org.compiere.util.DisplayType" ]
import org.compiere.util.DisplayType;
import org.compiere.util.*;
[ "org.compiere.util" ]
org.compiere.util;
126,215
Map<String, List<String>> ret = new TreeMap<String, List<String>>(new CaseInsensitiveStringComparator()); // init with empty value list for known params for (String n : names) { ret.put(n, new ArrayList<String>()); } for (Parameter p : paramList) { if (names.cont...
Map<String, List<String>> ret = new TreeMap<String, List<String>>(new CaseInsensitiveStringComparator()); for (String n : names) { ret.put(n, new ArrayList<String>()); } for (Parameter p : paramList) { if (names.contains(p.getName())) { String pname = p.getName(); List<String> values = ret.get(pname); values.add(p.getV...
/** * Get a map of parameter name to value(s). This map includes params that match the configured * accept list. * * @param paramList * @return list of 1+ values or null */
Get a map of parameter name to value(s). This map includes params that match the configured accept list
getParameters
{ "repo_name": "opencadc/dal", "path": "cadc-dali/src/main/java/ca/nrc/cadc/dali/ParamExtractor.java", "license": "agpl-3.0", "size": 6362 }
[ "ca.nrc.cadc.util.CaseInsensitiveStringComparator", "ca.nrc.cadc.uws.Parameter", "java.util.ArrayList", "java.util.List", "java.util.Map", "java.util.TreeMap" ]
import ca.nrc.cadc.util.CaseInsensitiveStringComparator; import ca.nrc.cadc.uws.Parameter; import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.TreeMap;
import ca.nrc.cadc.util.*; import ca.nrc.cadc.uws.*; import java.util.*;
[ "ca.nrc.cadc", "java.util" ]
ca.nrc.cadc; java.util;
2,748,170
public final HttpSession getSession(boolean allowCreate) { if (isRequestActive()) { return this.request.getSession(allowCreate); } else { // Access through stored session reference, if any... if (this.session == null && allowCreate) { throw new IllegalStateException( "No session foun...
final HttpSession function(boolean allowCreate) { if (isRequestActive()) { return this.request.getSession(allowCreate); } else { if (this.session == null && allowCreate) { throw new IllegalStateException( STR); } return this.session; } }
/** * Exposes the {@link HttpSession} that we're wrapping. * @param allowCreate whether to allow creation of a new session if none exists yet */
Exposes the <code>HttpSession</code> that we're wrapping
getSession
{ "repo_name": "besom/bbossgroups-mvn", "path": "bboss_mvc/src/main/java/org/frameworkset/web/servlet/context/ServletRequestAttributes.java", "license": "apache-2.0", "size": 10142 }
[ "javax.servlet.http.HttpSession" ]
import javax.servlet.http.HttpSession;
import javax.servlet.http.*;
[ "javax.servlet" ]
javax.servlet;
2,866,528
public void setStateConfiguration(Map<String, Object> stateConfiguration);
void function(Map<String, Object> stateConfiguration);
/** * Set any user-defined state that should accompany the RollbackHandler. This configuration will be passed to * the RollbackHandler implementation at runtime. * * @param stateConfiguration any user-defined state configuration necessary for the execution of the RollbackHandler */
Set any user-defined state that should accompany the RollbackHandler. This configuration will be passed to the RollbackHandler implementation at runtime
setStateConfiguration
{ "repo_name": "cloudbearings/BroadleafCommerce", "path": "core/broadleaf-framework/src/main/java/org/broadleafcommerce/core/workflow/Activity.java", "license": "apache-2.0", "size": 6896 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
1,719,246
protected Arrival createArrivalTime(VehicleState vehicleState, long arrivalTime, Block block, int tripIndex, int stopPathIndex) { // Store the arrival in the database via the db logger Arrival arrival = new Arrival(vehicleState.getVehicleId(), new Date(arrivalTime), vehicleState.getAvlReport().getDat...
Arrival function(VehicleState vehicleState, long arrivalTime, Block block, int tripIndex, int stopPathIndex) { Arrival arrival = new Arrival(vehicleState.getVehicleId(), new Date(arrivalTime), vehicleState.getAvlReport().getDate(), block, tripIndex, stopPathIndex); logger.debug(STR, arrival); if (arrivalTime > vehicleS...
/** * Writes out arrival time to database. Also keeps track of the latest * arrival time in VehicleState so that can make sure that subsequent * departures are after the last arrival time. * * @param vehicleState * @param arrivalTime * @param block * @param tripIndex * @param stopPathIndex */
Writes out arrival time to database. Also keeps track of the latest arrival time in VehicleState so that can make sure that subsequent departures are after the last arrival time
createArrivalTime
{ "repo_name": "sheldonabrown/core", "path": "transitime/src/main/java/org/transitime/core/ArrivalDepartureGeneratorDefaultImpl.java", "license": "gpl-3.0", "size": 51026 }
[ "java.util.Date", "org.transitime.db.structs.Arrival", "org.transitime.db.structs.Block" ]
import java.util.Date; import org.transitime.db.structs.Arrival; import org.transitime.db.structs.Block;
import java.util.*; import org.transitime.db.structs.*;
[ "java.util", "org.transitime.db" ]
java.util; org.transitime.db;
304,487
public static DoubleBuffer directDoubleBuffer(int size) { return directByteBuffer(size * 4).asDoubleBuffer(); }
static DoubleBuffer function(int size) { return directByteBuffer(size * 4).asDoubleBuffer(); }
/** * Asks for a new directly backed DoubleBuffer * * @param size * the number of buffer elements (doubles) * @return a new direct float buffer */
Asks for a new directly backed DoubleBuffer
directDoubleBuffer
{ "repo_name": "WorldSEnder/MCAnm", "path": "src/main/java/com/github/worldsender/mcanm/common/Utils.java", "license": "gpl-2.0", "size": 13067 }
[ "java.nio.DoubleBuffer" ]
import java.nio.DoubleBuffer;
import java.nio.*;
[ "java.nio" ]
java.nio;
976,496
public Library getLibraryWithNamespace( String namespace, int level ) { return null; }
Library function( String namespace, int level ) { return null; }
/** * Returns the module with the given namespace. This method checks the * namespace in included libraries within the given depth. * * @param namespace * the module namespace * @param level * the depth of the library * @return the module with the given namespace * * @see IMo...
Returns the module with the given namespace. This method checks the namespace in included libraries within the given depth
getLibraryWithNamespace
{ "repo_name": "sguan-actuate/birt", "path": "model/org.eclipse.birt.report.model/src/org/eclipse/birt/report/model/core/ModuleImpl.java", "license": "epl-1.0", "size": 72136 }
[ "org.eclipse.birt.report.model.elements.Library" ]
import org.eclipse.birt.report.model.elements.Library;
import org.eclipse.birt.report.model.elements.*;
[ "org.eclipse.birt" ]
org.eclipse.birt;
650,747
public List<Token> toList() { return Collections.unmodifiableList(tokens); }
List<Token> function() { return Collections.unmodifiableList(tokens); }
/** * Returns the tokens as a List * @return list */
Returns the tokens as a List
toList
{ "repo_name": "fergusq/nept", "path": "src/org/kaivos/nept/parser/TokenList.java", "license": "gpl-3.0", "size": 4671 }
[ "java.util.Collections", "java.util.List" ]
import java.util.Collections; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
228,182
public void save(File dir) throws Exception{ String id = getIdentifierSimple(); dir = new File(dir,TextUtils.stripSuffix(getTitleSimple())); Utils.saveFHIR(this,id,dir); // go over components Patient pt = getPatient(); if(pt != null) pt.save(dir); for(Element e: getReportElements()){ e.save...
void function(File dir) throws Exception{ String id = getIdentifierSimple(); dir = new File(dir,TextUtils.stripSuffix(getTitleSimple())); Utils.saveFHIR(this,id,dir); Patient pt = getPatient(); if(pt != null) pt.save(dir); for(Element e: getReportElements()){ e.save(dir); } }
/** * persist this object to a directory * @param dir * @throws Exception * @throws FileNotFoundException */
persist this object to a directory
save
{ "repo_name": "harryhoch/DeepPhe", "path": "src/edu/pitt/dbmi/deep/phe/model/Report.java", "license": "apache-2.0", "size": 5234 }
[ "edu.pitt.dbmi.deep.phe.util.TextUtils", "java.io.File" ]
import edu.pitt.dbmi.deep.phe.util.TextUtils; import java.io.File;
import edu.pitt.dbmi.deep.phe.util.*; import java.io.*;
[ "edu.pitt.dbmi", "java.io" ]
edu.pitt.dbmi; java.io;
1,997,443
protected void removeNonVisibleViews() { if(getChildCount() == 0) return; final int leftScreenEdge = getScrollX(); final int rightScreenEdge = leftScreenEdge + getWidth(); // check if we should remove any views in the left View firstChild = getChildAt(0); final int lef...
void function() { if(getChildCount() == 0) return; final int leftScreenEdge = getScrollX(); final int rightScreenEdge = leftScreenEdge + getWidth(); View firstChild = getChildAt(0); final int leftedge = firstChild.getLeft() - ((LoopLayoutParams)firstChild.getLayoutParams()).leftMargin; if(leftedge != mLeftChildEdge) th...
/** * Removes view that are outside of the visible part of the list. Will not * remove all views. */
Removes view that are outside of the visible part of the list. Will not remove all views
removeNonVisibleViews
{ "repo_name": "android-plugin/uexCoverFlow", "path": "src/it/moondroid/coverflow/components/ui/containers/EndlessLoopAdapterContainer.java", "license": "lgpl-3.0", "size": 41989 }
[ "android.view.View", "java.lang.ref.WeakReference" ]
import android.view.View; import java.lang.ref.WeakReference;
import android.view.*; import java.lang.ref.*;
[ "android.view", "java.lang" ]
android.view; java.lang;
1,952,177
@SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { applyFiltersButton.setIcon(new javax.swing.ImageIcon(getClass().getResource("/org/sleuthkit/autopsy/communications/images/tick.png"))); // NOI18N ...
@SuppressWarnings(STR) void function() { applyFiltersButton.setIcon(new javax.swing.ImageIcon(getClass().getResource(STR))); applyFiltersButton.setText(org.openide.util.NbBundle.getMessage(FiltersPanel.class, STR)); applyFiltersButton.setPreferredSize(null); filtersTitleLabel.setIcon(new javax.swing.ImageIcon(getClass(...
/** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */
This method is called from within the constructor to initialize the form. regenerated by the Form Editor
initComponents
{ "repo_name": "millmanorama/autopsy", "path": "Core/src/org/sleuthkit/autopsy/communications/FiltersPanel.java", "license": "apache-2.0", "size": 34880 }
[ "org.openide.util.NbBundle" ]
import org.openide.util.NbBundle;
import org.openide.util.*;
[ "org.openide.util" ]
org.openide.util;
2,404,932
public void addIdMapping(String id, IdDefinition idDefinition) { if (!idMappings.containsKey(id)) { idMappings.put(id, new ArrayList<IdDefinition>()); } idMappings.get(id).add(idDefinition); }
void function(String id, IdDefinition idDefinition) { if (!idMappings.containsKey(id)) { idMappings.put(id, new ArrayList<IdDefinition>()); } idMappings.get(id).add(idDefinition); }
/** * Appends the {@link IdDefinition} to the end of the list for the given ID. * * @param id * The ID of this {@link IdDefinition} object. * @param idDefinition * The {@link IdDefinition} object. */
Appends the <code>IdDefinition</code> to the end of the list for the given ID
addIdMapping
{ "repo_name": "andy32323/inspectIT", "path": "inspectIT/src/info/novatec/inspectit/rcp/editor/inputdefinition/InputDefinition.java", "license": "agpl-3.0", "size": 12457 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
354,922
public static void synchronizeAmbariEventPublisher(Binder binder) { EventBus synchronizedBus = new EventBus(); AmbariEventPublisher ambariEventPublisher = new AmbariEventPublisher(); replaceEventBus(AmbariEventPublisher.class, ambariEventPublisher, synchronizedBus); binder.bind(AmbariEventPu...
static void function(Binder binder) { EventBus synchronizedBus = new EventBus(); AmbariEventPublisher ambariEventPublisher = new AmbariEventPublisher(); replaceEventBus(AmbariEventPublisher.class, ambariEventPublisher, synchronizedBus); binder.bind(AmbariEventPublisher.class).toInstance(ambariEventPublisher); }
/** * Force the {@link EventBus} from {@link AmbariEventPublisher} to be serial * and synchronous. * * @param binder */
Force the <code>EventBus</code> from <code>AmbariEventPublisher</code> to be serial and synchronous
synchronizeAmbariEventPublisher
{ "repo_name": "alexryndin/ambari", "path": "ambari-server/src/main/java/org/apache/ambari/server/utils/EventBusSynchronizer.java", "license": "apache-2.0", "size": 5587 }
[ "com.google.common.eventbus.EventBus", "com.google.inject.Binder", "org.apache.ambari.server.events.publishers.AmbariEventPublisher" ]
import com.google.common.eventbus.EventBus; import com.google.inject.Binder; import org.apache.ambari.server.events.publishers.AmbariEventPublisher;
import com.google.common.eventbus.*; import com.google.inject.*; import org.apache.ambari.server.events.publishers.*;
[ "com.google.common", "com.google.inject", "org.apache.ambari" ]
com.google.common; com.google.inject; org.apache.ambari;
1,324,319
public void setGridBandPaint(Paint paint) { if (paint == null) { throw new IllegalArgumentException("Null 'paint' argument."); } this.gridBandPaint = paint; }
void function(Paint paint) { if (paint == null) { throw new IllegalArgumentException(STR); } this.gridBandPaint = paint; }
/** * Sets the grid band paint. * * @param paint the paint (<code>null</code> not permitted). * * @see #getGridBandPaint() */
Sets the grid band paint
setGridBandPaint
{ "repo_name": "apetresc/JFreeChart", "path": "src/main/java/org/jfree/chart/StandardChartTheme.java", "license": "lgpl-2.1", "size": 61509 }
[ "java.awt.Paint" ]
import java.awt.Paint;
import java.awt.*;
[ "java.awt" ]
java.awt;
1,007,627
public boolean removeFooterView(View v) { if (mFooterViewInfos.size() > 0) { boolean result = false; if (mAdapter != null && ((PLA_HeaderViewListAdapter) mAdapter).removeFooter(v)) { mDataSetObserver.onChanged(); result = true; } ...
boolean function(View v) { if (mFooterViewInfos.size() > 0) { boolean result = false; if (mAdapter != null && ((PLA_HeaderViewListAdapter) mAdapter).removeFooter(v)) { mDataSetObserver.onChanged(); result = true; } removeFixedViewInfo(v, mFooterViewInfos); return result; } return false; }
/** * Removes a previously-added footer view. * * @param v The view to remove * @return * true if the view was removed, false if the view was not a footer view */
Removes a previously-added footer view
removeFooterView
{ "repo_name": "susong0618/EasyFrame", "path": "library/src/main/java/com/dream/library/widgets/pla/PLA_ListView.java", "license": "apache-2.0", "size": 82672 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
2,176,697
void connect() throws InterruptedException { log.info("Connecting to VoltDB..."); final CountDownLatch connections = new CountDownLatch(config.parsedServers.length);
void connect() throws InterruptedException { log.info(STR); final CountDownLatch connections = new CountDownLatch(config.parsedServers.length);
/** * Connect to a set of servers in parallel. Each will retry until * connection. This call will block until all have connected. * * @throws InterruptedException if anything bad happens with the threads. */
Connect to a set of servers in parallel. Each will retry until connection. This call will block until all have connected
connect
{ "repo_name": "simonzhangsm/voltdb", "path": "tests/test_apps/txnid-selfcheck/src/txnIdSelfCheck/AsyncBenchmark.java", "license": "agpl-3.0", "size": 20074 }
[ "java.util.concurrent.CountDownLatch" ]
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
2,766,798
public static boolean verifyPresence(RuleContext ruleContext) { if (fromRuleContext(ruleContext) == null) { ruleContext.ruleError( "No Android SDK found. Use the --android_sdk command line option to specify one."); return false; } return true; }
static boolean function(RuleContext ruleContext) { if (fromRuleContext(ruleContext) == null) { ruleContext.ruleError( STR); return false; } return true; }
/** * Signals an error if the Android SDK cannot be found. */
Signals an error if the Android SDK cannot be found
verifyPresence
{ "repo_name": "mrdomino/bazel", "path": "src/main/java/com/google/devtools/build/lib/rules/android/AndroidSdkProvider.java", "license": "apache-2.0", "size": 5222 }
[ "com.google.devtools.build.lib.analysis.RuleContext" ]
import com.google.devtools.build.lib.analysis.RuleContext;
import com.google.devtools.build.lib.analysis.*;
[ "com.google.devtools" ]
com.google.devtools;
318,445
@Test public void testVarLengthVector_SetOOBCount() throws Exception { final MaterializedField field = MaterializedField.create(EMPTY_SCHEMA_PATH, VarCharHolder.TYPE); VariableWidthVector vector = new VarCharVector(field, allocator); try { vector.allocateNew(10, 1); vector.getMutator().setVa...
void function() throws Exception { final MaterializedField field = MaterializedField.create(EMPTY_SCHEMA_PATH, VarCharHolder.TYPE); VariableWidthVector vector = new VarCharVector(field, allocator); try { vector.allocateNew(10, 1); vector.getMutator().setValueCount(4); fail(); } catch (Exception ex) { assertTrue(ex inst...
/** For VariableLengthVectors when we try to set value count greater than value count for which memory is allocated, * then it should fail with IndexOutOfBoundException. * @throws Exception */
For VariableLengthVectors when we try to set value count greater than value count for which memory is allocated, then it should fail with IndexOutOfBoundException
testVarLengthVector_SetOOBCount
{ "repo_name": "KulykRoman/drill", "path": "exec/java-exec/src/test/java/org/apache/drill/exec/record/vector/TestValueVector.java", "license": "apache-2.0", "size": 32201 }
[ "junit.framework.TestCase", "org.apache.drill.exec.expr.holders.VarCharHolder", "org.apache.drill.exec.record.MaterializedField", "org.apache.drill.exec.vector.VarCharVector", "org.apache.drill.exec.vector.VariableWidthVector", "org.junit.Assert" ]
import junit.framework.TestCase; import org.apache.drill.exec.expr.holders.VarCharHolder; import org.apache.drill.exec.record.MaterializedField; import org.apache.drill.exec.vector.VarCharVector; import org.apache.drill.exec.vector.VariableWidthVector; import org.junit.Assert;
import junit.framework.*; import org.apache.drill.exec.expr.holders.*; import org.apache.drill.exec.record.*; import org.apache.drill.exec.vector.*; import org.junit.*;
[ "junit.framework", "org.apache.drill", "org.junit" ]
junit.framework; org.apache.drill; org.junit;
286,762
public static Formula totalOrder(Expression r, Expression s) { assert r.arity() == 2 && s.arity() == 1; final List<Formula> to = new ArrayList<Formula>(); // reflexive and complete over s to.add( s.product(s).in(r.union(r.transpose())) ); // transitive to.add( r.join(r).in(r) ); // antisymmetric to....
static Formula function(Expression r, Expression s) { assert r.arity() == 2 && s.arity() == 1; final List<Formula> to = new ArrayList<Formula>(); to.add( s.product(s).in(r.union(r.transpose())) ); to.add( r.join(r).in(r) ); to.add( r.intersection(r.transpose()).in(Expression.IDEN) ); return Formula.and(to); }
/** * Returns a formula that evaluates to true iff r is a total order * over the set s. * @requires r.arity = 2 and s.arity = 1 * @return a formula that evaluates to true iff r is reflexive, complete, * transitive and antisymmetric over the set s. */
Returns a formula that evaluates to true iff r is a total order over the set s
totalOrder
{ "repo_name": "wala/MemSAT", "path": "com.ibm.wala.memsat/src/com/ibm/wala/memsat/util/Nodes.java", "license": "epl-1.0", "size": 7821 }
[ "java.util.ArrayList", "java.util.List" ]
import java.util.ArrayList; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,975,727
@ServiceMethod(returns = ReturnType.SINGLE) public ConnectionMonitorQueryResultInner query( String resourceGroupName, String networkWatcherName, String connectionMonitorName, Context context) { return queryAsync(resourceGroupName, networkWatcherName, connectionMonitorName, context).block(); ...
@ServiceMethod(returns = ReturnType.SINGLE) ConnectionMonitorQueryResultInner function( String resourceGroupName, String networkWatcherName, String connectionMonitorName, Context context) { return queryAsync(resourceGroupName, networkWatcherName, connectionMonitorName, context).block(); }
/** * Query a snapshot of the most recent connection states. * * @param resourceGroupName The name of the resource group containing Network Watcher. * @param networkWatcherName The name of the Network Watcher resource. * @param connectionMonitorName The name given to the connection monitor. ...
Query a snapshot of the most recent connection states
query
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-network/src/main/java/com/azure/resourcemanager/network/implementation/ConnectionMonitorsClientImpl.java", "license": "mit", "size": 107051 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.util.Context", "com.azure.resourcemanager.network.fluent.models.ConnectionMonitorQueryResultInner" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.util.Context; import com.azure.resourcemanager.network.fluent.models.ConnectionMonitorQueryResultInner;
import com.azure.core.annotation.*; import com.azure.core.util.*; import com.azure.resourcemanager.network.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
328,815
public State getProperty(String propertyName) { return state.get(propertyName); }
State function(String propertyName) { return state.get(propertyName); }
/** * Returns teh current state for the property * * @param propertyName a possibly null, possibly empty property name * @return the {@link State} for the property or null if not found (or property name is null/empty) */
Returns teh current state for the property
getProperty
{ "repo_name": "MikeJMajor/openhab2-addons-dlinksmarthome", "path": "bundles/org.openhab.binding.russound/src/main/java/org/openhab/binding/russound/internal/rio/StatefulHandlerCallback.java", "license": "epl-1.0", "size": 5154 }
[ "org.openhab.core.types.State" ]
import org.openhab.core.types.State;
import org.openhab.core.types.*;
[ "org.openhab.core" ]
org.openhab.core;
573,814
@CalledByNative private static void markLocalKeysAsStale(int requestId, CoreAccountInfo accountInfo) { Consumer<Boolean> responseCallback = succeeded -> { if (get().mNativeTrustedVaultClientAndroid == 0) { // Native already unregistered, no response needed. re...
static void function(int requestId, CoreAccountInfo accountInfo) { Consumer<Boolean> responseCallback = succeeded -> { if (get().mNativeTrustedVaultClientAndroid == 0) { return; } TrustedVaultClientJni.get().markLocalKeysAsStaleCompleted( get().mNativeTrustedVaultClientAndroid, requestId, succeeded); }; get().mBackend ...
/** * Forwards calls to Backend.markLocalKeysAsStale() and upon completion invokes native method * markLocalKeysAsStaleCompleted(). */
Forwards calls to Backend.markLocalKeysAsStale() and upon completion invokes native method markLocalKeysAsStaleCompleted()
markLocalKeysAsStale
{ "repo_name": "ric2b/Vivaldi-browser", "path": "chromium/chrome/android/java/src/org/chromium/chrome/browser/sync/TrustedVaultClient.java", "license": "bsd-3-clause", "size": 13641 }
[ "org.chromium.base.Consumer", "org.chromium.components.signin.base.CoreAccountInfo" ]
import org.chromium.base.Consumer; import org.chromium.components.signin.base.CoreAccountInfo;
import org.chromium.base.*; import org.chromium.components.signin.base.*;
[ "org.chromium.base", "org.chromium.components" ]
org.chromium.base; org.chromium.components;
1,964,863
public static void mergeCompiledData( final SerializedAndroidData primary, final Path primaryManifest, final List<? extends SerializedAndroidData> direct, final List<? extends SerializedAndroidData> transitive, @Nullable final AndroidResourceClassWriter rclassWriter, boolean throwO...
static void function( final SerializedAndroidData primary, final Path primaryManifest, final List<? extends SerializedAndroidData> direct, final List<? extends SerializedAndroidData> transitive, @Nullable final AndroidResourceClassWriter rclassWriter, boolean throwOnResourceConflict, ListeningExecutorService executorSe...
/** * Merges all secondary compiled resources with the primary compiled resources, given that the * primary resources have been separately compiled */
Merges all secondary compiled resources with the primary compiled resources, given that the primary resources have been separately compiled
mergeCompiledData
{ "repo_name": "ButterflyNetwork/bazel", "path": "src/tools/android/java/com/google/devtools/build/android/AndroidResourceMerger.java", "license": "apache-2.0", "size": 10724 }
[ "com.android.annotations.Nullable", "com.google.common.base.Stopwatch", "com.google.common.util.concurrent.ListeningExecutorService", "com.google.devtools.build.android.AndroidDataMerger", "java.io.IOException", "java.nio.file.Path", "java.util.List", "java.util.concurrent.TimeUnit" ]
import com.android.annotations.Nullable; import com.google.common.base.Stopwatch; import com.google.common.util.concurrent.ListeningExecutorService; import com.google.devtools.build.android.AndroidDataMerger; import java.io.IOException; import java.nio.file.Path; import java.util.List; import java.util.concurrent.TimeU...
import com.android.annotations.*; import com.google.common.base.*; import com.google.common.util.concurrent.*; import com.google.devtools.build.android.*; import java.io.*; import java.nio.file.*; import java.util.*; import java.util.concurrent.*;
[ "com.android.annotations", "com.google.common", "com.google.devtools", "java.io", "java.nio", "java.util" ]
com.android.annotations; com.google.common; com.google.devtools; java.io; java.nio; java.util;
70,063
@Test public void testSimpleBindAPrincipalBadPassword() throws LdapException, IOException { Assertions.assertThrows( LdapAuthenticationException.class, () -> { connection.bind( "uid=admin,ou=system", "badsecret" ); } ); }
void function() throws LdapException, IOException { Assertions.assertThrows( LdapAuthenticationException.class, () -> { connection.bind( STR, STR ); } ); }
/** * try to connect using a known user but with a bad password: we should get a invalidCredentials error. * * @throws Exception on error */
try to connect using a known user but with a bad password: we should get a invalidCredentials error
testSimpleBindAPrincipalBadPassword
{ "repo_name": "apache/directory-server", "path": "core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java", "license": "apache-2.0", "size": 8781 }
[ "java.io.IOException", "org.apache.directory.api.ldap.model.exception.LdapAuthenticationException", "org.apache.directory.api.ldap.model.exception.LdapException", "org.junit.jupiter.api.Assertions" ]
import java.io.IOException; import org.apache.directory.api.ldap.model.exception.LdapAuthenticationException; import org.apache.directory.api.ldap.model.exception.LdapException; import org.junit.jupiter.api.Assertions;
import java.io.*; import org.apache.directory.api.ldap.model.exception.*; import org.junit.jupiter.api.*;
[ "java.io", "org.apache.directory", "org.junit.jupiter" ]
java.io; org.apache.directory; org.junit.jupiter;
1,272,593
public void disableBehaviour(NodeRef nodeRef);
void function(NodeRef nodeRef);
/** * Disable all behaviours for a given node * * @param nodeRef the node to disable for */
Disable all behaviours for a given node
disableBehaviour
{ "repo_name": "Alfresco/community-edition", "path": "projects/repository/source/java/org/alfresco/repo/policy/BehaviourFilter.java", "license": "lgpl-3.0", "size": 7709 }
[ "org.alfresco.service.cmr.repository.NodeRef" ]
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.*;
[ "org.alfresco.service" ]
org.alfresco.service;
457,991
public User getUser() { return user; }
User function() { return user; }
/** * Get the user. * * @return The user. */
Get the user
getUser
{ "repo_name": "EaW1805/data", "path": "src/main/java/com/eaw1805/data/model/forum/ForumSessions.java", "license": "mit", "size": 6122 }
[ "com.eaw1805.data.model.User" ]
import com.eaw1805.data.model.User;
import com.eaw1805.data.model.*;
[ "com.eaw1805.data" ]
com.eaw1805.data;
744,265
public static void main(String[] args) { JFrame frame = new JFrame(); frame.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); DefaultMutableTreeNode root = new DefaultMutableTreeNode("root"); Random rand = new Random(); java.util.List<DefaultMutableTreeNode> nodes = new ArrayList<DefaultMutabl...
static void function(String[] args) { JFrame frame = new JFrame(); frame.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); DefaultMutableTreeNode root = new DefaultMutableTreeNode("root"); Random rand = new Random(); java.util.List<DefaultMutableTreeNode> nodes = new ArrayList<DefaultMutableTreeNode>(); for (...
/** * Test function. NEW * * @param args */
Test function. NEW
main
{ "repo_name": "lorebiga/CheckboxTree", "path": "src/test/java/eu/floraresearch/lablib/gui/checkboxtree/MultipleToggleCheckboxTree.java", "license": "gpl-2.0", "size": 12250 }
[ "java.util.ArrayList", "java.util.Random", "javax.swing.JFrame", "javax.swing.WindowConstants", "javax.swing.tree.DefaultMutableTreeNode" ]
import java.util.ArrayList; import java.util.Random; import javax.swing.JFrame; import javax.swing.WindowConstants; import javax.swing.tree.DefaultMutableTreeNode;
import java.util.*; import javax.swing.*; import javax.swing.tree.*;
[ "java.util", "javax.swing" ]
java.util; javax.swing;
301,713
public void drawLine(List<mxPoint> pts, Map<String, Object> style) { Color penColor = mxUtils.getStyleStrokeColor(style,Color.BLACK); float penWidth = mxUtils.getStyleStrokeWidth(style,(float)1); if (penColor != null && penWidth > 0) { // Draws the shape String shape = mxUtils .getString(style, ...
void function(List<mxPoint> pts, Map<String, Object> style) { Color penColor = mxUtils.getStyleStrokeColor(style,Color.BLACK); float penWidth = mxUtils.getStyleStrokeWidth(style,(float)1); if (penColor != null && penWidth > 0) { String shape = mxUtils .getString(style, mxConstants.STYLE_SHAPE, ""); if (shape.equals(mxC...
/** * Draws the given lines as segments between all points of the given list * of mxPoints. * * @param pts List of points that define the line. * @param style Style to be used for painting the line. */
Draws the given lines as segments between all points of the given list of mxPoints
drawLine
{ "repo_name": "JasonEX/scxmlgui", "path": "jgraphx/src/com/mxgraph/canvas/mxGraphics2DCanvas.java", "license": "apache-2.0", "size": 44427 }
[ "java.awt.Color", "java.awt.Paint", "java.awt.Rectangle", "java.util.List", "java.util.Map" ]
import java.awt.Color; import java.awt.Paint; import java.awt.Rectangle; import java.util.List; import java.util.Map;
import java.awt.*; import java.util.*;
[ "java.awt", "java.util" ]
java.awt; java.util;
432,939
public Boolean getManagement(Connection c) throws Types.BadServerResponse, XmlRpcException { String method_call = "PIF.get_management"; String session = c.getSessionReference(); Object[] method_params = {Marshalling.toXMLRPC(session), Marshalling.toXMLRPC(this.ref)}; Ma...
Boolean function(Connection c) throws Types.BadServerResponse, XmlRpcException { String method_call = STR; String session = c.getSessionReference(); Object[] method_params = {Marshalling.toXMLRPC(session), Marshalling.toXMLRPC(this.ref)}; Map response = c.dispatch(method_call, method_params); if(response.get(STR).equal...
/** * Get the management field of the given PIF. * * @return value of the field */
Get the management field of the given PIF
getManagement
{ "repo_name": "cc14514/hq6", "path": "hq-plugin/xen-plugin/src/main/java/com/xensource/xenapi/PIF.java", "license": "unlicense", "size": 40462 }
[ "java.util.Map", "org.apache.xmlrpc.XmlRpcException" ]
import java.util.Map; import org.apache.xmlrpc.XmlRpcException;
import java.util.*; import org.apache.xmlrpc.*;
[ "java.util", "org.apache.xmlrpc" ]
java.util; org.apache.xmlrpc;
1,883,157
private static boolean validateSection( String[] sections ) { if ( sections == null ) return false; for ( int i = 0; i < sections.length; i++ ) { try { sections[i] = URLDecoder.decode( sections[i], CharsetUtils.getSystemCharset() ); } catch (...
static boolean function( String[] sections ) { if ( sections == null ) return false; for ( int i = 0; i < sections.length; i++ ) { try { sections[i] = URLDecoder.decode( sections[i], CharsetUtils.getSystemCharset() ); } catch ( UnsupportedEncodingException e ) { e.printStackTrace(); } if ( sections[i] != null && !"/".e...
/** * valid values are: * <ul> * <li>null * <li>/ * <li>/WCS_Capabilities/CapabilitiesService * <li>/WCS_Capabilities/Capabilitiy * <li>/WCS_Capabilities/ContentMetadata * </ul> * * @param sections */
valid values are: null /WCS_Capabilities/CapabilitiesService /WCS_Capabilities/Capabilitiy /WCS_Capabilities/ContentMetadata
validateSection
{ "repo_name": "lat-lon/deegree2-base", "path": "deegree2-core/src/main/java/org/deegree/ogcwebservices/wcs/getcapabilities/WCSGetCapabilities.java", "license": "lgpl-2.1", "size": 10241 }
[ "java.io.UnsupportedEncodingException", "java.net.URLDecoder", "java.util.Map", "org.deegree.framework.util.CharsetUtils" ]
import java.io.UnsupportedEncodingException; import java.net.URLDecoder; import java.util.Map; import org.deegree.framework.util.CharsetUtils;
import java.io.*; import java.net.*; import java.util.*; import org.deegree.framework.util.*;
[ "java.io", "java.net", "java.util", "org.deegree.framework" ]
java.io; java.net; java.util; org.deegree.framework;
2,052,509
MimeMessage getMimeMessage();
MimeMessage getMimeMessage();
/** * Retrieves the entire, original RFC 822 message object * * @return the full RFC 822 message object */
Retrieves the entire, original RFC 822 message object
getMimeMessage
{ "repo_name": "Acosix/alfresco-utility", "path": "full/repository/src/main/java/de/acosix/alfresco/utility/repo/email/server/ImprovedEmailMessage.java", "license": "apache-2.0", "size": 1007 }
[ "javax.mail.internet.MimeMessage" ]
import javax.mail.internet.MimeMessage;
import javax.mail.internet.*;
[ "javax.mail" ]
javax.mail;
1,248,266
public static ByteBuffer allocateDirectNoCleaner(int capacity) { assert USE_DIRECT_BUFFER_NO_CLEANER; incrementMemoryCounter(capacity); try { return PlatformDependent0.allocateDirectNoCleaner(capacity); } catch (Throwable e) { decrementMemoryCounter(capacity)...
static ByteBuffer function(int capacity) { assert USE_DIRECT_BUFFER_NO_CLEANER; incrementMemoryCounter(capacity); try { return PlatformDependent0.allocateDirectNoCleaner(capacity); } catch (Throwable e) { decrementMemoryCounter(capacity); throwException(e); return null; } }
/** * Allocate a new {@link ByteBuffer} with the given {@code capacity}. {@link ByteBuffer}s allocated with * this method <strong>MUST</strong> be deallocated via {@link #freeDirectNoCleaner(ByteBuffer)}. */
Allocate a new <code>ByteBuffer</code> with the given capacity. <code>ByteBuffer</code>s allocated with this method MUST be deallocated via <code>#freeDirectNoCleaner(ByteBuffer)</code>
allocateDirectNoCleaner
{ "repo_name": "zer0se7en/netty", "path": "common/src/main/java/io/netty/util/internal/PlatformDependent.java", "license": "apache-2.0", "size": 59919 }
[ "java.nio.ByteBuffer" ]
import java.nio.ByteBuffer;
import java.nio.*;
[ "java.nio" ]
java.nio;
429,439
private SubredditListing getSubreddits(String which, String query, String before, String after, int count, int limit, String show) throws RedditEngineException{ StringBuilder path = new StringBuilder(); path.append("/subreddits/"); path.append(which); String url = UrlUtils.getGetUrl(path.toString()); Li...
SubredditListing function(String which, String query, String before, String after, int count, int limit, String show) throws RedditEngineException{ StringBuilder path = new StringBuilder(); path.append(STR); path.append(which); String url = UrlUtils.getGetUrl(path.toString()); List<NameValuePair> params = new ArrayList...
/** * Implementation for many subreddit api methods */
Implementation for many subreddit api methods
getSubreddits
{ "repo_name": "fizzl/RedditEngine", "path": "src/net/fizzl/redditengine/impl/SubredditsApi.java", "license": "lgpl-3.0", "size": 14459 }
[ "android.util.Log", "com.google.gson.JsonSyntaxException", "java.io.InputStream", "java.util.ArrayList", "java.util.List", "net.fizzl.redditengine.data.SubredditListing", "org.apache.http.NameValuePair", "org.apache.http.message.BasicNameValuePair" ]
import android.util.Log; import com.google.gson.JsonSyntaxException; import java.io.InputStream; import java.util.ArrayList; import java.util.List; import net.fizzl.redditengine.data.SubredditListing; import org.apache.http.NameValuePair; import org.apache.http.message.BasicNameValuePair;
import android.util.*; import com.google.gson.*; import java.io.*; import java.util.*; import net.fizzl.redditengine.data.*; import org.apache.http.*; import org.apache.http.message.*;
[ "android.util", "com.google.gson", "java.io", "java.util", "net.fizzl.redditengine", "org.apache.http" ]
android.util; com.google.gson; java.io; java.util; net.fizzl.redditengine; org.apache.http;
334,474
@Test public void testPostCopyWorksheet() { System.out.println("PostCopyWorksheet"); String name = "test_cells.xlsx"; String sheetName = "Sheet5"; String sourceSheet = "Sheet1"; String folder = ""; String storage = ""; try { SaaSposeResponse result = cellsApi.PostCopyWorksheet(name, sheetName, ...
void function() { System.out.println(STR); String name = STR; String sheetName = STR; String sourceSheet = STR; String folder = STRSTRexp:" + apiException.getMessage()); assertNull(apiException); } }
/** * Test of PostCopyWorksheet method, of class CellsApi. */
Test of PostCopyWorksheet method, of class CellsApi
testPostCopyWorksheet
{ "repo_name": "aspose-cells/Aspose.Cells-for-Cloud", "path": "SDKs/Aspose.Cells-Cloud-SDK-for-Android/Aspose.Cells-Cloud-SDK-Android/src/test/java/com/aspose/cells/api/CellsApiTest.java", "license": "mit", "size": 91749 }
[ "org.junit.Assert" ]
import org.junit.Assert;
import org.junit.*;
[ "org.junit" ]
org.junit;
239,908
public Behavior[] getBehaviors() { return behavior.getBehaviors(); }
Behavior[] function() { return behavior.getBehaviors(); }
/** * Returns the list of behaviors for this window node * @return */
Returns the list of behaviors for this window node
getBehaviors
{ "repo_name": "pperboires/PocDrools", "path": "drools-core/src/main/java/org/drools/reteoo/WindowNode.java", "license": "apache-2.0", "size": 14934 }
[ "org.drools.rule.Behavior" ]
import org.drools.rule.Behavior;
import org.drools.rule.*;
[ "org.drools.rule" ]
org.drools.rule;
737,058
@Test public void testPostgresFilter() throws Exception { String testScript[] = { "-- this is a comment", "DROP TABLE IF EXISTS fooTab;", HiveSchemaHelper.PostgresCommandParser.POSTGRES_STANDARD_STRINGS_OPT + ";", "CREATE TABLE fooTab(id INTEGER);", "DROP TABLE footab;", ...
void function() throws Exception { String testScript[] = { STR, STR, HiveSchemaHelper.PostgresCommandParser.POSTGRES_STANDARD_STRINGS_OPT + ";", STR, STR, STR }; String expectedScriptWithOptionPresent[] = { STR, HiveSchemaHelper.PostgresCommandParser.POSTGRES_STANDARD_STRINGS_OPT, STR, STR, }; NestedScriptParser noDbOp...
/** * Test script formatting */
Test script formatting
testPostgresFilter
{ "repo_name": "vineetgarg02/hive", "path": "itests/hive-unit/src/test/java/org/apache/hive/beeline/schematool/TestSchemaTool.java", "license": "apache-2.0", "size": 12222 }
[ "java.io.File", "org.apache.commons.lang3.StringUtils", "org.apache.hadoop.hive.metastore.tools.schematool.HiveSchemaHelper", "org.junit.Assert" ]
import java.io.File; import org.apache.commons.lang3.StringUtils; import org.apache.hadoop.hive.metastore.tools.schematool.HiveSchemaHelper; import org.junit.Assert;
import java.io.*; import org.apache.commons.lang3.*; import org.apache.hadoop.hive.metastore.tools.schematool.*; import org.junit.*;
[ "java.io", "org.apache.commons", "org.apache.hadoop", "org.junit" ]
java.io; org.apache.commons; org.apache.hadoop; org.junit;
1,197,336
public static java.util.List extractCarePlanEvaluationNoteList(ims.domain.ILightweightDomainFactory domainFactory, ims.nursing.vo.CarePlanEvaluationNoteCollection voCollection) { return extractCarePlanEvaluationNoteList(domainFactory, voCollection, null, new HashMap()); }
static java.util.List function(ims.domain.ILightweightDomainFactory domainFactory, ims.nursing.vo.CarePlanEvaluationNoteCollection voCollection) { return extractCarePlanEvaluationNoteList(domainFactory, voCollection, null, new HashMap()); }
/** * Create the ims.nursing.careplans.domain.objects.CarePlanEvaluationNote list from the value object collection. * @param domainFactory - used to create existing (persistent) domain objects. * @param voCollection - the collection of value objects */
Create the ims.nursing.careplans.domain.objects.CarePlanEvaluationNote list from the value object collection
extractCarePlanEvaluationNoteList
{ "repo_name": "open-health-hub/openmaxims-linux", "path": "openmaxims_workspace/ValueObjects/src/ims/nursing/vo/domain/CarePlanEvaluationNoteAssembler.java", "license": "agpl-3.0", "size": 24302 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
380,618
public static long objectToLong(Object value, boolean coerce) { if (value instanceof Long) { return (Long)value; } double doubleValue = objectToDouble(value); // this check does not guarantee that value is inside MIN_VALUE/MAX_VALUE because values...
static long function(Object value, boolean coerce) { if (value instanceof Long) { return (Long)value; } double doubleValue = objectToDouble(value); if (doubleValue < Long.MIN_VALUE doubleValue > Long.MAX_VALUE) { throw new IllegalArgumentException(STR + value + STR); } if (coerce == false && doubleValue % 1 != 0) { thr...
/** * Converts an Object to a {@code long} by checking it against known * types and checking its range. */
Converts an Object to a long by checking it against known types and checking its range
objectToLong
{ "repo_name": "ern/elasticsearch", "path": "server/src/main/java/org/elasticsearch/index/mapper/NumberFieldMapper.java", "license": "apache-2.0", "size": 50824 }
[ "org.apache.lucene.util.BytesRef", "org.elasticsearch.common.Numbers" ]
import org.apache.lucene.util.BytesRef; import org.elasticsearch.common.Numbers;
import org.apache.lucene.util.*; import org.elasticsearch.common.*;
[ "org.apache.lucene", "org.elasticsearch.common" ]
org.apache.lucene; org.elasticsearch.common;
827,830
public Response execute(RequestMethod requestMethod, Object entity) throws IOException { request.entity(entity); return execute(requestMethod); }
Response function(RequestMethod requestMethod, Object entity) throws IOException { request.entity(entity); return execute(requestMethod); }
/** * Executes the request associated with this client as a given method.<br> * <br> * <i>Note:</i> this is equivalent to invoke {@link Request#entity(Object)} and then {@link #execute(RequestMethod)}. * * @param requestMethod The method in which the request is executed * @param entity The...
Executes the request associated with this client as a given method. Note: this is equivalent to invoke <code>Request#entity(Object)</code> and then <code>#execute(RequestMethod)</code>
execute
{ "repo_name": "Parisoft/resty", "path": "src/main/java/com/github/parisoft/resty/client/Client.java", "license": "apache-2.0", "size": 35376 }
[ "com.github.parisoft.resty.request.RequestMethod", "com.github.parisoft.resty.response.Response", "java.io.IOException" ]
import com.github.parisoft.resty.request.RequestMethod; import com.github.parisoft.resty.response.Response; import java.io.IOException;
import com.github.parisoft.resty.request.*; import com.github.parisoft.resty.response.*; import java.io.*;
[ "com.github.parisoft", "java.io" ]
com.github.parisoft; java.io;
65,473
List<String> getTopGenesForIndividual(String id, Integer k);
List<String> getTopGenesForIndividual(String id, Integer k);
/** * Get a list of top k harmful genes for an individual, sorted by harmfulness. * * @param id the individual's id * @param k the max number of genes to return * * @return the list of genes */
Get a list of top k harmful genes for an individual, sorted by harmfulness
getTopGenesForIndividual
{ "repo_name": "phenotips/variant-store", "path": "variant-store/src/main/java/org/phenotips/variantstore/VariantStoreInterface.java", "license": "agpl-3.0", "size": 5208 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,268,518
private TaskDTO acquireTask() { LOG.info("Thread {} : Trying to find a task to execute", Thread.currentThread().getId()); while (!shutdown) { List<TaskDTO> anomalyTasks = new ArrayList<>(); boolean hasFetchError = false; try { boolean orderAscending = System.currentTimeMillis() % 2 =...
TaskDTO function() { LOG.info(STR, Thread.currentThread().getId()); while (!shutdown) { List<TaskDTO> anomalyTasks = new ArrayList<>(); boolean hasFetchError = false; try { boolean orderAscending = System.currentTimeMillis() % 2 == 0; anomalyTasks = taskDAO .findByStatusOrderByCreateTime(TaskStatus.WAITING, driverConfi...
/** * Returns a TaskDTO if a task is successfully acquired; returns null if system is shutting down. * * @return null if system is shutting down. */
Returns a TaskDTO if a task is successfully acquired; returns null if system is shutting down
acquireTask
{ "repo_name": "fx19880617/pinot-1", "path": "thirdeye/thirdeye-pinot/src/main/java/com/linkedin/thirdeye/anomaly/task/TaskDriver.java", "license": "apache-2.0", "size": 9022 }
[ "com.linkedin.thirdeye.anomaly.task.TaskConstants", "com.linkedin.thirdeye.datalayer.dto.TaskDTO", "java.util.ArrayList", "java.util.List", "org.apache.commons.collections.CollectionUtils" ]
import com.linkedin.thirdeye.anomaly.task.TaskConstants; import com.linkedin.thirdeye.datalayer.dto.TaskDTO; import java.util.ArrayList; import java.util.List; import org.apache.commons.collections.CollectionUtils;
import com.linkedin.thirdeye.anomaly.task.*; import com.linkedin.thirdeye.datalayer.dto.*; import java.util.*; import org.apache.commons.collections.*;
[ "com.linkedin.thirdeye", "java.util", "org.apache.commons" ]
com.linkedin.thirdeye; java.util; org.apache.commons;
1,723,337
public DenseMatrix64F getMatrix() { return mat; }
DenseMatrix64F function() { return mat; }
/** * <p> * Returns a reference to the matrix that it uses internally. This is useful when an operation is needed that is not provided by this class. * </p> * * @return Reference to the internal DenseMatrix64F. */
Returns a reference to the matrix that it uses internally. This is useful when an operation is needed that is not provided by this class.
getMatrix
{ "repo_name": "ahmetaa/lium-diarization", "path": "src/fr/lium/spkDiarization/libMatrix/MatrixBase.java", "license": "gpl-3.0", "size": 21808 }
[ "org.ejml.data.DenseMatrix64F" ]
import org.ejml.data.DenseMatrix64F;
import org.ejml.data.*;
[ "org.ejml.data" ]
org.ejml.data;
435,657
try { String line; BufferedReader in = new BufferedReader(new FileReader(filename)); documents = new Vector(); while ( (line = in.readLine()) != null ) { documents.add(line.trim()); } } catch( Exception ex ) { ex.printStackTrace(); } }
try { String line; BufferedReader in = new BufferedReader(new FileReader(filename)); documents = new Vector(); while ( (line = in.readLine()) != null ) { documents.add(line.trim()); } } catch( Exception ex ) { ex.printStackTrace(); } }
/** * Create the list of document names to keep, filter the rest */
Create the list of document names to keep, filter the rest
readFilterList
{ "repo_name": "nchambers/schemas", "path": "src/main/java/nate/GigawordFilteredText.java", "license": "apache-2.0", "size": 1616 }
[ "java.io.BufferedReader", "java.io.FileReader", "java.util.Vector" ]
import java.io.BufferedReader; import java.io.FileReader; import java.util.Vector;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
1,262,659
@Test(timeout=360000) public void testDecommissionFederation() throws IOException { testDecommission(2, 2); }
@Test(timeout=360000) void function() throws IOException { testDecommission(2, 2); }
/** * Test decommission for federeated cluster */
Test decommission for federeated cluster
testDecommissionFederation
{ "repo_name": "Bizyroth/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestDecommission.java", "license": "apache-2.0", "size": 46103 }
[ "java.io.IOException", "org.junit.Test" ]
import java.io.IOException; import org.junit.Test;
import java.io.*; import org.junit.*;
[ "java.io", "org.junit" ]
java.io; org.junit;
47,873
private BlobContainerAsyncClient getAsyncContainerClient(String containerName, boolean autoCreate) throws ExecutionException, InterruptedException { BlobContainerAsyncClient containerAsyncClient = storageAsyncClientRef.get().getBlobContainerAsyncClient(containerName); if (autoCreate) { if ...
BlobContainerAsyncClient function(String containerName, boolean autoCreate) throws ExecutionException, InterruptedException { BlobContainerAsyncClient containerAsyncClient = storageAsyncClientRef.get().getBlobContainerAsyncClient(containerName); if (autoCreate) { if (!knownContainers.contains(containerName)) { try { if...
/** * Get a reference to an Azure container async client, creating it if necessary. * @param containerName the container name. * @param autoCreate flag indicating whether to create the container if it does not exist. * @return the created {@link BlobContainerClient}. */
Get a reference to an Azure container async client, creating it if necessary
getAsyncContainerClient
{ "repo_name": "cgtz/ambry", "path": "ambry-cloud/src/main/java/com/github/ambry/cloud/azure/StorageClient.java", "license": "apache-2.0", "size": 36931 }
[ "com.azure.storage.blob.BlobContainerAsyncClient", "com.azure.storage.blob.models.BlobErrorCode", "com.azure.storage.blob.models.BlobStorageException", "java.util.concurrent.ExecutionException" ]
import com.azure.storage.blob.BlobContainerAsyncClient; import com.azure.storage.blob.models.BlobErrorCode; import com.azure.storage.blob.models.BlobStorageException; import java.util.concurrent.ExecutionException;
import com.azure.storage.blob.*; import com.azure.storage.blob.models.*; import java.util.concurrent.*;
[ "com.azure.storage", "java.util" ]
com.azure.storage; java.util;
846,428
protected Ignite startRemoteGrid( String igniteInstanceName, IgniteConfiguration cfg, GridSpringResourceContext ctx, boolean resetDiscovery ) throws Exception { if (ctx != null) throw new UnsupportedOperationException("Starting of grid at another jvm by contex...
Ignite function( String igniteInstanceName, IgniteConfiguration cfg, GridSpringResourceContext ctx, boolean resetDiscovery ) throws Exception { if (ctx != null) throw new UnsupportedOperationException(STR); if (cfg == null) cfg = optimize(getConfiguration(igniteInstanceName)); IgniteEx locNode = grid(0); if (locNode !=...
/** * Starts new grid at another JVM with given name. * * @param igniteInstanceName Ignite instance name. * @param cfg Ignite configuration. * @param ctx Spring context. * @param resetDiscovery Reset DiscoverySpi. * @return Started grid. * @throws Exception If failed. */
Starts new grid at another JVM with given name
startRemoteGrid
{ "repo_name": "nizhikov/ignite", "path": "modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java", "license": "apache-2.0", "size": 99617 }
[ "org.apache.ignite.Ignite", "org.apache.ignite.configuration.IgniteConfiguration", "org.apache.ignite.internal.IgniteEx", "org.apache.ignite.internal.processors.resource.GridSpringResourceContext", "org.apache.ignite.spi.discovery.DiscoverySpi", "org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi", "or...
import org.apache.ignite.Ignite; import org.apache.ignite.configuration.IgniteConfiguration; import org.apache.ignite.internal.IgniteEx; import org.apache.ignite.internal.processors.resource.GridSpringResourceContext; import org.apache.ignite.spi.discovery.DiscoverySpi; import org.apache.ignite.spi.discovery.tcp.TcpDis...
import org.apache.ignite.*; import org.apache.ignite.configuration.*; import org.apache.ignite.internal.*; import org.apache.ignite.internal.processors.resource.*; import org.apache.ignite.spi.discovery.*; import org.apache.ignite.spi.discovery.tcp.*; import org.apache.ignite.testframework.junits.multijvm.*;
[ "org.apache.ignite" ]
org.apache.ignite;
1,267,889