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 Composite getComposite() { return composite; }
Composite function() { return composite; }
/** * Returns the current composite. * * @return the current composite */
Returns the current composite
getComposite
{ "repo_name": "SanDisk-Open-Source/SSD_Dashboard", "path": "uefi/gcc/gcc-4.6.3/libjava/classpath/gnu/java/awt/java2d/AbstractGraphics2D.java", "license": "gpl-2.0", "size": 64351 }
[ "java.awt.Composite" ]
import java.awt.Composite;
import java.awt.*;
[ "java.awt" ]
java.awt;
15,775
protected int getNavigationLeftKey() { return KeyCodes.KEY_LEFT; }
int function() { return KeyCodes.KEY_LEFT; }
/** * Get the key that moves the selection left. By default it is the left * arrow key but by overriding this you can change the key to whatever you * want. * * @return The keycode of the key */
Get the key that moves the selection left. By default it is the left arrow key but by overriding this you can change the key to whatever you want
getNavigationLeftKey
{ "repo_name": "mstahv/framework", "path": "client/src/main/java/com/vaadin/client/ui/VMenuBar.java", "license": "apache-2.0", "size": 62170 }
[ "com.google.gwt.event.dom.client.KeyCodes" ]
import com.google.gwt.event.dom.client.KeyCodes;
import com.google.gwt.event.dom.client.*;
[ "com.google.gwt" ]
com.google.gwt;
2,371,448
void setEnd(float end) { Trace.enter(this, "setEnd", new Object[] { new Float(end) } ); try { this.end = end; Iterator i = endDependents.iterator(); while (i.hasNext()) { InstanceTime it = (InstanceTime) i.next(); it.dependentUpdate(end); } } f...
void setEnd(float end) { Trace.enter(this, STR, new Object[] { new Float(end) } ); try { this.end = end; Iterator i = endDependents.iterator(); while (i.hasNext()) { InstanceTime it = (InstanceTime) i.next(); it.dependentUpdate(end); } } finally { Trace.exit(); } }
/** * Updates the end time for this interval. */
Updates the end time for this interval
setEnd
{ "repo_name": "Uni-Sol/batik", "path": "sources/org/apache/batik/anim/timing/Interval.java", "license": "apache-2.0", "size": 5064 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
2,783,502
public static boolean saveSipConfiguration(Context ctxt, String filePassword) { File dir = PreferencesWrapper.getConfigFolder(ctxt); if (dir != null) { Date d = new Date(); File file = new File(dir.getAbsoluteFile() + File.separator + "backup_" + DateForma...
static boolean function(Context ctxt, String filePassword) { File dir = PreferencesWrapper.getConfigFolder(ctxt); if (dir != null) { Date d = new Date(); File file = new File(dir.getAbsoluteFile() + File.separator + STR + DateFormat.format(STR, d) + ".json"); Log.d(THIS_FILE, STR + file.getAbsolutePath()); JSONObject c...
/** * Save current sip configuration * * @param ctxt * @return */
Save current sip configuration
saveSipConfiguration
{ "repo_name": "xiejianying/csipsimple", "path": "src/com/csipsimple/backup/SipProfileJson.java", "license": "lgpl-3.0", "size": 13508 }
[ "android.content.Context", "android.text.TextUtils", "android.text.format.DateFormat", "com.csipsimple.utils.Log", "com.csipsimple.utils.PreferencesWrapper", "java.io.BufferedWriter", "java.io.File", "java.io.FileOutputStream", "java.io.FileWriter", "java.io.OutputStream", "java.security.Invalid...
import android.content.Context; import android.text.TextUtils; import android.text.format.DateFormat; import com.csipsimple.utils.Log; import com.csipsimple.utils.PreferencesWrapper; import java.io.BufferedWriter; import java.io.File; import java.io.FileOutputStream; import java.io.FileWriter; import java.io.OutputStre...
import android.content.*; import android.text.*; import android.text.format.*; import com.csipsimple.utils.*; import java.io.*; import java.security.*; import java.util.*; import javax.crypto.*; import javax.crypto.spec.*; import org.json.*;
[ "android.content", "android.text", "com.csipsimple.utils", "java.io", "java.security", "java.util", "javax.crypto", "org.json" ]
android.content; android.text; com.csipsimple.utils; java.io; java.security; java.util; javax.crypto; org.json;
1,996,154
public List distinct( String key, ReadPreference readPrefs ){ return distinct( key , new BasicDBObject(), readPrefs ); }
List function( String key, ReadPreference readPrefs ){ return distinct( key , new BasicDBObject(), readPrefs ); }
/** * Find the distinct values for a specified field across a collection and returns the results in an array. * * @param key Specifies the field for which to return the distinct values * @param readPrefs {@link ReadPreference} to be used for this operation * @return A {@code List} of the ...
Find the distinct values for a specified field across a collection and returns the results in an array
distinct
{ "repo_name": "antonnik/code-classifier", "path": "naive_bayes/resources/java/DBCollection.java", "license": "apache-2.0", "size": 88389 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
291,206
public int getViewHorizontalDragRange(View child) { return 0; }
int function(View child) { return 0; }
/** * Return the magnitude of a draggable child view's horizontal range of * motion in pixels. This method should return 0 for views that cannot * move horizontally. * * @param child Child view to check * @return range of horizontal motion in pixels */
Return the magnitude of a draggable child view's horizontal range of motion in pixels. This method should return 0 for views that cannot move horizontally
getViewHorizontalDragRange
{ "repo_name": "HarryXR/SimpleNews", "path": "swipeback/src/main/java/me/imid/swipebacklayout/lib/ViewDragHelper.java", "license": "apache-2.0", "size": 62159 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
2,828,343
public static Vector<Double> calculateArrowVector(double startX, double startY, double endX, double endY, double angle) { double arrowHeadLengh = 4; double dx = endX - startX; double dy = endY - startY; double length = Math.sqrt(dx * dx + dy * dy); double unitDx = dx / length; double unitDy = dy / ...
static Vector<Double> function(double startX, double startY, double endX, double endY, double angle) { double arrowHeadLengh = 4; double dx = endX - startX; double dy = endY - startY; double length = Math.sqrt(dx * dx + dy * dy); double unitDx = dx / length; double unitDy = dy / length; double point1X = endX - unitDx *...
/** * Calculates the arrow vector. The result can be read like 0=x1 1=y1 2=x2 * 3=y2. * * @param startX * @param startY * @param endX * @param endY * @param angle * @return */
Calculates the arrow vector. The result can be read like 0=x1 1=y1 2=x2 3=y2
calculateArrowVector
{ "repo_name": "MayerTh/RVRPSimulator", "path": "vrpsim-visualization/src/main/java/vrpsim/visualization/support/MathUtil.java", "license": "apache-2.0", "size": 1734 }
[ "java.util.Vector" ]
import java.util.Vector;
import java.util.*;
[ "java.util" ]
java.util;
2,203,692
public void keyReleased(KeyEvent e) { selectInteractor(e); if (interactor != null) { interactor.keyReleased(e); deselectInteractor(); } else if (eventDispatcher != null) { dispatchKeyReleased(e); } }
void function(KeyEvent e) { selectInteractor(e); if (interactor != null) { interactor.keyReleased(e); deselectInteractor(); } else if (eventDispatcher != null) { dispatchKeyReleased(e); } }
/** * Invoked when a key has been released. */
Invoked when a key has been released
keyReleased
{ "repo_name": "Groostav/CMPT880-term-project", "path": "intruder/benchs/batik/batik-1.7/sources/org/apache/batik/swing/gvt/AbstractJGVTComponent.java", "license": "apache-2.0", "size": 38043 }
[ "java.awt.event.KeyEvent" ]
import java.awt.event.KeyEvent;
import java.awt.event.*;
[ "java.awt" ]
java.awt;
850,077
public void setDebugOption(final boolean debug) { if (debug == _debug) { return; } if (_debug) { try { _logfile.close(); } catch (final IOException e) { System.out.println("Problem closing logfile."); e.printStackTrac...
void function(final boolean debug) { if (debug == _debug) { return; } if (_debug) { try { _logfile.close(); } catch (final IOException e) { System.out.println(STR); e.printStackTrace(); System.out.println(STR); } } else { try { _logfile = new FileWriter(_debugFileName); } catch (final IOException e) { System.out.printl...
/** * output file format; */
output file format
setDebugOption
{ "repo_name": "AeroGlass/g3m", "path": "tools/externals/poly2tri-java/poly2Tri/Polygon.java", "license": "bsd-2-clause", "size": 32367 }
[ "java.io.FileWriter", "java.io.IOException" ]
import java.io.FileWriter; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,683,386
@SuppressWarnings("unchecked") @Test public void testFailsIfdirectoryIsIllegal() throws Exception { // create context Context context = new ContextBase(); // create file File dir = new File(testDirectory, randomName+"\0"); File file = new File(dir, randomXmlFileName); // create documen...
@SuppressWarnings(STR) void function() throws Exception { Context context = new ContextBase(); File dir = new File(testDirectory, randomName+"\0"); File file = new File(dir, randomXmlFileName); ObjectFactory factory = new ObjectFactory(); Root root = factory.createRoot(); root.setContainer(factory.createContainerType()...
/** * Test that marshalling fails if directory is illegal. * It is illegal to use "\0" or "/" in directory names in Windows and Linux. * * @throws Exception * If test fails. */
Test that marshalling fails if directory is illegal. It is illegal to use "\0" or "/" in directory names in Windows and Linux
testFailsIfdirectoryIsIllegal
{ "repo_name": "athrane/pineapple", "path": "modules/pineapple-core/src/test/java/com/alpha/pineapple/command/MarshallJAXBObjectsCommandIntegrationTest.java", "license": "gpl-3.0", "size": 9333 }
[ "com.alpha.pineapple.model.test.ItemType", "com.alpha.pineapple.model.test.ObjectFactory", "com.alpha.pineapple.model.test.Root", "java.io.File", "org.apache.commons.chain.Context", "org.apache.commons.chain.impl.ContextBase", "org.junit.Assert" ]
import com.alpha.pineapple.model.test.ItemType; import com.alpha.pineapple.model.test.ObjectFactory; import com.alpha.pineapple.model.test.Root; import java.io.File; import org.apache.commons.chain.Context; import org.apache.commons.chain.impl.ContextBase; import org.junit.Assert;
import com.alpha.pineapple.model.test.*; import java.io.*; import org.apache.commons.chain.*; import org.apache.commons.chain.impl.*; import org.junit.*;
[ "com.alpha.pineapple", "java.io", "org.apache.commons", "org.junit" ]
com.alpha.pineapple; java.io; org.apache.commons; org.junit;
1,526,798
private ArrayWritable createMap(Object obj, CarbonColumn carbonColumn) throws IOException { Object[] objArray = (Object[]) obj; List<CarbonDimension> childCarbonDimensions = null; CarbonDimension mapDimension = null; List<ArrayWritable> writablesList = new ArrayList<>(); if (carbonColumn.isDimensi...
ArrayWritable function(Object obj, CarbonColumn carbonColumn) throws IOException { Object[] objArray = (Object[]) obj; List<CarbonDimension> childCarbonDimensions = null; CarbonDimension mapDimension = null; List<ArrayWritable> writablesList = new ArrayList<>(); if (carbonColumn.isDimension() && carbonColumn.getColumnS...
/** * Create the Map data for Map Datatype * * @param obj * @param carbonColumn * @return * @throws IOException */
Create the Map data for Map Datatype
createMap
{ "repo_name": "jackylk/incubator-carbondata", "path": "integration/hive/src/main/java/org/apache/carbondata/hive/WritableReadSupport.java", "license": "apache-2.0", "size": 9559 }
[ "java.io.IOException", "java.util.ArrayList", "java.util.List", "org.apache.carbondata.core.metadata.schema.table.column.CarbonColumn", "org.apache.carbondata.core.metadata.schema.table.column.CarbonDimension", "org.apache.hadoop.io.ArrayWritable", "org.apache.hadoop.io.Writable" ]
import java.io.IOException; import java.util.ArrayList; import java.util.List; import org.apache.carbondata.core.metadata.schema.table.column.CarbonColumn; import org.apache.carbondata.core.metadata.schema.table.column.CarbonDimension; import org.apache.hadoop.io.ArrayWritable; import org.apache.hadoop.io.Writable;
import java.io.*; import java.util.*; import org.apache.carbondata.core.metadata.schema.table.column.*; import org.apache.hadoop.io.*;
[ "java.io", "java.util", "org.apache.carbondata", "org.apache.hadoop" ]
java.io; java.util; org.apache.carbondata; org.apache.hadoop;
1,902,002
public List<Object> setAttributeValues(String name, List<Object> values);
List<Object> function(String name, List<Object> values);
/** * Sets the specified attribute values * * @param name Name of the attribute, must not be null * @param values Values for the attribute, may be null * @return The previous values for the attribute if they existed */
Sets the specified attribute values
setAttributeValues
{ "repo_name": "jco0186/person-directory-impl", "path": "src/main/java/org/jasig/services/persondir/support/IAdditionalDescriptors.java", "license": "apache-2.0", "size": 2199 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,552,849
private void CVClusters() throws Exception { double CVLogLikely = -Double.MAX_VALUE; double templl, tll; boolean CVincreased = true; m_num_clusters = 1; int upperBoundMaxClusters = (m_upperBoundNumClustersCV > 0) ? m_upperBoundNumClustersCV : Integer.MAX_VALUE; int num_clusters = m_num_c...
void function() throws Exception { double CVLogLikely = -Double.MAX_VALUE; double templl, tll; boolean CVincreased = true; m_num_clusters = 1; int upperBoundMaxClusters = (m_upperBoundNumClustersCV > 0) ? m_upperBoundNumClustersCV : Integer.MAX_VALUE; int num_clusters = m_num_clusters; int i; Random cvr; Instances trai...
/** * estimate the number of clusters by cross validation on the training data. * * @throws Exception if something goes wrong */
estimate the number of clusters by cross validation on the training data
CVClusters
{ "repo_name": "runqingz/umple", "path": "Umplificator/UmplifiedProjects/weka-umplified-0/src/main/java/weka/clusterers/EM.java", "license": "mit", "size": 59390 }
[ "java.util.Random" ]
import java.util.Random;
import java.util.*;
[ "java.util" ]
java.util;
191,716
LeaderRetrievalService getResourceManagerLeaderRetriever();
LeaderRetrievalService getResourceManagerLeaderRetriever();
/** * Gets the leader retriever for the cluster's resource manager. */
Gets the leader retriever for the cluster's resource manager
getResourceManagerLeaderRetriever
{ "repo_name": "hwstreaming/flink", "path": "flink-runtime/src/main/java/org/apache/flink/runtime/highavailability/HighAvailabilityServices.java", "license": "apache-2.0", "size": 5920 }
[ "org.apache.flink.runtime.leaderretrieval.LeaderRetrievalService" ]
import org.apache.flink.runtime.leaderretrieval.LeaderRetrievalService;
import org.apache.flink.runtime.leaderretrieval.*;
[ "org.apache.flink" ]
org.apache.flink;
2,074,949
public static String getElementLabel(IJavaElement element, long flags) { return getElementLabel(element, flags, false); }
static String function(IJavaElement element, long flags) { return getElementLabel(element, flags, false); }
/** * Returns the label for a Java element with the flags as defined by {@link JavaElementLabels}. * Referenced element names in the label (except the given element's name) are rendered as * header links. * * @param element the element to render * @param flags the rendering flags * @r...
Returns the label for a Java element with the flags as defined by <code>JavaElementLabels</code>. Referenced element names in the label (except the given element's name) are rendered as header links
getElementLabel
{ "repo_name": "sunix/che-plugins", "path": "plugin-java/che-plugin-java-ext-java-codeassistant/src/main/java/org/eclipse/che/jdt/javadoc/JavaElementLinks.java", "license": "epl-1.0", "size": 18805 }
[ "org.eclipse.jdt.core.IJavaElement" ]
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.*;
[ "org.eclipse.jdt" ]
org.eclipse.jdt;
321,972
public static KeyPair generateKeyPair(String algorithm, int keySize) { KeyPairGenerator keyPairGenerator; try { keyPairGenerator = KeyPairGenerator.getInstance(algorithm); } catch (NoSuchAlgorithmException e) { throw new IllegalArgumentException(e); } ...
static KeyPair function(String algorithm, int keySize) { KeyPairGenerator keyPairGenerator; try { keyPairGenerator = KeyPairGenerator.getInstance(algorithm); } catch (NoSuchAlgorithmException e) { throw new IllegalArgumentException(e); } keyPairGenerator.initialize(keySize); return keyPairGenerator.generateKeyPair(); }
/** * Generate a {@link KeyPair} for the given assymmetric algorithm and keysize * * Example: CipherUtils.generateKeyPair("RSA", 2048) */
Generate a <code>KeyPair</code> for the given assymmetric algorithm and keysize Example: CipherUtils.generateKeyPair("RSA", 2048)
generateKeyPair
{ "repo_name": "openengsb/openengsb", "path": "components/util/src/main/java/org/openengsb/core/util/CipherUtils.java", "license": "apache-2.0", "size": 10081 }
[ "java.security.KeyPair", "java.security.KeyPairGenerator", "java.security.NoSuchAlgorithmException" ]
import java.security.KeyPair; import java.security.KeyPairGenerator; import java.security.NoSuchAlgorithmException;
import java.security.*;
[ "java.security" ]
java.security;
1,938,118
void setDataElementStructureForDataElementGroup( Grid grid, Integer dataElementGroupId, List<Integer> metaIds );
void setDataElementStructureForDataElementGroup( Grid grid, Integer dataElementGroupId, List<Integer> metaIds );
/** * Always called first. * * Sets the structure in DataBrowserTable for DataElements. Finds all * DataElementGroups with DataValue in betweenPeriod List and given * DataElementGroupId. Then calls on helpers internally to set it up. * * @param grid the Grid to set the structure in ...
Always called first. Sets the structure in DataBrowserTable for DataElements. Finds all DataElementGroups with DataValue in betweenPeriod List and given DataElementGroupId. Then calls on helpers internally to set it up
setDataElementStructureForDataElementGroup
{ "repo_name": "minagri-rwanda/DHIS2-Agriculture", "path": "dhis-api/src/main/java/org/hisp/dhis/databrowser/DataBrowserGridStore.java", "license": "bsd-3-clause", "size": 9693 }
[ "java.util.List", "org.hisp.dhis.common.Grid" ]
import java.util.List; import org.hisp.dhis.common.Grid;
import java.util.*; import org.hisp.dhis.common.*;
[ "java.util", "org.hisp.dhis" ]
java.util; org.hisp.dhis;
993,426
public boolean loadScript(String filename) throws FileNotFoundException { String newCode = FileIO.fileToString(filename); if (newCode != null && !newCode.isEmpty()) { log.info(String.format("replacing current script with %1s", filename)); currentScript = new Script(filename, newCode); // tell other li...
boolean function(String filename) throws FileNotFoundException { String newCode = FileIO.fileToString(filename); if (newCode != null && !newCode.isEmpty()) { log.info(String.format(STR, filename)); currentScript = new Script(filename, newCode); broadcastState(); return true; } else { log.warn(String.format(STR, filenam...
/** * this method can be used to load a Python script from the Python's local * file system, which may not be the GUIService's local system. Because it * can be done programatically on a different machine we want to broadcast * our changed state to other listeners (possibly the GUIService) * * @param filen...
this method can be used to load a Python script from the Python's local file system, which may not be the GUIService's local system. Because it can be done programatically on a different machine we want to broadcast our changed state to other listeners (possibly the GUIService)
loadScript
{ "repo_name": "sujitbehera27/MyRoboticsProjects-Arduino", "path": "src/org/myrobotlab/service/Python.java", "license": "apache-2.0", "size": 21572 }
[ "java.io.FileNotFoundException", "org.myrobotlab.fileLib.FileIO" ]
import java.io.FileNotFoundException; import org.myrobotlab.fileLib.FileIO;
import java.io.*; import org.myrobotlab.*;
[ "java.io", "org.myrobotlab" ]
java.io; org.myrobotlab;
1,454,545
public static void downloadFeedItems(final Context context, FeedItem... items) throws DownloadRequestException { downloadFeedItems(true, context, items); }
static void function(final Context context, FeedItem... items) throws DownloadRequestException { downloadFeedItems(true, context, items); }
/** * Requests the download of a list of FeedItem objects. * * @param context Used for requesting the download and accessing the DB. * @param items The FeedItem objects. */
Requests the download of a list of FeedItem objects
downloadFeedItems
{ "repo_name": "udif/AntennaPod", "path": "core/src/main/java/de/danoeh/antennapod/core/storage/DBTasks.java", "license": "mit", "size": 34451 }
[ "android.content.Context", "de.danoeh.antennapod.core.feed.FeedItem" ]
import android.content.Context; import de.danoeh.antennapod.core.feed.FeedItem;
import android.content.*; import de.danoeh.antennapod.core.feed.*;
[ "android.content", "de.danoeh.antennapod" ]
android.content; de.danoeh.antennapod;
1,418,221
public static final Column getColumn(Class type, int nrows, int nnz, Object defaultValue) { if ( type == byte.class ) { if ( defaultValue == null ) { return new ByteColumn(nrows); } else { byte def =...
static final Column function(Class type, int nrows, int nnz, Object defaultValue) { if ( type == byte.class ) { if ( defaultValue == null ) { return new ByteColumn(nrows); } else { byte def = ((Number)defaultValue).byteValue(); return new ByteColumn(nrows, nrows, def); } } if ( type == int.class ) { if ( defaultValue =...
/** * Get a new column of the given type. * @param type the column data type * @param nrows the number of rows to include in the column * @param nnz the number of expected non-zero entries (NOTE: currently * this value is not being used) * @param defaultValue the default value for the colu...
Get a new column of the given type
getColumn
{ "repo_name": "ezegarra/microbrowser", "path": "src/prefuse/data/column/ColumnFactory.java", "license": "bsd-3-clause", "size": 5108 }
[ "java.util.Date" ]
import java.util.Date;
import java.util.*;
[ "java.util" ]
java.util;
1,807,281
void delete(String resourceGroupName, String dnsForwardingRulesetName, String ifMatch, Context context);
void delete(String resourceGroupName, String dnsForwardingRulesetName, String ifMatch, Context context);
/** * Deletes a DNS forwarding ruleset. WARNING: This operation cannot be undone. All forwarding rules within the * ruleset will be deleted. * * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param dnsForwardingRulesetName The name of the DNS forwardin...
ruleset will be deleted
delete
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/dnsresolver/azure-resourcemanager-dnsresolver/src/main/java/com/azure/resourcemanager/dnsresolver/models/DnsForwardingRulesets.java", "license": "mit", "size": 12362 }
[ "com.azure.core.util.Context" ]
import com.azure.core.util.Context;
import com.azure.core.util.*;
[ "com.azure.core" ]
com.azure.core;
2,797,134
public void initListCacheAndSharedPreferences(Context context) { if (mCache == null || mCache.isEmpty()) { //Load up the ZipCode Cache with the Shared preferences values SharedPreferences weatherAppPref = context.getSharedPreferences(APP_NAME, Context.MODE_PRIVATE); Has...
void function(Context context) { if (mCache == null mCache.isEmpty()) { SharedPreferences weatherAppPref = context.getSharedPreferences(APP_NAME, Context.MODE_PRIVATE); HashSet<String> defaultZipcodeSet = new HashSet<>(Arrays.asList(DEFAULT_ZIPCODES)); if (!weatherAppPref.contains(ZIPCODE_CACHE_KEY)) { mCache = default...
/** * We store the list items in the sharedPreferences * (only keeping zipcode strings for now so SqliteDatabase is unnecessary overhead) * <p> * Update in memory list cache with the current sharedPreferences * and the shared preferences with the appropriate default data as needed */
We store the list items in the sharedPreferences (only keeping zipcode strings for now so SqliteDatabase is unnecessary overhead) Update in memory list cache with the current sharedPreferences and the shared preferences with the appropriate default data as needed
initListCacheAndSharedPreferences
{ "repo_name": "laurenyew/WeatherApp", "path": "app/src/main/java/laurenyew/weatherapp/cache/ZipcodeCache.java", "license": "mit", "size": 6884 }
[ "android.content.Context", "android.content.SharedPreferences", "java.util.Arrays", "java.util.HashSet" ]
import android.content.Context; import android.content.SharedPreferences; import java.util.Arrays; import java.util.HashSet;
import android.content.*; import java.util.*;
[ "android.content", "java.util" ]
android.content; java.util;
2,819,778
public static byte[] readFile(File file) throws IOException { assert file.exists(); assert file.length() < Integer.MAX_VALUE; byte[] bytes = new byte[(int) file.length()]; try (FileInputStream fis = new FileInputStream(file)) { int readBytesCnt = fis.read(bytes); ...
static byte[] function(File file) throws IOException { assert file.exists(); assert file.length() < Integer.MAX_VALUE; byte[] bytes = new byte[(int) file.length()]; try (FileInputStream fis = new FileInputStream(file)) { int readBytesCnt = fis.read(bytes); assert readBytesCnt == bytes.length; } return bytes; }
/** * Reads entire file into byte array. * * @param file File to read. * @return Content of file in byte array. * @throws IOException If failed. */
Reads entire file into byte array
readFile
{ "repo_name": "samaitra/ignite", "path": "modules/core/src/test/java/org/apache/ignite/testframework/GridTestUtils.java", "license": "apache-2.0", "size": 82485 }
[ "java.io.File", "java.io.FileInputStream", "java.io.IOException" ]
import java.io.File; import java.io.FileInputStream; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,069,272
public void startExecuting() { this.taskOwner.setAttackTarget(this.theTarget); EntityLivingBase entitylivingbase = this.theEntityTameable.getOwnerEntity(); if (entitylivingbase != null) { this.lastAttackerTime = entitylivingbase.getLastAttackerTime(); } ...
void function() { this.taskOwner.setAttackTarget(this.theTarget); EntityLivingBase entitylivingbase = this.theEntityTameable.getOwnerEntity(); if (entitylivingbase != null) { this.lastAttackerTime = entitylivingbase.getLastAttackerTime(); } super.startExecuting(); }
/** * Execute a one shot task or start executing a continuous task */
Execute a one shot task or start executing a continuous task
startExecuting
{ "repo_name": "SolarCactus/ARKCraft-Code", "path": "src/main/java/com/arkcraft/module/creature/common/entity/ai/EntityDinoAIOwnerHurtTarget.java", "license": "mit", "size": 1856 }
[ "net.minecraft.entity.EntityLivingBase" ]
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.*;
[ "net.minecraft.entity" ]
net.minecraft.entity;
669,473
private void unregister(final ServiceReference reference, final Object service) { final String name = idToNameMap.remove(reference.getProperty(Constants.SERVICE_ID)); if ( name != null ) { this.scheduler.unschedule(reference.getBundle().getBundleId(), name); } }
void function(final ServiceReference reference, final Object service) { final String name = idToNameMap.remove(reference.getProperty(Constants.SERVICE_ID)); if ( name != null ) { this.scheduler.unschedule(reference.getBundle().getBundleId(), name); } }
/** * Unregister a service. * @param ref The service reference. */
Unregister a service
unregister
{ "repo_name": "plutext/sling", "path": "bundles/commons/scheduler/src/main/java/org/apache/sling/commons/scheduler/impl/WhiteboardHandler.java", "license": "apache-2.0", "size": 9699 }
[ "org.osgi.framework.Constants", "org.osgi.framework.ServiceReference" ]
import org.osgi.framework.Constants; import org.osgi.framework.ServiceReference;
import org.osgi.framework.*;
[ "org.osgi.framework" ]
org.osgi.framework;
1,469,167
@Override public void activateParameters() { String[] keys = listParameters(); for ( String key : keys ) { String value; try { value = getParameterValue( key ); } catch ( UnknownParamException e ) { value = ""; } String defValue; try { defValue =...
void function() { String[] keys = listParameters(); for ( String key : keys ) { String value; try { value = getParameterValue( key ); } catch ( UnknownParamException e ) { value = STRSTRSTR" ) ); } } }
/** * Activates all parameters by setting their values. If no values already exist, the method will attempt to set the * parameter to the default value. If no default value exists, the method will set the value of the parameter to the * empty string (""). * * @see org.pentaho.di.core.parameters.NamedPara...
Activates all parameters by setting their values. If no values already exist, the method will attempt to set the parameter to the default value. If no default value exists, the method will set the value of the parameter to the empty string ("")
activateParameters
{ "repo_name": "bmorrise/pentaho-kettle", "path": "engine/src/main/java/org/pentaho/di/trans/Trans.java", "license": "apache-2.0", "size": 199512 }
[ "org.pentaho.di.core.parameters.UnknownParamException" ]
import org.pentaho.di.core.parameters.UnknownParamException;
import org.pentaho.di.core.parameters.*;
[ "org.pentaho.di" ]
org.pentaho.di;
667,225
public PagedResult<SentCampaign> sentCampaigns( Date sentFromDate, Date sentToDate, String tags, Integer page, Integer pageSize, String orderDirection) throws CreateSendException { return sentCampaigns( sentFromDate != null ? JsonProvider.ApiDateFormat.format(sent...
PagedResult<SentCampaign> function( Date sentFromDate, Date sentToDate, String tags, Integer page, Integer pageSize, String orderDirection) throws CreateSendException { return sentCampaigns( sentFromDate != null ? JsonProvider.ApiDateFormat.format(sentFromDate) : null, sentToDate != null ? JsonProvider.ApiDateFormat.fo...
/** * Gets a paged list of campaigns sent by the current client * @param sentFromDate Campaigns sent on or after the <code>sentFromDate/code> value specified will be returned. * Must be in the format YYYY-MM-DD. If not provided, results will go back to the beginning of the client’s...
Gets a paged list of campaigns sent by the current client
sentCampaigns
{ "repo_name": "campaignmonitor/createsend-java", "path": "src/com/createsend/Clients.java", "license": "mit", "size": 20122 }
[ "com.createsend.models.PagedResult", "com.createsend.models.campaigns.SentCampaign", "com.createsend.util.exceptions.CreateSendException", "com.createsend.util.jersey.JsonProvider", "java.util.Date" ]
import com.createsend.models.PagedResult; import com.createsend.models.campaigns.SentCampaign; import com.createsend.util.exceptions.CreateSendException; import com.createsend.util.jersey.JsonProvider; import java.util.Date;
import com.createsend.models.*; import com.createsend.models.campaigns.*; import com.createsend.util.exceptions.*; import com.createsend.util.jersey.*; import java.util.*;
[ "com.createsend.models", "com.createsend.util", "java.util" ]
com.createsend.models; com.createsend.util; java.util;
1,041,675
private RemoveNetworkCmd executeRemoveNetworkRequest(DockerClient client, Message message) { LOGGER.debug("Executing Docker Network Remove Request"); String networkId = DockerHelper.getProperty(DockerConstants.DOCKER_NETWORK, configuration, message, String.class); ObjectHelper.notNull(net...
RemoveNetworkCmd function(DockerClient client, Message message) { LOGGER.debug(STR); String networkId = DockerHelper.getProperty(DockerConstants.DOCKER_NETWORK, configuration, message, String.class); ObjectHelper.notNull(networkId, STR); RemoveNetworkCmd removeNetworkCmd = client.removeNetworkCmd(networkId); return rem...
/** * Produces a network remove request * * @param client * @param message * @return */
Produces a network remove request
executeRemoveNetworkRequest
{ "repo_name": "objectiser/camel", "path": "components/camel-docker/src/main/java/org/apache/camel/component/docker/producer/DockerProducer.java", "license": "apache-2.0", "size": 41056 }
[ "com.github.dockerjava.api.DockerClient", "com.github.dockerjava.api.command.RemoveNetworkCmd", "org.apache.camel.Message", "org.apache.camel.component.docker.DockerConstants", "org.apache.camel.component.docker.DockerHelper", "org.apache.camel.util.ObjectHelper" ]
import com.github.dockerjava.api.DockerClient; import com.github.dockerjava.api.command.RemoveNetworkCmd; import org.apache.camel.Message; import org.apache.camel.component.docker.DockerConstants; import org.apache.camel.component.docker.DockerHelper; import org.apache.camel.util.ObjectHelper;
import com.github.dockerjava.api.*; import com.github.dockerjava.api.command.*; import org.apache.camel.*; import org.apache.camel.component.docker.*; import org.apache.camel.util.*;
[ "com.github.dockerjava", "org.apache.camel" ]
com.github.dockerjava; org.apache.camel;
2,841,640
@Override public void accept(SocketChannel sc) { String cid = "" + port_props.get("local-hostname") + "@" + port_props.get("remote-hostname"); if (log.isLoggable(Level.FINEST)) { log.log(Level.FINEST, "Accept called for service: {0}", cid); } IO serv = getXMPPIOServiceInstance(); serv.s...
void function(SocketChannel sc) { String cid = STRlocal-hostnameSTR@STRremote-hostnameSTRAccept called for service: {0}STRProblem reconnecting the service: {0}, cid: {1}STRCan not accept connection cid: STRCan not accept connection.", e); serv.stop(); } }
/** * Method description * * * @param sc */
Method description
accept
{ "repo_name": "Smartupz/tigase-server", "path": "src/main/java/tigase/server/ConnectionManager.java", "license": "agpl-3.0", "size": 35213 }
[ "java.nio.channels.SocketChannel" ]
import java.nio.channels.SocketChannel;
import java.nio.channels.*;
[ "java.nio" ]
java.nio;
416,794
int getFlowsNumber(Node node);
int getFlowsNumber(Node node);
/** * Returns the number of flows installed on the switch in the current * container context If the context is the default container, the returned * value is the number of all the flows installed on the switch regardless * of the container they belong to * * @param node * @return numb...
Returns the number of flows installed on the switch in the current container context If the context is the default container, the returned value is the number of all the flows installed on the switch regardless of the container they belong to
getFlowsNumber
{ "repo_name": "lbchen/ODL", "path": "opendaylight/statisticsmanager/api/src/main/java/org/opendaylight/controller/statisticsmanager/IStatisticsManager.java", "license": "epl-1.0", "size": 3923 }
[ "org.opendaylight.controller.sal.core.Node" ]
import org.opendaylight.controller.sal.core.Node;
import org.opendaylight.controller.sal.core.*;
[ "org.opendaylight.controller" ]
org.opendaylight.controller;
1,987,400
public List<String> getHashSetNames() { return Collections.unmodifiableList(hashSetNames); }
List<String> function() { return Collections.unmodifiableList(hashSetNames); }
/** * Get the hash set names for this file * * @return The hash set names that matched this file. */
Get the hash set names for this file
getHashSetNames
{ "repo_name": "eugene7646/autopsy", "path": "Core/src/org/sleuthkit/autopsy/discovery/search/ResultFile.java", "license": "apache-2.0", "size": 13383 }
[ "java.util.Collections", "java.util.List" ]
import java.util.Collections; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,594,410
@Override public void enterCharacterLiteral(@NotNull BramsprParser.CharacterLiteralContext ctx) { }
@Override public void enterCharacterLiteral(@NotNull BramsprParser.CharacterLiteralContext ctx) { }
/** * {@inheritDoc} * <p/> * The default implementation does nothing. */
The default implementation does nothing
exitAssignableExpression
{ "repo_name": "bcleenders/Bramspr", "path": "src/bramspr/BramsprBaseListener.java", "license": "mit", "size": 21948 }
[ "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,277,702
private boolean drawBufferedImage(Image img, BufferedImage bufferedImage, int width, int height, ImageObserver observer) { java.awt.Graphics2D g2d = bufferedImage.createGraphics(); try { g2d.setComposite(AlphaComposite.SrcOver); Color color = new Color(1, 1, 1, ...
boolean function(Image img, BufferedImage bufferedImage, int width, int height, ImageObserver observer) { java.awt.Graphics2D g2d = bufferedImage.createGraphics(); try { g2d.setComposite(AlphaComposite.SrcOver); Color color = new Color(1, 1, 1, 0); g2d.setBackground(color); g2d.setPaint(color); g2d.fillRect(0, 0, width...
/** * Draws an AWT image into a BufferedImage using an AWT Graphics2D implementation * * @param img the AWT image * @param bufferedImage the AWT buffered image * @param width the image width * @param height the image height * @param observer the image observer * @return true if t...
Draws an AWT image into a BufferedImage using an AWT Graphics2D implementation
drawBufferedImage
{ "repo_name": "argv-minus-one/fop", "path": "fop-core/src/main/java/org/apache/fop/afp/AFPGraphics2D.java", "license": "apache-2.0", "size": 24025 }
[ "java.awt.AlphaComposite", "java.awt.Color", "java.awt.Image", "java.awt.Rectangle", "java.awt.image.BufferedImage", "java.awt.image.ImageObserver" ]
import java.awt.AlphaComposite; import java.awt.Color; import java.awt.Image; import java.awt.Rectangle; import java.awt.image.BufferedImage; import java.awt.image.ImageObserver;
import java.awt.*; import java.awt.image.*;
[ "java.awt" ]
java.awt;
707,018
public static void addGrassSeed(@Nonnull ItemStack seed, int weight) { addGrassSeed(new SeedEntry(seed, weight)); }
static void function(@Nonnull ItemStack seed, int weight) { addGrassSeed(new SeedEntry(seed, weight)); }
/** * Register a new seed to be dropped when breaking tall grass. * * @param seed The item to drop as a seed. * @param weight The relative probability of the seeds, * where wheat seeds are 10. * * Note: These functions may be going away soon, we're looking into loot tabl...
Register a new seed to be dropped when breaking tall grass
addGrassSeed
{ "repo_name": "SuperUnitato/UnLonely", "path": "build/tmp/recompileMc/sources/net/minecraftforge/common/MinecraftForge.java", "license": "lgpl-2.1", "size": 4536 }
[ "javax.annotation.Nonnull", "net.minecraft.item.ItemStack", "net.minecraftforge.common.ForgeHooks" ]
import javax.annotation.Nonnull; import net.minecraft.item.ItemStack; import net.minecraftforge.common.ForgeHooks;
import javax.annotation.*; import net.minecraft.item.*; import net.minecraftforge.common.*;
[ "javax.annotation", "net.minecraft.item", "net.minecraftforge.common" ]
javax.annotation; net.minecraft.item; net.minecraftforge.common;
443,845
@Test public void testBrokerProxySwitchBrokerPermissionNotGranted() throws PackageManager.NameNotFoundException, NoSuchAlgorithmException { final Context context = getMockContext(); final PackageManager mockedPackageManager = context.getPackageManager(); final SignatureData ...
void function() throws PackageManager.NameNotFoundException, NoSuchAlgorithmException { final Context context = getMockContext(); final PackageManager mockedPackageManager = context.getPackageManager(); final SignatureData signatureData = getSignature(InstrumentationRegistry.getContext(), InstrumentationRegistry.getCon...
/** * Verify even if GET_ACCOUNTS permission is not granted, if BrokerAccountService exists, * {@link BrokerProxy#canSwitchToBroker(String)} will return true. */
Verify even if GET_ACCOUNTS permission is not granted, if BrokerAccountService exists, <code>BrokerProxy#canSwitchToBroker(String)</code> will return true
testBrokerProxySwitchBrokerPermissionNotGranted
{ "repo_name": "iambmelt/azure-activedirectory-library-for-android", "path": "adal/src/androidTest/java/com/microsoft/aad/adal/BrokerAccountServiceTest.java", "license": "apache-2.0", "size": 19394 }
[ "android.content.Context", "android.content.pm.PackageManager", "android.support.test.InstrumentationRegistry", "java.security.NoSuchAlgorithmException", "junit.framework.Assert", "org.junit.Assert" ]
import android.content.Context; import android.content.pm.PackageManager; import android.support.test.InstrumentationRegistry; import java.security.NoSuchAlgorithmException; import junit.framework.Assert; import org.junit.Assert;
import android.content.*; import android.content.pm.*; import android.support.test.*; import java.security.*; import junit.framework.*; import org.junit.*;
[ "android.content", "android.support", "java.security", "junit.framework", "org.junit" ]
android.content; android.support; java.security; junit.framework; org.junit;
2,820,840
return new HasId(equalTo(expectedId)); }
return new HasId(equalTo(expectedId)); }
/** * Provides a matcher that matches when {@code expectedId} is equal to the {@link * org.batfish.representation.aws.ElasticsearchDomain}'s id. */
Provides a matcher that matches when expectedId is equal to the <code>org.batfish.representation.aws.ElasticsearchDomain</code>'s id
hasId
{ "repo_name": "arifogel/batfish", "path": "projects/batfish/src/test/java/org/batfish/representation/aws/matchers/ElasticsearchDomainMatchers.java", "license": "apache-2.0", "size": 3757 }
[ "org.batfish.representation.aws.matchers.ElasticsearchDomainMatchersImpl" ]
import org.batfish.representation.aws.matchers.ElasticsearchDomainMatchersImpl;
import org.batfish.representation.aws.matchers.*;
[ "org.batfish.representation" ]
org.batfish.representation;
1,019,915
protected void addSourceTypePropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_EnrichMediator_sourceType_feature"), getString("_UI_PropertyDesc...
void function(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), EsbPackage.Literals.ENRICH_MEDIATOR__SOURCE_TYPE, true, false, false, ItemPropertyDescriptor.GENE...
/** * This adds a property descriptor for the Source Type feature. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated NOT */
This adds a property descriptor for the Source Type feature.
addSourceTypePropertyDescriptor
{ "repo_name": "sohaniwso2/devstudio-tooling-esb", "path": "plugins/org.wso2.developerstudio.eclipse.gmf.esb.edit/src/org/wso2/developerstudio/eclipse/gmf/esb/provider/EnrichMediatorItemProvider.java", "license": "apache-2.0", "size": 16091 }
[ "org.eclipse.emf.edit.provider.ComposeableAdapterFactory", "org.eclipse.emf.edit.provider.ItemPropertyDescriptor", "org.wso2.developerstudio.eclipse.gmf.esb.EsbPackage" ]
import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; import org.wso2.developerstudio.eclipse.gmf.esb.EsbPackage;
import org.eclipse.emf.edit.provider.*; import org.wso2.developerstudio.eclipse.gmf.esb.*;
[ "org.eclipse.emf", "org.wso2.developerstudio" ]
org.eclipse.emf; org.wso2.developerstudio;
261,092
@Override protected Tree determineNonTrivialHead(Tree t, Tree parent) { String motherCat = tlp.basicCategory(t.label().value()); if (DEBUG) { System.err.println("At " + motherCat + ", my parent is " + parent); } // Some conj expressions seem to make more sense with the "not" or // other ...
Tree function(Tree t, Tree parent) { String motherCat = tlp.basicCategory(t.label().value()); if (DEBUG) { System.err.println(STR + motherCat + STR + parent); } if (motherCat.equals("CONJP")) { for (TregexPattern pattern : headOfConjpTregex) { TregexMatcher matcher = pattern.matcher(t); if (matcher.matchesAt(t)) { retu...
/** * Determine which daughter of the current parse tree is the * head. It assumes that the daughters already have had their * heads determined. Uses special rule for VP heads * * @param t The parse tree to examine the daughters of. * This is assumed to never be a leaf * @return The pars...
Determine which daughter of the current parse tree is the head. It assumes that the daughters already have had their heads determined. Uses special rule for VP heads
determineNonTrivialHead
{ "repo_name": "codev777/CoreNLP", "path": "src/edu/stanford/nlp/trees/UniversalSemanticHeadFinder.java", "license": "gpl-2.0", "size": 30107 }
[ "edu.stanford.nlp.trees.tregex.TregexMatcher", "edu.stanford.nlp.trees.tregex.TregexPattern", "edu.stanford.nlp.util.ArrayUtils" ]
import edu.stanford.nlp.trees.tregex.TregexMatcher; import edu.stanford.nlp.trees.tregex.TregexPattern; import edu.stanford.nlp.util.ArrayUtils;
import edu.stanford.nlp.trees.tregex.*; import edu.stanford.nlp.util.*;
[ "edu.stanford.nlp" ]
edu.stanford.nlp;
2,495,820
public static final CmsSolrIndex getIndexSolr(CmsObject cms, Map<String, String[]> params) { String indexName = null; CmsSolrIndex index = null; // try to get the index name from the parameters: 'core' or 'index' if (params != null) { indexName = params.get(OpenCmsSolrHa...
static final CmsSolrIndex function(CmsObject cms, Map<String, String[]> params) { String indexName = null; CmsSolrIndex index = null; if (params != null) { indexName = params.get(OpenCmsSolrHandler.PARAM_CORE) != null ? params.get(OpenCmsSolrHandler.PARAM_CORE)[0] : (params.get(OpenCmsSolrHandler.PARAM_INDEX) != null ?...
/** * Returns the Solr index configured with the parameters name. * The parameters must contain a key/value pair with an existing * Solr index, otherwise <code>null</code> is returned.<p> * * @param cms the current context * @param params the parameter map * * @return the best ma...
Returns the Solr index configured with the parameters name. The parameters must contain a key/value pair with an existing Solr index, otherwise <code>null</code> is returned
getIndexSolr
{ "repo_name": "ggiudetti/opencms-core", "path": "src/org/opencms/search/CmsSearchManager.java", "license": "lgpl-2.1", "size": 124143 }
[ "java.util.List", "java.util.Map", "org.opencms.file.CmsObject", "org.opencms.main.OpenCms", "org.opencms.main.OpenCmsSolrHandler", "org.opencms.search.solr.CmsSolrIndex" ]
import java.util.List; import java.util.Map; import org.opencms.file.CmsObject; import org.opencms.main.OpenCms; import org.opencms.main.OpenCmsSolrHandler; import org.opencms.search.solr.CmsSolrIndex;
import java.util.*; import org.opencms.file.*; import org.opencms.main.*; import org.opencms.search.solr.*;
[ "java.util", "org.opencms.file", "org.opencms.main", "org.opencms.search" ]
java.util; org.opencms.file; org.opencms.main; org.opencms.search;
2,471,674
default void forEmbeddedRoot(JavaConstant root, ScanReason reason) { }
default void forEmbeddedRoot(JavaConstant root, ScanReason reason) { }
/** * Hook for scanned embedded root. */
Hook for scanned embedded root
forEmbeddedRoot
{ "repo_name": "smarr/Truffle", "path": "substratevm/src/com.oracle.graal.pointsto/src/com/oracle/graal/pointsto/ObjectScanningObserver.java", "license": "gpl-2.0", "size": 3715 }
[ "com.oracle.graal.pointsto.ObjectScanner" ]
import com.oracle.graal.pointsto.ObjectScanner;
import com.oracle.graal.pointsto.*;
[ "com.oracle.graal" ]
com.oracle.graal;
2,129,502
StreamConnection performUpgrade() throws IOException;
StreamConnection performUpgrade() throws IOException;
/** * Upgrade the connection, if the underlying protocol supports it. This should only be called after an upgrade request * has been submitted and the target server has accepted the upgrade. * * @return The resulting StreamConnection */
Upgrade the connection, if the underlying protocol supports it. This should only be called after an upgrade request has been submitted and the target server has accepted the upgrade
performUpgrade
{ "repo_name": "grassjedi/undertow", "path": "core/src/main/java/io/undertow/client/ClientConnection.java", "license": "apache-2.0", "size": 3834 }
[ "java.io.IOException", "org.xnio.StreamConnection" ]
import java.io.IOException; import org.xnio.StreamConnection;
import java.io.*; import org.xnio.*;
[ "java.io", "org.xnio" ]
java.io; org.xnio;
1,185,477
public @Nonnull String build(@Nonnull CloudProvider provider) throws CloudException, InternalException { NetworkServices services = provider.getNetworkServices(); if( services == null ) { throw new OperationNotSupportedException(provider.getCloudName() + " does not support network servi...
@Nonnull String function(@Nonnull CloudProvider provider) throws CloudException, InternalException { NetworkServices services = provider.getNetworkServices(); if( services == null ) { throw new OperationNotSupportedException(provider.getCloudName() + STR); } else { VLANSupport support = services.getVlanSupport(); if( s...
/** * Provisions a firewall in the specified cloud based on the options described in this object. * @param provider the cloud provider in which the firewall will be created * @return the unique ID of the vlan that is provisioned * @throws org.dasein.cloud.CloudException an error occurred with the cl...
Provisions a firewall in the specified cloud based on the options described in this object
build
{ "repo_name": "OSS-TheWeatherCompany/dasein-cloud-core", "path": "src/main/java/org/dasein/cloud/network/VlanCreateOptions.java", "license": "apache-2.0", "size": 4810 }
[ "javax.annotation.Nonnull", "org.dasein.cloud.CloudException", "org.dasein.cloud.CloudProvider", "org.dasein.cloud.InternalException", "org.dasein.cloud.OperationNotSupportedException" ]
import javax.annotation.Nonnull; import org.dasein.cloud.CloudException; import org.dasein.cloud.CloudProvider; import org.dasein.cloud.InternalException; import org.dasein.cloud.OperationNotSupportedException;
import javax.annotation.*; import org.dasein.cloud.*;
[ "javax.annotation", "org.dasein.cloud" ]
javax.annotation; org.dasein.cloud;
1,270,696
public void setSelectable(boolean selectable) { if (!SharedUtil.equals(this.selectable, selectable)) { this.selectable = selectable; markAsDirty(); } }
void function(boolean selectable) { if (!SharedUtil.equals(this.selectable, selectable)) { this.selectable = selectable; markAsDirty(); } }
/** * Setter for property selectable. * * <p> * The table is not selectable until it's explicitly set as selectable via * this method or alternatively at least one {@link ValueChangeListener} is * added. * </p> * * @param selectable * the New value of prope...
Setter for property selectable. The table is not selectable until it's explicitly set as selectable via this method or alternatively at least one <code>ValueChangeListener</code> is added.
setSelectable
{ "repo_name": "carrchang/vaadin", "path": "server/src/com/vaadin/ui/Table.java", "license": "apache-2.0", "size": 218051 }
[ "com.vaadin.shared.util.SharedUtil" ]
import com.vaadin.shared.util.SharedUtil;
import com.vaadin.shared.util.*;
[ "com.vaadin.shared" ]
com.vaadin.shared;
2,416,430
public static Entity createBullet(World entityWorld, float x, float y, float angleDeg, Entity shooter) { Entity e = entityWorld.createEntity(); e.setGroup("bullets"); Transform transform = new Transform(x, y, angleDeg); e.addComponent(transform); e.addComponent(new SpatialForm("bulle...
static Entity function(World entityWorld, float x, float y, float angleDeg, Entity shooter) { Entity e = entityWorld.createEntity(); e.setGroup(STR); Transform transform = new Transform(x, y, angleDeg); e.addComponent(transform); e.addComponent(new SpatialForm(STR)); e.addComponent(new Expiration(1500)); Body b = Physi...
/** * Bullets consist of the following components:<br> * - <strong>Transform</strong>:<br> * - <strong>SpatialForm</strong>:<br> * - <strong>Expiration</strong>:<br> * - <strong>Physics Body</strong>:<br> * * @param entityWorld * @param x * @param y * @param angleDeg * @para...
Bullets consist of the following components: - Transform: - SpatialForm: - Expiration: - Physics Body:
createBullet
{ "repo_name": "minthubk/tankz", "path": "tankz/src/com/tankz/EntityFactory.java", "license": "apache-2.0", "size": 9605 }
[ "com.artemis.Entity", "com.artemis.World", "com.artemis.utils.TrigLUT", "com.badlogic.gdx.math.MathUtils", "com.badlogic.gdx.math.Vector2", "com.badlogic.gdx.physics.box2d.Body", "com.badlogic.gdx.physics.box2d.Filter", "com.badlogic.gdx.physics.box2d.Fixture", "com.tankz.components.Expiration", "...
import com.artemis.Entity; import com.artemis.World; import com.artemis.utils.TrigLUT; import com.badlogic.gdx.math.MathUtils; import com.badlogic.gdx.math.Vector2; import com.badlogic.gdx.physics.box2d.Body; import com.badlogic.gdx.physics.box2d.Filter; import com.badlogic.gdx.physics.box2d.Fixture; import com.tankz.c...
import com.artemis.*; import com.artemis.utils.*; import com.badlogic.gdx.math.*; import com.badlogic.gdx.physics.box2d.*; import com.tankz.components.*; import com.tankz.systems.physics.*;
[ "com.artemis", "com.artemis.utils", "com.badlogic.gdx", "com.tankz.components", "com.tankz.systems" ]
com.artemis; com.artemis.utils; com.badlogic.gdx; com.tankz.components; com.tankz.systems;
1,320,784
@ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable<LoadBalancerInner> list(Context context) { return new PagedIterable<>(listAsync(context)); }
@ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable<LoadBalancerInner> function(Context context) { return new PagedIterable<>(listAsync(context)); }
/** * Gets all the load balancers in a subscription. * * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeExc...
Gets all the load balancers in a subscription
list
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-network/src/main/java/com/azure/resourcemanager/network/implementation/LoadBalancersClientImpl.java", "license": "mit", "size": 67687 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.PagedIterable", "com.azure.core.util.Context", "com.azure.resourcemanager.network.fluent.models.LoadBalancerInner" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.PagedIterable; import com.azure.core.util.Context; import com.azure.resourcemanager.network.fluent.models.LoadBalancerInner;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.network.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
2,782,626
LogicalCallableStatement newLogicalCallableStatement( CallableStatement cs, StatementKey stmtKey, StatementCacheInteractor cacheInteractor);
LogicalCallableStatement newLogicalCallableStatement( CallableStatement cs, StatementKey stmtKey, StatementCacheInteractor cacheInteractor);
/** * Returns a new logical callable statement object. * * @param cs underlying physical callable statement * @param stmtKey key for the underlying physical callable statement * @param cacheInteractor the statement cache interactor * @return A logical callable statement. */
Returns a new logical callable statement object
newLogicalCallableStatement
{ "repo_name": "trejkaz/derby", "path": "java/client/org/apache/derby/client/am/ClientJDBCObjectFactory.java", "license": "apache-2.0", "size": 14404 }
[ "java.sql.CallableStatement", "org.apache.derby.client.am.stmtcache.StatementKey" ]
import java.sql.CallableStatement; import org.apache.derby.client.am.stmtcache.StatementKey;
import java.sql.*; import org.apache.derby.client.am.stmtcache.*;
[ "java.sql", "org.apache.derby" ]
java.sql; org.apache.derby;
305,103
public void assignUUID(UUIDObject object) { object.setUUID(generateUUID(object.getUUIDPrefix())); }
void function(UUIDObject object) { object.setUUID(generateUUID(object.getUUIDPrefix())); }
/** * Assigns UUID to the object * * @param object */
Assigns UUID to the object
assignUUID
{ "repo_name": "kynerix/kynerix-backend", "path": "core/src/main/java/com/kynerix/server/UUIDManager.java", "license": "apache-2.0", "size": 906 }
[ "com.kynerix.shared.UUIDObject" ]
import com.kynerix.shared.UUIDObject;
import com.kynerix.shared.*;
[ "com.kynerix.shared" ]
com.kynerix.shared;
2,863,134
public Class<UIJob> getUIJobClass() { return UIJob.class; }
Class<UIJob> function() { return UIJob.class; }
/** * Important: keep for scripting */
Important: keep for scripting
getUIJobClass
{ "repo_name": "rgom/Pydev", "path": "plugins/org.python.pydev/src/org/python/pydev/editor/PyEdit.java", "license": "epl-1.0", "size": 67141 }
[ "org.eclipse.ui.progress.UIJob" ]
import org.eclipse.ui.progress.UIJob;
import org.eclipse.ui.progress.*;
[ "org.eclipse.ui" ]
org.eclipse.ui;
820,745
@ServiceMethod(returns = ReturnType.SINGLE) ConfigurationListResultInner listUpdateConfigurations( String resourceGroupName, String serverName, ConfigurationListResultInner value);
@ServiceMethod(returns = ReturnType.SINGLE) ConfigurationListResultInner listUpdateConfigurations( String resourceGroupName, String serverName, ConfigurationListResultInner value);
/** * Update a list of configurations in a given server. * * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param serverName The name of the server. * @param value The parameters for updating a list of server configuration. * @throws IllegalArgume...
Update a list of configurations in a given server
listUpdateConfigurations
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/mariadb/azure-resourcemanager-mariadb/src/main/java/com/azure/resourcemanager/mariadb/fluent/ServerParametersClient.java", "license": "mit", "size": 4360 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.resourcemanager.mariadb.fluent.models.ConfigurationListResultInner" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.resourcemanager.mariadb.fluent.models.ConfigurationListResultInner;
import com.azure.core.annotation.*; import com.azure.resourcemanager.mariadb.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
61,680
public static void compact(DatasetGraph container, boolean shouldDeleteOld) { DatasetGraphSwitchable dsg = requireSwitchable(container); DatabaseOps.compact(dsg, shouldDeleteOld); }
static void function(DatasetGraph container, boolean shouldDeleteOld) { DatasetGraphSwitchable dsg = requireSwitchable(container); DatabaseOps.compact(dsg, shouldDeleteOld); }
/** * Compact a datasets which must be a switchable TDB database. * This is the normal dataset type for on-disk TDB2 databases. * * Deletes old database after successful compaction if `shouldDeleteOld` is `true`. * * @param container * @param shouldDeleteOld */
Compact a datasets which must be a switchable TDB database. This is the normal dataset type for on-disk TDB2 databases. Deletes old database after successful compaction if `shouldDeleteOld` is `true`
compact
{ "repo_name": "apache/jena", "path": "jena-db/jena-tdb2/src/main/java/org/apache/jena/tdb2/DatabaseMgr.java", "license": "apache-2.0", "size": 4919 }
[ "org.apache.jena.sparql.core.DatasetGraph", "org.apache.jena.tdb2.store.DatasetGraphSwitchable", "org.apache.jena.tdb2.sys.DatabaseOps" ]
import org.apache.jena.sparql.core.DatasetGraph; import org.apache.jena.tdb2.store.DatasetGraphSwitchable; import org.apache.jena.tdb2.sys.DatabaseOps;
import org.apache.jena.sparql.core.*; import org.apache.jena.tdb2.store.*; import org.apache.jena.tdb2.sys.*;
[ "org.apache.jena" ]
org.apache.jena;
1,289,425
protected boolean checkNewEntry(String goalWord, String searchWord, ITermSimilarity algorithm) { DictEntry testEntry = new DictEntry(goalWord, searchWord, algorithm); return dictionary.containsEntry(testEntry); }
boolean function(String goalWord, String searchWord, ITermSimilarity algorithm) { DictEntry testEntry = new DictEntry(goalWord, searchWord, algorithm); return dictionary.containsEntry(testEntry); }
/** * Return true if an entry with these components already exists * (Don't allow an entry to be modified into a duplicate of another existing * entry.) */
Return true if an entry with these components already exists (Don't allow an entry to be modified into a duplicate of another existing entry.)
checkNewEntry
{ "repo_name": "cogtool/cogtool", "path": "java/edu/cmu/cs/hcii/cogtool/controller/DictionaryEditorController.java", "license": "lgpl-2.1", "size": 35899 }
[ "edu.cmu.cs.hcii.cogtool.model.ISimilarityDictionary", "edu.cmu.cs.hcii.cogtool.model.ITermSimilarity" ]
import edu.cmu.cs.hcii.cogtool.model.ISimilarityDictionary; import edu.cmu.cs.hcii.cogtool.model.ITermSimilarity;
import edu.cmu.cs.hcii.cogtool.model.*;
[ "edu.cmu.cs" ]
edu.cmu.cs;
967,206
@Test public void whenSentEmptyListThenGetEmptyHashMap() { HashMap<Integer, User> expected = new HashMap<>(); List<User> list = new ArrayList<>(); HashMap<Integer, User> result = new UserConvert().process(list); assertThat(result, is(expected)); }
void function() { HashMap<Integer, User> expected = new HashMap<>(); List<User> list = new ArrayList<>(); HashMap<Integer, User> result = new UserConvert().process(list); assertThat(result, is(expected)); }
/** * Test process. */
Test process
whenSentEmptyListThenGetEmptyHashMap
{ "repo_name": "AlekseySidorenko/aleksey_sidorenko", "path": "chapter_003/src/test/java/ru/job4j/collections/UserConvertTest.java", "license": "apache-2.0", "size": 1120 }
[ "java.util.ArrayList", "java.util.HashMap", "java.util.List", "org.hamcrest.core.Is", "org.junit.Assert" ]
import java.util.ArrayList; import java.util.HashMap; import java.util.List; import org.hamcrest.core.Is; import org.junit.Assert;
import java.util.*; import org.hamcrest.core.*; import org.junit.*;
[ "java.util", "org.hamcrest.core", "org.junit" ]
java.util; org.hamcrest.core; org.junit;
393,737
private Intent getIntentToEnableOsPerAppPermission(Context context) { if (enabledForChrome(context)) return null; return getAppInfoIntent(context); }
Intent function(Context context) { if (enabledForChrome(context)) return null; return getAppInfoIntent(context); }
/** * Returns the OS Intent to use to enable a per-app permission, or null if the permission is * already enabled. Android M and above provides two ways of doing this for some permissions, * most notably Location, one that is per-app and another that is global. */
Returns the OS Intent to use to enable a per-app permission, or null if the permission is already enabled. Android M and above provides two ways of doing this for some permissions, most notably Location, one that is per-app and another that is global
getIntentToEnableOsPerAppPermission
{ "repo_name": "Pluto-tv/chromium-crosswalk", "path": "chrome/android/java/src/org/chromium/chrome/browser/preferences/website/SiteSettingsCategory.java", "license": "bsd-3-clause", "size": 18315 }
[ "android.content.Context", "android.content.Intent" ]
import android.content.Context; import android.content.Intent;
import android.content.*;
[ "android.content" ]
android.content;
2,438,346
private static boolean createDirIfNotExist(String path) { File f = new File(path); if (!f.exists()) { if (!f.mkdirs()) { Log.e(LOG_GPAC_CONFIG, "Failed to create directory " + path); //$NON-NLS-1$ return false; } else { Log.i(LO...
static boolean function(String path) { File f = new File(path); if (!f.exists()) { if (!f.mkdirs()) { Log.e(LOG_GPAC_CONFIG, STR + path); return false; } else { Log.i(LOG_GPAC_CONFIG, STR + path); } } return true; }
/** * Creates a given directory if it does not exist * * @param path */
Creates a given directory if it does not exist
createDirIfNotExist
{ "repo_name": "wipple/GPAC-old", "path": "applications/osmo4_android/src/com/gpac/Osmo4/GpacConfig.java", "license": "lgpl-2.1", "size": 5578 }
[ "android.util.Log", "java.io.File" ]
import android.util.Log; import java.io.File;
import android.util.*; import java.io.*;
[ "android.util", "java.io" ]
android.util; java.io;
942,462
public void addValueClassification( ValueClassification valueClassification) { if (valueClassification == null) { throw new IllegalArgumentException( "valueClassification cannot be null"); } if (!classificationMatrix.containsKey(valueClassification...
void function( ValueClassification valueClassification) { if (valueClassification == null) { throw new IllegalArgumentException( STR); } if (!classificationMatrix.containsKey(valueClassification.value)) { classificationMatrix.put(valueClassification.value, new ArrayList<>()); } lowLevelIds.add(valueClassification.lladI...
/** * Adds a value classification for the abstraction. If a classification of * the provided name doesn't exist, then it is created. The value definition * name must be one of the values applicable to the low-level abstraction * whose ID is also passed in. * * @param id the name of the val...
Adds a value classification for the abstraction. If a classification of the provided name doesn't exist, then it is created. The value definition name must be one of the values applicable to the low-level abstraction whose ID is also passed in
addValueClassification
{ "repo_name": "eurekaclinical/protempa", "path": "protempa-framework/src/main/java/org/protempa/CompoundLowLevelAbstractionDefinition.java", "license": "apache-2.0", "size": 13181 }
[ "java.util.ArrayList", "org.protempa.proposition.value.NominalValue" ]
import java.util.ArrayList; import org.protempa.proposition.value.NominalValue;
import java.util.*; import org.protempa.proposition.value.*;
[ "java.util", "org.protempa.proposition" ]
java.util; org.protempa.proposition;
411,084
public Range getSecondaryRangeForRow(int row) { if(row < 0 || row > getRowCount()) return null; return new Range(scores.get(row).range.getStart(), scores.get(row).range.getEnd()); }
Range function(int row) { if(row < 0 row > getRowCount()) return null; return new Range(scores.get(row).range.getStart(), scores.get(row).range.getEnd()); }
/** * Returns the redated (secondary) sample range for the specific row * * @param row * @return */
Returns the redated (secondary) sample range for the specific row
getSecondaryRangeForRow
{ "repo_name": "petebrew/tellervo", "path": "src/main/java/org/tellervo/desktop/cross/SigScoresTableModel.java", "license": "gpl-3.0", "size": 12721 }
[ "org.tellervo.desktop.Range" ]
import org.tellervo.desktop.Range;
import org.tellervo.desktop.*;
[ "org.tellervo.desktop" ]
org.tellervo.desktop;
1,150,369
@SuppressWarnings("null") // headerValue cannot be null private boolean parseHeader() throws IOException { // // Check for blank line // byte chr = 0; while (true) { // Read new bytes if needed if (pos >= lastValid) { if ...
@SuppressWarnings("null") boolean function() throws IOException { byte chr = 0; while (true) { if (pos >= lastValid) { if (!fill()) throw new EOFException(sm.getString(STR)); } chr = buf[pos]; if (chr == Constants.CR) { } else if (chr == Constants.LF) { pos++; return false; } else { break; } pos++; } int start = pos; b...
/** * Parse an HTTP header. * * @return false after reading a blank line (which indicates that the * HTTP header parsing is done */
Parse an HTTP header
parseHeader
{ "repo_name": "GazeboHub/ghub-portal-doc", "path": "doc/modelio/GHub Portal/mda/JavaDesigner/res/java/tomcat/java/org/apache/coyote/http11/InternalInputBuffer.java", "license": "epl-1.0", "size": 15609 }
[ "java.io.EOFException", "java.io.IOException", "org.apache.tomcat.util.buf.MessageBytes" ]
import java.io.EOFException; import java.io.IOException; import org.apache.tomcat.util.buf.MessageBytes;
import java.io.*; import org.apache.tomcat.util.buf.*;
[ "java.io", "org.apache.tomcat" ]
java.io; org.apache.tomcat;
1,959,166
Date from = date; Date to = date; Calendar calendar = Calendar.getInstance(); calendar.setTime(date); if (SerieDto.RANGE.equals(period)) { from = date; to = date; } else if (SerieDto.DAY.equals(period)) { from = date; to = date; } else if (SerieDto.WEEK.equals(period)) { calendar.set(Cale...
Date from = date; Date to = date; Calendar calendar = Calendar.getInstance(); calendar.setTime(date); if (SerieDto.RANGE.equals(period)) { from = date; to = date; } else if (SerieDto.DAY.equals(period)) { from = date; to = date; } else if (SerieDto.WEEK.equals(period)) { calendar.set(Calendar.DAY_OF_WEEK, 1); from = ca...
/** * Returns a serie. Don't use the value "range" for the parameter "period", * call findByPeriod(Date, Date) instead. * * @param period * @param date * @return SerieDto */
Returns a serie. Don't use the value "range" for the parameter "period", call findByPeriod(Date, Date) instead
findByPeriod
{ "repo_name": "Emergya/opensir", "path": "sir-admin/sir-admin-extensions/sir-admin-app-stats/src/main/java/com/emergya/ohiggins/stats/dao/impl/RequestedLayersGeoServerImpl.java", "license": "lgpl-2.1", "size": 5038 }
[ "com.emergya.ohiggins.stats.dto.SerieDto", "java.util.Calendar", "java.util.Date" ]
import com.emergya.ohiggins.stats.dto.SerieDto; import java.util.Calendar; import java.util.Date;
import com.emergya.ohiggins.stats.dto.*; import java.util.*;
[ "com.emergya.ohiggins", "java.util" ]
com.emergya.ohiggins; java.util;
859,278
public void parent(PreparedDocument rdoc, OutputStream os, ObjectPidsPath path, FontMap fontMap);
void function(PreparedDocument rdoc, OutputStream os, ObjectPidsPath path, FontMap fontMap);
/** * Generate first pdf page for title * @param rdoc Generating document model * @param os Outputstream * @param path Path for generting object * @param imgServlet IMG servlet * @param i18nServlet I18N servlet * @param fontMap Prepared FontMap object */
Generate first pdf page for title
parent
{ "repo_name": "ceskaexpedice/kramerius", "path": "shared/common/src/main/java/cz/incad/kramerius/pdf/FirstPagePDFService.java", "license": "gpl-3.0", "size": 1973 }
[ "cz.incad.kramerius.ObjectPidsPath", "cz.incad.kramerius.document.model.PreparedDocument", "cz.incad.kramerius.pdf.utils.pdf.FontMap", "java.io.OutputStream" ]
import cz.incad.kramerius.ObjectPidsPath; import cz.incad.kramerius.document.model.PreparedDocument; import cz.incad.kramerius.pdf.utils.pdf.FontMap; import java.io.OutputStream;
import cz.incad.kramerius.*; import cz.incad.kramerius.document.model.*; import cz.incad.kramerius.pdf.utils.pdf.*; import java.io.*;
[ "cz.incad.kramerius", "java.io" ]
cz.incad.kramerius; java.io;
495,113
protected List<String> getNonPrimaryKeyColumns(String tableName) { List<String> columns = getAllColumns(tableName); columns.removeAll(getPrimaryKeys(tableName)); return columns; }
List<String> function(String tableName) { List<String> columns = getAllColumns(tableName); columns.removeAll(getPrimaryKeys(tableName)); return columns; }
/** Returns all non-primary-key column names for the specified table, in the * order defined in the DDL. */
Returns all non-primary-key column names for the specified table, in the
getNonPrimaryKeyColumns
{ "repo_name": "paulmartel/voltdb", "path": "src/frontend/org/voltdb/NonVoltDBBackend.java", "license": "agpl-3.0", "size": 40578 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
885,819
@SuppressWarnings("deprecation") void registerMBean() { MXBeanImpl mxBeanInfo = MXBeanImpl.init(this); mxBean = MBeanUtil.registerMBean("RegionServer", "RegionServer", mxBeanInfo); LOG.info("Registered RegionServer MXBean"); }
@SuppressWarnings(STR) void registerMBean() { MXBeanImpl mxBeanInfo = MXBeanImpl.init(this); mxBean = MBeanUtil.registerMBean(STR, STR, mxBeanInfo); LOG.info(STR); }
/** * Register bean with platform management server */
Register bean with platform management server
registerMBean
{ "repo_name": "indi60/hbase-pmc", "path": "target/hbase-0.94.1/hbase-0.94.1/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java", "license": "apache-2.0", "size": 131335 }
[ "org.apache.hadoop.metrics.util.MBeanUtil" ]
import org.apache.hadoop.metrics.util.MBeanUtil;
import org.apache.hadoop.metrics.util.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
2,388,944
public void setRawObject(@Nonnull final ISerializer serializer, @Nonnull final JsonObject json) { }
void function(@Nonnull final ISerializer serializer, @Nonnull final JsonObject json) { }
/** * Sets the raw JSON object * * @param serializer the serializer * @param json the JSON object to set this object to */
Sets the raw JSON object
setRawObject
{ "repo_name": "microsoftgraph/msgraph-sdk-java", "path": "src/main/java/com/microsoft/graph/models/MessageRulePredicates.java", "license": "mit", "size": 11809 }
[ "com.google.gson.JsonObject", "com.microsoft.graph.serializer.ISerializer", "javax.annotation.Nonnull" ]
import com.google.gson.JsonObject; import com.microsoft.graph.serializer.ISerializer; import javax.annotation.Nonnull;
import com.google.gson.*; import com.microsoft.graph.serializer.*; import javax.annotation.*;
[ "com.google.gson", "com.microsoft.graph", "javax.annotation" ]
com.google.gson; com.microsoft.graph; javax.annotation;
2,162,349
public void begin() throws BeginTransactionException;
void function() throws BeginTransactionException;
/** * Begin a dummy transaction. */
Begin a dummy transaction
begin
{ "repo_name": "Kelvinli1988/mysqlmv", "path": "src/main/java/org/mysqlmv/mvm/sql/transaction/ITransaction.java", "license": "lgpl-3.0", "size": 926 }
[ "org.mysqlmv.mvm.sql.transaction.exception.BeginTransactionException" ]
import org.mysqlmv.mvm.sql.transaction.exception.BeginTransactionException;
import org.mysqlmv.mvm.sql.transaction.exception.*;
[ "org.mysqlmv.mvm" ]
org.mysqlmv.mvm;
2,386,069
public static HRegion createRegionAndWAL(final RegionInfo info, final Path rootDir, final Configuration conf, final TableDescriptor htd, BlockCache blockCache) throws IOException { HRegion region = createRegionAndWAL(info, rootDir, conf, htd, false); region.setBlockCache(blockCache); region.in...
static HRegion function(final RegionInfo info, final Path rootDir, final Configuration conf, final TableDescriptor htd, BlockCache blockCache) throws IOException { HRegion region = createRegionAndWAL(info, rootDir, conf, htd, false); region.setBlockCache(blockCache); region.initialize(); return region; }
/** * Create a region with it's own WAL. Be sure to call * {@link HBaseTestingUtility#closeRegionAndWAL(HRegion)} to clean up all resources. */
Create a region with it's own WAL. Be sure to call <code>HBaseTestingUtility#closeRegionAndWAL(HRegion)</code> to clean up all resources
createRegionAndWAL
{ "repo_name": "apurtell/hbase", "path": "hbase-testing-util/src/main/java/org/apache/hadoop/hbase/HBaseTestingUtility.java", "license": "apache-2.0", "size": 169342 }
[ "java.io.IOException", "org.apache.hadoop.conf.Configuration", "org.apache.hadoop.fs.Path", "org.apache.hadoop.hbase.client.RegionInfo", "org.apache.hadoop.hbase.client.TableDescriptor", "org.apache.hadoop.hbase.io.hfile.BlockCache", "org.apache.hadoop.hbase.regionserver.HRegion" ]
import java.io.IOException; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hbase.client.RegionInfo; import org.apache.hadoop.hbase.client.TableDescriptor; import org.apache.hadoop.hbase.io.hfile.BlockCache; import org.apache.hadoop.hbase.regionserver.HRegion;
import java.io.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.io.hfile.*; import org.apache.hadoop.hbase.regionserver.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
2,074,884
@Override public ServiceBusConnectionDetailsResponse getConnectionDetails(String namespaceName, String notificationHubName) throws IOException, ServiceException, ParserConfigurationException, SAXException { // Validate if (namespaceName == null) { throw new NullPointerException("name...
ServiceBusConnectionDetailsResponse function(String namespaceName, String notificationHubName) throws IOException, ServiceException, ParserConfigurationException, SAXException { if (namespaceName == null) { throw new NullPointerException(STR); } if (notificationHubName == null) { throw new NullPointerException(STR); } ...
/** * Lists the notification hubs associated with a namespace. * * @param namespaceName Required. The namespace name. * @param notificationHubName Required. The notification hub name. * @throws IOException Signals that an I/O exception of some sort has * occurred. This class is the general class...
Lists the notification hubs associated with a namespace
getConnectionDetails
{ "repo_name": "southworkscom/azure-sdk-for-java", "path": "service-management/azure-svc-mgmt-servicebus/src/main/java/com/microsoft/windowsazure/management/servicebus/NotificationHubOperationsImpl.java", "license": "apache-2.0", "size": 48376 }
[ "com.microsoft.windowsazure.core.utils.XmlUtility", "com.microsoft.windowsazure.exception.ServiceException", "com.microsoft.windowsazure.management.servicebus.models.AccessRight", "com.microsoft.windowsazure.management.servicebus.models.ServiceBusConnectionDetail", "com.microsoft.windowsazure.management.ser...
import com.microsoft.windowsazure.core.utils.XmlUtility; import com.microsoft.windowsazure.exception.ServiceException; import com.microsoft.windowsazure.management.servicebus.models.AccessRight; import com.microsoft.windowsazure.management.servicebus.models.ServiceBusConnectionDetail; import com.microsoft.windowsazure....
import com.microsoft.windowsazure.core.utils.*; import com.microsoft.windowsazure.exception.*; import com.microsoft.windowsazure.management.servicebus.models.*; import com.microsoft.windowsazure.tracing.*; import java.io.*; import java.util.*; import javax.xml.parsers.*; import org.w3c.dom.*; import org.xml.sax.*;
[ "com.microsoft.windowsazure", "java.io", "java.util", "javax.xml", "org.w3c.dom", "org.xml.sax" ]
com.microsoft.windowsazure; java.io; java.util; javax.xml; org.w3c.dom; org.xml.sax;
626,982
public void migrateInterfaceChanges(final Ooaofooa modelRoot, Component_c component, CD_CID cid) { // ensure that all interfaces have been // loaded if (modelRoot.getRoot() == null) { SystemModel_c system = SystemModel_c.SystemModelInstance(Ooaofooa .getDe...
void function(final Ooaofooa modelRoot, Component_c component, CD_CID cid) { if (modelRoot.getRoot() == null) { SystemModel_c system = SystemModel_c.SystemModelInstance(Ooaofooa .getDefaultInstance(), new ClassQueryInterface_c() {
/** * This function is used to migrate 1.4.2-based provisions and * requirements to 1.5.x provisions and requirements with ports * and interface references. * @param cid */
This function is used to migrate 1.4.2-based provisions and requirements to 1.5.x provisions and requirements with ports and interface references
migrateInterfaceChanges
{ "repo_name": "perojonsson/bridgepoint", "path": "src/org.xtuml.bp.io.core/src/org/xtuml/bp/io/core/ImportHelper.java", "license": "apache-2.0", "size": 111259 }
[ "org.xtuml.bp.core.Ooaofooa" ]
import org.xtuml.bp.core.Ooaofooa;
import org.xtuml.bp.core.*;
[ "org.xtuml.bp" ]
org.xtuml.bp;
228,638
@Override public void injectEvents(HandlerManager eventBus) { // TODO Auto-generated method stub }
void function(HandlerManager eventBus) { }
/** * To handle events. * * @param eventBus HandlerManager */
To handle events
injectEvents
{ "repo_name": "kuzavas/ephesoft", "path": "dcma-gwt/dcma-gwt-admin/src/main/java/com/ephesoft/dcma/gwt/admin/bm/client/presenter/tableinfo/TableInfoListPresenter.java", "license": "agpl-3.0", "size": 4418 }
[ "com.google.gwt.event.shared.HandlerManager" ]
import com.google.gwt.event.shared.HandlerManager;
import com.google.gwt.event.shared.*;
[ "com.google.gwt" ]
com.google.gwt;
1,722,270
public boolean onBlockActivated(World p_149727_1_, int p_149727_2_, int p_149727_3_, int p_149727_4_, EntityPlayer p_149727_5_, int p_149727_6_, float p_149727_7_, float p_149727_8_, float p_149727_9_) { if (p_149727_5_.getCurrentEquippedItem() != null && p_149727_5_.getCurrentEquippedItem().getItem() =...
boolean function(World p_149727_1_, int p_149727_2_, int p_149727_3_, int p_149727_4_, EntityPlayer p_149727_5_, int p_149727_6_, float p_149727_7_, float p_149727_8_, float p_149727_9_) { if (p_149727_5_.getCurrentEquippedItem() != null && p_149727_5_.getCurrentEquippedItem().getItem() == Items.flint_and_steel) { this...
/** * Called upon block activation (right click on the block.) */
Called upon block activation (right click on the block.)
onBlockActivated
{ "repo_name": "CheeseL0ver/Ore-TTM", "path": "build/tmp/recompSrc/net/minecraft/block/BlockTNT.java", "license": "lgpl-2.1", "size": 6592 }
[ "net.minecraft.entity.player.EntityPlayer", "net.minecraft.init.Items", "net.minecraft.world.World" ]
import net.minecraft.entity.player.EntityPlayer; import net.minecraft.init.Items; import net.minecraft.world.World;
import net.minecraft.entity.player.*; import net.minecraft.init.*; import net.minecraft.world.*;
[ "net.minecraft.entity", "net.minecraft.init", "net.minecraft.world" ]
net.minecraft.entity; net.minecraft.init; net.minecraft.world;
478,407
@Test public void testByte2Byte() { try { Message message = senderSession.createMessage(); message.setByteProperty("prop", (byte) 127); Assert.assertEquals((byte) 127, message.getByteProperty("prop")); } catch (JMSException e) { fail(e); } }
void function() { try { Message message = senderSession.createMessage(); message.setByteProperty("prop", (byte) 127); Assert.assertEquals((byte) 127, message.getByteProperty("prop")); } catch (JMSException e) { fail(e); } }
/** * if a property is set as a <code>byte</code>, * it can also be read as a <code>byte</code>. */
if a property is set as a <code>byte</code>, it can also be read as a <code>byte</code>
testByte2Byte
{ "repo_name": "cshannon/activemq-artemis", "path": "tests/joram-tests/src/test/java/org/objectweb/jtests/jms/conform/message/properties/MessagePropertyConversionTest.java", "license": "apache-2.0", "size": 43771 }
[ "javax.jms.JMSException", "javax.jms.Message", "org.junit.Assert" ]
import javax.jms.JMSException; import javax.jms.Message; import org.junit.Assert;
import javax.jms.*; import org.junit.*;
[ "javax.jms", "org.junit" ]
javax.jms; org.junit;
11,464
ContainerViewVariable getContainerView();
ContainerViewVariable getContainerView();
/** * Returns the value of the '<em><b>Container View</b></em>' containment * reference. <!-- begin-user-doc --> <!-- end-user-doc --> <!-- * begin-model-doc --> The view that contains the ViewPointElement to * delete. <!-- end-model-doc --> * * @return the value of the '<em>Container View...
Returns the value of the 'Container View' containment reference. The view that contains the ViewPointElement to delete.
getContainerView
{ "repo_name": "FTSRG/iq-sirius-integration", "path": "host/org.eclipse.sirius.diagram/src-gen/org/eclipse/sirius/diagram/description/tool/DeleteElementDescription.java", "license": "epl-1.0", "size": 7879 }
[ "org.eclipse.sirius.viewpoint.description.tool.ContainerViewVariable" ]
import org.eclipse.sirius.viewpoint.description.tool.ContainerViewVariable;
import org.eclipse.sirius.viewpoint.description.tool.*;
[ "org.eclipse.sirius" ]
org.eclipse.sirius;
2,432,177
public MetricName metricName(String name, String group, String description) { return metricName(name, group, description, new HashMap<String, String>()); }
MetricName function(String name, String group, String description) { return metricName(name, group, description, new HashMap<String, String>()); }
/** * Create a MetricName with the given name, group, description, and default tags * specified in the metric configuration. * * @param name The name of the metric * @param group logical group name of the metrics to which this metric belongs * @param description A human-readab...
Create a MetricName with the given name, group, description, and default tags specified in the metric configuration
metricName
{ "repo_name": "lemonJun/Jkafka", "path": "jkafka-core/src/main/java/kafka/metrics/Metrics.java", "license": "apache-2.0", "size": 18614 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
2,501,980
public void setFooterProgressDrawable(Drawable indeterminateDrawable) { mFooterProgress.setIndeterminateDrawable(indeterminateDrawable); }
void function(Drawable indeterminateDrawable) { mFooterProgress.setIndeterminateDrawable(indeterminateDrawable); }
/** * * Set custom drawable to the footer view progress. * @return * @throws */
Set custom drawable to the footer view progress
setFooterProgressDrawable
{ "repo_name": "yinglovezhuzhu/PullView_eclipse", "path": "PullView/src/com/opensource/pullview/PullFooterView2.java", "license": "apache-2.0", "size": 6460 }
[ "android.graphics.drawable.Drawable" ]
import android.graphics.drawable.Drawable;
import android.graphics.drawable.*;
[ "android.graphics" ]
android.graphics;
2,176,211
EClass getProgramStatus();
EClass getProgramStatus();
/** * Returns the meta object for class '{@link org.smeup.sys.os.pgm.QProgramStatus <em>Program Status</em>}'. * <!-- begin-user-doc --> <!-- end-user-doc --> * @return the meta object for class '<em>Program Status</em>'. * @see org.smeup.sys.os.pgm.QProgramStatus * @generated */
Returns the meta object for class '<code>org.smeup.sys.os.pgm.QProgramStatus Program Status</code>'.
getProgramStatus
{ "repo_name": "smeup/asup", "path": "org.smeup.sys.os.pgm/src/org/smeup/sys/os/pgm/QOperatingSystemProgramPackage.java", "license": "epl-1.0", "size": 33128 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,374,159
public void setPrintObjectAttrs(NPCPID idCodePoint, NPCPAttribute cpAttrs, int type) { cpID_ = idCodePoint; attrs = cpAttrs; objectType_ = type; try { ...
void function(NPCPID idCodePoint, NPCPAttribute cpAttrs, int type) { cpID_ = idCodePoint; attrs = cpAttrs; objectType_ = type; try { cpID_.setConverter(ConverterImplRemote.getConverter(system_.getCcsid(), system_)); if (attrs != null) attrs.setConverter(ConverterImplRemote.getConverter(system_.getCcsid(), system_)); } ...
/** * Sets the print object attributes. * This method is required so changes in the public class * are propogated to this remote implementation of the class. * * @param idCodePoint The ID code point * @param cpAttrs The code point attributes * @param type The type. ...
Sets the print object attributes. This method is required so changes in the public class are propogated to this remote implementation of the class
setPrintObjectAttrs
{ "repo_name": "devjunix/libjt400-java", "path": "src/com/ibm/as400/access/PrintObjectImplRemote.java", "license": "epl-1.0", "size": 28406 }
[ "java.io.UnsupportedEncodingException" ]
import java.io.UnsupportedEncodingException;
import java.io.*;
[ "java.io" ]
java.io;
2,560,564
public Void visitClass(ClassTree ct, Void _) { TypeElement e = (TypeElement) TreeUtil.getElement(ct); if(e!=null) { // put the marker on the class name portion. Token token=null; if(ct.getModifiers()!=null) ...
Void function(ClassTree ct, Void _) { TypeElement e = (TypeElement) TreeUtil.getElement(ct); if(e!=null) { Token token=null; if(ct.getModifiers()!=null) token = gen.findTokenAfter(ct.getModifiers(), true, ct.getSimpleName().toString()); if(token==null) token = gen.findTokenAfter(ct, false, ct.getSimpleName().toString()...
/** * Class declaration. */
Class declaration
visitClass
{ "repo_name": "kohsuke/sorcerer", "path": "core/src/main/java/org/jvnet/sorcerer/ParsedSourceSet.java", "license": "mit", "size": 25942 }
[ "com.sun.source.tree.ClassTree", "java.util.List", "javax.lang.model.element.NestingKind", "javax.lang.model.element.TypeElement", "org.jvnet.sorcerer.Tag", "org.jvnet.sorcerer.util.TreeUtil" ]
import com.sun.source.tree.ClassTree; import java.util.List; import javax.lang.model.element.NestingKind; import javax.lang.model.element.TypeElement; import org.jvnet.sorcerer.Tag; import org.jvnet.sorcerer.util.TreeUtil;
import com.sun.source.tree.*; import java.util.*; import javax.lang.model.element.*; import org.jvnet.sorcerer.*; import org.jvnet.sorcerer.util.*;
[ "com.sun.source", "java.util", "javax.lang", "org.jvnet.sorcerer" ]
com.sun.source; java.util; javax.lang; org.jvnet.sorcerer;
441,152
public static synchronized void end(String name, MemoryInfo memoryInfo) { final long eventId = name.hashCode(); TraceEvent.finishAsync(name, eventId); if (sEnabled && matchesFilter(name)) { if (sTrackTiming) { savePerfString(name, eventId, EventType.FINISH, false)...
static synchronized void function(String name, MemoryInfo memoryInfo) { final long eventId = name.hashCode(); TraceEvent.finishAsync(name, eventId); if (sEnabled && matchesFilter(name)) { if (sTrackTiming) { savePerfString(name, eventId, EventType.FINISH, false); } long timestampUs = (System.nanoTime() - sBeginNanoTime...
/** * Record an "end" memory trace event, to match a begin event. The * memory usage delta between begin and end is usually interesting to * graph code. */
Record an "end" memory trace event, to match a begin event. The memory usage delta between begin and end is usually interesting to graph code
end
{ "repo_name": "yuzaipiaofei/chromium_webview", "path": "java/src/org/chromium/base/PerfTraceEvent.java", "license": "bsd-3-clause", "size": 13470 }
[ "android.os.Debug" ]
import android.os.Debug;
import android.os.*;
[ "android.os" ]
android.os;
25,439
protected void processRevealEffect() { if ((mDrawMode != DecoEvent.EventType.EVENT_HIDE) && (mDrawMode != DecoEvent.EventType.EVENT_SHOW)) { if (mSeriesItem.getLineWidth() != mPaint.getStrokeWidth()) { mPaint.setStrokeWidth(mSeriesItem.getLineWidth()); ...
void function() { if ((mDrawMode != DecoEvent.EventType.EVENT_HIDE) && (mDrawMode != DecoEvent.EventType.EVENT_SHOW)) { if (mSeriesItem.getLineWidth() != mPaint.getStrokeWidth()) { mPaint.setStrokeWidth(mSeriesItem.getLineWidth()); } return; } float lineWidth = mSeriesItem.getLineWidth(); if (mPercentComplete > 0) { li...
/** * Adjust the line width used when the hide animation is taking place. This will reduce the * line width from the original width to nothing over time. At the same this the alpha of the * line will be reduced to nothing */
Adjust the line width used when the hide animation is taking place. This will reduce the line width from the original width to nothing over time. At the same this the alpha of the line will be reduced to nothing
processRevealEffect
{ "repo_name": "bmarrdev/android-DecoView-charting", "path": "decoviewlib/src/main/java/com/hookedonplay/decoviewlib/charts/ChartSeries.java", "license": "apache-2.0", "size": 25410 }
[ "android.graphics.Color", "com.hookedonplay.decoviewlib.events.DecoEvent" ]
import android.graphics.Color; import com.hookedonplay.decoviewlib.events.DecoEvent;
import android.graphics.*; import com.hookedonplay.decoviewlib.events.*;
[ "android.graphics", "com.hookedonplay.decoviewlib" ]
android.graphics; com.hookedonplay.decoviewlib;
893,797
private static void createTitle(final Shell shell, final String title, final NotifierColors colors) { final Label titleLabel = new Label(shell, SWT.NONE); final GridData gdLabel = new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false, 2, 1); gdLabel.horizontalIndent = 40; titleLabel.setLayoutData(...
static void function(final Shell shell, final String title, final NotifierColors colors) { final Label titleLabel = new Label(shell, SWT.NONE); final GridData gdLabel = new GridData(GridData.BEGINNING, GridData.BEGINNING, true, false, 2, 1); gdLabel.horizontalIndent = 40; titleLabel.setLayoutData(gdLabel); final Color ...
/** * Creates the title part of the window * * @param shell * the window * @param title * the title * @param colors * the color set */
Creates the title part of the window
createTitle
{ "repo_name": "Agem-Bilisim/lider-console", "path": "lider-console-core/src/tr/org/liderahenk/liderconsole/core/widgets/Notifier.java", "license": "lgpl-3.0", "size": 17349 }
[ "org.eclipse.swt.graphics.Color", "org.eclipse.swt.graphics.Font", "org.eclipse.swt.layout.GridData", "org.eclipse.swt.widgets.Label", "org.eclipse.swt.widgets.Shell", "tr.org.liderahenk.liderconsole.core.utils.SWTResourceManager" ]
import org.eclipse.swt.graphics.Color; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Shell; import tr.org.liderahenk.liderconsole.core.utils.SWTResourceManager;
import org.eclipse.swt.graphics.*; import org.eclipse.swt.layout.*; import org.eclipse.swt.widgets.*; import tr.org.liderahenk.liderconsole.core.utils.*;
[ "org.eclipse.swt", "tr.org.liderahenk" ]
org.eclipse.swt; tr.org.liderahenk;
1,853,484
private DnsServerAddressStream getNameServersFromCache(String hostname) { int len = hostname.length(); if (len == 0) { // We never cache for root servers. return null; } // We always store in the cache with a trailing '.'. if (hostname.charAt(len - 1...
DnsServerAddressStream function(String hostname) { int len = hostname.length(); if (len == 0) { return null; } if (hostname.charAt(len - 1) != '.') { hostname += "."; } int idx = hostname.indexOf('.'); if (idx == hostname.length() - 1) { return null; } for (;;) { hostname = hostname.substring(idx + 1); int idx2 = hostn...
/** * Returns the {@link DnsServerAddressStream} that was cached for the given hostname or {@code null} if non * could be found. */
Returns the <code>DnsServerAddressStream</code> that was cached for the given hostname or null if non could be found
getNameServersFromCache
{ "repo_name": "Apache9/netty", "path": "resolver-dns/src/main/java/io/netty/resolver/dns/DnsNameResolverContext.java", "license": "apache-2.0", "size": 36868 }
[ "java.net.InetSocketAddress", "java.util.List" ]
import java.net.InetSocketAddress; import java.util.List;
import java.net.*; import java.util.*;
[ "java.net", "java.util" ]
java.net; java.util;
1,437,626
@Test @MediumTest @Features.EnableFeatures(ChromeFeatureList.PRIVACY_SANDBOX_SETTINGS_3) public void testOpenAdPersonalizationSettings() throws IOException { loadUrlAndOpenPageInfo( mTestServerRule.getServer().getURLWithHostName("example.com", sSimpleHtml)); onView(withId...
@Features.EnableFeatures(ChromeFeatureList.PRIVACY_SANDBOX_SETTINGS_3) void function() throws IOException { loadUrlAndOpenPageInfo( mTestServerRule.getServer().getURLWithHostName(STR, sSimpleHtml)); onView(withId(PageInfoAdPersonalizationController.ROW_ID)).perform(click()); onViewWaiting(allOf(withText(R.string.page_i...
/** * Tests opening ad personalization settings. */
Tests opening ad personalization settings
testOpenAdPersonalizationSettings
{ "repo_name": "chromium/chromium", "path": "chrome/android/javatests/src/org/chromium/chrome/browser/page_info/PageInfoViewTest.java", "license": "bsd-3-clause", "size": 36581 }
[ "androidx.test.espresso.Espresso", "androidx.test.espresso.matcher.ViewMatchers", "java.io.IOException", "org.chromium.chrome.browser.flags.ChromeFeatureList", "org.chromium.chrome.test.util.browser.Features", "org.chromium.components.page_info.PageInfoAdPersonalizationController", "org.chromium.ui.test...
import androidx.test.espresso.Espresso; import androidx.test.espresso.matcher.ViewMatchers; import java.io.IOException; import org.chromium.chrome.browser.flags.ChromeFeatureList; import org.chromium.chrome.test.util.browser.Features; import org.chromium.components.page_info.PageInfoAdPersonalizationController; import ...
import androidx.test.espresso.*; import androidx.test.espresso.matcher.*; import java.io.*; import org.chromium.chrome.browser.flags.*; import org.chromium.chrome.test.util.browser.*; import org.chromium.components.page_info.*; import org.chromium.ui.test.util.*;
[ "androidx.test", "java.io", "org.chromium.chrome", "org.chromium.components", "org.chromium.ui" ]
androidx.test; java.io; org.chromium.chrome; org.chromium.components; org.chromium.ui;
2,626,568
@Override public void getTask(@NonNull String taskId, @NonNull GetTaskCallback callback) { SQLiteDatabase db = mDbHelper.getReadableDatabase(); String[] projection = { TasksPersistenceContract.TaskEntry.COLUMN_NAME_ENTRY_ID, TasksPersistenceContract.TaskEntry.COL...
void function(@NonNull String taskId, @NonNull GetTaskCallback callback) { SQLiteDatabase db = mDbHelper.getReadableDatabase(); String[] projection = { TasksPersistenceContract.TaskEntry.COLUMN_NAME_ENTRY_ID, TasksPersistenceContract.TaskEntry.COLUMN_NAME_TITLE, TasksPersistenceContract.TaskEntry.COLUMN_NAME_DESCRIPTIO...
/** * Note: {@link GetTaskCallback#onDataNotAvailable()} is fired if the {@link } isn't * found. */
Note: <code>GetTaskCallback#onDataNotAvailable()</code> is fired if the isn't found
getTask
{ "repo_name": "xiaowei20152012/LeeApp", "path": "todo/picomponent/src/main/java/com/todo/pic/data/local/TasksLocalDataSource.java", "license": "apache-2.0", "size": 8435 }
[ "android.database.Cursor", "android.database.sqlite.SQLiteDatabase", "android.support.annotation.NonNull", "com.todo.pic.domain.model.HomeInfo" ]
import android.database.Cursor; import android.database.sqlite.SQLiteDatabase; import android.support.annotation.NonNull; import com.todo.pic.domain.model.HomeInfo;
import android.database.*; import android.database.sqlite.*; import android.support.annotation.*; import com.todo.pic.domain.model.*;
[ "android.database", "android.support", "com.todo.pic" ]
android.database; android.support; com.todo.pic;
2,521,917
@SuppressWarnings("static-method") @Test public void testGetSegmentStreams_invalidDownsampleType() throws Exception { RateLimitedTestRunner.run(() -> { try { TestUtils.strava().getSegmentStreams(SegmentDataUtils.SEGMENT_VALID_ID, StravaStreamResolutionType.LOW, StravaStreamSeriesDownsamplingType.UNKNOWN);...
@SuppressWarnings(STR) void function() throws Exception { RateLimitedTestRunner.run(() -> { try { TestUtils.strava().getSegmentStreams(SegmentDataUtils.SEGMENT_VALID_ID, StravaStreamResolutionType.LOW, StravaStreamSeriesDownsamplingType.UNKNOWN); } catch (final IllegalArgumentException e) { return; } fail(STR); }); }
/** * <p> * Invalid downsample type * </p> * * @throws Exception * if the test fails in an unexpected way */
Invalid downsample type
testGetSegmentStreams_invalidDownsampleType
{ "repo_name": "danshannon/javastrava-test", "path": "src/main/java/test/service/impl/streamservice/GetSegmentStreamsTest.java", "license": "apache-2.0", "size": 6120 }
[ "org.junit.Assert" ]
import org.junit.Assert;
import org.junit.*;
[ "org.junit" ]
org.junit;
934,207
public void setUserProperties(List<PDUserProperty> userProperties) { COSArray p = new COSArray(); for (PDUserProperty userProperty : userProperties) { p.add(userProperty); } this.getCOSObject().setItem(COSName.P, p); }
void function(List<PDUserProperty> userProperties) { COSArray p = new COSArray(); for (PDUserProperty userProperty : userProperties) { p.add(userProperty); } this.getCOSObject().setItem(COSName.P, p); }
/** * Sets the user properties. * * @param userProperties the user properties */
Sets the user properties
setUserProperties
{ "repo_name": "ZhenyaM/veraPDF-pdfbox", "path": "pdfbox/src/main/java/org/apache/pdfbox/pdmodel/documentinterchange/logicalstructure/PDUserAttributeObject.java", "license": "apache-2.0", "size": 3624 }
[ "java.util.List", "org.apache.pdfbox.cos.COSArray", "org.apache.pdfbox.cos.COSName" ]
import java.util.List; import org.apache.pdfbox.cos.COSArray; import org.apache.pdfbox.cos.COSName;
import java.util.*; import org.apache.pdfbox.cos.*;
[ "java.util", "org.apache.pdfbox" ]
java.util; org.apache.pdfbox;
934,891
protected Size2D arrangeFF(BlockContainer container, Graphics2D g2, RectangleConstraint constraint) { double[] w = new double[5]; double[] h = new double[5]; w[0] = constraint.getWidth(); if (this.topBlock != null) { RectangleConstraint c1 =...
Size2D function(BlockContainer container, Graphics2D g2, RectangleConstraint constraint) { double[] w = new double[5]; double[] h = new double[5]; w[0] = constraint.getWidth(); if (this.topBlock != null) { RectangleConstraint c1 = new RectangleConstraint(w[0], null, LengthConstraintType.FIXED, 0.0, new Range(0.0, const...
/** * Arranges the items within a container. * * @param container the container. * @param constraint the constraint. * @param g2 the graphics device. * * @return The container size after the arrangement. */
Arranges the items within a container
arrangeFF
{ "repo_name": "JSansalone/JFreeChart", "path": "source/org/jfree/chart/block/BorderArrangement.java", "license": "lgpl-2.1", "size": 19786 }
[ "java.awt.Graphics2D", "java.awt.geom.Rectangle2D", "org.jfree.data.Range", "org.jfree.ui.Size2D" ]
import java.awt.Graphics2D; import java.awt.geom.Rectangle2D; import org.jfree.data.Range; import org.jfree.ui.Size2D;
import java.awt.*; import java.awt.geom.*; import org.jfree.data.*; import org.jfree.ui.*;
[ "java.awt", "org.jfree.data", "org.jfree.ui" ]
java.awt; org.jfree.data; org.jfree.ui;
1,201,241
public Observable<ServiceResponse<Page<ApplicationGatewayInner>>> listNextSinglePageAsync(final String nextPageLink) { if (nextPageLink == null) { throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); }
Observable<ServiceResponse<Page<ApplicationGatewayInner>>> function(final String nextPageLink) { if (nextPageLink == null) { throw new IllegalArgumentException(STR); }
/** * Gets all the application gateways in a subscription. * ServiceResponse<PageImpl<ApplicationGatewayInner>> * @param nextPageLink The NextLink from the previous successful call to List operation. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the PagedL...
Gets all the application gateways in a subscription
listNextSinglePageAsync
{ "repo_name": "martinsawicki/azure-sdk-for-java", "path": "azure-mgmt-network/src/main/java/com/microsoft/azure/management/network/implementation/ApplicationGatewaysInner.java", "license": "mit", "size": 125097 }
[ "com.microsoft.azure.Page", "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.azure.Page; import com.microsoft.rest.ServiceResponse;
import com.microsoft.azure.*; import com.microsoft.rest.*;
[ "com.microsoft.azure", "com.microsoft.rest" ]
com.microsoft.azure; com.microsoft.rest;
639,433
public void addAnimation(@NonNull AbstractTransitionBuilder transitionBuilder) { addAnimation(transitionBuilder.buildAnimation()); }
void function(@NonNull AbstractTransitionBuilder transitionBuilder) { addAnimation(transitionBuilder.buildAnimation()); }
/** * Same as calling addAnimation(transitionBuilder.buildAnimation()) * * @param transitionBuilder */
Same as calling addAnimation(transitionBuilder.buildAnimation())
addAnimation
{ "repo_name": "hypermit/android-transition", "path": "core/src/main/java/com/kaichunlin/transition/animation/AnimationManager.java", "license": "apache-2.0", "size": 9521 }
[ "android.support.annotation.NonNull", "com.kaichunlin.transition.AbstractTransitionBuilder" ]
import android.support.annotation.NonNull; import com.kaichunlin.transition.AbstractTransitionBuilder;
import android.support.annotation.*; import com.kaichunlin.transition.*;
[ "android.support", "com.kaichunlin.transition" ]
android.support; com.kaichunlin.transition;
2,244,393
@Test public final void testYBetween() { final Mesh yBet = this.m.yBetween(10, -10); Assert.assertTrue(yBet.contains(this.t1)); Assert.assertTrue(yBet.contains(this.t2)); }
final void function() { final Mesh yBet = this.m.yBetween(10, -10); Assert.assertTrue(yBet.contains(this.t1)); Assert.assertTrue(yBet.contains(this.t2)); }
/** * Test method for * {@link fr.nantes1900.models.basis.Mesh#yBetween(double, double)}. */
Test method for <code>fr.nantes1900.models.basis.Mesh#yBetween(double, double)</code>
testYBetween
{ "repo_name": "Nantes1900/Nantes-1900-PGROU-IHM", "path": "src/test/fr/nantes1900/models/MeshTest.java", "license": "gpl-3.0", "size": 20047 }
[ "fr.nantes1900.models.basis.Mesh", "junit.framework.Assert" ]
import fr.nantes1900.models.basis.Mesh; import junit.framework.Assert;
import fr.nantes1900.models.basis.*; import junit.framework.*;
[ "fr.nantes1900.models", "junit.framework" ]
fr.nantes1900.models; junit.framework;
2,083,627
@Nullable public WorkbookChartDataLabelFormat delete() throws ClientException { return send(HttpMethod.DELETE, null); }
WorkbookChartDataLabelFormat function() throws ClientException { return send(HttpMethod.DELETE, null); }
/** * Delete this item from the service * @return the resulting response if the service returns anything on deletion * * @throws ClientException if there was an exception during the delete operation */
Delete this item from the service
delete
{ "repo_name": "microsoftgraph/msgraph-sdk-java", "path": "src/main/java/com/microsoft/graph/requests/WorkbookChartDataLabelFormatRequest.java", "license": "mit", "size": 6793 }
[ "com.microsoft.graph.core.ClientException", "com.microsoft.graph.http.HttpMethod", "com.microsoft.graph.models.WorkbookChartDataLabelFormat" ]
import com.microsoft.graph.core.ClientException; import com.microsoft.graph.http.HttpMethod; import com.microsoft.graph.models.WorkbookChartDataLabelFormat;
import com.microsoft.graph.core.*; import com.microsoft.graph.http.*; import com.microsoft.graph.models.*;
[ "com.microsoft.graph" ]
com.microsoft.graph;
2,154,019
return Completable.fromCallable( () -> { // reads / writes are synchronized per client instance synchronized (this) { try (FileOutputStream output = application.openFileOutput(fileName, MODE_PRIVATE)) { output.write(messageLite.toByteArray()); return m...
return Completable.fromCallable( () -> { synchronized (this) { try (FileOutputStream output = application.openFileOutput(fileName, MODE_PRIVATE)) { output.write(messageLite.toByteArray()); return messageLite; } } }); }
/** * Write the proto to a file in the app' s file directory. * * <p>Writes are non atomic. * * <p>Readers are expected to deal with corrupt data resulting from faulty writes * * @param messageLite * @throws IOException */
Write the proto to a file in the app' s file directory. Writes are non atomic. Readers are expected to deal with corrupt data resulting from faulty writes
write
{ "repo_name": "firebase/firebase-android-sdk", "path": "firebase-inappmessaging/src/main/java/com/google/firebase/inappmessaging/internal/ProtoStorageClient.java", "license": "apache-2.0", "size": 3523 }
[ "io.reactivex.Completable", "java.io.FileOutputStream" ]
import io.reactivex.Completable; import java.io.FileOutputStream;
import io.reactivex.*; import java.io.*;
[ "io.reactivex", "java.io" ]
io.reactivex; java.io;
1,944,825
public ActionForward removePackagesFromErrata(ActionMapping mapping, ActionForm formIn, HttpServletRequest request, HttpServletResponse response) { RequestCo...
ActionForward function(ActionMapping mapping, ActionForm formIn, HttpServletRequest request, HttpServletResponse response) { RequestContext requestContext = new RequestContext(request); StrutsDelegate strutsDelegate = getStrutsDelegate(); User user = requestContext.getCurrentUser(); Errata errata = requestContext.looku...
/** * Remove packages corresponding to the ids in the packages_to_remove set from the * errata. * @param mapping ActionMapping * @param formIn ActionForm * @param request The request * @param response The response * @return Returns a success ActionForward if packages were removed. ...
Remove packages corresponding to the ids in the packages_to_remove set from the errata
removePackagesFromErrata
{ "repo_name": "xkollar/spacewalk", "path": "java/code/src/com/redhat/rhn/frontend/action/errata/RemovePackagesAction.java", "license": "gpl-2.0", "size": 7169 }
[ "com.redhat.rhn.domain.channel.Channel", "com.redhat.rhn.domain.errata.Errata", "com.redhat.rhn.domain.rhnpackage.Package", "com.redhat.rhn.domain.rhnset.RhnSet", "com.redhat.rhn.domain.rhnset.RhnSetElement", "com.redhat.rhn.domain.user.User", "com.redhat.rhn.frontend.struts.RequestContext", "com.redh...
import com.redhat.rhn.domain.channel.Channel; import com.redhat.rhn.domain.errata.Errata; import com.redhat.rhn.domain.rhnpackage.Package; import com.redhat.rhn.domain.rhnset.RhnSet; import com.redhat.rhn.domain.rhnset.RhnSetElement; import com.redhat.rhn.domain.user.User; import com.redhat.rhn.frontend.struts.RequestC...
import com.redhat.rhn.domain.channel.*; import com.redhat.rhn.domain.errata.*; import com.redhat.rhn.domain.rhnpackage.*; import com.redhat.rhn.domain.rhnset.*; import com.redhat.rhn.domain.user.*; import com.redhat.rhn.frontend.struts.*; import com.redhat.rhn.manager.errata.*; import com.redhat.rhn.manager.errata.cach...
[ "com.redhat.rhn", "java.util", "javax.servlet", "org.apache.struts" ]
com.redhat.rhn; java.util; javax.servlet; org.apache.struts;
1,401,676
private InputStreamReader asReader(File file){ try { return new InputStreamReader(new FileInputStream(file), Charset.defaultCharset()); } catch (IOException e){ throw new RuntimeException("Problem reading input"); } }
InputStreamReader function(File file){ try { return new InputStreamReader(new FileInputStream(file), Charset.defaultCharset()); } catch (IOException e){ throw new RuntimeException(STR); } }
/** * Convert a file into a Reader * @param file file to be converted * @return Json object representing the file, empty if problem reading file */
Convert a file into a Reader
asReader
{ "repo_name": "pluraliseseverythings/grakn", "path": "grakn-migration/json/src/main/java/ai/grakn/migration/json/JsonMigrator.java", "license": "gpl-3.0", "size": 5141 }
[ "java.io.File", "java.io.FileInputStream", "java.io.IOException", "java.io.InputStreamReader", "java.nio.charset.Charset" ]
import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStreamReader; import java.nio.charset.Charset;
import java.io.*; import java.nio.charset.*;
[ "java.io", "java.nio" ]
java.io; java.nio;
2,247,239
public static void submit(Optional<EventSubmitter> submitter, String name) { if (submitter.isPresent()) { submitter.get().submit(name); } }
static void function(Optional<EventSubmitter> submitter, String name) { if (submitter.isPresent()) { submitter.get().submit(name); } }
/** * Calls submit on submitter if present. */
Calls submit on submitter if present
submit
{ "repo_name": "pldash/gobblin-1", "path": "gobblin-metrics/src/main/java/gobblin/metrics/event/EventSubmitter.java", "license": "apache-2.0", "size": 5092 }
[ "com.google.common.base.Optional" ]
import com.google.common.base.Optional;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
2,265,165
public DelegateTree<ConstraintSolver,String> getConstraintSolverHierarchy() { DelegateTree<ConstraintSolver,String> ret = new DelegateTree<ConstraintSolver, String>(); ret.setRoot(this); ConstraintSolver[] myConstraintSolvers = this.getConstraintSolvers(); for (int i = 0; i < myConstraintSolvers.length; ...
DelegateTree<ConstraintSolver,String> function() { DelegateTree<ConstraintSolver,String> ret = new DelegateTree<ConstraintSolver, String>(); ret.setRoot(this); ConstraintSolver[] myConstraintSolvers = this.getConstraintSolvers(); for (int i = 0; i < myConstraintSolvers.length; i++) { String edgeLabel = i + STR + this.h...
/** * Get the hierarchy of {@link ConstraintSolver}s rooted in this {@link MultiConstraintSolver}. * @return The hierarchy of {@link ConstraintSolver}s rooted in this {@link MultiConstraintSolver}. */
Get the hierarchy of <code>ConstraintSolver</code>s rooted in this <code>MultiConstraintSolver</code>
getConstraintSolverHierarchy
{ "repo_name": "FedericoPecora/meta-csp-framework", "path": "src/main/java/org/metacsp/framework/multi/MultiConstraintSolver.java", "license": "mit", "size": 27325 }
[ "edu.uci.ics.jung.graph.DelegateTree", "edu.uci.ics.jung.graph.util.TreeUtils", "org.metacsp.framework.ConstraintSolver" ]
import edu.uci.ics.jung.graph.DelegateTree; import edu.uci.ics.jung.graph.util.TreeUtils; import org.metacsp.framework.ConstraintSolver;
import edu.uci.ics.jung.graph.*; import edu.uci.ics.jung.graph.util.*; import org.metacsp.framework.*;
[ "edu.uci.ics", "org.metacsp.framework" ]
edu.uci.ics; org.metacsp.framework;
2,098,542
private void setDiceSidesText(int sides) { ((TextView) getView().findViewById(R.id.settings_dice_sides_tv)) .setText(String.valueOf(sides)); }
void function(int sides) { ((TextView) getView().findViewById(R.id.settings_dice_sides_tv)) .setText(String.valueOf(sides)); }
/** * Sets the text of the number of sides on each die being rolled. * * @param sides * Number of sides on the dice */
Sets the text of the number of sides on each die being rolled
setDiceSidesText
{ "repo_name": "Ailuridaes/SimpleLife", "path": "app/src/main/java/com/brstf/simplelife/SettingsFragment.java", "license": "apache-2.0", "size": 19798 }
[ "android.widget.TextView" ]
import android.widget.TextView;
import android.widget.*;
[ "android.widget" ]
android.widget;
1,682,410
public static CallbackHandler getUsernamePasswordHandler( final String username, final String password) { LOGGER.fine("username=" + username + "; password=" + password.hashCode());
static CallbackHandler function( final String username, final String password) { LOGGER.fine(STR + username + STR + password.hashCode());
/** * Used by the BASIC Auth mechanism for establishing a LoginContext * to authenticate a client/caller/request. * * @param username client username * @param password client password * @return CallbackHandler to be used for establishing a LoginContext */
Used by the BASIC Auth mechanism for establishing a LoginContext to authenticate a client/caller/request
getUsernamePasswordHandler
{ "repo_name": "kkhmelevskoy/spnego", "path": "spnego/src/java/net/sourceforge/spnego/SpnegoProvider.java", "license": "lgpl-3.0", "size": 11773 }
[ "javax.security.auth.callback.CallbackHandler" ]
import javax.security.auth.callback.CallbackHandler;
import javax.security.auth.callback.*;
[ "javax.security" ]
javax.security;
322,453
public DateTime lastRenewedTime() { return this.lastRenewedTime; }
DateTime function() { return this.lastRenewedTime; }
/** * Get timestamp when the domain was renewed last time. * * @return the lastRenewedTime value */
Get timestamp when the domain was renewed last time
lastRenewedTime
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/appservice/mgmt-v2018_02_01/src/main/java/com/microsoft/azure/management/appservice/v2018_02_01/implementation/DomainInner.java", "license": "mit", "size": 14023 }
[ "org.joda.time.DateTime" ]
import org.joda.time.DateTime;
import org.joda.time.*;
[ "org.joda.time" ]
org.joda.time;
2,791,984
private static OrmLiteSqliteOpenHelper constructHelper(Context context, Class<? extends OrmLiteSqliteOpenHelper> openHelperClass) { Constructor<?> constructor; try { constructor = openHelperClass.getConstructor(Context.class); } catch (Exception e) { throw new IllegalStateException( "Could not fi...
static OrmLiteSqliteOpenHelper function(Context context, Class<? extends OrmLiteSqliteOpenHelper> openHelperClass) { Constructor<?> constructor; try { constructor = openHelperClass.getConstructor(Context.class); } catch (Exception e) { throw new IllegalStateException( STR + openHelperClass, e); } try { return (OrmLiteS...
/** * Call the constructor on our helper class. */
Call the constructor on our helper class
constructHelper
{ "repo_name": "d-tarasov/ormlite-android-sqlcipher", "path": "src/main/java/com/j256/ormlite/sqlcipher/android/apptools/OpenHelperManager.java", "license": "isc", "size": 12167 }
[ "android.content.Context", "java.lang.reflect.Constructor" ]
import android.content.Context; import java.lang.reflect.Constructor;
import android.content.*; import java.lang.reflect.*;
[ "android.content", "java.lang" ]
android.content; java.lang;
2,106,730
public void testBuildXmlFile() throws IOException { List<DspaceItem> items = itemExporter.getItems(1000, 1500); itemExporter.generateItemXMLFile(new File("C:\\items.xml"), items); }
void function() throws IOException { List<DspaceItem> items = itemExporter.getItems(1000, 1500); itemExporter.generateItemXMLFile(new File(STR), items); }
/** * Test building the xml file * * @throws IOException */
Test building the xml file
testBuildXmlFile
{ "repo_name": "nate-rcl/irplus", "path": "dspace_urresearch_export/test/edu/ur/dspace/export/DspaceItemExporterTest.java", "license": "apache-2.0", "size": 2647 }
[ "edu.ur.dspace.model.DspaceItem", "java.io.File", "java.io.IOException", "java.util.List" ]
import edu.ur.dspace.model.DspaceItem; import java.io.File; import java.io.IOException; import java.util.List;
import edu.ur.dspace.model.*; import java.io.*; import java.util.*;
[ "edu.ur.dspace", "java.io", "java.util" ]
edu.ur.dspace; java.io; java.util;
291,424
EReference getOrdinalOp__LessOp_1();
EReference getOrdinalOp__LessOp_1();
/** * Returns the meta object for the containment reference list '{@link cruise.umple.umple.OrdinalOp_#getLessOp_1 <em>Less Op 1</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the containment reference list '<em>Less Op 1</em>'. * @see cruise.umple.umple.OrdinalOp...
Returns the meta object for the containment reference list '<code>cruise.umple.umple.OrdinalOp_#getLessOp_1 Less Op 1</code>'.
getOrdinalOp__LessOp_1
{ "repo_name": "ahmedvc/umple", "path": "cruise.umple.xtext/src-gen/cruise/umple/umple/UmplePackage.java", "license": "mit", "size": 485842 }
[ "org.eclipse.emf.ecore.EReference" ]
import org.eclipse.emf.ecore.EReference;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
392,536
public PlayerDescriptor registerPlayer(final String playerName, final ServerTicket serverTicket) throws NullPointerException, ServerTicketException, PlayerRegisterException, RemoteException, RuntimeException;
PlayerDescriptor function(final String playerName, final ServerTicket serverTicket) throws NullPointerException, ServerTicketException, PlayerRegisterException, RemoteException, RuntimeException;
/** * Returns the player which has for name <code>playerName</code>, * or creates it if the player does not exist. * @param playerName the player name. * @param serverTicket the ticket of the calling client. * @return the descriptor of the player which has for name <code>playerName</code>, * or creates it i...
Returns the player which has for name <code>playerName</code>, or creates it if the player does not exist
registerPlayer
{ "repo_name": "pelletgu/fourinaline", "path": "org/gojul/fourinaline/model/GameServer.java", "license": "gpl-2.0", "size": 11698 }
[ "java.rmi.RemoteException" ]
import java.rmi.RemoteException;
import java.rmi.*;
[ "java.rmi" ]
java.rmi;
391,547