method
stringlengths
13
441k
clean_method
stringlengths
7
313k
doc
stringlengths
17
17.3k
comment
stringlengths
3
1.42k
method_name
stringlengths
1
273
extra
dict
imports
list
imports_info
stringlengths
19
34.8k
cluster_imports_info
stringlengths
15
3.66k
libraries
list
libraries_info
stringlengths
6
661
id
int64
0
2.92M
public List<SearchActivity> listLastSearches() { return historyService.listLastSearchesByUser(currentUser); }
List<SearchActivity> function() { return historyService.listLastSearchesByUser(currentUser); }
/** * Return the last searches * @return */
Return the last searches
listLastSearches
{ "repo_name": "fregaham/KiWi", "path": "extensions/dashboard/src/kiwi/dashboard/action/UserHistoryAction.java", "license": "bsd-3-clause", "size": 4662 }
[ "java.util.List", "kiwi.model.activity.SearchActivity" ]
import java.util.List; import kiwi.model.activity.SearchActivity;
import java.util.*; import kiwi.model.activity.*;
[ "java.util", "kiwi.model.activity" ]
java.util; kiwi.model.activity;
815,602
public Map<ConverterOption<?>, Object> getCustomOptions() { return new LinkedHashMap<ConverterOption<?>, Object>(defaultOptions); }
Map<ConverterOption<?>, Object> function() { return new LinkedHashMap<ConverterOption<?>, Object>(defaultOptions); }
/** * Get a modifiable set of options. Consider caching this object * as this method does a shallow copy of the default setting on every invocation. * * @return the modifiable options. */
Get a modifiable set of options. Consider caching this object as this method does a shallow copy of the default setting on every invocation
getCustomOptions
{ "repo_name": "marcosoldati/helio-coordinate-converter", "path": "src/main/java/ch/fhnw/i4ds/helio/coordinate/converter/AbstractConverter.java", "license": "lgpl-3.0", "size": 3397 }
[ "ch.fhnw.i4ds.helio.coordinate.converter.option.ConverterOption", "java.util.LinkedHashMap", "java.util.Map" ]
import ch.fhnw.i4ds.helio.coordinate.converter.option.ConverterOption; import java.util.LinkedHashMap; import java.util.Map;
import ch.fhnw.i4ds.helio.coordinate.converter.option.*; import java.util.*;
[ "ch.fhnw.i4ds", "java.util" ]
ch.fhnw.i4ds; java.util;
649,602
public void addInterestedClients(InternalDistributedMember member, Set clients, Set clientsInv, boolean longIDs) { this.memberWithFilterInfoExists = true; FilterInfo fInfo = this.serverFilterInfo.get(member); if (fInfo == null) { fInfo = new FilterInfo(); this.serverFilterInfo.put(member...
void function(InternalDistributedMember member, Set clients, Set clientsInv, boolean longIDs) { this.memberWithFilterInfoExists = true; FilterInfo fInfo = this.serverFilterInfo.get(member); if (fInfo == null) { fInfo = new FilterInfo(); this.serverFilterInfo.put(member, fInfo); } if (clients != null && clients.size() >...
/** * Sets interested clients routing information * * @param member on which the client interests are satisfied * @param clients Set containing interested clients with receiveValues=true * @param clientsInv Set containing interested clients with receiveValues=false * @param longIDs whether the client ...
Sets interested clients routing information
addInterestedClients
{ "repo_name": "davebarnes97/geode", "path": "geode-core/src/main/java/org/apache/geode/internal/cache/FilterRoutingInfo.java", "license": "apache-2.0", "size": 19201 }
[ "java.util.Set", "org.apache.geode.distributed.internal.membership.InternalDistributedMember" ]
import java.util.Set; import org.apache.geode.distributed.internal.membership.InternalDistributedMember;
import java.util.*; import org.apache.geode.distributed.internal.membership.*;
[ "java.util", "org.apache.geode" ]
java.util; org.apache.geode;
547,452
@Column(header = Messages.GUI_MODULES_HEADER_TITLE_0, expandRatio = 1.0f, order = 20) public String getTitle() { return Strings.nullToEmpty(m_module.getNiceName()); }
@Column(header = Messages.GUI_MODULES_HEADER_TITLE_0, expandRatio = 1.0f, order = 20) String function() { return Strings.nullToEmpty(m_module.getNiceName()); }
/** * Gets the nice name of the module.<p> * * @return the nice name of the module */
Gets the nice name of the module
getTitle
{ "repo_name": "alkacon/opencms-core", "path": "src/org/opencms/ui/apps/modules/CmsModuleRow.java", "license": "lgpl-2.1", "size": 3947 }
[ "com.google.common.base.Strings", "org.opencms.ui.apps.Messages", "org.opencms.ui.util.table.Column" ]
import com.google.common.base.Strings; import org.opencms.ui.apps.Messages; import org.opencms.ui.util.table.Column;
import com.google.common.base.*; import org.opencms.ui.apps.*; import org.opencms.ui.util.table.*;
[ "com.google.common", "org.opencms.ui" ]
com.google.common; org.opencms.ui;
840,954
public void addNewStandort() { final TdtaStandortMastCustomBean newStandort = TdtaStandortMastCustomBean.createNew(); newStandort.setVerrechnungseinheit(true); if (BelisBroker.getDefaultUnterhaltMast() != null) { newStandort.setUnterhaltspflichtMast(BelisBroker.getDefaultUnterha...
void function() { final TdtaStandortMastCustomBean newStandort = TdtaStandortMastCustomBean.createNew(); newStandort.setVerrechnungseinheit(true); if (BelisBroker.getDefaultUnterhaltMast() != null) { newStandort.setUnterhaltspflichtMast(BelisBroker.getDefaultUnterhaltMast()); } newStandort.addPropertyChangeListener(wor...
/** * DOCUMENT ME! */
DOCUMENT ME
addNewStandort
{ "repo_name": "cismet/belis-client", "path": "src/main/java/de/cismet/belis/broker/BelisBroker.java", "license": "gpl-3.0", "size": 138018 }
[ "de.cismet.cids.custom.beans.belis2.TdtaStandortMastCustomBean" ]
import de.cismet.cids.custom.beans.belis2.TdtaStandortMastCustomBean;
import de.cismet.cids.custom.beans.belis2.*;
[ "de.cismet.cids" ]
de.cismet.cids;
69,637
if (error != null) { final String message = error.getMessage(); return message != null ? Status.UNKNOWN.withDescription(message) : Status.UNKNOWN.withDescription(error.getClass().getSimpleName()); } if (statusMessage != null && statusMessage.equa...
if (error != null) { final String message = error.getMessage(); return message != null ? Status.UNKNOWN.withDescription(message) : Status.UNKNOWN.withDescription(error.getClass().getSimpleName()); } if (statusMessage != null && statusMessage.equalsIgnoreCase(STR)) { return Status.OK; } return Status.UNKNOWN.withDescrip...
/** * Parses an OpenTelemetry Status from AMQP Error Condition. * * @param statusMessage AMQP description for this error condition. * @param error the error occurred during response transmission (optional). * @return the corresponding OpenTelemetry {@link Status}. */
Parses an OpenTelemetry Status from AMQP Error Condition
parseStatusMessage
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/core/azure-core-tracing-opencensus/src/main/java/com/azure/core/tracing/opencensus/implementation/AmqpTraceUtil.java", "license": "mit", "size": 1199 }
[ "io.opencensus.trace.Status" ]
import io.opencensus.trace.Status;
import io.opencensus.trace.*;
[ "io.opencensus.trace" ]
io.opencensus.trace;
2,799,749
String[] result = cache.get(input); if (result != null) { return result; } MediaType m = null; try { m = HttpParser.parseMediaType(new StringReader(input)); } catch (IOException e) { // Ignore - return null } if (m != null) { ...
String[] result = cache.get(input); if (result != null) { return result; } MediaType m = null; try { m = HttpParser.parseMediaType(new StringReader(input)); } catch (IOException e) { } if (m != null) { result = new String[] {m.toStringNoCharset(), m.getCharset()}; cache.put(input, result); } return result; }
/** * Looks in the cache and returns the cached value if one is present. If no * match exists in the cache, a new parser is created, the input parsed and * the results placed in the cache and returned to the user. * * @param input The content-type header value to parse * @return The r...
Looks in the cache and returns the cached value if one is present. If no match exists in the cache, a new parser is created, the input parsed and the results placed in the cache and returned to the user
parse
{ "repo_name": "plumer/codana", "path": "tomcat_files/7.0.61/MediaTypeCache.java", "license": "mit", "size": 2282 }
[ "java.io.IOException", "java.io.StringReader" ]
import java.io.IOException; import java.io.StringReader;
import java.io.*;
[ "java.io" ]
java.io;
445,548
public void guardarOrden(Orden orden) throws ExcepcionConsulta;
void function(Orden orden) throws ExcepcionConsulta;
/** * Registra una orden dentro de la base de datos. * * @param orden Orden a registrar * @throws ExcepcionConsulta Error en la consulta */
Registra una orden dentro de la base de datos
guardarOrden
{ "repo_name": "ProjectAton/Aton", "path": "src/main/java/org/sunnycake/aton/dao/OrdenDAO.java", "license": "gpl-2.0", "size": 1767 }
[ "org.sunnycake.aton.dto.Orden", "org.sunnycake.aton.exception.ExcepcionConsulta" ]
import org.sunnycake.aton.dto.Orden; import org.sunnycake.aton.exception.ExcepcionConsulta;
import org.sunnycake.aton.dto.*; import org.sunnycake.aton.exception.*;
[ "org.sunnycake.aton" ]
org.sunnycake.aton;
675,387
public ImmutableList<Field> createFieldSchemas() { Map<String, String> featureNameToDesc = valueToFeatureName().entrySet().stream() .collect( Collectors.toMap( entry -> entry.getValue(), entry -> entry.getKey(), (fdes...
ImmutableList<Field> function() { Map<String, String> featureNameToDesc = valueToFeatureName().entrySet().stream() .collect( Collectors.toMap( entry -> entry.getValue(), entry -> entry.getKey(), (fdesc1, fdesc2) -> fdesc2)); return valueToFeatureName().values().stream() .distinct() .map( featureName -> new Field( featu...
/** * Creates a list of pair of feature column name and feature column type based on the * valueToFeatureName values. */
Creates a list of pair of feature column name and feature column type based on the valueToFeatureName values
createFieldSchemas
{ "repo_name": "GoogleCloudPlatform/cloud-for-marketing", "path": "marketing-analytics/predicting/ml-data-windowing-pipeline/feature/accumulator/AccumulatorOptions.java", "license": "apache-2.0", "size": 2946 }
[ "com.google.common.collect.ImmutableList", "com.google.corp.gtech.ads.datacatalyst.components.mldatawindowingpipeline.model.Field", "java.util.Map", "java.util.stream.Collectors" ]
import com.google.common.collect.ImmutableList; import com.google.corp.gtech.ads.datacatalyst.components.mldatawindowingpipeline.model.Field; import java.util.Map; import java.util.stream.Collectors;
import com.google.common.collect.*; import com.google.corp.gtech.ads.datacatalyst.components.mldatawindowingpipeline.model.*; import java.util.*; import java.util.stream.*;
[ "com.google.common", "com.google.corp", "java.util" ]
com.google.common; com.google.corp; java.util;
1,829,858
public void property(String name, LexicalUnit value, boolean important) throws CSSException { }
void function(String name, LexicalUnit value, boolean important) throws CSSException { }
/** * <b>SAC</b>: Implements {@link * org.w3c.css.sac.DocumentHandler#property(String,LexicalUnit,boolean)}. */
SAC: Implements <code>org.w3c.css.sac.DocumentHandler#property(String,LexicalUnit,boolean)</code>
property
{ "repo_name": "Squeegee/batik", "path": "sources/org/apache/batik/css/parser/DefaultDocumentHandler.java", "license": "apache-2.0", "size": 4652 }
[ "org.w3c.css.sac.CSSException", "org.w3c.css.sac.LexicalUnit" ]
import org.w3c.css.sac.CSSException; import org.w3c.css.sac.LexicalUnit;
import org.w3c.css.sac.*;
[ "org.w3c.css" ]
org.w3c.css;
1,277,145
@Override public synchronized List<JobSpec> getJobs() { return Lists.transform(Lists.newArrayList( loader.loadPullFilesRecursively(loader.getRootDirectory(), this.sysConfig, shouldLoadGlobalConf())), this.converter); }
synchronized List<JobSpec> function() { return Lists.transform(Lists.newArrayList( loader.loadPullFilesRecursively(loader.getRootDirectory(), this.sysConfig, shouldLoadGlobalConf())), this.converter); }
/** * Fetch all the job files under the jobConfDirPath * @return A collection of JobSpec */
Fetch all the job files under the jobConfDirPath
getJobs
{ "repo_name": "aditya1105/gobblin", "path": "gobblin-runtime/src/main/java/org/apache/gobblin/runtime/job_catalog/ImmutableFSJobCatalog.java", "license": "apache-2.0", "size": 12325 }
[ "com.google.common.collect.Lists", "java.util.List", "org.apache.gobblin.runtime.api.JobSpec" ]
import com.google.common.collect.Lists; import java.util.List; import org.apache.gobblin.runtime.api.JobSpec;
import com.google.common.collect.*; import java.util.*; import org.apache.gobblin.runtime.api.*;
[ "com.google.common", "java.util", "org.apache.gobblin" ]
com.google.common; java.util; org.apache.gobblin;
1,657,120
private MediaDrm.KeyRequest getKeyRequest(SessionId sessionId, byte[] data, String mime, int keyType, HashMap<String, String> optionalParameters) throws android.media.NotProvisionedException { assert mMediaDrm != null; assert mMediaCryptoSession != null; assert !mProv...
MediaDrm.KeyRequest function(SessionId sessionId, byte[] data, String mime, int keyType, HashMap<String, String> optionalParameters) throws android.media.NotProvisionedException { assert mMediaDrm != null; assert mMediaCryptoSession != null; assert !mProvisioningPending; if (optionalParameters == null) { optionalParame...
/** * Get a key request. * * @param sessionId ID of session on which we need to get the key request. * @param data Data needed to get the key request. * @param mime Mime type to get the key request. * @param keyType Key type for the requested key. * @param optionalParameters Optional ...
Get a key request
getKeyRequest
{ "repo_name": "youtube/cobalt", "path": "third_party/chromium/media/base/android/java/src/org/chromium/media/MediaDrmBridge.java", "license": "bsd-3-clause", "size": 62151 }
[ "android.media.MediaDrm", "java.util.HashMap", "org.chromium.base.Log", "org.chromium.media.MediaDrmSessionManager" ]
import android.media.MediaDrm; import java.util.HashMap; import org.chromium.base.Log; import org.chromium.media.MediaDrmSessionManager;
import android.media.*; import java.util.*; import org.chromium.base.*; import org.chromium.media.*;
[ "android.media", "java.util", "org.chromium.base", "org.chromium.media" ]
android.media; java.util; org.chromium.base; org.chromium.media;
249,372
EAttribute getHydroPowerPlant_SurgeTankCode();
EAttribute getHydroPowerPlant_SurgeTankCode();
/** * Returns the meta object for the attribute '{@link CIM.IEC61970.Generation.Production.HydroPowerPlant#getSurgeTankCode <em>Surge Tank Code</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the attribute '<em>Surge Tank Code</em>'. * @see CIM.IEC61970.Generation.Produ...
Returns the meta object for the attribute '<code>CIM.IEC61970.Generation.Production.HydroPowerPlant#getSurgeTankCode Surge Tank Code</code>'.
getHydroPowerPlant_SurgeTankCode
{ "repo_name": "georghinkel/ttc2017smartGrids", "path": "solutions/ModelJoin/src/main/java/CIM/IEC61970/Generation/Production/ProductionPackage.java", "license": "mit", "size": 499866 }
[ "org.eclipse.emf.ecore.EAttribute" ]
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
806,734
private void initUnconfirmedTab () { // Done already if (m_modelUnconfirmed != null) return; // Header Vector<String> columnNames = new Vector<String>(); columnNames.add(Msg.translate(Env.getCtx(), m_C_BPartner_ID == 0 ? "C_BPartner_ID" : "M_Product_ID")); columnNames.add(Msg.translate(E...
void function () { if (m_modelUnconfirmed != null) return; Vector<String> columnNames = new Vector<String>(); columnNames.add(Msg.translate(Env.getCtx(), m_C_BPartner_ID == 0 ? STR : STR)); columnNames.add(Msg.translate(Env.getCtx(), STR)); columnNames.add(Msg.translate(Env.getCtx(), STR)); columnNames.add(Msg.translat...
/** * Query Unconfirmed */
Query Unconfirmed
initUnconfirmedTab
{ "repo_name": "geneos/adempiere", "path": "client/src/org/compiere/apps/search/InvoiceHistory.java", "license": "gpl-2.0", "size": 25950 }
[ "java.sql.PreparedStatement", "java.sql.ResultSet", "java.sql.SQLException", "java.sql.Timestamp", "java.util.Vector", "java.util.logging.Level", "javax.swing.table.DefaultTableModel", "org.compiere.minigrid.MiniTable", "org.compiere.util.DB", "org.compiere.util.Env", "org.compiere.util.Msg" ]
import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Timestamp; import java.util.Vector; import java.util.logging.Level; import javax.swing.table.DefaultTableModel; import org.compiere.minigrid.MiniTable; import org.compiere.util.DB; import org.compiere.util.Env; i...
import java.sql.*; import java.util.*; import java.util.logging.*; import javax.swing.table.*; import org.compiere.minigrid.*; import org.compiere.util.*;
[ "java.sql", "java.util", "javax.swing", "org.compiere.minigrid", "org.compiere.util" ]
java.sql; java.util; javax.swing; org.compiere.minigrid; org.compiere.util;
693,120
protected synchronized void internalStart(int svc) throws ChannelException { try { boolean valid = false; //make sure we don't pass down any flags that are unrelated to the bottom layer svc = svc & Channel.DEFAULT; if (startLevel == Channel.DEFAULT) return; /...
synchronized void function(int svc) throws ChannelException { try { boolean valid = false; svc = svc & Channel.DEFAULT; if (startLevel == Channel.DEFAULT) return; if (svc == 0 ) return; if (svc == (svc & startLevel)) { throw new ChannelException(STR+svc); } if ( Channel.SND_RX_SEQ==(svc & Channel.SND_RX_SEQ) ) { cluste...
/** * Starts up the channel. This can be called multiple times for individual services to start * The svc parameter can be the logical or value of any constants * @param svc int value of <BR> * DEFAULT - will start all services <BR> * MBR_RX_SEQ - starts the membership receiver <BR> * MBR_...
Starts up the channel. This can be called multiple times for individual services to start The svc parameter can be the logical or value of any constants
internalStart
{ "repo_name": "plumer/codana", "path": "tomcat_files/8.0.22/ChannelCoordinator.java", "license": "mit", "size": 12979 }
[ "org.apache.catalina.tribes.Channel", "org.apache.catalina.tribes.ChannelException", "org.apache.catalina.tribes.MembershipService", "org.apache.catalina.tribes.membership.McastService" ]
import org.apache.catalina.tribes.Channel; import org.apache.catalina.tribes.ChannelException; import org.apache.catalina.tribes.MembershipService; import org.apache.catalina.tribes.membership.McastService;
import org.apache.catalina.tribes.*; import org.apache.catalina.tribes.membership.*;
[ "org.apache.catalina" ]
org.apache.catalina;
2,644,944
if (clazz != null) { return Logger.getLogger(clazz.getName()); } return Logger.getGlobal(); } private static Handler consoleHandler = null;
if (clazz != null) { return Logger.getLogger(clazz.getName()); } return Logger.getGlobal(); } private static Handler consoleHandler = null;
/** * Returns a configured logger for the given class. * * @param clazz A client of the logger. * * @return logger configured for the given class. */
Returns a configured logger for the given class
getLogger
{ "repo_name": "Neurpheus/neurpheus-utils", "path": "src/main/java/org/neurpheus/logging/LoggerService.java", "license": "lgpl-3.0", "size": 1985 }
[ "java.util.logging.Handler", "java.util.logging.Logger" ]
import java.util.logging.Handler; import java.util.logging.Logger;
import java.util.logging.*;
[ "java.util" ]
java.util;
610,940
protected void decreaseMatching(UndirectedNode node1, Double value1, UndirectedNode node2, Double value2) { double matchingG = this.matching.get(node1, node2) - Math.min(value1, value2); if (matchingG < 0.0 && Math.abs(matchingG) <= 1.0E-4 || matchingG > 0.0 && matchingG < 1.0E-6) { matchingG = 0.0...
void function(UndirectedNode node1, Double value1, UndirectedNode node2, Double value2) { double matchingG = this.matching.get(node1, node2) - Math.min(value1, value2); if (matchingG < 0.0 && Math.abs(matchingG) <= 1.0E-4 matchingG > 0.0 && matchingG < 1.0E-6) { matchingG = 0.0; } this.matching.put(node1, node2, matchi...
/** * Decreases the matching between the given nodes by the min value. */
Decreases the matching between the given nodes by the min value
decreaseMatching
{ "repo_name": "marcel-stud/DNA", "path": "src/dna/metrics/similarityMeasures/MeasuresUndirectedDoubleWeighted.java", "license": "gpl-3.0", "size": 9203 }
[ "dna.graph.nodes.UndirectedNode" ]
import dna.graph.nodes.UndirectedNode;
import dna.graph.nodes.*;
[ "dna.graph.nodes" ]
dna.graph.nodes;
223,101
public String findUserByToken(String token) throws DataServiceException, NameNotFoundException { QueryByTokenCommand cmd = new QueryByTokenCommand(); cmd.setToken(token); executeCmd(cmd, "UserTokenDao.findUserByToken"); List<Map<String, Object>> result = cmd.getResult(); if...
String function(String token) throws DataServiceException, NameNotFoundException { QueryByTokenCommand cmd = new QueryByTokenCommand(); cmd.setToken(token); executeCmd(cmd, STR); List<Map<String, Object>> result = cmd.getResult(); if (result.isEmpty()) { throw new NameNotFoundException(STR + token + STR); } String uid ...
/** * Searches the user_token association which match with the provided token. * * @param token * @return uid * * @throws DataServiceException * @throws NameNotFoundException */
Searches the user_token association which match with the provided token
findUserByToken
{ "repo_name": "jusabatier/georchestra", "path": "ldapadmin/src/main/java/org/georchestra/ldapadmin/ds/UserTokenDao.java", "license": "gpl-3.0", "size": 4917 }
[ "java.util.List", "java.util.Map", "org.springframework.ldap.NameNotFoundException" ]
import java.util.List; import java.util.Map; import org.springframework.ldap.NameNotFoundException;
import java.util.*; import org.springframework.ldap.*;
[ "java.util", "org.springframework.ldap" ]
java.util; org.springframework.ldap;
2,600,533
EClass getExceptionDeclaration();
EClass getExceptionDeclaration();
/** * Returns the meta object for class '{@link org.xtuml.bp.xtext.masl.masl.structure.ExceptionDeclaration <em>Exception Declaration</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>Exception Declaration</em>'. * @see org.xtuml.bp.xtext.masl.masl.structure.Ex...
Returns the meta object for class '<code>org.xtuml.bp.xtext.masl.masl.structure.ExceptionDeclaration Exception Declaration</code>'.
getExceptionDeclaration
{ "repo_name": "lwriemen/bridgepoint", "path": "src/org.xtuml.bp.xtext.masl.parent/org.xtuml.bp.xtext.masl/emf-gen/org/xtuml/bp/xtext/masl/masl/structure/StructurePackage.java", "license": "apache-2.0", "size": 189771 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,703,176
public Timestamp convertToSqlTimestamp() { return new Timestamp(getTimeInMillis()); } // ---------------------------------------------------------------- ctors from conversions public JDateTime(DateTimeStamp dts) { setDateTimeStamp(dts); } public JDateTime(JulianDateStamp jds) { setJulianDate(jds)...
Timestamp function() { return new Timestamp(getTimeInMillis()); } public JDateTime(DateTimeStamp dts) { setDateTimeStamp(dts); } public JDateTime(JulianDateStamp jds) { setJulianDate(jds); } public JDateTime(double jd) { setJulianDate(new JulianDateStamp(jd)); } public JDateTime(String src) { parse(src); } public JDate...
/** * Converts to <code>Timestamp</code> instance. */
Converts to <code>Timestamp</code> instance
convertToSqlTimestamp
{ "repo_name": "vilmospapp/jodd", "path": "jodd-core/src/main/java/jodd/datetime/JDateTime.java", "license": "bsd-2-clause", "size": 48911 }
[ "java.sql.Timestamp" ]
import java.sql.Timestamp;
import java.sql.*;
[ "java.sql" ]
java.sql;
757,636
public void dropDatabase(String database, Map<String, String> replacer) { m_errorLogging = true; executeSql(database, "drop_db.sql", replacer, false); }
void function(String database, Map<String, String> replacer) { m_errorLogging = true; executeSql(database, STR, replacer, false); }
/** * Calls the drop script for the given database. * * @param database the name of the database * @param replacer the replacements to perform in the drop script */
Calls the drop script for the given database
dropDatabase
{ "repo_name": "ggiudetti/opencms-core", "path": "src-setup/org/opencms/setup/CmsSetupDb.java", "license": "lgpl-2.1", "size": 27006 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,908,560
validateContextSupported(); // get a ref to the actual ID Field RuntimeResourceDefinition resourceDefinition = myFhirContext.getResourceDefinition(theIncomingResource); IBaseResource newGoldenResource = resourceDefinition.newInstance(); myMdmSurvivorshipService.applySurvivorshipRulesToGoldenResource(theInco...
validateContextSupported(); RuntimeResourceDefinition resourceDefinition = myFhirContext.getResourceDefinition(theIncomingResource); IBaseResource newGoldenResource = resourceDefinition.newInstance(); myMdmSurvivorshipService.applySurvivorshipRulesToGoldenResource(theIncomingResource, newGoldenResource, theMdmTransacti...
/** * Creates a copy of the specified resource. This method will carry over resource EID if it exists. If it does not exist, * a randomly generated UUID EID will be created. * @param <T> Supported MDM resource type (e.g. Patient, Practitioner) * @param theIncomingResource The resource that will...
Creates a copy of the specified resource. This method will carry over resource EID if it exists. If it does not exist, a randomly generated UUID EID will be created
createGoldenResourceFromMdmSourceResource
{ "repo_name": "SingingTree/hapi-fhir", "path": "hapi-fhir-server-mdm/src/main/java/ca/uhn/fhir/mdm/util/GoldenResourceHelper.java", "license": "apache-2.0", "size": 13330 }
[ "ca.uhn.fhir.context.BaseRuntimeChildDefinition", "ca.uhn.fhir.context.RuntimeResourceDefinition", "org.hl7.fhir.instance.model.api.IBaseResource" ]
import ca.uhn.fhir.context.BaseRuntimeChildDefinition; import ca.uhn.fhir.context.RuntimeResourceDefinition; import org.hl7.fhir.instance.model.api.IBaseResource;
import ca.uhn.fhir.context.*; import org.hl7.fhir.instance.model.api.*;
[ "ca.uhn.fhir", "org.hl7.fhir" ]
ca.uhn.fhir; org.hl7.fhir;
1,671,410
@Property(SPECIFICATION_VERSION) public String getSpecificationVersion();
@Property(SPECIFICATION_VERSION) String function();
/** * Contains the specification version */
Contains the specification version
getSpecificationVersion
{ "repo_name": "OndraZizka/windup", "path": "rules-java-ee/addon/src/main/java/org/jboss/windup/rules/apps/javaee/model/HibernateMappingFileModel.java", "license": "epl-1.0", "size": 1565 }
[ "com.tinkerpop.frames.Property" ]
import com.tinkerpop.frames.Property;
import com.tinkerpop.frames.*;
[ "com.tinkerpop.frames" ]
com.tinkerpop.frames;
27,688
private Collection<GeneralImageSubDoc> generalImageCollection; public Collection<GeneralImageSubDoc> getGeneralImageCollection(){ return generalImageCollection; }
Collection<GeneralImageSubDoc> generalImageCollection; public Collection<GeneralImageSubDoc> function(){ return generalImageCollection; }
/** * Retreives the value of generalImageCollection attribue * @return generalImageCollection **/
Retreives the value of generalImageCollection attribue
getGeneralImageCollection
{ "repo_name": "NCIP/national-biomedical-image-archive", "path": "software/nbia-dao/src/gov/nih/nci/nbia/textsupport/TrialDataProvenanceDoc.java", "license": "bsd-3-clause", "size": 3840 }
[ "java.util.Collection" ]
import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
1,883,857
public static void assertBlocked(ActionRequestBuilder builder) { assertBlocked(builder, null); }
static void function(ActionRequestBuilder builder) { assertBlocked(builder, null); }
/** * Executes the request and fails if the request has not been blocked. * * @param builder the request builder */
Executes the request and fails if the request has not been blocked
assertBlocked
{ "repo_name": "avikurapati/elasticsearch", "path": "test/framework/src/main/java/org/elasticsearch/test/hamcrest/ElasticsearchAssertions.java", "license": "apache-2.0", "size": 34264 }
[ "org.elasticsearch.action.ActionRequestBuilder" ]
import org.elasticsearch.action.ActionRequestBuilder;
import org.elasticsearch.action.*;
[ "org.elasticsearch.action" ]
org.elasticsearch.action;
554,418
public static boolean letBrowserInline(String type) { if (type == null) return false; String lType = type.toLowerCase(); // text (plain/html) mime types if (lType.startsWith("text/")) return true; // XHTML mime type if (lType.equals("application/xhtml+xml")) return true; // image mime types if ...
static boolean function(String type) { if (type == null) return false; String lType = type.toLowerCase(); if (lType.startsWith("text/")) return true; if (lType.equals(STR)) return true; if (lType.startsWith(STR)) return true; if (lType.equals(STR)) return true; if (lType.equals(STR)) return true; if (lType.equals(STR))...
/** * Is this a mime type that the browser can handle inline, in a browser window? If so, links to this type should be to a _blank, and content-disposition should be inline. If not, links to this type should be to _self, and content-disposition should be * attachment. * * @param type * The mime type t...
Is this a mime type that the browser can handle inline, in a browser window? If so, links to this type should be to a _blank, and content-disposition should be inline. If not, links to this type should be to _self, and content-disposition should be attachment
letBrowserInline
{ "repo_name": "eemirtekin/Sakai-10.6-TR", "path": "kernel/kernel-util/src/main/java/org/sakaiproject/util/Validator.java", "license": "apache-2.0", "size": 28818 }
[ "org.sakaiproject.component.cover.ServerConfigurationService" ]
import org.sakaiproject.component.cover.ServerConfigurationService;
import org.sakaiproject.component.cover.*;
[ "org.sakaiproject.component" ]
org.sakaiproject.component;
1,098,441
public void normalize() { final float l = length(); if (l <= ReactDefaults.MACHINE_EPSILON) { throw new IllegalArgumentException("Cannot normalize the zero quaternion"); } x /= l; y /= l; z /= l; w /= l; }
void function() { final float l = length(); if (l <= ReactDefaults.MACHINE_EPSILON) { throw new IllegalArgumentException(STR); } x /= l; y /= l; z /= l; w /= l; }
/** * Normalizes this quaternion. Doesn't create a new quaternion. */
Normalizes this quaternion. Doesn't create a new quaternion
normalize
{ "repo_name": "flow/react", "path": "src/main/java/com/flowpowered/react/math/Quaternion.java", "license": "mit", "size": 19408 }
[ "com.flowpowered.react.ReactDefaults" ]
import com.flowpowered.react.ReactDefaults;
import com.flowpowered.react.*;
[ "com.flowpowered.react" ]
com.flowpowered.react;
1,750,618
SmFullDecodeScenario.runWith(args, SmCodecBenchmarkState.Jackson::new); }
SmFullDecodeScenario.runWith(args, SmCodecBenchmarkState.Jackson::new); }
/** * Main method. * * @param args - params of main method. */
Main method
main
{ "repo_name": "scalecube/scalecube", "path": "services-benchmarks/src/main/java/io/scalecube/services/benchmarks/transport/codec/jackson/JacksonSmFullDecodeBenchmark.java", "license": "apache-2.0", "size": 472 }
[ "io.scalecube.services.benchmarks.transport.codec.SmCodecBenchmarkState", "io.scalecube.services.benchmarks.transport.codec.SmFullDecodeScenario" ]
import io.scalecube.services.benchmarks.transport.codec.SmCodecBenchmarkState; import io.scalecube.services.benchmarks.transport.codec.SmFullDecodeScenario;
import io.scalecube.services.benchmarks.transport.codec.*;
[ "io.scalecube.services" ]
io.scalecube.services;
702,224
public boolean delSmsFromInbox(MessageModel messageModel) { LogUtil.logInfo(CLASS_TAG, "delSmsFromInbox(): Delete SMS message app inbox"); final long threadId = getThreadId(messageModel); if (threadId >= 0) { Uri smsUri = Util.isKitKatOrHigher() ? ContentUris ...
boolean function(MessageModel messageModel) { LogUtil.logInfo(CLASS_TAG, STR); final long threadId = getThreadId(messageModel); if (threadId >= 0) { Uri smsUri = Util.isKitKatOrHigher() ? ContentUris .withAppendedId(SmsQuery.SMS_CONVERSATION_URI, threadId) : ContentUris.withAppendedId(Uri.parse(SMS_CONTENT_URI), thread...
/** * Delete SMS from the message app inbox * * @param messageModel The message to be deleted * @return true if deleted otherwise false */
Delete SMS from the message app inbox
delSmsFromInbox
{ "repo_name": "ushahidi/SMSSync", "path": "smssync/src/main/java/org/addhen/smssync/smslib/sms/ProcessSms.java", "license": "lgpl-3.0", "size": 11537 }
[ "android.content.ContentUris", "android.net.Uri", "org.addhen.smssync.presentation.model.MessageModel", "org.addhen.smssync.smslib.util.LogUtil", "org.addhen.smssync.smslib.util.Util" ]
import android.content.ContentUris; import android.net.Uri; import org.addhen.smssync.presentation.model.MessageModel; import org.addhen.smssync.smslib.util.LogUtil; import org.addhen.smssync.smslib.util.Util;
import android.content.*; import android.net.*; import org.addhen.smssync.presentation.model.*; import org.addhen.smssync.smslib.util.*;
[ "android.content", "android.net", "org.addhen.smssync" ]
android.content; android.net; org.addhen.smssync;
1,498,003
public void updateUserProfileDetails(Long userProfileId, UserProfileDetails userProfileDetails) throws InstanceNotFoundException;
void function(Long userProfileId, UserProfileDetails userProfileDetails) throws InstanceNotFoundException;
/** * Update user profile details. * * @param userProfileId * the user profile id * @param userProfileDetails * the user profile details * @throws InstanceNotFoundException * the instance not found exception */
Update user profile details
updateUserProfileDetails
{ "repo_name": "iago-suarez/pojo-cinema-app", "path": "src/main/java/es/udc/pojo/model/userservice/UserService.java", "license": "gpl-2.0", "size": 2956 }
[ "es.udc.pojo.modelutil.exceptions.InstanceNotFoundException" ]
import es.udc.pojo.modelutil.exceptions.InstanceNotFoundException;
import es.udc.pojo.modelutil.exceptions.*;
[ "es.udc.pojo" ]
es.udc.pojo;
2,826,848
@SuppressWarnings("checkstyle:ParameterNumber") private void updateTags(List<Tag> newTags, @NotNull Tool tool, SourceCodeRepoInterface sourceCodeRepoInterface, final TagDAO tagDAO, final FileDAO fileDAO, final ToolDAO toolDAO, final FileFormatDAO fileFormatDAO, final EventDAO eventDAO, final User user) ...
@SuppressWarnings(STR) void function(List<Tag> newTags, @NotNull Tool tool, SourceCodeRepoInterface sourceCodeRepoInterface, final TagDAO tagDAO, final FileDAO fileDAO, final ToolDAO toolDAO, final FileFormatDAO fileFormatDAO, final EventDAO eventDAO, final User user) { List<Tag> existingTags = new ArrayList<>(tool.get...
/** * Updates/Adds/Deletes tags for a specific tool * * @param newTags * @param tool * @param tagDAO * @param fileDAO * @param toolDAO */
Updates/Adds/Deletes tags for a specific tool
updateTags
{ "repo_name": "ga4gh/dockstore", "path": "dockstore-webservice/src/main/java/io/dockstore/webservice/helpers/AbstractImageRegistry.java", "license": "apache-2.0", "size": 48357 }
[ "io.dockstore.common.DescriptorLanguage", "io.dockstore.common.Registry", "io.dockstore.webservice.core.Tag", "io.dockstore.webservice.core.Tool", "io.dockstore.webservice.core.ToolMode", "io.dockstore.webservice.core.User", "io.dockstore.webservice.jdbi.EventDAO", "io.dockstore.webservice.jdbi.FileDA...
import io.dockstore.common.DescriptorLanguage; import io.dockstore.common.Registry; import io.dockstore.webservice.core.Tag; import io.dockstore.webservice.core.Tool; import io.dockstore.webservice.core.ToolMode; import io.dockstore.webservice.core.User; import io.dockstore.webservice.jdbi.EventDAO; import io.dockstore...
import io.dockstore.common.*; import io.dockstore.webservice.core.*; import io.dockstore.webservice.jdbi.*; import java.util.*; import javax.validation.constraints.*;
[ "io.dockstore.common", "io.dockstore.webservice", "java.util", "javax.validation" ]
io.dockstore.common; io.dockstore.webservice; java.util; javax.validation;
146,441
public static CouponIborSpreadDefinition from(final CouponIborDefinition couponIbor, final double spread) { ArgumentChecker.notNull(couponIbor, "Ibor coupon"); return new CouponIborSpreadDefinition(couponIbor.getCurrency(), couponIbor.getPaymentDate(), couponIbor.getAccrualStartDate(), couponIbor.getAccrualEn...
static CouponIborSpreadDefinition function(final CouponIborDefinition couponIbor, final double spread) { ArgumentChecker.notNull(couponIbor, STR); return new CouponIborSpreadDefinition(couponIbor.getCurrency(), couponIbor.getPaymentDate(), couponIbor.getAccrualStartDate(), couponIbor.getAccrualEndDate(), couponIbor.get...
/** * Builder from an Ibor coupon and the spread. * @param couponIbor An Ibor coupon. * @param spread The spread. * @return The Ibor coupon with spread. */
Builder from an Ibor coupon and the spread
from
{ "repo_name": "nssales/OG-Platform", "path": "projects/OG-Analytics/src/main/java/com/opengamma/analytics/financial/instrument/payment/CouponIborSpreadDefinition.java", "license": "apache-2.0", "size": 15333 }
[ "com.opengamma.util.ArgumentChecker" ]
import com.opengamma.util.ArgumentChecker;
import com.opengamma.util.*;
[ "com.opengamma.util" ]
com.opengamma.util;
936,921
@Test public void testFirstStart_EnvironmentFileMissing_IsCreated_ProgramExits() throws Exception { // create settings file loadSettings(true); // delete the environment file to simulate a first start environmentFile.delete(); doReturn(Boolean.FALSE).when(notesHelper).isNotesInSystemPath(); doReturn...
void function() throws Exception { loadSettings(true); environmentFile.delete(); doReturn(Boolean.FALSE).when(notesHelper).isNotesInSystemPath(); doReturn(Boolean.TRUE).when(notesHelper).isNotesInClassPath(); log = mock(Log.class); loadSettings(true); verify(log, times(1)).info(UserMessage.get().MSG_ENVIRONMENT_CHANGED...
/** * Verifies that environment file is created if missing. * @throws Exception */
Verifies that environment file is created if missing
testFirstStart_EnvironmentFileMissing_IsCreated_ProgramExits
{ "repo_name": "fjakop/ngcalsync", "path": "src/test/java/de/jakop/ngcalsync/settings/SettingsTest.java", "license": "bsd-2-clause", "size": 14871 }
[ "de.jakop.ngcalsync.i18n.LocalizedUserStrings", "org.apache.commons.logging.Log", "org.mockito.Mockito" ]
import de.jakop.ngcalsync.i18n.LocalizedUserStrings; import org.apache.commons.logging.Log; import org.mockito.Mockito;
import de.jakop.ngcalsync.i18n.*; import org.apache.commons.logging.*; import org.mockito.*;
[ "de.jakop.ngcalsync", "org.apache.commons", "org.mockito" ]
de.jakop.ngcalsync; org.apache.commons; org.mockito;
40,404
@Override protected MenuManager createMenuManager() { MenuManager menuBar = new MenuManager(local.getString("rapWinL49")); MenuManager fileMenu = new MenuManager(local.getString("rapWinL50")); MenuManager windowMenu = new MenuManager(local.getString("rapWinL51")); MenuManager helpMenu = new MenuManager(loca...
MenuManager function() { MenuManager menuBar = new MenuManager(local.getString(STR)); MenuManager fileMenu = new MenuManager(local.getString(STR)); MenuManager windowMenu = new MenuManager(local.getString(STR)); MenuManager helpMenu = new MenuManager(local.getString(STR)); buildFileMenu(fileMenu); menuBar.add(fileMenu)...
/** * Creates the menu items. */
Creates the menu items
createMenuManager
{ "repo_name": "ddugovic/raptor-chess-interface", "path": "raptor/src/raptor/RaptorWindow.java", "license": "bsd-3-clause", "size": 78862 }
[ "org.eclipse.jface.action.MenuManager" ]
import org.eclipse.jface.action.MenuManager;
import org.eclipse.jface.action.*;
[ "org.eclipse.jface" ]
org.eclipse.jface;
772,707
CompletableFuture<T> perform();
CompletableFuture<T> perform();
/** * The operation's implementation. */
The operation's implementation
perform
{ "repo_name": "m133225/HubTurbo", "path": "src/main/java/backend/control/operations/RepoOp.java", "license": "lgpl-3.0", "size": 385 }
[ "java.util.concurrent.CompletableFuture" ]
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
2,305,654
void unregisterWikiComponents(DocumentReference reference) throws WikiComponentException;
void unregisterWikiComponents(DocumentReference reference) throws WikiComponentException;
/** * Unregisters the wiki component(s) associated with the passed reference. * * @param reference the reference to the document holding the component to unregister * @throws WikiComponentException when failed to unregister the component from the CM. */
Unregisters the wiki component(s) associated with the passed reference
unregisterWikiComponents
{ "repo_name": "pbondoer/xwiki-platform", "path": "xwiki-platform-core/xwiki-platform-component/xwiki-platform-component-wiki/src/main/java/org/xwiki/component/wiki/WikiComponentManager.java", "license": "lgpl-2.1", "size": 3001 }
[ "org.xwiki.model.reference.DocumentReference" ]
import org.xwiki.model.reference.DocumentReference;
import org.xwiki.model.reference.*;
[ "org.xwiki.model" ]
org.xwiki.model;
639,641
List<Book> findAll();
List<Book> findAll();
/** * Finds all books in the database * * @return list of all books */
Finds all books in the database
findAll
{ "repo_name": "DavidLuptak/pa165-library-system", "path": "library-system-service/src/main/java/cz/muni/fi/pa165/library/service/BookService.java", "license": "gpl-3.0", "size": 1971 }
[ "cz.muni.fi.pa165.library.entity.Book", "java.util.List" ]
import cz.muni.fi.pa165.library.entity.Book; import java.util.List;
import cz.muni.fi.pa165.library.entity.*; import java.util.*;
[ "cz.muni.fi", "java.util" ]
cz.muni.fi; java.util;
1,710,976
public void setMetadataService(MetadataService metadataService) { this.metadataService = metadataService; }
void function(MetadataService metadataService) { this.metadataService = metadataService; }
/** * Sets metadataService. * @param metadataService the metadataService to set */
Sets metadataService
setMetadataService
{ "repo_name": "imagopole/omero-csv-tools", "path": "src/main/java/org/imagopole/omero/tools/impl/ctrl/DefaultMetadataController.java", "license": "gpl-2.0", "size": 4892 }
[ "org.imagopole.omero.tools.api.logic.MetadataService" ]
import org.imagopole.omero.tools.api.logic.MetadataService;
import org.imagopole.omero.tools.api.logic.*;
[ "org.imagopole.omero" ]
org.imagopole.omero;
1,681,970
public static ims.emergency.configuration.domain.objects.ProblemTriageProtocol extractProblemTriageProtocol(ims.domain.ILightweightDomainFactory domainFactory, ims.emergency.vo.ProblemTriageProtocolVo valueObject) { return extractProblemTriageProtocol(domainFactory, valueObject, new HashMap()); }
static ims.emergency.configuration.domain.objects.ProblemTriageProtocol function(ims.domain.ILightweightDomainFactory domainFactory, ims.emergency.vo.ProblemTriageProtocolVo valueObject) { return extractProblemTriageProtocol(domainFactory, valueObject, new HashMap()); }
/** * Create the domain object from the value object. * @param domainFactory - used to create existing (persistent) domain objects. * @param valueObject - extract the domain object fields from this. */
Create the domain object from the value object
extractProblemTriageProtocol
{ "repo_name": "open-health-hub/openMAXIMS", "path": "openmaxims_workspace/ValueObjects/src/ims/emergency/vo/domain/ProblemTriageProtocolVoAssembler.java", "license": "agpl-3.0", "size": 17201 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
575,523
@Override public List getByDocumentHeaderIdAndLineType(Class clazz, String documentHeaderId, String lineType) { return getAccountingLineDao().findByDocumentHeaderIdAndLineType(clazz, documentHeaderId, lineType); }
List function(Class clazz, String documentHeaderId, String lineType) { return getAccountingLineDao().findByDocumentHeaderIdAndLineType(clazz, documentHeaderId, lineType); }
/** * Calls AccountingLineDao#findByDocumentHeaderIdAndLineType to find the appropriate lines * @see org.kuali.kfs.sys.service.AccountingLineService#getByDocumentHeaderIdAndLineType(java.lang.Class, java.lang.String, java.lang.String) */
Calls AccountingLineDao#findByDocumentHeaderIdAndLineType to find the appropriate lines
getByDocumentHeaderIdAndLineType
{ "repo_name": "bhutchinson/kfs", "path": "kfs-core/src/main/java/org/kuali/kfs/sys/service/impl/AccountingLineServiceImpl.java", "license": "agpl-3.0", "size": 3092 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
249,500
private String amalgamateTextParagraphsAsHtml(final List<String> paragraphs) { StringBuffer result = new StringBuffer("<HTML><HEAD></HEAD><BODY>"); for (String paragraph : paragraphs) { result.append("<p>"); result.append(paragraph); result.append("</p>"); } result.append("</BODY></HTML>"); ...
String function(final List<String> paragraphs) { StringBuffer result = new StringBuffer(STR); for (String paragraph : paragraphs) { result.append("<p>"); result.append(paragraph); result.append("</p>"); } result.append(STR); return result.toString(); }
/** * <p> * Internal utility method to build a HTML representation of the message's * constituent paragraphs. * </p> * * @param paragraphs * The message text specified as a {@link List}, where each * element represents a distinct paragraph. * * @return An amalgamati...
Internal utility method to build a HTML representation of the message's constituent paragraphs.
amalgamateTextParagraphsAsHtml
{ "repo_name": "latency4j/repo", "path": "core/src/main/java/org/latency4j/util/Latency4JEmailSender.java", "license": "gpl-3.0", "size": 22568 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
511,852
EList<String> getAnnotations();
EList<String> getAnnotations();
/** * Returns the value of the '<em><b>Annotations</b></em>' attribute list. * The list contents are of type {@link java.lang.String}. * <!-- begin-user-doc --> * <p> * If the meaning of the '<em>Annotations</em>' attribute list isn't clear, * there really should be more of a description here... * ...
Returns the value of the 'Annotations' attribute list. The list contents are of type <code>java.lang.String</code>. If the meaning of the 'Annotations' attribute list isn't clear, there really should be more of a description here...
getAnnotations
{ "repo_name": "kevoree-modeling/eclipse-plugin", "path": "org.kevoree.modeling.eclipse/src-gen/org/kevoree/modeling/metaModel/classDeclr.java", "license": "gpl-3.0", "size": 1850 }
[ "org.eclipse.emf.common.util.EList" ]
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.common.util.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
504,766
@Deprecated @Override public List<EntityHeader> getEntityHeaderByMd5(String md5) throws SynapseException { ValidateArgument.required(md5, "md5"); String url = ENTITY + "/md5/" + md5; return getPaginatedResults(getRepoEndpoint(), url, EntityHeader.class).getResults(); }
List<EntityHeader> function(String md5) throws SynapseException { ValidateArgument.required(md5, "md5"); String url = ENTITY + "/md5/" + md5; return getPaginatedResults(getRepoEndpoint(), url, EntityHeader.class).getResults(); }
/** * Gets the header information of entities whose file's MD5 matches the * given MD5 checksum. */
Gets the header information of entities whose file's MD5 matches the given MD5 checksum
getEntityHeaderByMd5
{ "repo_name": "Sage-Bionetworks/Synapse-Repository-Services", "path": "client/synapseJavaClient/src/main/java/org/sagebionetworks/client/SynapseClientImpl.java", "license": "apache-2.0", "size": 233910 }
[ "java.util.List", "org.sagebionetworks.client.exceptions.SynapseException", "org.sagebionetworks.repo.model.EntityHeader", "org.sagebionetworks.util.ValidateArgument" ]
import java.util.List; import org.sagebionetworks.client.exceptions.SynapseException; import org.sagebionetworks.repo.model.EntityHeader; import org.sagebionetworks.util.ValidateArgument;
import java.util.*; import org.sagebionetworks.client.exceptions.*; import org.sagebionetworks.repo.model.*; import org.sagebionetworks.util.*;
[ "java.util", "org.sagebionetworks.client", "org.sagebionetworks.repo", "org.sagebionetworks.util" ]
java.util; org.sagebionetworks.client; org.sagebionetworks.repo; org.sagebionetworks.util;
1,295,479
public TemplateNodeBuilder setHeaderDecls(Collection<DeclInfo> declInfos) { List<TemplateParam> params = new ArrayList<>(declInfos.size()); for (DeclInfo declInfo : declInfos) { params.add(forDeclInfo(declInfo)); } this.addParams(params); return this; }
TemplateNodeBuilder function(Collection<DeclInfo> declInfos) { List<TemplateParam> params = new ArrayList<>(declInfos.size()); for (DeclInfo declInfo : declInfos) { params.add(forDeclInfo(declInfo)); } this.addParams(params); return this; }
/** * Sets the template header decls. * @param declInfos DeclInfo objects for the decls found in the template header. * @return This builder. */
Sets the template header decls
setHeaderDecls
{ "repo_name": "oujesky/closure-templates", "path": "java/src/com/google/template/soy/soytree/TemplateNodeBuilder.java", "license": "apache-2.0", "size": 25329 }
[ "com.google.template.soy.soytree.defn.TemplateParam", "java.util.ArrayList", "java.util.Collection", "java.util.List" ]
import com.google.template.soy.soytree.defn.TemplateParam; import java.util.ArrayList; import java.util.Collection; import java.util.List;
import com.google.template.soy.soytree.defn.*; import java.util.*;
[ "com.google.template", "java.util" ]
com.google.template; java.util;
2,472,186
@Test public void testResourceManagerReconciliation() { new JavaTestKit(system){{ new Within(duration("10 seconds")) { @Override protected void run() { ActorGateway jobManager = null; ActorGateway resourceManager = null; ActorGateway forwardingActor = null; try { jobManager = Testing...
void function() { new JavaTestKit(system){{ new Within(duration(STR)) { protected void run() { ActorGateway jobManager = null; ActorGateway resourceManager = null; ActorGateway forwardingActor = null; try { jobManager = TestingUtils.createJobManager( system, TestingUtils.defaultExecutor(), TestingUtils.defaultExecutor(...
/** * Tests whether the resource manager connects and reconciles existing task managers. */
Tests whether the resource manager connects and reconciles existing task managers
testResourceManagerReconciliation
{ "repo_name": "WangTaoTheTonic/flink", "path": "flink-runtime/src/test/java/org/apache/flink/runtime/clusterframework/ResourceManagerITCase.java", "license": "apache-2.0", "size": 7063 }
[ "java.util.Arrays", "org.apache.flink.runtime.clusterframework.types.ResourceID", "org.apache.flink.runtime.instance.ActorGateway", "org.apache.flink.runtime.instance.HardwareDescription", "org.apache.flink.runtime.messages.Acknowledge", "org.apache.flink.runtime.messages.RegistrationMessages", "org.apa...
import java.util.Arrays; import org.apache.flink.runtime.clusterframework.types.ResourceID; import org.apache.flink.runtime.instance.ActorGateway; import org.apache.flink.runtime.instance.HardwareDescription; import org.apache.flink.runtime.messages.Acknowledge; import org.apache.flink.runtime.messages.RegistrationMess...
import java.util.*; import org.apache.flink.runtime.*; import org.apache.flink.runtime.clusterframework.types.*; import org.apache.flink.runtime.instance.*; import org.apache.flink.runtime.messages.*; import org.apache.flink.runtime.taskmanager.*; import org.apache.flink.runtime.testutils.*; import org.junit.*; import ...
[ "java.util", "org.apache.flink", "org.junit", "org.mockito" ]
java.util; org.apache.flink; org.junit; org.mockito;
1,573,302
@Idempotent SnapshottableDirectoryStatus[] getSnapshottableDirListing() throws IOException; /////////////////////////////////////// // System issues and management ///////////////////////////////////////
SnapshottableDirectoryStatus[] getSnapshottableDirListing() throws IOException;
/** * Get listing of all the snapshottable directories. * * @return Information about all the current snapshottable directory * @throws IOException If an I/O error occurred */
Get listing of all the snapshottable directories
getSnapshottableDirListing
{ "repo_name": "legend-hua/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/protocol/ClientProtocol.java", "license": "apache-2.0", "size": 61815 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,345,708
default void limitSearch(Criterion aStopCriterion) { ref().addStopCriterion(aStopCriterion); }
default void limitSearch(Criterion aStopCriterion) { ref().addStopCriterion(aStopCriterion); }
/** * Limit the exploration of the search space with the help of a <code>aStopCriterion</code>. * When the condition depicted in the criterion is met, * the search stops. * * @param aStopCriterion the stop criterion which, when met, stops the search. */
Limit the exploration of the search space with the help of a <code>aStopCriterion</code>. When the condition depicted in the criterion is met, the search stops
limitSearch
{ "repo_name": "chocoteam/choco3", "path": "src/main/java/org/chocosolver/solver/search/loop/monitors/ISearchMonitorFactory.java", "license": "bsd-3-clause", "size": 5104 }
[ "org.chocosolver.util.criteria.Criterion" ]
import org.chocosolver.util.criteria.Criterion;
import org.chocosolver.util.criteria.*;
[ "org.chocosolver.util" ]
org.chocosolver.util;
1,501,573
@Mode(TestMode.LITE) @Test public void MPJwt12ConfigUsingBuilderTests_Header_Cookie_doNotSetCookieName_passTokenAsCookie() throws Exception { resourceServer.reconfigureServerUsingExpandedConfiguration(_testName, "rs_server_Header_Cookie.xml"); // pass the token as a cookie using the default ...
@Mode(TestMode.LITE) void function() throws Exception { resourceServer.reconfigureServerUsingExpandedConfiguration(_testName, STR); genericConfigTest(resourceServer, MPJwt12FatConstants.SIGALG_RS256, MPJwt12FatConstants.COOKIE, MPJwt12FatConstants.TOKEN_TYPE_BEARER, null); }
/** * Tests header set to Cookie. Do not configure the cookie (name). Pass the token as a cookie using the default name of "Bearer". * The request should succeed. * * @throws Exception */
Tests header set to Cookie. Do not configure the cookie (name). Pass the token as a cookie using the default name of "Bearer". The request should succeed
MPJwt12ConfigUsingBuilderTests_Header_Cookie_doNotSetCookieName_passTokenAsCookie
{ "repo_name": "OpenLiberty/open-liberty", "path": "dev/com.ibm.ws.security.mp.jwt.1.2_fat.commonTest/fat/src/com/ibm/ws/security/mp/jwt12/fat/MPJwt12ConfigUsingBuilderTests.java", "license": "epl-1.0", "size": 31020 }
[ "com.ibm.ws.security.fat.common.mp.jwt.MPJwt12FatConstants" ]
import com.ibm.ws.security.fat.common.mp.jwt.MPJwt12FatConstants;
import com.ibm.ws.security.fat.common.mp.jwt.*;
[ "com.ibm.ws" ]
com.ibm.ws;
1,303,491
public ArrayList<String> getMethods(String url) { for (int i = 0; _webResourceCollectionList != null && i < _webResourceCollectionList.size(); i++) { WebResourceCollection resource = _webResourceCollectionList.get(i); if (resource.isMatch(url)) return resource.g...
ArrayList<String> function(String url) { for (int i = 0; _webResourceCollectionList != null && i < _webResourceCollectionList.size(); i++) { WebResourceCollection resource = _webResourceCollectionList.get(i); if (resource.isMatch(url)) return resource.getMethods(); } return null; }
/** * Returns the applicable methods if the URL matches. */
Returns the applicable methods if the URL matches
getMethods
{ "repo_name": "dlitz/resin", "path": "modules/resin/src/com/caucho/server/security/SecurityConstraint.java", "license": "gpl-2.0", "size": 6457 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
2,869,207
protected static Long parseUpperRangeTerm(Object value, boolean include) { if ((value instanceof Long) || (value instanceof Integer) || (value instanceof Short) || (value instanceof Byte)) { long longValue = ((Number) value).longValue(); if ((longValue < 0) || (longVa...
static Long function(Object value, boolean include) { if ((value instanceof Long) (value instanceof Integer) (value instanceof Short) (value instanceof Byte)) { long longValue = ((Number) value).longValue(); if ((longValue < 0) (longValue == 0 && include == false)) return null; longValue = include ? longValue : --longV...
/** * Parses an upper term for a range query * @param value to parse * @param include whether a value should be included * @return parsed value to long considering include parameter * null, if value is less that 0, as value is lower than the minimum allowed value for un...
Parses an upper term for a range query
parseUpperRangeTerm
{ "repo_name": "robin13/elasticsearch", "path": "x-pack/plugin/mapper-unsigned-long/src/main/java/org/elasticsearch/xpack/unsignedlong/UnsignedLongFieldMapper.java", "license": "apache-2.0", "size": 24188 }
[ "java.math.BigDecimal", "org.apache.lucene.util.BytesRef", "org.elasticsearch.common.Explicit", "org.elasticsearch.index.mapper.MappedFieldType" ]
import java.math.BigDecimal; import org.apache.lucene.util.BytesRef; import org.elasticsearch.common.Explicit; import org.elasticsearch.index.mapper.MappedFieldType;
import java.math.*; import org.apache.lucene.util.*; import org.elasticsearch.common.*; import org.elasticsearch.index.mapper.*;
[ "java.math", "org.apache.lucene", "org.elasticsearch.common", "org.elasticsearch.index" ]
java.math; org.apache.lucene; org.elasticsearch.common; org.elasticsearch.index;
1,107,057
@NotNull List<String> getLinkNames();
List<String> getLinkNames();
/** * Returns names of all links of the entity. * * @return {@linkplain List list} of link names * @see #addLink(String, Entity) * @see #addLink(String, EntityId) * @see #getLink(String) * @see #getLinks(String) * @see #getLinks(Collection) * @see #setLink(String, Entity) ...
Returns names of all links of the entity
getLinkNames
{ "repo_name": "JetBrains/xodus", "path": "openAPI/src/main/java/jetbrains/exodus/entitystore/Entity.java", "license": "apache-2.0", "size": 18200 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,182,006
if (this.now != null) { return now; } else { return LocalDateTime.now(); } }
if (this.now != null) { return now; } else { return LocalDateTime.now(); } }
/** * Returns the current date and time. The current date can be overriden by setting the environment variable 'gitanizer.now' to a * valid ISO date time string for testing purposes. */
Returns the current date and time. The current date can be overriden by setting the environment variable 'gitanizer.now' to a valid ISO date time string for testing purposes
now
{ "repo_name": "reflectoring/gitanizer", "path": "src/main/java/org/wickedsource/gitanizer/core/DateProvider.java", "license": "mit", "size": 1360 }
[ "java.time.LocalDateTime" ]
import java.time.LocalDateTime;
import java.time.*;
[ "java.time" ]
java.time;
1,429,410
@Test public void setVarFunc() throws Exception { List<String> text = new ArrayList<String>(); String json = TestUtils.getJsonString("inkfiles/function/setvar-func.ink.json"); Story story = new Story(json); TestUtils.nextAll(story, text); Assert.assertEquals(1, text.size()); Assert.assertEq...
void function() throws Exception { List<String> text = new ArrayList<String>(); String json = TestUtils.getJsonString(STR); Story story = new Story(json); TestUtils.nextAll(story, text); Assert.assertEquals(1, text.size()); Assert.assertEquals(STR, text.get(0)); }
/** * "- be able to set a variable as a command" */
"- be able to set a variable as a command"
setVarFunc
{ "repo_name": "bladecoder/blade-ink", "path": "src/test/java/com/bladecoder/ink/runtime/test/FunctionSpecTest.java", "license": "mit", "size": 4571 }
[ "com.bladecoder.ink.runtime.Story", "java.util.ArrayList", "java.util.List", "org.junit.Assert" ]
import com.bladecoder.ink.runtime.Story; import java.util.ArrayList; import java.util.List; import org.junit.Assert;
import com.bladecoder.ink.runtime.*; import java.util.*; import org.junit.*;
[ "com.bladecoder.ink", "java.util", "org.junit" ]
com.bladecoder.ink; java.util; org.junit;
2,085,716
@Override public boolean onCreateOptionsMenu(Menu menu) { getMenuInflater().inflate(R.menu.main, menu); return true; }
boolean function(Menu menu) { getMenuInflater().inflate(R.menu.main, menu); return true; }
/******************************************************************************************** * Main menu handling *********************************************************************************************/
Main menu handling
onCreateOptionsMenu
{ "repo_name": "sasagajic/picasso", "path": "app/src/main/java/com/wealthpark/picasso/activity/MainActivity.java", "license": "mit", "size": 19220 }
[ "android.view.Menu" ]
import android.view.Menu;
import android.view.*;
[ "android.view" ]
android.view;
120,960
Color getColor();
Color getColor();
/** * Get the color of the object * @return color */
Get the color of the object
getColor
{ "repo_name": "billooms/BowlShape2", "path": "Drawables/src/com/billooms/drawables/Drawable.java", "license": "gpl-3.0", "size": 1494 }
[ "java.awt.Color" ]
import java.awt.Color;
import java.awt.*;
[ "java.awt" ]
java.awt;
814,117
public List<Discussion> getMergeRequestDiscussions(Object projectIdOrPath, Integer mergeRequestIid) throws GitLabApiException { Pager<Discussion> pager = getMergeRequestDiscussionsPager(projectIdOrPath, mergeRequestIid, getDefaultPerPage()); return (pager.all()); }
List<Discussion> function(Object projectIdOrPath, Integer mergeRequestIid) throws GitLabApiException { Pager<Discussion> pager = getMergeRequestDiscussionsPager(projectIdOrPath, mergeRequestIid, getDefaultPerPage()); return (pager.all()); }
/** * Get a list of all discussions for the specified merge request. * * <pre><code>GitLab Endpoint: GET /projects/:id/merge_requests/:merge_request_iid/discussions</code></pre> * * @param projectIdOrPath projectIdOrPath the project in the form of an Integer(ID), String(path), or Project instan...
Get a list of all discussions for the specified merge request. <code><code>GitLab Endpoint: GET /projects/:id/merge_requests/:merge_request_iid/discussions</code></code>
getMergeRequestDiscussions
{ "repo_name": "gmessner/gitlab4j-api", "path": "src/main/java/org/gitlab4j/api/DiscussionsApi.java", "license": "mit", "size": 42208 }
[ "java.util.List", "org.gitlab4j.api.models.Discussion" ]
import java.util.List; import org.gitlab4j.api.models.Discussion;
import java.util.*; import org.gitlab4j.api.models.*;
[ "java.util", "org.gitlab4j.api" ]
java.util; org.gitlab4j.api;
1,261,309
EReference getMethodPattern_Definition();
EReference getMethodPattern_Definition();
/** * Returns the meta object for the containment reference '{@link org.eclipselabs.recommenders.codesearch.rcp.dslQL1.qL1.MethodPattern#getDefinition <em>Definition</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the containment reference '<em>Definition</em>'. * ...
Returns the meta object for the containment reference '<code>org.eclipselabs.recommenders.codesearch.rcp.dslQL1.qL1.MethodPattern#getDefinition Definition</code>'.
getMethodPattern_Definition
{ "repo_name": "tobiasb/CodeFinder", "path": "plugins/org.eclipselabs.recommenders.codesearch.rcp.dslQL1/src-gen/org/eclipselabs/recommenders/codesearch/rcp/dslQL1/qL1/QL1Package.java", "license": "epl-1.0", "size": 37551 }
[ "org.eclipse.emf.ecore.EReference" ]
import org.eclipse.emf.ecore.EReference;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
2,237,935
public void endAttributes() throws XslParseException { if (_name == null) throw error(L.l("xsl:attribute-set needs a 'name' attribute.")); }
void function() throws XslParseException { if (_name == null) throw error(L.l(STR)); }
/** * Ends the attributes. */
Ends the attributes
endAttributes
{ "repo_name": "christianchristensen/resin", "path": "modules/resin/src/com/caucho/xsl/java/XslAttributeSet.java", "license": "gpl-2.0", "size": 3199 }
[ "com.caucho.xsl.XslParseException" ]
import com.caucho.xsl.XslParseException;
import com.caucho.xsl.*;
[ "com.caucho.xsl" ]
com.caucho.xsl;
210,667
private boolean assignInitialVerificationTimes() { int numBlocks = 1; synchronized (this) { numBlocks = Math.max(blockMap.size(), 1); } //First udpates the last verification times from the log file. LogFileHandler.Reader logReader = null; try { if (verificationLog != null) { ...
boolean function() { int numBlocks = 1; synchronized (this) { numBlocks = Math.max(blockMap.size(), 1); } LogFileHandler.Reader logReader = null; try { if (verificationLog != null) { logReader = verificationLog.new Reader(false); } } catch (IOException e) { LOG.warn(STR + StringUtils.stringifyException(e)); } if (verif...
/** returns false if the process was interrupted * because the thread is marked to exit. */
returns false if the process was interrupted because the thread is marked to exit
assignInitialVerificationTimes
{ "repo_name": "gndpig/hadoop", "path": "src/hdfs/org/apache/hadoop/hdfs/server/datanode/DataBlockScanner.java", "license": "apache-2.0", "size": 31211 }
[ "java.io.IOException", "org.apache.hadoop.io.IOUtils", "org.apache.hadoop.util.StringUtils" ]
import java.io.IOException; import org.apache.hadoop.io.IOUtils; import org.apache.hadoop.util.StringUtils;
import java.io.*; import org.apache.hadoop.io.*; import org.apache.hadoop.util.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
1,856,971
void disableCorrelator(KnowledgeBase knowledgeBase, Object correlatorClass);
void disableCorrelator(KnowledgeBase knowledgeBase, Object correlatorClass);
/** * Disables the correlator. * * @param knowledgeBase knowledge base. * @param correlatorClass correlator class. */
Disables the correlator
disableCorrelator
{ "repo_name": "softelnet/sponge", "path": "sponge-api/src/main/java/org/openksavi/sponge/engine/ProcessorManager.java", "license": "apache-2.0", "size": 4590 }
[ "org.openksavi.sponge.kb.KnowledgeBase" ]
import org.openksavi.sponge.kb.KnowledgeBase;
import org.openksavi.sponge.kb.*;
[ "org.openksavi.sponge" ]
org.openksavi.sponge;
322,857
@Test public void testMultiOutstandingChange() throws Exception { zks.getZKDatabase().dataTree.createNode("/foo", new byte[0], Ids.OPEN_ACL_UNSAFE, 0, 0, 0, 0); assertNull(zks.outstandingChangesForPath.get("/foo")); process(Arrays.asList(Op.setData("/foo", new byte[0], -1))); ...
void function() throws Exception { zks.getZKDatabase().dataTree.createNode("/foo", new byte[0], Ids.OPEN_ACL_UNSAFE, 0, 0, 0, 0); assertNull(zks.outstandingChangesForPath.get("/foo")); process(Arrays.asList(Op.setData("/foo", new byte[0], -1))); ChangeRecord cr = zks.outstandingChangesForPath.get("/foo"); assertNotNull...
/** * This test checks that a successful multi will change outstanding record * and failed multi shouldn't change outstanding record. */
This test checks that a successful multi will change outstanding record and failed multi shouldn't change outstanding record
testMultiOutstandingChange
{ "repo_name": "arshadmohammad/zookeeper", "path": "zookeeper-server/src/test/java/org/apache/zookeeper/server/PrepRequestProcessorTest.java", "license": "apache-2.0", "size": 15881 }
[ "java.util.Arrays", "org.apache.zookeeper.Op", "org.apache.zookeeper.ZooDefs", "org.apache.zookeeper.server.ZooKeeperServer", "org.junit.jupiter.api.Assertions" ]
import java.util.Arrays; import org.apache.zookeeper.Op; import org.apache.zookeeper.ZooDefs; import org.apache.zookeeper.server.ZooKeeperServer; import org.junit.jupiter.api.Assertions;
import java.util.*; import org.apache.zookeeper.*; import org.apache.zookeeper.server.*; import org.junit.jupiter.api.*;
[ "java.util", "org.apache.zookeeper", "org.junit.jupiter" ]
java.util; org.apache.zookeeper; org.junit.jupiter;
713,701
public MmsMessage getMessage(String registrationId, String messageId) throws BlueviaException, IOException{ // Check params checkRegistrationId(registrationId); if (Utils.isEmpty(messageId)) throw new BlueviaException("Bad request: Message identifier is either null or empty", BlueviaException.BAD_RE...
MmsMessage function(String registrationId, String messageId) throws BlueviaException, IOException{ checkRegistrationId(registrationId); if (Utils.isEmpty(messageId)) throw new BlueviaException(STR, BlueviaException.BAD_REQUEST_EXCEPTION); String feedUri = "/" + registrationId + RECEIVED_MESSAGES + "/" + messageId; Hash...
/** * Gets the content of a message with a 'messageId' sent to the 'registrationId' * * @param registrationId the registration id (short number) that receives the messages * @param messageId the message id (obtained in getAllMessages function) * @return the MmsMessage the complete MmsMessage (including...
Gets the content of a message with a 'messageId' sent to the 'registrationId'
getMessage
{ "repo_name": "BlueVia/Official-Library-Java", "path": "src/main/java/com/bluevia/messagery/mo/mms/client/BVMoMmsClient.java", "license": "lgpl-3.0", "size": 17545 }
[ "com.bluevia.commons.Entity", "com.bluevia.commons.Utils", "com.bluevia.commons.exception.BlueviaException", "com.bluevia.commons.parser.xml.XmlConstants", "com.bluevia.commons.parser.xml.XmlParser", "com.bluevia.messagery.mo.mms.data.MmsMessage", "com.telefonica.schemas.unica.rest.mms.v1.ReceivedMessag...
import com.bluevia.commons.Entity; import com.bluevia.commons.Utils; import com.bluevia.commons.exception.BlueviaException; import com.bluevia.commons.parser.xml.XmlConstants; import com.bluevia.commons.parser.xml.XmlParser; import com.bluevia.messagery.mo.mms.data.MmsMessage; import com.telefonica.schemas.unica.rest.m...
import com.bluevia.commons.*; import com.bluevia.commons.exception.*; import com.bluevia.commons.parser.xml.*; import com.bluevia.messagery.mo.mms.data.*; import com.telefonica.schemas.unica.rest.mms.v1.*; import java.io.*; import java.util.*;
[ "com.bluevia.commons", "com.bluevia.messagery", "com.telefonica.schemas", "java.io", "java.util" ]
com.bluevia.commons; com.bluevia.messagery; com.telefonica.schemas; java.io; java.util;
1,597,534
@Pure public static Iterator<Boolean> iterator(boolean[] array) { return new NativeBooleanToObjectBooleanIterator(array); }
static Iterator<Boolean> function(boolean[] array) { return new NativeBooleanToObjectBooleanIterator(array); }
/** Replies a sized iterator on the objects. * * @param array are the objects to iterate on. * @return an iterator * @since 4.1 */
Replies a sized iterator on the objects
iterator
{ "repo_name": "gallandarakhneorg/afc", "path": "core/util/src/main/java/org/arakhne/afc/util/ArrayUtil.java", "license": "apache-2.0", "size": 37810 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
2,325,660
public RuleConfiguredTargetBuilder addNativeDeclaredProviders( Iterable<SkylarkClassObject> providers) { for (SkylarkClassObject provider : providers) { addNativeDeclaredProvider(provider); } return this; } /** * Adds a "declared provider" defined in native code to the rule. * Use t...
RuleConfiguredTargetBuilder function( Iterable<SkylarkClassObject> providers) { for (SkylarkClassObject provider : providers) { addNativeDeclaredProvider(provider); } return this; } /** * Adds a STR defined in native code to the rule. * Use this method for declared providers in definitions of native rules. * * Use {@li...
/** * Adds "declared providers" defined in native code to the rule. Use this method for declared * providers in definitions of native rules. * * <p>Use {@link #addSkylarkDeclaredProvider(SkylarkClassObject, Location)} for Skylark rule * implementations. */
Adds "declared providers" defined in native code to the rule. Use this method for declared providers in definitions of native rules. Use <code>#addSkylarkDeclaredProvider(SkylarkClassObject, Location)</code> for Skylark rule implementations
addNativeDeclaredProviders
{ "repo_name": "juhalindfors/bazel-patches", "path": "src/main/java/com/google/devtools/build/lib/analysis/RuleConfiguredTargetBuilder.java", "license": "apache-2.0", "size": 17304 }
[ "com.google.devtools.build.lib.events.Location", "com.google.devtools.build.lib.packages.SkylarkClassObject" ]
import com.google.devtools.build.lib.events.Location; import com.google.devtools.build.lib.packages.SkylarkClassObject;
import com.google.devtools.build.lib.events.*; import com.google.devtools.build.lib.packages.*;
[ "com.google.devtools" ]
com.google.devtools;
1,822,967
public void deleteProduct(Product product);
void function(Product product);
/** * This method is responsible for removing a product from the general catalog. There are some business rules that * will be verified before. * <p /> * <ul> * <li>There should be no provider offering the product.</li> * <li>There is no offer for the product.</li> * <li>There is no t...
This method is responsible for removing a product from the general catalog. There are some business rules that will be verified before. There should be no provider offering the product. There is no offer for the product. There is no transaction made ever for the product.
deleteProduct
{ "repo_name": "afarias/cc5604", "path": "proyectos/price-comparator/src/cl/uchile/dcc/cc5604/proyectos/priceComparator/ProductManager.java", "license": "apache-2.0", "size": 2310 }
[ "cl.uchile.dcc.cc5604.proyectos.priceComparator.domain.Product" ]
import cl.uchile.dcc.cc5604.proyectos.priceComparator.domain.Product;
import cl.uchile.dcc.cc5604.proyectos.*;
[ "cl.uchile.dcc" ]
cl.uchile.dcc;
845,751
public String createPrefixDeclarations(Model model, boolean includeExtraPrefixes) { StringBuffer queryString = new StringBuffer(); String defaultNamespace = JenaUtil.getNsPrefixURI(model, ""); if(defaultNamespace != null) { queryString.append("PREFIX : <" + defaultNamespace + ">\n"); }...
String function(Model model, boolean includeExtraPrefixes) { StringBuffer queryString = new StringBuffer(); String defaultNamespace = JenaUtil.getNsPrefixURI(model, STRPREFIX : <STR>\nSTRPREFIX STR: <STR>\n"); } }); return queryString.toString(); }
/** * Creates SPARQL prefix declarations for a given Model. * @param model the Model to get the prefixes from * @param includeExtraPrefixes true to also include implicit prefixes like afn * @return the prefix declarations */
Creates SPARQL prefix declarations for a given Model
createPrefixDeclarations
{ "repo_name": "TopQuadrant/shacl", "path": "src/main/java/org/topbraid/jenax/util/ARQFactory.java", "license": "apache-2.0", "size": 13117 }
[ "org.apache.jena.rdf.model.Model" ]
import org.apache.jena.rdf.model.Model;
import org.apache.jena.rdf.model.*;
[ "org.apache.jena" ]
org.apache.jena;
401,214
void insertPatients(Stream<Patient> patients) throws SQLException { int counter = 0; try (PreparedStatement preparedStatement = connection .prepareStatement("insert into patient values (?,?,?,?,?,?,?,?,?,?,?)")) { for (Patient patient : (Iterable<Patient>) patients::itera...
void insertPatients(Stream<Patient> patients) throws SQLException { int counter = 0; try (PreparedStatement preparedStatement = connection .prepareStatement(STR)) { for (Patient patient : (Iterable<Patient>) patients::iterator) { Date dateOfBirth; if (patient.getDateOfBirth() == null) { dateOfBirth = null; } else { dat...
/** * Insert a stream of patients to the data base using the given connection. * * @param patients The stream of patients to insert. * @throws SQLException Thrown if there are any JDBC errors. */
Insert a stream of patients to the data base using the given connection
insertPatients
{ "repo_name": "eurekaclinical/protempa", "path": "protempa-test-suite/src/test/java/org/protempa/test/DataInserter.java", "license": "apache-2.0", "size": 16041 }
[ "java.sql.Date", "java.sql.PreparedStatement", "java.sql.SQLException", "java.util.stream.Stream" ]
import java.sql.Date; import java.sql.PreparedStatement; import java.sql.SQLException; import java.util.stream.Stream;
import java.sql.*; import java.util.stream.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
1,977,358
protected Object getUpdateObject(Region r, String key) { BaseValueHolder vhObj = null; Object getObj = null; if (r.containsKey(key)) { // key is here; we want to avoid invoking a cache loader if (r.containsValueForKey(key)) { // safe to do a get without rattling anything getObj = r.get(key); vhObj...
Object function(Region r, String key) { BaseValueHolder vhObj = null; Object getObj = null; if (r.containsKey(key)) { if (r.containsValueForKey(key)) { getObj = r.get(key); vhObj = PdxTest.toValueHolder(getObj); } } else { if (isThinClient && !hasPRCacheLoader) { getObj = r.get(key); vhObj = PdxTest.toValueHolder(getOb...
/** Return an object to be used to update the given key. If the * value for the key is a ValueHolder, then get an alternate * value which is similar to it's previous value (see * ValueHolder.getAlternateValueHolder()). * * @param aRegion The region which possible contains key. * @param key The key to get a n...
Return an object to be used to update the given key. If the value for the key is a ValueHolder, then get an alternate value which is similar to it's previous value (see ValueHolder.getAlternateValueHolder())
getUpdateObject
{ "repo_name": "papicella/snappy-store", "path": "tests/core/src/main/java/parReg/ParRegTest.java", "license": "apache-2.0", "size": 239462 }
[ "com.gemstone.gemfire.cache.EntryNotFoundException", "com.gemstone.gemfire.cache.Region", "com.gemstone.gemfire.pdx.PdxInstance", "com.gemstone.gemfire.pdx.WritablePdxInstance" ]
import com.gemstone.gemfire.cache.EntryNotFoundException; import com.gemstone.gemfire.cache.Region; import com.gemstone.gemfire.pdx.PdxInstance; import com.gemstone.gemfire.pdx.WritablePdxInstance;
import com.gemstone.gemfire.cache.*; import com.gemstone.gemfire.pdx.*;
[ "com.gemstone.gemfire" ]
com.gemstone.gemfire;
2,063,034
@Test public void testMultiDelete() throws IOException { // From the BSON specification. final byte[] helloWorld = new byte[] { 0x16, 0x00, 0x00, 0x00, 0x02, (byte) 'h', (byte) 'e', (byte) 'l', (byte) 'l', (byte) 'o', 0x00, 0x06, 0x00, 0x00, 0x00, (byte) 'w', (byt...
void function() throws IOException { final byte[] helloWorld = new byte[] { 0x16, 0x00, 0x00, 0x00, 0x02, (byte) 'h', (byte) 'e', (byte) 'l', (byte) 'l', (byte) 'o', 0x00, 0x06, 0x00, 0x00, 0x00, (byte) 'w', (byte) 'o', (byte) 'r', (byte) 'l', (byte) 'd', 0x00, 0x00 }; connect(); assertTrue(STR, ourServer.waitForClient...
/** * Test method for {@link TransportConnection#send} . * * @throws IOException * On a failure connecting to the Mock MongoDB server. */
Test method for <code>TransportConnection#send</code>
testMultiDelete
{ "repo_name": "allanbank/mongodb-async-driver", "path": "src/test/java/com/allanbank/mongodb/client/connection/socket/AbstractTransportConnectionTestCases.java", "license": "apache-2.0", "size": 125000 }
[ "com.allanbank.mongodb.bson.builder.BuilderFactory", "com.allanbank.mongodb.bson.builder.DocumentBuilder", "com.allanbank.mongodb.bson.io.EndianUtils", "com.allanbank.mongodb.client.Operation", "com.allanbank.mongodb.client.message.Delete", "java.io.IOException", "java.nio.ByteBuffer", "java.nio.IntBu...
import com.allanbank.mongodb.bson.builder.BuilderFactory; import com.allanbank.mongodb.bson.builder.DocumentBuilder; import com.allanbank.mongodb.bson.io.EndianUtils; import com.allanbank.mongodb.client.Operation; import com.allanbank.mongodb.client.message.Delete; import java.io.IOException; import java.nio.ByteBuffer...
import com.allanbank.mongodb.bson.builder.*; import com.allanbank.mongodb.bson.io.*; import com.allanbank.mongodb.client.*; import com.allanbank.mongodb.client.message.*; import java.io.*; import java.nio.*; import java.util.*; import java.util.concurrent.*; import org.junit.*;
[ "com.allanbank.mongodb", "java.io", "java.nio", "java.util", "org.junit" ]
com.allanbank.mongodb; java.io; java.nio; java.util; org.junit;
2,402,695
void createBatchInstance(BatchInstance batchInstance);
void createBatchInstance(BatchInstance batchInstance);
/** * This method will create a new batch instance. * * @param batchInstance BatchInstance */
This method will create a new batch instance
createBatchInstance
{ "repo_name": "kuzavas/ephesoft", "path": "dcma-data-access/src/main/java/com/ephesoft/dcma/da/dao/BatchInstanceDao.java", "license": "agpl-3.0", "size": 21511 }
[ "com.ephesoft.dcma.da.domain.BatchInstance" ]
import com.ephesoft.dcma.da.domain.BatchInstance;
import com.ephesoft.dcma.da.domain.*;
[ "com.ephesoft.dcma" ]
com.ephesoft.dcma;
2,900,462
protected final void reject(Runnable task) { rejectedExecutionHandler.rejected(task, this); } // ScheduledExecutorService implementation private static final long SCHEDULE_PURGE_INTERVAL = TimeUnit.SECONDS.toNanos(1);
final void function(Runnable task) { rejectedExecutionHandler.rejected(task, this); } private static final long SCHEDULE_PURGE_INTERVAL = TimeUnit.SECONDS.toNanos(1);
/** * Offers the task to the associated {@link RejectedExecutionHandler}. * * @param task to reject. */
Offers the task to the associated <code>RejectedExecutionHandler</code>
reject
{ "repo_name": "bryce-anderson/netty", "path": "common/src/main/java/io/netty/util/concurrent/SingleThreadEventExecutor.java", "license": "apache-2.0", "size": 35214 }
[ "java.util.concurrent.TimeUnit" ]
import java.util.concurrent.TimeUnit;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
406,292
public static Intent createGroupUpdateIntent(Context context, long groupId, String newLabel, long[] rawContactsToAdd, long[] rawContactsToRemove, Class<?> callbackActivity, String callbackAction) { Intent serviceIntent = new Intent(context, ContactSaveService.class); serv...
static Intent function(Context context, long groupId, String newLabel, long[] rawContactsToAdd, long[] rawContactsToRemove, Class<?> callbackActivity, String callbackAction) { Intent serviceIntent = new Intent(context, ContactSaveService.class); serviceIntent.setAction(ContactSaveService.ACTION_UPDATE_GROUP); serviceIn...
/** * Creates an intent that can be sent to this service to rename a group as * well as add and remove members from the group. * * @param context of the application * @param groupId of the group that should be modified * @param newLabel is the updated name of the group (can be null i...
Creates an intent that can be sent to this service to rename a group as well as add and remove members from the group
createGroupUpdateIntent
{ "repo_name": "risingsunm/Contacts_4.0", "path": "src/com/android/contacts/ContactSaveService.java", "license": "gpl-2.0", "size": 53834 }
[ "android.content.Context", "android.content.Intent" ]
import android.content.Context; import android.content.Intent;
import android.content.*;
[ "android.content" ]
android.content;
2,701,484
private void saveFields(StructuredStore.Save save, Object object) throws IOException { for(Field field: object.getClass().getDeclaredFields()) { if(isInstanceField(field)) { try { Object value = field.get(object); save.putField(field.getName()); saveData(save, value); } catch (IllegalArgu...
void function(StructuredStore.Save save, Object object) throws IOException { for(Field field: object.getClass().getDeclaredFields()) { if(isInstanceField(field)) { try { Object value = field.get(object); save.putField(field.getName()); saveData(save, value); } catch (IllegalArgumentException e) { e.printStackTrace(); }...
/** * Save the fields of the current object. * @param save Store to save to. * @param object Object to save. * @throws IOException In case of error. */
Save the fields of the current object
saveFields
{ "repo_name": "hcasse/elfy", "path": "src/elf/store/AutoStructuredSerializer.java", "license": "lgpl-3.0", "size": 6501 }
[ "java.io.IOException", "java.lang.reflect.Field" ]
import java.io.IOException; import java.lang.reflect.Field;
import java.io.*; import java.lang.reflect.*;
[ "java.io", "java.lang" ]
java.io; java.lang;
500,504
void invalidate(String bpid, Block invalidBlks[]) throws IOException;
void invalidate(String bpid, Block invalidBlks[]) throws IOException;
/** * Invalidates the specified blocks * @param bpid Block pool Id * @param invalidBlks - the blocks to be invalidated * @throws IOException */
Invalidates the specified blocks
invalidate
{ "repo_name": "plusplusjiajia/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/FsDatasetSpi.java", "license": "apache-2.0", "size": 22452 }
[ "java.io.IOException", "org.apache.hadoop.hdfs.protocol.Block" ]
import java.io.IOException; import org.apache.hadoop.hdfs.protocol.Block;
import java.io.*; import org.apache.hadoop.hdfs.protocol.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
872,576
public final Property<Tenor> tenor() { return metaBean().tenor().createProperty(this); }
final Property<Tenor> function() { return metaBean().tenor().createProperty(this); }
/** * Gets the the {@code tenor} property. * @return the property, not null */
Gets the the tenor property
tenor
{ "repo_name": "McLeodMoores/starling", "path": "projects/financial/src/main/java/com/opengamma/financial/analytics/ircurve/strips/ZeroCouponInflationNode.java", "license": "apache-2.0", "size": 14989 }
[ "com.opengamma.util.time.Tenor", "org.joda.beans.Property" ]
import com.opengamma.util.time.Tenor; import org.joda.beans.Property;
import com.opengamma.util.time.*; import org.joda.beans.*;
[ "com.opengamma.util", "org.joda.beans" ]
com.opengamma.util; org.joda.beans;
2,117,173
@Nullable default <DSTTYPE> DSTTYPE findFirstChildMapped (@Nonnull final Predicate <? super CHILDTYPE> aFilter, @Nonnull final Function <? super CHILDTYPE, ? extends DSTTYPE> aMapper) { if (hasNoChildren ()) return null; return getChildren ().findFir...
default <DSTTYPE> DSTTYPE findFirstChildMapped (@Nonnull final Predicate <? super CHILDTYPE> aFilter, @Nonnull final Function <? super CHILDTYPE, ? extends DSTTYPE> aMapper) { if (hasNoChildren ()) return null; return getChildren ().findFirstMapped (aFilter, aMapper); }
/** * Find the first direct child that matches the passed predicate. * * @param aFilter * The filter that is applied on each direct child node. May not be * <code>null</code>. * @param aMapper * The mapping function from micro node to the target type. May not be * <co...
Find the first direct child that matches the passed predicate
findFirstChildMapped
{ "repo_name": "phax/ph-commons", "path": "ph-commons/src/main/java/com/helger/commons/hierarchy/IHasChildrenSorted.java", "license": "apache-2.0", "size": 3727 }
[ "java.util.function.Function", "java.util.function.Predicate", "javax.annotation.Nonnull" ]
import java.util.function.Function; import java.util.function.Predicate; import javax.annotation.Nonnull;
import java.util.function.*; import javax.annotation.*;
[ "java.util", "javax.annotation" ]
java.util; javax.annotation;
332,269
XMLResource result = new EsmConfigResourceImpl(uri); result.getDefaultSaveOptions().put(XMLResource.OPTION_EXTENDED_META_DATA, extendedMetaData); result.getDefaultLoadOptions().put(XMLResource.OPTION_EXTENDED_META_DATA, extendedMetaData); result.getDefaultSaveOptions().put(XMLResource.OPTION_SCHEMA_LOCATION, B...
XMLResource result = new EsmConfigResourceImpl(uri); result.getDefaultSaveOptions().put(XMLResource.OPTION_EXTENDED_META_DATA, extendedMetaData); result.getDefaultLoadOptions().put(XMLResource.OPTION_EXTENDED_META_DATA, extendedMetaData); result.getDefaultSaveOptions().put(XMLResource.OPTION_SCHEMA_LOCATION, Boolean.TR...
/** * Creates an instance of the resource. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
Creates an instance of the resource.
createResource
{ "repo_name": "nasa/OpenSPIFe", "path": "gov.nasa.arc.spife.europa.clientside/src/gov/nasa/arc/spife/europa/clientside/esmconfig/util/EsmConfigResourceFactoryImpl.java", "license": "apache-2.0", "size": 3096 }
[ "org.eclipse.emf.ecore.xmi.XMLResource" ]
import org.eclipse.emf.ecore.xmi.XMLResource;
import org.eclipse.emf.ecore.xmi.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,514,200
public String getColumnName(int column) throws SQLException { if (this.useOldAliasBehavior) { return getField(column).getName(); } String name = getField(column).getNameNoAliases(); if (name != null && name.length() == 0) { return getField(column).getName();...
String function(int column) throws SQLException { if (this.useOldAliasBehavior) { return getField(column).getName(); } String name = getField(column).getNameNoAliases(); if (name != null && name.length() == 0) { return getField(column).getName(); } return name; }
/** * What's a column's name? * * @param column * the first column is 1, the second is 2, etc. * * @return the column name * * @throws SQLException * if a databvase access error occurs */
What's a column's name
getColumnName
{ "repo_name": "scopej/mysql-connector-j", "path": "src/com/mysql/jdbc/ResultSetMetaData.java", "license": "gpl-2.0", "size": 24375 }
[ "java.sql.SQLException" ]
import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
32,623
EList<MInternalComponentConnection> getConnections();
EList<MInternalComponentConnection> getConnections();
/** * Returns the list of connections defined among the component instances * that are part of the internal architecture of the component. * @return the list of internal connections. * @see es.uah.aut.srg.micobs.mclev.mclevcmp.mclevcmpPackage#getMComponentSupportedPlatform_Connections() * @model containment="...
Returns the list of connections defined among the component instances that are part of the internal architecture of the component
getConnections
{ "repo_name": "parraman/micobs", "path": "mclev/es.uah.aut.srg.micobs.mclev/src/es/uah/aut/srg/micobs/mclev/mclevcmp/MComponentSupportedPlatform.java", "license": "epl-1.0", "size": 8685 }
[ "org.eclipse.emf.common.util.EList" ]
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.common.util.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,173,970
public int showSaveFileDialog(Collection<FileFilter> fileFilters, FileFilter defaultFilter) { JFileChooser choose = gui.getChooser(); choose.resetChoosableFileFilters(); for (FileFilter ff : fileFilters) { choose.addChoosableFileFilter(ff); } choose.setFileFilter(defaultFilter); choose.setSelectedFi...
int function(Collection<FileFilter> fileFilters, FileFilter defaultFilter) { JFileChooser choose = gui.getChooser(); choose.resetChoosableFileFilters(); for (FileFilter ff : fileFilters) { choose.addChoosableFileFilter(ff); } choose.setFileFilter(defaultFilter); choose.setSelectedFile(new File(STRNo file selectedSTRFil...
/** * A utility method to show a file saving dialog with a selection of file filters and one as the default. * * @param fileFilters The file filters to be used within the file chooser. * @param defaultFilter The file filter to be used as the default within the filechooser. * @return An integer which is one o...
A utility method to show a file saving dialog with a selection of file filters and one as the default
showSaveFileDialog
{ "repo_name": "nicodelpiano/prism", "path": "src/userinterface/GUIPlugin.java", "license": "gpl-2.0", "size": 21100 }
[ "java.io.File", "java.util.Collection", "javax.swing.JFileChooser", "javax.swing.JOptionPane", "javax.swing.filechooser.FileFilter" ]
import java.io.File; import java.util.Collection; import javax.swing.JFileChooser; import javax.swing.JOptionPane; import javax.swing.filechooser.FileFilter;
import java.io.*; import java.util.*; import javax.swing.*; import javax.swing.filechooser.*;
[ "java.io", "java.util", "javax.swing" ]
java.io; java.util; javax.swing;
783,184
public Builder applyToAllUnaryMethods( ApiFunction<UnaryCallSettings.Builder<?, ?>, Void> settingsUpdater) { super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); return this; }
Builder function( ApiFunction<UnaryCallSettings.Builder<?, ?>, Void> settingsUpdater) { super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); return this; }
/** * Applies the given settings updater function to all of the unary API methods in this service. * * <p>Note: This method does not support applying settings to streaming methods. */
Applies the given settings updater function to all of the unary API methods in this service. Note: This method does not support applying settings to streaming methods
applyToAllUnaryMethods
{ "repo_name": "googleads/google-ads-java", "path": "google-ads-stubs-v8/src/main/java/com/google/ads/googleads/v8/services/stub/BiddingDataExclusionServiceStubSettings.java", "license": "apache-2.0", "size": 13317 }
[ "com.google.api.core.ApiFunction", "com.google.api.gax.rpc.UnaryCallSettings" ]
import com.google.api.core.ApiFunction; import com.google.api.gax.rpc.UnaryCallSettings;
import com.google.api.core.*; import com.google.api.gax.rpc.*;
[ "com.google.api" ]
com.google.api;
2,529,973
public final X500Principal getCA() { return this.caPrincipal; } /** * Returns the name of the most-trusted CA in RFC 2253 {@code String}
final X500Principal function() { return this.caPrincipal; } /** * Returns the name of the most-trusted CA in RFC 2253 {@code String}
/** * Returns the name of the most-trusted CA as an X500Principal. * * @return the X.500 distinguished name of the most-trusted CA, or * {@code null} if the trust anchor was not specified as a trusted * public key and name or X500Principal pair * @since 1.5 */
Returns the name of the most-trusted CA as an X500Principal
getCA
{ "repo_name": "mirkosertic/Bytecoder", "path": "classlib/java.base/src/main/resources/META-INF/modules/java.base/classes/java/security/cert/TrustAnchor.java", "license": "apache-2.0", "size": 14664 }
[ "javax.security.auth.x500.X500Principal" ]
import javax.security.auth.x500.X500Principal;
import javax.security.auth.x500.*;
[ "javax.security" ]
javax.security;
1,770,996
public List<String> enabledHostNames() { return this.enabledHostNames; }
List<String> function() { return this.enabledHostNames; }
/** * Get the enabledHostNames property: Enabled hostnames for the app.Hostnames need to be assigned (see HostNames) * AND enabled. Otherwise, the app is not served on those hostnames. * * @return the enabledHostNames value. */
Get the enabledHostNames property: Enabled hostnames for the app.Hostnames need to be assigned (see HostNames) AND enabled. Otherwise, the app is not served on those hostnames
enabledHostNames
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanagerhybrid/azure-resourcemanager-appservice/src/main/java/com/azure/resourcemanager/appservice/fluent/models/SitePropertiesInner.java", "license": "mit", "size": 28448 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,692,045
public void setBasicAuth(String user, String pass, AuthScope scope) { UsernamePasswordCredentials credentials = new UsernamePasswordCredentials(user, pass); this.httpClient.getCredentialsProvider().setCredentials(scope, credentials); }
void function(String user, String pass, AuthScope scope) { UsernamePasswordCredentials credentials = new UsernamePasswordCredentials(user, pass); this.httpClient.getCredentialsProvider().setCredentials(scope, credentials); }
/** * Sets basic authentication for the request. You should pass in your * AuthScope for security. It should be like this * setBasicAuth("username","password", new * AuthScope("host",port,AuthScope.ANY_REALM)) * * @param username * @param password * @param scope * - an AuthScope object *...
Sets basic authentication for the request. You should pass in your AuthScope for security. It should be like this setBasicAuth("username","password", new AuthScope("host",port,AuthScope.ANY_REALM))
setBasicAuth
{ "repo_name": "ice-coffee/WormBook", "path": "app/src/main/java/com/jie/book/work/download/AsyncHttpClient.java", "license": "apache-2.0", "size": 28256 }
[ "org.apache.http.auth.AuthScope", "org.apache.http.auth.UsernamePasswordCredentials" ]
import org.apache.http.auth.AuthScope; import org.apache.http.auth.UsernamePasswordCredentials;
import org.apache.http.auth.*;
[ "org.apache.http" ]
org.apache.http;
2,769,595
public TopDocs search(Query query, int n) throws IOException { return search(query, null, n); }
TopDocs function(Query query, int n) throws IOException { return search(query, null, n); }
/** Finds the top <code>n</code> * hits for <code>query</code>. * * @throws BooleanQuery.TooManyClauses If a query would exceed * {@link BooleanQuery#getMaxClauseCount()} clauses. */
Finds the top <code>n</code> hits for <code>query</code>
search
{ "repo_name": "pengzong1111/solr4", "path": "lucene/core/src/java/org/apache/lucene/search/IndexSearcher.java", "license": "apache-2.0", "size": 37398 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
862,079
public boolean renewToken(String tokenId, String issuerAddress, Policy issuerPolicy, TokenStorage store) throws TrustException { try { QName rstQn = new QName("requestSecurityToken"); ServiceClient client = getServiceClien...
boolean function(String tokenId, String issuerAddress, Policy issuerPolicy, TokenStorage store) throws TrustException { try { QName rstQn = new QName(STR); ServiceClient client = getServiceClient(rstQn, issuerAddress); client.getServiceContext().setProperty(RAMPART_POLICY, issuerPolicy); client.getOptions().setSoapVers...
/** * Renews the token referenced by the token id, updates the token store * @param tokenId * @param issuerAddress * @param issuerPolicy * @param store * @return status * @throws TrustException */
Renews the token referenced by the token id, updates the token store
renewToken
{ "repo_name": "maheshika/wso2-rampart", "path": "modules/rampart-trust/src/main/java/org/apache/rahas/client/STSClient.java", "license": "apache-2.0", "size": 36754 }
[ "javax.xml.namespace.QName", "org.apache.axiom.om.OMElement", "org.apache.axis2.AxisFault", "org.apache.axis2.addressing.AddressingConstants", "org.apache.axis2.client.ServiceClient", "org.apache.neethi.Policy", "org.apache.rahas.RahasConstants", "org.apache.rahas.TokenStorage", "org.apache.rahas.Tr...
import javax.xml.namespace.QName; import org.apache.axiom.om.OMElement; import org.apache.axis2.AxisFault; import org.apache.axis2.addressing.AddressingConstants; import org.apache.axis2.client.ServiceClient; import org.apache.neethi.Policy; import org.apache.rahas.RahasConstants; import org.apache.rahas.TokenStorage; ...
import javax.xml.namespace.*; import org.apache.axiom.om.*; import org.apache.axis2.*; import org.apache.axis2.addressing.*; import org.apache.axis2.client.*; import org.apache.neethi.*; import org.apache.rahas.*;
[ "javax.xml", "org.apache.axiom", "org.apache.axis2", "org.apache.neethi", "org.apache.rahas" ]
javax.xml; org.apache.axiom; org.apache.axis2; org.apache.neethi; org.apache.rahas;
2,174,126
private Action[][] getRelevantHistory(GameHistory history, boolean update) { Action[][] relevantHistory = new Action[2][TournamentManager.HISTORY_LENGTH]; int offset = history.getHistoryLength() - 1; for (int i = 0; i < Math.min(TournamentManager.HISTORY_LENGTH, offset); i++) { ...
Action[][] function(GameHistory history, boolean update) { Action[][] relevantHistory = new Action[2][TournamentManager.HISTORY_LENGTH]; int offset = history.getHistoryLength() - 1; for (int i = 0; i < Math.min(TournamentManager.HISTORY_LENGTH, offset); i++) { if (update) { relevantHistory[0][i] = history.getPlayerActi...
/** * Extracts the relevant sequence of moves from the history for updating or consulting * the model (look-back is limited by the history size of the model). */
Extracts the relevant sequence of moves from the history for updating or consulting the model (look-back is limited by the history size of the model)
getRelevantHistory
{ "repo_name": "dwdyer/ipdframework", "path": "src/java/main/au/edu/uwa/csse/dyerd01/ipd/strategies/LookUpTableOpponentModel.java", "license": "apache-2.0", "size": 11055 }
[ "au.edu.uwa.csse.dyerd01.ipd.framework.Action", "au.edu.uwa.csse.dyerd01.ipd.framework.GameHistory", "au.edu.uwa.csse.dyerd01.ipd.framework.TournamentManager" ]
import au.edu.uwa.csse.dyerd01.ipd.framework.Action; import au.edu.uwa.csse.dyerd01.ipd.framework.GameHistory; import au.edu.uwa.csse.dyerd01.ipd.framework.TournamentManager;
import au.edu.uwa.csse.dyerd01.ipd.framework.*;
[ "au.edu.uwa" ]
au.edu.uwa;
250,607
public ToastBuilder messageTextColor(@ColorInt int messageTextColor) { this.messageTextColor = messageTextColor; return this; }
ToastBuilder function(@ColorInt int messageTextColor) { this.messageTextColor = messageTextColor; return this; }
/** * Set the color to display the message on the Toast. * * @param messageTextColor The color to display the message. * @return This instance. */
Set the color to display the message on the Toast
messageTextColor
{ "repo_name": "andrewlord1990/SnackbarBuilder", "path": "snackbarbuilder/src/main/java/com/github/andrewlord1990/snackbarbuilder/toastbuilder/ToastBuilder.java", "license": "apache-2.0", "size": 6884 }
[ "android.support.annotation.ColorInt" ]
import android.support.annotation.ColorInt;
import android.support.annotation.*;
[ "android.support" ]
android.support;
1,772,220
public final synchronized void unregisterFailedConnectingHandler(DeviceHandler<BluetoothDevice> handler){ failedConnectingHandlers.remove(handler); }
final synchronized void function(DeviceHandler<BluetoothDevice> handler){ failedConnectingHandlers.remove(handler); }
/** * Unregisters a handler from the event "failedConnecting". This handler will no longer be called when connecting to a device failed * @param handler Handler to be unregistered */
Unregisters a handler from the event "failedConnecting". This handler will no longer be called when connecting to a device failed
unregisterFailedConnectingHandler
{ "repo_name": "Silveryard/BaseSystem", "path": "Libraries/System/Java/BaseSystem/src/main/java/de/silveryard/basesystem/driver/bluetooth/BluetoothManager.java", "license": "mit", "size": 7958 }
[ "de.silveryard.basesystem.driver.DeviceHandler" ]
import de.silveryard.basesystem.driver.DeviceHandler;
import de.silveryard.basesystem.driver.*;
[ "de.silveryard.basesystem" ]
de.silveryard.basesystem;
2,288,923
WebSiteOperationStatusResponse swapSlots(String webSpaceName, String webSiteName, String sourceSlotName, String targetSlotName) throws InterruptedException, ExecutionException, ServiceException, IOException;
WebSiteOperationStatusResponse swapSlots(String webSpaceName, String webSiteName, String sourceSlotName, String targetSlotName) throws InterruptedException, ExecutionException, ServiceException, IOException;
/** * You can swap a web site from one slot to another slot. * * @param webSpaceName Required. The name of the web space. * @param webSiteName Required. The name of the web site. * @param sourceSlotName Required. The name of the first web site slot to * swap (source). * @param targetSlotName...
You can swap a web site from one slot to another slot
swapSlots
{ "repo_name": "southworkscom/azure-sdk-for-java", "path": "service-management/azure-svc-mgmt-websites/src/main/java/com/microsoft/windowsazure/management/websites/WebSiteOperations.java", "license": "apache-2.0", "size": 61544 }
[ "com.microsoft.windowsazure.exception.ServiceException", "com.microsoft.windowsazure.management.websites.models.WebSiteOperationStatusResponse", "java.io.IOException", "java.util.concurrent.ExecutionException" ]
import com.microsoft.windowsazure.exception.ServiceException; import com.microsoft.windowsazure.management.websites.models.WebSiteOperationStatusResponse; import java.io.IOException; import java.util.concurrent.ExecutionException;
import com.microsoft.windowsazure.exception.*; import com.microsoft.windowsazure.management.websites.models.*; import java.io.*; import java.util.concurrent.*;
[ "com.microsoft.windowsazure", "java.io", "java.util" ]
com.microsoft.windowsazure; java.io; java.util;
1,223,776
private void startHttpServer() throws Exception { String httpRoot = URLDecoder.decode(new File(getClass().getResource("/").getFile()).getAbsolutePath(), "utf-8"); httpServer = HttpServer.createSimpleServer(httpRoot, "localhost", 9997); NetworkListener listener = httpServer.getListeners().ite...
void function() throws Exception { String httpRoot = URLDecoder.decode(new File(getClass().getResource("/").getFile()).getAbsolutePath(), "utf-8"); httpServer = HttpServer.createSimpleServer(httpRoot, STR, 9997); NetworkListener listener = httpServer.getListeners().iterator().next(); ((StaticHttpHandler) httpServer.get...
/** * Starts the HTTP server. * */
Starts the HTTP server
startHttpServer
{ "repo_name": "sismics/reader", "path": "reader-web-common/src/test/java/com/sismics/reader/rest/BaseJerseyTest.java", "license": "gpl-2.0", "size": 12063 }
[ "java.io.File", "java.net.URLDecoder", "org.glassfish.grizzly.http.server.HttpServer", "org.glassfish.grizzly.http.server.NetworkListener", "org.glassfish.grizzly.http.server.StaticHttpHandler" ]
import java.io.File; import java.net.URLDecoder; import org.glassfish.grizzly.http.server.HttpServer; import org.glassfish.grizzly.http.server.NetworkListener; import org.glassfish.grizzly.http.server.StaticHttpHandler;
import java.io.*; import java.net.*; import org.glassfish.grizzly.http.server.*;
[ "java.io", "java.net", "org.glassfish.grizzly" ]
java.io; java.net; org.glassfish.grizzly;
87,512
public static void cycleByteValue(NBTTagCompound nbt, String tagName, int minValue, int maxValue, boolean reverse) { byte value = nbt.getByte(tagName); if (reverse) { if (--value < minValue) { value = (byte)maxValue; } } ...
static void function(NBTTagCompound nbt, String tagName, int minValue, int maxValue, boolean reverse) { byte value = nbt.getByte(tagName); if (reverse) { if (--value < minValue) { value = (byte)maxValue; } } else { if (++value > maxValue) { value = (byte)minValue; } } nbt.setByte(tagName, value); }
/** * Cycle a byte value in the given NBT. If <b>containerTagName</b> * is not null, then the value is stored inside a compound tag by that name. */
Cycle a byte value in the given NBT. If containerTagName is not null, then the value is stored inside a compound tag by that name
cycleByteValue
{ "repo_name": "maruohon/worldutils", "path": "src/main/java/fi/dy/masa/worldutils/util/NBTUtils.java", "license": "gpl-3.0", "size": 5944 }
[ "net.minecraft.nbt.NBTTagCompound" ]
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.*;
[ "net.minecraft.nbt" ]
net.minecraft.nbt;
2,638,018
public void registerAggregation(AggregationSpec spec) { if (false == transportClient) { aggregationParserRegistry.register(spec.parser, spec.name); } namedWriteables.add(new Entry(AggregationBuilder.class, spec.name.getPreferredName(), spec.builderReader)); for (Map.Entry...
void function(AggregationSpec spec) { if (false == transportClient) { aggregationParserRegistry.register(spec.parser, spec.name); } namedWriteables.add(new Entry(AggregationBuilder.class, spec.name.getPreferredName(), spec.builderReader)); for (Map.Entry<String, Writeable.Reader<? extends InternalAggregation>> t : spec...
/** * Register an aggregation. */
Register an aggregation
registerAggregation
{ "repo_name": "zkidkid/elasticsearch", "path": "core/src/main/java/org/elasticsearch/search/SearchModule.java", "license": "apache-2.0", "size": 60021 }
[ "java.util.Map", "java.util.TreeMap", "org.elasticsearch.common.ParseField", "org.elasticsearch.common.io.stream.NamedWriteableRegistry", "org.elasticsearch.common.io.stream.Writeable", "org.elasticsearch.search.aggregations.AggregationBuilder", "org.elasticsearch.search.aggregations.Aggregator", "org...
import java.util.Map; import java.util.TreeMap; import org.elasticsearch.common.ParseField; import org.elasticsearch.common.io.stream.NamedWriteableRegistry; import org.elasticsearch.common.io.stream.Writeable; import org.elasticsearch.search.aggregations.AggregationBuilder; import org.elasticsearch.search.aggregations...
import java.util.*; import org.elasticsearch.common.*; import org.elasticsearch.common.io.stream.*; import org.elasticsearch.search.aggregations.*;
[ "java.util", "org.elasticsearch.common", "org.elasticsearch.search" ]
java.util; org.elasticsearch.common; org.elasticsearch.search;
1,482,107
@UnstableApi void clearCameraMotionListener(CameraMotionListener listener);
void clearCameraMotionListener(CameraMotionListener listener);
/** * Clears the listener which receives camera motion events if it matches the one passed. Else does * nothing. * * @param listener The listener to clear. */
Clears the listener which receives camera motion events if it matches the one passed. Else does nothing
clearCameraMotionListener
{ "repo_name": "androidx/media", "path": "libraries/exoplayer/src/main/java/androidx/media3/exoplayer/ExoPlayer.java", "license": "apache-2.0", "size": 63472 }
[ "androidx.media3.exoplayer.video.spherical.CameraMotionListener" ]
import androidx.media3.exoplayer.video.spherical.CameraMotionListener;
import androidx.media3.exoplayer.video.spherical.*;
[ "androidx.media3" ]
androidx.media3;
237,519
private void validateFields() { if (!mLoaded) return; boolean enabled = Utility.isServerNameValid(mServerView) && Utility.isPortFieldValid(mPortView); if (enabled && mRequireLoginView.isChecked()) { enabled = !TextUtils.isEmpty(mUsernameView.getText()) ...
void function() { if (!mLoaded) return; boolean enabled = Utility.isServerNameValid(mServerView) && Utility.isPortFieldValid(mPortView); if (enabled && mRequireLoginView.isChecked()) { enabled = !TextUtils.isEmpty(mUsernameView.getText()) && mAuthenticationView.getAuthValid(); } enableNextButton(enabled); }
/** * Preflight the values in the fields and decide if it makes sense to enable the "next" button */
Preflight the values in the fields and decide if it makes sense to enable the "next" button
validateFields
{ "repo_name": "s20121035/rk3288_android5.1_repo", "path": "packages/apps/Email/src/com/android/email/activity/setup/AccountSetupOutgoingFragment.java", "license": "gpl-3.0", "size": 17246 }
[ "android.text.TextUtils", "com.android.emailcommon.utility.Utility" ]
import android.text.TextUtils; import com.android.emailcommon.utility.Utility;
import android.text.*; import com.android.emailcommon.utility.*;
[ "android.text", "com.android.emailcommon" ]
android.text; com.android.emailcommon;
1,024,032
private void showNotification() { Log.d(TAG, "FmRadioService.showNotification"); Intent notificationIntent = new Intent(); notificationIntent.setClassName(getPackageName(), FmRadioActivity.class.getName()); PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext...
void function() { Log.d(TAG, STR); Intent notificationIntent = new Intent(); notificationIntent.setClassName(getPackageName(), FmRadioActivity.class.getName()); PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext(), 0, notificationIntent, 0); Notification notification = new Notification(R.draw...
/** * Show notification */
Show notification
showNotification
{ "repo_name": "darklord4822/android_device_smart_sprint4g", "path": "mtk/FmRadio/src/com/mediatek/fmradio/FmRadioService.java", "license": "gpl-2.0", "size": 105643 }
[ "android.app.Notification", "android.app.PendingIntent", "android.content.Intent", "android.util.Log" ]
import android.app.Notification; import android.app.PendingIntent; import android.content.Intent; import android.util.Log;
import android.app.*; import android.content.*; import android.util.*;
[ "android.app", "android.content", "android.util" ]
android.app; android.content; android.util;
222,011
public ClusterHealthStatus ensureYellow(String... indices) { return ensureColor(ClusterHealthStatus.YELLOW, TimeValue.timeValueSeconds(30), indices); }
ClusterHealthStatus function(String... indices) { return ensureColor(ClusterHealthStatus.YELLOW, TimeValue.timeValueSeconds(30), indices); }
/** * Ensures the cluster has a yellow state via the cluster health API. */
Ensures the cluster has a yellow state via the cluster health API
ensureYellow
{ "repo_name": "shreejay/elasticsearch", "path": "test/framework/src/main/java/org/elasticsearch/test/ESIntegTestCase.java", "license": "apache-2.0", "size": 105253 }
[ "org.elasticsearch.cluster.health.ClusterHealthStatus", "org.elasticsearch.common.unit.TimeValue" ]
import org.elasticsearch.cluster.health.ClusterHealthStatus; import org.elasticsearch.common.unit.TimeValue;
import org.elasticsearch.cluster.health.*; import org.elasticsearch.common.unit.*;
[ "org.elasticsearch.cluster", "org.elasticsearch.common" ]
org.elasticsearch.cluster; org.elasticsearch.common;
396,436
public static void queueActionUponActive(Runnable action) { try { if (currentActivity != null && !currentActivity.isFinishing() && !isActivityPaused && (!(action instanceof PostponableAction) || !isActivityClassIgnored(currentActivity))) { action.run(); } else { synchronized ...
static void function(Runnable action) { try { if (currentActivity != null && !currentActivity.isFinishing() && !isActivityPaused && (!(action instanceof PostponableAction) !isActivityClassIgnored(currentActivity))) { action.run(); } else { synchronized (pendingActions) { pendingActions.add(action); } } } catch (Throwab...
/** * Enqueues a callback to invoke when an activity reaches in the foreground. */
Enqueues a callback to invoke when an activity reaches in the foreground
queueActionUponActive
{ "repo_name": "Leanplum/Leanplum-Android-SDK", "path": "AndroidSDKCore/src/main/java/com/leanplum/LeanplumActivityHelper.java", "license": "apache-2.0", "size": 11479 }
[ "com.leanplum.callbacks.PostponableAction", "com.leanplum.internal.Log" ]
import com.leanplum.callbacks.PostponableAction; import com.leanplum.internal.Log;
import com.leanplum.callbacks.*; import com.leanplum.internal.*;
[ "com.leanplum.callbacks", "com.leanplum.internal" ]
com.leanplum.callbacks; com.leanplum.internal;
709,284
EList<ServiceRequirement> getRequires();
EList<ServiceRequirement> getRequires();
/** * Returns the value of the '<em><b>Requires</b></em>' containment reference list. * The list contents are of type {@link org.eclipselabs.osgitools.OSGiInfrastructure.ServiceRequirement}. * <!-- begin-user-doc --> * <p> * If the meaning of the '<em>Requires</em>' reference list isn't clear, * there reall...
Returns the value of the 'Requires' containment reference list. The list contents are of type <code>org.eclipselabs.osgitools.OSGiInfrastructure.ServiceRequirement</code>. If the meaning of the 'Requires' reference list isn't clear, there really should be more of a description here...
getRequires
{ "repo_name": "glefur/osgitools", "path": "plugins/org.eclipselabs.osgitools/src-gen/org/eclipselabs/osgitools/OSGiInfrastructure/DynamicComponent.java", "license": "epl-1.0", "size": 4961 }
[ "org.eclipse.emf.common.util.EList" ]
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.common.util.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
456,130
public ICellEditorValidator getEditTextValidator() { return new ICellEditorValidator() {
ICellEditorValidator function() { return new ICellEditorValidator() {
/** * Gets the edits the text validator. * * @return the edits the text validator * @generated */
Gets the edits the text validator
getEditTextValidator
{ "repo_name": "albertfdp/petrinet", "path": "src/dk.dtu.se2.geometry.diagram/src/geometry/diagram/edit/parts/LineLabelAppearanceLabelTokEditPart.java", "license": "mit", "size": 19254 }
[ "org.eclipse.jface.viewers.ICellEditorValidator" ]
import org.eclipse.jface.viewers.ICellEditorValidator;
import org.eclipse.jface.viewers.*;
[ "org.eclipse.jface" ]
org.eclipse.jface;
2,873,779