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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
protected String getString(final String key, final String language, final String... params) {
LocalizationBundle messages =
ResourceLocator.getLocalizationBundle("org.silverpeas.password.multilang.passwordBundle",
language);
String translation;
try {
translation =
(para... | String function(final String key, final String language, final String... params) { LocalizationBundle messages = ResourceLocator.getLocalizationBundle(STR, language); String translation; try { translation = (params != null && params.length > 0) ? messages.getStringWithParams(key, params) : messages.getString(key); } ca... | /**
* Gets a string message according to the given language.
* @param key
* @param language
* @param params
* @return
*/ | Gets a string message according to the given language | getString | {
"repo_name": "SilverDav/Silverpeas-Core",
"path": "core-library/src/main/java/org/silverpeas/core/security/authentication/password/service/PasswordCheck.java",
"license": "agpl-3.0",
"size": 5237
} | [
"java.util.MissingResourceException",
"org.silverpeas.core.util.LocalizationBundle",
"org.silverpeas.core.util.ResourceLocator"
] | import java.util.MissingResourceException; import org.silverpeas.core.util.LocalizationBundle; import org.silverpeas.core.util.ResourceLocator; | import java.util.*; import org.silverpeas.core.util.*; | [
"java.util",
"org.silverpeas.core"
] | java.util; org.silverpeas.core; | 1,056,118 |
interface WithOrigins {
WithCreate withOrigins(List<DeepCreatedOrigin> origins);
} | interface WithOrigins { WithCreate withOrigins(List<DeepCreatedOrigin> origins); } | /**
* Specifies origins.
* @param origins The source of the content being delivered via CDN
* @return the next definition stage
*/ | Specifies origins | withOrigins | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/cdn/mgmt-v2020_04_15/src/main/java/com/microsoft/azure/management/cdn/v2020_04_15/Endpoint.java",
"license": "mit",
"size": 24345
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,909,379 |
private Index createIndex(@Nullable String... extraAttributes) {
List<String> extraAtts = null;
if (extraAttributes != null) {
extraAtts = Lists.newArrayList(extraAttributes);
}
Index index = repo.command(CreateQuadTree.class).setExtraAttributes(extraAtts)
... | Index function(@Nullable String... extraAttributes) { List<String> extraAtts = null; if (extraAttributes != null) { extraAtts = Lists.newArrayList(extraAttributes); } Index index = repo.command(CreateQuadTree.class).setExtraAttributes(extraAtts) .setGeometryAttributeName("pp").setTreeRefSpec(pointsName).call(); return ... | /**
* Creates the spatial index on the {@code pp} property of the Points dataset, with the provided
* extra attributes, if any
*/ | Creates the spatial index on the pp property of the Points dataset, with the provided extra attributes, if any | createIndex | {
"repo_name": "jdgarrett/geogig",
"path": "src/datastore/src/test/java/org/locationtech/geogig/geotools/data/reader/FeatureReaderBuilderTest.java",
"license": "bsd-3-clause",
"size": 17036
} | [
"com.google.common.collect.Lists",
"java.util.List",
"org.eclipse.jdt.annotation.Nullable",
"org.locationtech.geogig.porcelain.index.CreateQuadTree",
"org.locationtech.geogig.porcelain.index.Index"
] | import com.google.common.collect.Lists; import java.util.List; import org.eclipse.jdt.annotation.Nullable; import org.locationtech.geogig.porcelain.index.CreateQuadTree; import org.locationtech.geogig.porcelain.index.Index; | import com.google.common.collect.*; import java.util.*; import org.eclipse.jdt.annotation.*; import org.locationtech.geogig.porcelain.index.*; | [
"com.google.common",
"java.util",
"org.eclipse.jdt",
"org.locationtech.geogig"
] | com.google.common; java.util; org.eclipse.jdt; org.locationtech.geogig; | 692,508 |
public MicrosoftGraphWorkbook withTables(List<MicrosoftGraphWorkbookTable> tables) {
this.tables = tables;
return this;
} | MicrosoftGraphWorkbook function(List<MicrosoftGraphWorkbookTable> tables) { this.tables = tables; return this; } | /**
* Set the tables property: Represents a collection of tables associated with the workbook. Read-only.
*
* @param tables the tables value to set.
* @return the MicrosoftGraphWorkbook object itself.
*/ | Set the tables property: Represents a collection of tables associated with the workbook. Read-only | withTables | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-authorization/src/main/java/com/azure/resourcemanager/authorization/fluent/models/MicrosoftGraphWorkbook.java",
"license": "mit",
"size": 8838
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 379,119 |
public void updateResourceJSON(ResourceScheduler<? extends WorkerResourceDescription> rs) {
JSONObject difference = this.jsm.updateResourceJSON(rs);
JSONObject implsdiff = difference.getJSONObject("implementations");
// Increasing Implementation stats
for (CoreElement ce : CoreManag... | void function(ResourceScheduler<? extends WorkerResourceDescription> rs) { JSONObject difference = this.jsm.updateResourceJSON(rs); JSONObject implsdiff = difference.getJSONObject(STR); for (CoreElement ce : CoreManager.getAllCores()) { for (Implementation impl : ce.getImplementations()) { JSONObject implJSON = this.js... | /**
* Updates the ResourceScheduler with the loaded JSON information.
*
* @param rs ResourceScheduler to update.
*/ | Updates the ResourceScheduler with the loaded JSON information | updateResourceJSON | {
"repo_name": "mF2C/COMPSs",
"path": "compss/runtime/scheduler/commons/src/main/java/es/bsc/compss/components/impl/TaskScheduler.java",
"license": "apache-2.0",
"size": 64481
} | [
"es.bsc.compss.scheduler.types.Profile",
"es.bsc.compss.types.CoreElement",
"es.bsc.compss.types.implementations.Implementation",
"es.bsc.compss.types.resources.WorkerResourceDescription",
"es.bsc.compss.util.CoreManager",
"org.json.JSONObject"
] | import es.bsc.compss.scheduler.types.Profile; import es.bsc.compss.types.CoreElement; import es.bsc.compss.types.implementations.Implementation; import es.bsc.compss.types.resources.WorkerResourceDescription; import es.bsc.compss.util.CoreManager; import org.json.JSONObject; | import es.bsc.compss.scheduler.types.*; import es.bsc.compss.types.*; import es.bsc.compss.types.implementations.*; import es.bsc.compss.types.resources.*; import es.bsc.compss.util.*; import org.json.*; | [
"es.bsc.compss",
"org.json"
] | es.bsc.compss; org.json; | 105,230 |
private boolean isError(IProblem problem, Type type) {
return true;
} | boolean function(IProblem problem, Type type) { return true; } | /**
* Decides if a problem matters.
*
* @param problem the problem
* @param type the current type
* @return return if a problem matters.
*/ | Decides if a problem matters | isError | {
"repo_name": "TypeFox/che",
"path": "plugins/plugin-java/che-plugin-java-ext-jdt/org-eclipse-jdt-ui/src/main/java/org/eclipse/jdt/internal/corext/refactoring/TypeContextChecker.java",
"license": "epl-1.0",
"size": 37468
} | [
"org.eclipse.jdt.core.compiler.IProblem",
"org.eclipse.jdt.core.dom.Type"
] | import org.eclipse.jdt.core.compiler.IProblem; import org.eclipse.jdt.core.dom.Type; | import org.eclipse.jdt.core.compiler.*; import org.eclipse.jdt.core.dom.*; | [
"org.eclipse.jdt"
] | org.eclipse.jdt; | 1,589,655 |
@Test
public void discoveryRouterTest() throws Exception {
ResourceDescriptor resourceDescriptor = ResourceHelper.newResourceDescriptor("router");
List<CapabilityDescriptor> capabilityDescriptors = new ArrayList<CapabilityDescriptor>();
capabilityDescriptors.add(ResourceHelper.newChassisCapabilityDescriptor... | void function() throws Exception { ResourceDescriptor resourceDescriptor = ResourceHelper.newResourceDescriptor(STR); List<CapabilityDescriptor> capabilityDescriptors = new ArrayList<CapabilityDescriptor>(); capabilityDescriptors.add(ResourceHelper.newChassisCapabilityDescriptor()); capabilityDescriptors.add(ResourceHe... | /**
* Test to check discovery functionalities. TODO It should be interesting to add some test in order to check if i want to remove resources that in
* the updated model doesn't exist
*/ | Test to check discovery functionalities. TODO It should be interesting to add some test in order to check if i want to remove resources that in the updated model doesn't exist | discoveryRouterTest | {
"repo_name": "eenbp/OpenNaaS-0.14-Marketplace",
"path": "itests/router/src/test/java/org/opennaas/itests/router/MantychoreRepositoryIntegrationTest.java",
"license": "lgpl-3.0",
"size": 17323
} | [
"java.util.ArrayList",
"java.util.List",
"org.opennaas.core.resources.Resource",
"org.opennaas.core.resources.descriptor.CapabilityDescriptor",
"org.opennaas.core.resources.descriptor.ResourceDescriptor",
"org.opennaas.core.resources.helpers.ResourceHelper",
"org.opennaas.extensions.router.model.Compute... | import java.util.ArrayList; import java.util.List; import org.opennaas.core.resources.Resource; import org.opennaas.core.resources.descriptor.CapabilityDescriptor; import org.opennaas.core.resources.descriptor.ResourceDescriptor; import org.opennaas.core.resources.helpers.ResourceHelper; import org.opennaas.extensions.... | import java.util.*; import org.opennaas.core.resources.*; import org.opennaas.core.resources.descriptor.*; import org.opennaas.core.resources.helpers.*; import org.opennaas.extensions.router.model.*; | [
"java.util",
"org.opennaas.core",
"org.opennaas.extensions"
] | java.util; org.opennaas.core; org.opennaas.extensions; | 900,563 |
protected Object getEarlyBeanReference(String beanName, RootBeanDefinition mbd, Object bean) {
Object exposedObject = bean;
if (bean != null && !mbd.isSynthetic() && hasInstantiationAwareBeanPostProcessors()) {
for (BeanPostProcessor bp : getBeanPostProcessors()) {
if (bp instanceof SmartInstantiationAwar... | Object function(String beanName, RootBeanDefinition mbd, Object bean) { Object exposedObject = bean; if (bean != null && !mbd.isSynthetic() && hasInstantiationAwareBeanPostProcessors()) { for (BeanPostProcessor bp : getBeanPostProcessors()) { if (bp instanceof SmartInstantiationAwareBeanPostProcessor) { SmartInstantiat... | /**
* Obtain a reference for early access to the specified bean,
* typically for the purpose of resolving a circular reference.
* @param beanName the name of the bean (for error handling purposes)
* @param mbd the merged bean definition for the bean
* @param bean the raw bean instance
* @return the object t... | Obtain a reference for early access to the specified bean, typically for the purpose of resolving a circular reference | getEarlyBeanReference | {
"repo_name": "kingtang/spring-learn",
"path": "spring-beans/src/main/java/org/springframework/beans/factory/support/AbstractAutowireCapableBeanFactory.java",
"license": "gpl-3.0",
"size": 70458
} | [
"org.springframework.beans.factory.config.BeanPostProcessor",
"org.springframework.beans.factory.config.SmartInstantiationAwareBeanPostProcessor"
] | import org.springframework.beans.factory.config.BeanPostProcessor; import org.springframework.beans.factory.config.SmartInstantiationAwareBeanPostProcessor; | import org.springframework.beans.factory.config.*; | [
"org.springframework.beans"
] | org.springframework.beans; | 679,925 |
protected String[] parseCommandlineArgs()
throws MojoExecutionException
{
if ( commandlineArgs == null )
{
return null;
}
else
{
try
{
return CommandLineUtils.translateCommandline( commandlineArgs );
... | String[] function() throws MojoExecutionException { if ( commandlineArgs == null ) { return null; } else { try { return CommandLineUtils.translateCommandline( commandlineArgs ); } catch ( Exception e ) { throw new MojoExecutionException( e.getMessage() ); } } } | /**
* Parses the argument string given by the user. Strings are recognized as everything between STRING_WRAPPER.
* PARAMETER_DELIMITER is ignored inside a string. STRING_WRAPPER and PARAMETER_DELIMITER can be escaped using
* ESCAPE_CHAR.
*
* @return Array of String representing the arguments
... | Parses the argument string given by the user. Strings are recognized as everything between STRING_WRAPPER. PARAMETER_DELIMITER is ignored inside a string. STRING_WRAPPER and PARAMETER_DELIMITER can be escaped using ESCAPE_CHAR | parseCommandlineArgs | {
"repo_name": "trustin/exec-maven-plugin",
"path": "src/main/java/kr/motd/maven/exec/ExecMojo.java",
"license": "apache-2.0",
"size": 37859
} | [
"org.apache.maven.plugin.MojoExecutionException",
"org.codehaus.plexus.util.cli.CommandLineUtils"
] | import org.apache.maven.plugin.MojoExecutionException; import org.codehaus.plexus.util.cli.CommandLineUtils; | import org.apache.maven.plugin.*; import org.codehaus.plexus.util.cli.*; | [
"org.apache.maven",
"org.codehaus.plexus"
] | org.apache.maven; org.codehaus.plexus; | 2,829,451 |
@Test
public void getClipManifold() {
Manifold m = new Manifold();
Penetration p = new Penetration();
Transform t1 = new Transform();
Transform t2 = new Transform();
ManifoldPoint mp = null;
Vector2 p1 = null;
// test containment gjk
this.gjk.detect(circ, t1, seg, t2, p);
TestCase.assertT... | void function() { Manifold m = new Manifold(); Penetration p = new Penetration(); Transform t1 = new Transform(); Transform t2 = new Transform(); ManifoldPoint mp = null; Vector2 p1 = null; this.gjk.detect(circ, t1, seg, t2, p); TestCase.assertTrue(this.cmfs.getManifold(p, circ, t1, seg, t2, m)); TestCase.assertEquals(... | /**
* Test the {@link ClippingManifoldSolver}.
*/ | Test the <code>ClippingManifoldSolver</code> | getClipManifold | {
"repo_name": "dmitrykolesnikovich/dyn4j",
"path": "junit/org/dyn4j/collision/CircleSegmentTest.java",
"license": "bsd-3-clause",
"size": 15097
} | [
"junit.framework.TestCase",
"org.dyn4j.collision.manifold.Manifold",
"org.dyn4j.collision.manifold.ManifoldPoint",
"org.dyn4j.collision.narrowphase.Penetration",
"org.dyn4j.geometry.Transform",
"org.dyn4j.geometry.Vector2"
] | import junit.framework.TestCase; import org.dyn4j.collision.manifold.Manifold; import org.dyn4j.collision.manifold.ManifoldPoint; import org.dyn4j.collision.narrowphase.Penetration; import org.dyn4j.geometry.Transform; import org.dyn4j.geometry.Vector2; | import junit.framework.*; import org.dyn4j.collision.manifold.*; import org.dyn4j.collision.narrowphase.*; import org.dyn4j.geometry.*; | [
"junit.framework",
"org.dyn4j.collision",
"org.dyn4j.geometry"
] | junit.framework; org.dyn4j.collision; org.dyn4j.geometry; | 1,605,006 |
@Override
public String getText(Object object) {
String label = ((AddressingEndpoint)object).getEndPointName();
return label == null || label.length() == 0 ?
getString("_UI_AddressingEndpoint_type") :
getString("_UI_AddressingEndpoint_type") + " " + label;
} | String function(Object object) { String label = ((AddressingEndpoint)object).getEndPointName(); return label == null label.length() == 0 ? getString(STR) : getString(STR) + " " + label; } | /**
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | This returns the label text for the adapted class. | getText | {
"repo_name": "nwnpallewela/devstudio-tooling-esb",
"path": "plugins/org.wso2.developerstudio.eclipse.gmf.esb.edit/src/org/wso2/developerstudio/eclipse/gmf/esb/provider/AddressingEndpointItemProvider.java",
"license": "apache-2.0",
"size": 6562
} | [
"org.wso2.developerstudio.eclipse.gmf.esb.AddressingEndpoint"
] | import org.wso2.developerstudio.eclipse.gmf.esb.AddressingEndpoint; | import org.wso2.developerstudio.eclipse.gmf.esb.*; | [
"org.wso2.developerstudio"
] | org.wso2.developerstudio; | 681,506 |
public void contextDestroyed(final ServletContextEvent arg0)
{
Logger.log(Level.INFO, "Closing caches...");
MyCacheManager.destroyAllCaches();
Logger.log(Level.INFO, "Caches closed.");
} | void function(final ServletContextEvent arg0) { Logger.log(Level.INFO, STR); MyCacheManager.destroyAllCaches(); Logger.log(Level.INFO, STR); } | /**
* Application shutdown.
*/ | Application shutdown | contextDestroyed | {
"repo_name": "SkyCrawl/ws_demo",
"path": "src/org/skycrawl/wsdemo/StartupQuitListener.java",
"license": "apache-2.0",
"size": 615
} | [
"java.util.logging.Level",
"javax.servlet.ServletContextEvent",
"org.skycrawl.wsdemo.util.cache.MyCacheManager"
] | import java.util.logging.Level; import javax.servlet.ServletContextEvent; import org.skycrawl.wsdemo.util.cache.MyCacheManager; | import java.util.logging.*; import javax.servlet.*; import org.skycrawl.wsdemo.util.cache.*; | [
"java.util",
"javax.servlet",
"org.skycrawl.wsdemo"
] | java.util; javax.servlet; org.skycrawl.wsdemo; | 1,325,680 |
public static String translateRowValueFromQuery(String value, ColumnTypeInfo columnType) {
if(value == null){
return null;
}
if(columnType == null){
return null;
}
return columnType.parseValueForDatabaseRead(value);
}
| static String function(String value, ColumnTypeInfo columnType) { if(value == null){ return null; } if(columnType == null){ return null; } return columnType.parseValueForDatabaseRead(value); } | /**
* Translate the value as returned from a query according to the column model
*
* @param value
* @param columnModel
* @return
*/ | Translate the value as returned from a query according to the column model | translateRowValueFromQuery | {
"repo_name": "hhu94/Synapse-Repository-Services",
"path": "lib/lib-table-cluster/src/main/java/org/sagebionetworks/table/cluster/utils/TableModelUtils.java",
"license": "apache-2.0",
"size": 50396
} | [
"org.sagebionetworks.table.cluster.ColumnTypeInfo"
] | import org.sagebionetworks.table.cluster.ColumnTypeInfo; | import org.sagebionetworks.table.cluster.*; | [
"org.sagebionetworks.table"
] | org.sagebionetworks.table; | 674,030 |
public String getDefaultScheme()
{
return _isSSL?HttpMessage.__SSL_SCHEME:super.getDefaultScheme();
} | String function() { return _isSSL?HttpMessage.__SSL_SCHEME:super.getDefaultScheme(); } | /**
* Get the listeners Default scheme. Conveniance method equivalent to
* getListener().getDefaultProtocol().
*
* @return HttpServer.
*/ | Get the listeners Default scheme. Conveniance method equivalent to getListener().getDefaultProtocol() | getDefaultScheme | {
"repo_name": "jknguyen/josephknguyen-selenium",
"path": "java/server/src/org/openqa/jetty/http/ajp/AJP13Connection.java",
"license": "apache-2.0",
"size": 14229
} | [
"org.openqa.jetty.http.HttpMessage"
] | import org.openqa.jetty.http.HttpMessage; | import org.openqa.jetty.http.*; | [
"org.openqa.jetty"
] | org.openqa.jetty; | 1,367,150 |
public static String[] getStrings(String str){
Collection<String> values = getStringCollection(str);
if(values.size() == 0) {
return null;
}
return values.toArray(new String[values.size()]);
} | static String[] function(String str){ Collection<String> values = getStringCollection(str); if(values.size() == 0) { return null; } return values.toArray(new String[values.size()]); } | /**
* Returns an arraylist of strings.
* @param str the comma seperated string values
* @return the arraylist of the comma seperated string values
*/ | Returns an arraylist of strings | getStrings | {
"repo_name": "ZhangXFeng/hadoop",
"path": "src/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/util/StringUtils.java",
"license": "apache-2.0",
"size": 33076
} | [
"java.util.Collection"
] | import java.util.Collection; | import java.util.*; | [
"java.util"
] | java.util; | 2,784,574 |
public Iterator<IJV> getIterator() {
//default generic iterator, override if necessary
return new SparseBlockIterator(numRows());
}
| Iterator<IJV> function() { return new SparseBlockIterator(numRows()); } | /**
* Get a non-zero iterator over the entire sparse block. Note that
* the returned IJV object is reused across next calls and should
* be directly consumed or deep copied.
*
* @return
*/ | Get a non-zero iterator over the entire sparse block. Note that the returned IJV object is reused across next calls and should be directly consumed or deep copied | getIterator | {
"repo_name": "Wenpei/incubator-systemml",
"path": "src/main/java/org/apache/sysml/runtime/matrix/data/SparseBlock.java",
"license": "apache-2.0",
"size": 14328
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 533,163 |
GtkBox gtk_statusbar_get_message_area(GtkStatusbar statusbar); | GtkBox gtk_statusbar_get_message_area(GtkStatusbar statusbar); | /**
* Retrieves the box containing the label widget.
*
* @param statusbar a GtkStatusbar
* @return a GtkBox.
*/ | Retrieves the box containing the label widget | gtk_statusbar_get_message_area | {
"repo_name": "Ccook/gtk-java-bindings",
"path": "src/main/java/com/github/ccook/gtk/library/object/widget/container/box/GtkStatusbarLibrary.java",
"license": "apache-2.0",
"size": 2847
} | [
"com.github.ccook.gtk.model.object.widget.container.GtkBox",
"com.github.ccook.gtk.model.object.widget.container.box.GtkStatusbar"
] | import com.github.ccook.gtk.model.object.widget.container.GtkBox; import com.github.ccook.gtk.model.object.widget.container.box.GtkStatusbar; | import com.github.ccook.gtk.model.object.widget.container.*; import com.github.ccook.gtk.model.object.widget.container.box.*; | [
"com.github.ccook"
] | com.github.ccook; | 848,000 |
public FileRequestQueue performQueueCleanup(File tempDir, String tempDirPrefix, String tempFilePrefix, String jarFilePrefix)
throws DBException {
// Get a connection to the database
Connection conn = null;
PreparedStatement pstmt = null;
Statement stmt = null;
FileRequestQueue reqQu... | FileRequestQueue function(File tempDir, String tempDirPrefix, String tempFilePrefix, String jarFilePrefix) throws DBException { Connection conn = null; PreparedStatement pstmt = null; Statement stmt = null; FileRequestQueue reqQueue = new FileRequestQueue(); try { conn = getConnection(DBConnectionPool.PermanentLease); ... | /**
* Perform a queue cleanup deleting temporary cache files that do not have an associated save or transaction
* request.
*
* @param tempDir File
* @param tempDirPrefix String
* @param tempFilePrefix String
* @param jarFilePrefix String
* @return FileRequestQueue
* @throws DBException
*/ | Perform a queue cleanup deleting temporary cache files that do not have an associated save or transaction request | performQueueCleanup | {
"repo_name": "arcusys/Liferay-CIFS",
"path": "source/java/org/alfresco/jlan/server/filesys/db/mysql/MySQLDBInterface.java",
"license": "gpl-3.0",
"size": 115358
} | [
"java.io.File",
"java.sql.Connection",
"java.sql.Date",
"java.sql.PreparedStatement",
"java.sql.ResultSet",
"java.sql.Statement",
"java.text.SimpleDateFormat",
"org.alfresco.jlan.debug.Debug",
"org.alfresco.jlan.server.filesys.cache.FileState",
"org.alfresco.jlan.server.filesys.db.DBException",
... | import java.io.File; import java.sql.Connection; import java.sql.Date; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.Statement; import java.text.SimpleDateFormat; import org.alfresco.jlan.debug.Debug; import org.alfresco.jlan.server.filesys.cache.FileState; import org.alfresco.jlan.serve... | import java.io.*; import java.sql.*; import java.text.*; import org.alfresco.jlan.debug.*; import org.alfresco.jlan.server.filesys.cache.*; import org.alfresco.jlan.server.filesys.db.*; import org.alfresco.jlan.server.filesys.loader.*; import org.alfresco.jlan.util.db.*; | [
"java.io",
"java.sql",
"java.text",
"org.alfresco.jlan"
] | java.io; java.sql; java.text; org.alfresco.jlan; | 2,521,177 |
//-----------------------------------------------------------------------
@Override
public StandardId getStandardId() {
return standardId;
} | StandardId function() { return standardId; } | /**
* Gets the identifier of the data.
* This is typically an identifier from an external data provider.
* @return the value of the property, not null
*/ | Gets the identifier of the data. This is typically an identifier from an external data provider | getStandardId | {
"repo_name": "OpenGamma/Strata",
"path": "modules/market/src/main/java/com/opengamma/strata/market/observable/QuoteId.java",
"license": "apache-2.0",
"size": 8632
} | [
"com.opengamma.strata.basics.StandardId"
] | import com.opengamma.strata.basics.StandardId; | import com.opengamma.strata.basics.*; | [
"com.opengamma.strata"
] | com.opengamma.strata; | 1,778,804 |
private String loopOnCondition(BlockWorker worker, IDbHandle dbHandle, ServiceContext ctx) {
try {
Value toContinue = Value.VALUE_TRUE;
if (this.executeOnCondition != null) {
toContinue = this.executeOnCondition.evaluate(ctx);
}
boolean interrupted = false;
while (toContinue.toBoolean()) {
... | String function(BlockWorker worker, IDbHandle dbHandle, ServiceContext ctx) { try { Value toContinue = Value.VALUE_TRUE; if (this.executeOnCondition != null) { toContinue = this.executeOnCondition.evaluate(ctx); } boolean interrupted = false; while (toContinue.toBoolean()) { if (this.breakOnInterrupt && Thread.interrup... | /**
* loop over this block for supplied expression/condition
*
* @param expr
* @param dbHandle
* @return true if normal completion. False if we encountered a STOP signal
*/ | loop over this block for supplied expression/condition | loopOnCondition | {
"repo_name": "simplity/simplity",
"path": "simplity/core/src/main/java/org/simplity/core/trans/Loop.java",
"license": "mit",
"size": 12119
} | [
"org.simplity.core.ApplicationError",
"org.simplity.core.idb.IDbHandle",
"org.simplity.core.service.ServiceContext",
"org.simplity.core.value.Value"
] | import org.simplity.core.ApplicationError; import org.simplity.core.idb.IDbHandle; import org.simplity.core.service.ServiceContext; import org.simplity.core.value.Value; | import org.simplity.core.*; import org.simplity.core.idb.*; import org.simplity.core.service.*; import org.simplity.core.value.*; | [
"org.simplity.core"
] | org.simplity.core; | 1,814,621 |
@Test public void testIntegerIntervalSet() {
checkIntegerIntervalSet("1,5", 1, 5);
// empty
checkIntegerIntervalSet("");
// empty due to exclusions
checkIntegerIntervalSet("2,4,-1-5");
// open range
checkIntegerIntervalSet("1-6,-3-5,4,9", 1, 2, 4, 6, 9);
// repeats
checkInteger... | @Test void function() { checkIntegerIntervalSet("1,5", 1, 5); checkIntegerIntervalSet(STR2,4,-1-5STR1-6,-3-5,4,9STR1,3,1,2-4,-2,-4", 1, 3); } | /**
* Unit test for {@link IntegerIntervalSet}.
*/ | Unit test for <code>IntegerIntervalSet</code> | testIntegerIntervalSet | {
"repo_name": "YrAuYong/incubator-calcite",
"path": "core/src/test/java/org/apache/calcite/util/UtilTest.java",
"license": "apache-2.0",
"size": 47713
} | [
"org.junit.Test"
] | import org.junit.Test; | import org.junit.*; | [
"org.junit"
] | org.junit; | 1,600,692 |
void dispatchEvent(ActivitiEvent event); | void dispatchEvent(ActivitiEvent event); | /**
* Dispatches the given event to any listeners that are registered.
*
* @param event
* event to dispatch.
*
* @throws ActivitiException
* if an exception occurs when dispatching the event or when the
* {@link ActivitiEventDispatcher} is disabled.
* @throws Ac... | Dispatches the given event to any listeners that are registered | dispatchEvent | {
"repo_name": "ahwxl/deep",
"path": "src/main/java/org/activiti/engine/RuntimeService.java",
"license": "apache-2.0",
"size": 40262
} | [
"org.activiti.engine.delegate.event.ActivitiEvent"
] | import org.activiti.engine.delegate.event.ActivitiEvent; | import org.activiti.engine.delegate.event.*; | [
"org.activiti.engine"
] | org.activiti.engine; | 1,092,086 |
public final static String ToString(Shape shape){
StringBuilder string = new StringBuilder();
PathIterator p = shape.getPathIterator(null);
double[] s = new double[6];
while (!p.isDone()){
switch(p.currentSegment(s)){
case PathIterator.SEG_MOVETO:
... | final static String function(Shape shape){ StringBuilder string = new StringBuilder(); PathIterator p = shape.getPathIterator(null); double[] s = new double[6]; while (!p.isDone()){ switch(p.currentSegment(s)){ case PathIterator.SEG_MOVETO: string.append('M'); string.append(String.format("%f",s[0])); string.append(',')... | /**
* Convert Shape PathIterator to Attribute "d" (of SVG Element
* Path) format.
*
* @see #CopyTo(Shape)
*/ | Convert Shape PathIterator to Attribute "d" (of SVG Element Path) format | ToString | {
"repo_name": "syntelos/java-vector",
"path": "awt/src/platform/Path.java",
"license": "gpl-3.0",
"size": 13904
} | [
"java.awt.geom.PathIterator"
] | import java.awt.geom.PathIterator; | import java.awt.geom.*; | [
"java.awt"
] | java.awt; | 2,388,359 |
public Observable<ServiceResponse<StreamingEndpointInner>> createWithServiceResponseAsync(String resourceGroupName, String accountName, String streamingEndpointName, StreamingEndpointInner parameters, Boolean autoStart) {
if (this.client.subscriptionId() == null) {
throw new IllegalArgumentExcep... | Observable<ServiceResponse<StreamingEndpointInner>> function(String resourceGroupName, String accountName, String streamingEndpointName, StreamingEndpointInner parameters, Boolean autoStart) { if (this.client.subscriptionId() == null) { throw new IllegalArgumentException(STR); } if (resourceGroupName == null) { throw n... | /**
* Create StreamingEndpoint.
* Creates a StreamingEndpoint.
*
* @param resourceGroupName The name of the resource group within the Azure subscription.
* @param accountName The Media Services account name.
* @param streamingEndpointName The name of the StreamingEndpoint.
* @param pa... | Create StreamingEndpoint. Creates a StreamingEndpoint | createWithServiceResponseAsync | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/mediaservices/mgmt-v2018_07_01/src/main/java/com/microsoft/azure/management/mediaservices/v2018_07_01/implementation/StreamingEndpointsInner.java",
"license": "mit",
"size": 117827
} | [
"com.google.common.reflect.TypeToken",
"com.microsoft.rest.ServiceResponse",
"com.microsoft.rest.Validator"
] | import com.google.common.reflect.TypeToken; import com.microsoft.rest.ServiceResponse; import com.microsoft.rest.Validator; | import com.google.common.reflect.*; import com.microsoft.rest.*; | [
"com.google.common",
"com.microsoft.rest"
] | com.google.common; com.microsoft.rest; | 2,706,688 |
@Transactional(propagation = Propagation.REQUIRED, readOnly = false)
public UserInfo changePassword(final UserInfo userInfo, final Long userId) {
userValidator.validateChangePassword(userInfo);
UserEntity userEntity = userRepository.findByUserId(userId);
if (ValidatorUtil.isNull(us... | @Transactional(propagation = Propagation.REQUIRED, readOnly = false) UserInfo function(final UserInfo userInfo, final Long userId) { userValidator.validateChangePassword(userInfo); UserEntity userEntity = userRepository.findByUserId(userId); if (ValidatorUtil.isNull(userEntity)) { LOGGER.warn(STR + userId + ")"); throw... | /**
* Change password.
*
* @param userInfo the user info
* @param userId the user id
* @return the user info
*/ | Change password | changePassword | {
"repo_name": "jonvestal/open-kilda",
"path": "src-gui/src/main/java/org/usermanagement/service/UserService.java",
"license": "apache-2.0",
"size": 28149
} | [
"org.springframework.transaction.annotation.Propagation",
"org.springframework.transaction.annotation.Transactional",
"org.usermanagement.conversion.UserConversionUtil",
"org.usermanagement.dao.entity.UserEntity",
"org.usermanagement.exception.RequestValidationException",
"org.usermanagement.model.UserInf... | import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; import org.usermanagement.conversion.UserConversionUtil; import org.usermanagement.dao.entity.UserEntity; import org.usermanagement.exception.RequestValidationException; import org.usermanagem... | import org.springframework.transaction.annotation.*; import org.usermanagement.conversion.*; import org.usermanagement.dao.entity.*; import org.usermanagement.exception.*; import org.usermanagement.model.*; import org.usermanagement.util.*; | [
"org.springframework.transaction",
"org.usermanagement.conversion",
"org.usermanagement.dao",
"org.usermanagement.exception",
"org.usermanagement.model",
"org.usermanagement.util"
] | org.springframework.transaction; org.usermanagement.conversion; org.usermanagement.dao; org.usermanagement.exception; org.usermanagement.model; org.usermanagement.util; | 2,860,926 |
public synchronized Set<String> getChildren() {
if (children == null) {
return EMPTY_SET;
}
return Collections.unmodifiableSet(children);
} | synchronized Set<String> function() { if (children == null) { return EMPTY_SET; } return Collections.unmodifiableSet(children); } | /**
* convenience methods to get the children
*
* @return the children of this datanode. If the datanode has no children, empty
* set is returned
*/ | convenience methods to get the children | getChildren | {
"repo_name": "maoling/zookeeper",
"path": "zookeeper-server/src/main/java/org/apache/zookeeper/server/DataNode.java",
"license": "apache-2.0",
"size": 6573
} | [
"java.util.Collections",
"java.util.Set"
] | import java.util.Collections; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 318,846 |
public void addAdmin(java.lang.String gridIdentity) throws DorianFault, DorianInternalFault, PermissionDeniedFault {
try {
getClient().addAdmin(gridIdentity);
} catch (DorianInternalFault gie) {
throw gie;
} catch (PermissionDeniedFault f) {
throw f;
... | void function(java.lang.String gridIdentity) throws DorianFault, DorianInternalFault, PermissionDeniedFault { try { getClient().addAdmin(gridIdentity); } catch (DorianInternalFault gie) { throw gie; } catch (PermissionDeniedFault f) { throw f; } catch (Exception e) { FaultUtil.printFault(e); DorianFault fault = new Dor... | /**
* This method grants a user privileges to Dorian to administrate grid
* accounts.
*
* @param gridIdentity
* The Grid identity of the user to add as an administrator.
* @throws DorianFault
* @throws DorianInternalFault
* @throws PermissionDeniedFault
*/ | This method grants a user privileges to Dorian to administrate grid accounts | addAdmin | {
"repo_name": "NCIP/cagrid",
"path": "cagrid/Software/core/caGrid/projects/dorian/src/org/cagrid/gaards/dorian/client/GridAdministrationClient.java",
"license": "bsd-3-clause",
"size": 29100
} | [
"gov.nih.nci.cagrid.common.FaultHelper",
"gov.nih.nci.cagrid.common.FaultUtil",
"gov.nih.nci.cagrid.common.Utils",
"org.cagrid.gaards.dorian.common.DorianFault",
"org.cagrid.gaards.dorian.stubs.types.DorianInternalFault",
"org.cagrid.gaards.dorian.stubs.types.PermissionDeniedFault"
] | import gov.nih.nci.cagrid.common.FaultHelper; import gov.nih.nci.cagrid.common.FaultUtil; import gov.nih.nci.cagrid.common.Utils; import org.cagrid.gaards.dorian.common.DorianFault; import org.cagrid.gaards.dorian.stubs.types.DorianInternalFault; import org.cagrid.gaards.dorian.stubs.types.PermissionDeniedFault; | import gov.nih.nci.cagrid.common.*; import org.cagrid.gaards.dorian.common.*; import org.cagrid.gaards.dorian.stubs.types.*; | [
"gov.nih.nci",
"org.cagrid.gaards"
] | gov.nih.nci; org.cagrid.gaards; | 1,725,584 |
@SuppressWarnings({ "rawtypes" })
ConcurrentMap getMetrics() {
metricsMap.put(NO_OF_PENDING_FAILED_MESSAGES, (long) pendingMessageRetries.size());
metricsMap.put(NO_OF_MESSAGES_RECEIVED, messagesReceived);
metricsMap.put(NO_OF_MESSAGES_EMITTED, messagesEmitted);
metricsMap.put(NO... | @SuppressWarnings({ STR }) ConcurrentMap getMetrics() { metricsMap.put(NO_OF_PENDING_FAILED_MESSAGES, (long) pendingMessageRetries.size()); metricsMap.put(NO_OF_MESSAGES_RECEIVED, messagesReceived); metricsMap.put(NO_OF_MESSAGES_EMITTED, messagesEmitted); metricsMap.put(NO_OF_PENDING_ACKS, pendingAcks); metricsMap.put(... | /**
* Helpers for metrics
*/ | Helpers for metrics | getMetrics | {
"repo_name": "tkb77/pulsar",
"path": "pulsar-storm/src/main/java/org/apache/pulsar/storm/PulsarSpout.java",
"license": "apache-2.0",
"size": 12392
} | [
"java.util.concurrent.ConcurrentMap"
] | import java.util.concurrent.ConcurrentMap; | import java.util.concurrent.*; | [
"java.util"
] | java.util; | 1,192,459 |
public synchronized boolean isAlive(long timeout) {
long lastUsed = System.currentTimeMillis() - lastAccess;
if (lastUsed < timeout) {
return true;
}
try {
sendSimpleCommand("NOOP");
return true;
} catch (MessagingException e) {
... | synchronized boolean function(long timeout) { long lastUsed = System.currentTimeMillis() - lastAccess; if (lastUsed < timeout) { return true; } try { sendSimpleCommand("NOOP"); return true; } catch (MessagingException e) { } return false; } | /**
* check to see if this connection is truely alive.
*
* @param timeout The timeout value to control how often we ping
* the server to see if we're still good.
*
* @return true if the server is responding to requests, false for any
* connection errors. This w... | check to see if this connection is truely alive | isAlive | {
"repo_name": "apache/geronimo-javamail",
"path": "geronimo-javamail_1.6/geronimo-javamail_1.6_provider/src/main/java/org/apache/geronimo/javamail/store/imap/connection/IMAPConnection.java",
"license": "apache-2.0",
"size": 75320
} | [
"javax.mail.MessagingException"
] | import javax.mail.MessagingException; | import javax.mail.*; | [
"javax.mail"
] | javax.mail; | 557,995 |
public Builder ingressPoints(Set<ConnectPoint> ingressPoints) {
this.ingressPoints = ImmutableSet.copyOf(ingressPoints);
return this;
} | Builder function(Set<ConnectPoint> ingressPoints) { this.ingressPoints = ImmutableSet.copyOf(ingressPoints); return this; } | /**
* Sets the ingress point of the single point to multi point intent
* that will be built.
*
* @param ingressPoints ingress connect points
* @return this builder
*/ | Sets the ingress point of the single point to multi point intent that will be built | ingressPoints | {
"repo_name": "wuwenbin2/onos_bgp_evpn",
"path": "core/api/src/main/java/org/onosproject/net/intent/LinkCollectionIntent.java",
"license": "apache-2.0",
"size": 11024
} | [
"com.google.common.collect.ImmutableSet",
"java.util.Set",
"org.onosproject.net.ConnectPoint"
] | import com.google.common.collect.ImmutableSet; import java.util.Set; import org.onosproject.net.ConnectPoint; | import com.google.common.collect.*; import java.util.*; import org.onosproject.net.*; | [
"com.google.common",
"java.util",
"org.onosproject.net"
] | com.google.common; java.util; org.onosproject.net; | 1,960,768 |
@SuppressWarnings("unused")
@Test(expected = IllegalArgumentException.class)
public void testInvalidWidth () {
new World(0, 8);
}
| @SuppressWarnings(STR) @Test(expected = IllegalArgumentException.class) void function () { new World(0, 8); } | /**
* Test that a world cannot be build with an invalid width.
*/ | Test that a world cannot be build with an invalid width | testInvalidWidth | {
"repo_name": "AlexRNL/GameOfLife",
"path": "src/test/java/com/alexrnl/gameoflife/world/WorldTest.java",
"license": "bsd-3-clause",
"size": 2893
} | [
"org.junit.Test"
] | import org.junit.Test; | import org.junit.*; | [
"org.junit"
] | org.junit; | 1,237,039 |
public static boolean isLocationOn(final Context context)
{
if (context == null)
{
throw new InvalidParameterException("context is null");
}
return !isMarshmallowOrLater() || isLocationTurnedOn(context);
} | static boolean function(final Context context) { if (context == null) { throw new InvalidParameterException(STR); } return !isMarshmallowOrLater() isLocationTurnedOn(context); } | /**
* Determine wether Location is turned on. Below Android M, will always return true.
*
* @param context to determine with if location is on
* @return true if location is turned on or the sdk is below Android M.
* @throws InvalidParameterException if {@code context} is null
*/ | Determine wether Location is turned on. Below Android M, will always return true | isLocationOn | {
"repo_name": "KoSeongho/ibeacon-scanner-android",
"path": "ibeaconscanner/src/main/java/mobi/inthepocket/android/beacons/ibeaconscanner/utils/LocationUtils.java",
"license": "mit",
"size": 1774
} | [
"android.content.Context",
"java.security.InvalidParameterException"
] | import android.content.Context; import java.security.InvalidParameterException; | import android.content.*; import java.security.*; | [
"android.content",
"java.security"
] | android.content; java.security; | 1,028,361 |
public static void saveHighScore(String levelId, String difficulty, int score)
{
// Ensure the inner map of difficulty->score exists.
HashMap<String, Integer> difficultyScores;
if (!LEVEL_DIFFICULTY_SCORES.containsKey(levelId))
{
difficultyScores = new HashMap<>();
... | static void function(String levelId, String difficulty, int score) { HashMap<String, Integer> difficultyScores; if (!LEVEL_DIFFICULTY_SCORES.containsKey(levelId)) { difficultyScores = new HashMap<>(); LEVEL_DIFFICULTY_SCORES.put(levelId, difficultyScores); } else { difficultyScores = LEVEL_DIFFICULTY_SCORES.get(levelId... | /**
* Saves the score if highest for this level.
*/ | Saves the score if highest for this level | saveHighScore | {
"repo_name": "overengineering/space-travels-3",
"path": "core/src/com/draga/spaceTravels3/manager/ScoreManager.java",
"license": "mit",
"size": 4001
} | [
"java.util.HashMap"
] | import java.util.HashMap; | import java.util.*; | [
"java.util"
] | java.util; | 995,732 |
@Test
public void testGetSplits() throws Exception {
Connector conn = getConnector();
String table = getUniqueNames(1)[0];
conn.tableOperations().create(table);
insertData(table, currentTimeMillis());
ClientConfiguration clientConf = cluster.getClientConfig();
AccumuloConfiguration clusterC... | void function() throws Exception { Connector conn = getConnector(); String table = getUniqueNames(1)[0]; conn.tableOperations().create(table); insertData(table, currentTimeMillis()); ClientConfiguration clientConf = cluster.getClientConfig(); AccumuloConfiguration clusterClientConf = new ConfigurationCopy(new DefaultCo... | /**
* Tests several different paths through the getSplits() method by setting different properties and verifying the results.
*/ | Tests several different paths through the getSplits() method by setting different properties and verifying the results | testGetSplits | {
"repo_name": "adamjshook/accumulo",
"path": "test/src/test/java/org/apache/accumulo/test/functional/AccumuloInputFormatIT.java",
"license": "apache-2.0",
"size": 8480
} | [
"java.io.IOException",
"java.lang.System",
"java.util.ArrayList",
"java.util.Collection",
"java.util.List",
"java.util.TreeSet",
"org.apache.accumulo.core.client.ClientConfiguration",
"org.apache.accumulo.core.client.Connector",
"org.apache.accumulo.core.client.mapreduce.AccumuloInputFormat",
"org... | import java.io.IOException; import java.lang.System; import java.util.ArrayList; import java.util.Collection; import java.util.List; import java.util.TreeSet; import org.apache.accumulo.core.client.ClientConfiguration; import org.apache.accumulo.core.client.Connector; import org.apache.accumulo.core.client.mapreduce.Ac... | import java.io.*; import java.lang.*; import java.util.*; import org.apache.accumulo.core.client.*; import org.apache.accumulo.core.client.mapreduce.*; import org.apache.accumulo.core.client.mapreduce.impl.*; import org.apache.accumulo.core.conf.*; import org.apache.accumulo.core.data.*; import org.apache.accumulo.core... | [
"java.io",
"java.lang",
"java.util",
"org.apache.accumulo",
"org.apache.hadoop",
"org.junit"
] | java.io; java.lang; java.util; org.apache.accumulo; org.apache.hadoop; org.junit; | 2,829,569 |
private List<Event> doAddServiceMapping(Connection dbConn, String ipaddr, String serviceName, long txNo) throws SQLException, FailedOperationException {
PreparedStatement stmt = null;
final DBUtils d = new DBUtils(getClass());
try {
stmt = dbConn.prepareStatement(SQL_ADD_SERVICE_... | List<Event> function(Connection dbConn, String ipaddr, String serviceName, long txNo) throws SQLException, FailedOperationException { PreparedStatement stmt = null; final DBUtils d = new DBUtils(getClass()); try { stmt = dbConn.prepareStatement(SQL_ADD_SERVICE_TO_MAPPING); d.watch(stmt); stmt.setString(1, ipaddr); stmt... | /**
* Helper method used to update the mapping of interfaces to services.
*
* @param dbConn
* @param ipaddr
* @param serviceName
* @param action
* @param txNo
* @return a list of events that need to be sent in response to these
* changes
* @throws SQLException
... | Helper method used to update the mapping of interfaces to services | doAddServiceMapping | {
"repo_name": "bugcy013/opennms-tmp-tools",
"path": "opennms-services/src/main/java/org/opennms/netmgt/capsd/BroadcastEventProcessor.java",
"license": "gpl-2.0",
"size": 95288
} | [
"java.sql.Connection",
"java.sql.PreparedStatement",
"java.sql.SQLException",
"java.util.List",
"org.opennms.core.utils.DBUtils",
"org.opennms.netmgt.xml.event.Event"
] | import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.SQLException; import java.util.List; import org.opennms.core.utils.DBUtils; import org.opennms.netmgt.xml.event.Event; | import java.sql.*; import java.util.*; import org.opennms.core.utils.*; import org.opennms.netmgt.xml.event.*; | [
"java.sql",
"java.util",
"org.opennms.core",
"org.opennms.netmgt"
] | java.sql; java.util; org.opennms.core; org.opennms.netmgt; | 1,218,427 |
@Override
protected void onCreate(Bundle savedInstanceState) {
Log.d(TAG, "onCreate:");
super.onCreate(savedInstanceState);
//setup view and toolbar
setContentView(R.layout.activity_photos_pager);
setupToolbar(R.id.picture_pager_toolbar, true);
//read intent ext... | void function(Bundle savedInstanceState) { Log.d(TAG, STR); super.onCreate(savedInstanceState); setContentView(R.layout.activity_photos_pager); setupToolbar(R.id.picture_pager_toolbar, true); Intent intent = getIntent(); id = intent.getStringExtra(EXTRA_ID); profilePictureUrl = intent.getStringExtra(EXTRA_PROFILE_PIC_U... | /**
* Set up the pager activity by doing the following:
* 1. Set up the view pager
* 2. Fetch the photo urls for the fragments in the pager
* @param savedInstanceState
*/ | Set up the pager activity by doing the following: 1. Set up the view pager 2. Fetch the photo urls for the fragments in the pager | onCreate | {
"repo_name": "yeelin/betweenus",
"path": "app/src/main/java/com/example/yeelin/projects/betweenus/activity/PhotosPagerActivity.java",
"license": "mit",
"size": 15124
} | [
"android.content.Intent",
"android.os.Bundle",
"android.os.Parcelable",
"android.util.Log",
"com.example.yeelin.projects.betweenus.adapter.PhotosStatePagerAdapter",
"com.example.yeelin.projects.betweenus.data.LocalConstants",
"com.example.yeelin.projects.betweenus.data.LocalPhoto"
] | import android.content.Intent; import android.os.Bundle; import android.os.Parcelable; import android.util.Log; import com.example.yeelin.projects.betweenus.adapter.PhotosStatePagerAdapter; import com.example.yeelin.projects.betweenus.data.LocalConstants; import com.example.yeelin.projects.betweenus.data.LocalPhoto; | import android.content.*; import android.os.*; import android.util.*; import com.example.yeelin.projects.betweenus.adapter.*; import com.example.yeelin.projects.betweenus.data.*; | [
"android.content",
"android.os",
"android.util",
"com.example.yeelin"
] | android.content; android.os; android.util; com.example.yeelin; | 2,716,974 |
public SimplePageInfoContainer getSimplePageInfoContainer() {
return new SimplePageInfoContainer(this.getId(), this.getNameText(), this.getContentText());
} | SimplePageInfoContainer function() { return new SimplePageInfoContainer(this.getId(), this.getNameText(), this.getContentText()); } | /**
* Transform SimplePage Dto to container object
*
* @return converted container object
*/ | Transform SimplePage Dto to container object | getSimplePageInfoContainer | {
"repo_name": "0x0000-dot-ru/jcommune",
"path": "jcommune-view/jcommune-web-controller/src/main/java/org/jtalks/jcommune/web/dto/SimplePageDto.java",
"license": "lgpl-2.1",
"size": 3529
} | [
"org.jtalks.jcommune.service.dto.SimplePageInfoContainer"
] | import org.jtalks.jcommune.service.dto.SimplePageInfoContainer; | import org.jtalks.jcommune.service.dto.*; | [
"org.jtalks.jcommune"
] | org.jtalks.jcommune; | 2,679,726 |
ManagedConnection manConn = null;
try {
manConn = connFactory.createManagedConnection(sub, connReqInfo);
} catch (ResourceException rex) {
rex.printStackTrace();
throw new PoolException(
LocalizedStrings.ManagedPoolCacheImpl_MANAGEDPOOLCACHEIMPLGETNEWCONNECTION_EXCEPTION_IN_CREATING_... | ManagedConnection manConn = null; try { manConn = connFactory.createManagedConnection(sub, connReqInfo); } catch (ResourceException rex) { rex.printStackTrace(); throw new PoolException( LocalizedStrings.ManagedPoolCacheImpl_MANAGEDPOOLCACHEIMPLGETNEWCONNECTION_EXCEPTION_IN_CREATING_NEW_MANAGED_POOLEDCONNECTION .toLoca... | /**
* Creates a new connection for the managed connection pool.
*
* @return the managed connection from the EIS as ManagedConnection object.
*/ | Creates a new connection for the managed connection pool | getNewPoolConnection | {
"repo_name": "deepakddixit/incubator-geode",
"path": "geode-core/src/main/java/org/apache/geode/internal/datasource/ManagedPoolCacheImpl.java",
"license": "apache-2.0",
"size": 3657
} | [
"javax.resource.ResourceException",
"javax.resource.spi.ConnectionEventListener",
"javax.resource.spi.ManagedConnection",
"org.apache.geode.internal.i18n.LocalizedStrings"
] | import javax.resource.ResourceException; import javax.resource.spi.ConnectionEventListener; import javax.resource.spi.ManagedConnection; import org.apache.geode.internal.i18n.LocalizedStrings; | import javax.resource.*; import javax.resource.spi.*; import org.apache.geode.internal.i18n.*; | [
"javax.resource",
"org.apache.geode"
] | javax.resource; org.apache.geode; | 2,390,952 |
public void connectWebSocket() {
URI uri;
try {
uri = new URI("ws://192.168.1.150:8080");
} catch (URISyntaxException e) {
e.printStackTrace();
return;
} | void function() { URI uri; try { uri = new URI("ws: } catch (URISyntaxException e) { e.printStackTrace(); return; } | /**
* Websocket methods
*/ | Websocket methods | connectWebSocket | {
"repo_name": "Sedatb23/SocialRobot",
"path": "android/app/src/main/java/com/hariharan/arduinousb/MainActivity.java",
"license": "mit",
"size": 13938
} | [
"java.net.URISyntaxException"
] | import java.net.URISyntaxException; | import java.net.*; | [
"java.net"
] | java.net; | 2,056,552 |
// todo [cdm 2015]: This clearly shouldn't be here! Maybe it's not needed at all now since parsing code does this?
public static void mergeLabels(Tree tree, List<CoreLabel> sentence) {
int idx = 0;
for (Tree t : tree.getLeaves()) {
CoreLabel cl = sentence.get(idx ++);
String value = t.value();
... | static void function(Tree tree, List<CoreLabel> sentence) { int idx = 0; for (Tree t : tree.getLeaves()) { CoreLabel cl = sentence.get(idx ++); String value = t.value(); cl.set(CoreAnnotations.ValueAnnotation.class, value); t.setLabel(cl); } tree.indexLeaves(); } | /**
* Sets the label of the leaf nodes of a Tree to be the CoreLabels in the given sentence.
* The original value() of the Tree nodes is preserved, and otherwise the label of tree
* leaves becomes the label from the List.
*/ | Sets the label of the leaf nodes of a Tree to be the CoreLabels in the given sentence. The original value() of the Tree nodes is preserved, and otherwise the label of tree leaves becomes the label from the List | mergeLabels | {
"repo_name": "automenta/corenlp",
"path": "src/edu/stanford/nlp/dcoref/MentionExtractor.java",
"license": "gpl-2.0",
"size": 18131
} | [
"edu.stanford.nlp.ling.CoreAnnotations",
"edu.stanford.nlp.ling.CoreLabel",
"edu.stanford.nlp.trees.Tree",
"java.util.List"
] | import edu.stanford.nlp.ling.CoreAnnotations; import edu.stanford.nlp.ling.CoreLabel; import edu.stanford.nlp.trees.Tree; import java.util.List; | import edu.stanford.nlp.ling.*; import edu.stanford.nlp.trees.*; import java.util.*; | [
"edu.stanford.nlp",
"java.util"
] | edu.stanford.nlp; java.util; | 405,210 |
public void writePropertyWithAttributes(Collection<ObjectLabel> objlabels, PKey propertyname, Value value) {
writePropertyWithAttributes(objlabels, propertyname, value, true, true);
} | void function(Collection<ObjectLabel> objlabels, PKey propertyname, Value value) { writePropertyWithAttributes(objlabels, propertyname, value, true, true); } | /**
* Assigns the given value to the given property of the given objects, with attributes.
* Attributes are taken from the given value.
* Modified is set on all values being written.
*/ | Assigns the given value to the given property of the given objects, with attributes. Attributes are taken from the given value. Modified is set on all values being written | writePropertyWithAttributes | {
"repo_name": "cs-au-dk/TAJS",
"path": "src/dk/brics/tajs/analysis/PropVarOperations.java",
"license": "apache-2.0",
"size": 65791
} | [
"dk.brics.tajs.lattice.ObjectLabel",
"dk.brics.tajs.lattice.PKey",
"dk.brics.tajs.lattice.Value",
"java.util.Collection"
] | import dk.brics.tajs.lattice.ObjectLabel; import dk.brics.tajs.lattice.PKey; import dk.brics.tajs.lattice.Value; import java.util.Collection; | import dk.brics.tajs.lattice.*; import java.util.*; | [
"dk.brics.tajs",
"java.util"
] | dk.brics.tajs; java.util; | 1,272,154 |
private void updateAtBottom(boolean atBottom) {
if (atBottom) {
nextButton.setText(R.string.btn_got_it);
nextButton.setOnClickListener(v2 -> {
onboardingViewModel.setOnboardedState(true);
if (binding.appAnalyticsSection.getVisibility() == View.VISIBLE) {
// Store whether the ... | void function(boolean atBottom) { if (atBottom) { nextButton.setText(R.string.btn_got_it); nextButton.setOnClickListener(v2 -> { onboardingViewModel.setOnboardedState(true); if (binding.appAnalyticsSection.getVisibility() == View.VISIBLE) { onboardingViewModel.setAppAnalyticsState( binding.onboardingAppAnalyticsSwitch.... | /**
* Update the UI depending on whether scrolling is at the bottom or not.
*/ | Update the UI depending on whether scrolling is at the bottom or not | updateAtBottom | {
"repo_name": "google/exposure-notifications-android",
"path": "app/src/v2/java/com/google/android/apps/exposurenotification/onboarding/OnboardingPermissionEnabledFragment.java",
"license": "apache-2.0",
"size": 6971
} | [
"android.view.View",
"android.view.accessibility.AccessibilityEvent"
] | import android.view.View; import android.view.accessibility.AccessibilityEvent; | import android.view.*; import android.view.accessibility.*; | [
"android.view"
] | android.view; | 934,171 |
@Override
protected MCRVirtualNode buildChildNode(Path fo) {
return null; //not implemented
} | MCRVirtualNode function(Path fo) { return null; } | /**
* Returns a MCRVirtualNode contained in this file as a child. A file that
* is a container, like zip or tar, may contain other files as children.
*/ | Returns a MCRVirtualNode contained in this file as a child. A file that is a container, like zip or tar, may contain other files as children | buildChildNode | {
"repo_name": "MyCoRe-Org/mycore",
"path": "mycore-base/src/main/java/org/mycore/datamodel/ifs2/MCRFile.java",
"license": "gpl-3.0",
"size": 5576
} | [
"java.nio.file.Path"
] | import java.nio.file.Path; | import java.nio.file.*; | [
"java.nio"
] | java.nio; | 2,902,808 |
@Test
public void whenDeleteIsUsed_thenNearCacheShouldBeInvalidated_onNearCacheAdapter() {
whenEntryIsRemoved_thenNearCacheShouldBeInvalidated(false, DataStructureMethods.DELETE);
} | void function() { whenEntryIsRemoved_thenNearCacheShouldBeInvalidated(false, DataStructureMethods.DELETE); } | /**
* Checks that the Near Cache is eventually invalidated when {@link DataStructureMethods#DELETE} is used.
*/ | Checks that the Near Cache is eventually invalidated when <code>DataStructureMethods#DELETE</code> is used | whenDeleteIsUsed_thenNearCacheShouldBeInvalidated_onNearCacheAdapter | {
"repo_name": "tkountis/hazelcast",
"path": "hazelcast/src/test/java/com/hazelcast/internal/nearcache/AbstractNearCacheBasicTest.java",
"license": "apache-2.0",
"size": 79879
} | [
"com.hazelcast.internal.adapter.DataStructureAdapter"
] | import com.hazelcast.internal.adapter.DataStructureAdapter; | import com.hazelcast.internal.adapter.*; | [
"com.hazelcast.internal"
] | com.hazelcast.internal; | 1,755,136 |
return Build.VERSION.SDK_INT >= 21;
}
private static class TransitionStub {
ArrayList<TransitionListener> mTransitionListeners;
TransitionStub() {
}
} | return Build.VERSION.SDK_INT >= 21; } private static class TransitionStub { ArrayList<TransitionListener> mTransitionListeners; TransitionStub() { } } | /**
* Returns true if system supports entrance Transition animations.
*/ | Returns true if system supports entrance Transition animations | systemSupportsEntranceTransitions | {
"repo_name": "AndroidX/androidx",
"path": "leanback/leanback/src/main/java/androidx/leanback/transition/TransitionHelper.java",
"license": "apache-2.0",
"size": 16367
} | [
"android.os.Build",
"java.util.ArrayList"
] | import android.os.Build; import java.util.ArrayList; | import android.os.*; import java.util.*; | [
"android.os",
"java.util"
] | android.os; java.util; | 1,612,698 |
@VisibleForTesting
static SortedSet<String> parseProtectedDirectories(Configuration conf) {
// Normalize each input path to guard against administrator error.
return new TreeSet<>(normalizePaths(
conf.getTrimmedStringCollection(FS_PROTECTED_DIRECTORIES),
FS_PROTECTED_DIRECTORIES));
} | static SortedSet<String> parseProtectedDirectories(Configuration conf) { return new TreeSet<>(normalizePaths( conf.getTrimmedStringCollection(FS_PROTECTED_DIRECTORIES), FS_PROTECTED_DIRECTORIES)); } | /**
* Parse configuration setting dfs.namenode.protected.directories to
* retrieve the set of protected directories.
*
* @param conf
* @return a TreeSet
*/ | Parse configuration setting dfs.namenode.protected.directories to retrieve the set of protected directories | parseProtectedDirectories | {
"repo_name": "odpi/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSDirectory.java",
"license": "apache-2.0",
"size": 62125
} | [
"java.util.SortedSet",
"java.util.TreeSet",
"org.apache.hadoop.conf.Configuration"
] | import java.util.SortedSet; import java.util.TreeSet; import org.apache.hadoop.conf.Configuration; | import java.util.*; import org.apache.hadoop.conf.*; | [
"java.util",
"org.apache.hadoop"
] | java.util; org.apache.hadoop; | 285,390 |
public static void debugLsr(Configuration conf,
Path p) throws IOException {
debugLsr(conf, p, new PrintingErrorReporter());
} | static void function(Configuration conf, Path p) throws IOException { debugLsr(conf, p, new PrintingErrorReporter()); } | /**
* ls -r for debugging purposes
*/ | ls -r for debugging purposes | debugLsr | {
"repo_name": "amyvmiwei/hbase",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/util/HBaseFsck.java",
"license": "apache-2.0",
"size": 172249
} | [
"java.io.IOException",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.fs.Path"
] | import java.io.IOException; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.Path; | import java.io.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 368,415 |
public void read(JmeImporter im) throws IOException {
InputCapsule ic = (InputCapsule) im.getCapsule(this);
leftVariable = (ShaderNodeVariable) ic.readSavable("leftVariable", null);
rightVariable = (ShaderNodeVariable) ic.readSavable("rightVariable", null);
condition = ic.readStr... | void function(JmeImporter im) throws IOException { InputCapsule ic = (InputCapsule) im.getCapsule(this); leftVariable = (ShaderNodeVariable) ic.readSavable(STR, null); rightVariable = (ShaderNodeVariable) ic.readSavable(STR, null); condition = ic.readString(STR, STRleftSwizzlingSTRSTRrightSwizzlingSTR"); } | /**
* jme seralization (not used)
*
* @param im the importer
* @throws IOException
*/ | jme seralization (not used) | read | {
"repo_name": "weilichuang/jmonkeyengine",
"path": "jme3-core/src/main/java/com/jme3/shader/VariableMapping.java",
"license": "bsd-3-clause",
"size": 6340
} | [
"com.jme3.export.InputCapsule",
"com.jme3.export.JmeImporter",
"java.io.IOException"
] | import com.jme3.export.InputCapsule; import com.jme3.export.JmeImporter; import java.io.IOException; | import com.jme3.export.*; import java.io.*; | [
"com.jme3.export",
"java.io"
] | com.jme3.export; java.io; | 1,190,598 |
void grantSchemaPrivileges(Session session, CatalogSchemaName schemaName, Set<Privilege> privileges, TrinoPrincipal grantee, boolean grantOption); | void grantSchemaPrivileges(Session session, CatalogSchemaName schemaName, Set<Privilege> privileges, TrinoPrincipal grantee, boolean grantOption); | /**
* Grants the specified privilege to the specified user on the specified schema.
*/ | Grants the specified privilege to the specified user on the specified schema | grantSchemaPrivileges | {
"repo_name": "electrum/presto",
"path": "core/trino-main/src/main/java/io/trino/metadata/Metadata.java",
"license": "apache-2.0",
"size": 24596
} | [
"io.trino.Session",
"io.trino.spi.connector.CatalogSchemaName",
"io.trino.spi.security.Privilege",
"io.trino.spi.security.TrinoPrincipal",
"java.util.Set"
] | import io.trino.Session; import io.trino.spi.connector.CatalogSchemaName; import io.trino.spi.security.Privilege; import io.trino.spi.security.TrinoPrincipal; import java.util.Set; | import io.trino.*; import io.trino.spi.connector.*; import io.trino.spi.security.*; import java.util.*; | [
"io.trino",
"io.trino.spi",
"java.util"
] | io.trino; io.trino.spi; java.util; | 1,347,061 |
protected JComponent getTypeSelector() {
if (typeSelector == null) {
typeSelector = new Box(BoxLayout.X_AXIS);
typeSelector.add(new UMLComboBoxNavigator(
Translator.localize("label.type.navigate.tooltip"),
new UMLComboBox2(
... | JComponent function() { if (typeSelector == null) { typeSelector = new Box(BoxLayout.X_AXIS); typeSelector.add(new UMLComboBoxNavigator( Translator.localize(STR), new UMLComboBox2( new UMLTaggedValueTypeComboBoxModel(), new ActionSetTaggedValueType()) )); } return typeSelector; } static class ActionSetTaggedValueModelE... | /**
* Returns the type selector.
* This is a component which allows the
* user to select a single taggedValue as the type.
*
* @return the modelelement selecter
*/ | Returns the type selector. This is a component which allows the user to select a single taggedValue as the type | getTypeSelector | {
"repo_name": "ckaestne/LEADT",
"path": "workspace/argouml_diagrams/argouml-app/src/org/argouml/uml/ui/foundation/extension_mechanisms/PropPanelTaggedValue.java",
"license": "gpl-3.0",
"size": 13086
} | [
"javax.swing.Box",
"javax.swing.BoxLayout",
"javax.swing.JComponent",
"org.argouml.i18n.Translator",
"org.argouml.uml.ui.UMLComboBox2",
"org.argouml.uml.ui.UMLComboBoxNavigator",
"org.tigris.gef.undo.UndoableAction"
] | import javax.swing.Box; import javax.swing.BoxLayout; import javax.swing.JComponent; import org.argouml.i18n.Translator; import org.argouml.uml.ui.UMLComboBox2; import org.argouml.uml.ui.UMLComboBoxNavigator; import org.tigris.gef.undo.UndoableAction; | import javax.swing.*; import org.argouml.i18n.*; import org.argouml.uml.ui.*; import org.tigris.gef.undo.*; | [
"javax.swing",
"org.argouml.i18n",
"org.argouml.uml",
"org.tigris.gef"
] | javax.swing; org.argouml.i18n; org.argouml.uml; org.tigris.gef; | 1,741,097 |
static byte[] getBytes(String s, String encoding) throws UnsupportedEncodingException {
if (encoding != null) {
return s.getBytes(encoding);
}
return s.getBytes();
}
| static byte[] getBytes(String s, String encoding) throws UnsupportedEncodingException { if (encoding != null) { return s.getBytes(encoding); } return s.getBytes(); } | /** Return a byte array corresponding to the given String, using the given
encoding.
*/ | Return a byte array corresponding to the given String, using the given | getBytes | {
"repo_name": "deusprogrammer/jna",
"path": "src/com/sun/jna/Native.java",
"license": "lgpl-2.1",
"size": 78784
} | [
"java.io.UnsupportedEncodingException"
] | import java.io.UnsupportedEncodingException; | import java.io.*; | [
"java.io"
] | java.io; | 142,119 |
public KualiDecimal getOriginalFringeBenefitAmount() {
if (this.originalFringeBenefitAmount == null || originalFringeBenefitAmount.isZero()) {
this.recalculateOriginalFringeBenefit();
}
return originalFringeBenefitAmount;
}
| KualiDecimal function() { if (this.originalFringeBenefitAmount == null originalFringeBenefitAmount.isZero()) { this.recalculateOriginalFringeBenefit(); } return originalFringeBenefitAmount; } | /**
* Gets the originalFringeBenefitAmount attribute.
*
* @return Returns the originalFringeBenefitAmount.
*/ | Gets the originalFringeBenefitAmount attribute | getOriginalFringeBenefitAmount | {
"repo_name": "ua-eas/ua-kfs-5.3",
"path": "work/src/org/kuali/kfs/module/ec/businessobject/EffortCertificationDetail.java",
"license": "agpl-3.0",
"size": 32057
} | [
"org.kuali.rice.core.api.util.type.KualiDecimal"
] | import org.kuali.rice.core.api.util.type.KualiDecimal; | import org.kuali.rice.core.api.util.type.*; | [
"org.kuali.rice"
] | org.kuali.rice; | 159,759 |
public IResourceMetadata[] getResourceMetadata() {
throw new UnsupportedOperationException();
} | IResourceMetadata[] function() { throw new UnsupportedOperationException(); } | /**
* This operation is not supported - the resource description of a scale-out
* index would include all "live" resources in the corresponding
* {@link MetadataIndex}.
*/ | This operation is not supported - the resource description of a scale-out index would include all "live" resources in the corresponding <code>MetadataIndex</code> | getResourceMetadata | {
"repo_name": "rac021/blazegraph_1_5_3_cluster_2_nodes",
"path": "bigdata/src/java/com/bigdata/service/ndx/AbstractScaleOutClientIndexView.java",
"license": "gpl-2.0",
"size": 42379
} | [
"com.bigdata.mdi.IResourceMetadata"
] | import com.bigdata.mdi.IResourceMetadata; | import com.bigdata.mdi.*; | [
"com.bigdata.mdi"
] | com.bigdata.mdi; | 242,024 |
public Collection<ObjectPropertyExpression> getObjectProperties();
| Collection<ObjectPropertyExpression> function(); | /**
* return all declared object properties
*
* @return
*/ | return all declared object properties | getObjectProperties | {
"repo_name": "srapisarda/ontop",
"path": "obdalib-core/src/main/java/it/unibz/inf/ontop/ontology/ImmutableOntologyVocabulary.java",
"license": "apache-2.0",
"size": 2441
} | [
"java.util.Collection"
] | import java.util.Collection; | import java.util.*; | [
"java.util"
] | java.util; | 65,525 |
@Generated
@Selector("deletePlaceholder")
boolean deletePlaceholder(); | @Selector(STR) boolean deletePlaceholder(); | /**
* If the placeholder is no longer needed or you wish to manually insert a cell for the drop data, you can
* remove the placeholder via this method.
* If the placeholder is no longer available (e.g. -reloadData has been called) this will return NO.
*/ | If the placeholder is no longer needed or you wish to manually insert a cell for the drop data, you can remove the placeholder via this method. If the placeholder is no longer available (e.g. -reloadData has been called) this will return NO | deletePlaceholder | {
"repo_name": "multi-os-engine/moe-core",
"path": "moe.apple/moe.platform.ios/src/main/java/apple/uikit/protocol/UICollectionViewDropPlaceholderContext.java",
"license": "apache-2.0",
"size": 2310
} | [
"org.moe.natj.objc.ann.Selector"
] | import org.moe.natj.objc.ann.Selector; | import org.moe.natj.objc.ann.*; | [
"org.moe.natj"
] | org.moe.natj; | 46,720 |
public static String getDate(Date aDate) {
SimpleDateFormat df;
String returnValue = "";
if (aDate != null) {
df = new SimpleDateFormat(getDatePattern());
returnValue = df.format(aDate);
}
return (returnValue);
} | static String function(Date aDate) { SimpleDateFormat df; String returnValue = ""; if (aDate != null) { df = new SimpleDateFormat(getDatePattern()); returnValue = df.format(aDate); } return (returnValue); } | /**
* This method attempts to convert an Oracle-formatted date
* in the form dd-MMM-yyyy to mm/dd/yyyy.
*
* @param aDate date from database as a string
* @return formatted string for the ui
*/ | This method attempts to convert an Oracle-formatted date in the form dd-MMM-yyyy to mm/dd/yyyy | getDate | {
"repo_name": "loveingenioustech/demo",
"path": "appfuse-demo/src/main/java/demo/util/DateUtil.java",
"license": "mit",
"size": 5644
} | [
"java.text.SimpleDateFormat",
"java.util.Date"
] | import java.text.SimpleDateFormat; import java.util.Date; | import java.text.*; import java.util.*; | [
"java.text",
"java.util"
] | java.text; java.util; | 935,145 |
//-----------------------------------------------------------------------
public final MetaProperty<URI> baseUri() {
return _baseUri;
} | final MetaProperty<URI> function() { return _baseUri; } | /**
* The meta-property for the {@code baseUri} property.
* @return the meta-property, not null
*/ | The meta-property for the baseUri property | baseUri | {
"repo_name": "McLeodMoores/starling",
"path": "projects/component/src/main/java/com/opengamma/component/factory/source/RemoteSourcesComponentFactory.java",
"license": "apache-2.0",
"size": 12504
} | [
"org.joda.beans.MetaProperty"
] | import org.joda.beans.MetaProperty; | import org.joda.beans.*; | [
"org.joda.beans"
] | org.joda.beans; | 2,499,961 |
@Message(id = Message.NONE, value = "Name of the user")
String argUser(); | @Message(id = Message.NONE, value = STR) String argUser(); | /**
* Instructions for the {@link org.jboss.as.domain.management.security.adduser.AddUser.CommandLineArgument#USER} command line argument.
* @return the message.
*/ | Instructions for the <code>org.jboss.as.domain.management.security.adduser.AddUser.CommandLineArgument#USER</code> command line argument | argUser | {
"repo_name": "luck3y/wildfly-core",
"path": "domain-management/src/main/java/org/jboss/as/domain/management/logging/DomainManagementLogger.java",
"license": "lgpl-2.1",
"size": 66410
} | [
"org.jboss.logging.annotations.Message"
] | import org.jboss.logging.annotations.Message; | import org.jboss.logging.annotations.*; | [
"org.jboss.logging"
] | org.jboss.logging; | 707,620 |
public void setGenre(List genre) {
this.genre = genre;
} | void function(List genre) { this.genre = genre; } | /**
* Set the genre.
*
* @param genre List of genres of movie.
*/ | Set the genre | setGenre | {
"repo_name": "amirakhmedov/ignite",
"path": "examples/src/main/java/org/apache/ignite/examples/ml/genetic/movie/Movie.java",
"license": "apache-2.0",
"size": 2996
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,654,771 |
String swapOut(List<FlowFileRecord> flowFiles, FlowFileQueue flowFileQueue, final String partitionName) throws IOException; | String swapOut(List<FlowFileRecord> flowFiles, FlowFileQueue flowFileQueue, final String partitionName) throws IOException; | /**
* Swaps out the given FlowFiles that belong to the queue with the given identifier.
*
* @param flowFiles the FlowFiles to swap out to external storage
* @param flowFileQueue the queue that the FlowFiles belong to
* @param partitionName the name of the partition within the queue, or <code>nu... | Swaps out the given FlowFiles that belong to the queue with the given identifier | swapOut | {
"repo_name": "apsaltis/nifi",
"path": "nifi-framework-api/src/main/java/org/apache/nifi/controller/repository/FlowFileSwapManager.java",
"license": "apache-2.0",
"size": 6162
} | [
"java.io.IOException",
"java.util.List",
"org.apache.nifi.controller.queue.FlowFileQueue"
] | import java.io.IOException; import java.util.List; import org.apache.nifi.controller.queue.FlowFileQueue; | import java.io.*; import java.util.*; import org.apache.nifi.controller.queue.*; | [
"java.io",
"java.util",
"org.apache.nifi"
] | java.io; java.util; org.apache.nifi; | 1,114,399 |
void buildCQLLibraryShareTable(List<CQLLibraryShareDTO> data); | void buildCQLLibraryShareTable(List<CQLLibraryShareDTO> data); | /**
* Builds the CQL library share table.
*
* @param data the data
*/ | Builds the CQL library share table | buildCQLLibraryShareTable | {
"repo_name": "MeasureAuthoringTool/MeasureAuthoringTool_Release",
"path": "mat/src/main/java/mat/client/CqlLibraryPresenter.java",
"license": "cc0-1.0",
"size": 49257
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,650,669 |
private void assign(TrailAssignment currentAssignment, int[] atomIDs, ThriceTruth[] truthValues) {
currentAssignment.growForMaxAtomId();
for (int i = 0; i < truthValues.length; i++) {
int atomID = atomIDs[i];
if (truthValues[i] != null) {
currentAssignment.assign(atomID, truthValues[i]);
}
}
} | void function(TrailAssignment currentAssignment, int[] atomIDs, ThriceTruth[] truthValues) { currentAssignment.growForMaxAtomId(); for (int i = 0; i < truthValues.length; i++) { int atomID = atomIDs[i]; if (truthValues[i] != null) { currentAssignment.assign(atomID, truthValues[i]); } } } | /**
* Assigns {@code truthValues} to atoms {@code atomIDs} in {@code currentAssignment}.
*/ | Assigns truthValues to atoms atomIDs in currentAssignment | assign | {
"repo_name": "alpha-asp/Alpha",
"path": "alpha-core/src/test/java/at/ac/tuwien/kr/alpha/core/grounder/NaiveGrounderTest.java",
"license": "bsd-2-clause",
"size": 22479
} | [
"at.ac.tuwien.kr.alpha.core.solver.ThriceTruth",
"at.ac.tuwien.kr.alpha.core.solver.TrailAssignment"
] | import at.ac.tuwien.kr.alpha.core.solver.ThriceTruth; import at.ac.tuwien.kr.alpha.core.solver.TrailAssignment; | import at.ac.tuwien.kr.alpha.core.solver.*; | [
"at.ac.tuwien"
] | at.ac.tuwien; | 22,173 |
void setJobDuedate(String jobId, Date newDuedate); | void setJobDuedate(String jobId, Date newDuedate); | /**
* Sets a new due date for the provided id.
* When newDuedate is null, the job is executed with the next
* job executor run.
* @param jobId id of job to modify, cannot be null.
* @param newDuedate new date for job execution
*/ | Sets a new due date for the provided id. When newDuedate is null, the job is executed with the next job executor run | setJobDuedate | {
"repo_name": "menski/camunda-bpm-platform",
"path": "engine/src/main/java/org/camunda/bpm/engine/ManagementService.java",
"license": "apache-2.0",
"size": 22435
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 419,490 |
@Override public void enterSelectorAlias(@NotNull QueryGrammarParser.SelectorAliasContext ctx) { } | @Override public void enterSelectorAlias(@NotNull QueryGrammarParser.SelectorAliasContext ctx) { } | /**
* {@inheritDoc}
* <p/>
* The default implementation does nothing.
*/ | The default implementation does nothing | exitExprWithPassword | {
"repo_name": "pmeisen/dis-timeintervaldataanalyzer",
"path": "src/net/meisen/dissertation/impl/parser/query/generated/QueryGrammarBaseListener.java",
"license": "bsd-3-clause",
"size": 33327
} | [
"org.antlr.v4.runtime.misc.NotNull"
] | import org.antlr.v4.runtime.misc.NotNull; | import org.antlr.v4.runtime.misc.*; | [
"org.antlr.v4"
] | org.antlr.v4; | 1,760,875 |
default public List<String> getSubNodes(String key){
return getSubNodes(key, false);
}
| default List<String> function(String key){ return getSubNodes(key, false); } | /**
* Get a list of all possible sub nodes for the provided key.
*
* @param key
* @return
*/ | Get a list of all possible sub nodes for the provided key | getSubNodes | {
"repo_name": "elexis/elexis-3-core",
"path": "bundles/ch.elexis.core/src/ch/elexis/core/services/IConfigService.java",
"license": "epl-1.0",
"size": 18163
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,394,533 |
public Networks getNetworksFrom(String sourceIndex) throws XBRLException; | Networks function(String sourceIndex) throws XBRLException; | /**
* Implemented by {@link Store#getNetworksFrom(String,String,String)}.
* @param sourceIndex The source fragment index
* @return a set of networks comprising the relationships
* from the source fragment.
* @throws XBRLException
*/ | Implemented by <code>Store#getNetworksFrom(String,String,String)</code> | getNetworksFrom | {
"repo_name": "martinggww/Programming",
"path": "XBRL/xbrl-api/module-api/src/main/java/org/xbrlapi/data/Store.java",
"license": "gpl-2.0",
"size": 59248
} | [
"org.xbrlapi.networks.Networks",
"org.xbrlapi.utilities.XBRLException"
] | import org.xbrlapi.networks.Networks; import org.xbrlapi.utilities.XBRLException; | import org.xbrlapi.networks.*; import org.xbrlapi.utilities.*; | [
"org.xbrlapi.networks",
"org.xbrlapi.utilities"
] | org.xbrlapi.networks; org.xbrlapi.utilities; | 1,919,448 |
public int computeHorizontalScrollExtent(@NonNull State state) {
return 0;
} | int function(@NonNull State state) { return 0; } | /**
* <p>Override this method if you want to support scroll bars.</p>
*
* <p>Read {@link RecyclerView#computeHorizontalScrollExtent()} for details.</p>
*
* <p>Default implementation returns 0.</p>
*
* @param state Current state of RecyclerView
* @r... | Override this method if you want to support scroll bars. Read <code>RecyclerView#computeHorizontalScrollExtent()</code> for details. Default implementation returns 0 | computeHorizontalScrollExtent | {
"repo_name": "aosp-mirror/platform_frameworks_support",
"path": "v7/recyclerview/src/main/java/androidx/recyclerview/widget/RecyclerView.java",
"license": "apache-2.0",
"size": 582575
} | [
"androidx.annotation.NonNull"
] | import androidx.annotation.NonNull; | import androidx.annotation.*; | [
"androidx.annotation"
] | androidx.annotation; | 1,943,025 |
CompilationSupport validateAttributes() {
for (PathFragment absoluteInclude :
Iterables.filter(attributes.includes(), PathFragment.IS_ABSOLUTE)) {
ruleContext.attributeError(
"includes", String.format(ABSOLUTE_INCLUDES_PATH_FORMAT, absoluteInclude));
}
if (ruleContext.attributes()... | CompilationSupport validateAttributes() { for (PathFragment absoluteInclude : Iterables.filter(attributes.includes(), PathFragment.IS_ABSOLUTE)) { ruleContext.attributeError( STR, String.format(ABSOLUTE_INCLUDES_PATH_FORMAT, absoluteInclude)); } if (ruleContext.attributes().has("srcs", BuildType.LABEL_LIST)) { Set<Arti... | /**
* Validates compilation-related attributes on this rule.
*
* @return this compilation support
*/ | Validates compilation-related attributes on this rule | validateAttributes | {
"repo_name": "kamalmarhubi/bazel",
"path": "src/main/java/com/google/devtools/build/lib/rules/objc/CompilationSupport.java",
"license": "apache-2.0",
"size": 60627
} | [
"com.google.common.collect.Iterables",
"com.google.common.collect.Sets",
"com.google.devtools.build.lib.actions.Artifact",
"com.google.devtools.build.lib.analysis.RuleConfiguredTarget",
"com.google.devtools.build.lib.packages.BuildType",
"com.google.devtools.build.lib.vfs.PathFragment",
"java.util.HashS... | import com.google.common.collect.Iterables; import com.google.common.collect.Sets; import com.google.devtools.build.lib.actions.Artifact; import com.google.devtools.build.lib.analysis.RuleConfiguredTarget; import com.google.devtools.build.lib.packages.BuildType; import com.google.devtools.build.lib.vfs.PathFragment; im... | import com.google.common.collect.*; import com.google.devtools.build.lib.actions.*; import com.google.devtools.build.lib.analysis.*; import com.google.devtools.build.lib.packages.*; import com.google.devtools.build.lib.vfs.*; import java.util.*; | [
"com.google.common",
"com.google.devtools",
"java.util"
] | com.google.common; com.google.devtools; java.util; | 360,599 |
public Series getSeries(String key) {
return series.get(key);
} | Series function(String key) { return series.get(key); } | /**
* Get series defined in definition tag, can be used for onSimulate method.
*
* @param key
* The id of series
* @return The series
*/ | Get series defined in definition tag, can be used for onSimulate method | getSeries | {
"repo_name": "chuntungho/input-simulator",
"path": "src/com/yayamagic/tool/tool/ActivityTool.java",
"license": "mit",
"size": 9888
} | [
"com.yayamagic.tool.simulator.Series"
] | import com.yayamagic.tool.simulator.Series; | import com.yayamagic.tool.simulator.*; | [
"com.yayamagic.tool"
] | com.yayamagic.tool; | 1,297,067 |
File getFile(final String bpid, final long blockId, boolean touch) {
ReplicaInfo info = volumeMap.get(bpid, blockId);
if (info != null) {
if (touch && info.getVolume().isTransientStorage()) {
ramDiskReplicaTracker.touch(bpid, blockId);
datanode.getMetrics().incrRamDiskBlocksReadHits();
... | File getFile(final String bpid, final long blockId, boolean touch) { ReplicaInfo info = volumeMap.get(bpid, blockId); if (info != null) { if (touch && info.getVolume().isTransientStorage()) { ramDiskReplicaTracker.touch(bpid, blockId); datanode.getMetrics().incrRamDiskBlocksReadHits(); } return info.getBlockFile(); } r... | /**
* Turn the block identifier into a filename
* @param bpid Block pool Id
* @param blockId a block's id
* @return on disk data file path; null if the replica does not exist
*/ | Turn the block identifier into a filename | getFile | {
"repo_name": "xuchenCN/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": 100444
} | [
"java.io.File",
"org.apache.hadoop.hdfs.server.datanode.ReplicaInfo"
] | import java.io.File; import org.apache.hadoop.hdfs.server.datanode.ReplicaInfo; | import java.io.*; import org.apache.hadoop.hdfs.server.datanode.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 1,790,119 |
public MavenProjectWizardPage setWorkingSet(String workingSet){
new LabeledCombo(this, "Working set:").setText(workingSet);
return this;
}
| MavenProjectWizardPage function(String workingSet){ new LabeledCombo(this, STR).setText(workingSet); return this; } | /**
* Sets the working set.
*
* @param workingSet the new working set
*/ | Sets the working set | setWorkingSet | {
"repo_name": "djelinek/reddeer",
"path": "plugins/org.eclipse.reddeer.eclipse/src/org/eclipse/reddeer/eclipse/m2e/core/ui/wizard/MavenProjectWizardPage.java",
"license": "epl-1.0",
"size": 3185
} | [
"org.eclipse.reddeer.swt.impl.combo.LabeledCombo"
] | import org.eclipse.reddeer.swt.impl.combo.LabeledCombo; | import org.eclipse.reddeer.swt.impl.combo.*; | [
"org.eclipse.reddeer"
] | org.eclipse.reddeer; | 441,201 |
List<ModelServiceInstance> instances = new ArrayList<ModelServiceInstance>();
for (ModelServiceInstance instance : list) {
boolean passed = true;
for (QueryCriterion criterion : query.getCriteria()) {
if (criterion.isMatch(instance.getMetadata()) == false) {
... | List<ModelServiceInstance> instances = new ArrayList<ModelServiceInstance>(); for (ModelServiceInstance instance : list) { boolean passed = true; for (QueryCriterion criterion : query.getCriteria()) { if (criterion.isMatch(instance.getMetadata()) == false) { passed = false; break; } } if (passed) { instances.add(instan... | /**
* Filter the ModelServiceInstance list against the ServiceInstanceQuery.
*
* @param query
* the ServiceInstanceQuery matchers.
* @param list
* the ModelServiceInstance list.
* @return
* the matched ModelServiceInstance list.
*/ | Filter the ModelServiceInstance list against the ServiceInstanceQuery | filter | {
"repo_name": "foundation-runtime/service-directory",
"path": "1.1/sd-api/src/main/java/com/cisco/oss/foundation/directory/impl/ServiceInstanceQueryHelper.java",
"license": "apache-2.0",
"size": 3034
} | [
"com.cisco.oss.foundation.directory.entity.ModelServiceInstance",
"com.cisco.oss.foundation.directory.query.QueryCriterion",
"java.util.ArrayList",
"java.util.List"
] | import com.cisco.oss.foundation.directory.entity.ModelServiceInstance; import com.cisco.oss.foundation.directory.query.QueryCriterion; import java.util.ArrayList; import java.util.List; | import com.cisco.oss.foundation.directory.entity.*; import com.cisco.oss.foundation.directory.query.*; import java.util.*; | [
"com.cisco.oss",
"java.util"
] | com.cisco.oss; java.util; | 273,692 |
public static ArrayList<Label> convertToNavigationLabels(List<org.transdroid.daemon.Label> daemonLabels, String unnamedLabel) {
if (daemonLabels == null) {
return null;
}
ArrayList<Label> localLabels = new ArrayList<>();
unnamedLabelText = unnamedLabel;
localLabels.add(new Label(unnamedLabel, -1, true))... | static ArrayList<Label> function(List<org.transdroid.daemon.Label> daemonLabels, String unnamedLabel) { if (daemonLabels == null) { return null; } ArrayList<Label> localLabels = new ArrayList<>(); unnamedLabelText = unnamedLabel; localLabels.add(new Label(unnamedLabel, -1, true)); for (org.transdroid.daemon.Label label... | /**
* Converts a list of labels as retrieved from a server daemon into a list of labels that can be used in the UI as navigation filters.
* @param daemonLabels The raw list of labels as received from the server daemon adapter
* @param unnamedLabel The text to show for the empty label (i.e. the unnamed label)
* ... | Converts a list of labels as retrieved from a server daemon into a list of labels that can be used in the UI as navigation filters | convertToNavigationLabels | {
"repo_name": "blurbdust/seedbox-mobile-app",
"path": "app/src/main/java/org/transdroid/core/gui/navigation/Label.java",
"license": "gpl-3.0",
"size": 4132
} | [
"android.os.Parcel",
"android.text.TextUtils",
"java.util.ArrayList",
"java.util.List"
] | import android.os.Parcel; import android.text.TextUtils; import java.util.ArrayList; import java.util.List; | import android.os.*; import android.text.*; import java.util.*; | [
"android.os",
"android.text",
"java.util"
] | android.os; android.text; java.util; | 2,550,414 |
public void finer(
String sourceClass,
String sourceMethod,
String msg
)
{
logp(Level.FINER, sourceClass, sourceMethod, msg);
} | void function( String sourceClass, String sourceMethod, String msg ) { logp(Level.FINER, sourceClass, sourceMethod, msg); } | /**
* Log a FINER message, with no arguments.
* <p>
* The message is forwarded to appropriate Java Logger objects.
* <p>
* @param sourceClass the name of the class that issued the logging request
* @param sourceMethod the name of the method that issued the logging request
* @param... | Log a FINER message, with no arguments. The message is forwarded to appropriate Java Logger objects. | finer | {
"repo_name": "kulinski/myfaces",
"path": "impl/src/main/java/org/apache/myfaces/logging/MyfacesLogger.java",
"license": "apache-2.0",
"size": 63180
} | [
"java.util.logging.Level"
] | import java.util.logging.Level; | import java.util.logging.*; | [
"java.util"
] | java.util; | 144,971 |
public static IAST newInstance(final int intialArgumentsCapacity, final IExpr head) {
return AST.newInstance(intialArgumentsCapacity, head, false);
} | static IAST function(final int intialArgumentsCapacity, final IExpr head) { return AST.newInstance(intialArgumentsCapacity, head, false); } | /**
* Create a new abstract syntax tree (AST).
*
* @param intialArgumentsCapacity the initial capacity of arguments of the AST.
* @param head the header expression of the function. If the ast represents a function like <code>
* f[x,y], Sin[x],...</code>, the <code>head</code> will be an instance of t... | Create a new abstract syntax tree (AST) | newInstance | {
"repo_name": "axkr/symja_android_library",
"path": "symja_android_library/matheclipse-core/src/main/java/org/matheclipse/core/expression/F.java",
"license": "gpl-3.0",
"size": 283472
} | [
"org.matheclipse.core.interfaces.IExpr"
] | import org.matheclipse.core.interfaces.IExpr; | import org.matheclipse.core.interfaces.*; | [
"org.matheclipse.core"
] | org.matheclipse.core; | 140,848 |
EAttribute getMBrickletRemoteSwitch_TypeBDevices(); | EAttribute getMBrickletRemoteSwitch_TypeBDevices(); | /**
* Returns the meta object for the attribute '{@link org.openhab.binding.tinkerforge.internal.model.MBrickletRemoteSwitch#getTypeBDevices <em>Type BDevices</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Type BDevices</em>'.
* @see org.openhab... | Returns the meta object for the attribute '<code>org.openhab.binding.tinkerforge.internal.model.MBrickletRemoteSwitch#getTypeBDevices Type BDevices</code>'. | getMBrickletRemoteSwitch_TypeBDevices | {
"repo_name": "gregfinley/openhab",
"path": "bundles/binding/org.openhab.binding.tinkerforge/src/main/java/org/openhab/binding/tinkerforge/internal/model/ModelPackage.java",
"license": "epl-1.0",
"size": 665067
} | [
"org.eclipse.emf.ecore.EAttribute"
] | import org.eclipse.emf.ecore.EAttribute; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 64,008 |
private int iterateAndCount(WALIterator walIter, boolean touchEntries) throws IgniteCheckedException {
int cnt = 0;
try (WALIterator it = walIter) {
while (it.hasNextX()) {
final IgniteBiTuple<WALPointer, WALRecord> next = it.nextX();
final WALRecord walR... | int function(WALIterator walIter, boolean touchEntries) throws IgniteCheckedException { int cnt = 0; try (WALIterator it = walIter) { while (it.hasNextX()) { final IgniteBiTuple<WALPointer, WALRecord> next = it.nextX(); final WALRecord walRecord = next.get2(); if (touchEntries && walRecord.type() == WALRecord.RecordTyp... | /**
* Iterates on records and closes iterator.
*
* @param walIter iterator to count, will be closed.
* @param touchEntries access data within entries.
* @return count of records.
* @throws IgniteCheckedException if failed to iterate.
*/ | Iterates on records and closes iterator | iterateAndCount | {
"repo_name": "wmz7year/ignite",
"path": "modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/db/wal/reader/IgniteWalReaderTest.java",
"license": "apache-2.0",
"size": 50797
} | [
"org.apache.ignite.IgniteCheckedException",
"org.apache.ignite.internal.pagemem.wal.WALIterator",
"org.apache.ignite.internal.pagemem.wal.WALPointer",
"org.apache.ignite.internal.pagemem.wal.record.DataEntry",
"org.apache.ignite.internal.pagemem.wal.record.DataRecord",
"org.apache.ignite.internal.pagemem.... | import org.apache.ignite.IgniteCheckedException; import org.apache.ignite.internal.pagemem.wal.WALIterator; import org.apache.ignite.internal.pagemem.wal.WALPointer; import org.apache.ignite.internal.pagemem.wal.record.DataEntry; import org.apache.ignite.internal.pagemem.wal.record.DataRecord; import org.apache.ignite.... | import org.apache.ignite.*; import org.apache.ignite.internal.pagemem.wal.*; import org.apache.ignite.internal.pagemem.wal.record.*; import org.apache.ignite.internal.processors.cache.*; import org.apache.ignite.lang.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 1,534,480 |
public AgentHost getNextLiveAgentHost(final int activeBuildID, final List freeAgentHosts,
final AgentHost preferredAgentHost) throws IOException {
// Get live agent liveHosts
final BuilderConfigurationManager bcm = BuilderConfigurationManager.getInstance();
final C... | AgentHost function(final int activeBuildID, final List freeAgentHosts, final AgentHost preferredAgentHost) throws IOException { final BuilderConfigurationManager bcm = BuilderConfigurationManager.getInstance(); final ConfigurationManager cm = ConfigurationManager.getInstance(); final BuildConfig buildConfig = cm.getBui... | /**
* Rotates an agent.
*
* @param activeBuildID active build ID.
* @param freeAgentHosts if not empty, the method will try to pick an agent that is not busy
* @param preferredAgentHost a preferred agent host.
* @return an agent host.
* @throws IOException if I/O exception occurred.
*/ | Rotates an agent | getNextLiveAgentHost | {
"repo_name": "simeshev/parabuild-ci",
"path": "src/org/parabuild/ci/remote/AgentManager.java",
"license": "lgpl-3.0",
"size": 34115
} | [
"java.io.IOException",
"java.security.NoSuchAlgorithmException",
"java.security.SecureRandom",
"java.util.List",
"java.util.Random",
"org.parabuild.ci.configuration.AgentHost",
"org.parabuild.ci.configuration.BuilderConfigurationManager",
"org.parabuild.ci.configuration.ConfigurationManager",
"org.p... | import java.io.IOException; import java.security.NoSuchAlgorithmException; import java.security.SecureRandom; import java.util.List; import java.util.Random; import org.parabuild.ci.configuration.AgentHost; import org.parabuild.ci.configuration.BuilderConfigurationManager; import org.parabuild.ci.configuration.Configur... | import java.io.*; import java.security.*; import java.util.*; import org.parabuild.ci.configuration.*; import org.parabuild.ci.object.*; | [
"java.io",
"java.security",
"java.util",
"org.parabuild.ci"
] | java.io; java.security; java.util; org.parabuild.ci; | 255,882 |
@Source("com/google/appinventor/images/cloudDB.png")
ImageResource cloudDB(); | @Source(STR) ImageResource cloudDB(); | /**
* Designer palette item: cloudDB component
*/ | Designer palette item: cloudDB component | cloudDB | {
"repo_name": "mintingle/appinventor-sources",
"path": "appinventor/appengine/src/com/google/appinventor/client/Images.java",
"license": "apache-2.0",
"size": 13759
} | [
"com.google.gwt.resources.client.ImageResource"
] | import com.google.gwt.resources.client.ImageResource; | import com.google.gwt.resources.client.*; | [
"com.google.gwt"
] | com.google.gwt; | 353,819 |
protected static List<Statistics> getFsStatistics(Path path, Configuration conf) throws IOException {
List<Statistics> matchedStats = new ArrayList<FileSystem.Statistics>();
path = path.getFileSystem(conf).makeQualified(path);
String scheme = path.toUri().getScheme();
for (Statistics stats : FileSyste... | static List<Statistics> function(Path path, Configuration conf) throws IOException { List<Statistics> matchedStats = new ArrayList<FileSystem.Statistics>(); path = path.getFileSystem(conf).makeQualified(path); String scheme = path.toUri().getScheme(); for (Statistics stats : FileSystem.getAllStatistics()) { if (stats.g... | /**
* Gets a handle to the Statistics instance based on the scheme associated
* with path.
*
* @param path the path.
* @param conf the configuration to extract the scheme from if not part of
* the path.
* @return a Statistics instance, or null if none is found for the scheme.
*/ | Gets a handle to the Statistics instance based on the scheme associated with path | getFsStatistics | {
"repo_name": "WIgor/hadoop",
"path": "hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java",
"license": "apache-2.0",
"size": 62223
} | [
"java.io.IOException",
"java.util.ArrayList",
"java.util.List",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.fs.FileSystem",
"org.apache.hadoop.fs.Path"
] | import java.io.IOException; import java.util.ArrayList; import java.util.List; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.Path; | import java.io.*; import java.util.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 185,074 |
@Override
public void setCurrencyRate(final BigDecimal argCurrencyRate) {
this.currencyRate = argCurrencyRate;
} | void function(final BigDecimal argCurrencyRate) { this.currencyRate = argCurrencyRate; } | /**
* Sets the value of currencyRate
*
* @param argCurrencyRate Value to assign to this.currencyRate
*/ | Sets the value of currencyRate | setCurrencyRate | {
"repo_name": "bhutchinson/kfs",
"path": "kfs-tem/src/main/java/org/kuali/kfs/module/tem/businessobject/AbstractExpense.java",
"license": "agpl-3.0",
"size": 15569
} | [
"java.math.BigDecimal"
] | import java.math.BigDecimal; | import java.math.*; | [
"java.math"
] | java.math; | 2,158,241 |
public void setLastExecutionResult(MutationExecutionResult lastExecutionResult,
Mutation mutation) {
this.lastMutationResult.put(mutation, lastExecutionResult);
} | void function(MutationExecutionResult lastExecutionResult, Mutation mutation) { this.lastMutationResult.put(mutation, lastExecutionResult); } | /**
* <p>Setter for the field <code>lastExecutionResult</code>.</p>
*
* @param lastExecutionResult a {@link org.evosuite.coverage.mutation.MutationExecutionResult} object.
* @param mutation a {@link org.evosuite.coverage.mutation.Mutation} object.
*/ | Setter for the field <code>lastExecutionResult</code> | setLastExecutionResult | {
"repo_name": "SoftwareEngineeringToolDemos/FSE-2011-EvoSuite",
"path": "client/src/main/java/org/evosuite/testcase/ExecutableChromosome.java",
"license": "lgpl-3.0",
"size": 4757
} | [
"org.evosuite.coverage.mutation.Mutation",
"org.evosuite.coverage.mutation.MutationExecutionResult"
] | import org.evosuite.coverage.mutation.Mutation; import org.evosuite.coverage.mutation.MutationExecutionResult; | import org.evosuite.coverage.mutation.*; | [
"org.evosuite.coverage"
] | org.evosuite.coverage; | 1,028,606 |
public synchronized boolean processBlockMunlockRequest(
ExtendedBlockId blockId) {
if (!enabled) return true;
boolean allowMunlock = true;
Set<Slot> affectedSlots = slots.get(blockId);
for (Slot slot : affectedSlots) {
slot.makeUnanchorable();
if (slot.isAnchored()) {
allowMu... | synchronized boolean function( ExtendedBlockId blockId) { if (!enabled) return true; boolean allowMunlock = true; Set<Slot> affectedSlots = slots.get(blockId); for (Slot slot : affectedSlots) { slot.makeUnanchorable(); if (slot.isAnchored()) { allowMunlock = false; } } return allowMunlock; } | /**
* Mark any slots associated with this blockId as unanchorable.
*
* @param blockId The block ID.
* @return True if we should allow the munlock request.
*/ | Mark any slots associated with this blockId as unanchorable | processBlockMunlockRequest | {
"repo_name": "dennishuo/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/ShortCircuitRegistry.java",
"license": "apache-2.0",
"size": 14670
} | [
"java.util.Set",
"org.apache.hadoop.hdfs.ExtendedBlockId",
"org.apache.hadoop.hdfs.shortcircuit.ShortCircuitShm"
] | import java.util.Set; import org.apache.hadoop.hdfs.ExtendedBlockId; import org.apache.hadoop.hdfs.shortcircuit.ShortCircuitShm; | import java.util.*; import org.apache.hadoop.hdfs.*; import org.apache.hadoop.hdfs.shortcircuit.*; | [
"java.util",
"org.apache.hadoop"
] | java.util; org.apache.hadoop; | 1,948,907 |
public void testRedeployContinuousMode() throws Exception {
depMode = DeploymentMode.CONTINUOUS;
processTest(true, false);
} | void function() throws Exception { depMode = DeploymentMode.CONTINUOUS; processTest(true, false); } | /**
* Test GridDeploymentMode.CONTINUOUS mode.
*
* @throws Exception if error occur.
*/ | Test GridDeploymentMode.CONTINUOUS mode | testRedeployContinuousMode | {
"repo_name": "dlnufox/ignite",
"path": "modules/core/src/test/java/org/apache/ignite/p2p/GridP2PDifferentClassLoaderSelfTest.java",
"license": "apache-2.0",
"size": 6841
} | [
"org.apache.ignite.configuration.DeploymentMode"
] | import org.apache.ignite.configuration.DeploymentMode; | import org.apache.ignite.configuration.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 1,259,053 |
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<List<CertificateEmailInner>> retrieveCertificateEmailHistoryAsync(
String resourceGroupName, String name) {
return retrieveCertificateEmailHistoryWithResponseAsync(resourceGroupName, name)
.flatMap(
(Response<Lis... | @ServiceMethod(returns = ReturnType.SINGLE) Mono<List<CertificateEmailInner>> function( String resourceGroupName, String name) { return retrieveCertificateEmailHistoryWithResponseAsync(resourceGroupName, name) .flatMap( (Response<List<CertificateEmailInner>> res) -> { if (res.getValue() != null) { return Mono.just(res.... | /**
* Retrieve email history.
*
* @param resourceGroupName Name of the resource group to which the resource belongs.
* @param name Name of the certificate order.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws DefaultErrorResponseErrorException thrown... | Retrieve email history | retrieveCertificateEmailHistoryAsync | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanagerhybrid/azure-resourcemanager-appservice/src/main/java/com/azure/resourcemanager/appservice/implementation/AppServiceCertificateOrdersClientImpl.java",
"license": "mit",
"size": 205075
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.core.http.rest.Response",
"com.azure.resourcemanager.appservice.fluent.models.CertificateEmailInner",
"java.util.List"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.resourcemanager.appservice.fluent.models.CertificateEmailInner; import java.util.List; | import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.resourcemanager.appservice.fluent.models.*; import java.util.*; | [
"com.azure.core",
"com.azure.resourcemanager",
"java.util"
] | com.azure.core; com.azure.resourcemanager; java.util; | 1,360,470 |
static void writeUntilIOException(Socket s) {
try {
byte[] bytes = new byte[100];
while (true) {
s.getOutputStream().write(bytes);
out.format("Client wrote %d bytes%n", bytes.length);
}
} catch (IOException ioe) {
out.fo... | static void writeUntilIOException(Socket s) { try { byte[] bytes = new byte[100]; while (true) { s.getOutputStream().write(bytes); out.format(STR, bytes.length); } } catch (IOException ioe) { out.format(STR, ioe); } } | /**
* Write bytes to a socket until I/O exception is thrown
*/ | Write bytes to a socket until I/O exception is thrown | writeUntilIOException | {
"repo_name": "md-5/jdk10",
"path": "test/jdk/java/net/Socket/ReadAfterReset.java",
"license": "gpl-2.0",
"size": 5215
} | [
"java.io.IOException",
"java.net.Socket"
] | import java.io.IOException; import java.net.Socket; | import java.io.*; import java.net.*; | [
"java.io",
"java.net"
] | java.io; java.net; | 214,904 |
return ResourcesPlugin.getWorkspace().getRoot().getLocation().toFile();
} | return ResourcesPlugin.getWorkspace().getRoot().getLocation().toFile(); } | /**
* Returns the workspace root as file.
*
* @return the workspace root as file
*/ | Returns the workspace root as file | getWorkspaceRoot | {
"repo_name": "SSEHUB/EASyProducer",
"path": "Plugins/IVML/de.uni_hildesheim.sse.ivml.ui/src/de/uni_hildesheim/sse/ui/StandaloneActivator.java",
"license": "apache-2.0",
"size": 3423
} | [
"org.eclipse.core.resources.ResourcesPlugin"
] | import org.eclipse.core.resources.ResourcesPlugin; | import org.eclipse.core.resources.*; | [
"org.eclipse.core"
] | org.eclipse.core; | 2,004,265 |
private String setupFullPath(String imageName) {
File mFolder = new File(Environment.getExternalStorageDirectory(), DEFAULT_APP_IMAGEDATA_DIRECTORY);
if (isExternalStorageReadable() && isExternalStorageWritable() && !mFolder.exists()) {
if (!mFolder.mkdirs()) {
Log.e("ER... | String function(String imageName) { File mFolder = new File(Environment.getExternalStorageDirectory(), DEFAULT_APP_IMAGEDATA_DIRECTORY); if (isExternalStorageReadable() && isExternalStorageWritable() && !mFolder.exists()) { if (!mFolder.mkdirs()) { Log.e("ERROR", STR); return ""; } } return mFolder.getPath() + '/' + im... | /**
* Creates the path for the image with name 'imageName' in DEFAULT_APP.. directory
* @param imageName name of the image
* @return the full path of the image. If it failed to create directory, return empty string
*/ | Creates the path for the image with name 'imageName' in DEFAULT_APP.. directory | setupFullPath | {
"repo_name": "Acidburn0zzz/org.numixproject.hermes",
"path": "hermes/src/main/java/org/numixproject/hermes/utils/TinyDB.java",
"license": "gpl-2.0",
"size": 16320
} | [
"android.os.Environment",
"android.util.Log",
"java.io.File"
] | import android.os.Environment; import android.util.Log; import java.io.File; | import android.os.*; import android.util.*; import java.io.*; | [
"android.os",
"android.util",
"java.io"
] | android.os; android.util; java.io; | 495,253 |
@Override
public DjNsOpt rename(Name name) {
return new DjNsOpt(name, null);
} | DjNsOpt function(Name name) { return new DjNsOpt(name, null); } | /**
* Rename this table
*/ | Rename this table | rename | {
"repo_name": "lkhusid/oneops",
"path": "crawler/src/generated-sources/java/com/oneops/crawler/jooq/cms/tables/DjNsOpt.java",
"license": "apache-2.0",
"size": 4437
} | [
"org.jooq.Name"
] | import org.jooq.Name; | import org.jooq.*; | [
"org.jooq"
] | org.jooq; | 655,722 |
@POST("list/{list_id}/add_item")
Call<Status> addMovie(
@Path("list_id") Integer listId,
@Body ListOperation item
); | @POST(STR) Call<Status> addMovie( @Path(STR) Integer listId, @Body ListOperation item ); | /**
* Add movie to list.
* <p>
* <b>Requires an active Session.</b>
*
* @param listId A BaseList TMDb id.(String/<b>Integer</b>).
* @param item The Body to send. ({@link com.uwetrottmann.tmdb2.entities.ListOperation ListOperation})
*/ | Add movie to list. Requires an active Session | addMovie | {
"repo_name": "ProIcons/tmdb-java",
"path": "src/main/java/com/uwetrottmann/tmdb2/services/ListsService.java",
"license": "unlicense",
"size": 4976
} | [
"com.uwetrottmann.tmdb2.entities.ListOperation",
"com.uwetrottmann.tmdb2.entities.Status"
] | import com.uwetrottmann.tmdb2.entities.ListOperation; import com.uwetrottmann.tmdb2.entities.Status; | import com.uwetrottmann.tmdb2.entities.*; | [
"com.uwetrottmann.tmdb2"
] | com.uwetrottmann.tmdb2; | 2,634,621 |
public Chronology getChronology(Object object, DateTimeZone zone) {
if (object.getClass().getName().endsWith(".BuddhistCalendar")) {
return BuddhistChronology.getInstance(zone);
} else if (object instanceof GregorianCalendar) {
GregorianCalendar gc = (GregorianCalendar) objec... | Chronology function(Object object, DateTimeZone zone) { if (object.getClass().getName().endsWith(STR)) { return BuddhistChronology.getInstance(zone); } else if (object instanceof GregorianCalendar) { GregorianCalendar gc = (GregorianCalendar) object; long cutover = gc.getGregorianChange().getTime(); if (cutover == Long... | /**
* Gets the chronology, which is the GJChronology if a GregorianCalendar is used,
* BuddhistChronology if a BuddhistCalendar is used or ISOChronology otherwise.
* The time zone specified is used in preference to that on the calendar.
*
* @param object the Calendar to convert, must not be n... | Gets the chronology, which is the GJChronology if a GregorianCalendar is used, BuddhistChronology if a BuddhistCalendar is used or ISOChronology otherwise. The time zone specified is used in preference to that on the calendar | getChronology | {
"repo_name": "mnn/AutoShutdown",
"path": "src/main/java/externalAS/org/joda/time/convert/CalendarConverter.java",
"license": "lgpl-2.1",
"size": 5019
} | [
"java.util.GregorianCalendar"
] | import java.util.GregorianCalendar; | import java.util.*; | [
"java.util"
] | java.util; | 659,083 |
protected void addModulePropertyDescriptor(Object object) {
itemPropertyDescriptors.add(createItemPropertyDescriptor(
((ComposeableAdapterFactory) adapterFactory)
.getRootAdapterFactory(), getResourceLocator(),
getString("_UI_ResourceRefType_module_feature"), getString(
"_UI_PropertyDescriptor_... | void function(Object object) { itemPropertyDescriptors.add(createItemPropertyDescriptor( ((ComposeableAdapterFactory) adapterFactory) .getRootAdapterFactory(), getResourceLocator(), getString(STR), getString( STR, STR, STR), NamingPackage.eINSTANCE .getResourceRefType_Module(), true, ItemPropertyDescriptor.GENERIC_VALU... | /**
* This adds a property descriptor for the Module feature. <!--
* begin-user-doc --> <!-- end-user-doc -->
*
* @generated
*/ | This adds a property descriptor for the Module feature. | addModulePropertyDescriptor | {
"repo_name": "apache/geronimo-devtools",
"path": "plugins/org.apache.geronimo.deployment.model.edit/src/org/apache/geronimo/xml/ns/naming/provider/ResourceRefTypeItemProvider.java",
"license": "apache-2.0",
"size": 13484
} | [
"org.apache.geronimo.xml.ns.naming.NamingPackage",
"org.eclipse.emf.edit.provider.ComposeableAdapterFactory",
"org.eclipse.emf.edit.provider.ItemPropertyDescriptor"
] | import org.apache.geronimo.xml.ns.naming.NamingPackage; import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; | import org.apache.geronimo.xml.ns.naming.*; import org.eclipse.emf.edit.provider.*; | [
"org.apache.geronimo",
"org.eclipse.emf"
] | org.apache.geronimo; org.eclipse.emf; | 489,996 |
@Deprecated
default void renderModel(Appendable writer, Object model) throws IOException {
// This method is a placeholder to support any client classes
// which previously extended Renderable implementers, such as Tags.
// No internal classes should implement this method; except to supp... | default void renderModel(Appendable writer, Object model) throws IOException { throw new RuntimeException(STR); } | /**
* Render the Renderable and it's children using the supplied writer and a model.
*
* @param writer the current writer
* @param model a model object to provide data for children to render
*/ | Render the Renderable and it's children using the supplied writer and a model | renderModel | {
"repo_name": "tipsy/j2html",
"path": "library/src/main/java/j2html/tags/Renderable.java",
"license": "apache-2.0",
"size": 3030
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,954,711 |
public static JSplitPane findJSplitPaneUnder(Component comp, ComponentChooser chooser) {
return (JSplitPane) findContainerUnder(comp, new JSplitPaneFinder(chooser));
} | static JSplitPane function(Component comp, ComponentChooser chooser) { return (JSplitPane) findContainerUnder(comp, new JSplitPaneFinder(chooser)); } | /**
* Searches JSplitPane object which component lies on.
*
* @param comp Component to find JSplitPane under.
* @param chooser org.netbeans.jemmy.ComponentChooser implementation.
* @return JSplitPane instance or null if component was not found.
*/ | Searches JSplitPane object which component lies on | findJSplitPaneUnder | {
"repo_name": "md-5/jdk10",
"path": "test/jdk/sanity/client/lib/jemmy/src/org/netbeans/jemmy/operators/JSplitPaneOperator.java",
"license": "gpl-2.0",
"size": 29887
} | [
"java.awt.Component",
"javax.swing.JSplitPane",
"org.netbeans.jemmy.ComponentChooser"
] | import java.awt.Component; import javax.swing.JSplitPane; import org.netbeans.jemmy.ComponentChooser; | import java.awt.*; import javax.swing.*; import org.netbeans.jemmy.*; | [
"java.awt",
"javax.swing",
"org.netbeans.jemmy"
] | java.awt; javax.swing; org.netbeans.jemmy; | 1,980,191 |
public final void setMonitoringListener(MonitoringListener monitoringListener) {
this.monitoringListener = monitoringListener;
} | final void function(MonitoringListener monitoringListener) { this.monitoringListener = monitoringListener; } | /**
* Sets a custom MonitoringListener to use for the client.
*
* @param monitoringListener Custom Monitoring Listener to use.
*/ | Sets a custom MonitoringListener to use for the client | setMonitoringListener | {
"repo_name": "jentfoo/aws-sdk-java",
"path": "aws-java-sdk-core/src/main/java/com/amazonaws/client/builder/AwsClientBuilder.java",
"license": "apache-2.0",
"size": 22211
} | [
"com.amazonaws.monitoring.MonitoringListener"
] | import com.amazonaws.monitoring.MonitoringListener; | import com.amazonaws.monitoring.*; | [
"com.amazonaws.monitoring"
] | com.amazonaws.monitoring; | 1,285,261 |
public void setLimitsVoltage(double lower, double upper) {
if (lower > upper) {
throw new BoundaryException("Lower bound is greater than upper bound");
}
AnalogJNI.setAnalogTriggerLimitsVoltage(m_port, lower, upper);
} | void function(double lower, double upper) { if (lower > upper) { throw new BoundaryException(STR); } AnalogJNI.setAnalogTriggerLimitsVoltage(m_port, lower, upper); } | /**
* Set the upper and lower limits of the analog trigger. The limits are given as floating point
* voltage values.
*
* @param lower the lower voltage limit
* @param upper the upper voltage limit
*/ | Set the upper and lower limits of the analog trigger. The limits are given as floating point voltage values | setLimitsVoltage | {
"repo_name": "pjreiniger/TempAllWpi",
"path": "wpilibj/src/main/java/edu/wpi/first/wpilibj/AnalogTrigger.java",
"license": "bsd-3-clause",
"size": 5739
} | [
"edu.wpi.first.wpilibj.hal.AnalogJNI",
"edu.wpi.first.wpilibj.util.BoundaryException"
] | import edu.wpi.first.wpilibj.hal.AnalogJNI; import edu.wpi.first.wpilibj.util.BoundaryException; | import edu.wpi.first.wpilibj.hal.*; import edu.wpi.first.wpilibj.util.*; | [
"edu.wpi.first"
] | edu.wpi.first; | 1,328,802 |
private void getDirectionAndShowResult() {
final Activity activity = this;
final Point start = endpointPoint[ENDPOINT_START];
final Point finish = endpointPoint[ENDPOINT_FINISH];
try {
request.findRoute(getResources().getString(R.string.iso639code),
start.getLocation(), finish.getLocation(),
new... | void function() { final Activity activity = this; final Point start = endpointPoint[ENDPOINT_START]; final Point finish = endpointPoint[ENDPOINT_FINISH]; try { request.findRoute(getResources().getString(R.string.iso639code), start.getLocation(), finish.getLocation(), new JSONResponseHandler() { | /**
* Gets the direction from server and show it in result when done. It will
* take from the internal {@link #endpointPoint}s attribute as parameter.
*/ | Gets the direction from server and show it in result when done. It will take from the internal <code>#endpointPoint</code>s attribute as parameter | getDirectionAndShowResult | {
"repo_name": "UiiLabsDev/smartpublictransport-as",
"path": "app/src/main/java/travel/kiri/smarttransportapp/MainActivity.java",
"license": "mit",
"size": 20666
} | [
"android.app.Activity",
"travel.kiri.smarttransportapp.model.Point",
"travel.kiri.smarttransportapp.model.protocol.JSONResponseHandler"
] | import android.app.Activity; import travel.kiri.smarttransportapp.model.Point; import travel.kiri.smarttransportapp.model.protocol.JSONResponseHandler; | import android.app.*; import travel.kiri.smarttransportapp.model.*; import travel.kiri.smarttransportapp.model.protocol.*; | [
"android.app",
"travel.kiri.smarttransportapp"
] | android.app; travel.kiri.smarttransportapp; | 196,955 |
public Collection<Clause> learn(TimeStamp timeStamp) {
updateWeights(timeStamp);
assignActualValuesToGroundLiterals(timeStamp);
return groundedMarkovNetwork.getAllClausesThatWereGrounded();
}
| Collection<Clause> function(TimeStamp timeStamp) { updateWeights(timeStamp); assignActualValuesToGroundLiterals(timeStamp); return groundedMarkovNetwork.getAllClausesThatWereGrounded(); } | /**
* Learns the weights of clauses.
*
* @return The clause objects with their learned weights.
*/ | Learns the weights of clauses | learn | {
"repo_name": "boost-starai/BoostSRL",
"path": "code/src/edu/wisc/cs/will/MLN_WeightLearning/PSCG.java",
"license": "gpl-3.0",
"size": 16853
} | [
"edu.wisc.cs.will.FOPC",
"edu.wisc.cs.will.MLN_Task",
"java.util.Collection"
] | import edu.wisc.cs.will.FOPC; import edu.wisc.cs.will.MLN_Task; import java.util.Collection; | import edu.wisc.cs.will.*; import java.util.*; | [
"edu.wisc.cs",
"java.util"
] | edu.wisc.cs; java.util; | 819,601 |
public void obtenerSimbolos(String formula, String simboloPrincipal) {
letraYvalor.getFormulas().add(formula);
letraYvalor.setParteFinalEvaluada(new ArrayList<>());
letraYvalor.setParteInicialEvaluada(new ArrayList<>());
String restoFormula;
String finalFormula;
Stri... | void function(String formula, String simboloPrincipal) { letraYvalor.getFormulas().add(formula); letraYvalor.setParteFinalEvaluada(new ArrayList<>()); letraYvalor.setParteInicialEvaluada(new ArrayList<>()); String restoFormula; String finalFormula; String negacionSimboloPrincipal = STR~STR(STR)STR~STR(STRSTRSTR")); } i... | /**
* metodo que nos permite llamar los metodos anteriores con los cuales vamos
* a evaluar la formula, vamos a guardar el resultado de la evaluacion
*
* @param formula, la formula ingresada por el usuario.
* @param simboloPrincipal, el simbolo principal de la formula
*/ | metodo que nos permite llamar los metodos anteriores con los cuales vamos a evaluar la formula, vamos a guardar el resultado de la evaluacion | obtenerSimbolos | {
"repo_name": "camilozuluaga/LogicaFormal",
"path": "Satisfacibilidad/src/logica/satisfacibilidad/LogicaSatisfacibilidad.java",
"license": "gpl-3.0",
"size": 39640
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 1,906,172 |
public @Nullable <T extends Feature> T getFeature(Class<T> type){
List <T> allFeature = getFeatures(type);
if(!allFeature.isEmpty())
return allFeature.get(0);
//else
return null;
}//getFeature
| @Nullable <T extends Feature> T function(Class<T> type){ List <T> allFeature = getFeatures(type); if(!allFeature.isEmpty()) return allFeature.get(0); return null; } | /**
* search for a specific feature
* @param type type of feature that we want search
* @param <T> class that will want search
* @return the feature of type {@code type} exported by this node, or null if not present
*/ | search for a specific feature | getFeature | {
"repo_name": "flyloong/BlueSTSDK",
"path": "BlueSTSDK/src/main/java/com/st/BlueSTSDK/Node.java",
"license": "bsd-3-clause",
"size": 73331
} | [
"android.support.annotation.Nullable",
"java.util.List"
] | import android.support.annotation.Nullable; import java.util.List; | import android.support.annotation.*; import java.util.*; | [
"android.support",
"java.util"
] | android.support; java.util; | 408,549 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.