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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
String path = String.format("/projects/%s/custom_field_settings", project);
return new CollectionRequest<CustomFieldSetting>(this, CustomFieldSetting.class, path, "GET");
} | String path = String.format(STR, project); return new CollectionRequest<CustomFieldSetting>(this, CustomFieldSetting.class, path, "GET"); } | /**
* Returns a list of all of the custom fields settings on a project.
*
* @param project The ID of the project for which to list custom field settings
* @return Request object
*/ | Returns a list of all of the custom fields settings on a project | findByProject | {
"repo_name": "Asana/java-asana",
"path": "src/main/java/com/asana/resources/CustomFieldSettings.java",
"license": "mit",
"size": 1335
} | [
"com.asana.models.CustomFieldSetting",
"com.asana.requests.CollectionRequest"
] | import com.asana.models.CustomFieldSetting; import com.asana.requests.CollectionRequest; | import com.asana.models.*; import com.asana.requests.*; | [
"com.asana.models",
"com.asana.requests"
] | com.asana.models; com.asana.requests; | 791,159 |
public synchronized PrintStream getDebugOut() {
if (out == null)
return System.out;
else
return out;
}
| synchronized PrintStream function() { if (out == null) return System.out; else return out; } | /**
* Returns the stream to be used for debugging output. If no stream has been
* set, <code>System.out</code> is returned.
*
* @return the PrintStream to use for debugging output.
*/ | Returns the stream to be used for debugging output. If no stream has been set, <code>System.out</code> is returned | getDebugOut | {
"repo_name": "gtrak/hedwig",
"path": "hedwig-server/src/main/java/com/hs/mail/imap/server/DebuggingHandler.java",
"license": "apache-2.0",
"size": 2974
} | [
"java.io.PrintStream"
] | import java.io.PrintStream; | import java.io.*; | [
"java.io"
] | java.io; | 382,480 |
public final Cut selectModel( MyDataset data )
{
double minResult, averageInfoGain = 0, sumOfWeights;
Cut [] current;
Cut best = null, noCut = null;
int models = 0, i;
boolean multiVal = true;
Classification checkClassification;
MyAttribute attribute;
try
{
// ... | final Cut function( MyDataset data ) { double minResult, averageInfoGain = 0, sumOfWeights; Cut [] current; Cut best = null, noCut = null; int models = 0, i; boolean multiVal = true; Classification checkClassification; MyAttribute attribute; try { checkClassification = new Classification( data ); noCut = new Cut( check... | /** Function to select the cut point.
*
* @param data The dataset used to compute the cut point.
*
* @return The cut point computed.
*/ | Function to select the cut point | selectModel | {
"repo_name": "TheMurderer/keel",
"path": "src/keel/Algorithms/Rule_Learning/C45Rules/SelectCut.java",
"license": "gpl-3.0",
"size": 5969
} | [
"java.util.Enumeration"
] | import java.util.Enumeration; | import java.util.*; | [
"java.util"
] | java.util; | 759,937 |
public static String getDefaultHost(String strInterface, String nameserver)
throws UnknownHostException {
if (HAS_NEW_DNS_GET_DEFAULT_HOST_API) {
try {
// Hadoop-2.8 includes a String, String, boolean variant of getDefaultHost
// which properly handles multi-homed systems with Kerberos... | static String function(String strInterface, String nameserver) throws UnknownHostException { if (HAS_NEW_DNS_GET_DEFAULT_HOST_API) { try { return (String) GET_DEFAULT_HOST_METHOD.invoke(null, strInterface, nameserver, true); } catch (Exception e) { throw new RuntimeException(STR, e); } } else { return org.apache.hadoop... | /**
* Wrapper around DNS.getDefaultHost(String, String), calling
* DNS.getDefaultHost(String, String, boolean) when available.
*
* @param strInterface The network interface to query.
* @param nameserver The DNS host name.
* @return The default host names associated with IPs bound to the network interf... | Wrapper around DNS.getDefaultHost(String, String), calling DNS.getDefaultHost(String, String, boolean) when available | getDefaultHost | {
"repo_name": "ultratendency/hbase",
"path": "hbase-common/src/main/java/org/apache/hadoop/hbase/util/DNS.java",
"license": "apache-2.0",
"size": 2787
} | [
"java.net.UnknownHostException"
] | import java.net.UnknownHostException; | import java.net.*; | [
"java.net"
] | java.net; | 529,441 |
@Override
public void removeVolumes(
final Collection<StorageLocation> storageLocsToRemove,
boolean clearFailure) {
Collection<StorageLocation> storageLocationsToRemove =
new ArrayList<>(storageLocsToRemove);
Map<String, List<ReplicaInfo>> blkToInvalidate = new HashMap<>();
List<Stri... | void function( final Collection<StorageLocation> storageLocsToRemove, boolean clearFailure) { Collection<StorageLocation> storageLocationsToRemove = new ArrayList<>(storageLocsToRemove); Map<String, List<ReplicaInfo>> blkToInvalidate = new HashMap<>(); List<String> storageToRemove = new ArrayList<>(); try (AutoCloseabl... | /**
* Removes a set of volumes from FsDataset.
* @param storageLocsToRemove a set of
* {@link StorageLocation}s for each volume.
* @param clearFailure set true to clear failure information.
*/ | Removes a set of volumes from FsDataset | removeVolumes | {
"repo_name": "nandakumar131/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/impl/FsDatasetImpl.java",
"license": "apache-2.0",
"size": 136365
} | [
"java.util.ArrayList",
"java.util.Collection",
"java.util.HashMap",
"java.util.Iterator",
"java.util.List",
"java.util.Map",
"org.apache.hadoop.hdfs.server.common.Storage",
"org.apache.hadoop.hdfs.server.datanode.ReplicaInfo",
"org.apache.hadoop.hdfs.server.datanode.StorageLocation",
"org.apache.h... | import java.util.ArrayList; import java.util.Collection; import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; import org.apache.hadoop.hdfs.server.common.Storage; import org.apache.hadoop.hdfs.server.datanode.ReplicaInfo; import org.apache.hadoop.hdfs.server.datanode.Storage... | import java.util.*; import org.apache.hadoop.hdfs.server.common.*; import org.apache.hadoop.hdfs.server.datanode.*; import org.apache.hadoop.util.*; | [
"java.util",
"org.apache.hadoop"
] | java.util; org.apache.hadoop; | 1,842,360 |
@Override
public void retry(VolleyError error) throws VolleyError {
currentRetryCount++;
currentTimeoutMs += (currentTimeoutMs * backoffMultiplier);
if (!hasAttemptRemaining()) {
throw error;
}
} | void function(VolleyError error) throws VolleyError { currentRetryCount++; currentTimeoutMs += (currentTimeoutMs * backoffMultiplier); if (!hasAttemptRemaining()) { throw error; } } | /**
* Prepares for the next retry by applying a backoff to the timeout.
*
* @param error The error code of the last attempt.
*/ | Prepares for the next retry by applying a backoff to the timeout | retry | {
"repo_name": "imdatcandan/wasp",
"path": "wasp/src/main/java/com/orhanobut/wasp/utils/WaspRetryPolicy.java",
"license": "apache-2.0",
"size": 2473
} | [
"com.android.volley.VolleyError"
] | import com.android.volley.VolleyError; | import com.android.volley.*; | [
"com.android.volley"
] | com.android.volley; | 2,272,058 |
public static HBaseProtos.TimeUnit toProtoTimeUnit(final TimeUnit timeUnit) {
switch (timeUnit) {
case NANOSECONDS: return HBaseProtos.TimeUnit.NANOSECONDS;
case MICROSECONDS: return HBaseProtos.TimeUnit.MICROSECONDS;
case MILLISECONDS: return HBaseProtos.TimeUnit.MILLISECONDS;
case SECON... | static HBaseProtos.TimeUnit function(final TimeUnit timeUnit) { switch (timeUnit) { case NANOSECONDS: return HBaseProtos.TimeUnit.NANOSECONDS; case MICROSECONDS: return HBaseProtos.TimeUnit.MICROSECONDS; case MILLISECONDS: return HBaseProtos.TimeUnit.MILLISECONDS; case SECONDS: return HBaseProtos.TimeUnit.SECONDS; case... | /**
* Convert a client TimeUnit to a protocol buffer TimeUnit
*
* @param timeUnit
* @return the converted protocol buffer TimeUnit
*/ | Convert a client TimeUnit to a protocol buffer TimeUnit | toProtoTimeUnit | {
"repo_name": "drewpope/hbase",
"path": "hbase-client/src/main/java/org/apache/hadoop/hbase/protobuf/ProtobufUtil.java",
"license": "apache-2.0",
"size": 114457
} | [
"java.util.concurrent.TimeUnit",
"org.apache.hadoop.hbase.protobuf.generated.HBaseProtos"
] | import java.util.concurrent.TimeUnit; import org.apache.hadoop.hbase.protobuf.generated.HBaseProtos; | import java.util.concurrent.*; import org.apache.hadoop.hbase.protobuf.generated.*; | [
"java.util",
"org.apache.hadoop"
] | java.util; org.apache.hadoop; | 106,069 |
public void assertPrepareAndReleaseAllPeriods() throws InterruptedException {
Timeline.Period period = new Timeline.Period();
for (int i = 0; i < timeline.getPeriodCount(); i++) {
timeline.getPeriod(i, period, true);
assertPrepareAndReleasePeriod(new MediaPeriodId(period.uid, period.windowIndex))... | void function() throws InterruptedException { Timeline.Period period = new Timeline.Period(); for (int i = 0; i < timeline.getPeriodCount(); i++) { timeline.getPeriod(i, period, true); assertPrepareAndReleasePeriod(new MediaPeriodId(period.uid, period.windowIndex)); for (int adGroupIndex = 0; adGroupIndex < period.getA... | /**
* Creates and releases all periods (including ad periods) defined in the last timeline to be
* returned from {@link #prepareSource()}, {@link #assertTimelineChange()} or {@link
* #assertTimelineChangeBlocking()}. The {@link MediaPeriodId#windowSequenceNumber} is set to the
* index of the window.
*/ | Creates and releases all periods (including ad periods) defined in the last timeline to be returned from <code>#prepareSource()</code>, <code>#assertTimelineChange()</code> or <code>#assertTimelineChangeBlocking()</code>. The <code>MediaPeriodId#windowSequenceNumber</code> is set to the index of the window | assertPrepareAndReleaseAllPeriods | {
"repo_name": "stari4ek/ExoPlayer",
"path": "testutils/src/main/java/com/google/android/exoplayer2/testutil/MediaSourceTestRunner.java",
"license": "apache-2.0",
"size": 16787
} | [
"com.google.android.exoplayer2.Timeline",
"com.google.android.exoplayer2.source.MediaSource"
] | import com.google.android.exoplayer2.Timeline; import com.google.android.exoplayer2.source.MediaSource; | import com.google.android.exoplayer2.*; import com.google.android.exoplayer2.source.*; | [
"com.google.android"
] | com.google.android; | 1,857,962 |
public void createAccount(Account account, Connection con) throws SQLException; | void function(Account account, Connection con) throws SQLException; | /**
* Overloading method, does the same as createAccount(account) but uses specified
* connection, useful for using this method as a part of a transaction.
*
* @param account
* Account object with all specified atributes with exception of id, id will
* be assigned inside this method auto... | Overloading method, does the same as createAccount(account) but uses specified connection, useful for using this method as a part of a transaction | createAccount | {
"repo_name": "MarekVan/pv168",
"path": "src/main/java/pv168/AccountManager.java",
"license": "mit",
"size": 4884
} | [
"java.sql.Connection",
"java.sql.SQLException"
] | import java.sql.Connection; import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 2,110,094 |
public static void requestDataLogsForApp( final Context context, final UUID appUuid )
{
final Intent requestIntent = new Intent( INTENT_DL_REQUEST_DATA );
requestIntent.putExtra( APP_UUID, appUuid );
context.sendBroadcast( requestIntent );
}
public static class FirmwareVersionInfo
{
private final int ... | static void function( final Context context, final UUID appUuid ) { final Intent requestIntent = new Intent( INTENT_DL_REQUEST_DATA ); requestIntent.putExtra( APP_UUID, appUuid ); context.sendBroadcast( requestIntent ); } public static class FirmwareVersionInfo { private final int major; private final int minor; privat... | /**
* A convenience function to emit an intent to pebble.apk to request the data logs for a particular app. If data
* is available, pebble.apk will advertise the data via 'INTENT_DL_RECEIVE_DATA' intents.
* <p/>
* To avoid leaking memory, activities registering BroadcastReceivers <em>must</em> unregister them i... | A convenience function to emit an intent to pebble.apk to request the data logs for a particular app. If data is available, pebble.apk will advertise the data via 'INTENT_DL_RECEIVE_DATA' intents. To avoid leaking memory, activities registering BroadcastReceivers must unregister them in the Activity's <code>android.app... | requestDataLogsForApp | {
"repo_name": "zaxebo1/RingMyPhoneAndroid",
"path": "RingMyPhone/src/main/java/com/getpebble/android/kit/PebbleKit.java",
"license": "mit",
"size": 35095
} | [
"android.content.Context",
"android.content.Intent"
] | import android.content.Context; import android.content.Intent; | import android.content.*; | [
"android.content"
] | android.content; | 1,926,531 |
public static AbstractInputStreamAssert<?, ? extends InputStream> then(InputStream actual) {
return assertThat(actual);
} | static AbstractInputStreamAssert<?, ? extends InputStream> function(InputStream actual) { return assertThat(actual); } | /**
* Creates a new instance of <code>{@link org.assertj.core.api.InputStreamAssert}</code>.
*
* @param actual the actual value.
* @return the created assertion object.
*/ | Creates a new instance of <code><code>org.assertj.core.api.InputStreamAssert</code></code> | then | {
"repo_name": "yurloc/assertj-core",
"path": "src/main/java/org/assertj/core/api/BDDAssertions.java",
"license": "apache-2.0",
"size": 13171
} | [
"java.io.InputStream"
] | import java.io.InputStream; | import java.io.*; | [
"java.io"
] | java.io; | 47,235 |
public void remove(MapView mapView) {
mapView.getOverlays().remove(this);
} | void function(MapView mapView) { mapView.getOverlays().remove(this); } | /**
* Removes this Marker from the MapView.
* Note that this method will operate only if the Marker is in the MapView overlays
* (it should not be included in a container like a FolderOverlay).
*
* @param mapView
*/ | Removes this Marker from the MapView. Note that this method will operate only if the Marker is in the MapView overlays (it should not be included in a container like a FolderOverlay) | remove | {
"repo_name": "osmdroid/osmdroid",
"path": "osmdroid-android/src/main/java/org/osmdroid/views/overlay/Marker.java",
"license": "apache-2.0",
"size": 20193
} | [
"org.osmdroid.views.MapView"
] | import org.osmdroid.views.MapView; | import org.osmdroid.views.*; | [
"org.osmdroid.views"
] | org.osmdroid.views; | 503,093 |
@Override
public void setPageContext(PageContext pageContext) {
super.setPageContext(pageContext);
WebApplicationContext ctx = WebApplicationContextUtils
.getRequiredWebApplicationContext(pageContext.getServletContext());
aclEvaluator = ctx.getBean(PermissionEvaluator.cla... | void function(PageContext pageContext) { super.setPageContext(pageContext); WebApplicationContext ctx = WebApplicationContextUtils .getRequiredWebApplicationContext(pageContext.getServletContext()); aclEvaluator = ctx.getBean(PermissionEvaluator.class); securityContextFacade = ctx.getBean(SecurityContextFacade.class); ... | /**
* Fetches all required beans from Spring context when page context is set.
* This guaranteed that all services will be initialized before actual
* page rendering
*
* @param pageContext page context to be set for this tag invocation
*
*/ | Fetches all required beans from Spring context when page context is set. This guaranteed that all services will be initialized before actual page rendering | setPageContext | {
"repo_name": "offn/Myrelease",
"path": "jcommune-view/jcommune-web-view/src/main/java/org/jtalks/jcommune/web/tags/HasPermission.java",
"license": "lgpl-2.1",
"size": 4539
} | [
"javax.servlet.jsp.PageContext",
"org.jtalks.common.service.security.SecurityContextFacade",
"org.springframework.security.access.PermissionEvaluator",
"org.springframework.web.context.WebApplicationContext",
"org.springframework.web.context.support.WebApplicationContextUtils"
] | import javax.servlet.jsp.PageContext; import org.jtalks.common.service.security.SecurityContextFacade; import org.springframework.security.access.PermissionEvaluator; import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.support.WebApplicationContextUtils; | import javax.servlet.jsp.*; import org.jtalks.common.service.security.*; import org.springframework.security.access.*; import org.springframework.web.context.*; import org.springframework.web.context.support.*; | [
"javax.servlet",
"org.jtalks.common",
"org.springframework.security",
"org.springframework.web"
] | javax.servlet; org.jtalks.common; org.springframework.security; org.springframework.web; | 299,878 |
void exit(AbruptExitException exception);
} | void exit(AbruptExitException exception); } | /**
* Exits Blaze as early as possible by sending an interrupt to the command's main thread.
*/ | Exits Blaze as early as possible by sending an interrupt to the command's main thread | exit | {
"repo_name": "hermione521/bazel",
"path": "src/main/java/com/google/devtools/build/lib/runtime/BlazeModule.java",
"license": "apache-2.0",
"size": 11006
} | [
"com.google.devtools.build.lib.util.AbruptExitException"
] | import com.google.devtools.build.lib.util.AbruptExitException; | import com.google.devtools.build.lib.util.*; | [
"com.google.devtools"
] | com.google.devtools; | 2,742,237 |
@ServiceMethod(returns = ReturnType.SINGLE)
public VirtualMachineInner getByResourceGroup(String resourceGroupName, String vmName) {
final InstanceViewTypes expand = null;
return getByResourceGroupAsync(resourceGroupName, vmName, expand).block();
} | @ServiceMethod(returns = ReturnType.SINGLE) VirtualMachineInner function(String resourceGroupName, String vmName) { final InstanceViewTypes expand = null; return getByResourceGroupAsync(resourceGroupName, vmName, expand).block(); } | /**
* Retrieves information about the model view or the instance view of a virtual machine.
*
* @param resourceGroupName The name of the resource group.
* @param vmName The name of the virtual machine.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws A... | Retrieves information about the model view or the instance view of a virtual machine | getByResourceGroup | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-compute/src/main/java/com/azure/resourcemanager/compute/implementation/VirtualMachinesClientImpl.java",
"license": "mit",
"size": 333925
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.resourcemanager.compute.fluent.models.VirtualMachineInner",
"com.azure.resourcemanager.compute.models.InstanceViewTypes"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.resourcemanager.compute.fluent.models.VirtualMachineInner; import com.azure.resourcemanager.compute.models.InstanceViewTypes; | import com.azure.core.annotation.*; import com.azure.resourcemanager.compute.fluent.models.*; import com.azure.resourcemanager.compute.models.*; | [
"com.azure.core",
"com.azure.resourcemanager"
] | com.azure.core; com.azure.resourcemanager; | 902,607 |
File mf = new File(filesPath + File.separator + destName);
if (!mf.exists()) {
// First, does our files/ directory even exist?
// We cannot wait for android to lazily create it as we will soon
// need it.
try {
FileInputStream fis = context.openFil... | File mf = new File(filesPath + File.separator + destName); if (!mf.exists()) { try { FileInputStream fis = context.openFileInput(BOGUS_FILE_NAME); fis.close(); } catch (FileNotFoundException e) { FileOutputStream fos = null; try { fos = context.openFileOutput("bogus", Context.MODE_PRIVATE); fos.write(STR.getBytes()); }... | /**
* This method can be used to unpack a binary from the raw resources folder and store it in
* /data/data/app.package/files/
* This is typically useful if you provide your own C- or C++-based binary.
* This binary can then be executed using sendShell() and its full path.
*
* @param sourc... | This method can be used to unpack a binary from the raw resources folder and store it in data/data/app.package/files This is typically useful if you provide your own C- or C++-based binary. This binary can then be executed using sendShell() and its full path | installBinary | {
"repo_name": "jabelai/Neverland",
"path": "NeverLand/src/com/stericson/RootTools/internal/Installer.java",
"license": "apache-2.0",
"size": 5974
} | [
"android.content.Context",
"android.util.Log",
"com.stericson.RootTools",
"java.io.File",
"java.io.FileInputStream",
"java.io.FileNotFoundException",
"java.io.FileOutputStream",
"java.io.IOException",
"java.io.InputStream"
] | import android.content.Context; import android.util.Log; import com.stericson.RootTools; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.io.InputStream; | import android.content.*; import android.util.*; import com.stericson.*; import java.io.*; | [
"android.content",
"android.util",
"com.stericson",
"java.io"
] | android.content; android.util; com.stericson; java.io; | 1,503,472 |
public int read() throws IOException {
if( frameSize != 1 ) {
throw new IOException("cannot read a single byte if frame size > 1");
}
byte[] data = new byte[1];
int temp = read(data);
if (temp <= 0) {
// we have a weird situation if read(byte[]) retur... | int function() throws IOException { if( frameSize != 1 ) { throw new IOException(STR); } byte[] data = new byte[1]; int temp = read(data); if (temp <= 0) { return -1; } return data[0] & 0xFF; } | /**
* Reads the next byte of data from the audio input stream. The audio input
* stream's frame size must be one byte, or an <code>IOException</code>
* will be thrown.
*
* @return the next byte of data, or -1 if the end of the stream is reached
* @throws IOException if an input or output ... | Reads the next byte of data from the audio input stream. The audio input stream's frame size must be one byte, or an <code>IOException</code> will be thrown | read | {
"repo_name": "shun634501730/java_source_cn",
"path": "src_en/javax/sound/sampled/AudioInputStream.java",
"license": "apache-2.0",
"size": 15669
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 84,922 |
// Get all the arguments that if attacked, could make the root defeated:
// They are returned in a leaves-to-root order (i.e. leaves first, and root node last)
public List<Argument> getDefenders(List<ArgumentationAgent> agents) {
return getDefenders(m_root, agents);
} | List<Argument> function(List<ArgumentationAgent> agents) { return getDefenders(m_root, agents); } | /**
* Gets the defenders.
*
* @param agents
* the agents
* @return the defenders
*/ | Gets the defenders | getDefenders | {
"repo_name": "santiontanon/fterm",
"path": "src/ftl/argumentation/core/ArgumentationTree.java",
"license": "bsd-3-clause",
"size": 16290
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,099,152 |
public static List<String> toList(String value,String delimiter){
List<String> collection = new ArrayList<String>();
StringTokenizer tokenizer = new StringTokenizer(value, delimiter);
while (tokenizer.hasMoreElements()) {
collection.add(tokenizer.nextToken());
}
return collection;
}
| static List<String> function(String value,String delimiter){ List<String> collection = new ArrayList<String>(); StringTokenizer tokenizer = new StringTokenizer(value, delimiter); while (tokenizer.hasMoreElements()) { collection.add(tokenizer.nextToken()); } return collection; } | /**
* Splits a String separated by a delimiter into tokens and returns them in a List.
*
* @param value
* @param delimiter
* @return list containing tokens
*/ | Splits a String separated by a delimiter into tokens and returns them in a List | toList | {
"repo_name": "nervepoint/identity4j",
"path": "identity4j-utils/src/main/java/com/identity4j/util/StringUtil.java",
"license": "lgpl-3.0",
"size": 12815
} | [
"java.util.ArrayList",
"java.util.List",
"java.util.StringTokenizer"
] | import java.util.ArrayList; import java.util.List; import java.util.StringTokenizer; | import java.util.*; | [
"java.util"
] | java.util; | 466,955 |
protected void addTitlePropertyDescriptor(Object object) {
itemPropertyDescriptors
.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
getResourceLocator(), getString("_UI_Document_title_feature"),
getString("_UI_PropertyDescriptor_description", "... | void function(Object object) { itemPropertyDescriptors .add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), BibtexPackage.Literals.DOCUMENT__TITLE, false, false, false, ItemPropertyDescriptor.GENERIC_VALUE... | /**
* This adds a property descriptor for the Title feature. <!-- begin-user-doc
* --> <!-- end-user-doc -->
*
* @generated NOT
*/ | This adds a property descriptor for the Title feature. | addTitlePropertyDescriptor | {
"repo_name": "sebastiangoetz/slr-toolkit",
"path": "plugins/de.tudresden.slr.model.bibtex.edit/src/de/tudresden/slr/model/bibtex/provider/DocumentItemProvider.java",
"license": "epl-1.0",
"size": 13957
} | [
"de.tudresden.slr.model.bibtex.BibtexPackage",
"org.eclipse.emf.edit.provider.ComposeableAdapterFactory",
"org.eclipse.emf.edit.provider.ItemPropertyDescriptor"
] | import de.tudresden.slr.model.bibtex.BibtexPackage; import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; | import de.tudresden.slr.model.bibtex.*; import org.eclipse.emf.edit.provider.*; | [
"de.tudresden.slr",
"org.eclipse.emf"
] | de.tudresden.slr; org.eclipse.emf; | 1,776,099 |
private static EASyLogger getLogger() {
return EASyLoggerFactory.INSTANCE.getLogger(EASyLogger.class, Bundle.ID);
} | static EASyLogger function() { return EASyLoggerFactory.INSTANCE.getLogger(EASyLogger.class, Bundle.ID); } | /**
* Returns the logger for this class.
*
* @return the logger
*/ | Returns the logger for this class | getLogger | {
"repo_name": "SSEHUB/EASyProducer",
"path": "Plugins/Instantiation/de.uni_hildesheim.sse.vil.rt.ui/src/de/uni_hildesheim/sse/vil/rt/ui/embed/SimulatorUi.java",
"license": "apache-2.0",
"size": 17141
} | [
"net.ssehub.easy.basics.logger.EASyLoggerFactory",
"net.ssehub.easy.instantiation.rt.core.model.rtVil.Bundle"
] | import net.ssehub.easy.basics.logger.EASyLoggerFactory; import net.ssehub.easy.instantiation.rt.core.model.rtVil.Bundle; | import net.ssehub.easy.basics.logger.*; import net.ssehub.easy.instantiation.rt.core.model.*; | [
"net.ssehub.easy"
] | net.ssehub.easy; | 1,184,607 |
public void set(int index, long value) {
assert index >= 0 : "index (" + index + ") should >= 0";
assert index < length : "index (" + index + ") should < length (" + length + ")";
Platform.putLong(baseObj, baseOffset + index * WIDTH, value);
} | void function(int index, long value) { assert index >= 0 : STR + index + STR; assert index < length : STR + index + STR + length + ")"; Platform.putLong(baseObj, baseOffset + index * WIDTH, value); } | /**
* Sets the value at position {@code index}.
*/ | Sets the value at position index | set | {
"repo_name": "ArvinDevel/onlineAggregationOnSparkV2",
"path": "unsafe/src/main/java/org/apache/spark/unsafe/array/LongArray.java",
"license": "apache-2.0",
"size": 2664
} | [
"org.apache.spark.unsafe.Platform"
] | import org.apache.spark.unsafe.Platform; | import org.apache.spark.unsafe.*; | [
"org.apache.spark"
] | org.apache.spark; | 1,791,268 |
private final Future<Void> executeTask (final ITask task) throws TaskExecutionException {
if (task instanceof IOTask) {
final Future<Void> returnVal = executor.submit((IOTask) task);
return returnVal;
} else {
try {
task.call();
} catc... | final Future<Void> function (final ITask task) throws TaskExecutionException { if (task instanceof IOTask) { final Future<Void> returnVal = executor.submit((IOTask) task); return returnVal; } else { try { task.call(); } catch (final Exception exc) { throw new TaskExecutionException(new ExecutionException(exc)); } retur... | /**
* This methods appends the given task to the end of the taskQueue and set the calling thread is sleep state.
*
* @param task The task to append to the end of the taskQueue.
* @throws InterruptedException if another thread interrupted the current thread before or while the current thread
* ... | This methods appends the given task to the end of the taskQueue and set the calling thread is sleep state | executeTask | {
"repo_name": "andrewgaul/jSCSI",
"path": "bundles/initiator/src/main/java/org/jscsi/initiator/connection/Session.java",
"license": "bsd-3-clause",
"size": 23195
} | [
"java.util.concurrent.ExecutionException",
"java.util.concurrent.Future",
"org.jscsi.exception.TaskExecutionException"
] | import java.util.concurrent.ExecutionException; import java.util.concurrent.Future; import org.jscsi.exception.TaskExecutionException; | import java.util.concurrent.*; import org.jscsi.exception.*; | [
"java.util",
"org.jscsi.exception"
] | java.util; org.jscsi.exception; | 77,900 |
public static boolean checkGroupPermission(Connection con,
PLGroup p,
DatabaseObject obj,
String perm)
throws SQLException, PLSecurityException {
if (perm.equals(CREATE_PERMISSION) && !(obj instanceof AllDatabaseObject)) {
throw new IllegalArgumentException
("CRE... | static boolean function(Connection con, PLGroup p, DatabaseObject obj, String perm) throws SQLException, PLSecurityException { if (perm.equals(CREATE_PERMISSION) && !(obj instanceof AllDatabaseObject)) { throw new IllegalArgumentException (STR); } StringBuffer sql = new StringBuffer(500); if (obj instanceof AllDatabase... | /**
* Returns true if and only if the given user has access to the
* given database object because of a group permission.
*
* @see checkUserPermission
*/ | Returns true if and only if the given user has access to the given database object because of a group permission | checkGroupPermission | {
"repo_name": "malikoski/sqlpower-library",
"path": "src/main/java/ca/sqlpower/security/PLSecurityManager.java",
"license": "gpl-3.0",
"size": 41504
} | [
"ca.sqlpower.sql.DatabaseObject",
"ca.sqlpower.sql.SQL",
"java.sql.Connection",
"java.sql.ResultSet",
"java.sql.SQLException",
"java.sql.Statement"
] | import ca.sqlpower.sql.DatabaseObject; import ca.sqlpower.sql.SQL; import java.sql.Connection; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; | import ca.sqlpower.sql.*; import java.sql.*; | [
"ca.sqlpower.sql",
"java.sql"
] | ca.sqlpower.sql; java.sql; | 242,580 |
protected E findDataPoint(float x, float y) {
float shortestDistance = Float.NaN;
E shortest = null;
for (Map.Entry<PointF, E> entry : mDataPoints.entrySet()) {
float x1 = entry.getKey().x;
float y1 = entry.getKey().y;
float x2 = x;
float y2 = ... | E function(float x, float y) { float shortestDistance = Float.NaN; E shortest = null; for (Map.Entry<PointF, E> entry : mDataPoints.entrySet()) { float x1 = entry.getKey().x; float y1 = entry.getKey().y; float x2 = x; float y2 = y; float distance = (float) Math.sqrt((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2)); if (shortest == n... | /**
* find the data point which is next to the
* coordinates
*
* @param x pixel
* @param y pixel
* @return the data point or null if nothing was found
*/ | find the data point which is next to the coordinates | findDataPoint | {
"repo_name": "kunal15595/quadapp",
"path": "GraphView/src/main/java/com/jjoe64/graphview/series/BaseSeries.java",
"license": "gpl-2.0",
"size": 15253
} | [
"android.graphics.PointF",
"java.util.Map"
] | import android.graphics.PointF; import java.util.Map; | import android.graphics.*; import java.util.*; | [
"android.graphics",
"java.util"
] | android.graphics; java.util; | 626,113 |
@Override
protected String createTransitUri(final ProcessContext context) {
final String protocol = TCP_VALUE.getValue();
final String host = context.getProperty(HOSTNAME).evaluateAttributeExpressions().getValue();
final String port = context.getProperty(PORT).evaluateAttributeExpression... | String function(final ProcessContext context) { final String protocol = TCP_VALUE.getValue(); final String host = context.getProperty(HOSTNAME).evaluateAttributeExpressions().getValue(); final String port = context.getProperty(PORT).evaluateAttributeExpressions().getValue(); return new StringBuilder().append(protocol).... | /**
* Creates a Universal Resource Identifier (URI) for this processor. Constructs a URI of the form TCP://< host >:< port > where the host and port
* values are taken from the configured property values.
*
* @param context
* - the current process context.
*
* @return The U... | values are taken from the configured property values | createTransitUri | {
"repo_name": "WilliamNouet/ApacheNiFi",
"path": "nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/PutTCP.java",
"license": "apache-2.0",
"size": 12775
} | [
"org.apache.nifi.processor.ProcessContext"
] | import org.apache.nifi.processor.ProcessContext; | import org.apache.nifi.processor.*; | [
"org.apache.nifi"
] | org.apache.nifi; | 2,458,540 |
@Test
public void testMatchWithRegeneratedAppliesToWithDifferentOrderProducts() throws ClassNotFoundException, NoSuchMethodException, SecurityException, IllegalAccessException, InstantiationException, IllegalArgumentException, InvocationTargetException {
ProductResourceImpl addon1 = new ProductResourceI... | void function() throws ClassNotFoundException, NoSuchMethodException, SecurityException, IllegalAccessException, InstantiationException, IllegalArgumentException, InvocationTargetException { ProductResourceImpl addon1 = new ProductResourceImpl(null); addon1.setAppliesTo(STRBase\STR); addon1.setType(ResourceType.ADDON);... | /**
* This checks that the order of entries in the appliesTo doesn't matter.
*
* @throws ClassNotFoundException
* @throws NoSuchMethodException
* @throws SecurityException
* @throws IllegalAccessException
* @throws InstantiationException
* @throws IllegalArgumentException
* ... | This checks that the order of entries in the appliesTo doesn't matter | testMatchWithRegeneratedAppliesToWithDifferentOrderProducts | {
"repo_name": "OpenLiberty/open-liberty",
"path": "dev/com.ibm.ws.repository_fat_shared/src/com/ibm/ws/repository/test/ProductResourceTest.java",
"license": "epl-1.0",
"size": 10222
} | [
"com.ibm.ws.repository.common.enums.ResourceType",
"com.ibm.ws.repository.resources.internal.ProductResourceImpl",
"java.lang.reflect.InvocationTargetException",
"org.junit.Assert"
] | import com.ibm.ws.repository.common.enums.ResourceType; import com.ibm.ws.repository.resources.internal.ProductResourceImpl; import java.lang.reflect.InvocationTargetException; import org.junit.Assert; | import com.ibm.ws.repository.common.enums.*; import com.ibm.ws.repository.resources.internal.*; import java.lang.reflect.*; import org.junit.*; | [
"com.ibm.ws",
"java.lang",
"org.junit"
] | com.ibm.ws; java.lang; org.junit; | 2,728,139 |
private int getInstanceCount(Map<String, String> properties) {
return (properties.containsKey(AppDeployer.COUNT_PROPERTY_KEY)) ?
Integer.valueOf(properties.get(AppDeployer.COUNT_PROPERTY_KEY)) : 1;
} | int function(Map<String, String> properties) { return (properties.containsKey(AppDeployer.COUNT_PROPERTY_KEY)) ? Integer.valueOf(properties.get(AppDeployer.COUNT_PROPERTY_KEY)) : 1; } | /**
* Return the app instance count indicated in the provided properties.
* @param properties properties for the app for which to determine the count
* @return instance count indicated in the provided properties;
* if the properties do not contain a count, a value of {@code 1} is returned
*/ | Return the app instance count indicated in the provided properties | getInstanceCount | {
"repo_name": "sabbyanandan/spring-cloud-dataflow",
"path": "spring-cloud-dataflow-server-core/src/main/java/org/springframework/cloud/dataflow/server/controller/StreamDeploymentController.java",
"license": "apache-2.0",
"size": 20811
} | [
"java.util.Map",
"org.springframework.cloud.deployer.spi.app.AppDeployer"
] | import java.util.Map; import org.springframework.cloud.deployer.spi.app.AppDeployer; | import java.util.*; import org.springframework.cloud.deployer.spi.app.*; | [
"java.util",
"org.springframework.cloud"
] | java.util; org.springframework.cloud; | 1,049,226 |
public void run(WorkflowInstanceDescr<?> wfInstanceDescr, Connection con) throws DuplicateIdException, CopperException;
| void function(WorkflowInstanceDescr<?> wfInstanceDescr, Connection con) throws DuplicateIdException, CopperException; | /**
* Enqueues the specified list of workflow instances into the engine for execution.
*
* @param wfInstanceDescr
* workflow instance descriptions to run
* @param con
* connection used for the inserting the workflow to the database
* @throws CopperExcepti... | Enqueues the specified list of workflow instances into the engine for execution | run | {
"repo_name": "benfortuna/copper-engine",
"path": "projects/copper-coreengine/src/main/java/org/copperengine/core/PersistentProcessingEngine.java",
"license": "apache-2.0",
"size": 3820
} | [
"java.sql.Connection"
] | import java.sql.Connection; | import java.sql.*; | [
"java.sql"
] | java.sql; | 2,066,734 |
@SuppressWarnings("unchecked")
public Collection<EsaResource> getMatchingEsas(ProductDefinition definition, Visibility visible) throws RepositoryBackendException {
Collection<EsaResource> ret = (Collection<EsaResource>) getResources(Collections.singleton(definition), Collections.singleton(ResourceType.F... | @SuppressWarnings(STR) Collection<EsaResource> function(ProductDefinition definition, Visibility visible) throws RepositoryBackendException { Collection<EsaResource> ret = (Collection<EsaResource>) getResources(Collections.singleton(definition), Collections.singleton(ResourceType.FEATURE), visible).get(ResourceType.FEA... | /**
* Get all features in the repositories that match the provided ProductDefinition (normally of the machine you are on)
* and the supplied visibility setting.
*
* @param loginInfo
* @param definition
* @param visible
* @return A collection of matching features
* @throws Reposit... | Get all features in the repositories that match the provided ProductDefinition (normally of the machine you are on) and the supplied visibility setting | getMatchingEsas | {
"repo_name": "ashleyrobertson/tool.lars",
"path": "client-lib/src/main/java/com/ibm/ws/repository/connections/RepositoryConnectionList.java",
"license": "apache-2.0",
"size": 29839
} | [
"com.ibm.ws.repository.common.enums.ResourceType",
"com.ibm.ws.repository.common.enums.Visibility",
"com.ibm.ws.repository.exceptions.RepositoryBackendException",
"com.ibm.ws.repository.resources.EsaResource",
"java.util.Collection",
"java.util.Collections"
] | import com.ibm.ws.repository.common.enums.ResourceType; import com.ibm.ws.repository.common.enums.Visibility; import com.ibm.ws.repository.exceptions.RepositoryBackendException; import com.ibm.ws.repository.resources.EsaResource; import java.util.Collection; import java.util.Collections; | import com.ibm.ws.repository.common.enums.*; import com.ibm.ws.repository.exceptions.*; import com.ibm.ws.repository.resources.*; import java.util.*; | [
"com.ibm.ws",
"java.util"
] | com.ibm.ws; java.util; | 1,454,727 |
public void exitRow_value_predicand_list(SQLParser.Row_value_predicand_listContext ctx) { } | public void exitRow_value_predicand_list(SQLParser.Row_value_predicand_listContext ctx) { } | /**
* {@inheritDoc}
*
* <p>The default implementation does nothing.</p>
*/ | The default implementation does nothing | enterRow_value_predicand_list | {
"repo_name": "HEIG-GAPS/slasher",
"path": "slasher.corrector/src/main/java/ch/gaps/slasher/corrector/SQLParserBaseListener.java",
"license": "mit",
"size": 73849
} | [
"ch.gaps.slasher.corrector.SQLParser"
] | import ch.gaps.slasher.corrector.SQLParser; | import ch.gaps.slasher.corrector.*; | [
"ch.gaps.slasher"
] | ch.gaps.slasher; | 761,285 |
Path stageInstall(Path availablePlugin) throws PluginRepositoryException; | Path stageInstall(Path availablePlugin) throws PluginRepositoryException; | /**
* Plugin is going to stage directory to be installed
* @param availablePlugin plugin that may be installed
*/ | Plugin is going to stage directory to be installed | stageInstall | {
"repo_name": "codenvy/che3",
"path": "plugin-tools/che-api-plugin/src/main/java/org/eclipse/che/plugin/internal/api/PluginRepository.java",
"license": "epl-1.0",
"size": 3373
} | [
"java.nio.file.Path"
] | import java.nio.file.Path; | import java.nio.file.*; | [
"java.nio"
] | java.nio; | 1,436,032 |
public static Icon createWithResource(String resPackage, @DrawableRes int resId) {
if (resPackage == null) {
throw new IllegalArgumentException("Resource package name must not be null.");
}
final Icon rep = new Icon(TYPE_RESOURCE);
rep.mInt1 = resId;
rep.mString1 ... | static Icon function(String resPackage, @DrawableRes int resId) { if (resPackage == null) { throw new IllegalArgumentException(STR); } final Icon rep = new Icon(TYPE_RESOURCE); rep.mInt1 = resId; rep.mString1 = resPackage; return rep; } | /**
* Create an Icon pointing to a drawable resource.
* @param resPackage Name of the package containing the resource in question
* @param resId ID of the drawable resource
*/ | Create an Icon pointing to a drawable resource | createWithResource | {
"repo_name": "OmniEvo/android_frameworks_base",
"path": "graphics/java/android/graphics/drawable/Icon.java",
"license": "gpl-3.0",
"size": 27504
} | [
"android.annotation.DrawableRes"
] | import android.annotation.DrawableRes; | import android.annotation.*; | [
"android.annotation"
] | android.annotation; | 161,603 |
private void runExample(GoogleAdsClient googleAdsClient, long customerId, long campaignId) {
// Creates a sitelink asset.
List<String> resourceNames = createSitelinkAssets(googleAdsClient, customerId);
// Associates the sitelinks at the campaign level.
linkSitelinksToCampaign(googleAdsClient, resource... | void function(GoogleAdsClient googleAdsClient, long customerId, long campaignId) { List<String> resourceNames = createSitelinkAssets(googleAdsClient, customerId); linkSitelinksToCampaign(googleAdsClient, resourceNames, customerId, campaignId); } | /**
* Runs the example.
*
* @param googleAdsClient the Google Ads API client.
* @param customerId the client customer ID.
* @param campaignId the campaign ID on which to add the sitelinks.
* @throws GoogleAdsException if an API request failed with one or more service errors.
*/ | Runs the example | runExample | {
"repo_name": "googleads/google-ads-java",
"path": "google-ads-examples/src/main/java/com/google/ads/googleads/examples/extensions/AddSitelinksUsingAssets.java",
"license": "apache-2.0",
"size": 9272
} | [
"com.google.ads.googleads.lib.GoogleAdsClient",
"java.util.List"
] | import com.google.ads.googleads.lib.GoogleAdsClient; import java.util.List; | import com.google.ads.googleads.lib.*; import java.util.*; | [
"com.google.ads",
"java.util"
] | com.google.ads; java.util; | 1,613,911 |
public static void recursiveSetBackground(Composite composite, Color color) {
composite.setBackground(color);
for (Control child : composite.getChildren()) {
if (child instanceof Composite) {
recursiveSetBackground((Composite)child, color);
} else {
child.setBackground(color);
... | static void function(Composite composite, Color color) { composite.setBackground(color); for (Control child : composite.getChildren()) { if (child instanceof Composite) { recursiveSetBackground((Composite)child, color); } else { child.setBackground(color); } } } | /**
* Recursively sets the background color for the composite and all its children.
*/ | Recursively sets the background color for the composite and all its children | recursiveSetBackground | {
"repo_name": "google/agi",
"path": "gapic/src/main/com/google/gapid/widgets/Widgets.java",
"license": "apache-2.0",
"size": 38823
} | [
"org.eclipse.swt.graphics.Color",
"org.eclipse.swt.widgets.Composite",
"org.eclipse.swt.widgets.Control"
] | import org.eclipse.swt.graphics.Color; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; | import org.eclipse.swt.graphics.*; import org.eclipse.swt.widgets.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 53,752 |
public void parseAttributesEvents( final byte[] data ) {
if ( data.length == 0 )
return;
setWrapper( data, ByteOrder.LITTLE_ENDIAN );
wrapper.getInt(); // Header (zeros)
// From version 1.2 there is an extra zero here!
if ( versionCompatibility.compareTo( VersionCompatibility.V_1_2 ) <= 0 )
wr... | void function( final byte[] data ) { if ( data.length == 0 ) return; setWrapper( data, ByteOrder.LITTLE_ENDIAN ); wrapper.getInt(); if ( versionCompatibility.compareTo( VersionCompatibility.V_1_2 ) <= 0 ) wrapper.get(); final List< Pair< Integer, String > > teamInfo1v1List = new ArrayList< Pair< Integer,String > >( 4 )... | /**
* Parses replay attributes events from the given data.
* @param data data of the replay details
*/ | Parses replay attributes events from the given data | parseAttributesEvents | {
"repo_name": "icza/sc2gears",
"path": "zprj-Sc2gears-parsing-engine/src/hu/belicza/andras/sc2gears/sc2replay/ReplayParser.java",
"license": "apache-2.0",
"size": 48410
} | [
"hu.belicza.andras.sc2gears.sc2replay.ReplayFactory",
"hu.belicza.andras.sc2gears.sc2replay.model.Details",
"hu.belicza.andras.sc2gearspluginapi.api.sc2replay.ReplayConsts",
"hu.belicza.andras.sc2gearspluginapi.impl.util.Pair",
"java.nio.ByteOrder",
"java.util.ArrayList",
"java.util.List"
] | import hu.belicza.andras.sc2gears.sc2replay.ReplayFactory; import hu.belicza.andras.sc2gears.sc2replay.model.Details; import hu.belicza.andras.sc2gearspluginapi.api.sc2replay.ReplayConsts; import hu.belicza.andras.sc2gearspluginapi.impl.util.Pair; import java.nio.ByteOrder; import java.util.ArrayList; import java.util.... | import hu.belicza.andras.sc2gears.sc2replay.*; import hu.belicza.andras.sc2gears.sc2replay.model.*; import hu.belicza.andras.sc2gearspluginapi.api.sc2replay.*; import hu.belicza.andras.sc2gearspluginapi.impl.util.*; import java.nio.*; import java.util.*; | [
"hu.belicza.andras",
"java.nio",
"java.util"
] | hu.belicza.andras; java.nio; java.util; | 1,618,854 |
public void addListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.addListener(notifyChangedListener);
} | void function(INotifyChangedListener notifyChangedListener) { changeNotifier.addListener(notifyChangedListener); } | /**
* This adds a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | This adds a listener. | addListener | {
"repo_name": "OpenSemanticsIO/semiotics-main",
"path": "bundles/io.opensemantics.semiotics.model.assessment.edit/src-gen/io/opensemantics/semiotics/model/assessment/provider/AssessmentItemProviderAdapterFactory.java",
"license": "apache-2.0",
"size": 24848
} | [
"org.eclipse.emf.edit.provider.INotifyChangedListener"
] | import org.eclipse.emf.edit.provider.INotifyChangedListener; | import org.eclipse.emf.edit.provider.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 1,865,504 |
protected void setProperties(Object bean, Map<String, Object> parameters) throws Exception {
setProperties(getCamelContext(), bean, parameters);
}
/**
* Sets the bean properties on the given bean using the given {@link CamelContext} | void function(Object bean, Map<String, Object> parameters) throws Exception { setProperties(getCamelContext(), bean, parameters); } /** * Sets the bean properties on the given bean using the given {@link CamelContext} | /**
* Sets the bean properties on the given bean
*
* @param bean the bean
* @param parameters properties to set
*/ | Sets the bean properties on the given bean | setProperties | {
"repo_name": "tkopczynski/camel",
"path": "camel-core/src/main/java/org/apache/camel/impl/DefaultComponent.java",
"license": "apache-2.0",
"size": 18446
} | [
"java.util.Map",
"org.apache.camel.CamelContext"
] | import java.util.Map; import org.apache.camel.CamelContext; | import java.util.*; import org.apache.camel.*; | [
"java.util",
"org.apache.camel"
] | java.util; org.apache.camel; | 2,613,920 |
public static void showFailureDialog(Activity activity, int actResp,
int errorCode) {
if (activity == null) {
Log.e("GameHelper", "*** No Activity. Can't show failure dialog!");
return;
}
Dialog errorDialog = null;
swi... | static void function(Activity activity, int actResp, int errorCode) { if (activity == null) { Log.e(STR, STR); return; } Dialog errorDialog = null; switch (actResp) { case GamesActivityResultCodes.RESULT_APP_MISCONFIGURED: errorDialog = makeSimpleDialog(activity, GameHelperUtils.getString( activity, GameHelperUtils.R_A... | /**
* Shows an error dialog that's appropriate for the failure reason.
*/ | Shows an error dialog that's appropriate for the failure reason | showFailureDialog | {
"repo_name": "Corbichon/2017",
"path": "app/src/main/java/com/corbel/pierre/p2017/lib/GameHelper.java",
"license": "gpl-3.0",
"size": 39112
} | [
"android.app.Activity",
"android.app.Dialog",
"android.util.Log",
"com.google.android.gms.common.GooglePlayServicesUtil",
"com.google.android.gms.games.GamesActivityResultCodes"
] | import android.app.Activity; import android.app.Dialog; import android.util.Log; import com.google.android.gms.common.GooglePlayServicesUtil; import com.google.android.gms.games.GamesActivityResultCodes; | import android.app.*; import android.util.*; import com.google.android.gms.common.*; import com.google.android.gms.games.*; | [
"android.app",
"android.util",
"com.google.android"
] | android.app; android.util; com.google.android; | 2,414,311 |
public void setAlternateSettings(String alternateSettings) throws IOException {
this.alternateSettings = alternateSettings;
save();
} | void function(String alternateSettings) throws IOException { this.alternateSettings = alternateSettings; save(); } | /**
* Sets the workspace-relative path to an alternative Maven settings.xml file.
*/ | Sets the workspace-relative path to an alternative Maven settings.xml file | setAlternateSettings | {
"repo_name": "sumitk1/jenkins",
"path": "maven-plugin/src/main/java/hudson/maven/MavenModuleSet.java",
"license": "mit",
"size": 32211
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,834,150 |
Socket socket = new Socket();
try {
InetSocketAddress is = new InetSocketAddress( host, port );
if ( timeout < 0 ) {
socket.connect( is );
} else {
socket.connect( is, timeout );
}
} catch ( Exception e ) {
throw new KettleException( e );
} finally {
try {... | Socket socket = new Socket(); try { InetSocketAddress is = new InetSocketAddress( host, port ); if ( timeout < 0 ) { socket.connect( is ); } else { socket.connect( is, timeout ); } } catch ( Exception e ) { throw new KettleException( e ); } finally { try { socket.close(); } catch ( Exception e ) { } } } | /**
* Attempts to connect to the specified host, wrapping any exceptions in a KettleException
*
* @param host
* the host to connect to
* @param port
* the port to connect to
* @param timeout
* the timeout
* @throws KettleException
*/ | Attempts to connect to the specified host, wrapping any exceptions in a KettleException | connectToHost | {
"repo_name": "IvanNikolaychuk/pentaho-kettle",
"path": "core/src/org/pentaho/di/core/util/SocketUtil.java",
"license": "apache-2.0",
"size": 1943
} | [
"java.net.InetSocketAddress",
"java.net.Socket",
"org.pentaho.di.core.exception.KettleException"
] | import java.net.InetSocketAddress; import java.net.Socket; import org.pentaho.di.core.exception.KettleException; | import java.net.*; import org.pentaho.di.core.exception.*; | [
"java.net",
"org.pentaho.di"
] | java.net; org.pentaho.di; | 1,590,036 |
public void setCreateSessionQuery(String createSessionQuery) {
Assert.hasText(createSessionQuery, "Query must not be empty");
this.createSessionQuery = getQuery(createSessionQuery);
} | void function(String createSessionQuery) { Assert.hasText(createSessionQuery, STR); this.createSessionQuery = getQuery(createSessionQuery); } | /**
* Set the custom SQL query used to create the session.
* @param createSessionQuery the SQL query string
*/ | Set the custom SQL query used to create the session | setCreateSessionQuery | {
"repo_name": "vpavic/spring-session",
"path": "spring-session-jdbc/src/main/java/org/springframework/session/jdbc/JdbcIndexedSessionRepository.java",
"license": "apache-2.0",
"size": 31700
} | [
"org.springframework.util.Assert"
] | import org.springframework.util.Assert; | import org.springframework.util.*; | [
"org.springframework.util"
] | org.springframework.util; | 1,482,137 |
final void load() {
synchronized (this) {
if (mHandler == null) {
mHandler = new Handler(this);
}
}
if (!mLoadListener.isSynchronous()) {
mHandler.sendEmptyMessage(MSG_STATUS);
} else {
// Load the stream synchronously.... | final void load() { synchronized (this) { if (mHandler == null) { mHandler = new Handler(this); } } if (!mLoadListener.isSynchronous()) { mHandler.sendEmptyMessage(MSG_STATUS); } else { if (setupStreamAndSendStatus()) { mData = new byte[8192]; sendHeaders(); while (!sendData() && !mLoadListener.cancelled()); closeStrea... | /**
* Calling this method starts the load of the content for this StreamLoader.
* This method simply creates a Handler in the current thread and posts a
* message to send the status and returns immediately.
*/ | Calling this method starts the load of the content for this StreamLoader. This method simply creates a Handler in the current thread and posts a message to send the status and returns immediately | load | {
"repo_name": "mateor/PDroidHistory",
"path": "frameworks/base/core/java/android/webkit/StreamLoader.java",
"license": "gpl-3.0",
"size": 7226
} | [
"android.os.Handler"
] | import android.os.Handler; | import android.os.*; | [
"android.os"
] | android.os; | 1,134,284 |
public Matcher<T> lessThan(T value) {
return new ComparatorMatcher<T>(comparator, value, ComparatorMatcher.LESS_THAN, ComparatorMatcher.LESS_THAN, includeComparatorInDescription);
} | Matcher<T> function(T value) { return new ComparatorMatcher<T>(comparator, value, ComparatorMatcher.LESS_THAN, ComparatorMatcher.LESS_THAN, includeComparatorInDescription); } | /**
* Creates a matcher of {@code T} object that matches when the examined object is
* less than the specified value, as reported by the {@code Comparator} used to
* create this builder.
* For example:
* <pre>assertThat(1, ComparatorMatcherBuilder.<Integer>usingNaturalOrdering().lessThan(... | Creates a matcher of T object that matches when the examined object is less than the specified value, as reported by the Comparator used to create this builder. For example: <code>assertThat(1, ComparatorMatcherBuilder.<Integer>usingNaturalOrdering().lessThan(2))</code> | lessThan | {
"repo_name": "vizewang/JavaHamcrest",
"path": "hamcrest-library/src/main/java/org/hamcrest/comparator/ComparatorMatcherBuilder.java",
"license": "bsd-3-clause",
"size": 7675
} | [
"org.hamcrest.Matcher"
] | import org.hamcrest.Matcher; | import org.hamcrest.*; | [
"org.hamcrest"
] | org.hamcrest; | 299,157 |
public static float getParentAbsoluteElevation(@NonNull View view) {
float absoluteElevation = 0;
ViewParent viewParent = view.getParent();
while (viewParent instanceof View) {
absoluteElevation += ViewCompat.getElevation((View) viewParent);
viewParent = viewParent.getParent();
}
retur... | static float function(@NonNull View view) { float absoluteElevation = 0; ViewParent viewParent = view.getParent(); while (viewParent instanceof View) { absoluteElevation += ViewCompat.getElevation((View) viewParent); viewParent = viewParent.getParent(); } return absoluteElevation; } | /**
* Returns the absolute elevation of the parent of the provided {@code view}, or in other words,
* the sum of the elevations of all ancestors of the {@code view}.
*/ | Returns the absolute elevation of the parent of the provided view, or in other words, the sum of the elevations of all ancestors of the view | getParentAbsoluteElevation | {
"repo_name": "material-components/material-components-android",
"path": "lib/java/com/google/android/material/internal/ViewUtils.java",
"license": "apache-2.0",
"size": 12519
} | [
"android.view.View",
"android.view.ViewParent",
"androidx.annotation.NonNull",
"androidx.core.view.ViewCompat"
] | import android.view.View; import android.view.ViewParent; import androidx.annotation.NonNull; import androidx.core.view.ViewCompat; | import android.view.*; import androidx.annotation.*; import androidx.core.view.*; | [
"android.view",
"androidx.annotation",
"androidx.core"
] | android.view; androidx.annotation; androidx.core; | 1,717,850 |
Expression computeIndex(Expression offset,
WinAggImplementor.SeekType seekType); | Expression computeIndex(Expression offset, WinAggImplementor.SeekType seekType); | /**
* Converts absolute index position of the given relative position.
* @param offset offset of the requested row
* @param seekType the type of offset (start of window, end of window, etc)
* @return absolute position of the requested row
*/ | Converts absolute index position of the given relative position | computeIndex | {
"repo_name": "arina-ielchiieva/calcite",
"path": "core/src/main/java/org/apache/calcite/adapter/enumerable/WinAggFrameResultContext.java",
"license": "apache-2.0",
"size": 2588
} | [
"org.apache.calcite.linq4j.tree.Expression"
] | import org.apache.calcite.linq4j.tree.Expression; | import org.apache.calcite.linq4j.tree.*; | [
"org.apache.calcite"
] | org.apache.calcite; | 1,197,453 |
private void storeSizeOfDialog() {
Dimension dim = getSize();
String store = dim.width + ";" + dim.height;
Globals.prefs.put(FindUnlinkedFilesDialog.GLOBAL_PREFS_DIALOG_SIZE_KEY, store);
} | void function() { Dimension dim = getSize(); String store = dim.width + ";" + dim.height; Globals.prefs.put(FindUnlinkedFilesDialog.GLOBAL_PREFS_DIALOG_SIZE_KEY, store); } | /**
* Stores the current size of this dialog persistently.
*/ | Stores the current size of this dialog persistently | storeSizeOfDialog | {
"repo_name": "tschechlovdev/jabref",
"path": "src/main/java/net/sf/jabref/gui/FindUnlinkedFilesDialog.java",
"license": "mit",
"size": 46115
} | [
"java.awt.Dimension",
"net.sf.jabref.Globals"
] | import java.awt.Dimension; import net.sf.jabref.Globals; | import java.awt.*; import net.sf.jabref.*; | [
"java.awt",
"net.sf.jabref"
] | java.awt; net.sf.jabref; | 758,080 |
public Entity<T> removeExcludeDefaultListeners()
{
childNode.removeChild("exclude-default-listeners");
return this;
}
// --------------------------------------------------------------------------------------------------------||
// ClassName: Entity ElementName: javaee:emptyType ElementType... | Entity<T> function() { childNode.removeChild(STR); return this; } | /**
* Removes the <code>exclude-default-listeners</code> element
* @return the current instance of <code>Entity<T></code>
*/ | Removes the <code>exclude-default-listeners</code> element | removeExcludeDefaultListeners | {
"repo_name": "forge/javaee-descriptors",
"path": "impl/src/main/java/org/jboss/shrinkwrap/descriptor/impl/orm10/EntityImpl.java",
"license": "epl-1.0",
"size": 47108
} | [
"org.jboss.shrinkwrap.descriptor.api.orm10.Entity"
] | import org.jboss.shrinkwrap.descriptor.api.orm10.Entity; | import org.jboss.shrinkwrap.descriptor.api.orm10.*; | [
"org.jboss.shrinkwrap"
] | org.jboss.shrinkwrap; | 1,769,112 |
@Override
public Method getMethod() {
return this.method;
} | Method function() { return this.method; } | /**
* getMethod: Returns the method (if any) associated with this route
* @return String The input name.
*/ | getMethod: Returns the method (if any) associated with this route | getMethod | {
"repo_name": "xtivia/xsf",
"path": "framework/src/main/java/com/xtivia/xsf/core/web/DefaultRoute.java",
"license": "lgpl-2.1",
"size": 6644
} | [
"java.lang.reflect.Method"
] | import java.lang.reflect.Method; | import java.lang.reflect.*; | [
"java.lang"
] | java.lang; | 143,578 |
EReference getExplicitSet_Features(); | EReference getExplicitSet_Features(); | /**
* Returns the meta object for the containment reference list '{@link org.tud.inf.st.mbt.features.ExplicitSet#getFeatures <em>Features</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference list '<em>Features</em>'.
* @see org.tud.inf.st.mbt.featur... | Returns the meta object for the containment reference list '<code>org.tud.inf.st.mbt.features.ExplicitSet#getFeatures Features</code>'. | getExplicitSet_Features | {
"repo_name": "paetti1988/qmate",
"path": "MATE/org.tud.inf.st.mbt.emf/src-gen/org/tud/inf/st/mbt/features/FeaturesPackage.java",
"license": "apache-2.0",
"size": 42307
} | [
"org.eclipse.emf.ecore.EReference"
] | import org.eclipse.emf.ecore.EReference; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 406,000 |
public static void assertClientExecutionTimerExecutorNotCreated(ClientExecutionTimer clientExecutionTimer) {
assertNull(clientExecutionTimer.getExecutor());
}
/**
* Assert response was buffered into memory to enforce the timeout on both connection
* established and reading of content
... | static void function(ClientExecutionTimer clientExecutionTimer) { assertNull(clientExecutionTimer.getExecutor()); } /** * Assert response was buffered into memory to enforce the timeout on both connection * established and reading of content * * @param responseProxy * Must by a spied {@link HttpResponseProxy} | /**
* Assert that the executor backing {@link ClientExecutionTimer} was never created or used
*
* @param clientExecutionTimer
*/ | Assert that the executor backing <code>ClientExecutionTimer</code> was never created or used | assertClientExecutionTimerExecutorNotCreated | {
"repo_name": "dagnir/aws-sdk-java",
"path": "aws-java-sdk-core/src/test/java/com/amazonaws/http/timers/ClientExecutionAndRequestTimerTestUtils.java",
"license": "apache-2.0",
"size": 10058
} | [
"com.amazonaws.http.response.HttpResponseProxy",
"com.amazonaws.http.timers.client.ClientExecutionTimer",
"org.junit.Assert"
] | import com.amazonaws.http.response.HttpResponseProxy; import com.amazonaws.http.timers.client.ClientExecutionTimer; import org.junit.Assert; | import com.amazonaws.http.response.*; import com.amazonaws.http.timers.client.*; import org.junit.*; | [
"com.amazonaws.http",
"org.junit"
] | com.amazonaws.http; org.junit; | 2,318,998 |
protected Object executeAttributeQueryMethod(AttributeQuery attributeQuery, Map<String, String> queryParameters,
boolean isSuggestQuery, String queryTerm) {
String queryMethodToCall = attributeQuery.getQueryMethodToCall();
MethodInvokerConfig queryMethodInvoker = attributeQuery.getQueryM... | Object function(AttributeQuery attributeQuery, Map<String, String> queryParameters, boolean isSuggestQuery, String queryTerm) { String queryMethodToCall = attributeQuery.getQueryMethodToCall(); MethodInvokerConfig queryMethodInvoker = attributeQuery.getQueryMethodInvokerConfig(); if (queryMethodInvoker == null) { query... | /**
* Prepares the method configured on the attribute query then performs the method invocation
*
* @param attributeQuery attribute query instance to execute
* @param queryParameters map of query parameters that provide values for the method arguments
* @param isSuggestQuery indicates whether t... | Prepares the method configured on the attribute query then performs the method invocation | executeAttributeQueryMethod | {
"repo_name": "bhutchinson/rice",
"path": "rice-framework/krad-web-framework/src/main/java/org/kuali/rice/krad/uif/service/impl/AttributeQueryServiceImpl.java",
"license": "apache-2.0",
"size": 22343
} | [
"java.util.ArrayList",
"java.util.List",
"java.util.Map",
"org.apache.commons.lang.StringUtils",
"org.kuali.rice.krad.uif.component.MethodInvokerConfig",
"org.kuali.rice.krad.uif.field.AttributeQuery"
] | import java.util.ArrayList; import java.util.List; import java.util.Map; import org.apache.commons.lang.StringUtils; import org.kuali.rice.krad.uif.component.MethodInvokerConfig; import org.kuali.rice.krad.uif.field.AttributeQuery; | import java.util.*; import org.apache.commons.lang.*; import org.kuali.rice.krad.uif.component.*; import org.kuali.rice.krad.uif.field.*; | [
"java.util",
"org.apache.commons",
"org.kuali.rice"
] | java.util; org.apache.commons; org.kuali.rice; | 489,032 |
public Return edit(final Parameter _parameter)
throws EFapsException
{
final BigDecimal crossTotal = parseBigDecimal(_parameter
.getParameterValue(CIFormSales.Sales_IncomingRetentionCertificateForm.crossTotal.name));
if (crossTotal.compareTo(BigDecimal.ZERO) > 0) ... | Return function(final Parameter _parameter) throws EFapsException { final BigDecimal crossTotal = parseBigDecimal(_parameter .getParameterValue(CIFormSales.Sales_IncomingRetentionCertificateForm.crossTotal.name)); if (crossTotal.compareTo(BigDecimal.ZERO) > 0) { editDoc(_parameter); } return new Return(); } | /**
* Executed from a Command execute event to edit.
*
* @param _parameter Parameter as passed from the eFaps API
* @return new Return
* @throws EFapsException on error
*/ | Executed from a Command execute event to edit | edit | {
"repo_name": "eFaps/eFapsApp-Sales",
"path": "src/main/efaps/ESJP/org/efaps/esjp/sales/document/IncomingRetentionCertificate_Base.java",
"license": "apache-2.0",
"size": 6854
} | [
"java.math.BigDecimal",
"org.efaps.admin.event.Parameter",
"org.efaps.admin.event.Return",
"org.efaps.esjp.ci.CIFormSales",
"org.efaps.esjp.sales.util.Sales",
"org.efaps.util.EFapsException"
] | import java.math.BigDecimal; import org.efaps.admin.event.Parameter; import org.efaps.admin.event.Return; import org.efaps.esjp.ci.CIFormSales; import org.efaps.esjp.sales.util.Sales; import org.efaps.util.EFapsException; | import java.math.*; import org.efaps.admin.event.*; import org.efaps.esjp.ci.*; import org.efaps.esjp.sales.util.*; import org.efaps.util.*; | [
"java.math",
"org.efaps.admin",
"org.efaps.esjp",
"org.efaps.util"
] | java.math; org.efaps.admin; org.efaps.esjp; org.efaps.util; | 1,221,119 |
public Attribute getAssociatedAttribute()
{
return new JobPriority(getValue());
} | Attribute function() { return new JobPriority(getValue()); } | /**
* Returns the equally enum of the standard attribute class
* of this DefaultValuesAttribute enum.
*
* @return The enum of the standard attribute class.
*/ | Returns the equally enum of the standard attribute class of this DefaultValuesAttribute enum | getAssociatedAttribute | {
"repo_name": "shaotuanchen/sunflower_exp",
"path": "tools/source/gcc-4.2.4/libjava/classpath/gnu/javax/print/ipp/attribute/defaults/JobPriorityDefault.java",
"license": "bsd-3-clause",
"size": 3586
} | [
"javax.print.attribute.Attribute",
"javax.print.attribute.standard.JobPriority"
] | import javax.print.attribute.Attribute; import javax.print.attribute.standard.JobPriority; | import javax.print.attribute.*; import javax.print.attribute.standard.*; | [
"javax.print"
] | javax.print; | 1,962,205 |
private long computeFreshnessLifetime() {
CacheControl responseCaching = cacheResponse.cacheControl();
if (responseCaching.maxAgeSeconds() != -1) {
return SECONDS.toMillis(responseCaching.maxAgeSeconds());
} else if (expires != null) {
long servedMillis = servedDate != null
... | long function() { CacheControl responseCaching = cacheResponse.cacheControl(); if (responseCaching.maxAgeSeconds() != -1) { return SECONDS.toMillis(responseCaching.maxAgeSeconds()); } else if (expires != null) { long servedMillis = servedDate != null ? servedDate.getTime() : receivedResponseMillis; long delta = expires... | /**
* Returns the number of milliseconds that the response was fresh for, starting from the served
* date.
*/ | Returns the number of milliseconds that the response was fresh for, starting from the served date | computeFreshnessLifetime | {
"repo_name": "twonde/NUll_logging-interceptor_set-deadline_to_okio-",
"path": "okhttp3/internal/http/CacheStrategy.java",
"license": "apache-2.0",
"size": 12292
} | [
"java.util.concurrent.TimeUnit"
] | import java.util.concurrent.TimeUnit; | import java.util.concurrent.*; | [
"java.util"
] | java.util; | 2,156,000 |
public static boolean createTag(Repository repository, String objectId, PersonIdent tagger, String tag, String message) {
try {
Git gitClient = Git.open(repository.getDirectory());
TagCommand tagCommand = gitClient.tag();
tagCommand.setTagger(tagger);
tagCommand.setMessage(message);
if (object... | static boolean function(Repository repository, String objectId, PersonIdent tagger, String tag, String message) { try { Git gitClient = Git.open(repository.getDirectory()); TagCommand tagCommand = gitClient.tag(); tagCommand.setTagger(tagger); tagCommand.setMessage(message); if (objectId != null) { RevObject revObj = g... | /**
* creates a tag in a repository
*
* @param repository
* @param objectId, the ref the tag points towards
* @param tagger, the person tagging the object
* @param tag, the string label
* @param message, the string message
* @return boolean, true if operation was successful, otherwise false
*... | creates a tag in a repository | createTag | {
"repo_name": "paulsputer/gitblit",
"path": "src/main/java/com/gitblit/utils/JGitUtils.java",
"license": "apache-2.0",
"size": 88271
} | [
"org.eclipse.jgit.api.Git",
"org.eclipse.jgit.api.TagCommand",
"org.eclipse.jgit.lib.PersonIdent",
"org.eclipse.jgit.lib.Ref",
"org.eclipse.jgit.lib.Repository",
"org.eclipse.jgit.revwalk.RevObject"
] | import org.eclipse.jgit.api.Git; import org.eclipse.jgit.api.TagCommand; import org.eclipse.jgit.lib.PersonIdent; import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevObject; | import org.eclipse.jgit.api.*; import org.eclipse.jgit.lib.*; import org.eclipse.jgit.revwalk.*; | [
"org.eclipse.jgit"
] | org.eclipse.jgit; | 173,595 |
public Collection<Collection<NodeDetail>> getPathList(PublicationPK pubPK); | Collection<Collection<NodeDetail>> function(PublicationPK pubPK); | /**
* Return list of all path to this publication - it's a Collection of NodeDetail collection
*
* @param pubPK the id of the publication
* @return a Collection of NodeDetail collection
* @see com.stratelia.webactiv.util.node.model.NodeDetail
* @since 1.0
*/ | Return list of all path to this publication - it's a Collection of NodeDetail collection | getPathList | {
"repo_name": "CecileBONIN/Silverpeas-Components",
"path": "kmelia/kmelia-ejb/src/main/java/com/stratelia/webactiv/kmelia/control/ejb/KmeliaBm.java",
"license": "agpl-3.0",
"size": 25457
} | [
"com.stratelia.webactiv.util.node.model.NodeDetail",
"com.stratelia.webactiv.util.publication.model.PublicationPK",
"java.util.Collection"
] | import com.stratelia.webactiv.util.node.model.NodeDetail; import com.stratelia.webactiv.util.publication.model.PublicationPK; import java.util.Collection; | import com.stratelia.webactiv.util.node.model.*; import com.stratelia.webactiv.util.publication.model.*; import java.util.*; | [
"com.stratelia.webactiv",
"java.util"
] | com.stratelia.webactiv; java.util; | 2,048,149 |
interface WithVirtualNetworkRules {
Update withVirtualNetworkRules(List<VirtualNetworkRule> virtualNetworkRules);
}
} | interface WithVirtualNetworkRules { Update withVirtualNetworkRules(List<VirtualNetworkRule> virtualNetworkRules); } } | /**
* Specifies virtualNetworkRules.
* @param virtualNetworkRules List of Virtual Network ACL rules configured for the Cosmos DB account
* @return the next update stage
*/ | Specifies virtualNetworkRules | withVirtualNetworkRules | {
"repo_name": "navalev/azure-sdk-for-java",
"path": "sdk/cosmosdb/mgmt-v2019_08_01/src/main/java/com/microsoft/azure/management/cosmosdb/v2019_08_01/DatabaseAccountGetResults.java",
"license": "mit",
"size": 18600
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 749,750 |
public static URL getURL (String ghubReferredObjectId, String host) throws MalformedURLException
{
return getURL (ghubReferredObjectId, host, port);
} | static URL function (String ghubReferredObjectId, String host) throws MalformedURLException { return getURL (ghubReferredObjectId, host, port); } | /**
* ghub:// with http://hostorip:port/CDMWeb/repo
*
* @param ghubReferredObjectId
* @return
*/ | ghub:// with HREF | getURL | {
"repo_name": "ihmc/nomads",
"path": "misc/java/us/ihmc/gst/util/GHubUtils.java",
"license": "gpl-3.0",
"size": 2443
} | [
"java.net.MalformedURLException"
] | import java.net.MalformedURLException; | import java.net.*; | [
"java.net"
] | java.net; | 2,735,974 |
boolean allowChildRowShift(QueryContext context, TableIterator rowIter)
{
return false;
} | boolean allowChildRowShift(QueryContext context, TableIterator rowIter) { return false; } | /**
* Returns true if shifing the child rows will make a difference.
*/ | Returns true if shifing the child rows will make a difference | allowChildRowShift | {
"repo_name": "christianchristensen/resin",
"path": "modules/resin/src/com/caucho/db/sql/IndexExpr.java",
"license": "gpl-2.0",
"size": 3977
} | [
"com.caucho.db.table.TableIterator"
] | import com.caucho.db.table.TableIterator; | import com.caucho.db.table.*; | [
"com.caucho.db"
] | com.caucho.db; | 1,928,802 |
@Test
public void testCompactFooterNestedTypeRegistration() throws Exception {
try (Ignite ignite = Ignition.start(Config.getServerConfiguration())) {
try (IgniteClient client = Ignition.startClient(new ClientConfiguration().setAddresses(Config.SERVER)
.setBinaryConfiguration... | void function() throws Exception { try (Ignite ignite = Ignition.start(Config.getServerConfiguration())) { try (IgniteClient client = Ignition.startClient(new ClientConfiguration().setAddresses(Config.SERVER) .setBinaryConfiguration(new BinaryConfiguration().setCompactFooter(true))) ) { IgniteCache<Integer, Person[]> i... | /**
* Check that binary types are registered for nested types too.
* With enabled "CompactFooter" binary type schema also should be passed to server.
*/ | Check that binary types are registered for nested types too. With enabled "CompactFooter" binary type schema also should be passed to server | testCompactFooterNestedTypeRegistration | {
"repo_name": "ascherbakoff/ignite",
"path": "modules/core/src/test/java/org/apache/ignite/client/IgniteBinaryTest.java",
"license": "apache-2.0",
"size": 16203
} | [
"org.apache.ignite.Ignite",
"org.apache.ignite.IgniteCache",
"org.apache.ignite.Ignition",
"org.apache.ignite.configuration.BinaryConfiguration",
"org.apache.ignite.configuration.ClientConfiguration",
"org.junit.Assert"
] | import org.apache.ignite.Ignite; import org.apache.ignite.IgniteCache; import org.apache.ignite.Ignition; import org.apache.ignite.configuration.BinaryConfiguration; import org.apache.ignite.configuration.ClientConfiguration; import org.junit.Assert; | import org.apache.ignite.*; import org.apache.ignite.configuration.*; import org.junit.*; | [
"org.apache.ignite",
"org.junit"
] | org.apache.ignite; org.junit; | 2,884,259 |
public static void writeStringValue(int hkey, String key, String valueName,
String value) throws IllegalArgumentException,
IllegalAccessException, InvocationTargetException {
if (hkey == HKEY_LOCAL_MACHINE) {
writeStringValue(systemRoot, hkey, key, valueName, value);
} else if (hkey == HKEY_CURRENT... | static void function(int hkey, String key, String valueName, String value) throws IllegalArgumentException, IllegalAccessException, InvocationTargetException { if (hkey == HKEY_LOCAL_MACHINE) { writeStringValue(systemRoot, hkey, key, valueName, value); } else if (hkey == HKEY_CURRENT_USER) { writeStringValue(userRoot, ... | /**
* Write a value in a given key/value name
*
* @param hkey
* @param key
* @param valueName
* @param value
* @throws IllegalArgumentException
* @throws IllegalAccessException
* @throws InvocationTargetException
*/ | Write a value in a given key/value name | writeStringValue | {
"repo_name": "grosca/yarta",
"path": "mselib/MSE-Middleware/src/fr/inria/arles/yarta/desktop/library/util/WinRegistry.java",
"license": "lgpl-3.0",
"size": 13461
} | [
"java.lang.reflect.InvocationTargetException"
] | import java.lang.reflect.InvocationTargetException; | import java.lang.reflect.*; | [
"java.lang"
] | java.lang; | 2,487,533 |
public void init(Properties properties) throws Exception; | void function(Properties properties) throws Exception; | /**
* initializes the Resource finder module
*
* @param properties properties, that need to initialize the module. These properties can be
* defined in pip-config.xml file
* @throws Exception throws when initialization is failed
*/ | initializes the Resource finder module | init | {
"repo_name": "jaadds/carbon-identity",
"path": "components/identity/org.wso2.carbon.identity.entitlement/src/main/java/org/wso2/carbon/identity/entitlement/pip/PIPResourceFinder.java",
"license": "apache-2.0",
"size": 3060
} | [
"java.util.Properties"
] | import java.util.Properties; | import java.util.*; | [
"java.util"
] | java.util; | 929,783 |
public void testEXPIRE_DESTROY() {
Operation op = Operation.EXPIRE_DESTROY;
assertFalse(op.isCreate());
assertFalse(op.isUpdate());
assertFalse(op.isInvalidate());
assertTrue(op.isDestroy());
assertFalse(op.isPutAll());
assertFalse(op.isRegionInvalidate());
assertFalse(op.isRegionDestr... | void function() { Operation op = Operation.EXPIRE_DESTROY; assertFalse(op.isCreate()); assertFalse(op.isUpdate()); assertFalse(op.isInvalidate()); assertTrue(op.isDestroy()); assertFalse(op.isPutAll()); assertFalse(op.isRegionInvalidate()); assertFalse(op.isRegionDestroy()); assertFalse(op.isRegion()); assertFalse(op.i... | /**
* Check EXPIRE_DESTROY Operation.
*/ | Check EXPIRE_DESTROY Operation | testEXPIRE_DESTROY | {
"repo_name": "robertgeiger/incubator-geode",
"path": "gemfire-core/src/test/java/com/gemstone/gemfire/cache/OperationJUnitTest.java",
"license": "apache-2.0",
"size": 28984
} | [
"com.gemstone.gemfire.cache.Operation"
] | import com.gemstone.gemfire.cache.Operation; | import com.gemstone.gemfire.cache.*; | [
"com.gemstone.gemfire"
] | com.gemstone.gemfire; | 1,480,444 |
protected Uri fromPluginUri(Uri pluginUri) {
return Uri.parse(pluginUri.getQueryParameter("origUri"));
} | Uri function(Uri pluginUri) { return Uri.parse(pluginUri.getQueryParameter(STR)); } | /**
* Refer to remapUri()
* Added in cordova-android@4.0.0
*/ | Refer to remapUri() Added in cordova-android@4.0.0 | fromPluginUri | {
"repo_name": "zendey/Zendey",
"path": "zendey/platforms/android/CordovaLib/src/org/apache/cordova/CordovaPlugin.java",
"license": "gpl-3.0",
"size": 15690
} | [
"android.net.Uri"
] | import android.net.Uri; | import android.net.*; | [
"android.net"
] | android.net; | 1,249,124 |
void expansionStart(Expansion e, boolean first); | void expansionStart(Expansion e, boolean first); | /**
* Output start of an Expansion.
* @param e Expansion being output
* @param first whether this is the first expansion
*/ | Output start of an Expansion | expansionStart | {
"repo_name": "amremam2004/javacc",
"path": "src/main/java/org/javacc/jjdoc/Generator.java",
"license": "bsd-3-clause",
"size": 4885
} | [
"org.javacc.parser.Expansion"
] | import org.javacc.parser.Expansion; | import org.javacc.parser.*; | [
"org.javacc.parser"
] | org.javacc.parser; | 2,826,197 |
@Test(timeout=600000)
public void testBlockInvalidationWhenRBWReplicaMissedInDN()
throws IOException, InterruptedException {
// This test cannot pass on Windows due to file locking enforcement. It will
// reject the attempt to delete the block file from the RBW folder.
assumeTrue(!Path.WINDOWS);
... | @Test(timeout=600000) void function() throws IOException, InterruptedException { assumeTrue(!Path.WINDOWS); Configuration conf = new HdfsConfiguration(); conf.setInt(DFSConfigKeys.DFS_REPLICATION_KEY, 2); conf.setLong(DFSConfigKeys.DFS_BLOCKREPORT_INTERVAL_MSEC_KEY, 300); conf.setLong(DFSConfigKeys.DFS_DATANODE_DIRECTO... | /**
* Test when a block's replica is removed from RBW folder in one of the
* datanode, namenode should ask to invalidate that corrupted block and
* schedule replication for one more replica for that under replicated block.
*/ | Test when a block's replica is removed from RBW folder in one of the datanode, namenode should ask to invalidate that corrupted block and schedule replication for one more replica for that under replicated block | testBlockInvalidationWhenRBWReplicaMissedInDN | {
"repo_name": "tseen/Federated-HDFS",
"path": "tseenliu/FedHDFS-hadoop-src/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestRBWBlockInvalidation.java",
"license": "apache-2.0",
"size": 9499
} | [
"java.io.File",
"java.io.IOException",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.fs.FSDataOutputStream",
"org.apache.hadoop.fs.FileSystem",
"org.apache.hadoop.fs.Path",
"org.apache.hadoop.hdfs.DFSConfigKeys",
"org.apache.hadoop.hdfs.DFSTestUtil",
"org.apache.hadoop.hdfs.HdfsConfigur... | import java.io.File; import java.io.IOException; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.FSDataOutputStream; import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hdfs.DFSConfigKeys; import org.apache.hadoop.hdfs.DFSTestUtil; import org.apach... | import java.io.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.hdfs.*; import org.apache.hadoop.hdfs.protocol.*; import org.apache.hadoop.hdfs.server.datanode.*; import org.apache.hadoop.hdfs.server.namenode.*; import org.junit.*; | [
"java.io",
"org.apache.hadoop",
"org.junit"
] | java.io; org.apache.hadoop; org.junit; | 61,558 |
CommandResponse execute(GwtCommand gwtCommand); | CommandResponse execute(GwtCommand gwtCommand); | /**
* Execute a <code>GwtCommandRequest</code>, and return the answer as a <code>CommandResponse</code>.
*
* @param gwtCommand
* The gwtCommand to be executed.
* @return The result.
*/ | Execute a <code>GwtCommandRequest</code>, and return the answer as a <code>CommandResponse</code> | execute | {
"repo_name": "geomajas/geomajas-project-client-gwt2",
"path": "common-gwt/command/src/main/java/org/geomajas/gwt/client/GeomajasService.java",
"license": "agpl-3.0",
"size": 1170
} | [
"org.geomajas.command.CommandResponse",
"org.geomajas.gwt.client.command.GwtCommand"
] | import org.geomajas.command.CommandResponse; import org.geomajas.gwt.client.command.GwtCommand; | import org.geomajas.command.*; import org.geomajas.gwt.client.command.*; | [
"org.geomajas.command",
"org.geomajas.gwt"
] | org.geomajas.command; org.geomajas.gwt; | 1,935,172 |
public List<MicrosoftGraphDirectoryObjectInner> rejectedSenders() {
return this.rejectedSenders;
} | List<MicrosoftGraphDirectoryObjectInner> function() { return this.rejectedSenders; } | /**
* Get the rejectedSenders property: The list of users or groups that are not allowed to create posts or calendar
* events in this group. Nullable.
*
* @return the rejectedSenders value.
*/ | Get the rejectedSenders property: The list of users or groups that are not allowed to create posts or calendar events in this group. Nullable | rejectedSenders | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-authorization/src/main/java/com/azure/resourcemanager/authorization/fluent/models/MicrosoftGraphGroupInner.java",
"license": "mit",
"size": 74957
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,780,084 |
@Test
public void ifFalse() throws Exception {
List<String> text = new ArrayList<>();
String json = TestUtils.getJsonString("inkfiles/conditional/iffalse.ink.json");
Story story = new Story(json);
TestUtils.nextAll(story, text);
Assert.assertEquals(1, text.size());
Assert.assertEquals("The value is 3... | void function() throws Exception { List<String> text = new ArrayList<>(); String json = TestUtils.getJsonString(STR); Story story = new Story(json); TestUtils.nextAll(story, text); Assert.assertEquals(1, text.size()); Assert.assertEquals(STR, text.get(0)); } | /**
* "- not evaluate the statement if the condition evaluates to false"
*/ | "- not evaluate the statement if the condition evaluates to false" | ifFalse | {
"repo_name": "bladecoder/blade-ink",
"path": "src/test/java/com/bladecoder/ink/runtime/test/ConditionalSpecTest.java",
"license": "mit",
"size": 13824
} | [
"com.bladecoder.ink.runtime.Story",
"java.util.ArrayList",
"java.util.List",
"org.junit.Assert"
] | import com.bladecoder.ink.runtime.Story; import java.util.ArrayList; import java.util.List; import org.junit.Assert; | import com.bladecoder.ink.runtime.*; import java.util.*; import org.junit.*; | [
"com.bladecoder.ink",
"java.util",
"org.junit"
] | com.bladecoder.ink; java.util; org.junit; | 1,279,884 |
public static String formatDate(final Date date, final String ifNull) {
if (date == null) {
return ifNull;
}
return formatDate(date);
} | static String function(final Date date, final String ifNull) { if (date == null) { return ifNull; } return formatDate(date); } | /**
* Format a date but return ifNull if null
*
* @param date
* @param ifNull
* @return
*/ | Format a date but return ifNull if null | formatDate | {
"repo_name": "ktakacs/sakai",
"path": "gradebookng/tool/src/java/org/sakaiproject/gradebookng/business/util/FormatHelper.java",
"license": "apache-2.0",
"size": 3608
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 2,678,888 |
Timestamp timestamp = null;
try {
SimpleDateFormat dateFormat = new SimpleDateFormat(
"yyyy-MM-dd hh:mm:ss.SSS");
Date parsedDate = dateFormat.parse(dateString);
timestamp = new Timestamp(parsedDate.getTime());
} catch (Exception e) {
e.printStackTrace();
}
return timestamp;
} | Timestamp timestamp = null; try { SimpleDateFormat dateFormat = new SimpleDateFormat( STR); Date parsedDate = dateFormat.parse(dateString); timestamp = new Timestamp(parsedDate.getTime()); } catch (Exception e) { e.printStackTrace(); } return timestamp; } | /**
* Convert date string to timestamp.
*
* @param dateString
* @return
*/ | Convert date string to timestamp | parseTimestamp | {
"repo_name": "VicCebedo/SeabedOHM",
"path": "src/com/seabed/util/Utilities.java",
"license": "gpl-2.0",
"size": 4871
} | [
"java.sql.Timestamp",
"java.text.SimpleDateFormat",
"java.util.Date"
] | import java.sql.Timestamp; import java.text.SimpleDateFormat; import java.util.Date; | import java.sql.*; import java.text.*; import java.util.*; | [
"java.sql",
"java.text",
"java.util"
] | java.sql; java.text; java.util; | 416,498 |
@MediumTest
@Feature({"TabContents"})
@Restriction(RESTRICTION_TYPE_PHONE)
public void testHideSelectionOnPhoneTabSwitcher() throws Exception {
// Setup
OverviewModeBehaviorWatcher showWatcher = new OverviewModeBehaviorWatcher(
getActivity().getLayoutManager(), true, fals... | @Feature({STR}) @Restriction(RESTRICTION_TYPE_PHONE) void function() throws Exception { OverviewModeBehaviorWatcher showWatcher = new OverviewModeBehaviorWatcher( getActivity().getLayoutManager(), true, false); OverviewModeBehaviorWatcher hideWatcher = new OverviewModeBehaviorWatcher( getActivity().getLayoutManager(), ... | /**
* Verify ContentView loses/gains focus on overview mode.
*
* @throws Exception
* @Feature({"TabContents"})
*/ | Verify ContentView loses/gains focus on overview mode | testHideSelectionOnPhoneTabSwitcher | {
"repo_name": "Chilledheart/chromium",
"path": "chrome/android/javatests/src/org/chromium/chrome/browser/ContentViewFocusTest.java",
"license": "bsd-3-clause",
"size": 7460
} | [
"android.view.View",
"org.chromium.base.test.util.Feature",
"org.chromium.base.test.util.Restriction",
"org.chromium.chrome.test.util.OverviewModeBehaviorWatcher"
] | import android.view.View; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; import org.chromium.chrome.test.util.OverviewModeBehaviorWatcher; | import android.view.*; import org.chromium.base.test.util.*; import org.chromium.chrome.test.util.*; | [
"android.view",
"org.chromium.base",
"org.chromium.chrome"
] | android.view; org.chromium.base; org.chromium.chrome; | 491,254 |
public void onBlockHarvested(World worldIn, BlockPos pos, IBlockState state, EntityPlayer player)
{
} | void function(World worldIn, BlockPos pos, IBlockState state, EntityPlayer player) { } | /**
* Called before the Block is set to air in the world. Called regardless of if the player's tool can actually
* collect this block
*/ | Called before the Block is set to air in the world. Called regardless of if the player's tool can actually collect this block | onBlockHarvested | {
"repo_name": "TheGreatAndPowerfulWeegee/wipunknown",
"path": "build/tmp/recompileMc/sources/net/minecraft/block/Block.java",
"license": "gpl-3.0",
"size": 129758
} | [
"net.minecraft.block.state.IBlockState",
"net.minecraft.entity.player.EntityPlayer",
"net.minecraft.util.math.BlockPos",
"net.minecraft.world.World"
] | import net.minecraft.block.state.IBlockState; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; | import net.minecraft.block.state.*; import net.minecraft.entity.player.*; import net.minecraft.util.math.*; import net.minecraft.world.*; | [
"net.minecraft.block",
"net.minecraft.entity",
"net.minecraft.util",
"net.minecraft.world"
] | net.minecraft.block; net.minecraft.entity; net.minecraft.util; net.minecraft.world; | 1,160,001 |
Set<Feature> importColors = nodeColors().getColors(node);
IBinding binding = node.resolveBinding();
Set<Feature> targetColors = null;
if (binding instanceof ITypeBinding) {
targetColors = javaElementColors().getColors(project(),
(ITypeBinding) binding);
importedTypes.put((ITypeBinding) bindin... | Set<Feature> importColors = nodeColors().getColors(node); IBinding binding = node.resolveBinding(); Set<Feature> targetColors = null; if (binding instanceof ITypeBinding) { targetColors = javaElementColors().getColors(project(), (ITypeBinding) binding); importedTypes.put((ITypeBinding) binding, importColors); } if (bin... | /**
* checks that the import declaration match the target types
*
* (import vs target types)
*/ | checks that the import declaration match the target types (import vs target types) | visit | {
"repo_name": "ckaestne/CIDE",
"path": "other/CIDE/src/coloredide/validator/checks/ImportValidator.java",
"license": "gpl-3.0",
"size": 2730
} | [
"java.util.Set",
"org.eclipse.jdt.core.dom.IBinding",
"org.eclipse.jdt.core.dom.IMethodBinding",
"org.eclipse.jdt.core.dom.ITypeBinding",
"org.eclipse.jdt.core.dom.IVariableBinding"
] | import java.util.Set; import org.eclipse.jdt.core.dom.IBinding; import org.eclipse.jdt.core.dom.IMethodBinding; import org.eclipse.jdt.core.dom.ITypeBinding; import org.eclipse.jdt.core.dom.IVariableBinding; | import java.util.*; import org.eclipse.jdt.core.dom.*; | [
"java.util",
"org.eclipse.jdt"
] | java.util; org.eclipse.jdt; | 74,289 |
private static Collection<String> getChildrenPropertyNames(String parent, Collection<String> properties) {
List<String> results = new ArrayList<String>();
for (String name : properties) {
if (name.startsWith(parent) && !name.equals(parent)) {
results.add(name);
... | static Collection<String> function(String parent, Collection<String> properties) { List<String> results = new ArrayList<String>(); for (String name : properties) { if (name.startsWith(parent) && !name.equals(parent)) { results.add(name); } } return results; } | /**
* Returns a child property names given a parent and an Iterator of property names.
*
* @param parent parent property name.
* @param properties all property names to search.
* @return an Iterator of child property names.
*/ | Returns a child property names given a parent and an Iterator of property names | getChildrenPropertyNames | {
"repo_name": "Gugli/Openfire",
"path": "src/plugins/fastpath/src/java/org/jivesoftware/xmpp/workgroup/dispatcher/RoundRobinDispatcher.java",
"license": "apache-2.0",
"size": 26948
} | [
"java.util.ArrayList",
"java.util.Collection",
"java.util.List"
] | import java.util.ArrayList; import java.util.Collection; import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,421,572 |
private static ArrayList<LatLngAlt> convertToLatLngAltArray(String coordinatesString) {
ArrayList<LatLngAlt> latLngAltsArray = new ArrayList<LatLngAlt>();
// Need to trim to avoid whitespace around the coordinates such as tabs
String[] coordinates = coordinatesString.trim().split("(\\s+)");
... | static ArrayList<LatLngAlt> function(String coordinatesString) { ArrayList<LatLngAlt> latLngAltsArray = new ArrayList<LatLngAlt>(); String[] coordinates = coordinatesString.trim().split(STR); for (String coordinate : coordinates) { latLngAltsArray.add(convertToLatLngAlt(coordinate)); } return latLngAltsArray; } | /**
* Convert a string of coordinates into an array of LatLngAlts
*
* @param coordinatesString coordinates string to convert from
* @return array of LatLngAlt objects created from the given coordinate string array
*/ | Convert a string of coordinates into an array of LatLngAlts | convertToLatLngAltArray | {
"repo_name": "googlemaps/android-maps-utils",
"path": "library/src/main/java/com/google/maps/android/data/kml/KmlFeatureParser.java",
"license": "apache-2.0",
"size": 19289
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 105,332 |
if (actionBarSupported()) {
activity.requestWindowFeature(Window.FEATURE_ACTION_BAR);
}
} | if (actionBarSupported()) { activity.requestWindowFeature(Window.FEATURE_ACTION_BAR); } } | /**
* Request the ActionBar window feature if we are on a supported Android
* version. This should be called before the activity's setContentView.
*
* @param activity
*/ | Request the ActionBar window feature if we are on a supported Android version. This should be called before the activity's setContentView | addActionBarIfSupported | {
"repo_name": "lyft/card.io-Android-source",
"path": "card.io/src/main/java/io/card/payment/ui/ActivityHelper.java",
"license": "mit",
"size": 4279
} | [
"android.view.Window"
] | import android.view.Window; | import android.view.*; | [
"android.view"
] | android.view; | 129,579 |
private void fileSetBuildingTime() {
PrintWriter pw;
try {
pw = new PrintWriter(Settings.sBuildingVersionFileName);
pw.println(EncryptionManager.encrypt64bits(Settings.nBuildingTimes + ""));
pw.println(EncryptionManager.encrypt64bits(Settings.clientVersion));
pw.close();
} catch (FileNotFoundExcept... | void function() { PrintWriter pw; try { pw = new PrintWriter(Settings.sBuildingVersionFileName); pw.println(EncryptionManager.encrypt64bits(Settings.nBuildingTimes + STRserverinfo.jrc do not exist"); } catch (Exception e) { e.printStackTrace(); } } | /**
* save the build time information into serverinfo.jrc using encrypt 64 bits
*/ | save the build time information into serverinfo.jrc using encrypt 64 bits | fileSetBuildingTime | {
"repo_name": "jrcforever/JavaFX_Game_Client",
"path": "src/J_R_C/JOGL/BaseGame/LoginMain.java",
"license": "mit",
"size": 3525
} | [
"java.io.PrintWriter"
] | import java.io.PrintWriter; | import java.io.*; | [
"java.io"
] | java.io; | 697,665 |
public String getHtml() {
if (type != GridStaticCellType.HTML) {
throw new IllegalStateException(
"Cannot fetch HTML from a cell with type " + type);
}
return (String) content;
} | String function() { if (type != GridStaticCellType.HTML) { throw new IllegalStateException( STR + type); } return (String) content; } | /**
* Returns the html inside the cell.
*
* @throws IllegalStateException
* if trying to retrive HTML from a cell with a type
* other than {@link GridStaticCellType#HTML}.
* @return the html content of the cell.
... | Returns the html inside the cell | getHtml | {
"repo_name": "Peppe/vaadin",
"path": "client/src/com/vaadin/client/widgets/Grid.java",
"license": "apache-2.0",
"size": 306271
} | [
"com.vaadin.shared.ui.grid.GridStaticCellType"
] | import com.vaadin.shared.ui.grid.GridStaticCellType; | import com.vaadin.shared.ui.grid.*; | [
"com.vaadin.shared"
] | com.vaadin.shared; | 1,832,243 |
public void set(int index, UInt4Holder holder) {
BitVectorHelper.setValidityBitToOne(validityBuffer, index);
setValue(index, holder.value);
} | void function(int index, UInt4Holder holder) { BitVectorHelper.setValidityBitToOne(validityBuffer, index); setValue(index, holder.value); } | /**
* Set the element at the given index to the value set in data holder.
*
* @param index position of element
* @param holder data holder for value of element
*/ | Set the element at the given index to the value set in data holder | set | {
"repo_name": "yufeldman/arrow",
"path": "java/vector/src/main/java/org/apache/arrow/vector/UInt4Vector.java",
"license": "apache-2.0",
"size": 9017
} | [
"org.apache.arrow.vector.holders.UInt4Holder"
] | import org.apache.arrow.vector.holders.UInt4Holder; | import org.apache.arrow.vector.holders.*; | [
"org.apache.arrow"
] | org.apache.arrow; | 172,033 |
public void setTPersonKey(ObjectKey key) throws TorqueException
{
setPerson(new Integer(((NumberKey) key).intValue()));
}
private static List<String> fieldNames = null; | void function(ObjectKey key) throws TorqueException { setPerson(new Integer(((NumberKey) key).intValue())); } private static List<String> fieldNames = null; | /**
* Provides convenient way to set a relationship based on a
* ObjectKey, for example
* <code>bar.setFooKey(foo.getPrimaryKey())</code>
*
*/ | Provides convenient way to set a relationship based on a ObjectKey, for example <code>bar.setFooKey(foo.getPrimaryKey())</code> | setTPersonKey | {
"repo_name": "trackplus/Genji",
"path": "src/main/java/com/aurel/track/persist/BaseTPersonBasket.java",
"license": "gpl-3.0",
"size": 36701
} | [
"java.util.List",
"org.apache.torque.TorqueException",
"org.apache.torque.om.NumberKey",
"org.apache.torque.om.ObjectKey"
] | import java.util.List; import org.apache.torque.TorqueException; import org.apache.torque.om.NumberKey; import org.apache.torque.om.ObjectKey; | import java.util.*; import org.apache.torque.*; import org.apache.torque.om.*; | [
"java.util",
"org.apache.torque"
] | java.util; org.apache.torque; | 1,794,173 |
public void insertFdbSiteUpdate(long siteId, String regionName, long fdbId, boolean successful, String message,
Date lastUpdate, TimeZone timeZone) {
String sql = "insert into datup.fdb_site_update(site_id, region_name, fdb_id, is_successful, message, Last_Update_Time, L... | void function(long siteId, String regionName, long fdbId, boolean successful, String message, Date lastUpdate, TimeZone timeZone) { String sql = STR + STR; Object[] params = new Object[] {siteId, regionName, fdbId, successful ? "Y" : "N", message, lastUpdate, timeZone.getID()}; int[] types = new int[] {Types.INTEGER, T... | /**
* Insert new FDB site update record.
*
* @param siteId site ID
* @param regionName region name
* @param fdbId FDB Version ID
* @param successful true if update successful
* @param message update status message
* @param lastUpdate when update occurred
* @param timeZone c... | Insert new FDB site update record | insertFdbSiteUpdate | {
"repo_name": "OSEHRA-Sandbox/MOCHA",
"path": "src/gov/va/med/pharmacy/peps/updater/common/database/SiteUpdate.java",
"license": "apache-2.0",
"size": 16411
} | [
"java.sql.Types",
"java.util.Date",
"java.util.TimeZone"
] | import java.sql.Types; import java.util.Date; import java.util.TimeZone; | import java.sql.*; import java.util.*; | [
"java.sql",
"java.util"
] | java.sql; java.util; | 2,605,478 |
private boolean checkModeMatch(GridDeploymentInfo dep, GridDeploymentMetadata meta) {
if (dep.deployMode() != meta.deploymentMode()) {
U.warn(log, "Received invalid deployment mode (will not deploy, make sure that all nodes " +
"executing the same classes in shared mode have iden... | boolean function(GridDeploymentInfo dep, GridDeploymentMetadata meta) { if (dep.deployMode() != meta.deploymentMode()) { U.warn(log, STR + STR + meta.deploymentMode() + STR + dep.deployMode() + ']'); return false; } return true; } | /**
* Checks if deployment modes match.
*
* @param dep Shared deployment.
* @param meta Request metadata.
* @return {@code True} if shared deployment modes match.
*/ | Checks if deployment modes match | checkModeMatch | {
"repo_name": "shroman/ignite",
"path": "modules/core/src/main/java/org/apache/ignite/internal/managers/deployment/GridDeploymentPerVersionStore.java",
"license": "apache-2.0",
"size": 49760
} | [
"org.apache.ignite.internal.util.typedef.internal.U"
] | import org.apache.ignite.internal.util.typedef.internal.U; | import org.apache.ignite.internal.util.typedef.internal.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 460,112 |
private TreeMap<byte[], StoreFile> processResults() throws IOException {
TreeMap<byte[], StoreFile> newStripes = null;
for (StoreFile sf : this.results) {
byte[] startRow = startOf(sf), endRow = endOf(sf);
if (isInvalid(endRow) || isInvalid(startRow)) {
if (!isFlush) {
... | TreeMap<byte[], StoreFile> function() throws IOException { TreeMap<byte[], StoreFile> newStripes = null; for (StoreFile sf : this.results) { byte[] startRow = startOf(sf), endRow = endOf(sf); if (isInvalid(endRow) isInvalid(startRow)) { if (!isFlush) { LOG.warn(STR + sf.getPath()); } insertFileIntoStripe(getLevel0Copy(... | /**
* Process new files, and add them either to the structure of existing stripes,
* or to the list of new candidate stripes.
* @return New candidate stripes.
*/ | Process new files, and add them either to the structure of existing stripes, or to the list of new candidate stripes | processResults | {
"repo_name": "amyvmiwei/hbase",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/StripeStoreFileManager.java",
"license": "apache-2.0",
"size": 41752
} | [
"java.io.IOException",
"java.util.TreeMap",
"org.apache.hadoop.hbase.util.Bytes"
] | import java.io.IOException; import java.util.TreeMap; import org.apache.hadoop.hbase.util.Bytes; | import java.io.*; import java.util.*; import org.apache.hadoop.hbase.util.*; | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 2,229,975 |
public IImplementationVersion getVersion ();
| IImplementationVersion function (); | /**
* Returns the server implementation version.
* @return
*/ | Returns the server implementation version | getVersion | {
"repo_name": "Evil-Co-Legacy/Flowerpot",
"path": "api/src/main/java/com/evilco/flowerpot/api/IProxyServer.java",
"license": "apache-2.0",
"size": 2200
} | [
"com.evilco.flowerpot.api.version.IImplementationVersion"
] | import com.evilco.flowerpot.api.version.IImplementationVersion; | import com.evilco.flowerpot.api.version.*; | [
"com.evilco.flowerpot"
] | com.evilco.flowerpot; | 1,339,936 |
void done(final RequestStatus error); | void done(final RequestStatus error); | /**
* Method called when the operation has been finished.
* @param requestStatus Indication of if any error happened or not
*/ | Method called when the operation has been finished | done | {
"repo_name": "jiahaoliuliu/NearestRestaurants",
"path": "src/com/jiahaoliuliu/nearestrestaurants/interfaces/ErrorCallback.java",
"license": "apache-2.0",
"size": 434
} | [
"com.jiahaoliuliu.nearestrestaurants.session.ErrorHandler"
] | import com.jiahaoliuliu.nearestrestaurants.session.ErrorHandler; | import com.jiahaoliuliu.nearestrestaurants.session.*; | [
"com.jiahaoliuliu.nearestrestaurants"
] | com.jiahaoliuliu.nearestrestaurants; | 805,218 |
@Override
public void accept(final MethodVisitor mv) {
switch (type) {
case Opcodes.F_NEW:
case Opcodes.F_FULL:
mv.visitFrame(type, local.size(), asArray(local), stack.size(),
asArray(stack));
break;
case Opcodes.F_APPEND:
m... | void function(final MethodVisitor mv) { switch (type) { case Opcodes.F_NEW: case Opcodes.F_FULL: mv.visitFrame(type, local.size(), asArray(local), stack.size(), asArray(stack)); break; case Opcodes.F_APPEND: mv.visitFrame(type, local.size(), asArray(local), 0, null); break; case Opcodes.F_CHOP: mv.visitFrame(type, loca... | /**
* Makes the given visitor visit this stack map frame.
*
* @param mv
* a method visitor.
*/ | Makes the given visitor visit this stack map frame | accept | {
"repo_name": "ArcherFeel/AWACS",
"path": "awacs-plugin/awacs-stacktrace-plugin/src/main/java/io/awacs/plugin/org/objectweb/asm/tree/FrameNode.java",
"license": "apache-2.0",
"size": 7979
} | [
"io.awacs.plugin.org.objectweb.asm.MethodVisitor",
"io.awacs.plugin.org.objectweb.asm.Opcodes"
] | import io.awacs.plugin.org.objectweb.asm.MethodVisitor; import io.awacs.plugin.org.objectweb.asm.Opcodes; | import io.awacs.plugin.org.objectweb.asm.*; | [
"io.awacs.plugin"
] | io.awacs.plugin; | 2,559,995 |
public GraphWalk<GraphTuple,? extends DefaultWeightedEdge> findRouteFor(WeightedGraph<GraphTuple, DefaultWeightedEdge> graph, GraphTuple source);
| GraphWalk<GraphTuple,? extends DefaultWeightedEdge> function(WeightedGraph<GraphTuple, DefaultWeightedEdge> graph, GraphTuple source); | /**
* Finds a possible location for a single annotation.
* @param graph The graph that will be used to find a route.
* @param source A node, designating the location of the annotated word. The annotation's information will be retrieved from the node's annotation object.
* @return A GraphWalk containing either t... | Finds a possible location for a single annotation | findRouteFor | {
"repo_name": "e1125755/AnnotationRouting",
"path": "Eclipse/Labeling/src/routingapp/Routing.java",
"license": "gpl-3.0",
"size": 1757
} | [
"org.jgrapht.WeightedGraph",
"org.jgrapht.graph.DefaultWeightedEdge",
"org.jgrapht.graph.GraphWalk"
] | import org.jgrapht.WeightedGraph; import org.jgrapht.graph.DefaultWeightedEdge; import org.jgrapht.graph.GraphWalk; | import org.jgrapht.*; import org.jgrapht.graph.*; | [
"org.jgrapht",
"org.jgrapht.graph"
] | org.jgrapht; org.jgrapht.graph; | 527,759 |
public static List<byte[]> loadDataChunks(final AbstractSQLProvider provider, final CModule module)
throws SQLException {
final List<byte[]> dataList = new ArrayList<>();
final String query =
"SELECT data FROM " + CTableNames.DATA_PARTS_TABLE + " WHERE module_id = "
+ module.getConf... | static List<byte[]> function(final AbstractSQLProvider provider, final CModule module) throws SQLException { final List<byte[]> dataList = new ArrayList<>(); final String query = STR + CTableNames.DATA_PARTS_TABLE + STR + module.getConfiguration().getId() + STR; try (ResultSet resultSet = provider.executeQuery(query)) ... | /**
* Loads the individual data chunks of module data from the database.
*
* The module must be stored in the database connected to by the provider argument.
*
* @param provider Provides the connection to the database.
* @param module The module whose data chunks are loaded.
*
* @return A lis... | Loads the individual data chunks of module data from the database. The module must be stored in the database connected to by the provider argument | loadDataChunks | {
"repo_name": "ant4g0nist/binnavi",
"path": "src/main/java/com/google/security/zynamics/binnavi/Database/PostgreSQL/Functions/PostgreSQLDataFunctions.java",
"license": "apache-2.0",
"size": 5377
} | [
"com.google.security.zynamics.binnavi.Database",
"com.google.security.zynamics.binnavi.disassembly.Modules",
"java.sql.ResultSet",
"java.sql.SQLException",
"java.util.ArrayList",
"java.util.List"
] | import com.google.security.zynamics.binnavi.Database; import com.google.security.zynamics.binnavi.disassembly.Modules; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; | import com.google.security.zynamics.binnavi.*; import com.google.security.zynamics.binnavi.disassembly.*; import java.sql.*; import java.util.*; | [
"com.google.security",
"java.sql",
"java.util"
] | com.google.security; java.sql; java.util; | 589,150 |
public void setInfo(String text)
{
if (text != null && text.length() > 0)
{
String prefix = "Result for: <span class=\"" + Helper.CORPUS_FONT_FORCE + "\">";
lblInfo.setDescription(prefix + text.replaceAll("\n", " ") + "</span>");
lblInfo.setValue(text.length() < 50 ? prefix + StringEscapeU... | void function(String text) { if (text != null && text.length() > 0) { String prefix = STRSTR\">"; lblInfo.setDescription(prefix + text.replaceAll("\n", " ") + STR); lblInfo.setValue(text.length() < 50 ? prefix + StringEscapeUtils. escapeHtml4(text.substring(0, text.length())) : prefix + StringEscapeUtils. escapeHtml4(t... | /**
* Cuts off long queries. Actually they are restricted to 50 characters. The
* full query is available with descriptions (tooltip in gui)
*
* @param text the query to display in the result view panel
*/ | Cuts off long queries. Actually they are restricted to 50 characters. The full query is available with descriptions (tooltip in gui) | setInfo | {
"repo_name": "zangsir/ANNIS",
"path": "annis-gui/src/main/java/annis/gui/paging/PagingComponent.java",
"license": "apache-2.0",
"size": 11593
} | [
"com.vaadin.data.validator.AbstractStringValidator",
"org.apache.commons.lang3.StringEscapeUtils"
] | import com.vaadin.data.validator.AbstractStringValidator; import org.apache.commons.lang3.StringEscapeUtils; | import com.vaadin.data.validator.*; import org.apache.commons.lang3.*; | [
"com.vaadin.data",
"org.apache.commons"
] | com.vaadin.data; org.apache.commons; | 2,702,674 |
public void removeRelatedFile(List<String> fileNames)
{
for (String name : fileNames)
{
File f = new File(name);
String dir = f.getParent();
if (dir == null) // avoid null point exception
{
dir = ".";
}
String fileName = f.getName();
File directory = new File(dir);
ThumbNailFileFilte... | void function(List<String> fileNames) { for (String name : fileNames) { File f = new File(name); String dir = f.getParent(); if (dir == null) { dir = "."; } String fileName = f.getName(); File directory = new File(dir); ThumbNailFileFilter tnff = new ThumbNailFileFilter(); tnff.setPattern(fileName+"["); String[] filter... | /**
* Remove all thumb nail images
* @param fileNames
*/ | Remove all thumb nail images | removeRelatedFile | {
"repo_name": "NCIP/national-biomedical-image-archive",
"path": "software/nbia-dao/src/gov/nih/nci/nbia/deletion/ImageFileDeletionServiceImpl.java",
"license": "bsd-3-clause",
"size": 3018
} | [
"java.io.File",
"java.util.List"
] | import java.io.File; import java.util.List; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 158,257 |
public void run() {
while (!isInterrupted()) {
try {
// Wait for an event one of the registered channels
this.selector.select();
// Iterate over the set of keys for which events are available
Iterator<SelectionKey> selectedKeys = this.selecto... | void function() { while (!isInterrupted()) { try { this.selector.select(); Iterator<SelectionKey> selectedKeys = this.selector.selectedKeys().iterator(); while (selectedKeys.hasNext()) { SelectionKey key = selectedKeys.next(); selectedKeys.remove(); if (!key.isValid()) { continue; } if (key.isAcceptable()) { this.accep... | /**
* As long as we are not interrupted,
* work on async-IO -requests.
*/ | As long as we are not interrupted, work on async-IO -requests | run | {
"repo_name": "xafero/travelingsales",
"path": "osmnavigation/src/main/java/org/openstreetmap/travelingsalesman/gps/gpsdemulation/MiniGPSD.java",
"license": "gpl-3.0",
"size": 15803
} | [
"java.io.IOException",
"java.nio.channels.SelectionKey",
"java.util.Iterator",
"java.util.logging.Level"
] | import java.io.IOException; import java.nio.channels.SelectionKey; import java.util.Iterator; import java.util.logging.Level; | import java.io.*; import java.nio.channels.*; import java.util.*; import java.util.logging.*; | [
"java.io",
"java.nio",
"java.util"
] | java.io; java.nio; java.util; | 819,742 |
public int nextHashForEqual() {
throw new SubclassResponsibilityException();
} | int function() { throw new SubclassResponsibilityException(); } | /**
* Shepherds use a sequence number for their hash. The most trivial (reasonable)
* implementation just uses a BatchCounter. This will not be persistent till we get
* Turtles.
*/ | Shepherds use a sequence number for their hash. The most trivial (reasonable) implementation just uses a BatchCounter. This will not be persistent till we get Turtles | nextHashForEqual | {
"repo_name": "jonesd/udanax-gold2java",
"path": "abora-gold/src/generated-sources/translator/info/dgjones/abora/gold/snarf/DiskManager.java",
"license": "mit",
"size": 23713
} | [
"info.dgjones.abora.gold.java.exception.SubclassResponsibilityException"
] | import info.dgjones.abora.gold.java.exception.SubclassResponsibilityException; | import info.dgjones.abora.gold.java.exception.*; | [
"info.dgjones.abora"
] | info.dgjones.abora; | 2,766,364 |
private CSVFormat configureHeaders(final String document, final CSVFormat format)
throws IOException {
if (hasHeaders(format, document)) {
return format.withFirstRecordAsHeader();
}
return format;
} | CSVFormat function(final String document, final CSVFormat format) throws IOException { if (hasHeaders(format, document)) { return format.withFirstRecordAsHeader(); } return format; } | /**
* Configure headers.
*
* @param document the document
* @param format the format
* @return the CSV format
* @throws IOException Signals that an I/O exception has occurred.
*/ | Configure headers | configureHeaders | {
"repo_name": "commitd/krill",
"path": "src/main/java/io/committed/krill/extraction/tika/parsers/CsvParser.java",
"license": "apache-2.0",
"size": 8648
} | [
"java.io.IOException",
"org.apache.commons.csv.CSVFormat"
] | import java.io.IOException; import org.apache.commons.csv.CSVFormat; | import java.io.*; import org.apache.commons.csv.*; | [
"java.io",
"org.apache.commons"
] | java.io; org.apache.commons; | 248,776 |
private static String FOLDERCSV;
@SuppressWarnings("deprecation")
public static void killThread() {
if (started) {
b.stop();
// progressBar.close();
Display.getDefault().syncExec(new Runnable() {
| static String FOLDERCSV; @SuppressWarnings(STR) public static void function() { if (started) { b.stop(); Display.getDefault().syncExec(new Runnable() { | /**
* Kills the active Import.
*/ | Kills the active Import | killThread | {
"repo_name": "tmfev/IDRT-Import-and-Mapping-Tool",
"path": "de.umg.mi.idrt.importtool/src/de/umg/mi/idrt/idrtimporttool/ImportWizard/DBImportWizard.java",
"license": "gpl-2.0",
"size": 14593
} | [
"org.eclipse.swt.widgets.Display"
] | import org.eclipse.swt.widgets.Display; | import org.eclipse.swt.widgets.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 944,366 |
public Locale getLocale() {
return this.locale;
} | Locale function() { return this.locale; } | /**
* Get the <code>Locale</code> stored by a previous invocation to
* {@link #setLocale}. If this method returns non <code>null</code>,
* this <code>Locale</code> must be used for all localization needs
* in the implementation. The <code>Locale</code> must not be cached
* to allow for appl... | Get the <code>Locale</code> stored by a previous invocation to <code>#setLocale</code>. If this method returns non <code>null</code>, this <code>Locale</code> must be used for all localization needs in the implementation. The <code>Locale</code> must not be cached to allow for applications that change <code>Locale</cod... | getLocale | {
"repo_name": "jboss/jboss-el-api_spec",
"path": "src/main/java/javax/el/ELContext.java",
"license": "gpl-2.0",
"size": 18058
} | [
"java.util.Locale"
] | import java.util.Locale; | import java.util.*; | [
"java.util"
] | java.util; | 1,587,067 |
List<PlatformSensorTypeConfig> getPlatformSensorTypes() throws StorageException; | List<PlatformSensorTypeConfig> getPlatformSensorTypes() throws StorageException; | /**
* Returns a {@link List} of the {@link PlatformSensorTypeConfig} classes.
*
* @return A {@link List} of {@link PlatformSensorTypeConfig} classes.
* @throws StorageException
* If agent configuration is not set.
*/ | Returns a <code>List</code> of the <code>PlatformSensorTypeConfig</code> classes | getPlatformSensorTypes | {
"repo_name": "inspectIT/inspectIT",
"path": "inspectit.agent.java/src/main/java/rocks/inspectit/agent/java/config/IConfigurationStorage.java",
"license": "agpl-3.0",
"size": 6867
} | [
"java.util.List",
"rocks.inspectit.shared.all.instrumentation.config.impl.PlatformSensorTypeConfig"
] | import java.util.List; import rocks.inspectit.shared.all.instrumentation.config.impl.PlatformSensorTypeConfig; | import java.util.*; import rocks.inspectit.shared.all.instrumentation.config.impl.*; | [
"java.util",
"rocks.inspectit.shared"
] | java.util; rocks.inspectit.shared; | 1,791,137 |
void addRow(MeasurementObject row)
{
values.add(row);
fireTableStructureChanged();
}
| void addRow(MeasurementObject row) { values.add(row); fireTableStructureChanged(); } | /**
* Adds a new row to the model.
*
* @param row The value to add.
*/ | Adds a new row to the model | addRow | {
"repo_name": "joshmoore/openmicroscopy",
"path": "components/insight/SRC/org/openmicroscopy/shoola/agents/measurement/view/MeasurementResults.java",
"license": "gpl-2.0",
"size": 24963
} | [
"org.openmicroscopy.shoola.agents.measurement.util.model.MeasurementObject"
] | import org.openmicroscopy.shoola.agents.measurement.util.model.MeasurementObject; | import org.openmicroscopy.shoola.agents.measurement.util.model.*; | [
"org.openmicroscopy.shoola"
] | org.openmicroscopy.shoola; | 1,381,042 |
@Test
public void testWithAMineName() throws Exception {
MineFilter mineFilter = new MineFilter("Dominion Copper Mine");
String filter = mineFilter.getFilterStringAllRecords();
Document doc = AbstractFilterTestUtilities.parsefilterStringXML(filter);
AbstractFilterTestUtilities.... | void function() throws Exception { MineFilter mineFilter = new MineFilter(STR); String filter = mineFilter.getFilterStringAllRecords(); Document doc = AbstractFilterTestUtilities.parsefilterStringXML(filter); AbstractFilterTestUtilities.runNodeSetValueCheck(doc, STR, new String[] {STR}, 1); AbstractFilterTestUtilities.... | /**
* Test with a mine name. A filter query should be generated searching for mines with the given name.
*/ | Test with a mine name. A filter query should be generated searching for mines with the given name | testWithAMineName | {
"repo_name": "GeoscienceAustralia/geoscience-portal",
"path": "src/test/java/org/auscope/portal/mineraloccurrence/TestMineFilter.java",
"license": "lgpl-3.0",
"size": 2358
} | [
"org.auscope.portal.server.domain.ogc.AbstractFilterTestUtilities",
"org.w3c.dom.Document"
] | import org.auscope.portal.server.domain.ogc.AbstractFilterTestUtilities; import org.w3c.dom.Document; | import org.auscope.portal.server.domain.ogc.*; import org.w3c.dom.*; | [
"org.auscope.portal",
"org.w3c.dom"
] | org.auscope.portal; org.w3c.dom; | 689,469 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.