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 RuntimeEnvironmentBuilder newDefaultBuilder(ReleaseId releaseId);
RuntimeEnvironmentBuilder function(ReleaseId releaseId);
/** * Provides default configuration of <code>RuntimeEnvironmentBuilder</code> that is based on: * <ul> * <li>DefaultRuntimeEnvironment</li> * </ul> * This one is tailored to works smoothly with kjars as the notion of kbase and ksessions * @param releaseId <code>ReleaseId</code> that desc...
Provides default configuration of <code>RuntimeEnvironmentBuilder</code> that is based on: DefaultRuntimeEnvironment This one is tailored to works smoothly with kjars as the notion of kbase and ksessions
newDefaultBuilder
{ "repo_name": "hxf0801/droolsjbpm-knowledge", "path": "kie-api/src/main/java/org/kie/api/runtime/manager/RuntimeEnvironmentBuilderFactory.java", "license": "apache-2.0", "size": 5681 }
[ "org.kie.api.builder.ReleaseId" ]
import org.kie.api.builder.ReleaseId;
import org.kie.api.builder.*;
[ "org.kie.api" ]
org.kie.api;
2,093,906
@RequestMapping(method=RequestMethod.POST) public void handlePOSTRequest(HttpServletRequest _request, HttpServletResponse _response, @RequestParam("url") String sURL) { handlePOSTRequest(_request, _response, sURL, null); }
@RequestMapping(method=RequestMethod.POST) void function(HttpServletRequest _request, HttpServletResponse _response, @RequestParam("url") String sURL) { handlePOSTRequest(_request, _response, sURL, null); }
/** * Proxy entry point. Accessible via POST. * @param request. Must contains a "url" parameter pointing to the remote host * @param response. Contains in its content response from remote host * @param sURL. Automatically filled by the Spring url mapping * @param HttpConnection. To use a specif...
Proxy entry point. Accessible via POST
handlePOSTRequest
{ "repo_name": "jusabatier/georchestra", "path": "mapfishapp/src/main/java/org/georchestra/mapfishapp/ws/OGCProxy.java", "license": "gpl-3.0", "size": 21650 }
[ "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse", "org.springframework.web.bind.annotation.RequestMapping", "org.springframework.web.bind.annotation.RequestMethod", "org.springframework.web.bind.annotation.RequestParam" ]
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam;
import javax.servlet.http.*; import org.springframework.web.bind.annotation.*;
[ "javax.servlet", "org.springframework.web" ]
javax.servlet; org.springframework.web;
2,657,454
public void setMaxBaseCRLNumber(BigInteger maxBaseCRLNumber) { this.maxBaseCRLNumber = maxBaseCRLNumber; }
void function(BigInteger maxBaseCRLNumber) { this.maxBaseCRLNumber = maxBaseCRLNumber; }
/** * Sets the maximum base CRL number. Setting to <code>null</code> disables * this cheack. * <p> * This is only meaningful for delta CRLs. Complete CRLs must have a CRL * number which is greater or equal than the base number of the * corresponding CRL. * * @param maxBaseCRLNum...
Sets the maximum base CRL number. Setting to <code>null</code> disables this cheack. This is only meaningful for delta CRLs. Complete CRLs must have a CRL number which is greater or equal than the base number of the corresponding CRL
setMaxBaseCRLNumber
{ "repo_name": "bullda/DroidText", "path": "src/bouncycastle/repack/org/bouncycastle/x509/X509CRLStoreSelector.java", "license": "lgpl-3.0", "size": 10507 }
[ "java.math.BigInteger" ]
import java.math.BigInteger;
import java.math.*;
[ "java.math" ]
java.math;
2,764,863
public boolean matches(ScanResultCompat scanResult) { if (scanResult == null) { return false; } BluetoothDevice device = scanResult.getDevice(); // Device match. if (mDeviceAddress != null && (device == null || !mDeviceAddress.equals(device.getAddr...
boolean function(ScanResultCompat scanResult) { if (scanResult == null) { return false; } BluetoothDevice device = scanResult.getDevice(); if (mDeviceAddress != null && (device == null !mDeviceAddress.equals(device.getAddress()))) { return false; } ScanRecordCompat scanRecord = scanResult.getScanRecord(); if (scanRecor...
/** * Check if the scan filter matches a {@code scanResultCompat}. A scan result is considered as a match * if it matches all the field filters. */
Check if the scan filter matches a scanResultCompat. A scan result is considered as a match if it matches all the field filters
matches
{ "repo_name": "haodynasty/AndroidBleManager", "path": "bluetooth-manager-lib/src/main/java/com/blakequ/bluetooth_manager_lib/scan/bluetoothcompat/ScanFilterCompat.java", "license": "apache-2.0", "size": 24229 }
[ "android.bluetooth.BluetoothDevice" ]
import android.bluetooth.BluetoothDevice;
import android.bluetooth.*;
[ "android.bluetooth" ]
android.bluetooth;
2,901,536
@ServiceMethod(returns = ReturnType.SINGLE) public Response<AppInner> getByResourceGroupWithResponse( String resourceGroupName, String resourceName, Context context) { return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName, context).block(); }
@ServiceMethod(returns = ReturnType.SINGLE) Response<AppInner> function( String resourceGroupName, String resourceName, Context context) { return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName, context).block(); }
/** * Get the metadata of an IoT Central application. * * @param resourceGroupName The name of the resource group that contains the IoT Central application. * @param resourceName The ARM resource name of the IoT Central application. * @param context The context to associate with this operation....
Get the metadata of an IoT Central application
getByResourceGroupWithResponse
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/iotcentral/azure-resourcemanager-iotcentral/src/main/java/com/azure/resourcemanager/iotcentral/implementation/AppsClientImpl.java", "license": "mit", "size": 103959 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.Response", "com.azure.core.util.Context", "com.azure.resourcemanager.iotcentral.fluent.models.AppInner" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.iotcentral.fluent.models.AppInner;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.iotcentral.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
385,720
public T gone() { return visibility(View.GONE); }
T function() { return visibility(View.GONE); }
/** * Set view visibility to View.GONE. * * @return self */
Set view visibility to View.GONE
gone
{ "repo_name": "libit/lr_dialer", "path": "app/src/main/java/com/androidquery/AbstractAQuery.java", "license": "gpl-3.0", "size": 62801 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
1,507,068
protected void addArgument() { TableItem item = new TableItem(m_viewer.getTable(), SWT.NONE); item.setText(0, Integer.toString(m_viewer.getTable().getItemCount())); item.setBackground(0, Display.getCurrent().getSystemColor(SWT.COLOR_YELLOW)); }
void function() { TableItem item = new TableItem(m_viewer.getTable(), SWT.NONE); item.setText(0, Integer.toString(m_viewer.getTable().getItemCount())); item.setBackground(0, Display.getCurrent().getSystemColor(SWT.COLOR_YELLOW)); }
/*************************************************************************** * Add an argument **************************************************************************/
Add an argument
addArgument
{ "repo_name": "Spacecraft-Code/SPELL", "path": "src/spel-gui/com.astra.ses.spell.gui/src/com/astra/ses/spell/gui/dialogs/StartWithParametersDialog.java", "license": "lgpl-3.0", "size": 15574 }
[ "org.eclipse.swt.widgets.Display", "org.eclipse.swt.widgets.TableItem" ]
import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.TableItem;
import org.eclipse.swt.widgets.*;
[ "org.eclipse.swt" ]
org.eclipse.swt;
1,186,989
public List<List<TypeDeclaration>> getAllDeclarations() throws JavaParserException { wantedTypes = new LinkedList<List<TypeDeclaration>>(); searchDir(sourceCodeDir); return wantedTypes; }
List<List<TypeDeclaration>> function() throws JavaParserException { wantedTypes = new LinkedList<List<TypeDeclaration>>(); searchDir(sourceCodeDir); return wantedTypes; }
/** * Returns a list of lists of wanted type declarations and all parent type declarations. */
Returns a list of lists of wanted type declarations and all parent type declarations
getAllDeclarations
{ "repo_name": "conyx/jenkins.py", "path": "pwm/src/main/java/jenkins/python/pwm/AbstractTypeDeclFinder.java", "license": "mit", "size": 11341 }
[ "java.util.LinkedList", "java.util.List", "org.eclipse.jdt.core.dom.TypeDeclaration" ]
import java.util.LinkedList; import java.util.List; import org.eclipse.jdt.core.dom.TypeDeclaration;
import java.util.*; import org.eclipse.jdt.core.dom.*;
[ "java.util", "org.eclipse.jdt" ]
java.util; org.eclipse.jdt;
2,148,592
private NodeImporterStrategy createNodeImporterStrategy(ImporterBinding.UUID_BINDING uuidBinding) { if (uuidBinding == null) { return new CreateNewNodeImporterStrategy(true); } else if (uuidBinding.equals(UUID_BINDING.CREATE_NEW)) ...
NodeImporterStrategy function(ImporterBinding.UUID_BINDING uuidBinding) { if (uuidBinding == null) { return new CreateNewNodeImporterStrategy(true); } else if (uuidBinding.equals(UUID_BINDING.CREATE_NEW)) { return new CreateNewNodeImporterStrategy(true); } else if (uuidBinding.equals(UUID_BINDING.CREATE_NEW_WITH_UUID))...
/** * Create Node Importer Strategy * * @param uuidBinding UUID Binding * @return Node Importer Strategy */
Create Node Importer Strategy
createNodeImporterStrategy
{ "repo_name": "loftuxab/community-edition-old", "path": "projects/repository/source/java/org/alfresco/repo/importer/ImporterComponent.java", "license": "lgpl-3.0", "size": 71461 }
[ "org.alfresco.service.cmr.view.ImporterBinding" ]
import org.alfresco.service.cmr.view.ImporterBinding;
import org.alfresco.service.cmr.view.*;
[ "org.alfresco.service" ]
org.alfresco.service;
92,615
@Test public void testCleanupExpiredSegments() throws Exception, MessageSetSizeTooLargeException, SamsaStorageException, MessageSizeTooLargeException, InvalidMessageSizeException, OffsetOutOfRangeException { final Log log = logManager.createLog(new TopicAndPartition(name, 0), logConfig); long of...
void function() throws Exception, MessageSetSizeTooLargeException, SamsaStorageException, MessageSizeTooLargeException, InvalidMessageSizeException, OffsetOutOfRangeException { final Log log = logManager.createLog(new TopicAndPartition(name, 0), logConfig); long offset = 0L; for (int i = 0; i < 200; i++) { final ByteBu...
/** * Test time-based log cleanup. First append messages, then set the time into the future and run cleanup. */
Test time-based log cleanup. First append messages, then set the time into the future and run cleanup
testCleanupExpiredSegments
{ "repo_name": "bernd/samsa", "path": "src/test/java/com/github/bernd/samsa/LogManagerTest.java", "license": "apache-2.0", "size": 12290 }
[ "com.github.bernd.samsa.message.ByteBufferMessageSet", "com.github.bernd.samsa.message.InvalidMessageSizeException", "com.github.bernd.samsa.message.MessageSetSizeTooLargeException", "com.github.bernd.samsa.message.MessageSizeTooLargeException", "org.testng.Assert" ]
import com.github.bernd.samsa.message.ByteBufferMessageSet; import com.github.bernd.samsa.message.InvalidMessageSizeException; import com.github.bernd.samsa.message.MessageSetSizeTooLargeException; import com.github.bernd.samsa.message.MessageSizeTooLargeException; import org.testng.Assert;
import com.github.bernd.samsa.message.*; import org.testng.*;
[ "com.github.bernd", "org.testng" ]
com.github.bernd; org.testng;
1,283,336
private PersistentClass getClassMapping(String className) throws DataMigrationException { PersistentClass pClass = this.metadata.getEntityBinding(className); if (pClass == null) { throw new DataMigrationException( String.format("Could not migrate IDs for class [%s] :...
PersistentClass function(String className) throws DataMigrationException { PersistentClass pClass = this.metadata.getEntityBinding(className); if (pClass == null) { throw new DataMigrationException( String.format(STR + STR + STR + STR + STR + STR + STR, className)); } return pClass; }
/** * get hibernate mapping of the given class or entity name. * * @param className the class or entity name * @return a list of pair of table name and the property field name. * @throws DataMigrationException if mapping cannot be found */
get hibernate mapping of the given class or entity name
getClassMapping
{ "repo_name": "xwiki/xwiki-platform", "path": "xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/store/migration/hibernate/R40000XWIKI6990DataMigration.java", "license": "lgpl-2.1", "size": 56579 }
[ "com.xpn.xwiki.store.migration.DataMigrationException", "org.hibernate.mapping.PersistentClass" ]
import com.xpn.xwiki.store.migration.DataMigrationException; import org.hibernate.mapping.PersistentClass;
import com.xpn.xwiki.store.migration.*; import org.hibernate.mapping.*;
[ "com.xpn.xwiki", "org.hibernate.mapping" ]
com.xpn.xwiki; org.hibernate.mapping;
549,575
public Observable<ServiceResponse<Page<ClusterInner>>> listByResourceGroupSinglePageAsync(final String resourceGroupName) { if (this.client.subscriptionId() == null) { throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); } ...
Observable<ServiceResponse<Page<ClusterInner>>> function(final String resourceGroupName) { if (this.client.subscriptionId() == null) { throw new IllegalArgumentException(STR); } if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (this.client.apiVersion() == null) { throw new IllegalArgumentE...
/** * Lists the available Event Hubs Clusters within an ARM resource group. * ServiceResponse<PageImpl<ClusterInner>> * @param resourceGroupName Name of the resource group within the Azure subscription. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the Pag...
Lists the available Event Hubs Clusters within an ARM resource group
listByResourceGroupSinglePageAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/eventhubs/mgmt-v2018_01_01_preview/src/main/java/com/microsoft/azure/management/eventhubs/v2018_01_01_preview/implementation/ClustersInner.java", "license": "mit", "size": 63607 }
[ "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;
2,281,141
public void showResource(ICEResource resource) throws PartInitException { // TODO Do this off the UI thread. // TODO This method has several return statements, making it a little // hard to read. It should be updated and simplified. // If no resource is selected, then clear the current contents of // th...
void function(ICEResource resource) throws PartInitException { if (resource == null) { Control topControl = stackLayout.topControl; if (topControl != browser) { browser.setText(STR + STRfont-family:Tahoma;font-size:x-small\" " + STRcenter\STR + STR); stackLayout.topControl = browser; pageComposite.layout(); if (topCont...
/** * Updates the Resource Page's widgets to render the specified Resource. * <p> * <b>Note:</b> This method assumes it is called from the UI thread. * </p> * * @param resource * The resource to render. Assumed not to be {@code null}. * @throws PartInitException */
Updates the Resource Page's widgets to render the specified Resource. Note: This method assumes it is called from the UI thread.
showResource
{ "repo_name": "wo-amlangwang/ice", "path": "org.eclipse.ice.client.widgets/src/org/eclipse/ice/client/widgets/ICEResourcePage.java", "license": "epl-1.0", "size": 17550 }
[ "org.eclipse.core.filesystem.EFS", "org.eclipse.core.filesystem.IFileStore", "org.eclipse.ice.datastructures.resource.ICEResource", "org.eclipse.ice.datastructures.resource.VizResource", "org.eclipse.swt.widgets.Control", "org.eclipse.ui.IWorkbenchPage", "org.eclipse.ui.IWorkbenchWindow", "org.eclipse...
import org.eclipse.core.filesystem.EFS; import org.eclipse.core.filesystem.IFileStore; import org.eclipse.ice.datastructures.resource.ICEResource; import org.eclipse.ice.datastructures.resource.VizResource; import org.eclipse.swt.widgets.Control; import org.eclipse.ui.IWorkbenchPage; import org.eclipse.ui.IWorkbenchWin...
import org.eclipse.core.filesystem.*; import org.eclipse.ice.datastructures.resource.*; import org.eclipse.swt.widgets.*; import org.eclipse.ui.*; import org.eclipse.ui.ide.*;
[ "org.eclipse.core", "org.eclipse.ice", "org.eclipse.swt", "org.eclipse.ui" ]
org.eclipse.core; org.eclipse.ice; org.eclipse.swt; org.eclipse.ui;
2,561,392
private void updateInterfaceState(String iface, boolean up) { if (!mIface.equals(iface)) { return; } Log.d(TAG, "updateInterface: " + iface + " link " + (up ? "up" : "down")); synchronized(this) { mLinkUp = up; mNetworkInfo.setIsAvailable(up); ...
void function(String iface, boolean up) { if (!mIface.equals(iface)) { return; } Log.d(TAG, STR + iface + STR + (up ? "up" : "down")); synchronized(this) { mLinkUp = up; mNetworkInfo.setIsAvailable(up); if (!up) { mNetworkInfo.setDetailedState(DetailedState.DISCONNECTED, null, mHwAddr); sendEthernetStateChangedBroadcas...
/** * Updates interface state variables. * Called on link state changes or on startup. */
Updates interface state variables. Called on link state changes or on startup
updateInterfaceState
{ "repo_name": "s20121035/rk3288_android5.1_repo", "path": "frameworks/opt/net/ethernet/java/com/android/server/ethernet/EthernetNetworkFactory.java", "license": "gpl-3.0", "size": 25744 }
[ "android.net.EthernetManager", "android.net.NetworkInfo", "android.util.Log" ]
import android.net.EthernetManager; import android.net.NetworkInfo; import android.util.Log;
import android.net.*; import android.util.*;
[ "android.net", "android.util" ]
android.net; android.util;
1,254,765
public void saveGeoPoints() { double lat = 0; double lon = 0; int i = 0; for (GeoPoint geoPoint : this.getPoints()) { lat += geoPoint.getLatitude(); lon += geoPoint.getLongitude(); i++; } this.midLocation = new Location("provide"); ...
void function() { double lat = 0; double lon = 0; int i = 0; for (GeoPoint geoPoint : this.getPoints()) { lat += geoPoint.getLatitude(); lon += geoPoint.getLongitude(); i++; } this.midLocation = new Location(STR); this.midLocation.setLatitude(lat / i); this.midLocation.setLongitude(lon / i); this.pointCoords = new Arra...
/** * Saves all Points in a different coordinate system and saves the Location * of this system. */
Saves all Points in a different coordinate system and saves the Location of this system
saveGeoPoints
{ "repo_name": "Data4All/Data4All", "path": "src/main/java/io/github/data4all/model/map/MapPolygon.java", "license": "apache-2.0", "size": 18411 }
[ "android.content.SharedPreferences", "android.content.res.Resources", "android.location.Location", "android.preference.PreferenceManager", "io.github.data4all.model.data.Node", "io.github.data4all.util.MathUtil", "java.util.ArrayList", "org.osmdroid.util.GeoPoint" ]
import android.content.SharedPreferences; import android.content.res.Resources; import android.location.Location; import android.preference.PreferenceManager; import io.github.data4all.model.data.Node; import io.github.data4all.util.MathUtil; import java.util.ArrayList; import org.osmdroid.util.GeoPoint;
import android.content.*; import android.content.res.*; import android.location.*; import android.preference.*; import io.github.data4all.model.data.*; import io.github.data4all.util.*; import java.util.*; import org.osmdroid.util.*;
[ "android.content", "android.location", "android.preference", "io.github.data4all", "java.util", "org.osmdroid.util" ]
android.content; android.location; android.preference; io.github.data4all; java.util; org.osmdroid.util;
2,589,499
public String getEtagValue() throws RepositoryException { final Date lastModifiedDate = getLastModifiedDate(); if (lastModifiedDate != null) { return shaHex(node.getPath() + lastModifiedDate.toString()); } else { return ""; } }
String function() throws RepositoryException { final Date lastModifiedDate = getLastModifiedDate(); if (lastModifiedDate != null) { return shaHex(node.getPath() + lastModifiedDate.toString()); } else { return ""; } }
/** * Construct an ETag value from the last modified date and path. JCR has a * mix:etag type, but it only takes into account binary properties. We * actually want whole-object etag data. TODO : construct and store an ETag * value on object modify * * @return * @throws RepositoryExcep...
Construct an ETag value from the last modified date and path. JCR has a mix:etag type, but it only takes into account binary properties. We actually want whole-object etag data. TODO : construct and store an ETag value on object modify
getEtagValue
{ "repo_name": "barmintor/fcrepo4", "path": "fcrepo-kernel/src/main/java/org/fcrepo/kernel/FedoraResource.java", "license": "apache-2.0", "size": 13555 }
[ "java.util.Date", "javax.jcr.RepositoryException", "org.apache.commons.codec.digest.DigestUtils" ]
import java.util.Date; import javax.jcr.RepositoryException; import org.apache.commons.codec.digest.DigestUtils;
import java.util.*; import javax.jcr.*; import org.apache.commons.codec.digest.*;
[ "java.util", "javax.jcr", "org.apache.commons" ]
java.util; javax.jcr; org.apache.commons;
1,240,976
protected Context getDefaultInitCtx() throws NamingException{ if (!gotDefault) { defaultInitCtx = NamingManager.getInitialContext(myProps); gotDefault = true; } if (defaultInitCtx == null) throw new NoInitialContextException(); return defaultInitC...
Context function() throws NamingException{ if (!gotDefault) { defaultInitCtx = NamingManager.getInitialContext(myProps); gotDefault = true; } if (defaultInitCtx == null) throw new NoInitialContextException(); return defaultInitCtx; }
/** * Retrieves the initial context by calling * <code>NamingManager.getInitialContext()</code> * and cache it in defaultInitCtx. * Set <code>gotDefault</code> so that we know we've tried this before. * @return The non-null cached initial context. * @exception NoInitialContextException If ...
Retrieves the initial context by calling <code>NamingManager.getInitialContext()</code> and cache it in defaultInitCtx. Set <code>gotDefault</code> so that we know we've tried this before
getDefaultInitCtx
{ "repo_name": "Taichi-SHINDO/jdk9-jdk", "path": "src/java.naming/share/classes/javax/naming/InitialContext.java", "license": "gpl-2.0", "size": 20939 }
[ "javax.naming.spi.NamingManager" ]
import javax.naming.spi.NamingManager;
import javax.naming.spi.*;
[ "javax.naming" ]
javax.naming;
2,209,239
@Property(SHA1_HASH) void setSHA1Hash(String sha1Hash);
@Property(SHA1_HASH) void setSHA1Hash(String sha1Hash);
/** * Contains a SHA1 Hash of the file */
Contains a SHA1 Hash of the file
setSHA1Hash
{ "repo_name": "lincolnthree/windup", "path": "graph/api/src/main/java/org/jboss/windup/graph/model/resource/FileModel.java", "license": "epl-1.0", "size": 9089 }
[ "com.tinkerpop.frames.Property" ]
import com.tinkerpop.frames.Property;
import com.tinkerpop.frames.*;
[ "com.tinkerpop.frames" ]
com.tinkerpop.frames;
1,642,600
private void writeIndexData(final String table, final BufferedWriter writer, final Map<String, Map<IndexData, List<IndexColData>>> indexData) { // Check for no indexes for this table if ((indexData == null) || (!indexData.containsKey(table))) { return; } Map<IndexData, List<IndexColData>>...
void function(final String table, final BufferedWriter writer, final Map<String, Map<IndexData, List<IndexColData>>> indexData) { if ((indexData == null) (!indexData.containsKey(table))) { return; } Map<IndexData, List<IndexColData>> map = indexData.get(table); if ((map == null) (map.isEmpty())) { return; } writeOut(wr...
/** * Write out data on the table indexes. * * @param table the table to inspect for indexes * @param writer the output writer * @param indexData the index data set */
Write out data on the table indexes
writeIndexData
{ "repo_name": "argonium/beetle-cli", "path": "src/io/miti/beetle/prefs/DBScript.java", "license": "mit", "size": 24846 }
[ "java.io.BufferedWriter", "java.util.List", "java.util.Map" ]
import java.io.BufferedWriter; import java.util.List; import java.util.Map;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
2,612,182
public static ErasureDecoder createDecoder(Configuration conf, ErasureCodecOptions options) { Preconditions.checkNotNull(conf); Preconditions.checkNotNull(options); String codecKey = getCodecClassName(conf, options.getSchema().getCodecName()); ErasureCodec codec = createCodec(conf, cod...
static ErasureDecoder function(Configuration conf, ErasureCodecOptions options) { Preconditions.checkNotNull(conf); Preconditions.checkNotNull(options); String codecKey = getCodecClassName(conf, options.getSchema().getCodecName()); ErasureCodec codec = createCodec(conf, codecKey, options); return codec.createDecoder();...
/** * Create decoder corresponding to given codec. * @param options Erasure codec options * @return erasure decoder */
Create decoder corresponding to given codec
createDecoder
{ "repo_name": "JingchengDu/hadoop", "path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/erasurecode/CodecUtil.java", "license": "apache-2.0", "size": 10315 }
[ "org.apache.hadoop.conf.Configuration", "org.apache.hadoop.io.erasurecode.codec.ErasureCodec", "org.apache.hadoop.io.erasurecode.coder.ErasureDecoder", "org.apache.hadoop.util.Preconditions" ]
import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.io.erasurecode.codec.ErasureCodec; import org.apache.hadoop.io.erasurecode.coder.ErasureDecoder; import org.apache.hadoop.util.Preconditions;
import org.apache.hadoop.conf.*; import org.apache.hadoop.io.erasurecode.codec.*; import org.apache.hadoop.io.erasurecode.coder.*; import org.apache.hadoop.util.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
111,462
public ServiceFuture<RollingUpgradeStatusInfoInner> getLatestAsync(String resourceGroupName, String vmScaleSetName, final ServiceCallback<RollingUpgradeStatusInfoInner> serviceCallback) { return ServiceFuture.fromResponse(getLatestWithServiceResponseAsync(resourceGroupName, vmScaleSetName), serviceCallback)...
ServiceFuture<RollingUpgradeStatusInfoInner> function(String resourceGroupName, String vmScaleSetName, final ServiceCallback<RollingUpgradeStatusInfoInner> serviceCallback) { return ServiceFuture.fromResponse(getLatestWithServiceResponseAsync(resourceGroupName, vmScaleSetName), serviceCallback); }
/** * Gets the status of the latest virtual machine scale set rolling upgrade. * * @param resourceGroupName The name of the resource group. * @param vmScaleSetName The name of the VM scale set. * @param serviceCallback the async ServiceCallback to handle successful and failed responses. * ...
Gets the status of the latest virtual machine scale set rolling upgrade
getLatestAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/compute/mgmt-v2017_03_30/src/main/java/com/microsoft/azure/management/compute/v2017_03_30/implementation/VirtualMachineScaleSetRollingUpgradesInner.java", "license": "mit", "size": 29692 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
50,173
private void addCodeToRequireJsFunctions(SoyFileNode soyFile) { SortedSet<String> requires = new TreeSet<>(); for (CallBasicNode node : new FindCalleesNotInFileVisitor().exec(soyFile)) { requires.add(node.getCalleeName()); } for (String require : requires) { addGoogRequire(require, false);...
void function(SoyFileNode soyFile) { SortedSet<String> requires = new TreeSet<>(); for (CallBasicNode node : new FindCalleesNotInFileVisitor().exec(soyFile)) { requires.add(node.getCalleeName()); } for (String require : requires) { addGoogRequire(require, false); } }
/** * Helper for visitSoyFileNode(SoyFileNode) to add code to require template JS functions. * @param soyFile The node we're visiting. */
Helper for visitSoyFileNode(SoyFileNode) to add code to require template JS functions
addCodeToRequireJsFunctions
{ "repo_name": "nathancomstock/closure-templates", "path": "java/src/com/google/template/soy/jssrc/internal/GenJsCodeVisitor.java", "license": "apache-2.0", "size": 70178 }
[ "com.google.template.soy.shared.internal.FindCalleesNotInFileVisitor", "com.google.template.soy.soytree.CallBasicNode", "com.google.template.soy.soytree.SoyFileNode", "java.util.SortedSet", "java.util.TreeSet" ]
import com.google.template.soy.shared.internal.FindCalleesNotInFileVisitor; import com.google.template.soy.soytree.CallBasicNode; import com.google.template.soy.soytree.SoyFileNode; import java.util.SortedSet; import java.util.TreeSet;
import com.google.template.soy.shared.internal.*; import com.google.template.soy.soytree.*; import java.util.*;
[ "com.google.template", "java.util" ]
com.google.template; java.util;
2,150,772
public List<Datapoint> convertJsonArrayToDatapointList(JsonArray jsonArray) { List<Datapoint> result = gson.fromJson(jsonArray.toString(), new TypeToken<List<Datapoint>>() {}.getType()); return result; }
List<Datapoint> function(JsonArray jsonArray) { List<Datapoint> result = gson.fromJson(jsonArray.toString(), new TypeToken<List<Datapoint>>() {}.getType()); return result; }
/** * Convert any jsonarray with convertable objects to a List * * @param jsonArray * @param clzz * @return */
Convert any jsonarray with convertable objects to a List
convertJsonArrayToDatapointList
{ "repo_name": "icttuwien/acona", "path": "src/acona-core/src/main/java/at/tuwien/ict/acona/mq/utils/GsonUtils.java", "license": "lgpl-3.0", "size": 5995 }
[ "at.tuwien.ict.acona.mq.datastructures.Datapoint", "com.google.gson.JsonArray", "com.google.gson.reflect.TypeToken", "java.util.List" ]
import at.tuwien.ict.acona.mq.datastructures.Datapoint; import com.google.gson.JsonArray; import com.google.gson.reflect.TypeToken; import java.util.List;
import at.tuwien.ict.acona.mq.datastructures.*; import com.google.gson.*; import com.google.gson.reflect.*; import java.util.*;
[ "at.tuwien.ict", "com.google.gson", "java.util" ]
at.tuwien.ict; com.google.gson; java.util;
824,503
@Override protected synchronized void startInternal() throws LifecycleException { super.startInternal(); setState(LifecycleState.STARTING); Boolean attachedToValve = false; for (Valve valve : getContainer().getPipeline().getValves()) { if (valve instanceof RedisSessionHandlerValve) { ...
synchronized void function() throws LifecycleException { super.startInternal(); setState(LifecycleState.STARTING); Boolean attachedToValve = false; for (Valve valve : getContainer().getPipeline().getValves()) { if (valve instanceof RedisSessionHandlerValve) { this.handlerValve = (RedisSessionHandlerValve) valve; this.h...
/** * Start this component and implement the requirements * of {@link org.apache.catalina.util.LifecycleBase#startInternal()}. * * @exception LifecycleException if this component detects a fatal error * that prevents this component from being used */
Start this component and implement the requirements of <code>org.apache.catalina.util.LifecycleBase#startInternal()</code>
startInternal
{ "repo_name": "michaelcameron/tomcat-redis-session-manager", "path": "src/main/java/com/orangefunction/tomcat/redissessions/RedisSessionManager.java", "license": "mit", "size": 25721 }
[ "org.apache.catalina.LifecycleException", "org.apache.catalina.LifecycleState", "org.apache.catalina.Valve" ]
import org.apache.catalina.LifecycleException; import org.apache.catalina.LifecycleState; import org.apache.catalina.Valve;
import org.apache.catalina.*;
[ "org.apache.catalina" ]
org.apache.catalina;
1,319,823
private static void diskIoCheckWithoutNativeIo(File file) throws IOException { FileOutputStream fos = null; try { final FileIoProvider provider = fileIoProvider.get(); fos = provider.get(file); provider.write(fos, new byte[1]); fos.getFD().sync(); fos.close(); fos = ...
static void function(File file) throws IOException { FileOutputStream fos = null; try { final FileIoProvider provider = fileIoProvider.get(); fos = provider.get(file); provider.write(fos, new byte[1]); fos.getFD().sync(); fos.close(); fos = null; if (!file.delete() && file.exists()) { throw new IOException(STR + file);...
/** * Try to perform some disk IO by writing to the given file * without using Native IO. * * @param file * @throws IOException if there was a non-retriable error. */
Try to perform some disk IO by writing to the given file without using Native IO
diskIoCheckWithoutNativeIo
{ "repo_name": "GeLiXin/hadoop", "path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/DiskChecker.java", "license": "apache-2.0", "size": 12283 }
[ "java.io.File", "java.io.FileOutputStream", "java.io.IOException", "org.apache.commons.io.FileUtils", "org.apache.hadoop.io.IOUtils" ]
import java.io.File; import java.io.FileOutputStream; import java.io.IOException; import org.apache.commons.io.FileUtils; import org.apache.hadoop.io.IOUtils;
import java.io.*; import org.apache.commons.io.*; import org.apache.hadoop.io.*;
[ "java.io", "org.apache.commons", "org.apache.hadoop" ]
java.io; org.apache.commons; org.apache.hadoop;
1,962,077
public static void show(Activity activity, View customView) { make(activity, customView).show(); }
static void function(Activity activity, View customView) { make(activity, customView).show(); }
/** * Creates a {@link Crouton} with provided text and style for a given activity * and displays it directly. * * @param activity * The {@link android.app.Activity} that the {@link Crouton} should * be attached to. * @param customView * The custom {@link View} to display */
Creates a <code>Crouton</code> with provided text and style for a given activity and displays it directly
show
{ "repo_name": "manumaticx/TiCrouton", "path": "src/de/manumaticx/crouton/Crouton.java", "license": "mit", "size": 32725 }
[ "android.app.Activity", "android.view.View" ]
import android.app.Activity; import android.view.View;
import android.app.*; import android.view.*;
[ "android.app", "android.view" ]
android.app; android.view;
998,945
public Date getCloseOnOrBeforeDate() { return closeOnOrBeforeDate; }
Date function() { return closeOnOrBeforeDate; }
/** * Gets the date on which this instance should trigger the CloseBatchStep to close out {@link {Proposal}s and {@link Award}s. * * @return the date on which this instance should trigger the CloseBatchStep to close out {@link {Proposal}s and {@link Award}s. */
Gets the date on which this instance should trigger the CloseBatchStep to close out <code>{Proposal</code>s and <code>Award</code>s
getCloseOnOrBeforeDate
{ "repo_name": "Ariah-Group/Finance", "path": "af_webapp/src/main/java/org/kuali/kfs/module/cg/document/CloseDocument.java", "license": "apache-2.0", "size": 2629 }
[ "java.sql.Date" ]
import java.sql.Date;
import java.sql.*;
[ "java.sql" ]
java.sql;
1,534,323
public void setMinimumNodeEdgeDistance(final Integer minNodeEdgeDistance) { Preconditions.checkArgument(minNodeEdgeDistance >= 0, "Error: Distance argument must not be negative"); if (minNodeEdgeDistance == getMinimumNodeEdgeDistance()) { return; } if (m_type == null) { m_minimum...
void function(final Integer minNodeEdgeDistance) { Preconditions.checkArgument(minNodeEdgeDistance >= 0, STR); if (minNodeEdgeDistance == getMinimumNodeEdgeDistance()) { return; } if (m_type == null) { m_minimumNodeEdgeDistance = minNodeEdgeDistance; } else { m_type.setHierarchicMinimumNodeEdgeDistance(minNodeEdgeDista...
/** * Changes the current minimum node to edge distance setting. * * @param minNodeEdgeDistance the new minimum distance between nodes and edges */
Changes the current minimum node to edge distance setting
setMinimumNodeEdgeDistance
{ "repo_name": "AmesianX/binnavi", "path": "src/main/java/com/google/security/zynamics/binnavi/ZyGraph/Settings/ZyGraphHierarchicalSettings.java", "license": "apache-2.0", "size": 8886 }
[ "com.google.common.base.Preconditions" ]
import com.google.common.base.Preconditions;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
2,471,937
@ServiceMethod(returns = ReturnType.SINGLE) void reimageAll(String resourceGroupName, String vmScaleSetName);
@ServiceMethod(returns = ReturnType.SINGLE) void reimageAll(String resourceGroupName, String vmScaleSetName);
/** * Reimages all the disks ( including data disks ) in the virtual machines in a VM scale set. This operation is only * supported for managed disks. * * @param resourceGroupName The name of the resource group. * @param vmScaleSetName The name of the VM scale set. * @throws IllegalArgumen...
Reimages all the disks ( including data disks ) in the virtual machines in a VM scale set. This operation is only supported for managed disks
reimageAll
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanagerhybrid/azure-resourcemanager-compute/src/main/java/com/azure/resourcemanager/compute/fluent/VirtualMachineScaleSetsClient.java", "license": "mit", "size": 129320 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod;
import com.azure.core.annotation.*;
[ "com.azure.core" ]
com.azure.core;
445,859
@EventHandler("btn-resubmitted-situation") protected void onResubmittedSituationClick(ClickEvent event) { HashMultimap<String,String> map=HashMultimap.<String,String>create(); map.put("id", situation.getModel().getResubmittedSituationId()); resubmittedSituationLink.go(map); }
@EventHandler(STR) void function(ClickEvent event) { HashMultimap<String,String> map=HashMultimap.<String,String>create(); map.put("id", situation.getModel().getResubmittedSituationId()); resubmittedSituationLink.go(map); }
/** * Called when the user clicks the Resubmit button. * @param event */
Called when the user clicks the Resubmit button
onResubmittedSituationClick
{ "repo_name": "jorgemoralespou/rtgov", "path": "ui/overlord-rtgov-ui-base/src/main/java/org/overlord/rtgov/ui/client/local/pages/SituationDetailsPage.java", "license": "apache-2.0", "size": 19710 }
[ "com.google.common.collect.HashMultimap", "com.google.gwt.event.dom.client.ClickEvent", "org.jboss.errai.ui.shared.api.annotations.EventHandler" ]
import com.google.common.collect.HashMultimap; import com.google.gwt.event.dom.client.ClickEvent; import org.jboss.errai.ui.shared.api.annotations.EventHandler;
import com.google.common.collect.*; import com.google.gwt.event.dom.client.*; import org.jboss.errai.ui.shared.api.annotations.*;
[ "com.google.common", "com.google.gwt", "org.jboss.errai" ]
com.google.common; com.google.gwt; org.jboss.errai;
1,905,216
@Override protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { processRequest(request, response); } catch (SQLException ex) { Logger.getLogger(Favorite.class.getName()).log(Level.SEVERE, n...
void function(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { processRequest(request, response); } catch (SQLException ex) { Logger.getLogger(Favorite.class.getName()).log(Level.SEVERE, null, ex); } }
/** * Handles the HTTP <code>POST</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */
Handles the HTTP <code>POST</code> method
doPost
{ "repo_name": "chin8628/Usami", "path": "src/java/controller/Favorite.java", "license": "mit", "size": 4499 }
[ "java.io.IOException", "java.sql.SQLException", "java.util.logging.Level", "java.util.logging.Logger", "javax.servlet.ServletException", "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse" ]
import java.io.IOException; import java.sql.SQLException; import java.util.logging.Level; import java.util.logging.Logger; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse;
import java.io.*; import java.sql.*; import java.util.logging.*; import javax.servlet.*; import javax.servlet.http.*;
[ "java.io", "java.sql", "java.util", "javax.servlet" ]
java.io; java.sql; java.util; javax.servlet;
1,036,845
public void setValidating(boolean validate) { setProperty(new BooleanProperty(VALIDATE_KEY, validate)); }
void function(boolean validate) { setProperty(new BooleanProperty(VALIDATE_KEY, validate)); }
/** * Set use validation * * @param validate Flag whether validation should be used */
Set use validation
setValidating
{ "repo_name": "benbenw/jmeter", "path": "src/components/src/main/java/org/apache/jmeter/assertions/XPathAssertion.java", "license": "apache-2.0", "size": 8972 }
[ "org.apache.jmeter.testelement.property.BooleanProperty" ]
import org.apache.jmeter.testelement.property.BooleanProperty;
import org.apache.jmeter.testelement.property.*;
[ "org.apache.jmeter" ]
org.apache.jmeter;
1,558,688
public ImmutableList<Artifact> getFilesToRun() { return filesToRun; }
ImmutableList<Artifact> function() { return filesToRun; }
/** * Returns artifacts needed to run the executable for this target. */
Returns artifacts needed to run the executable for this target
getFilesToRun
{ "repo_name": "iamthearm/bazel", "path": "src/main/java/com/google/devtools/build/lib/analysis/FilesToRunProvider.java", "license": "apache-2.0", "size": 3912 }
[ "com.google.common.collect.ImmutableList", "com.google.devtools.build.lib.actions.Artifact" ]
import com.google.common.collect.ImmutableList; import com.google.devtools.build.lib.actions.Artifact;
import com.google.common.collect.*; import com.google.devtools.build.lib.actions.*;
[ "com.google.common", "com.google.devtools" ]
com.google.common; com.google.devtools;
1,129,621
@Test public void testGetObject() { addSome(); assertNotNull(subject.getObject("Meisen", 32, "Philipp")); assertNotNull(subject.getObject("Meisen", 32, "Tobias")); assertNotNull(subject.getObject("Meyer", 40, "Jörg")); assertNotNull(subject.getObject("Pehle", 30, "Jann")); assertNull(subject.getObject(...
void function() { addSome(); assertNotNull(subject.getObject(STR, 32, STR)); assertNotNull(subject.getObject(STR, 32, STR)); assertNotNull(subject.getObject("Meyer", 40, "Jörg")); assertNotNull(subject.getObject("Pehle", 30, "Jann")); assertNull(subject.getObject("Pehle", 32, "Jann")); assertEquals(new PersonMock(STR, ...
/** * Tests the implementation of * {@link NestedIndexedCollection#getObject(Object...)}. */
Tests the implementation of <code>NestedIndexedCollection#getObject(Object...)</code>
testGetObject
{ "repo_name": "pmeisen/dis-timeintervaldataanalyzer", "path": "test/net/meisen/dissertation/impl/indexes/TestNestedIndexedCollection.java", "license": "bsd-3-clause", "size": 5096 }
[ "net.meisen.dissertation.impl.indexes.mock.PersonMock", "org.junit.Assert" ]
import net.meisen.dissertation.impl.indexes.mock.PersonMock; import org.junit.Assert;
import net.meisen.dissertation.impl.indexes.mock.*; import org.junit.*;
[ "net.meisen.dissertation", "org.junit" ]
net.meisen.dissertation; org.junit;
1,163,520
public void drawIcon(Graphics graphics, org.eclipse.draw2d.geometry.Rectangle drawArea) { drawIcon(graphics, drawArea, drawArea); }
void function(Graphics graphics, org.eclipse.draw2d.geometry.Rectangle drawArea) { drawIcon(graphics, drawArea, drawArea); }
/** * Draw the icon image in the full figure bounds * @param graphics Graphics context * @param drawArea The area to draw the image in */
Draw the icon image in the full figure bounds
drawIcon
{ "repo_name": "archimatetool/archi", "path": "com.archimatetool.editor/src/com/archimatetool/editor/diagram/figures/IconicDelegate.java", "license": "mit", "size": 10144 }
[ "org.eclipse.draw2d.Graphics", "org.eclipse.swt.graphics.Rectangle" ]
import org.eclipse.draw2d.Graphics; import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.draw2d.*; import org.eclipse.swt.graphics.*;
[ "org.eclipse.draw2d", "org.eclipse.swt" ]
org.eclipse.draw2d; org.eclipse.swt;
1,873,418
private long appendSchemaChangeToTable(String userId, String tableId, List<String> current, List<ColumnChange> changes) throws IOException{ Long transactionId = tableTransactionDao.startTransaction(tableId, Long.parseLong(userId)); long version = tableRowTruthDao.appendSchemaChangeToTable(userId, tableId, curr...
long function(String userId, String tableId, List<String> current, List<ColumnChange> changes) throws IOException{ Long transactionId = tableTransactionDao.startTransaction(tableId, Long.parseLong(userId)); long version = tableRowTruthDao.appendSchemaChangeToTable(userId, tableId, current, changes, transactionId); Tabl...
/** * Helper to append a schema change with a transaction. * * @param userId * @param tableId * @param current * @param changes * @return * @throws IOException */
Helper to append a schema change with a transaction
appendSchemaChangeToTable
{ "repo_name": "xschildw/Synapse-Repository-Services", "path": "lib/jdomodels/src/test/java/org/sagebionetworks/repo/model/dbo/dao/table/TableRowTruthDAOImplTest.java", "license": "apache-2.0", "size": 23927 }
[ "java.io.IOException", "java.util.List", "org.junit.Assert", "org.sagebionetworks.repo.model.table.ColumnChange", "org.sagebionetworks.repo.model.table.TableChangeType", "org.sagebionetworks.repo.model.table.TableRowChange" ]
import java.io.IOException; import java.util.List; import org.junit.Assert; import org.sagebionetworks.repo.model.table.ColumnChange; import org.sagebionetworks.repo.model.table.TableChangeType; import org.sagebionetworks.repo.model.table.TableRowChange;
import java.io.*; import java.util.*; import org.junit.*; import org.sagebionetworks.repo.model.table.*;
[ "java.io", "java.util", "org.junit", "org.sagebionetworks.repo" ]
java.io; java.util; org.junit; org.sagebionetworks.repo;
984,675
public Serializer serializer() { return serializer; }
Serializer function() { return serializer; }
/** * Returns the serializer for map entries. * @return map entry serializer */
Returns the serializer for map entries
serializer
{ "repo_name": "planoAccess/clonedONOS", "path": "core/store/dist/src/main/java/org/onosproject/store/consistent/impl/DefaultAsyncConsistentMap.java", "license": "apache-2.0", "size": 19896 }
[ "org.onosproject.store.service.Serializer" ]
import org.onosproject.store.service.Serializer;
import org.onosproject.store.service.*;
[ "org.onosproject.store" ]
org.onosproject.store;
1,193,481
public static <T> Set<T> symDifference(final Set<T> setA, final Set<T> setB) { final Set<T> union = new TreeSet<>(setA); union.addAll(setB); final Set<T> intersection = new TreeSet<>(setA); intersection.retainAll(setB); union.removeAll(intersection); return u...
static <T> Set<T> function(final Set<T> setA, final Set<T> setB) { final Set<T> union = new TreeSet<>(setA); union.addAll(setB); final Set<T> intersection = new TreeSet<>(setA); intersection.retainAll(setB); union.removeAll(intersection); return union; }
/** * Get the elements of sets A,B that are not in their intersection. * @param <T> The generic type of the sets used. * @param setA one of two sets for the intersection * @param setB second of two sets for the intersection * @return (setA union setB) minus (setA union setB) */
Get the elements of sets A,B that are not in their intersection
symDifference
{ "repo_name": "EPICScotland/Broadwick", "path": "src/main/java/broadwick/math/SetOperations.java", "license": "apache-2.0", "size": 3641 }
[ "java.util.Set", "java.util.TreeSet" ]
import java.util.Set; import java.util.TreeSet;
import java.util.*;
[ "java.util" ]
java.util;
2,816,286
public int quantityDroppedWithBonus(int p_149679_1_, Random p_149679_2_) { if (p_149679_1_ > 0 && Item.getItemFromBlock(this) != this.getItemDropped(0, p_149679_2_, p_149679_1_)) { int var3 = p_149679_2_.nextInt(p_149679_1_ + 2) - 1; if (var3 < 0) { ...
int function(int p_149679_1_, Random p_149679_2_) { if (p_149679_1_ > 0 && Item.getItemFromBlock(this) != this.getItemDropped(0, p_149679_2_, p_149679_1_)) { int var3 = p_149679_2_.nextInt(p_149679_1_ + 2) - 1; if (var3 < 0) { var3 = 0; } return this.quantityDropped(p_149679_2_) * (var3 + 1); } else { return this.quant...
/** * Returns the usual quantity dropped by the block plus a bonus of 1 to 'i' (inclusive). */
Returns the usual quantity dropped by the block plus a bonus of 1 to 'i' (inclusive)
quantityDroppedWithBonus
{ "repo_name": "TheHecticByte/BananaJ1.7.10Beta", "path": "src/net/minecraft/Server1_7_10/block/BlockOre.java", "license": "gpl-3.0", "size": 3511 }
[ "java.util.Random", "net.minecraft.Server1_7_10" ]
import java.util.Random; import net.minecraft.Server1_7_10;
import java.util.*; import net.minecraft.*;
[ "java.util", "net.minecraft" ]
java.util; net.minecraft;
1,313,405
T onMethod(MethodDescription.InDefinedShape methodDescription); enum NoOp implements Visitor<TypeVariableSource> { INSTANCE; /** * {@inheritDoc}
T onMethod(MethodDescription.InDefinedShape methodDescription); enum NoOp implements Visitor<TypeVariableSource> { INSTANCE; /** * {@inheritDoc}
/** * Applies the visitor on a method. * * @param methodDescription The method onto which this visitor is applied. * @return The visitor's return value. */
Applies the visitor on a method
onMethod
{ "repo_name": "DALDEI/byte-buddy", "path": "byte-buddy-dep/src/main/java/net/bytebuddy/description/TypeVariableSource.java", "license": "apache-2.0", "size": 4174 }
[ "net.bytebuddy.description.method.MethodDescription" ]
import net.bytebuddy.description.method.MethodDescription;
import net.bytebuddy.description.method.*;
[ "net.bytebuddy.description" ]
net.bytebuddy.description;
590,582
public static <T> IgniteReducer<T, Collection<T>> objectsReducer() { return new IgniteReducer<T, Collection<T>>() { private final Collection<T> ret = new ConcurrentLinkedQueue<>();
static <T> IgniteReducer<T, Collection<T>> function() { return new IgniteReducer<T, Collection<T>>() { private final Collection<T> ret = new ConcurrentLinkedQueue<>();
/** * Gets reducer that aggregates items into collection. * * @param <T> Items type. * @return Reducer. */
Gets reducer that aggregates items into collection
objectsReducer
{ "repo_name": "DoudTechData/ignite", "path": "modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java", "license": "apache-2.0", "size": 59639 }
[ "java.util.Collection", "java.util.concurrent.ConcurrentLinkedQueue", "org.apache.ignite.lang.IgniteReducer" ]
import java.util.Collection; import java.util.concurrent.ConcurrentLinkedQueue; import org.apache.ignite.lang.IgniteReducer;
import java.util.*; import java.util.concurrent.*; import org.apache.ignite.lang.*;
[ "java.util", "org.apache.ignite" ]
java.util; org.apache.ignite;
50,068
public static void setSolrWriterQueueSize(int count, Configuration conf) { conf.setInt(SOLR_WRITER_QUEUE_SIZE, count); }
static void function(int count, Configuration conf) { conf.setInt(SOLR_WRITER_QUEUE_SIZE, count); }
/** * Set the maximum size of the the queue for documents to be written to the * index. */
Set the maximum size of the the queue for documents to be written to the index
setSolrWriterQueueSize
{ "repo_name": "bfs/solr-mapreduce-indexer", "path": "src/main/java/org/apache/solr/hadoop/SolrOutputFormat.java", "license": "apache-2.0", "size": 10297 }
[ "org.apache.hadoop.conf.Configuration" ]
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.conf.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
90,970
@Test public void testMRAsyncDiskService() throws Throwable { FileSystem localFileSystem = FileSystem.getLocal(new Configuration()); String[] vols = new String[]{TEST_ROOT_DIR + "/0", TEST_ROOT_DIR + "/1"}; MRAsyncDiskService service = new MRAsyncDiskService( localFileSystem, vols); ...
void function() throws Throwable { FileSystem localFileSystem = FileSystem.getLocal(new Configuration()); String[] vols = new String[]{TEST_ROOT_DIR + "/0", TEST_ROOT_DIR + "/1"}; MRAsyncDiskService service = new MRAsyncDiskService( localFileSystem, vols); String a = "a"; String b = "b"; String c = "b/c"; String d = "d...
/** * This test creates some directories and then removes them through * MRAsyncDiskService. */
This test creates some directories and then removes them through MRAsyncDiskService
testMRAsyncDiskService
{ "repo_name": "robzor92/hops", "path": "hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/util/TestMRAsyncDiskService.java", "license": "apache-2.0", "size": 11645 }
[ "java.io.File", "java.io.IOException", "org.apache.hadoop.conf.Configuration", "org.apache.hadoop.fs.FileSystem", "org.apache.hadoop.fs.Path", "org.apache.hadoop.mapreduce.util.MRAsyncDiskService", "org.junit.Assert" ]
import java.io.File; import java.io.IOException; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.mapreduce.util.MRAsyncDiskService; import org.junit.Assert;
import java.io.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.mapreduce.util.*; import org.junit.*;
[ "java.io", "org.apache.hadoop", "org.junit" ]
java.io; org.apache.hadoop; org.junit;
1,204,151
public FsStatus getFsStatus(final Path f) throws AccessControlException, FileNotFoundException, UnsupportedFileSystemException, IOException { if (f == null) { return defaultFS.getFsStatus(); }
FsStatus function(final Path f) throws AccessControlException, FileNotFoundException, UnsupportedFileSystemException, IOException { if (f == null) { return defaultFS.getFsStatus(); }
/** * Returns a status object describing the use and capacity of the * file system denoted by the Parh argument p. * If the file system has multiple partitions, the * use and capacity of the partition pointed to by the specified * path is reflected. * * @param f Path for which status should be obt...
Returns a status object describing the use and capacity of the file system denoted by the Parh argument p. If the file system has multiple partitions, the use and capacity of the partition pointed to by the specified path is reflected
getFsStatus
{ "repo_name": "linpawslitap/mds_scaling", "path": "hadoop/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileContext.java", "license": "bsd-3-clause", "size": 95921 }
[ "java.io.FileNotFoundException", "java.io.IOException", "org.apache.hadoop.security.AccessControlException" ]
import java.io.FileNotFoundException; import java.io.IOException; import org.apache.hadoop.security.AccessControlException;
import java.io.*; import org.apache.hadoop.security.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
2,737,113
public void checkSchemas(ValidationContext vctx) { // check for unique match to schema customization for (int i = 0; i < getChildren().size(); i++) { SchemaRootBase child = (SchemaRootBase)getChildren().get(i); if (child instanceof SchemaCustom) { Sch...
void function(ValidationContext vctx) { for (int i = 0; i < getChildren().size(); i++) { SchemaRootBase child = (SchemaRootBase)getChildren().get(i); if (child instanceof SchemaCustom) { SchemaCustom custom = (SchemaCustom)child; if (custom.getSchema() == null) { StringBuffer buff = new StringBuffer(STR); if (custom.ge...
/** * Recursively check that each schema customization has been matched to a schema. A warning is generated for any * customization without a matching schema. * * @param vctx */
Recursively check that each schema customization has been matched to a schema. A warning is generated for any customization without a matching schema
checkSchemas
{ "repo_name": "vkorbut/jibx", "path": "jibx/build/src/org/jibx/schema/codegen/custom/SchemasetCustom.java", "license": "bsd-3-clause", "size": 11280 }
[ "org.jibx.schema.validation.ValidationContext" ]
import org.jibx.schema.validation.ValidationContext;
import org.jibx.schema.validation.*;
[ "org.jibx.schema" ]
org.jibx.schema;
462,854
public void onDirectoryDelete(final File directory) { }
void function(final File directory) { }
/** * Directory deleted Event. * * @param directory The directory deleted */
Directory deleted Event
onDirectoryDelete
{ "repo_name": "sebastiansemmle/acio", "path": "src/main/java/org/apache/commons/io/monitor/FileAlterationListenerAdaptor.java", "license": "apache-2.0", "size": 2429 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
877,169
protected boolean canScroll(View v, boolean checkV, int dx, int x, int y) { if (v instanceof ViewGroup) { final ViewGroup group = (ViewGroup) v; final int scrollX = v.getScrollX(); final int scrollY = v.getScrollY(); final int count = group.getChildCount(); // Count backwards - let topmost views con...
boolean function(View v, boolean checkV, int dx, int x, int y) { if (v instanceof ViewGroup) { final ViewGroup group = (ViewGroup) v; final int scrollX = v.getScrollX(); final int scrollY = v.getScrollY(); final int count = group.getChildCount(); for (int i = count - 1; i >= 0; i--) { final View child = group.getChildA...
/** * Tests scrollability within child views of v given a delta of dx. * * @param v View to test for horizontal scrollability * @param checkV Whether the view v passed should itself be checked for scrollability (true), * or just its children (false). * @param dx Delta scrolled in pixels * @p...
Tests scrollability within child views of v given a delta of dx
canScroll
{ "repo_name": "GoToFly/hunteronlibrary", "path": "src/com/jeremyfeinstein/slidingmenu/lib/CustomViewAbove.java", "license": "apache-2.0", "size": 29944 }
[ "android.support.v4.view.ViewCompat", "android.view.View", "android.view.ViewGroup" ]
import android.support.v4.view.ViewCompat; import android.view.View; import android.view.ViewGroup;
import android.support.v4.view.*; import android.view.*;
[ "android.support", "android.view" ]
android.support; android.view;
1,271,833
HTableInterface getTable(String tableName) { if (LOG.isTraceEnabled()) { LOG.trace(String.format("Getting table from pool named '%s'", tableName)); } HTableInterface table = this.hTablePool.getTable(tableName); if (LOG.isTraceEnabled()) { LOG.trace(String.form...
HTableInterface getTable(String tableName) { if (LOG.isTraceEnabled()) { LOG.trace(String.format(STR, tableName)); } HTableInterface table = this.hTablePool.getTable(tableName); if (LOG.isTraceEnabled()) { LOG.trace(String.format(STR, tableName, table)); } return table; } /** * Return the table to the pool. This method...
/** * Get an {@link HTableInterface} from the internal table pool. This method is meant to be called * by a {@link Query}. * * @param tableName the name of a table to get from the pool * @return an instance from the internal table pool */
Get an <code>HTableInterface</code> from the internal table pool. This method is meant to be called by a <code>Query</code>
getTable
{ "repo_name": "jeffkole/odoop", "path": "hbase-filters/src/main/java/com/opower/hadoop/hbase/query/DefaultQueryPlanner.java", "license": "apache-2.0", "size": 2441 }
[ "org.apache.hadoop.hbase.client.HTableInterface" ]
import org.apache.hadoop.hbase.client.HTableInterface;
import org.apache.hadoop.hbase.client.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
428,800
@Override public void startup() { logger.info("XCPDInitiatingGateway::startup()"); try { XConfig xconf; xconf = XConfig.getInstance(); XConfigObject homeCommunity = xconf.getHomeCommunityConfig(); config = (XConfigActor) homeCommunity.getXConfigObj...
void function() { logger.info(STR); try { XConfig xconf; xconf = XConfig.getInstance(); XConfigObject homeCommunity = xconf.getHomeCommunityConfig(); config = (XConfigActor) homeCommunity.getXConfigObjectWithName("ig", XConfig.XCA_INITIATING_GATEWAY_TYPE); } catch (Exception ex) { logger.fatal(STR, ex); } this.ATNAlogS...
/** * This will be called during the deployment time of the service. * Irrespective of the service scope this method will be called */
This will be called during the deployment time of the service. Irrespective of the service scope this method will be called
startup
{ "repo_name": "kef/hieos", "path": "src/xcpd/src/com/vangent/hieos/services/xcpd/gateway/serviceimpl/XCPDInitiatingGateway.java", "license": "apache-2.0", "size": 5364 }
[ "com.vangent.hieos.xutil.atna.ATNAAuditEvent", "com.vangent.hieos.xutil.xconfig.XConfig", "com.vangent.hieos.xutil.xconfig.XConfigActor", "com.vangent.hieos.xutil.xconfig.XConfigObject" ]
import com.vangent.hieos.xutil.atna.ATNAAuditEvent; import com.vangent.hieos.xutil.xconfig.XConfig; import com.vangent.hieos.xutil.xconfig.XConfigActor; import com.vangent.hieos.xutil.xconfig.XConfigObject;
import com.vangent.hieos.xutil.atna.*; import com.vangent.hieos.xutil.xconfig.*;
[ "com.vangent.hieos" ]
com.vangent.hieos;
2,631,558
protected void build( KeyToolListRequest request, Commandline cli ) { addKeytoolCommandAndDefaultoptions( cli, "-list", request ); addArgIfTrue( cli, "-rfc", request.isRfc() ); }
void function( KeyToolListRequest request, Commandline cli ) { addKeytoolCommandAndDefaultoptions( cli, "-list", request ); addArgIfTrue( cli, "-rfc", request.isRfc() ); }
/** * Fill the commandline client for the given {@code request}. * * @param request the keytool request to consume * @param cli the commandline client to prepare */
Fill the commandline client for the given request
build
{ "repo_name": "ctomc/keytool-maven-plugin", "path": "keytool-api-1.5/src/main/java/org/codehaus/mojo/keytool/DefaultKeyToolCommandLineBuilder.java", "license": "apache-2.0", "size": 15474 }
[ "org.apache.maven.shared.utils.cli.Commandline", "org.codehaus.mojo.keytool.requests.KeyToolListRequest" ]
import org.apache.maven.shared.utils.cli.Commandline; import org.codehaus.mojo.keytool.requests.KeyToolListRequest;
import org.apache.maven.shared.utils.cli.*; import org.codehaus.mojo.keytool.requests.*;
[ "org.apache.maven", "org.codehaus.mojo" ]
org.apache.maven; org.codehaus.mojo;
467,219
boolean doRequiredTopoFilesExist(Map<String, Object> conf, String topologyId) throws IOException;
boolean doRequiredTopoFilesExist(Map<String, Object> conf, String topologyId) throws IOException;
/** * Sanity check if everything the topology needs is there for it to run. * * @param conf the config of the supervisor * @param topologyId the ID of the topology * @return true if everything is there, else false * * @throws IOException on any error */
Sanity check if everything the topology needs is there for it to run
doRequiredTopoFilesExist
{ "repo_name": "srdo/storm", "path": "storm-client/src/jvm/org/apache/storm/daemon/supervisor/IAdvancedFSOps.java", "license": "apache-2.0", "size": 7270 }
[ "java.io.IOException", "java.util.Map" ]
import java.io.IOException; import java.util.Map;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
481,741
public void setAnnotated(Annotated annotated) { }
void function(Annotated annotated) { }
/** * Sets the ServiceType annotated */
Sets the ServiceType annotated
setAnnotated
{ "repo_name": "dlitz/resin", "path": "modules/resin/src/com/caucho/remote/client/AbstractProtocolProxyFactory.java", "license": "gpl-2.0", "size": 1651 }
[ "javax.enterprise.inject.spi.Annotated" ]
import javax.enterprise.inject.spi.Annotated;
import javax.enterprise.inject.spi.*;
[ "javax.enterprise" ]
javax.enterprise;
1,506,904
protected static String join(final Collection<String> elements, final String joinSeparator) { String separator = ","; if (elements == null) { return null; } if (joinSeparator != null) { separator = joinSeparator; } StringBuilder buf...
static String function(final Collection<String> elements, final String joinSeparator) { String separator = ","; if (elements == null) { return null; } if (joinSeparator != null) { separator = joinSeparator; } StringBuilder buffer = new StringBuilder(); boolean isFirst = true; for (String element : elements) { if (!isFi...
/** * Joins elements of {@link Set} into a string, where each element is * separated by the provided separator. * * @param elements * The {@link Set} containing elements to join together. * @param joinSeparator * The character to be used for separating elements. ...
Joins elements of <code>Set</code> into a string, where each element is separated by the provided separator
join
{ "repo_name": "plumer/codana", "path": "tomcat_files/8.0.22/CorsFilter.java", "license": "mit", "size": 44538 }
[ "java.util.Collection" ]
import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
1,519,542
final Sequence sequence = this.context.sequence("load-sequence"); final BundleContext bundleContext = this.context.mock(BundleContext.class); final PackageAdmin packageAdmin = this.context.mock(PackageAdmin.class); final ExportedPackage ep = this.context.mock(ExportedPackage.class); fina...
final Sequence sequence = this.context.sequence(STR); final BundleContext bundleContext = this.context.mock(BundleContext.class); final PackageAdmin packageAdmin = this.context.mock(PackageAdmin.class); final ExportedPackage ep = this.context.mock(ExportedPackage.class); final Bundle bundle = this.context.mock(Bundle.c...
/** * This method tests the dynamic class loading through the package admin. * The returned class changes from map to array list. */
This method tests the dynamic class loading through the package admin. The returned class changes from map to array list
testLoading
{ "repo_name": "plutext/sling", "path": "bundles/commons/classloader/src/test/java/org/apache/sling/commons/classloader/impl/ClassLoadingTest.java", "license": "apache-2.0", "size": 4157 }
[ "org.jmock.Expectations", "org.jmock.Sequence", "org.junit.Assert", "org.osgi.framework.Bundle", "org.osgi.framework.BundleContext", "org.osgi.framework.ServiceListener", "org.osgi.service.packageadmin.ExportedPackage", "org.osgi.service.packageadmin.PackageAdmin" ]
import org.jmock.Expectations; import org.jmock.Sequence; import org.junit.Assert; import org.osgi.framework.Bundle; import org.osgi.framework.BundleContext; import org.osgi.framework.ServiceListener; import org.osgi.service.packageadmin.ExportedPackage; import org.osgi.service.packageadmin.PackageAdmin;
import org.jmock.*; import org.junit.*; import org.osgi.framework.*; import org.osgi.service.packageadmin.*;
[ "org.jmock", "org.junit", "org.osgi.framework", "org.osgi.service" ]
org.jmock; org.junit; org.osgi.framework; org.osgi.service;
299,168
public boolean rename(String newName) { String oldName = this.name; File oldDir = getRootDirectory(); this.name = newName; File newDir = getRootDirectory(); if (oldDir.renameTo(newDir)) { return true; } else { this.name = oldName; r...
boolean function(String newName) { String oldName = this.name; File oldDir = getRootDirectory(); this.name = newName; File newDir = getRootDirectory(); if (oldDir.renameTo(newDir)) { return true; } else { this.name = oldName; return false; } }
/** * Renames this instance including renaming the folder in the Instances directory to the new name provided. * * @param newName the new name of the Instance * @return true if the Instances folder was renamed and false if it failed */
Renames this instance including renaming the folder in the Instances directory to the new name provided
rename
{ "repo_name": "LexMinecraft/Launcher", "path": "src/main/java/com/atlauncher/data/Instance.java", "license": "gpl-3.0", "size": 54157 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
1,211,540
public HttpPipeline getHttpPipeline() { return dataLakeFileSystemAsyncClient.getHttpPipeline(); } /** * Creates a new file system within a storage account. If a file system with the same name already exists, the * operation fails. For more information, see the * <a href="https://doc...
HttpPipeline function() { return dataLakeFileSystemAsyncClient.getHttpPipeline(); } /** * Creates a new file system within a storage account. If a file system with the same name already exists, the * operation fails. For more information, see the * <a href="https: * * <p><strong>Code Samples</strong></p> * * {@codesnip...
/** * Gets the {@link HttpPipeline} powering this client. * * @return The pipeline. */
Gets the <code>HttpPipeline</code> powering this client
getHttpPipeline
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/storage/azure-storage-file-datalake/src/main/java/com/azure/storage/file/datalake/DataLakeFileSystemClient.java", "license": "mit", "size": 32966 }
[ "com.azure.core.http.HttpPipeline" ]
import com.azure.core.http.HttpPipeline;
import com.azure.core.http.*;
[ "com.azure.core" ]
com.azure.core;
240,748
TaskExecution startTaskExecution(long executionId, String taskName, Date startTime, List<String> arguments, String externalExecutionId);
TaskExecution startTaskExecution(long executionId, String taskName, Date startTime, List<String> arguments, String externalExecutionId);
/** * Update and existing {@link TaskExecution} to mark it as started. * * @param executionId the id of the taskExecution to be updated. * @param taskName the name that associated with the task execution. * @param startTime the time task began. * @param arguments list of key/value pairs that configure the ...
Update and existing <code>TaskExecution</code> to mark it as started
startTaskExecution
{ "repo_name": "trisberg/spring-cloud-task", "path": "spring-cloud-task-core/src/main/java/org/springframework/cloud/task/repository/dao/TaskExecutionDao.java", "license": "apache-2.0", "size": 7541 }
[ "java.util.Date", "java.util.List", "org.springframework.cloud.task.repository.TaskExecution" ]
import java.util.Date; import java.util.List; import org.springframework.cloud.task.repository.TaskExecution;
import java.util.*; import org.springframework.cloud.task.repository.*;
[ "java.util", "org.springframework.cloud" ]
java.util; org.springframework.cloud;
2,634,090
Update withAzureCertificateFromFile(String name, File certificateFile) throws IOException;
Update withAzureCertificateFromFile(String name, File certificateFile) throws IOException;
/** * Specifies that azure certificate authentication type will be used and certificate to use for Azure * authentication. * * @param name name of certificate * @param certificateFile public Base64-encoded certificate file * @return the next ...
Specifies that azure certificate authentication type will be used and certificate to use for Azure authentication
withAzureCertificateFromFile
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-network/src/main/java/com/azure/resourcemanager/network/models/PointToSiteConfiguration.java", "license": "mit", "size": 9692 }
[ "java.io.File", "java.io.IOException" ]
import java.io.File; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
231,698
this.parent = getParent(); final Display display = parent.getDisplay(); this.shell = new Shell(parent, SWT.DIALOG_TRIM | SWT.RESIZE | SWT.MIN | SWT.MAX); props.setLook(shell); setShellImage(shell, this.input);
this.parent = getParent(); final Display display = parent.getDisplay(); this.shell = new Shell(parent, SWT.DIALOG_TRIM SWT.RESIZE SWT.MIN SWT.MAX); props.setLook(shell); setShellImage(shell, this.input);
/** * Opens a step dialog window. * * @return the (potentially new) name of the step */
Opens a step dialog window
open
{ "repo_name": "latinojoel/pdi-apple-pushnotifications", "path": "src/main/java/com/latinojoel/di/trans/steps/pushnotifications/apple/PushNotificationDialog.java", "license": "gpl-3.0", "size": 51031 }
[ "org.eclipse.swt.widgets.Display", "org.eclipse.swt.widgets.Shell" ]
import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.*;
[ "org.eclipse.swt" ]
org.eclipse.swt;
511,800
public synchronized float getTempoAt(long tick) { if (dirty) reco(); SortedMap<Long, MyTempoEvent> head = treeSet.headMap(tick + 1); if (head.isEmpty()) { return 120.0f; } MyTempoEvent ev = (head.get(head.lastKey())); return (float) ev.bpm; }
synchronized float function(long tick) { if (dirty) reco(); SortedMap<Long, MyTempoEvent> head = treeSet.headMap(tick + 1); if (head.isEmpty()) { return 120.0f; } MyTempoEvent ev = (head.get(head.lastKey())); return (float) ev.bpm; }
/** * * Get tempo at tick. * * @param tick * @return */
Get tempo at tick
getTempoAt
{ "repo_name": "hajdam/frinthesia", "path": "modules/frinika-sequencer/src/main/java/com/frinika/sequencer/model/tempo/TempoList.java", "license": "gpl-2.0", "size": 8047 }
[ "java.util.SortedMap" ]
import java.util.SortedMap;
import java.util.*;
[ "java.util" ]
java.util;
379,330
EClass getDomainmodel();
EClass getDomainmodel();
/** * Returns the meta object for class '{@link org.example.domainmodel.domainmodel.Domainmodel <em>Domainmodel</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>Domainmodel</em>'. * @see org.example.domainmodel.domainmodel.Domainmodel * @generated *...
Returns the meta object for class '<code>org.example.domainmodel.domainmodel.Domainmodel Domainmodel</code>'.
getDomainmodel
{ "repo_name": "adrian-herscu/experiments", "path": "language-workbenches/xtext/org.example.domainmodel/src-gen/org/example/domainmodel/domainmodel/DomainmodelPackage.java", "license": "apache-2.0", "size": 22388 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
306,951
public void writeToParentChildBWC(StreamOutput out, QueryBuilder query, String parentChildPath) throws IOException { assert(out.getVersion().before(Version.V_5_5_0)) : "invalid output version, must be < " + Version.V_5_5_0.toString(); writeToBWC(out, query, null, parentChildPath); }
void function(StreamOutput out, QueryBuilder query, String parentChildPath) throws IOException { assert(out.getVersion().before(Version.V_5_5_0)) : STR + Version.V_5_5_0.toString(); writeToBWC(out, query, null, parentChildPath); }
/** * BWC serialization for parent/child {@link InnerHitBuilder}. * Should only be used to send hasParent or hasChild inner hits to nodes pre 5.5. */
BWC serialization for parent/child <code>InnerHitBuilder</code>. Should only be used to send hasParent or hasChild inner hits to nodes pre 5.5
writeToParentChildBWC
{ "repo_name": "qwerty4030/elasticsearch", "path": "server/src/main/java/org/elasticsearch/index/query/InnerHitBuilder.java", "license": "apache-2.0", "size": 20485 }
[ "java.io.IOException", "org.elasticsearch.Version", "org.elasticsearch.common.io.stream.StreamOutput" ]
import java.io.IOException; import org.elasticsearch.Version; import org.elasticsearch.common.io.stream.StreamOutput;
import java.io.*; import org.elasticsearch.*; import org.elasticsearch.common.io.stream.*;
[ "java.io", "org.elasticsearch", "org.elasticsearch.common" ]
java.io; org.elasticsearch; org.elasticsearch.common;
1,795,975
public final AuthenticationConfiguration allowSaslMechanisms(String... names) { return names == null || names.length == 0 ? new FilterSaslMechanismAuthenticationConfiguration(this, true, Collections.<String>emptySet()) : new FilterSaslMechanismAuthenticationConfiguration(this, true, new HashSet<String>(Arra...
final AuthenticationConfiguration function(String... names) { return names == null names.length == 0 ? new FilterSaslMechanismAuthenticationConfiguration(this, true, Collections.<String>emptySet()) : new FilterSaslMechanismAuthenticationConfiguration(this, true, new HashSet<String>(Arrays.asList(names))); }
/** * Create a new configuration which is the same as this configuration, but which sets the allowed mechanism set * to only include the given named mechanisms. * * @param names the mechanism names * @return the new configuration */
Create a new configuration which is the same as this configuration, but which sets the allowed mechanism set to only include the given named mechanisms
allowSaslMechanisms
{ "repo_name": "sguilhen/wildfly-elytron", "path": "src/main/java/org/wildfly/security/auth/client/AuthenticationConfiguration.java", "license": "apache-2.0", "size": 36415 }
[ "java.util.Arrays", "java.util.Collections", "java.util.HashSet" ]
import java.util.Arrays; import java.util.Collections; import java.util.HashSet;
import java.util.*;
[ "java.util" ]
java.util;
14,396
public List<Argument> arguments() { return this.arguments; }
List<Argument> function() { return this.arguments; }
/** * Get the collection of override arguments to be used when executing the run. * * @return the arguments value */
Get the collection of override arguments to be used when executing the run
arguments
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/containerregistry/mgmt-v2019_04_01/src/main/java/com/microsoft/azure/management/containerregistry/v2019_04_01/DockerBuildRequest.java", "license": "mit", "size": 9188 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
648,059
public static int frequency(Iterator<?> iterator, @Nullable Object element) { return size(filter(iterator, equalTo(element))); }
static int function(Iterator<?> iterator, @Nullable Object element) { return size(filter(iterator, equalTo(element))); }
/** * Returns the number of elements in the specified iterator that equal the * specified object. The iterator will be left exhausted: its * {@code hasNext()} method will return {@code false}. * * @see Collections#frequency */
Returns the number of elements in the specified iterator that equal the specified object. The iterator will be left exhausted: its hasNext() method will return false
frequency
{ "repo_name": "npvincent/guava", "path": "guava/src/com/google/common/collect/Iterators.java", "license": "apache-2.0", "size": 45470 }
[ "com.google.common.base.Predicates", "java.util.Iterator", "javax.annotation.Nullable" ]
import com.google.common.base.Predicates; import java.util.Iterator; import javax.annotation.Nullable;
import com.google.common.base.*; import java.util.*; import javax.annotation.*;
[ "com.google.common", "java.util", "javax.annotation" ]
com.google.common; java.util; javax.annotation;
1,669,806
@Test(timeOut = 200000) public void testDeadLetterWithoutConsumerReceiveImmediately() throws PulsarClientException, InterruptedException { final String topic = "persistent://my-property/my-ns/dead-letter-topic-without-consumer-receive-immediately"; Consumer<byte[]> consumer = pulsarClient.newCo...
@Test(timeOut = 200000) void function() throws PulsarClientException, InterruptedException { final String topic = STRmy-subscriptionSTRa message").getBytes()); Thread.sleep(5000L); Message<byte[]> msg = consumer.receive(1, TimeUnit.SECONDS); assertNotNull(msg); }
/** * issue https://github.com/apache/pulsar/issues/3077 */
issue HREF
testDeadLetterWithoutConsumerReceiveImmediately
{ "repo_name": "merlimat/pulsar", "path": "pulsar-broker/src/test/java/org/apache/pulsar/client/api/DeadLetterTopicTest.java", "license": "apache-2.0", "size": 12520 }
[ "java.util.concurrent.TimeUnit", "org.testng.Assert", "org.testng.annotations.Test" ]
import java.util.concurrent.TimeUnit; import org.testng.Assert; import org.testng.annotations.Test;
import java.util.concurrent.*; import org.testng.*; import org.testng.annotations.*;
[ "java.util", "org.testng", "org.testng.annotations" ]
java.util; org.testng; org.testng.annotations;
548,264
public static void importContacts(Activity activity, List<Contact> contactsToImport){ Contact currentContact; for(int i = 0 ; i < contactsToImport.size() ; i++) { currentContact = contactsToImport.get(i); Party newParty = new Party(currentContact.name); if (curre...
static void function(Activity activity, List<Contact> contactsToImport){ Contact currentContact; for(int i = 0 ; i < contactsToImport.size() ; i++) { currentContact = contactsToImport.get(i); Party newParty = new Party(currentContact.name); if (currentContact.hasPhoneNum) { String[] contactSelection = {ContactsContract...
/** * This method reads ContentProvider for Contacts and creates respective Parties and saves it to * the database. <Note>This method should be called in the background thread</Note> * @param activity * @param contactsToImport */
This method reads ContentProvider for Contacts and creates respective Parties and saves it to the database. This method should be called in the background thread
importContacts
{ "repo_name": "ndhunju/dailyJournal", "path": "app/src/main/java/com/ndhunju/dailyjournal/service/ImportContacts.java", "license": "gpl-2.0", "size": 5712 }
[ "android.app.Activity", "android.content.ContentUris", "android.database.Cursor", "android.graphics.Bitmap", "android.net.Uri", "android.provider.ContactsContract", "android.provider.MediaStore", "com.ndhunju.dailyjournal.model.Party", "com.ndhunju.dailyjournal.util.UtilsFile", "java.io.File", "...
import android.app.Activity; import android.content.ContentUris; import android.database.Cursor; import android.graphics.Bitmap; import android.net.Uri; import android.provider.ContactsContract; import android.provider.MediaStore; import com.ndhunju.dailyjournal.model.Party; import com.ndhunju.dailyjournal.util.UtilsFi...
import android.app.*; import android.content.*; import android.database.*; import android.graphics.*; import android.net.*; import android.provider.*; import com.ndhunju.dailyjournal.model.*; import com.ndhunju.dailyjournal.util.*; import java.io.*; import java.util.*;
[ "android.app", "android.content", "android.database", "android.graphics", "android.net", "android.provider", "com.ndhunju.dailyjournal", "java.io", "java.util" ]
android.app; android.content; android.database; android.graphics; android.net; android.provider; com.ndhunju.dailyjournal; java.io; java.util;
1,169,687
public void generateHaving(CharBuffer cb) { generateWhere(cb); }
void function(CharBuffer cb) { generateWhere(cb); }
/** * Generates the having expression. */
Generates the having expression
generateHaving
{ "repo_name": "christianchristensen/resin", "path": "modules/resin/src/com/caucho/amber/expr/BooleanColumnExpr.java", "license": "gpl-2.0", "size": 4195 }
[ "com.caucho.util.CharBuffer" ]
import com.caucho.util.CharBuffer;
import com.caucho.util.*;
[ "com.caucho.util" ]
com.caucho.util;
2,472,706
public void testMoveDirectoryDestinationRootSourceMissingPartially() throws Exception { create(igfsSecondary, paths(DIR, SUBDIR, SUBSUBDIR), null); create(igfs, paths(DIR), null); igfs.rename(SUBSUBDIR, new IgfsPath()); checkExist(igfs, SUBDIR); checkExist(igfs, igfsSeconda...
void function() throws Exception { create(igfsSecondary, paths(DIR, SUBDIR, SUBSUBDIR), null); create(igfs, paths(DIR), null); igfs.rename(SUBSUBDIR, new IgfsPath()); checkExist(igfs, SUBDIR); checkExist(igfs, igfsSecondary, new IgfsPath("/" + SUBSUBDIR.name())); checkNotExist(igfs, igfsSecondary, SUBSUBDIR); }
/** * Test directory move when destination is the root and source is missing partially. * * @throws Exception If failed. */
Test directory move when destination is the root and source is missing partially
testMoveDirectoryDestinationRootSourceMissingPartially
{ "repo_name": "dlnufox/ignite", "path": "modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsDualAbstractSelfTest.java", "license": "apache-2.0", "size": 55550 }
[ "org.apache.ignite.igfs.IgfsPath" ]
import org.apache.ignite.igfs.IgfsPath;
import org.apache.ignite.igfs.*;
[ "org.apache.ignite" ]
org.apache.ignite;
1,408,534
public com.google.ads.interactivemedia.v3.api.AdsLoader getAdsLoader() { return adsLoader; }
com.google.ads.interactivemedia.v3.api.AdsLoader function() { return adsLoader; }
/** * Returns the underlying {@code com.google.ads.interactivemedia.v3.api.AdsLoader} wrapped by * this instance. */
Returns the underlying com.google.ads.interactivemedia.v3.api.AdsLoader wrapped by this instance
getAdsLoader
{ "repo_name": "superbderrick/ExoPlayer", "path": "extensions/ima/src/main/java/com/google/android/exoplayer2/ext/ima/ImaAdsLoader.java", "license": "apache-2.0", "size": 54459 }
[ "com.google.android.exoplayer2.source.ads.AdsLoader" ]
import com.google.android.exoplayer2.source.ads.AdsLoader;
import com.google.android.exoplayer2.source.ads.*;
[ "com.google.android" ]
com.google.android;
1,263,127
private final <T extends Annotation> T annotationOf(final Class<T> clazz) { return (T)getAnnotations().get(clazz); }
final <T extends Annotation> T function(final Class<T> clazz) { return (T)getAnnotations().get(clazz); }
/** * Gets the annotation of the specified type. * @param clazz The annotation type. * @return The annotation or null if not applicable. */
Gets the annotation of the specified type
annotationOf
{ "repo_name": "mhurne/aws-sdk-java", "path": "aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/datamodeling/DynamoDBAnnotationRegistry.java", "license": "apache-2.0", "size": 15266 }
[ "java.lang.annotation.Annotation" ]
import java.lang.annotation.Annotation;
import java.lang.annotation.*;
[ "java.lang" ]
java.lang;
2,104,269
public static void main( String[] args ) { new Regression_134309( ); } public Regression_134309( ) { final PluginSettings ps = PluginSettings.instance( ); try { //ULocale.setDefault( new ULocale( "ar_YE" ) ); dRenderer = ps.getDevice( "dv.JPG" );//$NON-NLS-1$ } catch ( ChartException ...
static void function( String[] args ) { new Regression_134309( ); } public Regression_134309( ) { final PluginSettings ps = PluginSettings.instance( ); try { dRenderer = ps.getDevice( STR ); } catch ( ChartException ex ) { ex.printStackTrace( ); } cm = createBarChart( ); BufferedImage img = new BufferedImage( 500, 500,...
/** * execute application * * @param args */
execute application
main
{ "repo_name": "sguan-actuate/birt", "path": "testsuites/org.eclipse.birt.report.tests.chart/src/org/eclipse/birt/report/tests/chart/regression/Regression_134309.java", "license": "epl-1.0", "size": 9010 }
[ "com.ibm.icu.util.ULocale", "java.awt.Graphics", "java.awt.Graphics2D", "java.awt.image.BufferedImage", "org.eclipse.birt.chart.device.IDeviceRenderer", "org.eclipse.birt.chart.exception.ChartException", "org.eclipse.birt.chart.factory.Generator", "org.eclipse.birt.chart.factory.RunTimeContext", "or...
import com.ibm.icu.util.ULocale; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.image.BufferedImage; import org.eclipse.birt.chart.device.IDeviceRenderer; import org.eclipse.birt.chart.exception.ChartException; import org.eclipse.birt.chart.factory.Generator; import org.eclipse.birt.chart.factory...
import com.ibm.icu.util.*; import java.awt.*; import java.awt.image.*; import org.eclipse.birt.chart.device.*; import org.eclipse.birt.chart.exception.*; import org.eclipse.birt.chart.factory.*; import org.eclipse.birt.chart.model.attribute.*; import org.eclipse.birt.chart.model.attribute.impl.*; import org.eclipse.bir...
[ "com.ibm.icu", "java.awt", "org.eclipse.birt" ]
com.ibm.icu; java.awt; org.eclipse.birt;
1,154,258
protected void onModified() throws IOException { owner.save(); }
void function() throws IOException { owner.save(); }
/** * Called when a list is mutated. */
Called when a list is mutated
onModified
{ "repo_name": "vivek/hudson", "path": "core/src/main/java/hudson/util/PersistedList.java", "license": "mit", "size": 6442 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,387,604
private int comparePreviousRecord (int slot, LeafControlRow leaf, DataValueDescriptor [] rows, DataValueDescriptor [] oldRows) throws StandardException { Re...
int function (int slot, LeafControlRow leaf, DataValueDescriptor [] rows, DataValueDescriptor [] oldRows) throws StandardException { RecordHandle rh = null; boolean newLeaf = false; LeafControlRow originalLeaf = leaf; while (leaf != null) { if (slot == 0) { LeafControlRow oldLeaf = leaf; try { leaf = (LeafControlRow) l...
/** * Compares the oldrow with the one at 'slot' or the one left to it. * If the slot is first slot it will move to the left sibiling of * the 'leaf' and will compare with the record from the last slot. * @param slot slot number to start with * @param leaf LeafControlRow of the current page ...
Compares the oldrow with the one at 'slot' or the one left to it. If the slot is first slot it will move to the left sibiling of the 'leaf' and will compare with the record from the last slot
comparePreviousRecord
{ "repo_name": "lpxz/grail-derby104", "path": "java/engine/org/apache/derby/impl/store/access/btree/BTreeController.java", "license": "apache-2.0", "size": 66807 }
[ "org.apache.derby.iapi.error.StandardException", "org.apache.derby.iapi.store.raw.RecordHandle", "org.apache.derby.iapi.types.DataValueDescriptor" ]
import org.apache.derby.iapi.error.StandardException; import org.apache.derby.iapi.store.raw.RecordHandle; import org.apache.derby.iapi.types.DataValueDescriptor;
import org.apache.derby.iapi.error.*; import org.apache.derby.iapi.store.raw.*; import org.apache.derby.iapi.types.*;
[ "org.apache.derby" ]
org.apache.derby;
774,972
@WebMethod(operationName = "updateRoleMember") @WebResult(name = "roleMember") @CacheEvict(value={Role.Cache.NAME, Permission.Cache.NAME, Responsibility.Cache.NAME, RoleMembership.Cache.NAME, RoleMember.Cache.NAME, DelegateMember.Cache.NAME, RoleResponsibility.Cache.NAME, DelegateType.Cache.NAME }, allEntri...
@WebMethod(operationName = STR) @WebResult(name = STR) @CacheEvict(value={Role.Cache.NAME, Permission.Cache.NAME, Responsibility.Cache.NAME, RoleMembership.Cache.NAME, RoleMember.Cache.NAME, DelegateMember.Cache.NAME, RoleResponsibility.Cache.NAME, DelegateType.Cache.NAME }, allEntries = true) RoleMember updateRoleMemb...
/** * Updates the given roleMember to the values in the passed in roleMember * * @param roleMember the new RoleMember to save. * @return RoleMember as updated. * @throws RiceIllegalArgumentException if roleMember is null. * @throws RiceIllegalStateException if roleMember does not yet exist. ...
Updates the given roleMember to the values in the passed in roleMember
updateRoleMember
{ "repo_name": "ricepanda/rice-git3", "path": "rice-middleware/kim/kim-api/src/main/java/org/kuali/rice/kim/api/role/RoleService.java", "license": "apache-2.0", "size": 48854 }
[ "javax.jws.WebMethod", "javax.jws.WebParam", "javax.jws.WebResult", "org.kuali.rice.core.api.exception.RiceIllegalArgumentException", "org.kuali.rice.core.api.exception.RiceIllegalStateException", "org.kuali.rice.kim.api.common.delegate.DelegateMember", "org.kuali.rice.kim.api.common.delegate.DelegateTy...
import javax.jws.WebMethod; import javax.jws.WebParam; import javax.jws.WebResult; import org.kuali.rice.core.api.exception.RiceIllegalArgumentException; import org.kuali.rice.core.api.exception.RiceIllegalStateException; import org.kuali.rice.kim.api.common.delegate.DelegateMember; import org.kuali.rice.kim.api.common...
import javax.jws.*; import org.kuali.rice.core.api.exception.*; import org.kuali.rice.kim.api.common.delegate.*; import org.kuali.rice.kim.api.permission.*; import org.kuali.rice.kim.api.responsibility.*; import org.springframework.cache.annotation.*;
[ "javax.jws", "org.kuali.rice", "org.springframework.cache" ]
javax.jws; org.kuali.rice; org.springframework.cache;
2,794,513
public ServiceFuture<OperationListResultInner> listAsync(final ServiceCallback<OperationListResultInner> serviceCallback) { return ServiceFuture.fromResponse(listWithServiceResponseAsync(), serviceCallback); }
ServiceFuture<OperationListResultInner> function(final ServiceCallback<OperationListResultInner> serviceCallback) { return ServiceFuture.fromResponse(listWithServiceResponseAsync(), serviceCallback); }
/** * List the operations for Azure Container Instance service. * * @param serviceCallback the async ServiceCallback to handle successful and failed responses. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the {@link ServiceFuture} object */
List the operations for Azure Container Instance service
listAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/containerinstance/mgmt-v2018_04_01/src/main/java/com/microsoft/azure/management/containerinstance/v2018_04_01/implementation/OperationsInner.java", "license": "mit", "size": 5637 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
136,692
public SDepartment getSDepartmentById(Integer departmentId) { SDepartment department = (SDepartment) getSqlMapClientTemplate().queryForObject("s_department.getSDepartmentById", departmentId); return department; }
SDepartment function(Integer departmentId) { SDepartment department = (SDepartment) getSqlMapClientTemplate().queryForObject(STR, departmentId); return department; }
/** * This method was generated by Abator for iBATIS. * This method corresponds to the database table s_department * * @abatorgenerated Tue Apr 23 17:36:30 CST 2013 */
This method was generated by Abator for iBATIS. This method corresponds to the database table s_department
getSDepartmentById
{ "repo_name": "goulin2k/salesManager", "path": "salesManagerServer/src/com/sales/dao/impl/SDepartmentDAOImpl.java", "license": "gpl-2.0", "size": 3002 }
[ "com.sales.model.SDepartment" ]
import com.sales.model.SDepartment;
import com.sales.model.*;
[ "com.sales.model" ]
com.sales.model;
1,141,100
private final void __loadStream(final Path f, final ArrayList<ArrayList<Number[]>> list, final boolean canGrow) throws Throwable { ArrayList<Number[]> current; int index, i, end1, start2, end2, len; double d; char ch; String s; try { try (final InputStream is = f...
final void function(final Path f, final ArrayList<ArrayList<Number[]>> list, final boolean canGrow) throws Throwable { ArrayList<Number[]> current; int index, i, end1, start2, end2, len; double d; char ch; String s; try { try (final InputStream is = f.getFileSystem().provider() .newInputStream(f)) { try (final InputStr...
/** * load a stream * * @param f * the file * @param list * the list * @param canGrow * can the list grow? * @throws Throwable * if i/o fails */
load a stream
__loadStream
{ "repo_name": "optimizationBenchmarking/evaluator-base", "path": "src/main/java/org/optimizationBenchmarking/evaluator/io/impl/bbob/_BBOBHandler.java", "license": "gpl-3.0", "size": 18819 }
[ "java.io.BufferedReader", "java.io.InputStream", "java.io.InputStreamReader", "java.nio.file.Path", "java.util.ArrayList", "java.util.logging.Level" ]
import java.io.BufferedReader; import java.io.InputStream; import java.io.InputStreamReader; import java.nio.file.Path; import java.util.ArrayList; import java.util.logging.Level;
import java.io.*; import java.nio.file.*; import java.util.*; import java.util.logging.*;
[ "java.io", "java.nio", "java.util" ]
java.io; java.nio; java.util;
2,092,577
@Override public void readExternal(final ObjectInput in) throws IOException { // read the base class final double t = readBaseExternal(in); if (currentState == null) { currentDerivative = null; } else { currentDerivative = new double[currentState.length]; for (int i = ...
void function(final ObjectInput in) throws IOException { final double t = readBaseExternal(in); if (currentState == null) { currentDerivative = null; } else { currentDerivative = new double[currentState.length]; for (int i = 0; i < currentDerivative.length; ++i) { currentDerivative[i] = in.readDouble(); } } setInterpol...
/** Read the instance from an input channel. * @param in input channel * @exception IOException if the instance cannot be read */
Read the instance from an input channel
readExternal
{ "repo_name": "SpoonLabs/astor", "path": "examples/math_57/src/main/java/org/apache/commons/math/ode/sampling/DummyStepInterpolator.java", "license": "gpl-2.0", "size": 5240 }
[ "java.io.IOException", "java.io.ObjectInput" ]
import java.io.IOException; import java.io.ObjectInput;
import java.io.*;
[ "java.io" ]
java.io;
2,760,504
private synchronized void unRegisterConnection(Socket socket) { openConnections.remove(socket); }
synchronized void function(Socket socket) { openConnections.remove(socket); }
/** * Registers that a connection has been closed * * @param socket * the {@link Socket} for the connection. */
Registers that a connection has been closed
unRegisterConnection
{ "repo_name": "mfietz/AntennaPod", "path": "app/src/androidTest/java/de/test/antennapod/util/service/download/NanoHTTPD.java", "license": "mit", "size": 53580 }
[ "java.net.Socket" ]
import java.net.Socket;
import java.net.*;
[ "java.net" ]
java.net;
2,177,690
public static ResourceResolver getInstance( Attr uri, String baseURI, List<ResourceResolver> individualResolvers, boolean secureValidation ) throws ResourceResolverException { if (log.isLoggable(java.util.logging.Level.FINE)) { log.log(java.util.logging.Level.FINE, "I...
static ResourceResolver function( Attr uri, String baseURI, List<ResourceResolver> individualResolvers, boolean secureValidation ) throws ResourceResolverException { if (log.isLoggable(java.util.logging.Level.FINE)) { log.log(java.util.logging.Level.FINE, STR + (individualResolvers == null ? 0 : individualResolvers.siz...
/** * Method getInstance * * @param uri * @param baseURI * @param individualResolvers * @param secureValidation * @return the instance * * @throws ResourceResolverException */
Method getInstance
getInstance
{ "repo_name": "itgeeker/jdk", "path": "src/com/sun/org/apache/xml/internal/security/utils/resolver/ResourceResolver.java", "license": "apache-2.0", "size": 13904 }
[ "java.util.List", "org.w3c.dom.Attr" ]
import java.util.List; import org.w3c.dom.Attr;
import java.util.*; import org.w3c.dom.*;
[ "java.util", "org.w3c.dom" ]
java.util; org.w3c.dom;
2,807,935
private String[] extractAndDecodeHeader(String header, HttpServletRequest request) throws IOException { byte[] base64Token = header.substring(6).getBytes("UTF-8"); byte[] decoded; try { decoded = Base64.getDecoder().decode(base64Token); } catch (IllegalArgumentException e) { throw new BadCredenti...
String[] function(String header, HttpServletRequest request) throws IOException { byte[] base64Token = header.substring(6).getBytes("UTF-8"); byte[] decoded; try { decoded = Base64.getDecoder().decode(base64Token); } catch (IllegalArgumentException e) { throw new BadCredentialsException( STR); } String token = new Stri...
/** * Decodes the header into a username and password. * * @throws BadCredentialsException if the Basic header is not present or is not valid * Base64 */
Decodes the header into a username and password
extractAndDecodeHeader
{ "repo_name": "thomasdarimont/spring-security", "path": "web/src/main/java/org/springframework/security/web/authentication/www/BasicAuthenticationFilter.java", "license": "apache-2.0", "size": 12192 }
[ "java.io.IOException", "java.util.Base64", "javax.servlet.http.HttpServletRequest", "org.springframework.security.authentication.BadCredentialsException" ]
import java.io.IOException; import java.util.Base64; import javax.servlet.http.HttpServletRequest; import org.springframework.security.authentication.BadCredentialsException;
import java.io.*; import java.util.*; import javax.servlet.http.*; import org.springframework.security.authentication.*;
[ "java.io", "java.util", "javax.servlet", "org.springframework.security" ]
java.io; java.util; javax.servlet; org.springframework.security;
2,348,792
@ServiceMethod(returns = ReturnType.SINGLE) public SyncPoller< PollResult<ManagedBackupShortTermRetentionPolicyInner>, ManagedBackupShortTermRetentionPolicyInner> beginUpdate( String resourceGroupName, String managedInstanceName, String databaseName, ...
@ServiceMethod(returns = ReturnType.SINGLE) SyncPoller< PollResult<ManagedBackupShortTermRetentionPolicyInner>, ManagedBackupShortTermRetentionPolicyInner> function( String resourceGroupName, String managedInstanceName, String databaseName, ManagedShortTermRetentionPolicyName policyName, Integer retentionDays) { return...
/** * Updates a managed database's short term retention policy. * * @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value * from the Azure Resource Manager API or the portal. * @param managedInstanceName The name of the managed instanc...
Updates a managed database's short term retention policy
beginUpdate
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-sql/src/main/java/com/azure/resourcemanager/sql/implementation/ManagedBackupShortTermRetentionPoliciesClientImpl.java", "license": "mit", "size": 74712 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.management.polling.PollResult", "com.azure.core.util.polling.SyncPoller", "com.azure.resourcemanager.sql.fluent.models.ManagedBackupShortTermRetentionPolicyInner", "com.azure.resourcemanager.sql.models.Manag...
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.management.polling.PollResult; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.sql.fluent.models.ManagedBackupShortTermRetentionPolicyInner; import com.azure.resourcemanager...
import com.azure.core.annotation.*; import com.azure.core.management.polling.*; import com.azure.core.util.polling.*; import com.azure.resourcemanager.sql.fluent.models.*; import com.azure.resourcemanager.sql.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
2,454,674
Collection<RegionMapping> getMappings() { return mappings; }
Collection<RegionMapping> getMappings() { return mappings; }
/** * For testing only */
For testing only
getMappings
{ "repo_name": "smanvi-pivotal/geode", "path": "geode-connectors/src/main/java/org/apache/geode/connectors/jdbc/internal/xml/JdbcConnectorServiceXmlGenerator.java", "license": "apache-2.0", "size": 7596 }
[ "java.util.Collection", "org.apache.geode.connectors.jdbc.internal.RegionMapping" ]
import java.util.Collection; import org.apache.geode.connectors.jdbc.internal.RegionMapping;
import java.util.*; import org.apache.geode.connectors.jdbc.internal.*;
[ "java.util", "org.apache.geode" ]
java.util; org.apache.geode;
2,292,597
public PreparedStatement newPreparedStatement(Agent agent, org.apache.derby.client.am.Connection connection, String sql,Section section,ClientPooledConnection cpc) throws SqlException { return new PreparedStatement40(agent,connection,sql,section,cpc); }
PreparedStatement function(Agent agent, org.apache.derby.client.am.Connection connection, String sql,Section section,ClientPooledConnection cpc) throws SqlException { return new PreparedStatement40(agent,connection,sql,section,cpc); }
/** * Returns an instance of org.apache.derby.client.am.CallableStatement40 */
Returns an instance of org.apache.derby.client.am.CallableStatement40
newPreparedStatement
{ "repo_name": "viaper/DBPlus", "path": "DerbyHodgepodge/java/client/org/apache/derby/client/net/ClientJDBCObjectFactoryImpl40.java", "license": "apache-2.0", "size": 15931 }
[ "org.apache.derby.client.ClientPooledConnection", "org.apache.derby.client.am.Agent", "org.apache.derby.client.am.PreparedStatement", "org.apache.derby.client.am.PreparedStatement40", "org.apache.derby.client.am.Section", "org.apache.derby.client.am.SqlException" ]
import org.apache.derby.client.ClientPooledConnection; import org.apache.derby.client.am.Agent; import org.apache.derby.client.am.PreparedStatement; import org.apache.derby.client.am.PreparedStatement40; import org.apache.derby.client.am.Section; import org.apache.derby.client.am.SqlException;
import org.apache.derby.client.*; import org.apache.derby.client.am.*;
[ "org.apache.derby" ]
org.apache.derby;
533,249
@Override public void setUp() throws Exception { super.setUp(); MockConnection.clear(); setRequestPathInfo("/systems/details/kickstart/PowerManagement"); }
void function() throws Exception { super.setUp(); MockConnection.clear(); setRequestPathInfo(STR); }
/** * Sets up action path and mocked Cobbler connection. * @throws Exception if something goes wrong */
Sets up action path and mocked Cobbler connection
setUp
{ "repo_name": "xkollar/spacewalk", "path": "java/code/src/com/redhat/rhn/frontend/action/kickstart/test/PowerManagementActionTest.java", "license": "gpl-2.0", "size": 15074 }
[ "org.cobbler.test.MockConnection" ]
import org.cobbler.test.MockConnection;
import org.cobbler.test.*;
[ "org.cobbler.test" ]
org.cobbler.test;
2,372,927
CamelEvent createCamelContextResumedEvent(CamelContext context);
CamelEvent createCamelContextResumedEvent(CamelContext context);
/** * Creates an {@link CamelEvent} for Camel has been resumed successfully. * * @param context camel context * @return the created event */
Creates an <code>CamelEvent</code> for Camel has been resumed successfully
createCamelContextResumedEvent
{ "repo_name": "ullgren/camel", "path": "core/camel-api/src/main/java/org/apache/camel/spi/EventFactory.java", "license": "apache-2.0", "size": 11087 }
[ "org.apache.camel.CamelContext" ]
import org.apache.camel.CamelContext;
import org.apache.camel.*;
[ "org.apache.camel" ]
org.apache.camel;
274,557
public static List<VtnPathMap> readPathMaps(ReadTransaction rtx) throws VTNException { InstanceIdentifier<GlobalPathMaps> path = InstanceIdentifier.create(GlobalPathMaps.class); LogicalDatastoreType oper = LogicalDatastoreType.OPERATIONAL; Optional<GlobalPathMaps> opt = D...
static List<VtnPathMap> function(ReadTransaction rtx) throws VTNException { InstanceIdentifier<GlobalPathMaps> path = InstanceIdentifier.create(GlobalPathMaps.class); LogicalDatastoreType oper = LogicalDatastoreType.OPERATIONAL; Optional<GlobalPathMaps> opt = DataStoreUtils.read(rtx, oper, path); if (opt.isPresent()) {...
/** * Read the path maps in the global path map list. * * @param rtx A {@link ReadTransaction} instance associated with the * read transaction for the MD-SAL datastore. * @return A list of all global path maps. * Each element in the list is sorted by index in ascendi...
Read the path maps in the global path map list
readPathMaps
{ "repo_name": "opendaylight/vtn", "path": "manager/implementation/src/main/java/org/opendaylight/vtn/manager/internal/util/pathmap/PathMapUtils.java", "license": "epl-1.0", "size": 19208 }
[ "com.google.common.base.Optional", "java.util.Collections", "java.util.List", "org.opendaylight.controller.md.sal.binding.api.ReadTransaction", "org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType", "org.opendaylight.vtn.manager.VTNException", "org.opendaylight.vtn.manager.internal.u...
import com.google.common.base.Optional; import java.util.Collections; import java.util.List; import org.opendaylight.controller.md.sal.binding.api.ReadTransaction; import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType; import org.opendaylight.vtn.manager.VTNException; import org.opendaylight.vt...
import com.google.common.base.*; import java.util.*; import org.opendaylight.controller.md.sal.binding.api.*; import org.opendaylight.controller.md.sal.common.api.data.*; import org.opendaylight.vtn.manager.*; import org.opendaylight.vtn.manager.internal.util.*; import org.opendaylight.yang.gen.v1.urn.opendaylight.vtn....
[ "com.google.common", "java.util", "org.opendaylight.controller", "org.opendaylight.vtn", "org.opendaylight.yang", "org.opendaylight.yangtools" ]
com.google.common; java.util; org.opendaylight.controller; org.opendaylight.vtn; org.opendaylight.yang; org.opendaylight.yangtools;
1,481,456
// XXX: Performance Issue: count type notification public int getUnreadNotificationCountByType(final String userId, final int notificationDataType) { final List<Filter> filters = new ArrayList<Filter>(); filters.add(new PropertyFilter(Notification.NOTIFICATION_USER_ID, FilterOperator.EQUAL, use...
int function(final String userId, final int notificationDataType) { final List<Filter> filters = new ArrayList<Filter>(); filters.add(new PropertyFilter(Notification.NOTIFICATION_USER_ID, FilterOperator.EQUAL, userId)); filters.add(new PropertyFilter(Notification.NOTIFICATION_HAS_READ, FilterOperator.EQUAL, false)); fi...
/** * Gets the count of unread notifications with the specified data of a user specified with the given user id. * * @param userId the given user id * @param notificationDataType the specified notification data type * @return count of unread notifications, returns {@code 0} if occurs exception ...
Gets the count of unread notifications with the specified data of a user specified with the given user id
getUnreadNotificationCountByType
{ "repo_name": "ggchxx/symphony", "path": "src/main/java/org/b3log/symphony/service/NotificationQueryService.java", "license": "apache-2.0", "size": 21475 }
[ "java.util.ArrayList", "java.util.List", "org.b3log.latke.Keys", "org.b3log.latke.logging.Level", "org.b3log.latke.model.Pagination", "org.b3log.latke.repository.CompositeFilter", "org.b3log.latke.repository.CompositeFilterOperator", "org.b3log.latke.repository.Filter", "org.b3log.latke.repository.F...
import java.util.ArrayList; import java.util.List; import org.b3log.latke.Keys; import org.b3log.latke.logging.Level; import org.b3log.latke.model.Pagination; import org.b3log.latke.repository.CompositeFilter; import org.b3log.latke.repository.CompositeFilterOperator; import org.b3log.latke.repository.Filter; import or...
import java.util.*; import org.b3log.latke.*; import org.b3log.latke.logging.*; import org.b3log.latke.model.*; import org.b3log.latke.repository.*; import org.b3log.symphony.model.*; import org.json.*;
[ "java.util", "org.b3log.latke", "org.b3log.symphony", "org.json" ]
java.util; org.b3log.latke; org.b3log.symphony; org.json;
930,428
private void hedgedFetchBlockByteRange(LocatedBlock block, long start, long end, byte[] buf, int offset, Map<ExtendedBlock, Set<DatanodeInfo>> corruptedBlockMap) throws IOException { ArrayList<Future<ByteBuffer>> futures = new ArrayList<Future<ByteBuffer>>(); ArrayList<DatanodeInfo> ignored ...
void function(LocatedBlock block, long start, long end, byte[] buf, int offset, Map<ExtendedBlock, Set<DatanodeInfo>> corruptedBlockMap) throws IOException { ArrayList<Future<ByteBuffer>> futures = new ArrayList<Future<ByteBuffer>>(); ArrayList<DatanodeInfo> ignored = new ArrayList<DatanodeInfo>(); ByteBuffer bb = null...
/** * Like {@link #fetchBlockByteRange(LocatedBlock, long, long, byte[], * int, Map)} except we start up a second, parallel, 'hedged' read * if the first read is taking longer than configured amount of * time. We then wait on which ever read returns first. */
Like <code>#fetchBlockByteRange(LocatedBlock, long, long, byte[], int, Map)</code> except we start up a second, parallel, 'hedged' read if the first read is taking longer than configured amount of time. We then wait on which ever read returns first
hedgedFetchBlockByteRange
{ "repo_name": "yelshater/hadoop-2.3.0", "path": "hadoop-hdfs-2.3.0-cdh5.1.0/src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java", "license": "apache-2.0", "size": 62394 }
[ "java.io.IOException", "java.nio.ByteBuffer", "java.util.ArrayList", "java.util.Map", "java.util.Set", "java.util.concurrent.CountDownLatch", "java.util.concurrent.ExecutionException", "java.util.concurrent.Future", "java.util.concurrent.TimeUnit", "java.util.concurrent.TimeoutException", "org.a...
import java.io.IOException; import java.nio.ByteBuffer; import java.util.ArrayList; import java.util.Map; import java.util.Set; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ExecutionException; import java.util.concurrent.Future; import java.util.concurrent.TimeUnit; import java.util.concurren...
import java.io.*; import java.nio.*; import java.util.*; import java.util.concurrent.*; import org.apache.hadoop.hdfs.protocol.*;
[ "java.io", "java.nio", "java.util", "org.apache.hadoop" ]
java.io; java.nio; java.util; org.apache.hadoop;
264,638
public Observable<ServiceResponse<StorageBundle>> setStorageAccountWithServiceResponseAsync(String vaultBaseUrl, String storageAccountName, String resourceId, String activeKeyName, boolean autoRegenerateKey) { if (vaultBaseUrl == null) { throw new IllegalArgumentException("Parameter vaultBaseUrl...
Observable<ServiceResponse<StorageBundle>> function(String vaultBaseUrl, String storageAccountName, String resourceId, String activeKeyName, boolean autoRegenerateKey) { if (vaultBaseUrl == null) { throw new IllegalArgumentException(STR); } if (storageAccountName == null) { throw new IllegalArgumentException(STR); } if...
/** * Creates or updates a new storage account. This operation requires the storage/set permission. * * @param vaultBaseUrl The vault name, for example https://myvault.vault.azure.net. * @param storageAccountName The name of the storage account. * @param resourceId Storage account resource id. ...
Creates or updates a new storage account. This operation requires the storage/set permission
setStorageAccountWithServiceResponseAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/keyvault/microsoft-azure-keyvault/src/main/java/com/microsoft/azure/keyvault/implementation/KeyVaultClientBaseImpl.java", "license": "mit", "size": 884227 }
[ "com.microsoft.azure.keyvault.models.StorageBundle", "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.azure.keyvault.models.StorageBundle; import com.microsoft.rest.ServiceResponse;
import com.microsoft.azure.keyvault.models.*; import com.microsoft.rest.*;
[ "com.microsoft.azure", "com.microsoft.rest" ]
com.microsoft.azure; com.microsoft.rest;
1,553,184
public Collection<Object> newInstanceForArray(Object context, Field field) { return null; }
Collection<Object> function(Object context, Field field) { return null; }
/** * Returns a new instance value for the given field in the given context object for a JSON array * or {@code null} for the default behavior. */
Returns a new instance value for the given field in the given context object for a JSON array or null for the default behavior
newInstanceForArray
{ "repo_name": "wgpshashank/google-http-java-client", "path": "google-http-client/src/main/java/com/google/api/client/json/CustomizeJsonParser.java", "license": "apache-2.0", "size": 2037 }
[ "java.lang.reflect.Field", "java.util.Collection" ]
import java.lang.reflect.Field; import java.util.Collection;
import java.lang.reflect.*; import java.util.*;
[ "java.lang", "java.util" ]
java.lang; java.util;
655,995
@Transactional(readOnly = true) public int countUsers (DetachedCriteria criteria) { if (criteria == null) { criteria = DetachedCriteria.forClass (User.class); } criteria.setResultTransformer (Criteria.DISTINCT_ROOT_ENTITY); criteria.setProjection (Projections.rowCount ())...
@Transactional(readOnly = true) int function (DetachedCriteria criteria) { if (criteria == null) { criteria = DetachedCriteria.forClass (User.class); } criteria.setResultTransformer (Criteria.DISTINCT_ROOT_ENTITY); criteria.setProjection (Projections.rowCount ()); return userDao.count (criteria); }
/** * Counts corresponding users at the given criteria. * * @param criteria criteria contains filter of required collection. * @return number of corresponding users. */
Counts corresponding users at the given criteria
countUsers
{ "repo_name": "SentinelDataHub/DataHubSystem", "path": "core/src/main/java/fr/gael/dhus/service/UserService.java", "license": "agpl-3.0", "size": 35460 }
[ "fr.gael.dhus.database.object.User", "org.hibernate.Criteria", "org.hibernate.criterion.DetachedCriteria", "org.hibernate.criterion.Projections", "org.springframework.transaction.annotation.Transactional" ]
import fr.gael.dhus.database.object.User; import org.hibernate.Criteria; import org.hibernate.criterion.DetachedCriteria; import org.hibernate.criterion.Projections; import org.springframework.transaction.annotation.Transactional;
import fr.gael.dhus.database.object.*; import org.hibernate.*; import org.hibernate.criterion.*; import org.springframework.transaction.annotation.*;
[ "fr.gael.dhus", "org.hibernate", "org.hibernate.criterion", "org.springframework.transaction" ]
fr.gael.dhus; org.hibernate; org.hibernate.criterion; org.springframework.transaction;
2,909,810
Schedule resource = manager.schedules().getWithResponse("testrg123", "testlab", "schedule1", Context.NONE).getValue(); resource .update() .withRecurrencePattern( new RecurrencePattern() .withFrequency(RecurrenceFrequency.DAILY) ...
Schedule resource = manager.schedules().getWithResponse(STR, STR, STR, Context.NONE).getValue(); resource .update() .withRecurrencePattern( new RecurrencePattern() .withFrequency(RecurrenceFrequency.DAILY) .withInterval(2) .withExpirationDate(LocalDate.parse(STR))) .apply(); }
/** * Sample code: patchSchedule. * * @param manager Entry point to LabServicesManager. */
Sample code: patchSchedule
patchSchedule
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/labservices/azure-resourcemanager-labservices/src/samples/java/com/azure/resourcemanager/labservices/generated/SchedulesUpdateSamples.java", "license": "mit", "size": 1414 }
[ "com.azure.core.util.Context", "com.azure.resourcemanager.labservices.models.RecurrenceFrequency", "com.azure.resourcemanager.labservices.models.RecurrencePattern", "com.azure.resourcemanager.labservices.models.Schedule", "java.time.LocalDate" ]
import com.azure.core.util.Context; import com.azure.resourcemanager.labservices.models.RecurrenceFrequency; import com.azure.resourcemanager.labservices.models.RecurrencePattern; import com.azure.resourcemanager.labservices.models.Schedule; import java.time.LocalDate;
import com.azure.core.util.*; import com.azure.resourcemanager.labservices.models.*; import java.time.*;
[ "com.azure.core", "com.azure.resourcemanager", "java.time" ]
com.azure.core; com.azure.resourcemanager; java.time;
2,884,941
public void generarFecha(){ Date fechaActual = new Date(); tfFechaActual.setDate(fechaActual); }
void function(){ Date fechaActual = new Date(); tfFechaActual.setDate(fechaActual); }
/** * Obtiene la fecha del sistema y la inserta en el cuadro de texto de fecha. */
Obtiene la fecha del sistema y la inserta en el cuadro de texto de fecha
generarFecha
{ "repo_name": "zavex/agrarian2", "path": "src/vista/frmRegistrarPago.java", "license": "gpl-3.0", "size": 53403 }
[ "java.util.Date" ]
import java.util.Date;
import java.util.*;
[ "java.util" ]
java.util;
2,636,738
Observable<ServiceResponse<Void>> putBase64UrlEncodedWithServiceResponseAsync(byte[] stringBody);
Observable<ServiceResponse<Void>> putBase64UrlEncodedWithServiceResponseAsync(byte[] stringBody);
/** * Put value that is base64url encoded. * * @param stringBody the Base64Url value * @return the {@link ServiceResponse} object if successful. */
Put value that is base64url encoded
putBase64UrlEncodedWithServiceResponseAsync
{ "repo_name": "anudeepsharma/autorest", "path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/bodystring/Strings.java", "license": "mit", "size": 17112 }
[ "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.rest.ServiceResponse;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
475,571
public static void cleanDirectory(final File directory) throws IOException { final File[] files = verifiedListFiles(directory); IOException exception = null; for (final File file : files) { try { forceDelete(file); } catch (final IOException ioe) { ...
static void function(final File directory) throws IOException { final File[] files = verifiedListFiles(directory); IOException exception = null; for (final File file : files) { try { forceDelete(file); } catch (final IOException ioe) { exception = ioe; } } if (null != exception) { throw exception; } }
/** * Cleans a directory without deleting it. * * @param directory directory to clean * @throws IOException in case cleaning is unsuccessful * @throws IllegalArgumentException if {@code directory} does not exist or is not a directory */
Cleans a directory without deleting it
cleanDirectory
{ "repo_name": "247321453/RePlugin", "path": "replugin-host-library/replugin-host-lib/src/main/java/com/qihoo360/replugin/utils/FileUtils.java", "license": "apache-2.0", "size": 28694 }
[ "java.io.File", "java.io.IOException" ]
import java.io.File; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,835,003
public MultipleCurrencyAmount presentValueFromCleanNominalPrice(final BondCapitalIndexedSecurity<?> bond, final InflationIssuerProviderInterface market, final double cleanPriceNominal) { Validate.notNull(bond, "Coupon"); Validate.notNull(market, "Market"); Currency ccy = bond.getCurrency(); fin...
MultipleCurrencyAmount function(final BondCapitalIndexedSecurity<?> bond, final InflationIssuerProviderInterface market, final double cleanPriceNominal) { Validate.notNull(bond, STR); Validate.notNull(market, STR); Currency ccy = bond.getCurrency(); final double notional = bond.getCoupon().getNthPayment(0).getNotional(...
/** * Computes the security present value from a quoted clean real price. * The real accrued inflated and discounted from settlement are added to the discounted clean nominal price. * @param bond The bond security. * @param market The market. * @param cleanPriceNominal The nominal clean price. * @ret...
Computes the security present value from a quoted clean real price. The real accrued inflated and discounted from settlement are added to the discounted clean nominal price
presentValueFromCleanNominalPrice
{ "repo_name": "ChinaQuants/OG-Platform", "path": "projects/OG-Analytics/src/main/java/com/opengamma/analytics/financial/interestrate/bond/provider/BondCapitalIndexedSecurityDiscountingMethod.java", "license": "apache-2.0", "size": 37503 }
[ "com.opengamma.analytics.financial.interestrate.bond.definition.BondCapitalIndexedSecurity", "com.opengamma.analytics.financial.provider.description.inflation.InflationIssuerProviderInterface", "com.opengamma.util.money.Currency", "com.opengamma.util.money.MultipleCurrencyAmount", "org.apache.commons.lang.V...
import com.opengamma.analytics.financial.interestrate.bond.definition.BondCapitalIndexedSecurity; import com.opengamma.analytics.financial.provider.description.inflation.InflationIssuerProviderInterface; import com.opengamma.util.money.Currency; import com.opengamma.util.money.MultipleCurrencyAmount; import org.apache....
import com.opengamma.analytics.financial.interestrate.bond.definition.*; import com.opengamma.analytics.financial.provider.description.inflation.*; import com.opengamma.util.money.*; import org.apache.commons.lang.*;
[ "com.opengamma.analytics", "com.opengamma.util", "org.apache.commons" ]
com.opengamma.analytics; com.opengamma.util; org.apache.commons;
1,422,576
public static OneResponse chown(Client client, int id, int uid, int gid) { return client.call(CHOWN, id, uid, gid); }
static OneResponse function(Client client, int id, int uid, int gid) { return client.call(CHOWN, id, uid, gid); }
/** * Changes the owner/group * * @param client XML-RPC Client. * @param id The virtual network id (nid) of the target network. * @param uid The new owner user ID. Set it to -1 to leave the current one. * @param gid The new group ID. Set it to -1 to leave the current one. * @return If...
Changes the owner/group
chown
{ "repo_name": "hsanjuan/one", "path": "src/oca/java/src/org/opennebula/client/vnet/VirtualNetwork.java", "license": "apache-2.0", "size": 21150 }
[ "org.opennebula.client.Client", "org.opennebula.client.OneResponse" ]
import org.opennebula.client.Client; import org.opennebula.client.OneResponse;
import org.opennebula.client.*;
[ "org.opennebula.client" ]
org.opennebula.client;
1,292,127
EClass getLIndex();
EClass getLIndex();
/** * Returns the meta object for class '{@link org.lunifera.dsl.semantic.entity.LIndex <em>LIndex</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>LIndex</em>'. * @see org.lunifera.dsl.semantic.entity.LIndex * @generated */
Returns the meta object for class '<code>org.lunifera.dsl.semantic.entity.LIndex LIndex</code>'.
getLIndex
{ "repo_name": "lunifera/lunifera-dsl", "path": "org.lunifera.dsl.semantic.entity/emf-gen/org/lunifera/dsl/semantic/entity/LunEntityPackage.java", "license": "epl-1.0", "size": 119334 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
2,025,754