method stringlengths 13 441k | clean_method stringlengths 7 313k | doc stringlengths 17 17.3k | comment stringlengths 3 1.42k | method_name stringlengths 1 273 | extra dict | imports list | imports_info stringlengths 19 34.8k | cluster_imports_info stringlengths 15 3.66k | libraries list | libraries_info stringlengths 6 661 | id int64 0 2.92M |
|---|---|---|---|---|---|---|---|---|---|---|---|
public static BroadcastReceiver registerReceivedAckHandler( final Context context,
final PebbleAckReceiver receiver )
{
return registerBroadcastReceiverInternal( context, INTENT_APP_RECEIVE_ACK, receiver );
} | static BroadcastReceiver function( final Context context, final PebbleAckReceiver receiver ) { return registerBroadcastReceiverInternal( context, INTENT_APP_RECEIVE_ACK, receiver ); } | /**
* A convenience function to assist in programatically registering a broadcast receiver for the 'RECEIVE_ACK'
* intent.
* <p/>
* To avoid leaking memory, activities registering BroadcastReceivers <em>must</em> unregister them in the
* Activity's {@link android.app.Activity#onPause()} method.
*
* @param... | A convenience function to assist in programatically registering a broadcast receiver for the 'RECEIVE_ACK' intent. To avoid leaking memory, activities registering BroadcastReceivers must unregister them in the Activity's <code>android.app.Activity#onPause()</code> method | registerReceivedAckHandler | {
"repo_name": "zaxebo1/RingMyPhoneAndroid",
"path": "RingMyPhone/src/main/java/com/getpebble/android/kit/PebbleKit.java",
"license": "mit",
"size": 35095
} | [
"android.content.BroadcastReceiver",
"android.content.Context"
] | import android.content.BroadcastReceiver; import android.content.Context; | import android.content.*; | [
"android.content"
] | android.content; | 1,926,524 |
public int getDaysBetweenDates(Date startDate, Date endDate)
{
long diff = endDate.getTime() - startDate.getTime();
double daysdiff = diff / (double) MILLISECONDS_PER_DAY;
int days = (int) Math.ceil(daysdiff);
return Math.abs(days);
} | int function(Date startDate, Date endDate) { long diff = endDate.getTime() - startDate.getTime(); double daysdiff = diff / (double) MILLISECONDS_PER_DAY; int days = (int) Math.ceil(daysdiff); return Math.abs(days); } | /**
* Calculate the number of days between two dates
*
* @param startDate The start date of the period
* @param endDate The end date of the period
* @return The number of days difference
*/ | Calculate the number of days between two dates | getDaysBetweenDates | {
"repo_name": "petebarnett/OpenRate",
"path": "src/main/java/OpenRate/process/AbstractProRation.java",
"license": "gpl-2.0",
"size": 14929
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 1,952,932 |
public ParameterService getParameterService() {
return parameterService;
} | ParameterService function() { return parameterService; } | /**
* Gets the parameterService attribute.
*
* @return Returns the parameterService.
*/ | Gets the parameterService attribute | getParameterService | {
"repo_name": "quikkian-ua-devops/will-financials",
"path": "kfs-core/src/main/java/org/kuali/kfs/gl/batch/service/impl/EncumbranceClosingOriginEntryGenerationServiceImpl.java",
"license": "agpl-3.0",
"size": 35661
} | [
"org.kuali.kfs.coreservice.framework.parameter.ParameterService"
] | import org.kuali.kfs.coreservice.framework.parameter.ParameterService; | import org.kuali.kfs.coreservice.framework.parameter.*; | [
"org.kuali.kfs"
] | org.kuali.kfs; | 1,557,101 |
public void triggerEvents(final TriggerEvent[] evts)
throws ModelException {
if (evts != null) {
for (TriggerEvent evt : evts) {
addEvent(evt);
}
}
triggerEvents();
} | void function(final TriggerEvent[] evts) throws ModelException { if (evts != null) { for (TriggerEvent evt : evts) { addEvent(evt); } } triggerEvents(); } | /**
* The worker method.
* Re-evaluates current status whenever any events are triggered.
*
* @param evts
* an array of external events which triggered during the last
* time quantum
* @throws ModelException in case there is a fatal SCXML object
* ... | The worker method. Re-evaluates current status whenever any events are triggered | triggerEvents | {
"repo_name": "catalia-health/scxml2-android",
"path": "src/main/java/org/apache/commons/scxml2/SCXMLExecutor.java",
"license": "apache-2.0",
"size": 17742
} | [
"org.apache.commons.scxml2.model.ModelException"
] | import org.apache.commons.scxml2.model.ModelException; | import org.apache.commons.scxml2.model.*; | [
"org.apache.commons"
] | org.apache.commons; | 1,974,232 |
private void selectNode(Node node) {
deselectNode();
NodeController.getGUI(node).setSelectedFlag(true);
setSelectedNode(node);
} | void function(Node node) { deselectNode(); NodeController.getGUI(node).setSelectedFlag(true); setSelectedNode(node); } | /**
* Selects a node. The selected node changes its color.
*
* @param node
* The node to select.
*/ | Selects a node. The selected node changes its color | selectNode | {
"repo_name": "glahiru/airavata",
"path": "modules/xbaya-gui/src/main/java/org/apache/airavata/xbaya/ui/graph/GraphCanvas.java",
"license": "apache-2.0",
"size": 46565
} | [
"org.apache.airavata.workflow.model.graph.Node",
"org.apache.airavata.xbaya.graph.controller.NodeController"
] | import org.apache.airavata.workflow.model.graph.Node; import org.apache.airavata.xbaya.graph.controller.NodeController; | import org.apache.airavata.workflow.model.graph.*; import org.apache.airavata.xbaya.graph.controller.*; | [
"org.apache.airavata"
] | org.apache.airavata; | 1,790,615 |
private Notification createNotfication(Context context) {
CharSequence tickerText = context.getString(R.string.notification_status_bar_message);
long when = System.currentTimeMillis();
return new Notification(R.drawable.report_icon, tickerText, when);
} | Notification function(Context context) { CharSequence tickerText = context.getString(R.string.notification_status_bar_message); long when = System.currentTimeMillis(); return new Notification(R.drawable.report_icon, tickerText, when); } | /**
* Create notification for status bar to inform the user at least one off
* line message were sent
*
* @return Notification
*/ | Create notification for status bar to inform the user at least one off line message were sent | createNotfication | {
"repo_name": "pdoffice35/SVQCOM",
"path": "Core/src/com/ushahidi/android/app/OfflineIncidentSendReceiver.java",
"license": "lgpl-3.0",
"size": 7272
} | [
"android.app.Notification",
"android.content.Context"
] | import android.app.Notification; import android.content.Context; | import android.app.*; import android.content.*; | [
"android.app",
"android.content"
] | android.app; android.content; | 184,679 |
public void
uninstall()
throws PluginException;
| void function() throws PluginException; | /**
* uninstall this plugin
* @throws PluginException
*/ | uninstall this plugin | uninstall | {
"repo_name": "AcademicTorrents/AcademicTorrents-Downloader",
"path": "vuze/org/gudy/azureus2/plugins/installer/InstallablePlugin.java",
"license": "gpl-2.0",
"size": 2165
} | [
"org.gudy.azureus2.plugins.PluginException"
] | import org.gudy.azureus2.plugins.PluginException; | import org.gudy.azureus2.plugins.*; | [
"org.gudy.azureus2"
] | org.gudy.azureus2; | 2,174,909 |
public KeyValue createKVFromCellVisibilityExpr(int rowKeyOffset, int rowKeyLength, byte[] family,
int familyOffset, int familyLength, byte[] qualifier, int qualifierOffset,
int qualifierLength, long ts, Type put, byte[] lineBytes, int columnOffset, int columnLength,
String cellVisibilityExpr) throws... | KeyValue function(int rowKeyOffset, int rowKeyLength, byte[] family, int familyOffset, int familyLength, byte[] qualifier, int qualifierOffset, int qualifierLength, long ts, Type put, byte[] lineBytes, int columnOffset, int columnLength, String cellVisibilityExpr) throws IOException, BadTsvLineException { if(this.label... | /**
* Creates a kv from the cell visibility expr specified in the ImportTSV and uses it as the
* visibility tag in the kv
* @param rowKeyOffset
* @param rowKeyLength
* @param family
* @param familyOffset
* @param familyLength
* @param qualifier
* @param qualifierOffset
* @param qualifierLe... | Creates a kv from the cell visibility expr specified in the ImportTSV and uses it as the visibility tag in the kv | createKVFromCellVisibilityExpr | {
"repo_name": "mapr/hbase",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/LabelExpander.java",
"license": "apache-2.0",
"size": 9299
} | [
"java.io.IOException",
"java.util.List",
"org.apache.hadoop.hbase.KeyValue",
"org.apache.hadoop.hbase.Tag",
"org.apache.hadoop.hbase.mapreduce.ImportTsv",
"org.apache.hadoop.hbase.security.visibility.ParseException"
] | import java.io.IOException; import java.util.List; import org.apache.hadoop.hbase.KeyValue; import org.apache.hadoop.hbase.Tag; import org.apache.hadoop.hbase.mapreduce.ImportTsv; import org.apache.hadoop.hbase.security.visibility.ParseException; | import java.io.*; import java.util.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.mapreduce.*; import org.apache.hadoop.hbase.security.visibility.*; | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 2,332,503 |
@Test
public void testTimestampExtractorWithDecreasingCustomWatermarkEmit() throws Exception {
final int NUM_ELEMENTS = 10;
StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment();
env.setStreamTimeCharacteristic(TimeCharacteristic.EventTime);
env.getConfig().setAutoWatermark... | void function() throws Exception { final int NUM_ELEMENTS = 10; StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment(); env.setStreamTimeCharacteristic(TimeCharacteristic.EventTime); env.getConfig().setAutoWatermarkInterval(1); env.setParallelism(1); env.getConfig().disableSysoutLogging()... | /**
* This test verifies that the timestamp extractor does not emit decreasing watermarks even
*
*/ | This test verifies that the timestamp extractor does not emit decreasing watermarks even | testTimestampExtractorWithDecreasingCustomWatermarkEmit | {
"repo_name": "WangTaoTheTonic/flink",
"path": "flink-tests/src/test/java/org/apache/flink/test/streaming/runtime/TimestampITCase.java",
"license": "apache-2.0",
"size": 27514
} | [
"org.apache.flink.streaming.api.TimeCharacteristic",
"org.apache.flink.streaming.api.environment.StreamExecutionEnvironment"
] | import org.apache.flink.streaming.api.TimeCharacteristic; import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment; | import org.apache.flink.streaming.api.*; import org.apache.flink.streaming.api.environment.*; | [
"org.apache.flink"
] | org.apache.flink; | 318,908 |
private JPanel getUnformattedHanyuPinyinPanel()
{
if (unformattedHanyuPinyinPanel == null)
{
unformattedHanyuPinyinPanel = new JPanel();
unformattedHanyuPinyinPanel.setLayout(new BorderLayout()); // Generated
unformattedHanyuPinyinPanel.add(unformattedHa... | JPanel function() { if (unformattedHanyuPinyinPanel == null) { unformattedHanyuPinyinPanel = new JPanel(); unformattedHanyuPinyinPanel.setLayout(new BorderLayout()); unformattedHanyuPinyinPanel.add(unformattedHanyuPinyinLabel, BorderLayout.NORTH); unformattedHanyuPinyinPanel.add(getUnformattedHanyuPinyinScrollPane(), B... | /**
* This method initializes unformattedHanyuPinyinPanel
*
* @return javax.swing.JPanel
*/ | This method initializes unformattedHanyuPinyinPanel | getUnformattedHanyuPinyinPanel | {
"repo_name": "bruce-yang/javabase",
"path": "src/com/base/utils/Pinyin4jAppletDemo.java",
"license": "apache-2.0",
"size": 29074
} | [
"java.awt.BorderLayout",
"javax.swing.JPanel"
] | import java.awt.BorderLayout; import javax.swing.JPanel; | import java.awt.*; import javax.swing.*; | [
"java.awt",
"javax.swing"
] | java.awt; javax.swing; | 1,007,082 |
public HttpServer webSocketHandler(final String prefix,
final HandlerFactory<? extends ChannelHandler> factory) {
webSocketHandlers.put(prefix, factory);
return this;
} | HttpServer function(final String prefix, final HandlerFactory<? extends ChannelHandler> factory) { webSocketHandlers.put(prefix, factory); return this; } | /**
* Add a websocket handler factory for the given prefix.
*/ | Add a websocket handler factory for the given prefix | webSocketHandler | {
"repo_name": "barchart/barchart-netty4",
"path": "server/src/main/java/com/barchart/netty/server/http/HttpServer.java",
"license": "bsd-3-clause",
"size": 9804
} | [
"com.barchart.netty.server.HandlerFactory",
"io.netty.channel.ChannelHandler"
] | import com.barchart.netty.server.HandlerFactory; import io.netty.channel.ChannelHandler; | import com.barchart.netty.server.*; import io.netty.channel.*; | [
"com.barchart.netty",
"io.netty.channel"
] | com.barchart.netty; io.netty.channel; | 1,676,011 |
private List<TaskProperty> getMissingProperties() {
List<TaskProperty> newList = new ArrayList<TaskProperty>();
for (String prop : properties) {
boolean isAvailable = false;
for (TaskProperty property : taskPropertyList) {
if (prop.equals(property.getPropertyName())) {
isAvailable = true;
bre... | List<TaskProperty> function() { List<TaskProperty> newList = new ArrayList<TaskProperty>(); for (String prop : properties) { boolean isAvailable = false; for (TaskProperty property : taskPropertyList) { if (prop.equals(property.getPropertyName())) { isAvailable = true; break; } } if (!isAvailable) { TaskProperty tskPro... | /**
* Get missing required properties
*/ | Get missing required properties | getMissingProperties | {
"repo_name": "prabushi/devstudio-tooling-esb",
"path": "plugins/org.wso2.developerstudio.esb.form.editors/src/org/wso2/developerstudio/esb/form/editors/article/providers/TaskPropertyDialog.java",
"license": "apache-2.0",
"size": 16185
} | [
"java.util.ArrayList",
"java.util.List",
"org.wso2.developerstudio.eclipse.gmf.esb.TaskProperty"
] | import java.util.ArrayList; import java.util.List; import org.wso2.developerstudio.eclipse.gmf.esb.TaskProperty; | import java.util.*; import org.wso2.developerstudio.eclipse.gmf.esb.*; | [
"java.util",
"org.wso2.developerstudio"
] | java.util; org.wso2.developerstudio; | 103,505 |
public String toString(final Charset charset) {
return new String(toByteArray(), charset);
} | String function(final Charset charset) { return new String(toByteArray(), charset); } | /**
* Gets the current contents of this byte stream as a string
* using the specified encoding.
*
* @param charset the character encoding
* @return the string converted from the byte array
* @see java.io.ByteArrayOutputStream#toString(String)
* @since 2.5
*/ | Gets the current contents of this byte stream as a string using the specified encoding | toString | {
"repo_name": "apache/commons-io",
"path": "src/main/java/org/apache/commons/io/output/AbstractByteArrayOutputStream.java",
"license": "apache-2.0",
"size": 14636
} | [
"java.nio.charset.Charset"
] | import java.nio.charset.Charset; | import java.nio.charset.*; | [
"java.nio"
] | java.nio; | 88,856 |
void onItemChosen(View labelledSpinner, AdapterView<?> adapterView, View itemView, int position, long id); | void onItemChosen(View labelledSpinner, AdapterView<?> adapterView, View itemView, int position, long id); | /**
* Callback method to be invoked when an item in this LabelledSpinner's
* spinner view has been selected. This callback is invoked only when
* the newly selected position is different from the previously selected
* position or if there was no selected item.
*
* @... | Callback method to be invoked when an item in this LabelledSpinner's spinner view has been selected. This callback is invoked only when the newly selected position is different from the previously selected position or if there was no selected item | onItemChosen | {
"repo_name": "weslly99/glucosio-android",
"path": "app/src/main/java/org/glucosio/android/tools/LabelledSpinner.java",
"license": "gpl-3.0",
"size": 13970
} | [
"android.view.View",
"android.widget.AdapterView"
] | import android.view.View; import android.widget.AdapterView; | import android.view.*; import android.widget.*; | [
"android.view",
"android.widget"
] | android.view; android.widget; | 319,698 |
@Test
public void testRootOnly() throws Exception {
Directory indexDir = newDirectory();
TaxonomyWriter tw = new DirectoryTaxonomyWriter(indexDir);
// right after opening the index, it should already contain the
// root, so have size 1:
assertEquals(1, tw.getSize());
tw.close();
Taxonomy... | void function() throws Exception { Directory indexDir = newDirectory(); TaxonomyWriter tw = new DirectoryTaxonomyWriter(indexDir); assertEquals(1, tw.getSize()); tw.close(); TaxonomyReader tr = new DirectoryTaxonomyReader(indexDir); assertEquals(1, tr.getSize()); assertEquals(0, tr.getPath(0).length); assertEquals(Taxo... | /** Test writing an empty index, and seeing that a reader finds in it
the root category, and only it. We check all the methods on that
root category return the expected results.
*/ | Test writing an empty index, and seeing that a reader finds in it | testRootOnly | {
"repo_name": "kankedong/solr_reading",
"path": "lucene/facet/src/test/org/apache/lucene/facet/taxonomy/TestTaxonomyCombined.java",
"license": "apache-2.0",
"size": 41836
} | [
"org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyReader",
"org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyWriter",
"org.apache.lucene.store.Directory"
] | import org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyReader; import org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyWriter; import org.apache.lucene.store.Directory; | import org.apache.lucene.facet.taxonomy.directory.*; import org.apache.lucene.store.*; | [
"org.apache.lucene"
] | org.apache.lucene; | 746,176 |
public Color getBorderColor(Object entity); | Color function(Object entity); | /**
* Returns the background colour for this entity. May return null for
* defaults. Any resources created by this class must be disposed by this
* class.
*
* @param entity
* the entity to be styled.
* @return the background colour for this entity.
* @see #dispose()
... | Returns the background colour for this entity. May return null for defaults. Any resources created by this class must be disposed by this class | getBorderColor | {
"repo_name": "archimatetool/archi",
"path": "org.eclipse.zest.core/src/org/eclipse/zest/core/viewers/IEntityStyleProvider.java",
"license": "mit",
"size": 4758
} | [
"org.eclipse.swt.graphics.Color"
] | import org.eclipse.swt.graphics.Color; | import org.eclipse.swt.graphics.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 187,978 |
private void enableImport(GoodsType gt) {
if (gt == null) return;
for (int stopIndex : this.stopList.getSelectedIndices()) {
TradeRouteStop stop = this.stopListModel.get(stopIndex);
stop.addCargo(gt);
}
this.stopList.revalidate();
this.stopList.repaint... | void function(GoodsType gt) { if (gt == null) return; for (int stopIndex : this.stopList.getSelectedIndices()) { TradeRouteStop stop = this.stopListModel.get(stopIndex); stop.addCargo(gt); } this.stopList.revalidate(); this.stopList.repaint(); } | /**
* Import new goods at the selected stops.
*
* @param gt The {@code GoodsType} to import.
*/ | Import new goods at the selected stops | enableImport | {
"repo_name": "FreeCol/freecol",
"path": "src/net/sf/freecol/client/gui/panel/TradeRouteInputPanel.java",
"license": "gpl-2.0",
"size": 26976
} | [
"net.sf.freecol.common.model.GoodsType",
"net.sf.freecol.common.model.TradeRouteStop"
] | import net.sf.freecol.common.model.GoodsType; import net.sf.freecol.common.model.TradeRouteStop; | import net.sf.freecol.common.model.*; | [
"net.sf.freecol"
] | net.sf.freecol; | 1,810,088 |
protected File getScriptForWSDL(File wsdlFile) {
String wsdlFileName = wsdlFile.getName();
String fileSuffix = wsdlFileName.substring(0, wsdlFileName.lastIndexOf('.') );
File wsdlFileDir = wsdlFile.getParentFile();
String[] files = wsdlFileDir.list();
for (int i = 0; i < file... | File function(File wsdlFile) { String wsdlFileName = wsdlFile.getName(); String fileSuffix = wsdlFileName.substring(0, wsdlFileName.lastIndexOf('.') ); File wsdlFileDir = wsdlFile.getParentFile(); String[] files = wsdlFileDir.list(); for (int i = 0; i < files.length; i++) { if (!files[i].equals(wsdlFileName) && files[i... | /**
* Gets the script associated with the wsdl. The associated script is the
* file with the same name as the wsdl file excluding the file suffix, for
* example, stockquote.js and stockquote.wsdl.
*/ | Gets the script associated with the wsdl. The associated script is the file with the same name as the wsdl file excluding the file suffix, for example, stockquote.js and stockquote.wsdl | getScriptForWSDL | {
"repo_name": "apache/axis2-java",
"path": "modules/scripting/src/org/apache/axis2/scripting/ScriptDeploymentEngine.java",
"license": "apache-2.0",
"size": 10860
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 2,186,344 |
@Generated
@Selector("setVelocity:")
public native void setVelocity(@NFloat double value); | @Selector(STR) native void function(@NFloat double value); | /**
* The initial mean velocity of each emitted object, and its range. Both
* values default to zero. Animatable.
*/ | The initial mean velocity of each emitted object, and its range. Both values default to zero. Animatable | setVelocity | {
"repo_name": "multi-os-engine/moe-core",
"path": "moe.apple/moe.platform.ios/src/main/java/apple/quartzcore/CAEmitterCell.java",
"license": "apache-2.0",
"size": 20919
} | [
"org.moe.natj.general.ann.NFloat",
"org.moe.natj.objc.ann.Selector"
] | import org.moe.natj.general.ann.NFloat; import org.moe.natj.objc.ann.Selector; | import org.moe.natj.general.ann.*; import org.moe.natj.objc.ann.*; | [
"org.moe.natj"
] | org.moe.natj; | 2,118,675 |
public final Element encodeWS(final String s) {
return new Element("span", getVersion().getTEXT()).setContent(encodeWSasList(s));
}
| final Element function(final String s) { return new Element("span", getVersion().getTEXT()).setContent(encodeWSasList(s)); } | /**
* Encode a String to OO XML. Handles substition of whitespaces to their OO equivalent.
*
* @param s a plain ole String, eg "term\tdefinition".
* @return an Element suitable to be inserted in an OO XML document, eg
*
* <pre>
* <text:span>term<text:tab-... | Encode a String to OO XML. Handles substition of whitespaces to their OO equivalent | encodeWS | {
"repo_name": "eric-lemesre/OpenConcerto",
"path": "OpenConcerto/src/org/openconcerto/openoffice/OOXML.java",
"license": "gpl-3.0",
"size": 21034
} | [
"org.jdom.Element"
] | import org.jdom.Element; | import org.jdom.*; | [
"org.jdom"
] | org.jdom; | 1,427,492 |
private void initializeStructureForAllViews( LookUpCameraInfo db, int numberOfFeatures, View seed, DogArray_I32 seedConnIdx ) {
utils.observations.initialize(1 + seedConnIdx.size);
utils.structure.initialize(1 + seedConnIdx.size, numberOfFeatures);
viewsByStructureIndex.resize(utils.structure.views.size, null)... | void function( LookUpCameraInfo db, int numberOfFeatures, View seed, DogArray_I32 seedConnIdx ) { utils.observations.initialize(1 + seedConnIdx.size); utils.structure.initialize(1 + seedConnIdx.size, numberOfFeatures); viewsByStructureIndex.resize(utils.structure.views.size, null); utils.triangulateFeatures(); db.looku... | /**
* Initializes the bundle adjustment structure for all views not just the initial set of 3. The seed view is
* view index=0. The other views are in order of `seedConnIdx` after that.
*/ | Initializes the bundle adjustment structure for all views not just the initial set of 3. The seed view is view index=0. The other views are in order of `seedConnIdx` after that | initializeStructureForAllViews | {
"repo_name": "lessthanoptimal/BoofCV",
"path": "main/boofcv-reconstruction/src/main/java/boofcv/alg/structure/ProjectiveInitializeAllCommon.java",
"license": "apache-2.0",
"size": 22136
} | [
"org.ddogleg.struct.DogArray"
] | import org.ddogleg.struct.DogArray; | import org.ddogleg.struct.*; | [
"org.ddogleg.struct"
] | org.ddogleg.struct; | 1,098,563 |
public StatementBuilder withBindVariableValue(String key, Value value) {
queryBuilder.withBindVariableValue(key, value);
return this;
}
/**
* Gets the {@link Statement} representing the state of this statement
* builder.
*
* @return the {@link Statement} | StatementBuilder function(String key, Value value) { queryBuilder.withBindVariableValue(key, value); return this; } /** * Gets the {@link Statement} representing the state of this statement * builder. * * @return the {@link Statement} | /**
* Adds a bind variable value to the statement.
*
* @param key the value key
* @param value the bind variable value
* @return a reference to this object
*/ | Adds a bind variable value to the statement | withBindVariableValue | {
"repo_name": "gawkermedia/googleads-java-lib",
"path": "modules/dfp_axis/src/main/java/com/google/api/ads/dfp/axis/utils/v201602/StatementBuilder.java",
"license": "apache-2.0",
"size": 4547
} | [
"com.google.api.ads.dfp.axis.v201602.Statement",
"com.google.api.ads.dfp.axis.v201602.Value"
] | import com.google.api.ads.dfp.axis.v201602.Statement; import com.google.api.ads.dfp.axis.v201602.Value; | import com.google.api.ads.dfp.axis.v201602.*; | [
"com.google.api"
] | com.google.api; | 661,456 |
public static void createApplicationFolders() {
// create the user files directory
if ( !fileExists( CONFIG_FILES_DIR_PATH ) ) {
new File( CONFIG_FILES_DIR_PATH ).mkdir();
}
// create the business rules directory
if ( !fileExists( BUSINESS_RULES_DIR_PATH ) ) {
new File( BUSINESS_RULES_DI... | static void function() { if ( !fileExists( CONFIG_FILES_DIR_PATH ) ) { new File( CONFIG_FILES_DIR_PATH ).mkdir(); } if ( !fileExists( BUSINESS_RULES_DIR_PATH ) ) { new File( BUSINESS_RULES_DIR_PATH ).mkdir(); } if ( !fileExists( PREF_DIR_PATH ) ) { new File( PREF_DIR_PATH ).mkdir(); } if ( !fileExists( CHECK_DIR_PATH )... | /**
* Create the application folders if they do not exist
*/ | Create the application folders if they do not exist | createApplicationFolders | {
"repo_name": "openefsa/CatalogueBrowser",
"path": "src/utilities/GlobalUtil.java",
"license": "lgpl-3.0",
"size": 19707
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 2,750,808 |
public static String encodeHost(String host, String encoding) throws UnsupportedEncodingException {
return encode(host, encoding, HOST);
} | static String function(String host, String encoding) throws UnsupportedEncodingException { return encode(host, encoding, HOST); } | /**
* Encodes the given URI host.
*
* @param host the host to be encoded
* @param encoding the character encoding to encode to
* @return the encoded host
* @throws UnsupportedEncodingException when the given encoding parameter is not supported
*/ | Encodes the given URI host | encodeHost | {
"repo_name": "sosilent/euca",
"path": "clc/modules/www/test-gwt/src/com/eucalyptus/webui/server/UriUtils.java",
"license": "gpl-3.0",
"size": 13496
} | [
"java.io.UnsupportedEncodingException"
] | import java.io.UnsupportedEncodingException; | import java.io.*; | [
"java.io"
] | java.io; | 52,244 |
public void emptyElement(QName element, XMLAttributes attributes, Augmentations augs)
throws XNIException {
startElement(element, attributes, augs);
endElement(element, augs);
} // emptyElement(QName,XMLAttributes)
| void function(QName element, XMLAttributes attributes, Augmentations augs) throws XNIException { startElement(element, attributes, augs); endElement(element, augs); } | /**
* An empty element.
*
* @param element The name of the element.
* @param attributes The element attributes.
* @param augs Additional information that may include infoset augmentations
*
* @throws XNIException Thrown by handler to signal an error.
*/ | An empty element | emptyElement | {
"repo_name": "AaronZhangL/SplitCharater",
"path": "xerces-2_11_0/src/org/apache/xerces/parsers/AbstractXMLDocumentParser.java",
"license": "gpl-2.0",
"size": 31977
} | [
"org.apache.xerces.xni.Augmentations",
"org.apache.xerces.xni.QName",
"org.apache.xerces.xni.XMLAttributes",
"org.apache.xerces.xni.XNIException"
] | import org.apache.xerces.xni.Augmentations; import org.apache.xerces.xni.QName; import org.apache.xerces.xni.XMLAttributes; import org.apache.xerces.xni.XNIException; | import org.apache.xerces.xni.*; | [
"org.apache.xerces"
] | org.apache.xerces; | 1,225,600 |
private void closedNotifyClients()
{
TransportClient[] clients;
synchronized ( owners )
{
// check if still acquired
int refs = owners.size ();
if ( refs == 0 )
{
return;
}
logger.log(Level.FINE,"Transport to " + socketAddress + "... | void function() { TransportClient[] clients; synchronized ( owners ) { int refs = owners.size (); if ( refs == 0 ) { return; } logger.log(Level.FINE,STR + socketAddress + STR + refs + STR); clients = new TransportClient[ refs ]; owners.toArray (clients); owners.clear (); } for ( TransportClient client : clients ) { try... | /**
* Notifies clients about disconnect.
*/ | Notifies clients about disconnect | closedNotifyClients | {
"repo_name": "channelaccess/ca",
"path": "src/main/java/org/epics/ca/impl/TcpTransport.java",
"license": "gpl-3.0",
"size": 26309
} | [
"java.util.logging.Level"
] | import java.util.logging.Level; | import java.util.logging.*; | [
"java.util"
] | java.util; | 2,584,336 |
public void setConfigFile(File configFile) {
setConfig(project.getResources().getText().fromFile(configFile));
} | void function(File configFile) { setConfig(project.getResources().getText().fromFile(configFile)); } | /**
* The Checkstyle configuration file to use.
*/ | The Checkstyle configuration file to use | setConfigFile | {
"repo_name": "robinverduijn/gradle",
"path": "subprojects/code-quality/src/main/groovy/org/gradle/api/plugins/quality/CheckstyleExtension.java",
"license": "apache-2.0",
"size": 6238
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 1,452,292 |
public TextView getMonthTitleTextView() {
return monthTitleTextView;
} | TextView function() { return monthTitleTextView; } | /**
* To let client customize month title textview
*/ | To let client customize month title textview | getMonthTitleTextView | {
"repo_name": "javake/Caldroid",
"path": "library/src/com/roomorama/caldroid/CaldroidFragment.java",
"license": "mit",
"size": 36856
} | [
"android.widget.TextView"
] | import android.widget.TextView; | import android.widget.*; | [
"android.widget"
] | android.widget; | 2,214,623 |
CustomCommandLine buildSingleJarCommandLine(BuildConfiguration configuration,
Artifact output, String mainClass, ImmutableList<String> manifestLines,
Iterable<Artifact> buildInfoFiles, ImmutableList<Artifact> resources,
Iterable<Artifact> classpath, boolean includeBuildData,
Compression compre... | CustomCommandLine buildSingleJarCommandLine(BuildConfiguration configuration, Artifact output, String mainClass, ImmutableList<String> manifestLines, Iterable<Artifact> buildInfoFiles, ImmutableList<Artifact> resources, Iterable<Artifact> classpath, boolean includeBuildData, Compression compression, Artifact launcher); | /**
* Constructs the command line to call SingleJar to join all artifacts from
* {@code classpath} (java code) and {@code resources} into {@code output}.
*/ | Constructs the command line to call SingleJar to join all artifacts from classpath (java code) and resources into output | buildSingleJarCommandLine | {
"repo_name": "gavares/bazel",
"path": "src/main/java/com/google/devtools/build/lib/rules/java/JavaSemantics.java",
"license": "apache-2.0",
"size": 15348
} | [
"com.google.common.collect.ImmutableList",
"com.google.devtools.build.lib.actions.Artifact",
"com.google.devtools.build.lib.analysis.actions.CustomCommandLine",
"com.google.devtools.build.lib.analysis.config.BuildConfiguration",
"com.google.devtools.build.lib.rules.java.DeployArchiveBuilder"
] | import com.google.common.collect.ImmutableList; import com.google.devtools.build.lib.actions.Artifact; import com.google.devtools.build.lib.analysis.actions.CustomCommandLine; import com.google.devtools.build.lib.analysis.config.BuildConfiguration; import com.google.devtools.build.lib.rules.java.DeployArchiveBuilder; | import com.google.common.collect.*; import com.google.devtools.build.lib.actions.*; import com.google.devtools.build.lib.analysis.actions.*; import com.google.devtools.build.lib.analysis.config.*; import com.google.devtools.build.lib.rules.java.*; | [
"com.google.common",
"com.google.devtools"
] | com.google.common; com.google.devtools; | 1,807,114 |
public final Verification getVerification(final Id<Verification> id)
throws IOException, OptimalException {
final Request request = Request.builder()
.uri(prepareUri(VERIFY_PATH + id))
.method(Request.RequestType.GET)
.build();
return client.processRequest(r... | final Verification function(final Id<Verification> id) throws IOException, OptimalException { final Request request = Request.builder() .uri(prepareUri(VERIFY_PATH + id)) .method(Request.RequestType.GET) .build(); return client.processRequest(request, Verification.class); } | /**
* Get an verification by id.
*
* @param id the id
* @return Verification
* @throws IOException Signals that an I/O exception has occurred.
* @throws OptimalException the optimal exception
*/ | Get an verification by id | getVerification | {
"repo_name": "OptimalPayments/Java_SDK",
"path": "NetBanxSDK/src/main/java/com/optimalpayments/cardpayments/CardPaymentsService.java",
"license": "mit",
"size": 24566
} | [
"com.optimalpayments.common.Id",
"com.optimalpayments.common.OptimalException",
"com.optimalpayments.common.impl.Request",
"java.io.IOException"
] | import com.optimalpayments.common.Id; import com.optimalpayments.common.OptimalException; import com.optimalpayments.common.impl.Request; import java.io.IOException; | import com.optimalpayments.common.*; import com.optimalpayments.common.impl.*; import java.io.*; | [
"com.optimalpayments.common",
"java.io"
] | com.optimalpayments.common; java.io; | 2,496,021 |
public static MessageTemplate getInstance(
ServletContext context,
String path) {
RequestDispatcher dispatcher = context.getRequestDispatcher(path);
if (dispatcher == null) {
return null;
}
MessageTemplate templ = new MessageTemplate();
te... | static MessageTemplate function( ServletContext context, String path) { RequestDispatcher dispatcher = context.getRequestDispatcher(path); if (dispatcher == null) { return null; } MessageTemplate templ = new MessageTemplate(); templ.servletContext = context; templ.path = path; templ.dispatcher = dispatcher; return temp... | /**
* Create and return a <code>MessageTemplate</code> instance for the
* specified context and path.
* @param context the context that the requested template belongs to
* @param path the path to the requested template
* @return a <code>MessageTemplate</code> instance or
* ... | Create and return a <code>MessageTemplate</code> instance for the specified context and path | getInstance | {
"repo_name": "rogersuen/jmp",
"path": "taglib/src/main/java/org/javaplus/jmp/MessageTemplate.java",
"license": "apache-2.0",
"size": 3333
} | [
"javax.servlet.RequestDispatcher",
"javax.servlet.ServletContext"
] | import javax.servlet.RequestDispatcher; import javax.servlet.ServletContext; | import javax.servlet.*; | [
"javax.servlet"
] | javax.servlet; | 2,205,809 |
@ResponseBody
@ExceptionHandler(PersonNotFoundException.class)
@ResponseStatus(HttpStatus.FORBIDDEN)
VndErrors courseTopicAlreadyExistExceptionHandler(PersonNotFoundException ex) {
return new VndErrors(HttpStatus.FORBIDDEN.getReasonPhrase(), ex.getLocalizedMessage());
} | @ExceptionHandler(PersonNotFoundException.class) @ResponseStatus(HttpStatus.FORBIDDEN) VndErrors courseTopicAlreadyExistExceptionHandler(PersonNotFoundException ex) { return new VndErrors(HttpStatus.FORBIDDEN.getReasonPhrase(), ex.getLocalizedMessage()); } | /**
*
* Catch <code>PersonNotFoundException</code> exception thrown by any endpoint and change the return code.
*
* @param ex
* @return
*/ | Catch <code>PersonNotFoundException</code> exception thrown by any endpoint and change the return code | courseTopicAlreadyExistExceptionHandler | {
"repo_name": "gustavoorsi/deprecated",
"path": "referaice-searchengine-api/src/main/java/com/referaice/api/aop/ExceptionControllerAdvice.java",
"license": "gpl-2.0",
"size": 3502
} | [
"com.referaice.model.entitties.exceptions.PersonNotFoundException",
"org.springframework.hateoas.VndErrors",
"org.springframework.http.HttpStatus",
"org.springframework.web.bind.annotation.ExceptionHandler",
"org.springframework.web.bind.annotation.ResponseStatus"
] | import com.referaice.model.entitties.exceptions.PersonNotFoundException; import org.springframework.hateoas.VndErrors; import org.springframework.http.HttpStatus; import org.springframework.web.bind.annotation.ExceptionHandler; import org.springframework.web.bind.annotation.ResponseStatus; | import com.referaice.model.entitties.exceptions.*; import org.springframework.hateoas.*; import org.springframework.http.*; import org.springframework.web.bind.annotation.*; | [
"com.referaice.model",
"org.springframework.hateoas",
"org.springframework.http",
"org.springframework.web"
] | com.referaice.model; org.springframework.hateoas; org.springframework.http; org.springframework.web; | 2,756,881 |
public void write( int bv )
throws IOException
{
int b = ( 256 + bv ) % 256;
if( m_currentChar != -1 )
{
if( m_currentChar == b )
{
m_runLength++;
if( m_runLength > 254 )
{
writeRun();
... | void function( int bv ) throws IOException { int b = ( 256 + bv ) % 256; if( m_currentChar != -1 ) { if( m_currentChar == b ) { m_runLength++; if( m_runLength > 254 ) { writeRun(); m_currentChar = -1; m_runLength = 0; } } else { writeRun(); m_runLength = 1; m_currentChar = b; } } else { m_currentChar = b; m_runLength++... | /**
* modified by Oliver Merkel, 010128
*
* @param bv Description of Parameter
* @exception java.io.IOException Description of Exception
*/ | modified by Oliver Merkel, 010128 | write | {
"repo_name": "taolee/XmlDataAnalysisToolsets",
"path": "DataAnalysis_Wikipedia/spw/src/org/apache/commons/compress/bzip2/CBZip2OutputStream.java",
"license": "bsd-3-clause",
"size": 53970
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,073,505 |
public static void setFittedEvenCoordSystem(Graphics2D g, Component comp, Shape[] sh) {
Rectangle2D rek = getBounds2D(sh);
setFittedEvenCoordSystem(g, comp, rek);
} | static void function(Graphics2D g, Component comp, Shape[] sh) { Rectangle2D rek = getBounds2D(sh); setFittedEvenCoordSystem(g, comp, rek); } | /**
* set a coordinate system for the component such that a given Shape[] array will
* fit exactly into the component, keeping the same unit on both axes.
*
* @param g the Graphics2D context
* @param comp the component in question
* @param sh the Shape[] array object to fit into the c... | set a coordinate system for the component such that a given Shape[] array will fit exactly into the component, keeping the same unit on both axes | setFittedEvenCoordSystem | {
"repo_name": "opencadc/caom2",
"path": "caom2-viz/src/main/java/ca/nrc/cadc/caom2/viz/CoordSystemUtil.java",
"license": "agpl-3.0",
"size": 32159
} | [
"java.awt.Component",
"java.awt.Graphics2D",
"java.awt.Shape",
"java.awt.geom.Rectangle2D"
] | import java.awt.Component; import java.awt.Graphics2D; import java.awt.Shape; import java.awt.geom.Rectangle2D; | import java.awt.*; import java.awt.geom.*; | [
"java.awt"
] | java.awt; | 2,750,682 |
void write(int numBytes, Writer writer) throws Http2Exception {
// Update the streamable bytes, assuming that all the bytes will be written.
int newStreamableBytes = streamableBytes - numBytes;
updateStreamableBytes(newStreamableBytes, newStreamableBytes > 0);
tr... | void write(int numBytes, Writer writer) throws Http2Exception { int newStreamableBytes = streamableBytes - numBytes; updateStreamableBytes(newStreamableBytes, newStreamableBytes > 0); try { writer.write(stream, numBytes); } catch (Throwable t) { throw connectionError(INTERNAL_ERROR, t, STR); } } | /**
* Write any allocated bytes for the given stream and updates the streamable bytes,
* assuming all of the bytes will be written.
*/ | Write any allocated bytes for the given stream and updates the streamable bytes, assuming all of the bytes will be written | write | {
"repo_name": "smayoorans/netty",
"path": "codec-http2/src/main/java/io/netty/handler/codec/http2/UniformStreamByteDistributor.java",
"license": "apache-2.0",
"size": 6741
} | [
"io.netty.handler.codec.http2.Http2Exception"
] | import io.netty.handler.codec.http2.Http2Exception; | import io.netty.handler.codec.http2.*; | [
"io.netty.handler"
] | io.netty.handler; | 2,284,106 |
public void initialize(UimaContext context) throws ResourceInitializationException {
// super
super.initialize(context);
//System.out.println("Debug: this.getStopWord() "+this.getStopWord());
// current AE parameter
try {
Integer w = (Integer) context.getConfigParameterValue(WINDOW_PARAM);
if ... | void function(UimaContext context) throws ResourceInitializationException { super.initialize(context); try { Integer w = (Integer) context.getConfigParameterValue(WINDOW_PARAM); if (w == null) w =WINDOW_DEFAULT; this.setWindow(w); Integer s = (Integer) context.getConfigParameterValue(STEP_PARAM); if (s == null) s = STE... | /**
* Get the parameter values
*/ | Get the parameter values | initialize | {
"repo_name": "EUMSSI/EUMSSI-tools",
"path": "UimaAEs/TextSegmenter/src/fr/univnantes/lina/uima/textSegmenter/JTextTile/JTextTileAE.java",
"license": "apache-2.0",
"size": 9689
} | [
"org.apache.uima.UimaContext",
"org.apache.uima.resource.ResourceInitializationException"
] | import org.apache.uima.UimaContext; import org.apache.uima.resource.ResourceInitializationException; | import org.apache.uima.*; import org.apache.uima.resource.*; | [
"org.apache.uima"
] | org.apache.uima; | 2,334,525 |
public static HttpMethod createMethod(Message message, boolean hasPayload) {
// use header first
HttpMethod m = message.getHeader(Exchange.HTTP_METHOD, HttpMethod.class);
if (m != null) {
return m;
}
String name = message.getHeader(Exchange.HTTP_METHOD, String.cla... | static HttpMethod function(Message message, boolean hasPayload) { HttpMethod m = message.getHeader(Exchange.HTTP_METHOD, HttpMethod.class); if (m != null) { return m; } String name = message.getHeader(Exchange.HTTP_METHOD, String.class); if (name != null) { return HttpMethod.valueOf(name); } if (hasPayload) { return Ht... | /**
* Creates the {@link HttpMethod} to use to call the remote server, often either its GET or POST.
*
* @param message the Camel message
* @return the created method
*/ | Creates the <code>HttpMethod</code> to use to call the remote server, often either its GET or POST | createMethod | {
"repo_name": "onders86/camel",
"path": "components/camel-netty-http/src/main/java/org/apache/camel/component/netty/http/NettyHttpHelper.java",
"license": "apache-2.0",
"size": 10568
} | [
"org.apache.camel.Exchange",
"org.apache.camel.Message",
"org.jboss.netty.handler.codec.http.HttpMethod"
] | import org.apache.camel.Exchange; import org.apache.camel.Message; import org.jboss.netty.handler.codec.http.HttpMethod; | import org.apache.camel.*; import org.jboss.netty.handler.codec.http.*; | [
"org.apache.camel",
"org.jboss.netty"
] | org.apache.camel; org.jboss.netty; | 524,150 |
void enterFieldDeclaration(@NotNull MelingParser.FieldDeclarationContext ctx);
void exitFieldDeclaration(@NotNull MelingParser.FieldDeclarationContext ctx); | void enterFieldDeclaration(@NotNull MelingParser.FieldDeclarationContext ctx); void exitFieldDeclaration(@NotNull MelingParser.FieldDeclarationContext ctx); | /**
* Exit a parse tree produced by {@link MelingParser#fieldDeclaration}.
* @param ctx the parse tree
*/ | Exit a parse tree produced by <code>MelingParser#fieldDeclaration</code> | exitFieldDeclaration | {
"repo_name": "watersoft/meling",
"path": "meling-main/src/main/java/com/watersoft/parser/MelingListener.java",
"license": "gpl-3.0",
"size": 8358
} | [
"org.antlr.v4.runtime.misc.NotNull"
] | import org.antlr.v4.runtime.misc.NotNull; | import org.antlr.v4.runtime.misc.*; | [
"org.antlr.v4"
] | org.antlr.v4; | 2,810,782 |
public CountDownLatch setBillingInfoAsync(com.mozu.api.contracts.commerceruntime.payments.BillingInfo billingInfo, String orderId, AsyncCallback<com.mozu.api.contracts.commerceruntime.payments.BillingInfo> callback) throws Exception
{
return setBillingInfoAsync( billingInfo, orderId, null, null, null, callbac... | CountDownLatch function(com.mozu.api.contracts.commerceruntime.payments.BillingInfo billingInfo, String orderId, AsyncCallback<com.mozu.api.contracts.commerceruntime.payments.BillingInfo> callback) throws Exception { return setBillingInfoAsync( billingInfo, orderId, null, null, null, callback); } | /**
* Updates the billing information supplied for an order.
* <p><pre><code>
* BillingInfo billinginfo = new BillingInfo();
* CountDownLatch latch = billinginfo.setBillingInfo( billingInfo, orderId, callback );
* latch.await() * </code></pre></p>
* @param orderId Unique identifier of the order.
* @para... | Updates the billing information supplied for an order. <code><code> BillingInfo billinginfo = new BillingInfo(); CountDownLatch latch = billinginfo.setBillingInfo( billingInfo, orderId, callback ); latch.await() * </code></code> | setBillingInfoAsync | {
"repo_name": "sanjaymandadi/mozu-java",
"path": "mozu-javaasync-core/src/main/java/com/mozu/api/resources/commerce/orders/BillingInfoResource.java",
"license": "mit",
"size": 10876
} | [
"com.mozu.api.AsyncCallback",
"java.util.concurrent.CountDownLatch"
] | import com.mozu.api.AsyncCallback; import java.util.concurrent.CountDownLatch; | import com.mozu.api.*; import java.util.concurrent.*; | [
"com.mozu.api",
"java.util"
] | com.mozu.api; java.util; | 1,864,106 |
public Timestamp getCreated();
public static final String COLUMNNAME_CreatedBy = "CreatedBy"; | Timestamp function(); public static final String COLUMNNAME_CreatedBy = STR; | /** Get Created.
* Date this record was created
*/ | Get Created. Date this record was created | getCreated | {
"repo_name": "geneos/adempiere",
"path": "base/src/org/compiere/model/I_R_RequestProcessor_Route.java",
"license": "gpl-2.0",
"size": 5937
} | [
"java.sql.Timestamp"
] | import java.sql.Timestamp; | import java.sql.*; | [
"java.sql"
] | java.sql; | 1,503,974 |
public void hazardHit(SoundManager soundManager) {
if (isDead() ) return;
if (hazard.explodes() ) {
exploding = true;
animationPoint = 0;
soundManager.playOnce(GameSoundEffect.EXPLOSION);
}
}
| void function(SoundManager soundManager) { if (isDead() ) return; if (hazard.explodes() ) { exploding = true; animationPoint = 0; soundManager.playOnce(GameSoundEffect.EXPLOSION); } } | /**
*
* Called when bonzo hits the hazard. This does not kill or affect bonzo; it affects the state of the hazard (exploding
* hazards must now begin explodin). Does nothing if the hazard is dead.
* <p/>
* Requires a sound manager in case the hazard needs to play a sound upon collision.
*
*/ | Called when bonzo hits the hazard. This does not kill or affect bonzo; it affects the state of the hazard (exploding hazards must now begin explodin). Does nothing if the hazard is dead. Requires a sound manager in case the hazard needs to play a sound upon collision | hazardHit | {
"repo_name": "ErikaRedmark/monkey-shines-java-port",
"path": "Monkey Shines/src/org/erikaredmark/monkeyshines/tiles/HazardTile.java",
"license": "gpl-3.0",
"size": 7185
} | [
"org.erikaredmark.monkeyshines.GameSoundEffect",
"org.erikaredmark.monkeyshines.resource.SoundManager"
] | import org.erikaredmark.monkeyshines.GameSoundEffect; import org.erikaredmark.monkeyshines.resource.SoundManager; | import org.erikaredmark.monkeyshines.*; import org.erikaredmark.monkeyshines.resource.*; | [
"org.erikaredmark.monkeyshines"
] | org.erikaredmark.monkeyshines; | 2,273,097 |
@Test
public void testIsSerializable() throws IOException, ClassNotFoundException {
// serialize
final ByteArrayOutputStream out = new ByteArrayOutputStream();
try (final ObjectOutputStream oos = new ObjectOutputStream(out)) {
oos.writeObject(this.windowsPrincipal);
}... | void function() throws IOException, ClassNotFoundException { final ByteArrayOutputStream out = new ByteArrayOutputStream(); try (final ObjectOutputStream oos = new ObjectOutputStream(out)) { oos.writeObject(this.windowsPrincipal); } Assertions.assertThat(out.toByteArray().length).isGreaterThan(0); final InputStream in ... | /**
* Test is serializable.
*
* @throws IOException
* Signals that an I/O exception has occurred.
* @throws ClassNotFoundException
* the class not found exception
*/ | Test is serializable | testIsSerializable | {
"repo_name": "vimil/waffle",
"path": "Source/JNA/waffle-tests/src/test/java/waffle/servlet/WindowsPrincipalTests.java",
"license": "epl-1.0",
"size": 2926
} | [
"java.io.ByteArrayInputStream",
"java.io.ByteArrayOutputStream",
"java.io.IOException",
"java.io.InputStream",
"java.io.ObjectInputStream",
"java.io.ObjectOutputStream",
"java.util.Arrays",
"org.assertj.core.api.Assertions",
"org.junit.Assert"
] | import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.util.Arrays; import org.assertj.core.api.Assertions; import org.junit.Assert; | import java.io.*; import java.util.*; import org.assertj.core.api.*; import org.junit.*; | [
"java.io",
"java.util",
"org.assertj.core",
"org.junit"
] | java.io; java.util; org.assertj.core; org.junit; | 658,584 |
private void cleanUp() {
String bckFolderName = configurationService.getValue(Recoverable.BACKUP_FOLDER_CONFIG);
File path = new File(bckFolderName);
if (path.exists() && path.isDirectory()) {
try {
FileUtils.deleteDirectory(path);
} catch (IOException e) {
fail("Unable to clean up backup directo... | void function() { String bckFolderName = configurationService.getValue(Recoverable.BACKUP_FOLDER_CONFIG); File path = new File(bckFolderName); if (path.exists() && path.isDirectory()) { try { FileUtils.deleteDirectory(path); } catch (IOException e) { fail(STR); } } } | /**
* Cleans backup directory after every test
*/ | Cleans backup directory after every test | cleanUp | {
"repo_name": "bcvsolutions/CzechIdMng",
"path": "Realization/backend/core/core-impl/src/test/java/eu/bcvsolutions/idm/core/bulk/action/impl/notification/NotificationTemplateRedeployBulkActionIntegrationTest.java",
"license": "mit",
"size": 6293
} | [
"eu.bcvsolutions.idm.core.api.service.Recoverable",
"java.io.File",
"java.io.IOException",
"org.apache.commons.io.FileUtils",
"org.junit.Assert"
] | import eu.bcvsolutions.idm.core.api.service.Recoverable; import java.io.File; import java.io.IOException; import org.apache.commons.io.FileUtils; import org.junit.Assert; | import eu.bcvsolutions.idm.core.api.service.*; import java.io.*; import org.apache.commons.io.*; import org.junit.*; | [
"eu.bcvsolutions.idm",
"java.io",
"org.apache.commons",
"org.junit"
] | eu.bcvsolutions.idm; java.io; org.apache.commons; org.junit; | 2,622,225 |
public com.mozu.api.contracts.productadmin.ProductReservation getProductReservation(Integer productReservationId, String responseFields) throws Exception
{
MozuClient<com.mozu.api.contracts.productadmin.ProductReservation> client = com.mozu.api.clients.commerce.catalog.admin.ProductReservationClient.getProductRes... | com.mozu.api.contracts.productadmin.ProductReservation function(Integer productReservationId, String responseFields) throws Exception { MozuClient<com.mozu.api.contracts.productadmin.ProductReservation> client = com.mozu.api.clients.commerce.catalog.admin.ProductReservationClient.getProductReservationClient(_dataViewMo... | /**
* Retrieves the details of a product reservation.
* <p><pre><code>
* ProductReservation productreservation = new ProductReservation();
* ProductReservation productReservation = productreservation.getProductReservation( productReservationId, responseFields);
* </code></pre></p>
* @param productReservati... | Retrieves the details of a product reservation. <code><code> ProductReservation productreservation = new ProductReservation(); ProductReservation productReservation = productreservation.getProductReservation( productReservationId, responseFields); </code></code> | getProductReservation | {
"repo_name": "sanjaymandadi/mozu-java",
"path": "mozu-java-core/src/main/java/com/mozu/api/resources/commerce/catalog/admin/ProductReservationResource.java",
"license": "mit",
"size": 12540
} | [
"com.mozu.api.MozuClient"
] | import com.mozu.api.MozuClient; | import com.mozu.api.*; | [
"com.mozu.api"
] | com.mozu.api; | 2,777,877 |
public SearchSourceBuilder filter(BytesReference filterBinary) {
this.filterBinary = filterBinary;
return this;
} | SearchSourceBuilder function(BytesReference filterBinary) { this.filterBinary = filterBinary; return this; } | /**
* Sets a filter on the query executed that only applies to the search query
* (and not facets for example).
*/ | Sets a filter on the query executed that only applies to the search query (and not facets for example) | filter | {
"repo_name": "lmenezes/elasticsearch",
"path": "src/main/java/org/elasticsearch/search/builder/SearchSourceBuilder.java",
"license": "apache-2.0",
"size": 27894
} | [
"org.elasticsearch.common.bytes.BytesReference"
] | import org.elasticsearch.common.bytes.BytesReference; | import org.elasticsearch.common.bytes.*; | [
"org.elasticsearch.common"
] | org.elasticsearch.common; | 1,518,947 |
public static int hashCode(ByteBuf buffer) {
final int aLen = buffer.readableBytes();
final int intCount = aLen >>> 2;
final int byteCount = aLen & 3;
int hashCode = 1;
int arrayIndex = buffer.readerIndex();
if (buffer.order() == ByteOrder.BIG_ENDIAN) {
f... | static int function(ByteBuf buffer) { final int aLen = buffer.readableBytes(); final int intCount = aLen >>> 2; final int byteCount = aLen & 3; int hashCode = 1; int arrayIndex = buffer.readerIndex(); if (buffer.order() == ByteOrder.BIG_ENDIAN) { for (int i = intCount; i > 0; i --) { hashCode = 31 * hashCode + buffer.g... | /**
* Calculates the hash code of the specified buffer. This method is
* useful when implementing a new buffer type.
*/ | Calculates the hash code of the specified buffer. This method is useful when implementing a new buffer type | hashCode | {
"repo_name": "deerwalk/voltdb",
"path": "third_party/java/src/io/netty_voltpatches/buffer/ByteBufUtil.java",
"license": "agpl-3.0",
"size": 43987
} | [
"java.nio.ByteOrder"
] | import java.nio.ByteOrder; | import java.nio.*; | [
"java.nio"
] | java.nio; | 1,877,013 |
void checkUserValue(AttributeValue value, AttributeDesignator attribute) throws ParsingException;
| void checkUserValue(AttributeValue value, AttributeDesignator attribute) throws ParsingException; | /**
* Determines if the user entered value is valid.
*
* @param value The value to check
* @param attribute The relevant attribute
* @throws ParsingException if the user entered value is invalid
*/ | Determines if the user entered value is valid | checkUserValue | {
"repo_name": "NCIP/cadsr-cgmdr-nci-uk",
"path": "src/org/exist/client/xacml/AttributeHandler.java",
"license": "bsd-3-clause",
"size": 1651
} | [
"com.sun.xacml.ParsingException",
"com.sun.xacml.attr.AttributeDesignator",
"com.sun.xacml.attr.AttributeValue"
] | import com.sun.xacml.ParsingException; import com.sun.xacml.attr.AttributeDesignator; import com.sun.xacml.attr.AttributeValue; | import com.sun.xacml.*; import com.sun.xacml.attr.*; | [
"com.sun.xacml"
] | com.sun.xacml; | 2,462,791 |
public void deleteTags(String[] tags){
log.info("Deleting tags");
JSONObject params = new JSONObject();
JSONArray tagsArray = new JSONArray();
for(String tag : tags){
tagsArray.put(tag);
}
try {
params.put("tags", tagsArray);
} catch (JSONException e) {
log.err... | void function(String[] tags){ log.info(STR); JSONObject params = new JSONObject(); JSONArray tagsArray = new JSONArray(); for(String tag : tags){ tagsArray.put(tag); } try { params.put("tags", tagsArray); } catch (JSONException e) { log.error(STR+e.getMessage()); } | /**
* Delete tags.
* @param tags The tags to delete.
*/ | Delete tags | deleteTags | {
"repo_name": "EsriDE/PTM-OSMGeotrigger",
"path": "Admin/Core/src/de/esri/geotrigger/core/TriggerHandler.java",
"license": "apache-2.0",
"size": 15374
} | [
"org.json.JSONArray",
"org.json.JSONException",
"org.json.JSONObject"
] | import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; | import org.json.*; | [
"org.json"
] | org.json; | 1,238,478 |
@Test
public void testGetScannerCfAndQual() throws Exception {
HTableInterface hTable = getHTable();
byte[] row = randomRowKey();
byte[] qual = randomRowKey();
Put put = new Put(row);
put.add(cf, qual, row);
hTable.put(put);
ResultScanner rs = hTable.getScanner(c... | void function() throws Exception { HTableInterface hTable = getHTable(); byte[] row = randomRowKey(); byte[] qual = randomRowKey(); Put put = new Put(row); put.add(cf, qual, row); hTable.put(put); ResultScanner rs = hTable.getScanner(cf, qual); Assert.assertNotNull(rs.next()); assertMetricsUpdated(OpType.PUT, OpType.GE... | /**
* Test getScanner(byte[] family)
*/ | Test getScanner(byte[] family) | testGetScannerCfAndQual | {
"repo_name": "urbanairship/statshtable",
"path": "src/test/java/com/urbanairship/statshtable/StatsHTableTest.java",
"license": "apache-2.0",
"size": 17496
} | [
"org.apache.hadoop.hbase.client.HTableInterface",
"org.apache.hadoop.hbase.client.Put",
"org.apache.hadoop.hbase.client.ResultScanner",
"org.junit.Assert"
] | import org.apache.hadoop.hbase.client.HTableInterface; import org.apache.hadoop.hbase.client.Put; import org.apache.hadoop.hbase.client.ResultScanner; import org.junit.Assert; | import org.apache.hadoop.hbase.client.*; import org.junit.*; | [
"org.apache.hadoop",
"org.junit"
] | org.apache.hadoop; org.junit; | 774,322 |
public Intent getAssistIntent(Context context, int userHandle) {
try {
if (mService == null) {
return null;
}
ComponentName comp = mService.getAssistIntent(userHandle);
if (comp == null) {
return null;
}
... | Intent function(Context context, int userHandle) { try { if (mService == null) { return null; } ComponentName comp = mService.getAssistIntent(userHandle); if (comp == null) { return null; } Intent intent = new Intent(Intent.ACTION_ASSIST); intent.setComponent(comp); return intent; } catch (RemoteException re) { Log.e(T... | /**
* Gets an intent for launching installed assistant activity, or null if not available.
* @return The assist intent.
*
* @hide
*/ | Gets an intent for launching installed assistant activity, or null if not available | getAssistIntent | {
"repo_name": "rex-xxx/mt6572_x201",
"path": "frameworks/base/core/java/android/app/SearchManager.java",
"license": "gpl-2.0",
"size": 36646
} | [
"android.content.ComponentName",
"android.content.Context",
"android.content.Intent",
"android.os.RemoteException",
"android.util.Log"
] | import android.content.ComponentName; import android.content.Context; import android.content.Intent; import android.os.RemoteException; import android.util.Log; | import android.content.*; import android.os.*; import android.util.*; | [
"android.content",
"android.os",
"android.util"
] | android.content; android.os; android.util; | 2,353,829 |
public void engineInit(X509StoreParameters params)
{
if (!(params instanceof X509LDAPCertStoreParameters))
{
throw new IllegalArgumentException(
"Initialization parameters must be an instance of "
+ X509LDAPCertStoreParameters.class.getName() + "."... | void function(X509StoreParameters params) { if (!(params instanceof X509LDAPCertStoreParameters)) { throw new IllegalArgumentException( STR + X509LDAPCertStoreParameters.class.getName() + "."); } helper = new LDAPStoreHelper((X509LDAPCertStoreParameters)params); } | /**
* Initializes this LDAP cert store implementation.
*
* @param params <code>X509LDAPCertStoreParameters</code>.
* @throws IllegalArgumentException if <code>params</code> is not an instance of
* <code>X509LDAPCertStoreParameters</code>.
*/ | Initializes this LDAP cert store implementation | engineInit | {
"repo_name": "iseki-masaya/spongycastle",
"path": "prov/src/main/java/org/spongycastle/jce/provider/X509StoreLDAPCerts.java",
"license": "mit",
"size": 4481
} | [
"org.spongycastle.jce.X509LDAPCertStoreParameters",
"org.spongycastle.x509.X509StoreParameters",
"org.spongycastle.x509.util.LDAPStoreHelper"
] | import org.spongycastle.jce.X509LDAPCertStoreParameters; import org.spongycastle.x509.X509StoreParameters; import org.spongycastle.x509.util.LDAPStoreHelper; | import org.spongycastle.jce.*; import org.spongycastle.x509.*; import org.spongycastle.x509.util.*; | [
"org.spongycastle.jce",
"org.spongycastle.x509"
] | org.spongycastle.jce; org.spongycastle.x509; | 2,523,057 |
public HashMap<String, byte[]> buildTranslatedBook(final ContentSpec contentSpec, final String requester,
final DocBookBuildingOptions buildingOptions,
final ZanataDetails zanataDetails) throws BuilderCreationException, BuildProcessingException {
return buildTranslatedBook(contentSpe... | HashMap<String, byte[]> function(final ContentSpec contentSpec, final String requester, final DocBookBuildingOptions buildingOptions, final ZanataDetails zanataDetails) throws BuilderCreationException, BuildProcessingException { return buildTranslatedBook(contentSpec, requester, buildingOptions, new HashMap<String, byt... | /**
* Builds a DocBook Formatted Book using a Content Specification to define the structure and contents of the book.
*
* @param contentSpec The content specification to build from.
* @param requester The user who requested the build.
* @param buildingOptions The options to be used wh... | Builds a DocBook Formatted Book using a Content Specification to define the structure and contents of the book | buildTranslatedBook | {
"repo_name": "pressgang-ccms/PressGangCCMSBuilder",
"path": "src/main/java/org/jboss/pressgang/ccms/contentspec/builder/DocBookBuilder.java",
"license": "gpl-3.0",
"size": 210070
} | [
"java.util.HashMap",
"org.jboss.pressgang.ccms.contentspec.ContentSpec",
"org.jboss.pressgang.ccms.contentspec.builder.exception.BuildProcessingException",
"org.jboss.pressgang.ccms.contentspec.builder.exception.BuilderCreationException",
"org.jboss.pressgang.ccms.contentspec.builder.structures.DocBookBuild... | import java.util.HashMap; import org.jboss.pressgang.ccms.contentspec.ContentSpec; import org.jboss.pressgang.ccms.contentspec.builder.exception.BuildProcessingException; import org.jboss.pressgang.ccms.contentspec.builder.exception.BuilderCreationException; import org.jboss.pressgang.ccms.contentspec.builder.structure... | import java.util.*; import org.jboss.pressgang.ccms.contentspec.*; import org.jboss.pressgang.ccms.contentspec.builder.exception.*; import org.jboss.pressgang.ccms.contentspec.builder.structures.*; import org.jboss.pressgang.ccms.zanata.*; | [
"java.util",
"org.jboss.pressgang"
] | java.util; org.jboss.pressgang; | 2,200,849 |
@Test
public void testWriterTwice3() throws Exception {
Directory indexDir = newDirectory();
// First, create and fill the taxonomy
TaxonomyWriter tw = new DirectoryTaxonomyWriter(indexDir);
fillTaxonomy(tw);
tw.close();
// Now, open the same taxonomy and add the same categories again.
/... | void function() throws Exception { Directory indexDir = newDirectory(); TaxonomyWriter tw = new DirectoryTaxonomyWriter(indexDir); fillTaxonomy(tw); tw.close(); tw = new DirectoryTaxonomyWriter(indexDir); fillTaxonomy(tw); tw.addCategory(new CategoryPath("hi")); tw.commit(); assertEquals(expectedCategories.length+1, tw... | /**
* testWriterTwice3 is yet another test which tests creating a taxonomy
* in two separate writing sessions. This test used to fail because of
* a bug involving commit(), explained below, and now should succeed.
*/ | testWriterTwice3 is yet another test which tests creating a taxonomy in two separate writing sessions. This test used to fail because of a bug involving commit(), explained below, and now should succeed | testWriterTwice3 | {
"repo_name": "terrancesnyder/solr-analytics",
"path": "lucene/facet/src/test/org/apache/lucene/facet/taxonomy/TestTaxonomyCombined.java",
"license": "apache-2.0",
"size": 42104
} | [
"org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyWriter",
"org.apache.lucene.store.Directory"
] | import org.apache.lucene.facet.taxonomy.directory.DirectoryTaxonomyWriter; import org.apache.lucene.store.Directory; | import org.apache.lucene.facet.taxonomy.directory.*; import org.apache.lucene.store.*; | [
"org.apache.lucene"
] | org.apache.lucene; | 2,319,155 |
private void onConnectionLost(String reason) {
if (connListener != null) {
connListener.onConnectionStateChange(ConnectionListener.CONNECTION_LOST, reason);
}
connectionEstablished = false;
} | void function(String reason) { if (connListener != null) { connListener.onConnectionStateChange(ConnectionListener.CONNECTION_LOST, reason); } connectionEstablished = false; } | /**
* This method is called whenever the connection to the digitalSTROM-Server is lost.
*
* @param reason
*/ | This method is called whenever the connection to the digitalSTROM-Server is lost | onConnectionLost | {
"repo_name": "paulianttila/openhab2",
"path": "bundles/org.openhab.binding.digitalstrom/src/main/java/org/openhab/binding/digitalstrom/internal/lib/manager/impl/ConnectionManagerImpl.java",
"license": "epl-1.0",
"size": 23359
} | [
"org.openhab.binding.digitalstrom.internal.lib.listener.ConnectionListener"
] | import org.openhab.binding.digitalstrom.internal.lib.listener.ConnectionListener; | import org.openhab.binding.digitalstrom.internal.lib.listener.*; | [
"org.openhab.binding"
] | org.openhab.binding; | 2,237,966 |
public Traverser<Object> removePartition(int partitionIndex) {
return removePartition(System.nanoTime(), partitionIndex);
} | Traverser<Object> function(int partitionIndex) { return removePartition(System.nanoTime(), partitionIndex); } | /**
* Removes a partition that will no longer have events. If we were waiting
* for a watermark from it, the returned traverser might contain a
* watermark to emit.
* <p>
* Note that the indexes of partitions with index larger than the given
* {@code partitionIndex} will be decremented by ... | Removes a partition that will no longer have events. If we were waiting for a watermark from it, the returned traverser might contain a watermark to emit. Note that the indexes of partitions with index larger than the given partitionIndex will be decremented by 1 | removePartition | {
"repo_name": "gurbuzali/hazelcast-jet",
"path": "hazelcast-jet-core/src/main/java/com/hazelcast/jet/core/EventTimeMapper.java",
"license": "apache-2.0",
"size": 15955
} | [
"com.hazelcast.jet.Traverser"
] | import com.hazelcast.jet.Traverser; | import com.hazelcast.jet.*; | [
"com.hazelcast.jet"
] | com.hazelcast.jet; | 262,043 |
Decision getDecision(Long idProject, String idDecision);
Decision addDecision(Long idProject, Decision decision);
Decision updateDecision(Long idProject, Decision decision);
Boolean deleteDecision(Long idProject, String idDecision);
| Decision getDecision(Long idProject, String idDecision); Decision addDecision(Long idProject, Decision decision); Decision updateDecision(Long idProject, Decision decision); Boolean deleteDecision(Long idProject, String idDecision); | /**
* Deletes the decision for the given decision id.
*/ | Deletes the decision for the given decision id | deleteDecision | {
"repo_name": "DDMoReThoughtflow/ThoughtflowGUI",
"path": "DDMoRe-BWF-Client/src/main/java/eu/ddmore/workflow/bwf/client/service/FileService.java",
"license": "agpl-3.0",
"size": 1836
} | [
"eu.ddmore.workflow.bwf.client.model.Decision"
] | import eu.ddmore.workflow.bwf.client.model.Decision; | import eu.ddmore.workflow.bwf.client.model.*; | [
"eu.ddmore.workflow"
] | eu.ddmore.workflow; | 574,066 |
void setColumn(BigInteger value); | void setColumn(BigInteger value); | /**
* Sets the value of the '{@link org.casa.dsltesting.Qt48XmlschemaQwtEnhanced.LayoutItem#getColumn <em>Column</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @param value the new value of the '<em>Column</em>' attribute.
* @see #getColumn()
* @generated
*/ | Sets the value of the '<code>org.casa.dsltesting.Qt48XmlschemaQwtEnhanced.LayoutItem#getColumn Column</code>' attribute. | setColumn | {
"repo_name": "pedromateo/tug_qt_unit_testing_fw",
"path": "qt48_model/src/org/casa/dsltesting/Qt48XmlschemaQwtEnhanced/LayoutItem.java",
"license": "gpl-3.0",
"size": 9463
} | [
"java.math.BigInteger"
] | import java.math.BigInteger; | import java.math.*; | [
"java.math"
] | java.math; | 2,434,772 |
public Accessible getAccessible() {
checkWidget();
return _getAccessible();
} | Accessible function() { checkWidget(); return _getAccessible(); } | /**
* Returns the accessible object for the receiver.
* <p>
* If this is the first time this object is requested, then the object is
* created and returned. The object returned by getAccessible() does not
* need to be disposed.
* </p>
*
* @return the accessible object
*
* @exception SWTException
... | Returns the accessible object for the receiver. If this is the first time this object is requested, then the object is created and returned. The object returned by getAccessible() does not need to be disposed. | getAccessible | {
"repo_name": "ghillairet/gef-gwt",
"path": "src/main/java/org/eclipse/swt/widgets/Control.java",
"license": "epl-1.0",
"size": 120160
} | [
"org.eclipse.swt.accessibility.Accessible"
] | import org.eclipse.swt.accessibility.Accessible; | import org.eclipse.swt.accessibility.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 2,640,340 |
EMap<String, String> getXMLNSPrefixMap(); | EMap<String, String> getXMLNSPrefixMap(); | /**
* Returns the value of the '<em><b>XMLNS Prefix Map</b></em>' map.
* The key is of type {@link java.lang.String},
* and the value is of type {@link java.lang.String},
* <!-- begin-user-doc -->
* <p>
* If the meaning of the '<em>XMLNS Prefix Map</em>' map isn't clear,
* there really should be more of a... | Returns the value of the 'XMLNS Prefix Map' map. The key is of type <code>java.lang.String</code>, and the value is of type <code>java.lang.String</code>, If the meaning of the 'XMLNS Prefix Map' map isn't clear, there really should be more of a description here... | getXMLNSPrefixMap | {
"repo_name": "GRA-UML/tool",
"path": "plugins/org.ijis.gra.ebxml.cpp-cpa/src/org/w3/_1999/xlink/DocumentRoot.java",
"license": "epl-1.0",
"size": 12676
} | [
"org.eclipse.emf.common.util.EMap"
] | import org.eclipse.emf.common.util.EMap; | import org.eclipse.emf.common.util.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 2,086,935 |
@Override
public Container findChild(String name) {
if (name == null)
return (null);
synchronized (children) {
return children.get(name);
}
} | Container function(String name) { if (name == null) return (null); synchronized (children) { return children.get(name); } } | /**
* Return the child Container, associated with this Container, with
* the specified name (if any); otherwise, return <code>null</code>
*
* @param name Name of the child Container to be retrieved
*/ | Return the child Container, associated with this Container, with the specified name (if any); otherwise, return <code>null</code> | findChild | {
"repo_name": "mayonghui2112/helloWorld",
"path": "sourceCode/apache-tomcat-7.0.82-src/java/org/apache/catalina/core/ContainerBase.java",
"license": "apache-2.0",
"size": 53688
} | [
"org.apache.catalina.Container"
] | import org.apache.catalina.Container; | import org.apache.catalina.*; | [
"org.apache.catalina"
] | org.apache.catalina; | 446,871 |
LoggerContext getContext(String fqcn, ClassLoader loader, boolean currentContext, URI configLocation); | LoggerContext getContext(String fqcn, ClassLoader loader, boolean currentContext, URI configLocation); | /**
* Returns the LoggerContext.
* @param fqcn The fully qualified class name of the caller.
* @param loader ClassLoader to use or null.
* @param currentContext If true returns the current Context, if false returns the Context appropriate
* for the caller if a more appropriate Context can be de... | Returns the LoggerContext | getContext | {
"repo_name": "apache/logging-log4j2",
"path": "log4j-core/src/main/java/org/apache/logging/log4j/core/selector/ContextSelector.java",
"license": "apache-2.0",
"size": 5855
} | [
"org.apache.logging.log4j.core.LoggerContext"
] | import org.apache.logging.log4j.core.LoggerContext; | import org.apache.logging.log4j.core.*; | [
"org.apache.logging"
] | org.apache.logging; | 2,537,617 |
public String getSelectedFont() {
return mSelectedFont;
}
private class FontAdapter extends BaseAdapter {
private Context mContext;
public FontAdapter(Context c) {
mContext = c;
} | String function() { return mSelectedFont; } private class FontAdapter extends BaseAdapter { private Context mContext; public FontAdapter(Context c) { mContext = c; } | /**
* Callback method that is called once a font has been selected and the fontpickerdialog closes.
*
* @return The pathname of the font that was selected
*/ | Callback method that is called once a font has been selected and the fontpickerdialog closes | getSelectedFont | {
"repo_name": "phimpme/android-prototype",
"path": "app/src/main/java/org/fossasia/phimpme/editor/font/FontPickerDialog.java",
"license": "apache-2.0",
"size": 5136
} | [
"android.content.Context",
"android.widget.BaseAdapter"
] | import android.content.Context; import android.widget.BaseAdapter; | import android.content.*; import android.widget.*; | [
"android.content",
"android.widget"
] | android.content; android.widget; | 1,567,209 |
T visitArglist(@NotNull PoCoParser.ArglistContext ctx);
T visitMetapol(@NotNull PoCoParser.MetapolContext ctx);
T visitTransaction(@NotNull PoCoParser.TransactionContext ctx);
T visitArgs(@NotNull PoCoParser.ArgsContext ctx);
T visitRewild(@NotNull PoCoParser.RewildContext ctx);
T visitSredisj(@NotNul... | T visitArglist(@NotNull PoCoParser.ArglistContext ctx); T visitMetapol(@NotNull PoCoParser.MetapolContext ctx); T visitTransaction(@NotNull PoCoParser.TransactionContext ctx); T visitArgs(@NotNull PoCoParser.ArgsContext ctx); T visitRewild(@NotNull PoCoParser.RewildContext ctx); T visitSredisj(@NotNull PoCoParser.Sredi... | /**
* Visit a parse tree produced by {@link PoCoParser#vardecl}.
* @param ctx the parse tree
* @return the visitor result
*/ | Visit a parse tree produced by <code>PoCoParser#vardecl</code> | visitVardecl | {
"repo_name": "Corjuh/PoCo-Compiler",
"path": "Parser/gen/PoCoParserVisitor.java",
"license": "lgpl-2.1",
"size": 10598
} | [
"org.antlr.v4.runtime.misc.NotNull"
] | import org.antlr.v4.runtime.misc.NotNull; | import org.antlr.v4.runtime.misc.*; | [
"org.antlr.v4"
] | org.antlr.v4; | 473,779 |
private static CellProcessor addParseChar(CellProcessor cellProcessor)
{
if (cellProcessor == null) {
return new ParseChar();
}
return new ParseChar((DoubleCellProcessor)cellProcessor);
}
private static class IntMinMax extends LMinMax
{
public IntMinMax(int min, int max)
{
... | static CellProcessor function(CellProcessor cellProcessor) { if (cellProcessor == null) { return new ParseChar(); } return new ParseChar((DoubleCellProcessor)cellProcessor); } private static class IntMinMax extends LMinMax { public IntMinMax(int min, int max) { super(min, max); } | /**
* Get cellprocessor to parse String as Character.
*
* @param cellProcessor
* next processor in the chain.
* @return CellProcessor
*/ | Get cellprocessor to parse String as Character | addParseChar | {
"repo_name": "ilganeli/incubator-apex-malhar",
"path": "contrib/src/main/java/com/datatorrent/contrib/parser/CellProcessorBuilder.java",
"license": "apache-2.0",
"size": 16493
} | [
"org.supercsv.cellprocessor.ParseChar",
"org.supercsv.cellprocessor.constraint.LMinMax",
"org.supercsv.cellprocessor.ift.CellProcessor",
"org.supercsv.cellprocessor.ift.DoubleCellProcessor"
] | import org.supercsv.cellprocessor.ParseChar; import org.supercsv.cellprocessor.constraint.LMinMax; import org.supercsv.cellprocessor.ift.CellProcessor; import org.supercsv.cellprocessor.ift.DoubleCellProcessor; | import org.supercsv.cellprocessor.*; import org.supercsv.cellprocessor.constraint.*; import org.supercsv.cellprocessor.ift.*; | [
"org.supercsv.cellprocessor"
] | org.supercsv.cellprocessor; | 1,071,403 |
//-----------------------------------------------------------------------
private void writeObject(ObjectOutputStream out) throws IOException {
out.defaultWriteObject();
out.writeObject(collection);
}
| void function(ObjectOutputStream out) throws IOException { out.defaultWriteObject(); out.writeObject(collection); } | /**
* Write the collection out using a custom routine.
*
* @param out the output stream
* @throws IOException
*/ | Write the collection out using a custom routine | writeObject | {
"repo_name": "leodmurillo/sonar",
"path": "plugins/sonar-squid-java-plugin/test-resources/commons-collections-3.2.1/src/org/apache/commons/collections/set/UnmodifiableSortedSet.java",
"license": "lgpl-3.0",
"size": 4716
} | [
"java.io.IOException",
"java.io.ObjectOutputStream"
] | import java.io.IOException; import java.io.ObjectOutputStream; | import java.io.*; | [
"java.io"
] | java.io; | 600,248 |
private AxisOperation createAxisOperationFromDSOperation(Operation operation,
AxisBinding soap11Binding, AxisBinding soap12Binding,
AxisBinding httpBinding) throws AxisFault {
String opName = operation.getName();
String requestName = operation.getRequestName();
int index = opName.indexOf(":");
if (ind... | AxisOperation function(Operation operation, AxisBinding soap11Binding, AxisBinding soap12Binding, AxisBinding httpBinding) throws AxisFault { String opName = operation.getName(); String requestName = operation.getRequestName(); int index = opName.indexOf(":"); if (index > -1) { opName = opName.substring(index + 1); } b... | /**
* Creates an AxisOperation with the given data service operation object.
* @see Operation
* @see AxisOperation
*/ | Creates an AxisOperation with the given data service operation object | createAxisOperationFromDSOperation | {
"repo_name": "anupama-pathirage/carbon-data",
"path": "components/data-services/org.wso2.carbon.dataservices.core/src/main/java/org/wso2/carbon/dataservices/core/DBDeployer.java",
"license": "apache-2.0",
"size": 50377
} | [
"org.apache.axis2.AxisFault",
"org.apache.axis2.description.AxisBinding",
"org.apache.axis2.description.AxisOperation",
"org.apache.axis2.transport.http.HTTPConstants",
"org.wso2.carbon.dataservices.core.description.operation.Operation"
] | import org.apache.axis2.AxisFault; import org.apache.axis2.description.AxisBinding; import org.apache.axis2.description.AxisOperation; import org.apache.axis2.transport.http.HTTPConstants; import org.wso2.carbon.dataservices.core.description.operation.Operation; | import org.apache.axis2.*; import org.apache.axis2.description.*; import org.apache.axis2.transport.http.*; import org.wso2.carbon.dataservices.core.description.operation.*; | [
"org.apache.axis2",
"org.wso2.carbon"
] | org.apache.axis2; org.wso2.carbon; | 678,375 |
@Override
protected void setTargetEditPart(EditPart editpart) {
if (getTargetEditPart() == editpart)
return;
super.setTargetEditPart(editpart);
snapToHelper = null;
if (getTargetEditPart() != null && getOperationSet().size() > 0)
snapToHelper = getTargetEd... | void function(EditPart editpart) { if (getTargetEditPart() == editpart) return; super.setTargetEditPart(editpart); snapToHelper = null; if (getTargetEditPart() != null && getOperationSet().size() > 0) snapToHelper = getTargetEditPart().getAdapter( SnapToHelper.class); } | /**
* Extended to update the current snap-to strategy.
*
* @see org.eclipse.gef.tools.TargetingTool#setTargetEditPart(org.eclipse.gef.EditPart)
*/ | Extended to update the current snap-to strategy | setTargetEditPart | {
"repo_name": "archimatetool/archi",
"path": "org.eclipse.gef/src/org/eclipse/gef/tools/DragEditPartsTracker.java",
"license": "mit",
"size": 25374
} | [
"org.eclipse.gef.EditPart",
"org.eclipse.gef.SnapToHelper"
] | import org.eclipse.gef.EditPart; import org.eclipse.gef.SnapToHelper; | import org.eclipse.gef.*; | [
"org.eclipse.gef"
] | org.eclipse.gef; | 2,351,280 |
public List<InstanceInfo> getInstancesByVipAddress(String vipAddress, boolean secure); | List<InstanceInfo> function(String vipAddress, boolean secure); | /**
* Gets the list of instances matching the given VIP Address.
*
* @param vipAddress The VIP address to match the instances for.
* @param secure true if it is a secure vip address, false otherwise
* @return - The list of {@link InstanceInfo} objects matching the criteria
*/ | Gets the list of instances matching the given VIP Address | getInstancesByVipAddress | {
"repo_name": "jkschneider/eureka",
"path": "eureka-client/src/main/java/com/netflix/discovery/EurekaClient.java",
"license": "apache-2.0",
"size": 7161
} | [
"com.netflix.appinfo.InstanceInfo",
"java.util.List"
] | import com.netflix.appinfo.InstanceInfo; import java.util.List; | import com.netflix.appinfo.*; import java.util.*; | [
"com.netflix.appinfo",
"java.util"
] | com.netflix.appinfo; java.util; | 1,699,451 |
@Override
@Transactional("entityManager")
public Lab getLabByPrimaryUserId (final int primaryUserId) {
HashMap<String, Integer> m = new HashMap<String, Integer>();
m.put("primaryUserId", primaryUserId);
List<Lab> results = this.findByMap(m);
if (results.size() == 0) {
Lab rt = new Lab();
return... | @Transactional(STR) Lab function (final int primaryUserId) { HashMap<String, Integer> m = new HashMap<String, Integer>(); m.put(STR, primaryUserId); List<Lab> results = this.findByMap(m); if (results.size() == 0) { Lab rt = new Lab(); return rt; } return results.get(0); } | /**
* getLabByPrimaryUserId(final int primaryUserId)
*
* @param final int primaryUserId
*
* @return lab
*/ | getLabByPrimaryUserId(final int primaryUserId) | getLabByPrimaryUserId | {
"repo_name": "WASP-System/central",
"path": "wasp-core/src/main/java/edu/yu/einstein/wasp/dao/impl/LabDaoImpl.java",
"license": "agpl-3.0",
"size": 2146
} | [
"edu.yu.einstein.wasp.model.Lab",
"java.util.HashMap",
"java.util.List",
"org.springframework.transaction.annotation.Transactional"
] | import edu.yu.einstein.wasp.model.Lab; import java.util.HashMap; import java.util.List; import org.springframework.transaction.annotation.Transactional; | import edu.yu.einstein.wasp.model.*; import java.util.*; import org.springframework.transaction.annotation.*; | [
"edu.yu.einstein",
"java.util",
"org.springframework.transaction"
] | edu.yu.einstein; java.util; org.springframework.transaction; | 1,535,928 |
@SuppressWarnings({"CatchGenericClass"})
private void notifyLifecycleBeansEx(LifecycleEventType evt) {
try {
notifyLifecycleBeans(evt);
}
// Catch generic throwable to secure against user assertions.
catch (Throwable e) {
U.error(log, "Failed to notify lif... | @SuppressWarnings({STR}) void function(LifecycleEventType evt) { try { notifyLifecycleBeans(evt); } catch (Throwable e) { U.error(log, STR + evt + (igniteInstanceName == null ? STR, igniteInstanceName=" + igniteInstanceName) + ']', e); if (e instanceof Error) throw (Error)e; } } | /**
* Notifies life-cycle beans of grid event.
*
* @param evt Grid event.
*/ | Notifies life-cycle beans of grid event | notifyLifecycleBeansEx | {
"repo_name": "dream-x/ignite",
"path": "modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java",
"license": "apache-2.0",
"size": 143522
} | [
"org.apache.ignite.internal.util.typedef.internal.U",
"org.apache.ignite.lifecycle.LifecycleEventType"
] | import org.apache.ignite.internal.util.typedef.internal.U; import org.apache.ignite.lifecycle.LifecycleEventType; | import org.apache.ignite.internal.util.typedef.internal.*; import org.apache.ignite.lifecycle.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 26,238 |
public static <E> List<E> toList(final Iterable<E> iterable) {
return IteratorUtils.toList(emptyIteratorIfNull(iterable));
}
/**
* Returns a string representation of the elements of the specified iterable.
* <p>
* The string representation consists of a list of the iterable's element... | static <E> List<E> function(final Iterable<E> iterable) { return IteratorUtils.toList(emptyIteratorIfNull(iterable)); } /** * Returns a string representation of the elements of the specified iterable. * <p> * The string representation consists of a list of the iterable's elements, * enclosed in square brackets ({@code ... | /**
* Gets a new list with the contents of the provided iterable.
*
* @param <E> the element type
* @param iterable the iterable to use, may be null
* @return a list of the iterator contents
*/ | Gets a new list with the contents of the provided iterable | toList | {
"repo_name": "MuShiiii/commons-collections",
"path": "src/main/java/org/apache/commons/collections4/IterableUtils.java",
"license": "apache-2.0",
"size": 45435
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 674,722 |
ByteArrayOutputStream bos = new ByteArrayOutputStream(72);
DERSequenceGenerator seq = new DERSequenceGenerator(bos);
seq.addObject(new ASN1Integer(sigs[0]));
seq.addObject(new ASN1Integer(sigs[1]));
seq.close();
return bos.toByteArray();
}
/**
* DER - From byte[] to Big Integer rs
* UAF_ALG_SIGN_SECP... | ByteArrayOutputStream bos = new ByteArrayOutputStream(72); DERSequenceGenerator seq = new DERSequenceGenerator(bos); seq.addObject(new ASN1Integer(sigs[0])); seq.addObject(new ASN1Integer(sigs[1])); seq.close(); return bos.toByteArray(); } /** * DER - From byte[] to Big Integer rs * UAF_ALG_SIGN_SECP256K1_ECDSA_SHA256_... | /**
* DER - From Big Integer rs to byte[]
* UAF_ALG_SIGN_SECP256K1_ECDSA_SHA256_DER 0x06 DER [ITU-X690-2008] encoded
* ECDSA signature [RFC5480] on the secp256k1 curve. I.e. a DER encoded
* SEQUENCE { r INTEGER, s INTEGER }
*
* @param signature
* @return
* @throws IOException
*/ | DER - From Big Integer rs to byte[] UAF_ALG_SIGN_SECP256K1_ECDSA_SHA256_DER 0x06 DER [ITU-X690-2008] encoded ECDSA signature [RFC5480] on the secp256k1 curve. I.e. a DER encoded SEQUENCE { r INTEGER, s INTEGER } | getEncoded | {
"repo_name": "eBay/UAF",
"path": "fido-uaf-core/src/main/java/org/ebayopensource/fido/uaf/crypto/Asn1.java",
"license": "apache-2.0",
"size": 3900
} | [
"java.io.ByteArrayOutputStream",
"org.bouncycastle.asn1.ASN1Integer",
"org.bouncycastle.asn1.DERSequenceGenerator"
] | import java.io.ByteArrayOutputStream; import org.bouncycastle.asn1.ASN1Integer; import org.bouncycastle.asn1.DERSequenceGenerator; | import java.io.*; import org.bouncycastle.asn1.*; | [
"java.io",
"org.bouncycastle.asn1"
] | java.io; org.bouncycastle.asn1; | 2,087,163 |
public PopulateService getPopulateService()
{
return populateService;
} | PopulateService function() { return populateService; } | /**
* The current populateService
*
* @return populateService
*/ | The current populateService | getPopulateService | {
"repo_name": "harfalm/Sakai-10.1",
"path": "rwiki/rwiki-tool/tool/src/java/uk/ac/cam/caret/sakai/rwiki/tool/bean/PrePopulateBean.java",
"license": "apache-2.0",
"size": 3329
} | [
"uk.ac.cam.caret.sakai.rwiki.tool.api.PopulateService"
] | import uk.ac.cam.caret.sakai.rwiki.tool.api.PopulateService; | import uk.ac.cam.caret.sakai.rwiki.tool.api.*; | [
"uk.ac.cam"
] | uk.ac.cam; | 781,558 |
LOG.debug("Registering stream consumer - {}::{}", stream, streamConsumerName);
int attempt = 1;
if (configuration.getEfoRegistrationType() == LAZY) {
registrationBackoff(configuration, backoff, attempt++);
}
DescribeStreamResponse describeStreamResponse = kinesisProxyV2Interface.describeStream(stream);
... | LOG.debug(STR, stream, streamConsumerName); int attempt = 1; if (configuration.getEfoRegistrationType() == LAZY) { registrationBackoff(configuration, backoff, attempt++); } DescribeStreamResponse describeStreamResponse = kinesisProxyV2Interface.describeStream(stream); String streamArn = describeStreamResponse.streamDes... | /**
* Register a stream consumer with the given name against the given stream.
* Blocks until the consumer becomes active.
* If the stream consumer already exists, the ARN is returned.
*
* @param stream the stream to register the stream consumer against
* @param streamConsumerName the name of the new stream... | Register a stream consumer with the given name against the given stream. Blocks until the consumer becomes active. If the stream consumer already exists, the ARN is returned | registerStreamConsumer | {
"repo_name": "greghogan/flink",
"path": "flink-connectors/flink-connector-kinesis/src/main/java/org/apache/flink/streaming/connectors/kinesis/internals/publisher/fanout/StreamConsumerRegistrar.java",
"license": "apache-2.0",
"size": 10817
} | [
"java.util.Optional",
"software.amazon.awssdk.services.kinesis.model.DescribeStreamConsumerResponse",
"software.amazon.awssdk.services.kinesis.model.DescribeStreamResponse"
] | import java.util.Optional; import software.amazon.awssdk.services.kinesis.model.DescribeStreamConsumerResponse; import software.amazon.awssdk.services.kinesis.model.DescribeStreamResponse; | import java.util.*; import software.amazon.awssdk.services.kinesis.model.*; | [
"java.util",
"software.amazon.awssdk"
] | java.util; software.amazon.awssdk; | 2,441,838 |
private static synchronized boolean loadNativeLibrary(String path, String name) {
File libPath = new File(path, name);
if(libPath.exists()) {
try {
System.load(new File(path, name).getAbsolutePath());
return true;
} catch(UnsatisfiedLinkError ... | static synchronized boolean function(String path, String name) { File libPath = new File(path, name); if(libPath.exists()) { try { System.load(new File(path, name).getAbsolutePath()); return true; } catch(UnsatisfiedLinkError e) { System.err.println(e); return false; } } else { return false; } } | /**
* Loads native library using the given path and name of the library.
*
* @param path Path of the native library.
* @param name Name of the native library.
* @return True for successfully loading; false otherwise.
*/ | Loads native library using the given path and name of the library | loadNativeLibrary | {
"repo_name": "paramvir-b/sqlite-jdbc",
"path": "src/main/java/org/sqlite/SQLiteJDBCLoader.java",
"license": "apache-2.0",
"size": 12301
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 2,530,966 |
public static L3ModificationInstruction modL3Src(IpAddress addr) {
checkNotNull(addr, "Src l3 IPv4 address cannot be null");
return new ModIPInstruction(L3SubType.IPV4_SRC, addr);
} | static L3ModificationInstruction function(IpAddress addr) { checkNotNull(addr, STR); return new ModIPInstruction(L3SubType.IPV4_SRC, addr); } | /**
* Creates a L3 IPv4 src modification.
*
* @param addr the IPv4 address to modify to
* @return a L3 modification
*/ | Creates a L3 IPv4 src modification | modL3Src | {
"repo_name": "kuangrewawa/onos",
"path": "core/api/src/main/java/org/onosproject/net/flow/instructions/Instructions.java",
"license": "apache-2.0",
"size": 15029
} | [
"com.google.common.base.Preconditions",
"org.onlab.packet.IpAddress",
"org.onosproject.net.flow.instructions.L3ModificationInstruction"
] | import com.google.common.base.Preconditions; import org.onlab.packet.IpAddress; import org.onosproject.net.flow.instructions.L3ModificationInstruction; | import com.google.common.base.*; import org.onlab.packet.*; import org.onosproject.net.flow.instructions.*; | [
"com.google.common",
"org.onlab.packet",
"org.onosproject.net"
] | com.google.common; org.onlab.packet; org.onosproject.net; | 906,326 |
public XMLSignatureInput getContentsBeforeTransformation()
throws ReferenceNotInitializedException {
try {
Attr uriAttr =
getElement().getAttributeNodeNS(null, Constants._ATT_URI);
ResourceResolver resolver =
ResourceResolver.getInstance(
... | XMLSignatureInput function() throws ReferenceNotInitializedException { try { Attr uriAttr = getElement().getAttributeNodeNS(null, Constants._ATT_URI); ResourceResolver resolver = ResourceResolver.getInstance( uriAttr, this.baseURI, this.manifest.getPerManifestResolvers(), secureValidation ); resolver.addProperties(this... | /**
* Returns the XMLSignatureInput which is created by de-referencing the URI attribute.
* @return the XMLSignatureInput of the source of this reference
* @throws ReferenceNotInitializedException If the resolver found any
* problem resolving the reference
*/ | Returns the XMLSignatureInput which is created by de-referencing the URI attribute | getContentsBeforeTransformation | {
"repo_name": "Legostaev/xmlsec-gost",
"path": "src/main/java/org/apache/xml/security/signature/Reference.java",
"license": "apache-2.0",
"size": 29792
} | [
"org.apache.xml.security.utils.Constants",
"org.apache.xml.security.utils.resolver.ResourceResolver",
"org.apache.xml.security.utils.resolver.ResourceResolverException",
"org.w3c.dom.Attr"
] | import org.apache.xml.security.utils.Constants; import org.apache.xml.security.utils.resolver.ResourceResolver; import org.apache.xml.security.utils.resolver.ResourceResolverException; import org.w3c.dom.Attr; | import org.apache.xml.security.utils.*; import org.apache.xml.security.utils.resolver.*; import org.w3c.dom.*; | [
"org.apache.xml",
"org.w3c.dom"
] | org.apache.xml; org.w3c.dom; | 1,033,312 |
public void setEvents(Collection<Event> events) {
this.events = events;
} | void function(Collection<Event> events) { this.events = events; } | /**
* The events associated with a person.
*
* @param events The events associated with a person.
*/ | The events associated with a person | setEvents | {
"repo_name": "uniqueid001/enunciate",
"path": "examples/cxf/src/main/java/com/webcohesion/enunciate/examples/cxf/genealogy/data/Person.java",
"license": "apache-2.0",
"size": 3520
} | [
"java.util.Collection"
] | import java.util.Collection; | import java.util.*; | [
"java.util"
] | java.util; | 322,568 |
public ServiceCall<Void> putDateTimeRfc1123ValidAsync(Map<String, DateTime> arrayBody, final ServiceCallback<Void> serviceCallback) {
return ServiceCall.fromResponse(putDateTimeRfc1123ValidWithServiceResponseAsync(arrayBody), serviceCallback);
} | ServiceCall<Void> function(Map<String, DateTime> arrayBody, final ServiceCallback<Void> serviceCallback) { return ServiceCall.fromResponse(putDateTimeRfc1123ValidWithServiceResponseAsync(arrayBody), serviceCallback); } | /**
* Set dictionary value empty {"0": "Fri, 01 Dec 2000 00:00:01 GMT", "1": "Wed, 02 Jan 1980 00:11:35 GMT", "2": "Wed, 12 Oct 1492 10:15:01 GMT"}.
*
* @param arrayBody the Map<String, DateTimeRfc1123> value
* @param serviceCallback the async ServiceCallback to handle successful and failed re... | Set dictionary value empty {"0": "Fri, 01 Dec 2000 00:00:01 GMT", "1": "Wed, 02 Jan 1980 00:11:35 GMT", "2": "Wed, 12 Oct 1492 10:15:01 GMT"} | putDateTimeRfc1123ValidAsync | {
"repo_name": "matthchr/autorest",
"path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/bodydictionary/implementation/DictionarysImpl.java",
"license": "mit",
"size": 210563
} | [
"com.microsoft.rest.ServiceCall",
"com.microsoft.rest.ServiceCallback",
"java.util.Map",
"org.joda.time.DateTime"
] | import com.microsoft.rest.ServiceCall; import com.microsoft.rest.ServiceCallback; import java.util.Map; import org.joda.time.DateTime; | import com.microsoft.rest.*; import java.util.*; import org.joda.time.*; | [
"com.microsoft.rest",
"java.util",
"org.joda.time"
] | com.microsoft.rest; java.util; org.joda.time; | 2,119,917 |
@Test
public void validateFilteredConcat() {
final TestRunner testRunner = TestRunners.newTestRunner(new MatchIP());
testRunner.setProperty(MatchQuery.ON_MATCH_POLICY, MatchQuery.OnMatchPolicy.all.toString());
testRunner.setProperty("match_exception", "exception:match");
testRunn... | void function() { final TestRunner testRunner = TestRunners.newTestRunner(new MatchIP()); testRunner.setProperty(MatchQuery.ON_MATCH_POLICY, MatchQuery.OnMatchPolicy.all.toString()); testRunner.setProperty(STR, STR); testRunner.setProperty(STR, STR); testRunner.assertValid(); testRunner.clearQueues(); testRunner.enqueu... | /**
* Only matching records are not filtered out.
* Records that match more than one query are NOT duplicated but the matching query information are
* concatenated in record fields.
*/ | Only matching records are not filtered out. Records that match more than one query are NOT duplicated but the matching query information are concatenated in record fields | validateFilteredConcat | {
"repo_name": "Hurence/log-island",
"path": "logisland-components/logisland-processors/logisland-processor-querymatcher/src/test/java/com/hurence/logisland/processor/MatchIPTest.java",
"license": "apache-2.0",
"size": 18514
} | [
"com.hurence.logisland.record.Field",
"com.hurence.logisland.util.runner.MockRecord",
"com.hurence.logisland.util.runner.TestRunner",
"com.hurence.logisland.util.runner.TestRunners",
"java.util.List",
"org.junit.Assert"
] | import com.hurence.logisland.record.Field; import com.hurence.logisland.util.runner.MockRecord; import com.hurence.logisland.util.runner.TestRunner; import com.hurence.logisland.util.runner.TestRunners; import java.util.List; import org.junit.Assert; | import com.hurence.logisland.record.*; import com.hurence.logisland.util.runner.*; import java.util.*; import org.junit.*; | [
"com.hurence.logisland",
"java.util",
"org.junit"
] | com.hurence.logisland; java.util; org.junit; | 316,399 |
Itemset cloneItemSetMinusItems(Map<Item, BitSet> mapSequenceID) {
Itemset itemset = new Itemset();
itemset.timestamp = timestamp;
for(Item item : items){
if(mapSequenceID.get(item)!=null){
itemset.addItem(item);
}
}
return itemset;
} | Itemset cloneItemSetMinusItems(Map<Item, BitSet> mapSequenceID) { Itemset itemset = new Itemset(); itemset.timestamp = timestamp; for(Item item : items){ if(mapSequenceID.get(item)!=null){ itemset.addItem(item); } } return itemset; } | /**
* It clones the itemset ignoring the items that are non-frequent.
* @param mapSequenceID the map of items with their associated bitsets representing their sequence IDs
* @return the clone
*/ | It clones the itemset ignoring the items that are non-frequent | cloneItemSetMinusItems | {
"repo_name": "ArneBinder/LanguageAnalyzer",
"path": "src/main/java/ca/pfv/spmf/algorithms/sequentialpatterns/prefixSpan_AGP/items/Itemset.java",
"license": "gpl-3.0",
"size": 6230
} | [
"java.util.BitSet",
"java.util.Map"
] | import java.util.BitSet; import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 1,446,493 |
public static <P> P createPort(final Service service, final Class portType, final String url, final Handler handler) {
final P port = createPort(service, portType, url);
setHandler(port, handler);
LoggerUtils.log(getLogger(), Level.FINE, "Session Port = [{0}]", port);
return port;... | static <P> P function(final Service service, final Class portType, final String url, final Handler handler) { final P port = createPort(service, portType, url); setHandler(port, handler); LoggerUtils.log(getLogger(), Level.FINE, STR, port); return port; } | /**
* Create a usable session port including a URL and session id.
*
* @param <P> the type of port to create.
*
* @param service the service to call.
* @param portType used to retrieve a port from the service.
* @param url the URL for the port.
* @param handler the ne... | Create a usable session port including a URL and session id | createPort | {
"repo_name": "FlossWare/jCore",
"path": "src/main/java/org/flossware/jcore/utils/soap/SoapUtils.java",
"license": "gpl-3.0",
"size": 14280
} | [
"java.util.logging.Level",
"javax.xml.ws.Service",
"javax.xml.ws.handler.Handler",
"org.flossware.jcore.utils.LoggerUtils"
] | import java.util.logging.Level; import javax.xml.ws.Service; import javax.xml.ws.handler.Handler; import org.flossware.jcore.utils.LoggerUtils; | import java.util.logging.*; import javax.xml.ws.*; import javax.xml.ws.handler.*; import org.flossware.jcore.utils.*; | [
"java.util",
"javax.xml",
"org.flossware.jcore"
] | java.util; javax.xml; org.flossware.jcore; | 2,244,947 |
public int getSelectionStart(int line)
{
if(line == selectionStartLine)
return selectionStart;
else if(rectSelect)
{
Element map = document.getDefaultRootElement();
int start = selectionStart - map.getElement(selectionStartLine)
.getStartOffset();
Element lineE... | int function(int line) { if(line == selectionStartLine) return selectionStart; else if(rectSelect) { Element map = document.getDefaultRootElement(); int start = selectionStart - map.getElement(selectionStartLine) .getStartOffset(); Element lineElement = map.getElement(line); int lineStart = lineElement.getStartOffset()... | /**
* Returns the offset where the selection starts on the specified
* line.
*/ | Returns the offset where the selection starts on the specified line | getSelectionStart | {
"repo_name": "natetrue/ReplicatorG",
"path": "src/replicatorg/app/syntax/JEditTextArea.java",
"license": "gpl-2.0",
"size": 60498
} | [
"javax.swing.text.Element"
] | import javax.swing.text.Element; | import javax.swing.text.*; | [
"javax.swing"
] | javax.swing; | 1,317,106 |
@Aspect(advice = org.support.project.ormapping.transaction.Transaction.class)
public LikesEntity selectOnKey(Long no) {
String sql = SQLManager.getInstance().getSql("/org/support/project/knowledge/dao/sql/LikesDao/LikesDao_select_on_key.sql");
return executeQuerySingle(sql, LikesEntity.class, no... | @Aspect(advice = org.support.project.ormapping.transaction.Transaction.class) LikesEntity function(Long no) { String sql = SQLManager.getInstance().getSql(STR); return executeQuerySingle(sql, LikesEntity.class, no); } | /**
* Select data that not deleted on key.
* @param no no
* @return data
*/ | Select data that not deleted on key | selectOnKey | {
"repo_name": "support-project/knowledge",
"path": "src/main/java/org/support/project/knowledge/dao/gen/GenLikesDao.java",
"license": "apache-2.0",
"size": 16247
} | [
"org.support.project.aop.Aspect",
"org.support.project.knowledge.entity.LikesEntity",
"org.support.project.ormapping.common.SQLManager"
] | import org.support.project.aop.Aspect; import org.support.project.knowledge.entity.LikesEntity; import org.support.project.ormapping.common.SQLManager; | import org.support.project.aop.*; import org.support.project.knowledge.entity.*; import org.support.project.ormapping.common.*; | [
"org.support.project"
] | org.support.project; | 2,706,169 |
private boolean nodeExists(Connection dbConn, String nodeLabel) throws SQLException {
PreparedStatement stmt = null;
ResultSet rs = null;
final DBUtils d = new DBUtils(getClass());
try {
stmt = dbConn.prepareStatement(SQL_QUERY_NODE_EXIST);
d.watch(stmt);
... | boolean function(Connection dbConn, String nodeLabel) throws SQLException { PreparedStatement stmt = null; ResultSet rs = null; final DBUtils d = new DBUtils(getClass()); try { stmt = dbConn.prepareStatement(SQL_QUERY_NODE_EXIST); d.watch(stmt); stmt.setString(1, nodeLabel); rs = stmt.executeQuery(); d.watch(rs); retur... | /**
* Returns true if and only a node with the give label exists
*
* @param dbConn
* a database connection
* @param nodeLabel
* the label to check
* @return true iff the node exists
* @throws SQLException
* if a database error occurs
*... | Returns true if and only a node with the give label exists | nodeExists | {
"repo_name": "bugcy013/opennms-tmp-tools",
"path": "opennms-services/src/main/java/org/opennms/netmgt/capsd/BroadcastEventProcessor.java",
"license": "gpl-2.0",
"size": 95288
} | [
"java.sql.Connection",
"java.sql.PreparedStatement",
"java.sql.ResultSet",
"java.sql.SQLException",
"org.opennms.core.utils.DBUtils"
] | import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import org.opennms.core.utils.DBUtils; | import java.sql.*; import org.opennms.core.utils.*; | [
"java.sql",
"org.opennms.core"
] | java.sql; org.opennms.core; | 1,218,461 |
void updateGroup(DeviceGroup deviceGroup, int groupId, int tenantId)
throws GroupManagementDAOException; | void updateGroup(DeviceGroup deviceGroup, int groupId, int tenantId) throws GroupManagementDAOException; | /**
* Update an existing Device Group.
*
* @param deviceGroup group to update.
* @param groupId of Device Group.
* @param tenantId of the group.
* @throws GroupManagementDAOException
*/ | Update an existing Device Group | updateGroup | {
"repo_name": "charithag/carbon-device-mgt",
"path": "components/device-mgt/org.wso2.carbon.device.mgt.core/src/main/java/org/wso2/carbon/device/mgt/core/dao/GroupDAO.java",
"license": "apache-2.0",
"size": 9568
} | [
"org.wso2.carbon.device.mgt.common.group.mgt.DeviceGroup"
] | import org.wso2.carbon.device.mgt.common.group.mgt.DeviceGroup; | import org.wso2.carbon.device.mgt.common.group.mgt.*; | [
"org.wso2.carbon"
] | org.wso2.carbon; | 568,545 |
public void testInvalidOIDEncodings() {
byte[][] testcase = new byte[][] {
// incorrect tag: MUST be 0x06
new byte[] { 0x05, 0x03, 0x55, 0x04, 0x03 },
// incorrect length: MUST be 0x03
new byte[] { 0x06, 0x07, 0x55, 0x04, 0x03 },
// in... | void function() { byte[][] testcase = new byte[][] { new byte[] { 0x05, 0x03, 0x55, 0x04, 0x03 }, new byte[] { 0x06, 0x07, 0x55, 0x04, 0x03 }, new byte[] { 0x06, 0x03, 0x55, 0x04, (byte) 0x83 } }; for (int i = 0; i < testcase.length; i++) { try { new Oid(testcase[i]); fail(STR + i); } catch (GSSException e) { assertEqu... | /**
* Oid constructors Oid(byte[] oid) and Oid(InputStream oid)
* are tested in case when an invalid oid encoding is passed as a parameter
*/ | Oid constructors Oid(byte[] oid) and Oid(InputStream oid) are tested in case when an invalid oid encoding is passed as a parameter | testInvalidOIDEncodings | {
"repo_name": "rex-xxx/mt6572_x201",
"path": "external/apache-harmony/auth/src/test/java/common/org/ietf/jgss/OidTest.java",
"license": "gpl-2.0",
"size": 11341
} | [
"java.io.ByteArrayInputStream"
] | import java.io.ByteArrayInputStream; | import java.io.*; | [
"java.io"
] | java.io; | 422,702 |
private boolean isNegatedNode(NodeInst ni)
{
for(Iterator<Connection> it = ni.getConnections(); it.hasNext(); )
{
Connection con = it.next();
PortInst pi = con.getPortInst();
PortProto pp = pi.getPortProto();
if (pp.getCharacteristic() != PortCharacteristic.OUT) continue;
if (con.isNegated()) r... | boolean function(NodeInst ni) { for(Iterator<Connection> it = ni.getConnections(); it.hasNext(); ) { Connection con = it.next(); PortInst pi = con.getPortInst(); PortProto pp = pi.getPortProto(); if (pp.getCharacteristic() != PortCharacteristic.OUT) continue; if (con.isNegated()) return true; } return false; } | /**
* Method to determine whether a nodeinst has an output arc that is negated.
* @param ni the NodeInst that may be negated.
* @return true if the NodeInst is negated (its output is negated).
*/ | Method to determine whether a nodeinst has an output arc that is negated | isNegatedNode | {
"repo_name": "imr/Electric8",
"path": "com/sun/electric/tool/io/output/Tegas.java",
"license": "gpl-3.0",
"size": 27656
} | [
"com.sun.electric.database.prototype.PortCharacteristic",
"com.sun.electric.database.prototype.PortProto",
"com.sun.electric.database.topology.Connection",
"com.sun.electric.database.topology.NodeInst",
"com.sun.electric.database.topology.PortInst",
"java.util.Iterator"
] | import com.sun.electric.database.prototype.PortCharacteristic; import com.sun.electric.database.prototype.PortProto; import com.sun.electric.database.topology.Connection; import com.sun.electric.database.topology.NodeInst; import com.sun.electric.database.topology.PortInst; import java.util.Iterator; | import com.sun.electric.database.prototype.*; import com.sun.electric.database.topology.*; import java.util.*; | [
"com.sun.electric",
"java.util"
] | com.sun.electric; java.util; | 1,409,248 |
public void setJTree(JTree tree) {
this.tree = tree;
} | void function(JTree tree) { this.tree = tree; } | /**
* Sets the JTree attribute of the JMeterTreeListener object.
*
* @param tree
* the new JTree value
*/ | Sets the JTree attribute of the JMeterTreeListener object | setJTree | {
"repo_name": "benbenw/jmeter",
"path": "src/core/src/main/java/org/apache/jmeter/gui/tree/JMeterTreeListener.java",
"license": "apache-2.0",
"size": 8642
} | [
"javax.swing.JTree"
] | import javax.swing.JTree; | import javax.swing.*; | [
"javax.swing"
] | javax.swing; | 1,262,681 |
public ItemStack[] getContents() {
// TODO: Defensive deep copy
return slots;
}
public static class Entry {
public final int slot;
public final ItemStack item;
public Entry(int slot, ItemStack item) {
this.slot = slot;
this.item = item;... | ItemStack[] function() { return slots; } public static class Entry { public final int slot; public final ItemStack item; public Entry(int slot, ItemStack item) { this.slot = slot; this.item = item; } } | /**
* Get the current contents of the viewed inventory.
*
* @return The contents.
*/ | Get the current contents of the viewed inventory | getContents | {
"repo_name": "GlowstoneMC/GlowstonePlusPlus",
"path": "src/main/java/net/glowstone/inventory/InventoryMonitor.java",
"license": "mit",
"size": 4420
} | [
"org.bukkit.inventory.ItemStack"
] | import org.bukkit.inventory.ItemStack; | import org.bukkit.inventory.*; | [
"org.bukkit.inventory"
] | org.bukkit.inventory; | 2,282,262 |
String text = opact.getContent();
String state = opact.getState();
return Constants.escape(text, Constants.DB_ATTRIB_DELIM) + Constants.DB_ATTRIB_DELIM + state;
} | String text = opact.getContent(); String state = opact.getState(); return Constants.escape(text, Constants.DB_ATTRIB_DELIM) + Constants.DB_ATTRIB_DELIM + state; } | /**
* Format each operator action entry
*
* @param opact
* the entry
* @return the formatted string
*/ | Format each operator action entry | format | {
"repo_name": "tdefilip/opennms",
"path": "opennms-dao-api/src/main/java/org/opennms/netmgt/dao/util/OperatorAction.java",
"license": "agpl-3.0",
"size": 3280
} | [
"org.opennms.netmgt.model.events.Constants"
] | import org.opennms.netmgt.model.events.Constants; | import org.opennms.netmgt.model.events.*; | [
"org.opennms.netmgt"
] | org.opennms.netmgt; | 988,164 |
public static ValidationResult updateNicForBackwardCompatibility(VmNic nic,
VmNic oldNic,
String networkName,
boolean portMirroring,
VmBase vm,
DbUser user) {
// if network wasn't provided, no need for backward compatibility logic
if (netw... | static ValidationResult function(VmNic nic, VmNic oldNic, String networkName, boolean portMirroring, VmBase vm, DbUser user) { if (networkName == null) { return ValidationResult.VALID; } if (oldNic != null && oldNic.getVnicProfileId() != null) { VnicProfile oldProfile = getVnicProfileDao().get(oldNic.getVnicProfileId()... | /**
* Since the network name and port mirroring attributed were replaced on the {@link VmNic} with the vnic profile id,
* a certain logic should be applied to translate a given usage of the former api to the expected one.
*
* @param nic
* the candidate nic to apply the logic for
... | Since the network name and port mirroring attributed were replaced on the <code>VmNic</code> with the vnic profile id, a certain logic should be applied to translate a given usage of the former api to the expected one | updateNicForBackwardCompatibility | {
"repo_name": "jtux270/translate",
"path": "ovirt/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/network/vm/VnicProfileHelper.java",
"license": "gpl-3.0",
"size": 10288
} | [
"java.util.List",
"org.apache.commons.lang.StringUtils",
"org.ovirt.engine.core.bll.ValidationResult",
"org.ovirt.engine.core.common.businessentities.VmBase",
"org.ovirt.engine.core.common.businessentities.aaa.DbUser",
"org.ovirt.engine.core.common.businessentities.network.Network",
"org.ovirt.engine.co... | import java.util.List; import org.apache.commons.lang.StringUtils; import org.ovirt.engine.core.bll.ValidationResult; import org.ovirt.engine.core.common.businessentities.VmBase; import org.ovirt.engine.core.common.businessentities.aaa.DbUser; import org.ovirt.engine.core.common.businessentities.network.Network; import... | import java.util.*; import org.apache.commons.lang.*; import org.ovirt.engine.core.bll.*; import org.ovirt.engine.core.common.businessentities.*; import org.ovirt.engine.core.common.businessentities.aaa.*; import org.ovirt.engine.core.common.businessentities.network.*; import org.ovirt.engine.core.common.errors.*; | [
"java.util",
"org.apache.commons",
"org.ovirt.engine"
] | java.util; org.apache.commons; org.ovirt.engine; | 1,630,483 |
if (jsonItem==JSONObject.NULL){
return null;
}
if (jsonItem instanceof JSONArray) {
return listFromJSONArray((JSONArray)jsonItem);
}
if (jsonItem instanceof JSONObject) {
return mapFromJSONObject((JSONObject)jsonItem);
}
return jsonItem... | if (jsonItem==JSONObject.NULL){ return null; } if (jsonItem instanceof JSONArray) { return listFromJSONArray((JSONArray)jsonItem); } if (jsonItem instanceof JSONObject) { return mapFromJSONObject((JSONObject)jsonItem); } return jsonItem; } | /**
* If argument is a JSONArray or JSONObject, returns the equivalent List or Map. If argument
* is JSONObject.NULL, returns null. Otherwise, returns the argument unchanged.
*/ | If argument is a JSONArray or JSONObject, returns the equivalent List or Map. If argument is JSONObject.NULL, returns null. Otherwise, returns the argument unchanged | objectFromJSONItem | {
"repo_name": "bestwpw/Vector-Pinball",
"path": "src/com/dozingcatsoftware/bouncy/util/JSONUtils.java",
"license": "gpl-3.0",
"size": 2921
} | [
"org.json.JSONArray",
"org.json.JSONObject"
] | import org.json.JSONArray; import org.json.JSONObject; | import org.json.*; | [
"org.json"
] | org.json; | 258,786 |
public Account updateAccount(String friendlyName) throws ZangException {
return updateAccount(conf.getSid(), friendlyName);
} | Account function(String friendlyName) throws ZangException { return updateAccount(conf.getSid(), friendlyName); } | /**
* Updates account information.
*
* @param friendlyName The new friendly name for this account
* @return Updated account
* @throws ZangException
*/ | Updates account information | updateAccount | {
"repo_name": "zang-cloud/zang-java",
"path": "src/main/java/com/zang/api/connectors/AccountsConnector.java",
"license": "mit",
"size": 2146
} | [
"com.zang.api.domain.Account",
"com.zang.api.exceptions.ZangException"
] | import com.zang.api.domain.Account; import com.zang.api.exceptions.ZangException; | import com.zang.api.domain.*; import com.zang.api.exceptions.*; | [
"com.zang.api"
] | com.zang.api; | 1,824,634 |
public ArrayList<T> getResultUnmatched1() {
return getIncludedElems(elems1, getUnMatchedIndices1());
} | ArrayList<T> function() { return getIncludedElems(elems1, getUnMatchedIndices1()); } | /**
* Elements of input 1 that are not part of the LCS
* (empty before algorithm is applied)
* @return non-LCS elements for input 1
*/ | Elements of input 1 that are not part of the LCS (empty before algorithm is applied) | getResultUnmatched1 | {
"repo_name": "metaborg/jsglr",
"path": "org.spoofax.interpreter.library.jsglr/src/main/java/org/spoofax/interpreter/library/jsglr/treediff/LCS.java",
"license": "apache-2.0",
"size": 9219
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 177,399 |
public void setDomainAxis(CategoryAxis axis) {
setDomainAxis(0, axis);
} | void function(CategoryAxis axis) { setDomainAxis(0, axis); } | /**
* Sets the domain axis for the plot and sends a {@link PlotChangeEvent} to
* all registered listeners.
*
* @param axis the axis (<code>null</code> permitted).
*
* @see #getDomainAxis()
*/ | Sets the domain axis for the plot and sends a <code>PlotChangeEvent</code> to all registered listeners | setDomainAxis | {
"repo_name": "oskopek/jfreechart-fse",
"path": "src/main/java/org/jfree/chart/plot/CategoryPlot.java",
"license": "lgpl-2.1",
"size": 170549
} | [
"org.jfree.chart.axis.CategoryAxis"
] | import org.jfree.chart.axis.CategoryAxis; | import org.jfree.chart.axis.*; | [
"org.jfree.chart"
] | org.jfree.chart; | 2,686,785 |
private void checkIfNameIsUsed(@Nonnull String newName) throws Failure {
try {
Item item = getParent().getItem(newName);
if (item != null) {
throw new Failure(Messages.AbstractItem_NewNameInUse(newName));
}
try (ACLContext ctx = ACL.as(ACL.SYST... | void function(@Nonnull String newName) throws Failure { try { Item item = getParent().getItem(newName); if (item != null) { throw new Failure(Messages.AbstractItem_NewNameInUse(newName)); } try (ACLContext ctx = ACL.as(ACL.SYSTEM)) { item = getParent().getItem(newName); if (item != null) { if (LOGGER.isLoggable(Level.F... | /**
* Check new name for job
* @param newName - New name for job.
*/ | Check new name for job | checkIfNameIsUsed | {
"repo_name": "aldaris/jenkins",
"path": "core/src/main/java/hudson/model/AbstractItem.java",
"license": "mit",
"size": 38194
} | [
"hudson.security.ACL",
"hudson.security.ACLContext",
"java.util.logging.Level",
"javax.annotation.Nonnull",
"org.acegisecurity.AccessDeniedException"
] | import hudson.security.ACL; import hudson.security.ACLContext; import java.util.logging.Level; import javax.annotation.Nonnull; import org.acegisecurity.AccessDeniedException; | import hudson.security.*; import java.util.logging.*; import javax.annotation.*; import org.acegisecurity.*; | [
"hudson.security",
"java.util",
"javax.annotation",
"org.acegisecurity"
] | hudson.security; java.util; javax.annotation; org.acegisecurity; | 1,246,014 |
EAttribute getnBldFl2Sh3_Value(); | EAttribute getnBldFl2Sh3_Value(); | /**
* Returns the meta object for the attribute '{@link sc.ndt.editor.fast.fastbld.nBldFl2Sh3#getValue <em>Value</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Value</em>'.
* @see sc.ndt.editor.fast.fastbld.nBldFl2Sh3#getValue()
* @see #getnB... | Returns the meta object for the attribute '<code>sc.ndt.editor.fast.fastbld.nBldFl2Sh3#getValue Value</code>'. | getnBldFl2Sh3_Value | {
"repo_name": "cooked/NDT",
"path": "sc.ndt.editor.fast.bld/src-gen/sc/ndt/editor/fast/fastbld/FastbldPackage.java",
"license": "gpl-3.0",
"size": 123602
} | [
"org.eclipse.emf.ecore.EAttribute"
] | import org.eclipse.emf.ecore.EAttribute; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 2,480,290 |
public static short getBuildRevision() {
return getInstance()._getBuildRevision();
}
/**
* Get a reference to the <code>ResourceFactory</code>. Most applications do not need to deal with
* the <code>ResourceFactory</code> - instead one of the static <code>produce</code> methods on
* this class may b... | static short function() { return getInstance()._getBuildRevision(); } /** * Get a reference to the <code>ResourceFactory</code>. Most applications do not need to deal with * the <code>ResourceFactory</code> - instead one of the static <code>produce</code> methods on * this class may be used to create Resources. * <p> *... | /**
* Gets the build revision number of the framework implementation.
*
* @return the build revision number
*/ | Gets the build revision number of the framework implementation | getBuildRevision | {
"repo_name": "apache/uima-uimaj",
"path": "uimaj-core/src/main/java/org/apache/uima/UIMAFramework.java",
"license": "apache-2.0",
"size": 64569
} | [
"org.apache.uima.resource.Resource"
] | import org.apache.uima.resource.Resource; | import org.apache.uima.resource.*; | [
"org.apache.uima"
] | org.apache.uima; | 153,836 |
@Override
protected AmazonCloudWatchAsync build(AwsAsyncClientParams params) {
return new AmazonCloudWatchAsyncClient(params);
} | AmazonCloudWatchAsync function(AwsAsyncClientParams params) { return new AmazonCloudWatchAsyncClient(params); } | /**
* Construct an asynchronous implementation of AmazonCloudWatchAsync using the current builder configuration.
*
* @param params
* Current builder configuration represented as a parameter object.
* @return Fully configured implementation of AmazonCloudWatchAsync.
*/ | Construct an asynchronous implementation of AmazonCloudWatchAsync using the current builder configuration | build | {
"repo_name": "dagnir/aws-sdk-java",
"path": "aws-java-sdk-cloudwatch/src/main/java/com/amazonaws/services/cloudwatch/AmazonCloudWatchAsyncClientBuilder.java",
"license": "apache-2.0",
"size": 2454
} | [
"com.amazonaws.client.AwsAsyncClientParams"
] | import com.amazonaws.client.AwsAsyncClientParams; | import com.amazonaws.client.*; | [
"com.amazonaws.client"
] | com.amazonaws.client; | 1,803,612 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.