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 String renderNode(TreeNode node);
}
private class TreeFragment extends Fragment
{
private static final long serialVersionUID = 1L;
public TreeFragment(final String id, final TreeNode node, final int level,
final IRenderNodeCallback renderNodeCallback)
{
super(id, "fragment", TreeTable.... | String function(TreeNode node); } class TreeFragment extends Fragment { private static final long serialVersionUID = 1L; public TreeFragment(final String id, final TreeNode node, final int level, final IRenderNodeCallback functionCallback) { super(id, STR, TreeTable.this); add(newIndentation(this, STR, node, level)); a... | /**
* Renders the tree node to text.
*
* @param node
* The tree node to render
* @return the tree node as text
*/ | Renders the tree node to text | renderNode | {
"repo_name": "wicketstuff/wicket1.5-tree",
"path": "src/main/java/org/apache/wicket/extensions/markup/html/tree/table/TreeTable.java",
"license": "apache-2.0",
"size": 11475
} | [
"javax.swing.tree.TreeNode",
"org.apache.wicket.MarkupContainer",
"org.apache.wicket.markup.html.basic.Label",
"org.apache.wicket.markup.html.panel.Fragment",
"org.apache.wicket.model.IModel"
] | import javax.swing.tree.TreeNode; import org.apache.wicket.MarkupContainer; import org.apache.wicket.markup.html.basic.Label; import org.apache.wicket.markup.html.panel.Fragment; import org.apache.wicket.model.IModel; | import javax.swing.tree.*; import org.apache.wicket.*; import org.apache.wicket.markup.html.basic.*; import org.apache.wicket.markup.html.panel.*; import org.apache.wicket.model.*; | [
"javax.swing",
"org.apache.wicket"
] | javax.swing; org.apache.wicket; | 128,804 |
protected void addMonitoringMachinePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_Configuration_monitoringMachine_feature"),
getString("_UI... | void function(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), ArchPackage.Literals.CONFIGURATION__MONITORING_MACHINE, true, false, true, null, null, null)); } | /**
* This adds a property descriptor for the Monitoring Machine feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | This adds a property descriptor for the Monitoring Machine feature. | addMonitoringMachinePropertyDescriptor | {
"repo_name": "FTSRG/viatra-dse-swarm",
"path": "plugins/incqueryd/hu.bme.mit.incqueryd.arch/hu.bme.mit.incqueryd.arch.edit/src/arch/provider/ConfigurationItemProvider.java",
"license": "epl-1.0",
"size": 9456
} | [
"org.eclipse.emf.edit.provider.ComposeableAdapterFactory"
] | import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; | import org.eclipse.emf.edit.provider.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 2,493,639 |
public PluginPropertiesService getPluginPropertiesService() {
return pluginPropertiesService;
}
| PluginPropertiesService function() { return pluginPropertiesService; } | /**
* To get Plugin Properties Service.
* @return the pluginPropertiesService
*/ | To get Plugin Properties Service | getPluginPropertiesService | {
"repo_name": "kuzavas/ephesoft",
"path": "dcma-da/src/main/java/com/ephesoft/dcma/docassembler/DocumentAssembler.java",
"license": "agpl-3.0",
"size": 14159
} | [
"com.ephesoft.dcma.batch.service.PluginPropertiesService"
] | import com.ephesoft.dcma.batch.service.PluginPropertiesService; | import com.ephesoft.dcma.batch.service.*; | [
"com.ephesoft.dcma"
] | com.ephesoft.dcma; | 1,372,116 |
public static Adapter getAdapter(List<Adapter> adapters, Object type)
{
for (int i = 0, size = adapters.size(); i < size; ++i)
{
Adapter adapter = adapters.get(i);
if (adapter.isAdapterForType(type))
{
return adapter;
}
}
return null;
} | static Adapter function(List<Adapter> adapters, Object type) { for (int i = 0, size = adapters.size(); i < size; ++i) { Adapter adapter = adapters.get(i); if (adapter.isAdapterForType(type)) { return adapter; } } return null; } | /**
* Returns the adapter of the specified type.
* @param adapters list of adapters to search.
* @param type the type of adapter.
* @return an adapter from the list or null.
*/ | Returns the adapter of the specified type | getAdapter | {
"repo_name": "LangleyStudios/eclipse-avro",
"path": "test/org.eclipse.emf.ecore/src/org/eclipse/emf/ecore/util/EcoreUtil.java",
"license": "epl-1.0",
"size": 154916
} | [
"java.util.List",
"org.eclipse.emf.common.notify.Adapter"
] | import java.util.List; import org.eclipse.emf.common.notify.Adapter; | import java.util.*; import org.eclipse.emf.common.notify.*; | [
"java.util",
"org.eclipse.emf"
] | java.util; org.eclipse.emf; | 1,167,241 |
private static boolean isInSpecificCodeBlock(DetailAST node, int blockType) {
boolean returnValue = false;
for (DetailAST token = node.getParent(); token != null; token = token.getParent()) {
final int type = token.getType();
if (type == blockType) {
returnVal... | static boolean function(DetailAST node, int blockType) { boolean returnValue = false; for (DetailAST token = node.getParent(); token != null; token = token.getParent()) { final int type = token.getType(); if (type == blockType) { returnValue = true; break; } } return returnValue; } | /**
* Checks whether the scope of a node is restricted to a specific code block.
* @param node node.
* @param blockType block type.
* @return true if the scope of a node is restricted to a specific code block.
*/ | Checks whether the scope of a node is restricted to a specific code block | isInSpecificCodeBlock | {
"repo_name": "AkshitaKukreja30/checkstyle",
"path": "src/main/java/com/puppycrawl/tools/checkstyle/checks/coding/FinalLocalVariableCheck.java",
"license": "lgpl-2.1",
"size": 27259
} | [
"com.puppycrawl.tools.checkstyle.api.DetailAST"
] | import com.puppycrawl.tools.checkstyle.api.DetailAST; | import com.puppycrawl.tools.checkstyle.api.*; | [
"com.puppycrawl.tools"
] | com.puppycrawl.tools; | 463,824 |
public boolean canUpdate() throws InternalException, CloudException; | boolean function() throws InternalException, CloudException; | /**
* Indicates whether or not details on an account can be updated for this
* cloud using an {@link AccountSupport#update(String)} call.
*
* @return true if account details can be updated, false if otherwise
* @throws InternalException
* an error occurred within the Dasein Cl... | Indicates whether or not details on an account can be updated for this cloud using an <code>AccountSupport#update(String)</code> call | canUpdate | {
"repo_name": "greese/dasein-cloud-core",
"path": "src/main/java/org/dasein/cloud/admin/AccountCapabilities.java",
"license": "apache-2.0",
"size": 5424
} | [
"org.dasein.cloud.CloudException",
"org.dasein.cloud.InternalException"
] | import org.dasein.cloud.CloudException; import org.dasein.cloud.InternalException; | import org.dasein.cloud.*; | [
"org.dasein.cloud"
] | org.dasein.cloud; | 2,833,132 |
protected boolean isFatal(int damage) {
if (Misc.isNPC(player) || player.getHealth() - damage < 1) {
return true;
}
return false;
}
| boolean function(int damage) { if (Misc.isNPC(player) player.getHealth() - damage < 1) { return true; } return false; } | /**
* Check to ensure you're not gaining XP after you die.
*
* @param damage The damage to be dealt
* @return true if the damage is fatal, false otherwise
*/ | Check to ensure you're not gaining XP after you die | isFatal | {
"repo_name": "javalangSystemwin/mcMMOPlus",
"path": "src/main/java/com/gmail/nossr50/skills/acrobatics/AcrobaticsEventHandler.java",
"license": "agpl-3.0",
"size": 1679
} | [
"com.gmail.nossr50.util.Misc"
] | import com.gmail.nossr50.util.Misc; | import com.gmail.nossr50.util.*; | [
"com.gmail.nossr50"
] | com.gmail.nossr50; | 1,507,194 |
// ORDERING IS IMPORTANT:
// The resource lifecycle is RESERVE -> CREATE -> DESTROY -> UNRESERVE
// Therefore we *must* put any DESTROY calls before any UNRESERVE calls
List<OfferRecommendation> recommendations = new ArrayList<OfferRecommendation>();
// First, find any unexpected per... | List<OfferRecommendation> recommendations = new ArrayList<OfferRecommendation>(); int offerResourceCount = 0; for (Offer offer : offers) { offerResourceCount += offer.getResourcesCount(); for (Resource toDestroy : selectUnexpectedResources( expectedPersistentVolumeIds, getPersistentVolumesById(offer))) { recommendation... | /**
* Returns a list of operations which should be performed, given the provided list of Offers
* from Mesos. The returned operations MUST be performed in the order in which they are
* provided.
*/ | Returns a list of operations which should be performed, given the provided list of Offers from Mesos. The returned operations MUST be performed in the order in which they are provided | evaluate | {
"repo_name": "comptelfwd/dcos-commons",
"path": "sdk/scheduler/src/main/java/com/mesosphere/sdk/offer/ResourceCleaner.java",
"license": "apache-2.0",
"size": 7323
} | [
"java.util.ArrayList",
"java.util.List",
"org.apache.mesos.Protos"
] | import java.util.ArrayList; import java.util.List; import org.apache.mesos.Protos; | import java.util.*; import org.apache.mesos.*; | [
"java.util",
"org.apache.mesos"
] | java.util; org.apache.mesos; | 1,742,884 |
public static GetRequest getRequest(String index) {
return new GetRequest(index);
} | static GetRequest function(String index) { return new GetRequest(index); } | /**
* Creates a get request to get the JSON source from an index based on a type and id. Note, the
* {@link GetRequest#type(String)} and {@link GetRequest#id(String)} must be set.
*
* @param index The index to get the JSON source from
* @return The get request
* @see org.elasticsearch.clie... | Creates a get request to get the JSON source from an index based on a type and id. Note, the <code>GetRequest#type(String)</code> and <code>GetRequest#id(String)</code> must be set | getRequest | {
"repo_name": "dongaihua/highlight-elasticsearch",
"path": "src/main/java/org/elasticsearch/client/Requests.java",
"license": "apache-2.0",
"size": 19189
} | [
"org.elasticsearch.action.get.GetRequest"
] | import org.elasticsearch.action.get.GetRequest; | import org.elasticsearch.action.get.*; | [
"org.elasticsearch.action"
] | org.elasticsearch.action; | 562,989 |
private Collection<String> getPreferredConnections(ModeledAuthenticatedUser user,
Collection<String> identifiers) {
// Search provided identifiers for any preferred connections
for (String identifier : identifiers) {
// If at least one prefferred connection is found, assume... | Collection<String> function(ModeledAuthenticatedUser user, Collection<String> identifiers) { for (String identifier : identifiers) { if (user.isPreferredConnection(identifier)) return Collections.singletonList(identifier); } return identifiers; } | /**
* Filters the given collection of connection identifiers, returning a new
* collection which contains only those identifiers which are preferred. If
* no connection identifiers within the given collection are preferred, the
* collection is left untouched.
*
* @param user
* The... | Filters the given collection of connection identifiers, returning a new collection which contains only those identifiers which are preferred. If no connection identifiers within the given collection are preferred, the collection is left untouched | getPreferredConnections | {
"repo_name": "softpymesJeffer/incubator-guacamole-client",
"path": "extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/tunnel/AbstractGuacamoleTunnelService.java",
"license": "apache-2.0",
"size": 29723
} | [
"java.util.Collection",
"java.util.Collections",
"org.apache.guacamole.auth.jdbc.user.ModeledAuthenticatedUser"
] | import java.util.Collection; import java.util.Collections; import org.apache.guacamole.auth.jdbc.user.ModeledAuthenticatedUser; | import java.util.*; import org.apache.guacamole.auth.jdbc.user.*; | [
"java.util",
"org.apache.guacamole"
] | java.util; org.apache.guacamole; | 2,898,784 |
private void consumeByteString(List<ByteString> list)
throws ParseException {
final char quote = currentToken.length() > 0
? currentToken.charAt(0)
: '\0';
if (quote != '\"' && quote != '\'') {
throw parseException("Expected string.");
}
if (currentToken.... | void function(List<ByteString> list) throws ParseException { final char quote = currentToken.length() > 0 ? currentToken.charAt(0) : '\0'; if (quote != '\STRExpected string.STRString missing ending quote."); } try { final String escaped = currentToken.substring(1, currentToken.length() - 1); final ByteString result = u... | /**
* Like {@link #consumeByteString()} but adds each token of the string to
* the given list. String literals (whether bytes or text) may come in
* multiple adjacent tokens which are automatically concatenated, like in
* C or Python.
*/ | Like <code>#consumeByteString()</code> but adds each token of the string to the given list. String literals (whether bytes or text) may come in multiple adjacent tokens which are automatically concatenated, like in C or Python | consumeByteString | {
"repo_name": "npuichigo/ttsflow",
"path": "third_party/protobuf/java/core/src/main/java/com/google/protobuf/TextFormat.java",
"license": "apache-2.0",
"size": 71934
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 404,682 |
@SuppressWarnings("unchecked")
public static <E> Set<E> immutableSet(E... elements) {
// TODO(anorth): optimise to a truly immutable set.
return Collections.unmodifiableSet(newHashSet(elements));
} | @SuppressWarnings(STR) static <E> Set<E> function(E... elements) { return Collections.unmodifiableSet(newHashSet(elements)); } | /**
* Creates an immutable set containing the given elements.
*
* @param elements the elements that the set should contain
* @return a newly created set containing those elements.
*/ | Creates an immutable set containing the given elements | immutableSet | {
"repo_name": "vega113/incubator-wave",
"path": "wave/src/main/java/org/waveprotocol/wave/model/util/CollectionUtils.java",
"license": "apache-2.0",
"size": 37875
} | [
"java.util.Collections",
"java.util.Set"
] | import java.util.Collections; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 2,344,270 |
public static SugarCRMOperations createNewModuleItem(Context context, String moduleName,
String accountName, SugarBean sBean,
BatchOperation batchOperation) {
return new SugarCRMOperations(context, moduleName, accountName, batchOperatio... | static SugarCRMOperations function(Context context, String moduleName, String accountName, SugarBean sBean, BatchOperation batchOperation) { return new SugarCRMOperations(context, moduleName, accountName, batchOperation); } | /**
* Returns an instance of SugarCRMOperations instance for adding new module item to the sugar
* crm provider.
*
* @param context
* the Authenticator Activity context
* @param accountName
* the username of the current login
* @return instance of ContactOp... | Returns an instance of SugarCRMOperations instance for adding new module item to the sugar crm provider | createNewModuleItem | {
"repo_name": "Imaginea/pancake-android",
"path": "src/com/imaginea/android/sugarcrm/sync/SugarCRMOperations.java",
"license": "apache-2.0",
"size": 14371
} | [
"android.content.Context",
"com.imaginea.android.sugarcrm.util.SugarBean"
] | import android.content.Context; import com.imaginea.android.sugarcrm.util.SugarBean; | import android.content.*; import com.imaginea.android.sugarcrm.util.*; | [
"android.content",
"com.imaginea.android"
] | android.content; com.imaginea.android; | 2,435,387 |
private MediaDTO toMediaDTO(MediaLocal media) {
MediaDTO dto = new MediaDTO();
dto.setPk(media.getPk().intValue());
dto.setCreatedTime(media.getCreatedTime());
dto.setUpdatedTime(media.getUpdatedTime());
dto.setMediaUsage(media.getMediaUsage());
dto.setMediaStatus(med... | MediaDTO function(MediaLocal media) { MediaDTO dto = new MediaDTO(); dto.setPk(media.getPk().intValue()); dto.setCreatedTime(media.getCreatedTime()); dto.setUpdatedTime(media.getUpdatedTime()); dto.setMediaUsage(media.getMediaUsage()); dto.setMediaStatus(media.getMediaStatus()); dto.setMediaStatusInfo(media.getMediaSta... | /**
* Creates a MediaDTO object for given given MediaLocal object.
*
* @param media A MediaLocal object.
*
* @return The MediaDTO object for given MediaLocal.
*/ | Creates a MediaDTO object for given given MediaLocal object | toMediaDTO | {
"repo_name": "medicayun/medicayundicom",
"path": "dcm4jboss-all/tags/DCM4JBOSS_2_5_3/dcm4jboss-ejb/src/java/org/dcm4chex/archive/ejb/session/MediaComposerBean.java",
"license": "apache-2.0",
"size": 23165
} | [
"javax.ejb.FinderException",
"org.dcm4chex.archive.ejb.interfaces.MediaDTO",
"org.dcm4chex.archive.ejb.interfaces.MediaLocal"
] | import javax.ejb.FinderException; import org.dcm4chex.archive.ejb.interfaces.MediaDTO; import org.dcm4chex.archive.ejb.interfaces.MediaLocal; | import javax.ejb.*; import org.dcm4chex.archive.ejb.interfaces.*; | [
"javax.ejb",
"org.dcm4chex.archive"
] | javax.ejb; org.dcm4chex.archive; | 1,474,159 |
public double computeBoundsInformation( Hop input, LocalVariableMap vars )
{
double ret = Double.MAX_VALUE;
try
{
ret = OptimizerUtils.rEvalSimpleDoubleExpression(input, new HashMap<Long, Double>(), vars);
}
catch(Exception ex)
{
LOG.error("Failed to compute bounds information.", ex);
ret ... | double function( Hop input, LocalVariableMap vars ) { double ret = Double.MAX_VALUE; try { ret = OptimizerUtils.rEvalSimpleDoubleExpression(input, new HashMap<Long, Double>(), vars); } catch(Exception ex) { LOG.error(STR, ex); ret = Double.MAX_VALUE; } return ret; } | /**
* Computes bound information for sequence if possible, otherwise returns
* Double.MAX_VALUE
*
* @param input high-level operator
* @param vars local variable map
* @return bounds information
*/ | Computes bound information for sequence if possible, otherwise returns Double.MAX_VALUE | computeBoundsInformation | {
"repo_name": "akchinSTC/systemml",
"path": "src/main/java/org/apache/sysml/hops/Hop.java",
"license": "apache-2.0",
"size": 63099
} | [
"java.util.HashMap",
"org.apache.sysml.runtime.controlprogram.LocalVariableMap"
] | import java.util.HashMap; import org.apache.sysml.runtime.controlprogram.LocalVariableMap; | import java.util.*; import org.apache.sysml.runtime.controlprogram.*; | [
"java.util",
"org.apache.sysml"
] | java.util; org.apache.sysml; | 221,036 |
private static native long openForAtomicAppend(String path)
throws IOException; | static native long function(String path) throws IOException; | /**
* Opens a file for atomic append. The file is created if it doesn't
* already exist.
*
* @param file the file to open or create
* @return the native HANDLE
*/ | Opens a file for atomic append. The file is created if it doesn't already exist | openForAtomicAppend | {
"repo_name": "axDev-JDK/jdk",
"path": "src/windows/classes/java/lang/ProcessImpl.java",
"license": "gpl-2.0",
"size": 19377
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,354,689 |
private static final synchronized int nextPoolId() {
return ++poolNumberSequence;
}
// static configuration constants
private static final long DEFAULT_KEEPALIVE = 60_000L;
private static final long TIMEOUT_SLOP = 20L;
private static final int DEFAULT_COMMON_MAX_SPARES... | static final synchronized int function() { return ++poolNumberSequence; } private static final long DEFAULT_KEEPALIVE = 60_000L; private static final long TIMEOUT_SLOP = 20L; private static final int DEFAULT_COMMON_MAX_SPARES = 256; private static final int SEED_INCREMENT = 0x9e3779b9; private static final long SP_MASK... | /**
* Returns the next sequence number. We don't expect this to
* ever contend, so use simple builtin sync.
*/ | Returns the next sequence number. We don't expect this to ever contend, so use simple builtin sync | nextPoolId | {
"repo_name": "YouDiSN/OpenJDK-Research",
"path": "jdk9/jdk/src/java.base/share/classes/java/util/concurrent/ForkJoinPool.java",
"license": "gpl-2.0",
"size": 142181
} | [
"java.lang.Thread",
"java.util.function.Predicate"
] | import java.lang.Thread; import java.util.function.Predicate; | import java.lang.*; import java.util.function.*; | [
"java.lang",
"java.util"
] | java.lang; java.util; | 1,889,178 |
public List<Parameter> getParameters() {
List<Parameter> parameters = new Vector<Parameter>();
// loop over cohorts and get parameters
if (getFilter() != null) {
parameters.addAll(getFilter().getParameters());
}
// loop over datasetdefinitions and get the parameters
if (getDataSetDefinitions(... | List<Parameter> function() { List<Parameter> parameters = new Vector<Parameter>(); if (getFilter() != null) { parameters.addAll(getFilter().getParameters()); } if (getDataSetDefinitions() != null) { for (DataSetDefinition dataSetDef : getDataSetDefinitions()) { parameters.addAll(dataSetDef.getParameters()); } } return ... | /**
* Looks through the datasetdefinitions and cohorts to get the rquired parameters TODO
*
* @see org.openmrs.report.Parameterizable#getParameters()
*/ | Looks through the datasetdefinitions and cohorts to get the rquired parameters TODO | getParameters | {
"repo_name": "Winbobob/openmrs-core",
"path": "api/src/main/java/org/openmrs/report/ReportSchema.java",
"license": "mpl-2.0",
"size": 5704
} | [
"java.util.List",
"java.util.Vector"
] | import java.util.List; import java.util.Vector; | import java.util.*; | [
"java.util"
] | java.util; | 2,045,536 |
@Override
public void looseMarshal(OpenWireFormat wireFormat, Object o, DataOutput dataOut) throws IOException {
ConnectionError info = (ConnectionError) o;
super.looseMarshal(wireFormat, o, dataOut);
looseMarshalThrowable(wireFormat, info.getException(), dataOut);
looseMarshalN... | void function(OpenWireFormat wireFormat, Object o, DataOutput dataOut) throws IOException { ConnectionError info = (ConnectionError) o; super.looseMarshal(wireFormat, o, dataOut); looseMarshalThrowable(wireFormat, info.getException(), dataOut); looseMarshalNestedObject(wireFormat, info.getConnectionId(), dataOut); } | /**
* Write the booleans that this object uses to a BooleanStream
*/ | Write the booleans that this object uses to a BooleanStream | looseMarshal | {
"repo_name": "tabish121/OpenWire",
"path": "openwire-legacy/src/main/java/io/openwire/codec/v3/ConnectionErrorMarshaller.java",
"license": "apache-2.0",
"size": 4572
} | [
"io.openwire.codec.OpenWireFormat",
"io.openwire.commands.ConnectionError",
"java.io.DataOutput",
"java.io.IOException"
] | import io.openwire.codec.OpenWireFormat; import io.openwire.commands.ConnectionError; import java.io.DataOutput; import java.io.IOException; | import io.openwire.codec.*; import io.openwire.commands.*; import java.io.*; | [
"io.openwire.codec",
"io.openwire.commands",
"java.io"
] | io.openwire.codec; io.openwire.commands; java.io; | 1,193,491 |
//----------------------------------------------------------------------------
public void setName(String name) {
XNamed xNamed = (XNamed) UnoRuntime.queryInterface(XNamed.class, getXTextContent());
xNamed.setName(name);
}
//-------------------------------------------------------------------------... | void function(String name) { XNamed xNamed = (XNamed) UnoRuntime.queryInterface(XNamed.class, getXTextContent()); xNamed.setName(name); } | /**
* Sets the name of the image.
*
* @param name the name of the image
*
* @author Markus Krüger
* @date 02.11.2009
*/ | Sets the name of the image | setName | {
"repo_name": "LibreOffice/noa-libre",
"path": "src/ag/ion/bion/officelayer/internal/text/TextDocumentImage.java",
"license": "lgpl-2.1",
"size": 6048
} | [
"com.sun.star.container.XNamed",
"com.sun.star.uno.UnoRuntime"
] | import com.sun.star.container.XNamed; import com.sun.star.uno.UnoRuntime; | import com.sun.star.container.*; import com.sun.star.uno.*; | [
"com.sun.star"
] | com.sun.star; | 1,236,317 |
@Override
public javax.persistence.Query createQuery(Call call, Class entityClass) {
try {
verifyOpen();
ReadAllQuery query = new ReadAllQuery(entityClass, call);
return new EJBQueryImpl(query, this);
} catch (RuntimeException e) {
setRollbackOnly(... | javax.persistence.Query function(Call call, Class entityClass) { try { verifyOpen(); ReadAllQuery query = new ReadAllQuery(entityClass, call); return new EJBQueryImpl(query, this); } catch (RuntimeException e) { setRollbackOnly(); throw e; } } | /**
* This method is used to create a query using a EclipseLink Call.
*/ | This method is used to create a query using a EclipseLink Call | createQuery | {
"repo_name": "gameduell/eclipselink.runtime",
"path": "jpa/org.eclipse.persistence.jpa/src/org/eclipse/persistence/internal/jpa/EntityManagerImpl.java",
"license": "epl-1.0",
"size": 135266
} | [
"javax.persistence.Query",
"org.eclipse.persistence.queries.Call",
"org.eclipse.persistence.queries.ReadAllQuery"
] | import javax.persistence.Query; import org.eclipse.persistence.queries.Call; import org.eclipse.persistence.queries.ReadAllQuery; | import javax.persistence.*; import org.eclipse.persistence.queries.*; | [
"javax.persistence",
"org.eclipse.persistence"
] | javax.persistence; org.eclipse.persistence; | 1,338,865 |
public final ImageBuffersReadyFlyweight wrap(final MutableDirectBuffer buffer, final int offset)
{
this.buffer = buffer;
this.offset = offset;
return this;
} | final ImageBuffersReadyFlyweight function(final MutableDirectBuffer buffer, final int offset) { this.buffer = buffer; this.offset = offset; return this; } | /**
* Wrap the buffer at a given offset for updates.
*
* @param buffer to wrap
* @param offset at which the message begins.
* @return for fluent API
*/ | Wrap the buffer at a given offset for updates | wrap | {
"repo_name": "tbrooks8/Aeron",
"path": "aeron-client/src/main/java/io/aeron/command/ImageBuffersReadyFlyweight.java",
"license": "apache-2.0",
"size": 10140
} | [
"org.agrona.MutableDirectBuffer"
] | import org.agrona.MutableDirectBuffer; | import org.agrona.*; | [
"org.agrona"
] | org.agrona; | 2,473,273 |
protected static Value toValue(final String valueString) {
checkNotNull(valueString);
// Split the String that was stored in Fluo into its Value and Type parts.
final String[] valueAndType = valueString.split(TYPE_DELIM);
if(valueAndType.length != 2) {
throw new IllegalA... | static Value function(final String valueString) { checkNotNull(valueString); final String[] valueAndType = valueString.split(TYPE_DELIM); if(valueAndType.length != 2) { throw new IllegalArgumentException(STR); } final String dataString = valueAndType[0]; final String typeString = valueAndType[1]; final URI typeURI = va... | /**
* Creates a {@link Value} from a String representation of it.
*
* @param valueString - The String representation of the value. (not null)
* @return The {@link Value} representation of the String.
*/ | Creates a <code>Value</code> from a String representation of it | toValue | {
"repo_name": "isper3at/incubator-rya",
"path": "extras/rya.indexing.pcj/src/main/java/org/apache/rya/indexing/pcj/storage/accumulo/BindingSetStringConverter.java",
"license": "apache-2.0",
"size": 6224
} | [
"com.google.common.base.Preconditions",
"org.openrdf.model.Value",
"org.openrdf.model.impl.URIImpl",
"org.openrdf.model.vocabulary.XMLSchema"
] | import com.google.common.base.Preconditions; import org.openrdf.model.Value; import org.openrdf.model.impl.URIImpl; import org.openrdf.model.vocabulary.XMLSchema; | import com.google.common.base.*; import org.openrdf.model.*; import org.openrdf.model.impl.*; import org.openrdf.model.vocabulary.*; | [
"com.google.common",
"org.openrdf.model"
] | com.google.common; org.openrdf.model; | 2,060,092 |
@SuppressWarnings("rawtypes")
@Override
public ViewEntry getFirstEntry() {
org.openntf.red.nsf.endpoint.ViewEntry entry = beObject.getFirstEntry();
if (null == entry)
return null;
// TODO Auto-generated method stub
return null;
} | @SuppressWarnings(STR) ViewEntry function() { org.openntf.red.nsf.endpoint.ViewEntry entry = beObject.getFirstEntry(); if (null == entry) return null; return null; } | /**
* Not implemented yet.
*/ | Not implemented yet | getFirstEntry | {
"repo_name": "hyarthi/project-red",
"path": "src/java/org.openntf.red.main/src/org/openntf/red/impl/ViewEntryCollection.java",
"license": "apache-2.0",
"size": 7272
} | [
"org.openntf.red.ViewEntry"
] | import org.openntf.red.ViewEntry; | import org.openntf.red.*; | [
"org.openntf.red"
] | org.openntf.red; | 618,220 |
public void setContent(final LightweightContent content) {
if (content == null) {
System.err.println("JLightweightFrame.setContent: content may not be null!");
return;
}
this.content = content;
this.component = content.getComponent();
Dimension d = th... | void function(final LightweightContent content) { if (content == null) { System.err.println(STR); return; } this.content = content; this.component = content.getComponent(); Dimension d = this.component.getPreferredSize(); content.preferredSizeChanged(d.width, d.height); d = this.component.getMaximumSize(); content.maxi... | /**
* Sets the {@link LightweightContent} instance for this frame.
* The {@code JComponent} object returned by the
* {@link LightweightContent#getComponent()} method is immediately
* added to the frame's content pane.
*
* @param content the {@link LightweightContent} instance
*/ | Sets the <code>LightweightContent</code> instance for this frame. The JComponent object returned by the <code>LightweightContent#getComponent()</code> method is immediately added to the frame's content pane | setContent | {
"repo_name": "FauxFaux/jdk9-jdk",
"path": "src/java.desktop/share/classes/sun/swing/JLightweightFrame.java",
"license": "gpl-2.0",
"size": 17796
} | [
"java.awt.Dimension"
] | import java.awt.Dimension; | import java.awt.*; | [
"java.awt"
] | java.awt; | 1,391,549 |
public final void testGetPrimeQ() {
RSAPrivateCrtKeySpec ks = new RSAPrivateCrtKeySpec(
BigInteger.ONE,
BigInteger.ONE,
BigInteger.ONE,
BigInteger.ONE,
BigInteger.valueOf(5L),
BigInteger.ONE,
BigI... | final void function() { RSAPrivateCrtKeySpec ks = new RSAPrivateCrtKeySpec( BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.ONE, BigInteger.valueOf(5L), BigInteger.ONE, BigInteger.ONE, BigInteger.ONE); assertTrue(BigInteger.valueOf(5L).equals(ks.getPrimeQ())); } | /**
* Test for <code>getPrimeQ()</code> method<br>
* Assertion: returns prime Q
*/ | Test for <code>getPrimeQ()</code> method Assertion: returns prime Q | testGetPrimeQ | {
"repo_name": "AdmireTheDistance/android_libcore",
"path": "luni/src/test/java/tests/security/spec/RSAPrivateCrtKeySpecTest.java",
"license": "gpl-2.0",
"size": 7438
} | [
"java.math.BigInteger",
"java.security.spec.RSAPrivateCrtKeySpec"
] | import java.math.BigInteger; import java.security.spec.RSAPrivateCrtKeySpec; | import java.math.*; import java.security.spec.*; | [
"java.math",
"java.security"
] | java.math; java.security; | 691,001 |
@Override
@Generated(value = "com.sun.tools.xjc.Driver", date = "2014-09-19T03:09:21-06:00", comment = "JAXB RI v2.2.6")
public String toString() {
return ToStringBuilder.reflectionToString(this, JAXBToStringStyle.MULTI_LINE_STYLE);
} | @Generated(value = STR, date = STR, comment = STR) String function() { return ToStringBuilder.reflectionToString(this, JAXBToStringStyle.MULTI_LINE_STYLE); } | /**
* Generates a String representation of the contents of this type.
* This is an extension method, produced by the 'ts' xjc plugin
*
*/ | Generates a String representation of the contents of this type. This is an extension method, produced by the 'ts' xjc plugin | toString | {
"repo_name": "angecab10/travelport-uapi-tutorial",
"path": "src/com/travelport/schema/common_v28_0/ServiceRuleType.java",
"license": "gpl-3.0",
"size": 59237
} | [
"javax.annotation.Generated",
"org.apache.commons.lang.builder.ToStringBuilder",
"org.apache.cxf.xjc.runtime.JAXBToStringStyle"
] | import javax.annotation.Generated; import org.apache.commons.lang.builder.ToStringBuilder; import org.apache.cxf.xjc.runtime.JAXBToStringStyle; | import javax.annotation.*; import org.apache.commons.lang.builder.*; import org.apache.cxf.xjc.runtime.*; | [
"javax.annotation",
"org.apache.commons",
"org.apache.cxf"
] | javax.annotation; org.apache.commons; org.apache.cxf; | 766,209 |
public List<String> getGenericWrapperTypes() {
return this.genericWrapperTypes;
} | List<String> function() { return this.genericWrapperTypes; } | /**
* This gets a list of FQN of types which simply wrap the
* real underlying data type
* @return The type
*/ | This gets a list of FQN of types which simply wrap the real underlying data type | getGenericWrapperTypes | {
"repo_name": "rodney757/swagger-doclet",
"path": "swagger-doclet/src/main/java/com/tenxerconsulting/swagger/doclet/DocletOptions.java",
"license": "apache-2.0",
"size": 59779
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,193,731 |
void endBeanDelete(String path, Object source, Object target) throws ApplicationException, ApplicationExceptions, FrameworkException; | void endBeanDelete(String path, Object source, Object target) throws ApplicationException, ApplicationExceptions, FrameworkException; | /**
* Called after deleting the target bean from the persistent store.
*
* @param path This is the source path of this graph, used when processing a more complex tree, where this is the path to get to this root object being processed.
* @param source the graph object being processed.
* @param... | Called after deleting the target bean from the persistent store | endBeanDelete | {
"repo_name": "jaffa-projects/jaffa-framework",
"path": "jaffa-soa/source/java/org/jaffa/soa/dataaccess/ITransformationHandler.java",
"license": "gpl-3.0",
"size": 20696
} | [
"org.jaffa.exceptions.ApplicationException",
"org.jaffa.exceptions.ApplicationExceptions",
"org.jaffa.exceptions.FrameworkException"
] | import org.jaffa.exceptions.ApplicationException; import org.jaffa.exceptions.ApplicationExceptions; import org.jaffa.exceptions.FrameworkException; | import org.jaffa.exceptions.*; | [
"org.jaffa.exceptions"
] | org.jaffa.exceptions; | 381,719 |
public RealVector unitVector() throws MathArithmeticException {
final double norm = getNorm();
if (norm == 0) {
throw new MathArithmeticException(LocalizedFormats.ZERO_NORM);
}
return mapDivide(norm);
} | RealVector function() throws MathArithmeticException { final double norm = getNorm(); if (norm == 0) { throw new MathArithmeticException(LocalizedFormats.ZERO_NORM); } return mapDivide(norm); } | /**
* Creates a unit vector pointing in the direction of this vector.
* The instance is not changed by this method.
*
* @return a unit vector pointing in direction of this vector.
* @throws MathArithmeticException if the norm is zero.
*/ | Creates a unit vector pointing in the direction of this vector. The instance is not changed by this method | unitVector | {
"repo_name": "najibghadri/NeuralNetworkSimulator",
"path": "src/org/apache/commons/math3/linear/RealVector.java",
"license": "mit",
"size": 54376
} | [
"org.apache.commons.math3.exception.MathArithmeticException",
"org.apache.commons.math3.exception.util.LocalizedFormats"
] | import org.apache.commons.math3.exception.MathArithmeticException; import org.apache.commons.math3.exception.util.LocalizedFormats; | import org.apache.commons.math3.exception.*; import org.apache.commons.math3.exception.util.*; | [
"org.apache.commons"
] | org.apache.commons; | 2,033,828 |
public List getChildren() {
return Collections.EMPTY_LIST;
} | List function() { return Collections.EMPTY_LIST; } | /**
* Always returns an empty list since designators never have children.
*
* @return an empty <code>List</code>
*/ | Always returns an empty list since designators never have children | getChildren | {
"repo_name": "shaundmorris/arbitro",
"path": "modules/arbitro-core/src/main/java/com/connexta/arbitro/attr/AttributeDesignator.java",
"license": "apache-2.0",
"size": 17517
} | [
"java.util.Collections",
"java.util.List"
] | import java.util.Collections; import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,437,216 |
public void setCondition(String condition) {
setProperty(new StringProperty(CONDITION, condition));
} | void function(String condition) { setProperty(new StringProperty(CONDITION, condition)); } | /**
* Condition Accessor - this is gonna be like <code>${count} < 10</code>
* @param condition The condition for this controller
*/ | Condition Accessor - this is gonna be like <code>${count} < 10</code> | setCondition | {
"repo_name": "etnetera/jmeter",
"path": "src/core/src/main/java/org/apache/jmeter/control/IfController.java",
"license": "apache-2.0",
"size": 9242
} | [
"org.apache.jmeter.testelement.property.StringProperty"
] | import org.apache.jmeter.testelement.property.StringProperty; | import org.apache.jmeter.testelement.property.*; | [
"org.apache.jmeter"
] | org.apache.jmeter; | 2,042,660 |
public int[] readIntValues(String dataSetName) throws Exception {
Dataset dataset = metaData.getDataset(dataSetName);
if (dataset == null)
throw new NoSuchElementException("No dataset named '" + dataSetName + "' found!");
dataset.init();
selectAll(dataset);
retur... | int[] function(String dataSetName) throws Exception { Dataset dataset = metaData.getDataset(dataSetName); if (dataset == null) throw new NoSuchElementException(STR + dataSetName + STR); dataset.init(); selectAll(dataset); return (int[]) dataset.read(); } | /**
* Read ALL values of the dataset at once and store them in ONE array. Be careful, this can be very big!
*
* @param dataSetName The dataset name. Must contain int values
* @return A float array containing ALL values in once.
* @throws Exception Something went wrong while reading
*/ | Read ALL values of the dataset at once and store them in ONE array. Be careful, this can be very big | readIntValues | {
"repo_name": "Meldanor/NeonGenesisTool",
"path": "src/main/java/de/meldanor/neongenesis/hdf5/Hdf5Reader.java",
"license": "mit",
"size": 5101
} | [
"java.util.NoSuchElementException"
] | import java.util.NoSuchElementException; | import java.util.*; | [
"java.util"
] | java.util; | 55,150 |
private void prepareCurrentQuery() {
Log.d(TAG, "prepareCurrentQuery");
if (getCurrentQuery() != null) {
if (getCurrentQuery().isPlayable()) {
mKillTimerHandler.removeCallbacksAndMessages(null);
Message msg = mKillTimerHandler.obtainMessage();
... | void function() { Log.d(TAG, STR); if (getCurrentQuery() != null) { if (getCurrentQuery().isPlayable()) { mKillTimerHandler.removeCallbacksAndMessages(null); Message msg = mKillTimerHandler.obtainMessage(); mKillTimerHandler.sendMessageDelayed(msg, DELAY_TO_KILL); if (getCurrentQuery().getImage() == null) { ArrayList<S... | /**
* This method sets the current track and prepares it for playback.
*/ | This method sets the current track and prepares it for playback | prepareCurrentQuery | {
"repo_name": "andi34/tomahawk-android",
"path": "src/org/tomahawk/tomahawk_android/services/PlaybackService.java",
"license": "gpl-3.0",
"size": 58686
} | [
"android.os.Message",
"android.util.Log",
"java.util.ArrayList",
"org.tomahawk.libtomahawk.infosystem.InfoSystem"
] | import android.os.Message; import android.util.Log; import java.util.ArrayList; import org.tomahawk.libtomahawk.infosystem.InfoSystem; | import android.os.*; import android.util.*; import java.util.*; import org.tomahawk.libtomahawk.infosystem.*; | [
"android.os",
"android.util",
"java.util",
"org.tomahawk.libtomahawk"
] | android.os; android.util; java.util; org.tomahawk.libtomahawk; | 804,827 |
if (candidates == null) {
candidates = itemDAO.getItemIds();
}
if (exclude == null) {
exclude = getDefaultExcludes(items);
}
if (!exclude.isEmpty()) {
candidates = LongUtils.setDifference(candidates, exclude);
}
SparseVector scores = s... | if (candidates == null) { candidates = itemDAO.getItemIds(); } if (exclude == null) { exclude = getDefaultExcludes(items); } if (!exclude.isEmpty()) { candidates = LongUtils.setDifference(candidates, exclude); } SparseVector scores = scorer.globalScore(items, candidates); return recommend(n, scores); } | /**
* Implement the ID-based recommendation in terms of the scorer. This method
* uses {@link #getDefaultExcludes(LongSet)} to supply a missing exclude set.
*/ | Implement the ID-based recommendation in terms of the scorer. This method uses <code>#getDefaultExcludes(LongSet)</code> to supply a missing exclude set | globalRecommend | {
"repo_name": "amaliujia/lenskit",
"path": "lenskit-core/src/main/java/org/grouplens/lenskit/basic/TopNGlobalItemRecommender.java",
"license": "lgpl-2.1",
"size": 3855
} | [
"org.grouplens.lenskit.vectors.SparseVector",
"org.lenskit.util.collections.LongUtils"
] | import org.grouplens.lenskit.vectors.SparseVector; import org.lenskit.util.collections.LongUtils; | import org.grouplens.lenskit.vectors.*; import org.lenskit.util.collections.*; | [
"org.grouplens.lenskit",
"org.lenskit.util"
] | org.grouplens.lenskit; org.lenskit.util; | 2,097,978 |
private void assertEval(String expression, double result) throws Exception {
assertThat(eval(expression).floatValue()).isEqualTo(result);
} | void function(String expression, double result) throws Exception { assertThat(eval(expression).floatValue()).isEqualTo(result); } | /**
* Asserts that the given expression evaluates to the given result.
* @param expression The expression to evaluate.
* @param result The expected result.
* @throws Exception If the assertion is not true or if there's an error.
*/ | Asserts that the given expression evaluates to the given result | assertEval | {
"repo_name": "iacdingping/closure-templates",
"path": "java/tests/com/google/template/soy/sharedpasses/render/EvalVisitorTest.java",
"license": "apache-2.0",
"size": 19630
} | [
"com.google.common.truth.Truth"
] | import com.google.common.truth.Truth; | import com.google.common.truth.*; | [
"com.google.common"
] | com.google.common; | 741,301 |
public void getMultipleImagesFromStorage(final String fileid, final boolean callOnFailure) {
final Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("image/*");
intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true);
startIntent(Intent.createChooser(intent, "Select Mu... | void function(final String fileid, final boolean callOnFailure) { final Intent intent = new Intent(Intent.ACTION_GET_CONTENT); intent.setType(STR); intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, true); startIntent(Intent.createChooser(intent, STR), new IntentContextData(REQUEST_CODE_STORAGE_SELECT_MULTI, fileid, null, ca... | /**
* lets the user select MULTIPLE images from his/her device (calling necessary intents and such).
* It will create local image copies for all selected images in c:geo private storage for further processing.
* This function wil only work if you call {@link #onActivityResult(int, int, Intent)} in
*... | lets the user select MULTIPLE images from his/her device (calling necessary intents and such). It will create local image copies for all selected images in c:geo private storage for further processing. This function wil only work if you call <code>#onActivityResult(int, int, Intent)</code> in your activity as explained... | getMultipleImagesFromStorage | {
"repo_name": "tobiasge/cgeo",
"path": "main/src/cgeo/geocaching/ui/ImageActivityHelper.java",
"license": "apache-2.0",
"size": 14420
} | [
"android.content.Intent"
] | import android.content.Intent; | import android.content.*; | [
"android.content"
] | android.content; | 792,859 |
protected String getPDPSelcectionProperty() throws PropertyAccessException
{
return PropertyAccessor.getInstance().getProperty(PROPERTY_FILE_NAME_GATEWAY, PROPERTY_FILE_KEY_PDP_ENTITY);
}
| String function() throws PropertyAccessException { return PropertyAccessor.getInstance().getProperty(PROPERTY_FILE_NAME_GATEWAY, PROPERTY_FILE_KEY_PDP_ENTITY); } | /**
*
* Retrieve the PDP selection property from a properties file.
*
*
*
* @return PDP selection property
*
* @throws PropertyAccessException
*/ | Retrieve the PDP selection property from a properties file | getPDPSelcectionProperty | {
"repo_name": "alameluchidambaram/CONNECT",
"path": "Product/Production/Common/CONNECTCoreLib/src/main/java/gov/hhs/fha/nhinc/policyengine/adapter/pdp/proxy/AdapterPDPProxyOpenSSOClientImpl.java",
"license": "bsd-3-clause",
"size": 5169
} | [
"gov.hhs.fha.nhinc.properties.PropertyAccessException",
"gov.hhs.fha.nhinc.properties.PropertyAccessor"
] | import gov.hhs.fha.nhinc.properties.PropertyAccessException; import gov.hhs.fha.nhinc.properties.PropertyAccessor; | import gov.hhs.fha.nhinc.properties.*; | [
"gov.hhs.fha"
] | gov.hhs.fha; | 777,150 |
public IEntityLock newWriteLock(Class entityType, String entityKey, String owner)
throws LockingException
{
return lockService.newLock(entityType, entityKey, IEntityLockService.WRITE_LOCK, owner);
} | IEntityLock function(Class entityType, String entityKey, String owner) throws LockingException { return lockService.newLock(entityType, entityKey, IEntityLockService.WRITE_LOCK, owner); } | /**
* Returns a write lock for the entity type, entity key and owner.
* @return org.jasig.portal.concurrency.locking.IEntityLock
* @param entityType Class
* @param entityKey String
* @param owner String
* @exception LockingException
*/ | Returns a write lock for the entity type, entity key and owner | newWriteLock | {
"repo_name": "drewwills/uPortal",
"path": "uportal-war/src/main/java/org/jasig/portal/services/EntityLockService.java",
"license": "apache-2.0",
"size": 8456
} | [
"org.jasig.portal.concurrency.IEntityLock",
"org.jasig.portal.concurrency.IEntityLockService",
"org.jasig.portal.concurrency.LockingException"
] | import org.jasig.portal.concurrency.IEntityLock; import org.jasig.portal.concurrency.IEntityLockService; import org.jasig.portal.concurrency.LockingException; | import org.jasig.portal.concurrency.*; | [
"org.jasig.portal"
] | org.jasig.portal; | 929,688 |
@BeanTagAttribute(name = "renderViewBreadcrumb")
public boolean isRenderViewBreadcrumb() {
return renderViewBreadcrumb;
}
| @BeanTagAttribute(name = STR) boolean function() { return renderViewBreadcrumb; } | /**
* Whether or not to render the view breadcrumb at this level
*
* @return true if rendering the view breadcrumb, false otherwise
*/ | Whether or not to render the view breadcrumb at this level | isRenderViewBreadcrumb | {
"repo_name": "geothomasp/kualico-rice-kc",
"path": "rice-framework/krad-web-framework/src/main/java/org/kuali/rice/krad/uif/element/PageBreadcrumbOptions.java",
"license": "apache-2.0",
"size": 7426
} | [
"org.kuali.rice.krad.datadictionary.parse.BeanTagAttribute"
] | import org.kuali.rice.krad.datadictionary.parse.BeanTagAttribute; | import org.kuali.rice.krad.datadictionary.parse.*; | [
"org.kuali.rice"
] | org.kuali.rice; | 1,195,148 |
public ProvidersClient getProviders() {
return this.providers;
}
private final RecommendationsClient recommendations; | ProvidersClient function() { return this.providers; } private final RecommendationsClient recommendations; | /**
* Gets the ProvidersClient object to access its operations.
*
* @return the ProvidersClient object.
*/ | Gets the ProvidersClient object to access its operations | getProviders | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-appservice/src/main/java/com/azure/resourcemanager/appservice/implementation/WebSiteManagementClientImpl.java",
"license": "mit",
"size": 15159
} | [
"com.azure.resourcemanager.appservice.fluent.ProvidersClient",
"com.azure.resourcemanager.appservice.fluent.RecommendationsClient"
] | import com.azure.resourcemanager.appservice.fluent.ProvidersClient; import com.azure.resourcemanager.appservice.fluent.RecommendationsClient; | import com.azure.resourcemanager.appservice.fluent.*; | [
"com.azure.resourcemanager"
] | com.azure.resourcemanager; | 697,706 |
public List<CategoryAnswer> findAnswers(Question question); | List<CategoryAnswer> function(Question question); | /**
* Get the answers for a {@link Question}.
* @param question
* @return empty list if not found
*/ | Get the answers for a <code>Question</code> | findAnswers | {
"repo_name": "apruden/onyx",
"path": "onyx-modules/quartz/quartz-core/src/main/java/org/obiba/onyx/quartz/core/service/ActiveQuestionnaireAdministrationService.java",
"license": "gpl-3.0",
"size": 11728
} | [
"java.util.List",
"org.obiba.onyx.quartz.core.domain.answer.CategoryAnswer",
"org.obiba.onyx.quartz.core.engine.questionnaire.question.Question"
] | import java.util.List; import org.obiba.onyx.quartz.core.domain.answer.CategoryAnswer; import org.obiba.onyx.quartz.core.engine.questionnaire.question.Question; | import java.util.*; import org.obiba.onyx.quartz.core.domain.answer.*; import org.obiba.onyx.quartz.core.engine.questionnaire.question.*; | [
"java.util",
"org.obiba.onyx"
] | java.util; org.obiba.onyx; | 488,662 |
private static void loadModuleInternal(final Window parent, final INaviModule module,
final JTree projectTree) {
final CModuleLoaderOperation operation = new CModuleLoaderOperation(module);
boolean success = false;
try {
if (projectTree != null) {
// Make sure the lazy UI components ... | static void function(final Window parent, final INaviModule module, final JTree projectTree) { final CModuleLoaderOperation operation = new CModuleLoaderOperation(module); boolean success = false; try { if (projectTree != null) { CNodeExpander.findNode(projectTree, module).getComponent(); } module.load(); success = tru... | /**
* Loads a module inside a thread.
*
* @param parent Parent window used for dialogs.
* @param module Module to load.
* @param projectTree Project tree to expand on module loading. This argument can be null.
*/ | Loads a module inside a thread | loadModuleInternal | {
"repo_name": "paran0ids0ul/binnavi",
"path": "src/main/java/com/google/security/zynamics/binnavi/Gui/Loaders/CModuleLoader.java",
"license": "apache-2.0",
"size": 8367
} | [
"com.google.security.zynamics.binnavi.Gui",
"com.google.security.zynamics.binnavi.disassembly.INaviModule",
"java.awt.Window",
"javax.swing.JTree"
] | import com.google.security.zynamics.binnavi.Gui; import com.google.security.zynamics.binnavi.disassembly.INaviModule; import java.awt.Window; import javax.swing.JTree; | import com.google.security.zynamics.binnavi.*; import com.google.security.zynamics.binnavi.disassembly.*; import java.awt.*; import javax.swing.*; | [
"com.google.security",
"java.awt",
"javax.swing"
] | com.google.security; java.awt; javax.swing; | 1,206,211 |
public static <T> void writeList(String filePath, Collection<T> ts, Converter<T, String> lw, boolean append)
throws Exception {
BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(filePath, append), "UTF-8"));
StringBuilder contents = new StringBuilder();
int count = 0;
for ... | static <T> void function(String filePath, Collection<T> ts, Converter<T, String> lw, boolean append) throws Exception { BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(filePath, append), "UTF-8")); StringBuilder contents = new StringBuilder(); int count = 0; for (T t : ts) { contents.... | /**
* Write contents in Collection<T> to a file with the help of a writer helper
*
* @param <T>
* type of Objects in the collection
*
*/ | Write contents in Collection to a file with the help of a writer helper | writeList | {
"repo_name": "mys3lf/recalot.com",
"path": "com.recalot.model.rec.recommender.librec/src/librec/util/FileIO.java",
"license": "gpl-3.0",
"size": 19193
} | [
"java.io.BufferedWriter",
"java.io.FileOutputStream",
"java.io.OutputStreamWriter",
"java.util.Collection"
] | import java.io.BufferedWriter; import java.io.FileOutputStream; import java.io.OutputStreamWriter; import java.util.Collection; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 2,478,049 |
public PactDslJsonArray decimalType() {
generators.addGenerator(Category.BODY, rootPath + appendArrayIndex(1), new RandomDecimalGenerator(10));
return decimalType(new BigDecimal("100"));
} | PactDslJsonArray function() { generators.addGenerator(Category.BODY, rootPath + appendArrayIndex(1), new RandomDecimalGenerator(10)); return decimalType(new BigDecimal("100")); } | /**
* Element that must be a decimal value
*/ | Element that must be a decimal value | decimalType | {
"repo_name": "DiUS/pact-jvm",
"path": "consumer/src/main/java/au/com/dius/pact/consumer/dsl/PactDslJsonArray.java",
"license": "apache-2.0",
"size": 45650
} | [
"au.com.dius.pact.core.model.generators.Category",
"au.com.dius.pact.core.model.generators.RandomDecimalGenerator",
"java.math.BigDecimal"
] | import au.com.dius.pact.core.model.generators.Category; import au.com.dius.pact.core.model.generators.RandomDecimalGenerator; import java.math.BigDecimal; | import au.com.dius.pact.core.model.generators.*; import java.math.*; | [
"au.com.dius",
"java.math"
] | au.com.dius; java.math; | 1,586,155 |
public boolean isItemValid(ItemStack par1ItemStack) {
return par1ItemStack == null ? false : (par1ItemStack.getItem() instanceof ItemArmor ? ((ItemArmor) par1ItemStack.getItem()).armorType == this.armorType : (par1ItemStack.getItem().itemID != Block.pumpkin.blockID && par1ItemStack.getItem().itemID != Item.... | boolean function(ItemStack par1ItemStack) { return par1ItemStack == null ? false : (par1ItemStack.getItem() instanceof ItemArmor ? ((ItemArmor) par1ItemStack.getItem()).armorType == this.armorType : (par1ItemStack.getItem().itemID != Block.pumpkin.blockID && par1ItemStack.getItem().itemID != Item.skull.itemID ? false :... | /**
* Check if the stack is a valid item for this slot. Always true beside for the armor slots.
*/ | Check if the stack is a valid item for this slot. Always true beside for the armor slots | isItemValid | {
"repo_name": "DirectCodeGraveyard/Minetweak",
"path": "src/main/java/net/minecraft/inventory/slot/SlotArmor.java",
"license": "lgpl-3.0",
"size": 1577
} | [
"net.minecraft.block.Block",
"net.minecraft.item.Item",
"net.minecraft.item.ItemArmor",
"net.minecraft.item.ItemStack"
] | import net.minecraft.block.Block; import net.minecraft.item.Item; import net.minecraft.item.ItemArmor; import net.minecraft.item.ItemStack; | import net.minecraft.block.*; import net.minecraft.item.*; | [
"net.minecraft.block",
"net.minecraft.item"
] | net.minecraft.block; net.minecraft.item; | 998,315 |
@Test
public void testWorkManagerResourceReferenceLookupOfManagedScheduledExecutorService(HttpServletRequest request, HttpServletResponse response) throws Exception {
WorkManager wm = InitialContext.doLookup("java:comp/env/wm/scheduledExecutorRef");
assertNotNull(wm);
assertTrue(wm.toStr... | void function(HttpServletRequest request, HttpServletResponse response) throws Exception { WorkManager wm = InitialContext.doLookup(STR); assertNotNull(wm); assertTrue(wm.toString(), wm instanceof ScheduledExecutorService); assertTrue(wm.toString(), wm instanceof ManagedScheduledExecutorService); Phaser workStarted = n... | /**
* Perform a lookup of a managedExecutorService using deployment descriptor defined resource reference
* that specifies the resource type as WorkManager.
*/ | Perform a lookup of a managedExecutorService using deployment descriptor defined resource reference that specifies the resource type as WorkManager | testWorkManagerResourceReferenceLookupOfManagedScheduledExecutorService | {
"repo_name": "kgibm/open-liberty",
"path": "dev/com.ibm.ws.concurrent_fat_work/test-applications/WorkTestApp/src/test/concurrent/work/app/WorkTestServlet.java",
"license": "epl-1.0",
"size": 29745
} | [
"java.util.concurrent.CompletionException",
"java.util.concurrent.CountDownLatch",
"java.util.concurrent.Phaser",
"java.util.concurrent.ScheduledExecutorService",
"java.util.concurrent.TimeUnit",
"javax.enterprise.concurrent.ManagedScheduledExecutorService",
"javax.naming.InitialContext",
"javax.servl... | import java.util.concurrent.CompletionException; import java.util.concurrent.CountDownLatch; import java.util.concurrent.Phaser; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; import javax.enterprise.concurrent.ManagedScheduledExecutorService; import javax.naming.InitialCont... | import java.util.concurrent.*; import javax.enterprise.concurrent.*; import javax.naming.*; import javax.servlet.http.*; import org.junit.*; | [
"java.util",
"javax.enterprise",
"javax.naming",
"javax.servlet",
"org.junit"
] | java.util; javax.enterprise; javax.naming; javax.servlet; org.junit; | 22,282 |
private void processPredicationDocument(Document document, BLAS blas)
{
String subject = document.get(SUBJECT_FIELD);
String predicate = document.get(PREDICATE_FIELD);
String object = document.get(OBJECT_FIELD);
String predication = subject+predicate+object;
String subsem =... | void function(Document document, BLAS blas) { String subject = document.get(SUBJECT_FIELD); String predicate = document.get(PREDICATE_FIELD); String object = document.get(OBJECT_FIELD); String predication = subject+predicate+object; String subsem = document.get(STR); String obsem = document.get(STR); boolean encode = t... | /**
* Process an individual predication (each Document object contains one predication)
* in both directions (i.e. a PRED b; b PRED-INV a)
* @param document
**/ | Process an individual predication (each Document object contains one predication) in both directions (i.e. a PRED b; b PRED-INV a) | processPredicationDocument | {
"repo_name": "semanticvectors/semanticvectors",
"path": "src/main/java/pitt/search/semanticvectors/ESP.java",
"license": "bsd-3-clause",
"size": 35623
} | [
"org.apache.lucene.document.Document",
"org.apache.lucene.index.Term",
"pitt.search.semanticvectors.utils.VerbatimLogger"
] | import org.apache.lucene.document.Document; import org.apache.lucene.index.Term; import pitt.search.semanticvectors.utils.VerbatimLogger; | import org.apache.lucene.document.*; import org.apache.lucene.index.*; import pitt.search.semanticvectors.utils.*; | [
"org.apache.lucene",
"pitt.search.semanticvectors"
] | org.apache.lucene; pitt.search.semanticvectors; | 2,359,862 |
protected Object parseValue( String arg, Locale locale )
throws IllegalOptionValueException {
return null;
}
private String shortForm = null;
private String longForm = null;
private boolean wantsValue = false;
public static class BooleanOption extends Option {
public BooleanOption( char shortFo... | Object function( String arg, Locale locale ) throws IllegalOptionValueException { return null; } private String shortForm = null; private String longForm = null; private boolean wantsValue = false; public static class BooleanOption extends Option { public BooleanOption( char shortForm, String longForm ) { super(shortFo... | /**
* Override to extract and convert an option value passed on the
* command-line
*/ | Override to extract and convert an option value passed on the command-line | parseValue | {
"repo_name": "SoftwareIntrospectionLab/FixCache",
"path": "src/main/java/edu/ucsc/sil/fixcache/util/CmdLineParser.java",
"license": "bsd-3-clause",
"size": 16059
} | [
"java.util.Locale"
] | import java.util.Locale; | import java.util.*; | [
"java.util"
] | java.util; | 1,840,760 |
public EventType[] getEventTypes()
{
return eventTypes;
} | EventType[] function() { return eventTypes; } | /**
* Returns types allowed for variant streams.
* @return types
*/ | Returns types allowed for variant streams | getEventTypes | {
"repo_name": "b-cuts/esper",
"path": "esper/src/main/java/com/espertech/esper/event/vaevent/VariantSpec.java",
"license": "gpl-2.0",
"size": 2114
} | [
"com.espertech.esper.client.EventType"
] | import com.espertech.esper.client.EventType; | import com.espertech.esper.client.*; | [
"com.espertech.esper"
] | com.espertech.esper; | 276,679 |
protected void firePeerDisconnected(URI peerURI, SpaceID space) {
final NetworkServiceListener[] ilisteners;
synchronized (this.listeners) {
ilisteners = new NetworkServiceListener[this.listeners.size()];
this.listeners.toArray(ilisteners);
}
for (final Networ... | void function(URI peerURI, SpaceID space) { final NetworkServiceListener[] ilisteners; synchronized (this.listeners) { ilisteners = new NetworkServiceListener[this.listeners.size()]; this.listeners.toArray(ilisteners); } for (final NetworkServiceListener listener : ilisteners) { listener.peerDisconnected(peerURI, space... | /**
* Notifies that a peer space was disconnected.
*
* @param peerURI
* - the URI of the peer that was disconnected to.
* @param space
* - the identifier of the disconnected space.
*/ | Notifies that a peer space was disconnected | firePeerDisconnected | {
"repo_name": "jgfoster/sarl",
"path": "sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/zeromq/ZeroMQNetworkService.java",
"license": "apache-2.0",
"size": 29823
} | [
"io.janusproject.services.network.NetworkServiceListener",
"io.sarl.lang.core.SpaceID"
] | import io.janusproject.services.network.NetworkServiceListener; import io.sarl.lang.core.SpaceID; | import io.janusproject.services.network.*; import io.sarl.lang.core.*; | [
"io.janusproject.services",
"io.sarl.lang"
] | io.janusproject.services; io.sarl.lang; | 1,981,500 |
private void readNextKey() throws IOException {
more = in.next();
if (more) {
DataInputBuffer nextKeyBytes = in.getKey();
keyIn.reset(nextKeyBytes.getData(), nextKeyBytes.getPosition(), nextKeyBytes.getLength());
nextKey = keyDeserializer.deserialize(nextKey);
hasNext = k... | void function() throws IOException { more = in.next(); if (more) { DataInputBuffer nextKeyBytes = in.getKey(); keyIn.reset(nextKeyBytes.getData(), nextKeyBytes.getPosition(), nextKeyBytes.getLength()); nextKey = keyDeserializer.deserialize(nextKey); hasNext = key != null && (comparator.compare(key, nextKey) == 0); } el... | /**
* read the next key
*/ | read the next key | readNextKey | {
"repo_name": "apurtell/hadoop",
"path": "hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java",
"license": "apache-2.0",
"size": 66589
} | [
"java.io.IOException",
"org.apache.hadoop.io.DataInputBuffer"
] | import java.io.IOException; import org.apache.hadoop.io.DataInputBuffer; | import java.io.*; import org.apache.hadoop.io.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 1,041,101 |
public static String getMessage(String key)
{
return load().getString(key);
}
/**
* Look up the message string from the resource bundle and format with
* the supplied arguments
* @param key
* @param args MessageFormat arguments. See {@linkplain MessageFormat#format(Object)} | static String function(String key) { return load().getString(key); } /** * Look up the message string from the resource bundle and format with * the supplied arguments * @param key * @param args MessageFormat arguments. See {@linkplain MessageFormat#format(Object)} | /**
* Look up the message string from the resource bundle.
*
* @param key Must be one of the statics defined in this file
* @return
*/ | Look up the message string from the resource bundle | getMessage | {
"repo_name": "prelert/engine-java",
"path": "prelert-engine-api-common/src/main/java/com/prelert/job/messages/Messages.java",
"license": "apache-2.0",
"size": 19875
} | [
"java.text.MessageFormat"
] | import java.text.MessageFormat; | import java.text.*; | [
"java.text"
] | java.text; | 1,148,718 |
public void startSlave(RawStoreFactory rawStore, LogFactory logFac)
throws StandardException {
rawStoreFactory = rawStore;
try {
logToFile = (LogToFile)logFac;
} catch (ClassCastException cce) {
// Since there are only two implementing classes of
... | void function(RawStoreFactory rawStore, LogFactory logFac) throws StandardException { rawStoreFactory = rawStore; try { logToFile = (LogToFile)logFac; } catch (ClassCastException cce) { throw StandardException.newException( SQLState.LOGMODULE_DOES_NOT_SUPPORT_REPLICATION); } logToFile.initializeReplicationSlaveRole(); ... | /**
* Start slave replication. This method establishes a network
* connection with the associated replication master and starts a
* thread that applies operations received from the master (in the
* form of log records) to the local slave database.
*
* @param rawStore The RawStoreFactory fo... | Start slave replication. This method establishes a network connection with the associated replication master and starts a thread that applies operations received from the master (in the form of log records) to the local slave database | startSlave | {
"repo_name": "papicella/snappy-store",
"path": "gemfirexd/core/src/main/java/com/pivotal/gemfirexd/internal/impl/store/replication/slave/SlaveController.java",
"license": "apache-2.0",
"size": 23627
} | [
"com.pivotal.gemfirexd.internal.iapi.error.StandardException",
"com.pivotal.gemfirexd.internal.iapi.reference.MessageId",
"com.pivotal.gemfirexd.internal.iapi.reference.SQLState",
"com.pivotal.gemfirexd.internal.iapi.services.monitor.Monitor",
"com.pivotal.gemfirexd.internal.iapi.store.raw.RawStoreFactory",... | import com.pivotal.gemfirexd.internal.iapi.error.StandardException; import com.pivotal.gemfirexd.internal.iapi.reference.MessageId; import com.pivotal.gemfirexd.internal.iapi.reference.SQLState; import com.pivotal.gemfirexd.internal.iapi.services.monitor.Monitor; import com.pivotal.gemfirexd.internal.iapi.store.raw.Raw... | import com.pivotal.gemfirexd.internal.iapi.error.*; import com.pivotal.gemfirexd.internal.iapi.reference.*; import com.pivotal.gemfirexd.internal.iapi.services.monitor.*; import com.pivotal.gemfirexd.internal.iapi.store.raw.*; import com.pivotal.gemfirexd.internal.iapi.store.raw.log.*; import com.pivotal.gemfirexd.inte... | [
"com.pivotal.gemfirexd"
] | com.pivotal.gemfirexd; | 2,065,467 |
public static void setEnabled(TextView textview, boolean enabled) {
textview.setEnabled(enabled);
textview.invalidate();
} | static void function(TextView textview, boolean enabled) { textview.setEnabled(enabled); textview.invalidate(); } | /**
* Enables a {@link TextView}.
*
* @param textview text view instance
* @param enabled {@code true} for enabled, {@code false} disabled
*/ | Enables a <code>TextView</code> | setEnabled | {
"repo_name": "Edeleon4/punya",
"path": "appinventor/components/src/com/google/appinventor/components/runtime/util/TextViewUtil.java",
"license": "apache-2.0",
"size": 5313
} | [
"android.widget.TextView"
] | import android.widget.TextView; | import android.widget.*; | [
"android.widget"
] | android.widget; | 2,911,240 |
public static Endpoint resolveMandatoryEndpoint(CamelContext context, String uri) {
Endpoint endpoint = context.getEndpoint(uri);
assertNotNull("No endpoint found for URI: " + uri, endpoint);
return endpoint;
}
| static Endpoint function(CamelContext context, String uri) { Endpoint endpoint = context.getEndpoint(uri); assertNotNull(STR + uri, endpoint); return endpoint; } | /**
* Resolves an endpoint and asserts that it is found
*/ | Resolves an endpoint and asserts that it is found | resolveMandatoryEndpoint | {
"repo_name": "everttigchelaar/camel-svn",
"path": "components/camel-test/src/main/java/org/apache/camel/test/TestSupport.java",
"license": "apache-2.0",
"size": 18523
} | [
"org.apache.camel.CamelContext",
"org.apache.camel.Endpoint"
] | import org.apache.camel.CamelContext; import org.apache.camel.Endpoint; | import org.apache.camel.*; | [
"org.apache.camel"
] | org.apache.camel; | 417,124 |
private void endDeclarable() {
Declarable d = createDeclarable();
stack.push(d);
} | void function() { Declarable d = createDeclarable(); stack.push(d); } | /**
* When we have finished a <code>declarable</code>, instantiate an instance of the
* {@link Declarable}and push it on the stack.
*/ | When we have finished a <code>declarable</code>, instantiate an instance of the <code>Declarable</code>and push it on the stack | endDeclarable | {
"repo_name": "smanvi-pivotal/geode",
"path": "geode-core/src/main/java/org/apache/geode/internal/cache/xmlcache/CacheXmlParser.java",
"license": "apache-2.0",
"size": 130334
} | [
"org.apache.geode.cache.Declarable"
] | import org.apache.geode.cache.Declarable; | import org.apache.geode.cache.*; | [
"org.apache.geode"
] | org.apache.geode; | 615,996 |
private static ExecutorService getPool() {
if (pool == null) {
pool = Executors.newWorkStealingPool();
}
return pool;
} | static ExecutorService function() { if (pool == null) { pool = Executors.newWorkStealingPool(); } return pool; } | /**
* Returns the thread pool for executing processes
*
* @return ExecutorService
*/ | Returns the thread pool for executing processes | getPool | {
"repo_name": "VISNode/VISNode",
"path": "src/main/java/visnode/executor/ProcessNode.java",
"license": "apache-2.0",
"size": 11902
} | [
"java.util.concurrent.ExecutorService",
"java.util.concurrent.Executors"
] | import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; | import java.util.concurrent.*; | [
"java.util"
] | java.util; | 2,680,311 |
public DataNode setGroup_type(IDataset group_type); | DataNode function(IDataset group_type); | /**
* Code number for group type, e.g. bank=1, tube=2 etc.
* <p>
* <b>Type:</b> NX_INT
* <b>Dimensions:</b> 1: ;
* </p>
*
* @param group_type the group_type
*/ | Code number for group type, e.g. bank=1, tube=2 etc. Type: NX_INT Dimensions: 1: ; | setGroup_type | {
"repo_name": "jamesmudd/dawnsci",
"path": "org.eclipse.dawnsci.nexus/autogen/org/eclipse/dawnsci/nexus/NXdetector_group.java",
"license": "epl-1.0",
"size": 5346
} | [
"org.eclipse.dawnsci.analysis.api.tree.DataNode",
"org.eclipse.january.dataset.IDataset"
] | import org.eclipse.dawnsci.analysis.api.tree.DataNode; import org.eclipse.january.dataset.IDataset; | import org.eclipse.dawnsci.analysis.api.tree.*; import org.eclipse.january.dataset.*; | [
"org.eclipse.dawnsci",
"org.eclipse.january"
] | org.eclipse.dawnsci; org.eclipse.january; | 1,855,334 |
private static void appendFile(Path p, int length) throws IOException {
byte[] toAppend = new byte[length];
Random random = new Random();
random.nextBytes(toAppend);
FSDataOutputStream out = cluster.getFileSystem().append(p);
try {
out.write(toAppend);
} finally {
IOUtils.closeStre... | static void function(Path p, int length) throws IOException { byte[] toAppend = new byte[length]; Random random = new Random(); random.nextBytes(toAppend); FSDataOutputStream out = cluster.getFileSystem().append(p); try { out.write(toAppend); } finally { IOUtils.closeStream(out); } } | /**
* Append specified length of bytes to a given file
*/ | Append specified length of bytes to a given file | appendFile | {
"repo_name": "robzor92/hops",
"path": "hadoop-tools/hadoop-distcp/src/test/java/org/apache/hadoop/tools/mapred/TestCopyMapper.java",
"license": "apache-2.0",
"size": 37751
} | [
"java.io.IOException",
"java.util.Random",
"org.apache.hadoop.fs.FSDataOutputStream",
"org.apache.hadoop.fs.Path",
"org.apache.hadoop.io.IOUtils"
] | import java.io.IOException; import java.util.Random; import org.apache.hadoop.fs.FSDataOutputStream; import org.apache.hadoop.fs.Path; import org.apache.hadoop.io.IOUtils; | import java.io.*; import java.util.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.io.*; | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 1,683,194 |
Node createObjectLit(Node... elements) {
Node result = IR.objectlit(elements);
if (isAddingTypes()) {
result.setJSType(registry.createAnonymousObjectType(null));
}
return result;
} | Node createObjectLit(Node... elements) { Node result = IR.objectlit(elements); if (isAddingTypes()) { result.setJSType(registry.createAnonymousObjectType(null)); } return result; } | /**
* Creates an object-literal with zero or more elements, `{}`.
*
* <p>The type of the literal, if assigned, may be a supertype of the known properties.
*/ | Creates an object-literal with zero or more elements, `{}`. The type of the literal, if assigned, may be a supertype of the known properties | createObjectLit | {
"repo_name": "vobruba-martin/closure-compiler",
"path": "src/com/google/javascript/jscomp/AstFactory.java",
"license": "apache-2.0",
"size": 40914
} | [
"com.google.javascript.rhino.IR",
"com.google.javascript.rhino.Node"
] | import com.google.javascript.rhino.IR; import com.google.javascript.rhino.Node; | import com.google.javascript.rhino.*; | [
"com.google.javascript"
] | com.google.javascript; | 2,224,207 |
Date getProcessingStartTime() {
return new Date(processingStartTime.getTime());
} | Date getProcessingStartTime() { return new Date(processingStartTime.getTime()); } | /**
* Gets the the processing start time for the decorated module.
*
* @return The start time, not valid if setProcessingStartTime() has not
* been called first.
*/ | Gets the the processing start time for the decorated module | getProcessingStartTime | {
"repo_name": "sleuthkit/autopsy",
"path": "Core/src/org/sleuthkit/autopsy/ingest/IngestPipeline.java",
"license": "apache-2.0",
"size": 18000
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 808,535 |
protected PointSensitivities parSpreadSensitivity(IborFutureTrade trade, RatesProvider provider) {
return productPricer.priceSensitivity(trade.getSecurity().getProduct(), provider);
} | PointSensitivities function(IborFutureTrade trade, RatesProvider provider) { return productPricer.priceSensitivity(trade.getSecurity().getProduct(), provider); } | /**
* Calculates the par spread sensitivity of the Ibor future trade.
* <p>
* The par spread sensitivity of the trade is the sensitivity of the par spread to
* the underlying curves.
*
* @param trade the trade to price
* @param provider the rates provider
* @return the par spread curve sensit... | Calculates the par spread sensitivity of the Ibor future trade. The par spread sensitivity of the trade is the sensitivity of the par spread to the underlying curves | parSpreadSensitivity | {
"repo_name": "nssales/Strata",
"path": "modules/pricer/src/main/java/com/opengamma/strata/pricer/rate/future/DiscountingIborFutureTradePricer.java",
"license": "apache-2.0",
"size": 4949
} | [
"com.opengamma.strata.finance.rate.future.IborFutureTrade",
"com.opengamma.strata.market.sensitivity.PointSensitivities",
"com.opengamma.strata.pricer.rate.RatesProvider"
] | import com.opengamma.strata.finance.rate.future.IborFutureTrade; import com.opengamma.strata.market.sensitivity.PointSensitivities; import com.opengamma.strata.pricer.rate.RatesProvider; | import com.opengamma.strata.finance.rate.future.*; import com.opengamma.strata.market.sensitivity.*; import com.opengamma.strata.pricer.rate.*; | [
"com.opengamma.strata"
] | com.opengamma.strata; | 168,842 |
@Override
public String getExtraNameCharacters() throws SQLException
{
checkClosed();
return "";
} | String function() throws SQLException { checkClosed(); return ""; } | /**
* Retrieves all the "extra" characters that can be used in unquoted identifier
* names (those beyond a-z, A-Z, 0-9 and _).
*/ | Retrieves all the "extra" characters that can be used in unquoted identifier names (those beyond a-z, A-Z, 0-9 and _) | getExtraNameCharacters | {
"repo_name": "migue/voltdb",
"path": "src/frontend/org/voltdb/jdbc/JDBC4DatabaseMetaData.java",
"license": "agpl-3.0",
"size": 57351
} | [
"java.sql.SQLException"
] | import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 1,290,620 |
@Test
public void testHandleRequestVoteWhenSenderLogMoreUpToDate() {
MockRaftActorContext context = createActorContext();
behavior = createBehavior(context);
context.getTermInformation().update(1, "test");
behavior.handleMessage(behaviorActor, new RequestVote(context.getTermIn... | void function() { MockRaftActorContext context = createActorContext(); behavior = createBehavior(context); context.getTermInformation().update(1, "test"); behavior.handleMessage(behaviorActor, new RequestVote(context.getTermInformation().getCurrentTerm(), "test", 10000, 999)); RequestVoteReply reply = MessageCollectorA... | /**
* This test verifies that when a RequestVote is received by the RaftActor
* with the senders' log is more up to date than the receiver that the receiver grants
* the vote to the sender.
*/ | This test verifies that when a RequestVote is received by the RaftActor with the senders' log is more up to date than the receiver that the receiver grants the vote to the sender | testHandleRequestVoteWhenSenderLogMoreUpToDate | {
"repo_name": "Sushma7785/OpenDayLight-Load-Balancer",
"path": "opendaylight/md-sal/sal-akka-raft/src/test/java/org/opendaylight/controller/cluster/raft/behaviors/AbstractRaftActorBehaviorTest.java",
"license": "epl-1.0",
"size": 15452
} | [
"org.junit.Assert",
"org.opendaylight.controller.cluster.raft.MockRaftActorContext",
"org.opendaylight.controller.cluster.raft.messages.RequestVote",
"org.opendaylight.controller.cluster.raft.messages.RequestVoteReply",
"org.opendaylight.controller.cluster.raft.utils.MessageCollectorActor"
] | import org.junit.Assert; import org.opendaylight.controller.cluster.raft.MockRaftActorContext; import org.opendaylight.controller.cluster.raft.messages.RequestVote; import org.opendaylight.controller.cluster.raft.messages.RequestVoteReply; import org.opendaylight.controller.cluster.raft.utils.MessageCollectorActor; | import org.junit.*; import org.opendaylight.controller.cluster.raft.*; import org.opendaylight.controller.cluster.raft.messages.*; import org.opendaylight.controller.cluster.raft.utils.*; | [
"org.junit",
"org.opendaylight.controller"
] | org.junit; org.opendaylight.controller; | 387,583 |
public DataNode setRaw_valueScalar(Number raw_value); | DataNode function(Number raw_value); | /**
* Array of raw information, such as thermocouple voltage
* <p>
* <b>Units:</b> NX_ANY
* <b>Type:</b> NX_NUMBER
* </p>
*
* @param raw_value the raw_value
*/ | Array of raw information, such as thermocouple voltage Units: NX_ANY Type: NX_NUMBER | setRaw_valueScalar | {
"repo_name": "xen-0/dawnsci",
"path": "org.eclipse.dawnsci.nexus/autogen/org/eclipse/dawnsci/nexus/NXlog.java",
"license": "epl-1.0",
"size": 9457
} | [
"org.eclipse.dawnsci.analysis.api.tree.DataNode"
] | import org.eclipse.dawnsci.analysis.api.tree.DataNode; | import org.eclipse.dawnsci.analysis.api.tree.*; | [
"org.eclipse.dawnsci"
] | org.eclipse.dawnsci; | 1,698,416 |
default Label entityRole(Label resourceLabel) {
return Schema.ImplicitType.HAS_OWNER.getLabel(resourceLabel);
} | default Label entityRole(Label resourceLabel) { return Schema.ImplicitType.HAS_OWNER.getLabel(resourceLabel); } | /**
* The name of the entity role type in an entity-role relation representing an OWL data property
*/ | The name of the entity role type in an entity-role relation representing an OWL data property | entityRole | {
"repo_name": "sheldonkhall/grakn",
"path": "grakn-migration/owl/src/main/java/ai/grakn/migration/owl/Namer.java",
"license": "gpl-3.0",
"size": 4177
} | [
"ai.grakn.concept.Label",
"ai.grakn.util.Schema"
] | import ai.grakn.concept.Label; import ai.grakn.util.Schema; | import ai.grakn.concept.*; import ai.grakn.util.*; | [
"ai.grakn.concept",
"ai.grakn.util"
] | ai.grakn.concept; ai.grakn.util; | 893,137 |
public Bound from(TableReference table) {
return new Bound(
name, query, toJsonString(table), validate, flattenResults, testBigQueryServices);
} | Bound function(TableReference table) { return new Bound( name, query, toJsonString(table), validate, flattenResults, testBigQueryServices); } | /**
* Returns a copy of this transform that reads from the specified table.
*
* <p>Does not modify this object.
*/ | Returns a copy of this transform that reads from the specified table. Does not modify this object | from | {
"repo_name": "tweise/beam",
"path": "sdks/java/core/src/main/java/org/apache/beam/sdk/io/BigQueryIO.java",
"license": "apache-2.0",
"size": 95053
} | [
"com.google.api.services.bigquery.model.TableReference"
] | import com.google.api.services.bigquery.model.TableReference; | import com.google.api.services.bigquery.model.*; | [
"com.google.api"
] | com.google.api; | 481,790 |
@Nullable
public GroupByQuery toGroupByQuery()
{
if (grouping == null) {
return null;
}
final Filtration filtration = Filtration.create(filter).optimize(sourceRowSignature);
return new GroupByQuery(
dataSource,
filtration.getQuerySegmentSpec(),
getVirtualColumns(pla... | GroupByQuery function() { if (grouping == null) { return null; } final Filtration filtration = Filtration.create(filter).optimize(sourceRowSignature); return new GroupByQuery( dataSource, filtration.getQuerySegmentSpec(), getVirtualColumns(plannerContext.getExprMacroTable()), filtration.getDimFilter(), Granularities.AL... | /**
* Return this query as a GroupBy query, or null if this query is not compatible with GroupBy.
*
* @return query or null
*/ | Return this query as a GroupBy query, or null if this query is not compatible with GroupBy | toGroupByQuery | {
"repo_name": "praveev/druid",
"path": "sql/src/main/java/io/druid/sql/calcite/rel/DruidQuery.java",
"license": "apache-2.0",
"size": 32883
} | [
"com.google.common.collect.ImmutableSortedMap",
"io.druid.java.util.common.granularity.Granularities",
"io.druid.query.groupby.GroupByQuery",
"io.druid.query.groupby.having.DimFilterHavingSpec",
"io.druid.sql.calcite.filtration.Filtration"
] | import com.google.common.collect.ImmutableSortedMap; import io.druid.java.util.common.granularity.Granularities; import io.druid.query.groupby.GroupByQuery; import io.druid.query.groupby.having.DimFilterHavingSpec; import io.druid.sql.calcite.filtration.Filtration; | import com.google.common.collect.*; import io.druid.java.util.common.granularity.*; import io.druid.query.groupby.*; import io.druid.query.groupby.having.*; import io.druid.sql.calcite.filtration.*; | [
"com.google.common",
"io.druid.java",
"io.druid.query",
"io.druid.sql"
] | com.google.common; io.druid.java; io.druid.query; io.druid.sql; | 692,719 |
private static boolean checkName(DetailAST method) {
final DetailAST ident = method.findFirstToken(TokenTypes.IDENT);
return "main".equals(ident.getText());
} | static boolean function(DetailAST method) { final DetailAST ident = method.findFirstToken(TokenTypes.IDENT); return "main".equals(ident.getText()); } | /**
* Checks that method name is @quot;main@quot;.
* @param method the METHOD_DEF node
* @return true if check passed, false otherwise
*/ | Checks that method name is @quot;main@quot; | checkName | {
"repo_name": "nikhilgupta23/checkstyle",
"path": "src/main/java/com/puppycrawl/tools/checkstyle/checks/UncommentedMainCheck.java",
"license": "lgpl-2.1",
"size": 7977
} | [
"com.puppycrawl.tools.checkstyle.api.DetailAST",
"com.puppycrawl.tools.checkstyle.api.TokenTypes"
] | import com.puppycrawl.tools.checkstyle.api.DetailAST; import com.puppycrawl.tools.checkstyle.api.TokenTypes; | import com.puppycrawl.tools.checkstyle.api.*; | [
"com.puppycrawl.tools"
] | com.puppycrawl.tools; | 2,707,354 |
@JsonProperty("planning")
public Planning getPlanning() {
return planning;
} | @JsonProperty(STR) Planning function() { return planning; } | /**
* Planning
* <p>
* Information from the planning phase of the contracting process. Note that many other fields may be filled in a
* planning release, in the appropriate fields in other schema sections, these would likely be estimates at this
* stage e.g. totalValue in tender
*/ | Planning Information from the planning phase of the contracting process. Note that many other fields may be filled in a planning release, in the appropriate fields in other schema sections, these would likely be estimates at this stage e.g. totalValue in tender | getPlanning | {
"repo_name": "devgateway/ocua",
"path": "persistence-mongodb/src/main/java/org/devgateway/ocds/persistence/mongo/Release.java",
"license": "mit",
"size": 24880
} | [
"com.fasterxml.jackson.annotation.JsonProperty"
] | import com.fasterxml.jackson.annotation.JsonProperty; | import com.fasterxml.jackson.annotation.*; | [
"com.fasterxml.jackson"
] | com.fasterxml.jackson; | 956,752 |
public static int hashCode(long address, long length, int seed) {
int index = 0;
int hash = seed;
while (index + 4 <= length) {
int intValue = MemoryUtil.UNSAFE.getInt(address + index);
hash = combineHashCode(hash, intValue);
index += 4;
}
if (index < length) {
// process ... | static int function(long address, long length, int seed) { int index = 0; int hash = seed; while (index + 4 <= length) { int intValue = MemoryUtil.UNSAFE.getInt(address + index); hash = combineHashCode(hash, intValue); index += 4; } if (index < length) { int intValue = 0; for (int i = index - 1; i >= index; i--) { intV... | /**
* Calculates the hash code for a memory region.
* @param address start address of the memory region.
* @param length length of the memory region.
* @param seed the seed.
* @return the hash code.
*/ | Calculates the hash code for a memory region | hashCode | {
"repo_name": "cpcloud/arrow",
"path": "java/memory/memory-core/src/main/java/org/apache/arrow/memory/util/hash/MurmurHasher.java",
"license": "apache-2.0",
"size": 5065
} | [
"org.apache.arrow.memory.util.MemoryUtil"
] | import org.apache.arrow.memory.util.MemoryUtil; | import org.apache.arrow.memory.util.*; | [
"org.apache.arrow"
] | org.apache.arrow; | 927,381 |
static private List<String> readTable()
{
LinkedList<String> informations = new LinkedList<String>();
BufferedReader br;
try {
br = new BufferedReader(new FileReader(Constants.PathOfTableBackupFile+"//"+Constants.NameOfTableBackupFile));
String line;
while ((line = br.readLine()) != null) ... | static List<String> function() { LinkedList<String> informations = new LinkedList<String>(); BufferedReader br; try { br = new BufferedReader(new FileReader(Constants.PathOfTableBackupFile+" String line; while ((line = br.readLine()) != null) { informations.add(line); } br.close(); } catch (FileNotFoundException e1) { ... | /**
* Read from file the informations about known clients, which may have been saved in the previous session (if any).
*
* @return a list of strings containing the existing clients' informations.
*/ | Read from file the informations about known clients, which may have been saved in the previous session (if any) | readTable | {
"repo_name": "fagiodarkie/PRP",
"path": "src/it/unipr/informatica/reti/PRP/implementation/ParentsManager.java",
"license": "gpl-2.0",
"size": 6844
} | [
"it.unipr.informatica.reti.PRP",
"java.io.BufferedReader",
"java.io.FileNotFoundException",
"java.io.FileReader",
"java.io.IOException",
"java.util.LinkedList",
"java.util.List"
] | import it.unipr.informatica.reti.PRP; import java.io.BufferedReader; import java.io.FileNotFoundException; import java.io.FileReader; import java.io.IOException; import java.util.LinkedList; import java.util.List; | import it.unipr.informatica.reti.*; import java.io.*; import java.util.*; | [
"it.unipr.informatica",
"java.io",
"java.util"
] | it.unipr.informatica; java.io; java.util; | 272,772 |
public void getBytes(int index, OutputStream out, int length) throws IOException {
Preconditions.checkArgument(out != null, "expecting valid output stream");
checkIndex(index, length);
if (length > 0) {
// copy length bytes of data from this ArrowBuf starting at
// address addr(index) into the... | void function(int index, OutputStream out, int length) throws IOException { Preconditions.checkArgument(out != null, STR); checkIndex(index, length); if (length > 0) { byte[] tmp = new byte[length]; PlatformDependent.copyMemory(addr(index), tmp, 0, length); out.write(tmp); } } | /**
* Copy a certain length of bytes from this ArrowBuf at a given
* index into the given OutputStream.
* @param index index index (0 based relative to the portion of memory
* this ArrowBuf has access to)
* @param out dst stream to copy data into
* @param length length of data to copy
... | Copy a certain length of bytes from this ArrowBuf at a given index into the given OutputStream | getBytes | {
"repo_name": "renesugar/arrow",
"path": "java/memory/src/main/java/io/netty/buffer/ArrowBuf.java",
"license": "apache-2.0",
"size": 43243
} | [
"io.netty.util.internal.PlatformDependent",
"java.io.IOException",
"java.io.OutputStream",
"org.apache.arrow.util.Preconditions"
] | import io.netty.util.internal.PlatformDependent; import java.io.IOException; import java.io.OutputStream; import org.apache.arrow.util.Preconditions; | import io.netty.util.internal.*; import java.io.*; import org.apache.arrow.util.*; | [
"io.netty.util",
"java.io",
"org.apache.arrow"
] | io.netty.util; java.io; org.apache.arrow; | 1,233,626 |
@Override
@Deprecated
public boolean remove(Widget w) {
return false;
} | boolean function(Widget w) { return false; } | /**
* Grid does not support removing Widgets this way.
* <p>
* This method is implemented only because removing widgets from Grid (added
* via e.g. {@link Renderer}s) requires the {@link HasWidgets} interface.
*
* @return always <code>false</code>
*/ | Grid does not support removing Widgets this way. This method is implemented only because removing widgets from Grid (added via e.g. <code>Renderer</code>s) requires the <code>HasWidgets</code> interface | remove | {
"repo_name": "shahrzadmn/vaadin",
"path": "client/src/com/vaadin/client/widgets/Grid.java",
"license": "apache-2.0",
"size": 302957
} | [
"com.google.gwt.user.client.ui.Widget"
] | import com.google.gwt.user.client.ui.Widget; | import com.google.gwt.user.client.ui.*; | [
"com.google.gwt"
] | com.google.gwt; | 1,527,008 |
public static Pubsub getClient() throws IOException {
return getClient(Utils.getDefaultTransport(),
Utils.getDefaultJsonFactory());
} | static Pubsub function() throws IOException { return getClient(Utils.getDefaultTransport(), Utils.getDefaultJsonFactory()); } | /**
* Builds a new Pubsub client with default HttpTransport and
* JsonFactory and returns it.
*/ | Builds a new Pubsub client with default HttpTransport and JsonFactory and returns it | getClient | {
"repo_name": "sammcveety/DataflowJavaSDK",
"path": "examples/src/main/java8/com/google/cloud/dataflow/examples/complete/game/injector/InjectorUtils.java",
"license": "apache-2.0",
"size": 3775
} | [
"com.google.api.client.googleapis.util.Utils",
"com.google.api.services.pubsub.Pubsub",
"java.io.IOException"
] | import com.google.api.client.googleapis.util.Utils; import com.google.api.services.pubsub.Pubsub; import java.io.IOException; | import com.google.api.client.googleapis.util.*; import com.google.api.services.pubsub.*; import java.io.*; | [
"com.google.api",
"java.io"
] | com.google.api; java.io; | 2,798,658 |
protected void transform( final GridBodyCellRenderContext context ) {
final Transform transform = context.getTransform();
final double width = context.getCellWidth();
final double height = context.getCellHeight();
final Style style = widgetContainer.getElement().getStyle();
... | void function( final GridBodyCellRenderContext context ) { final Transform transform = context.getTransform(); final double width = context.getCellWidth(); final double height = context.getCellHeight(); final Style style = widgetContainer.getElement().getStyle(); style.setOpacity( gridWidget.getAlpha() ); style.setLeft... | /**
* Transform the DOMElement based on the render context, such as scale and position.
* @param context
*/ | Transform the DOMElement based on the render context, such as scale and position | transform | {
"repo_name": "paulovmr/uberfire",
"path": "uberfire-extensions/uberfire-wires/uberfire-wires-core/uberfire-wires-core-grids/src/main/java/org/uberfire/ext/wires/core/grids/client/widget/dom/impl/BaseDOMElement.java",
"license": "apache-2.0",
"size": 15449
} | [
"com.ait.lienzo.client.core.shape.Group",
"com.ait.lienzo.client.core.types.Transform",
"com.google.gwt.dom.client.Style",
"org.uberfire.ext.wires.core.grids.client.util.MathUtilities",
"org.uberfire.ext.wires.core.grids.client.widget.context.GridBodyCellRenderContext"
] | import com.ait.lienzo.client.core.shape.Group; import com.ait.lienzo.client.core.types.Transform; import com.google.gwt.dom.client.Style; import org.uberfire.ext.wires.core.grids.client.util.MathUtilities; import org.uberfire.ext.wires.core.grids.client.widget.context.GridBodyCellRenderContext; | import com.ait.lienzo.client.core.shape.*; import com.ait.lienzo.client.core.types.*; import com.google.gwt.dom.client.*; import org.uberfire.ext.wires.core.grids.client.util.*; import org.uberfire.ext.wires.core.grids.client.widget.context.*; | [
"com.ait.lienzo",
"com.google.gwt",
"org.uberfire.ext"
] | com.ait.lienzo; com.google.gwt; org.uberfire.ext; | 2,490,937 |
@SkylarkCallable(
name = "mostly_static_link_options",
doc =
"Returns the immutable list of linker options for mostly statically linked "
+ "outputs. Does not include command-line options passed via --linkopt or "
+ "--linkopts."
)
public ImmutableList<String> getMostlyStat... | @SkylarkCallable( name = STR, doc = STR + STR + STR ) ImmutableList<String> function(Iterable<String> features, Boolean sharedLib) { if (sharedLib) { return getSharedLibraryLinkOptions( supportsEmbeddedRuntimes ? mostlyStaticSharedLinkFlags : dynamicLinkFlags, features); } else { return mostlyStaticLinkFlags.evaluate(f... | /**
* Returns the immutable list of linker options for mostly statically linked
* outputs. Does not include command-line options passed via --linkopt or
* --linkopts.
*
* @param features default settings affecting this link
* @param sharedLib true if the output is a shared lib, false if it's an execut... | Returns the immutable list of linker options for mostly statically linked outputs. Does not include command-line options passed via --linkopt or --linkopts | getMostlyStaticLinkOptions | {
"repo_name": "iamthearm/bazel",
"path": "src/main/java/com/google/devtools/build/lib/rules/cpp/CppConfiguration.java",
"license": "apache-2.0",
"size": 77120
} | [
"com.google.common.collect.ImmutableList",
"com.google.devtools.build.lib.skylarkinterface.SkylarkCallable"
] | import com.google.common.collect.ImmutableList; import com.google.devtools.build.lib.skylarkinterface.SkylarkCallable; | import com.google.common.collect.*; import com.google.devtools.build.lib.skylarkinterface.*; | [
"com.google.common",
"com.google.devtools"
] | com.google.common; com.google.devtools; | 62,890 |
public Observable<ServiceResponse<Page<WebApplicationFirewallPolicyInner>>> listSinglePageAsync() {
if (this.client.subscriptionId() == null) {
throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null.");
} | Observable<ServiceResponse<Page<WebApplicationFirewallPolicyInner>>> function() { if (this.client.subscriptionId() == null) { throw new IllegalArgumentException(STR); } | /**
* Gets all the WAF policies in a subscription.
*
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the PagedList<WebApplicationFirewallPolicyInner> object wrapped in {@link ServiceResponse} if successful.
*/ | Gets all the WAF policies in a subscription | listSinglePageAsync | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2019_07_01/src/main/java/com/microsoft/azure/management/network/v2019_07_01/implementation/WebApplicationFirewallPoliciesInner.java",
"license": "mit",
"size": 51475
} | [
"com.microsoft.azure.Page",
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.azure.Page; import com.microsoft.rest.ServiceResponse; | import com.microsoft.azure.*; import com.microsoft.rest.*; | [
"com.microsoft.azure",
"com.microsoft.rest"
] | com.microsoft.azure; com.microsoft.rest; | 1,302,632 |
private void logPlatformInfo(BundleContext context) {
StringBuilder platformInfo = new StringBuilder();
// add platform information
platformInfo.append(osgiPlatform);
platformInfo.append(" [");
// Version
platformInfo.append(OsgiPlatformDetector.getVersion(con... | void function(BundleContext context) { StringBuilder platformInfo = new StringBuilder(); platformInfo.append(osgiPlatform); platformInfo.append(STR); platformInfo.append(OsgiPlatformDetector.getVersion(context)); platformInfo.append("]"); logger.info(platformInfo + STR); } | /**
* Logs the underlying OSGi information (which can be tricky).
*/ | Logs the underlying OSGi information (which can be tricky) | logPlatformInfo | {
"repo_name": "eclipse/gemini.blueprint",
"path": "test-support/src/main/java/org/eclipse/gemini/blueprint/test/AbstractOsgiTests.java",
"license": "apache-2.0",
"size": 18539
} | [
"org.eclipse.gemini.blueprint.util.OsgiPlatformDetector",
"org.osgi.framework.BundleContext"
] | import org.eclipse.gemini.blueprint.util.OsgiPlatformDetector; import org.osgi.framework.BundleContext; | import org.eclipse.gemini.blueprint.util.*; import org.osgi.framework.*; | [
"org.eclipse.gemini",
"org.osgi.framework"
] | org.eclipse.gemini; org.osgi.framework; | 96,054 |
@Override
protected CloseableBLOBStore createLocalFSBlobStore(PMContext context)
throws Exception {
File baseLocation = context.getHomeDir();
if ( useSharedFsBlobStore ) {
baseLocation = new File(sharedLocation);
}
LocalFileSystem blobFS = new LocalFileSystem();
blobFS.setRoot(new File(baseLocati... | CloseableBLOBStore function(PMContext context) throws Exception { File baseLocation = context.getHomeDir(); if ( useSharedFsBlobStore ) { baseLocation = new File(sharedLocation); } LocalFileSystem blobFS = new LocalFileSystem(); blobFS.setRoot(new File(baseLocation, "blobs")); blobFS.init(); return new FSBlobStore(blob... | /**
* Creates a blob store that is based on a local fs. This is called by init
* if {@link #useLocalFsBlobStore()} returns <code>true</code>.
*
* If {@link #useSharedFsBlobStore} is <code>true</code>, then the store will be in a
* shared location.
*
* @param context
* the persistence manager ... | Creates a blob store that is based on a local fs. This is called by init if <code>#useLocalFsBlobStore()</code> returns <code>true</code>. If <code>#useSharedFsBlobStore</code> is <code>true</code>, then the store will be in a shared location | createLocalFSBlobStore | {
"repo_name": "sakai-mirror/k2",
"path": "kernel/src/main/java/org/sakaiproject/kernel/jcr/jackrabbit/persistance/Oracle9SharedPersistenceManager.java",
"license": "apache-2.0",
"size": 2510
} | [
"java.io.File",
"org.apache.jackrabbit.core.fs.local.LocalFileSystem",
"org.apache.jackrabbit.core.persistence.PMContext"
] | import java.io.File; import org.apache.jackrabbit.core.fs.local.LocalFileSystem; import org.apache.jackrabbit.core.persistence.PMContext; | import java.io.*; import org.apache.jackrabbit.core.fs.local.*; import org.apache.jackrabbit.core.persistence.*; | [
"java.io",
"org.apache.jackrabbit"
] | java.io; org.apache.jackrabbit; | 1,767,826 |
@Test
public void testEquals() {
TimeSeriesCollection c1 = new TimeSeriesCollection();
TimeSeriesCollection c2 = new TimeSeriesCollection();
TimeSeries s1 = new TimeSeries("Series 1");
TimeSeries s2 = new TimeSeries("Series 2");
// newly created collections should be eq... | void function() { TimeSeriesCollection c1 = new TimeSeriesCollection(); TimeSeriesCollection c2 = new TimeSeriesCollection(); TimeSeries s1 = new TimeSeries(STR); TimeSeries s2 = new TimeSeries(STR); boolean b1 = c1.equals(c2); assertTrue("b1", b1); c1.addSeries(s1); c1.addSeries(s2); boolean b2 = c1.equals(c2); assert... | /**
* Some tests for the equals() method.
*/ | Some tests for the equals() method | testEquals | {
"repo_name": "sternze/CurrentTopics_JFreeChart",
"path": "tests/org/jfree/data/time/TimeSeriesCollectionTest.java",
"license": "lgpl-2.1",
"size": 13875
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 2,036,495 |
public void warnCr(final Reconciliation reconciliation, final Message msg, final Throwable t) {
logger.logIfEnabled(FQCN, WARN, reconciliation.getMarker(), msg, t);
} | void function(final Reconciliation reconciliation, final Message msg, final Throwable t) { logger.logIfEnabled(FQCN, WARN, reconciliation.getMarker(), msg, t); } | /**
* Logs a message with the specific Marker at the {@code WARN} level.
*
* @param reconciliation The reconciliation
* @param msg the message string to be logged
* @param t A Throwable or null.
*/ | Logs a message with the specific Marker at the WARN level | warnCr | {
"repo_name": "ppatierno/kaas",
"path": "operator-common/src/main/java/io/strimzi/operator/common/ReconciliationLogger.java",
"license": "apache-2.0",
"size": 352724
} | [
"org.apache.logging.log4j.message.Message"
] | import org.apache.logging.log4j.message.Message; | import org.apache.logging.log4j.message.*; | [
"org.apache.logging"
] | org.apache.logging; | 399,514 |
protected void createLogoutConfirmationView(final Flow flow) {
val view = createViewState(flow, CasWebflowConstants.STATE_ID_CONFIRM_LOGOUT_VIEW, "casConfirmLogoutView");
createTransitionForState(view, CasWebflowConstants.TRANSITION_ID_SUCCESS, CasWebflowConstants.STATE_ID_TERMINATE_SESSION);
} | void function(final Flow flow) { val view = createViewState(flow, CasWebflowConstants.STATE_ID_CONFIRM_LOGOUT_VIEW, STR); createTransitionForState(view, CasWebflowConstants.TRANSITION_ID_SUCCESS, CasWebflowConstants.STATE_ID_TERMINATE_SESSION); } | /**
* Create logout confirmation view.
*
* @param flow the flow
*/ | Create logout confirmation view | createLogoutConfirmationView | {
"repo_name": "pdrados/cas",
"path": "core/cas-server-core-webflow-api/src/main/java/org/apereo/cas/web/flow/configurer/DefaultLogoutWebflowConfigurer.java",
"license": "apache-2.0",
"size": 5608
} | [
"org.apereo.cas.web.flow.CasWebflowConstants",
"org.springframework.webflow.engine.Flow"
] | import org.apereo.cas.web.flow.CasWebflowConstants; import org.springframework.webflow.engine.Flow; | import org.apereo.cas.web.flow.*; import org.springframework.webflow.engine.*; | [
"org.apereo.cas",
"org.springframework.webflow"
] | org.apereo.cas; org.springframework.webflow; | 1,386,541 |
long findContainerid(long conglomid)
throws StandardException; | long findContainerid(long conglomid) throws StandardException; | /**
* For debugging, find the containerid given the conglomid.
* <p>
* Will have to change if we ever have more than one container in
* a conglomerate.
*
* @return the containerid of container implementing conglomerate with
* "conglomid."
*
* @exception StandardExce... | For debugging, find the containerid given the conglomid. Will have to change if we ever have more than one container in a conglomerate | findContainerid | {
"repo_name": "scnakandala/derby",
"path": "java/engine/org/apache/derby/iapi/store/access/TransactionController.java",
"license": "apache-2.0",
"size": 89701
} | [
"org.apache.derby.iapi.error.StandardException"
] | import org.apache.derby.iapi.error.StandardException; | import org.apache.derby.iapi.error.*; | [
"org.apache.derby"
] | org.apache.derby; | 577,351 |
List<Exchange> entryList;
if (null == exchange.getProperty(Exchange.GROUPED_EXCHANGE)) {
entryList = new ArrayList<>();
entryList.add(exchange);
} else {
entryList = (List<Exchange>) exchange.getProperty(Exchange.GROUPED_EXCHANGE);
}
return entryList... | List<Exchange> entryList; if (null == exchange.getProperty(Exchange.GROUPED_EXCHANGE)) { entryList = new ArrayList<>(); entryList.add(exchange); } else { entryList = (List<Exchange>) exchange.getProperty(Exchange.GROUPED_EXCHANGE); } return entryList; } | /**
* The method converts a single incoming message into a List
*/ | The method converts a single incoming message into a List | prepareExchangeList | {
"repo_name": "DariusX/camel",
"path": "components/camel-google-bigquery/src/main/java/org/apache/camel/component/google/bigquery/GoogleBigQueryProducer.java",
"license": "apache-2.0",
"size": 8283
} | [
"java.util.ArrayList",
"java.util.List",
"org.apache.camel.Exchange"
] | import java.util.ArrayList; import java.util.List; import org.apache.camel.Exchange; | import java.util.*; import org.apache.camel.*; | [
"java.util",
"org.apache.camel"
] | java.util; org.apache.camel; | 679,271 |
public AddressSpace addressSpace() {
return this.addressSpace;
} | AddressSpace function() { return this.addressSpace; } | /**
* Get the AddressSpace that contains an array of IP address ranges.
*
* @return the addressSpace value
*/ | Get the AddressSpace that contains an array of IP address ranges | addressSpace | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2019_04_01/src/main/java/com/microsoft/azure/management/network/v2019_04_01/implementation/VpnSiteInner.java",
"license": "mit",
"size": 7321
} | [
"com.microsoft.azure.management.network.v2019_04_01.AddressSpace"
] | import com.microsoft.azure.management.network.v2019_04_01.AddressSpace; | import com.microsoft.azure.management.network.v2019_04_01.*; | [
"com.microsoft.azure"
] | com.microsoft.azure; | 2,678,339 |
public void clearRestrictedRoleMembersSearchResults(IdentityManagementRoleDocument identityManagementRoleDocument);
| void function(IdentityManagementRoleDocument identityManagementRoleDocument); | /**
*
* This method loads a document's original role members
*
* @param identityManagementRoleDocument
*/ | This method loads a document's original role members | clearRestrictedRoleMembersSearchResults | {
"repo_name": "ua-eas/ksd-kc5.2.1-rice2.3.6-ua",
"path": "rice-middleware/impl/src/main/java/org/kuali/rice/kim/service/UiDocumentService.java",
"license": "apache-2.0",
"size": 6172
} | [
"org.kuali.rice.kim.document.IdentityManagementRoleDocument"
] | import org.kuali.rice.kim.document.IdentityManagementRoleDocument; | import org.kuali.rice.kim.document.*; | [
"org.kuali.rice"
] | org.kuali.rice; | 362,245 |
public GQuery toggle(final Function... fn) {
for (Element e : elements) {
$(e).click(new Function() {
int click = 0; | GQuery function(final Function... fn) { for (Element e : elements) { $(e).click(new Function() { int click = 0; | /**
* Toggle among two or more function calls every other click.
*/ | Toggle among two or more function calls every other click | toggle | {
"repo_name": "stori-es/stori_es",
"path": "dashboard/src/main/java/com/google/gwt/query/client/GQuery.java",
"license": "apache-2.0",
"size": 177285
} | [
"com.google.gwt.dom.client.Element"
] | import com.google.gwt.dom.client.Element; | import com.google.gwt.dom.client.*; | [
"com.google.gwt"
] | com.google.gwt; | 2,364,366 |
private MockHttpServletRequest getMockHttpServletRequest() {
MockHttpServletRequest request = new MockHttpServletRequest();
ServletRequestAttributes attributes = new ServletRequestAttributes(request);
RequestContextHolder.setRequestAttributes(attributes);
return request;
}
| MockHttpServletRequest function() { MockHttpServletRequest request = new MockHttpServletRequest(); ServletRequestAttributes attributes = new ServletRequestAttributes(request); RequestContextHolder.setRequestAttributes(attributes); return request; } | /**
* Returns a mock HttpServletRequest object.
*
*/ | Returns a mock HttpServletRequest object | getMockHttpServletRequest | {
"repo_name": "didoux/Spring-BowlingDB",
"path": "generated/bowling/web/rest/GameRestControllerTest.java",
"license": "gpl-2.0",
"size": 4862
} | [
"org.springframework.mock.web.MockHttpServletRequest",
"org.springframework.web.context.request.RequestContextHolder",
"org.springframework.web.context.request.ServletRequestAttributes"
] | import org.springframework.mock.web.MockHttpServletRequest; import org.springframework.web.context.request.RequestContextHolder; import org.springframework.web.context.request.ServletRequestAttributes; | import org.springframework.mock.web.*; import org.springframework.web.context.request.*; | [
"org.springframework.mock",
"org.springframework.web"
] | org.springframework.mock; org.springframework.web; | 1,693,618 |
private Enumeration<URL> findEntries( String path )
{
Set<URL> entries = new HashSet<URL>( );
Enumeration<URL> children = bundle.findEntries( path, null, false );
while ( children != null && children.hasMoreElements( ) )
{
URL url = children.nextElement( );
if ( filter == null || ( filter != null && ... | Enumeration<URL> function( String path ) { Set<URL> entries = new HashSet<URL>( ); Enumeration<URL> children = bundle.findEntries( path, null, false ); while ( children != null && children.hasMoreElements( ) ) { URL url = children.nextElement( ); if ( filter == null ( filter != null && filter.accept( url ) ) ) entries.... | /**
* Returns an enumeration of URL objects for each matching entry.
*
* @param path
* The path name in which to look.
* @param patterns
* The file name pattern for selecting entries in the specified
* path.
* @return an enumeration of URL objects for each matching entr... | Returns an enumeration of URL objects for each matching entry | findEntries | {
"repo_name": "sguan-actuate/birt",
"path": "UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/internal/ui/resourcelocator/FragmentResourceEntry.java",
"license": "epl-1.0",
"size": 10093
} | [
"java.util.Enumeration",
"java.util.HashSet",
"java.util.Set",
"java.util.Vector"
] | import java.util.Enumeration; import java.util.HashSet; import java.util.Set; import java.util.Vector; | import java.util.*; | [
"java.util"
] | java.util; | 1,212,578 |
private void ordinalParametersDeleteQueryTest()
{
persistStudents();
Student s1 = em.find(Student.class, 12345677L);
Assert.assertNotNull(s1);
Query q = em.createQuery("delete from Student s where s.studentName = ?1");
q.setParameter(1, "Amresh");
int results = q.... | void function() { persistStudents(); Student s1 = em.find(Student.class, 12345677L); Assert.assertNotNull(s1); Query q = em.createQuery(STR); q.setParameter(1, STR); int results = q.executeUpdate(); Assert.assertNotNull(results); Assert.assertEquals(1, results); em.clear(); s1 = em.find(Student.class, 12345677L); Asser... | /**
* Ordinal parameters delete query test.
*/ | Ordinal parameters delete query test | ordinalParametersDeleteQueryTest | {
"repo_name": "ravisund/Kundera",
"path": "src/kundera-hbase/kundera-hbase-v2/src/test/java/com/impetus/client/query/HBaseParameterizedQueryTest.java",
"license": "apache-2.0",
"size": 44347
} | [
"javax.persistence.Query",
"junit.framework.Assert"
] | import javax.persistence.Query; import junit.framework.Assert; | import javax.persistence.*; import junit.framework.*; | [
"javax.persistence",
"junit.framework"
] | javax.persistence; junit.framework; | 1,587,063 |
@Nullable
public synchronized File reserve(String segmentFilePathToAdd, String segmentId, long segmentSize)
{
final File segmentFileToAdd = new File(path, segmentFilePathToAdd);
if (files.contains(segmentFileToAdd)) {
return null;
}
if (canHandle(segmentId, segmentSize)) {
files.add(se... | synchronized File function(String segmentFilePathToAdd, String segmentId, long segmentSize) { final File segmentFileToAdd = new File(path, segmentFilePathToAdd); if (files.contains(segmentFileToAdd)) { return null; } if (canHandle(segmentId, segmentSize)) { files.add(segmentFileToAdd); currSizeBytes += segmentSize; ret... | /**
* Reserves space to store the given segment.
* If it succeeds, it returns a file for the given segmentFilePathToAdd in this storage location.
* Returns null otherwise.
*/ | Reserves space to store the given segment. If it succeeds, it returns a file for the given segmentFilePathToAdd in this storage location. Returns null otherwise | reserve | {
"repo_name": "nishantmonu51/druid",
"path": "server/src/main/java/org/apache/druid/segment/loading/StorageLocation.java",
"license": "apache-2.0",
"size": 7773
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 1,506,285 |
ServiceCenterInfo getServiceCenterInfo(); | ServiceCenterInfo getServiceCenterInfo(); | /**
* get ServiceCenterVersionInfo
*/ | get ServiceCenterVersionInfo | getServiceCenterInfo | {
"repo_name": "acsukesh/java-chassis",
"path": "service-registry/src/main/java/org/apache/servicecomb/serviceregistry/client/ServiceRegistryClient.java",
"license": "apache-2.0",
"size": 4677
} | [
"org.apache.servicecomb.serviceregistry.api.registry.ServiceCenterInfo"
] | import org.apache.servicecomb.serviceregistry.api.registry.ServiceCenterInfo; | import org.apache.servicecomb.serviceregistry.api.registry.*; | [
"org.apache.servicecomb"
] | org.apache.servicecomb; | 762,377 |
public StepMeta findStep(String name, StepMeta exclude)
{
if (name==null) return null;
int excl = -1;
if (exclude != null) excl = indexOfStep(exclude);
for (int i = 0; i < nrSteps(); i++)
{
StepMeta stepMeta = getStep(i);
if (i != excl && stepMet... | StepMeta function(String name, StepMeta exclude) { if (name==null) return null; int excl = -1; if (exclude != null) excl = indexOfStep(exclude); for (int i = 0; i < nrSteps(); i++) { StepMeta stepMeta = getStep(i); if (i != excl && stepMeta.getName().equalsIgnoreCase(name)) { return stepMeta; } } return null; } | /**
* Searches the list of steps for a step with a certain name while excluding one step.
*
* @param name The name of the step to look for
* @param exclude The step information to exclude.
* @return The step information or null if nothing was found.
*/ | Searches the list of steps for a step with a certain name while excluding one step | findStep | {
"repo_name": "icholy/geokettle-2.0",
"path": "src/org/pentaho/di/trans/TransMeta.java",
"license": "lgpl-2.1",
"size": 230572
} | [
"org.pentaho.di.trans.step.StepMeta"
] | import org.pentaho.di.trans.step.StepMeta; | import org.pentaho.di.trans.step.*; | [
"org.pentaho.di"
] | org.pentaho.di; | 1,554,569 |
public ScreenPos mapToScreen(MapPos mapPos) {
return baseMapView.mapToScreen(mapPos);
} | ScreenPos function(MapPos mapPos) { return baseMapView.mapToScreen(mapPos); } | /**
* Calculates the screen position corresponding to a map position, using the current view parameters.
* @param mapPos The map position in base projection coordinate system.
* @return The calculated screen position. Can be off-screen.
*/ | Calculates the screen position corresponding to a map position, using the current view parameters | mapToScreen | {
"repo_name": "CartoDB/mobile-sdk",
"path": "android/java/com/carto/ui/MapView.java",
"license": "bsd-3-clause",
"size": 29228
} | [
"com.carto.core.MapPos",
"com.carto.core.ScreenPos"
] | import com.carto.core.MapPos; import com.carto.core.ScreenPos; | import com.carto.core.*; | [
"com.carto.core"
] | com.carto.core; | 2,453,576 |
public static ShortcutIconResource fromContext(Context context, int resourceId) {
ShortcutIconResource icon = new ShortcutIconResource();
icon.packageName = context.getPackageName();
icon.resourceName = context.getResources().getResourceName(resourceId);
return ic... | static ShortcutIconResource function(Context context, int resourceId) { ShortcutIconResource icon = new ShortcutIconResource(); icon.packageName = context.getPackageName(); icon.resourceName = context.getResources().getResourceName(resourceId); return icon; } public static final Parcelable.Creator<ShortcutIconResource>... | /**
* Creates a new ShortcutIconResource for the specified context and resource
* identifier.
*
* @param context The context of the application.
* @param resourceId The resource idenfitier for the icon.
* @return A new ShortcutIconResource with the specified's conte... | Creates a new ShortcutIconResource for the specified context and resource identifier | fromContext | {
"repo_name": "indashnet/InDashNet.Open.UN2000",
"path": "android/frameworks/base/core/java/android/content/Intent.java",
"license": "apache-2.0",
"size": 299722
} | [
"android.os.Parcelable"
] | import android.os.Parcelable; | import android.os.*; | [
"android.os"
] | android.os; | 981,311 |
public Map<String, Object> getPolicyDocument() {
final Map<String, Object> serializablePolicy = new HashMap<>();
serializablePolicy.put(VERSION, policyDocumentObject.Version);
final Statement[] statements = policyDocumentObject.getStatement();
final Map<String, Object>[] serializableStatementArray = n... | Map<String, Object> function() { final Map<String, Object> serializablePolicy = new HashMap<>(); serializablePolicy.put(VERSION, policyDocumentObject.Version); final Statement[] statements = policyDocumentObject.getStatement(); final Map<String, Object>[] serializableStatementArray = new Map[statements.length]; for (in... | /**
* IAM Policies use capitalized field names, but Lambda by default will serialize object members
* using camel case
*
* This method implements a custom serializer to return the IAM Policy as a well-formed JSON
* document, with the correct field names
*
* @return IAM Policy as a well-formed JSON ... | IAM Policies use capitalized field names, but Lambda by default will serialize object members using camel case This method implements a custom serializer to return the IAM Policy as a well-formed JSON document, with the correct field names | getPolicyDocument | {
"repo_name": "floodfx/gma-village",
"path": "java-lambda/src/main/java/com/amazonaws/services/lambda/runtime/AuthPolicy.java",
"license": "apache-2.0",
"size": 10819
} | [
"java.util.HashMap",
"java.util.Map"
] | import java.util.HashMap; import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 33,623 |
public Iterator<String> getAttributeKeys() {
return hasAttributes() ? responseObjects.keySet().iterator() : null;
} | Iterator<String> function() { return hasAttributes() ? responseObjects.keySet().iterator() : null; } | /**
* Get all keys of attributes stored in this object
*
* @return Iterator of keys of private collection of attributes, null if
* collection is null or empty
*/ | Get all keys of attributes stored in this object | getAttributeKeys | {
"repo_name": "tair/tairwebapp",
"path": "src/org/tair/handler/RequestHandlerResponse.java",
"license": "gpl-3.0",
"size": 3222
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 145,908 |
public List<UserModel> searchUsers(String searchString, RealmModel realmModel) {
if (searchString == null) {
return Collections.emptyList();
}
return session.users().searchForUser(searchString.trim(), realmModel);
} | List<UserModel> function(String searchString, RealmModel realmModel) { if (searchString == null) { return Collections.emptyList(); } return session.users().searchForUser(searchString.trim(), realmModel); } | /**
* Query users based on a search string:
* <p/>
* "Bill Burke" first and last name
* "bburke@redhat.com" email
* "Burke" lastname or username
*
* @param searchString
* @param realmModel
* @return
*/ | Query users based on a search string: "Bill Burke" first and last name "bburke@redhat.com" email "Burke" lastname or username | searchUsers | {
"repo_name": "dbarentine/keycloak",
"path": "services/src/main/java/org/keycloak/services/managers/RealmManager.java",
"license": "apache-2.0",
"size": 22867
} | [
"java.util.Collections",
"java.util.List",
"org.keycloak.models.RealmModel",
"org.keycloak.models.UserModel"
] | import java.util.Collections; import java.util.List; import org.keycloak.models.RealmModel; import org.keycloak.models.UserModel; | import java.util.*; import org.keycloak.models.*; | [
"java.util",
"org.keycloak.models"
] | java.util; org.keycloak.models; | 1,278,282 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.