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 Executable getExecutable() { return executor != null ? executor.getCurrentExecutable() : null; } /** * Is this work unit the "main work", which is the primary {@link SubTask}
Executable function() { return executor != null ? executor.getCurrentExecutable() : null; } /** * Is this work unit the STR, which is the primary {@link SubTask}
/** * If the execution has already started, return the current executable. */
If the execution has already started, return the current executable
getExecutable
{ "repo_name": "eclipse/hudson.core", "path": "hudson-core/src/main/java/hudson/model/queue/WorkUnit.java", "license": "apache-2.0", "size": 2228 }
[ "hudson.model.Queue" ]
import hudson.model.Queue;
import hudson.model.*;
[ "hudson.model" ]
hudson.model;
2,512,948
@ThreadConfined(type = ThreadConfined.ThreadType.AWT) void cancelSearch() { if (searchWorker != null) { searchWorker.cancel(true); } }
@ThreadConfined(type = ThreadConfined.ThreadType.AWT) void cancelSearch() { if (searchWorker != null) { searchWorker.cancel(true); } }
/** * Cancel the searchWorker if it exists. */
Cancel the searchWorker if it exists
cancelSearch
{ "repo_name": "eugene7646/autopsy", "path": "Core/src/org/sleuthkit/autopsy/discovery/ui/DiscoveryDialog.java", "license": "apache-2.0", "size": 40201 }
[ "org.sleuthkit.autopsy.coreutils.ThreadConfined" ]
import org.sleuthkit.autopsy.coreutils.ThreadConfined;
import org.sleuthkit.autopsy.coreutils.*;
[ "org.sleuthkit.autopsy" ]
org.sleuthkit.autopsy;
736,781
public static boolean visitSuperclasses(ITypeBinding type, TypeBindingVisitor visitor) { while ((type= type.getSuperclass()) != null) { if (!visitor.visit(type)) { return false; } } return true; } /** * Tests whether the two methods are erasure-equivalent. * @param method the first method * ...
static boolean function(ITypeBinding type, TypeBindingVisitor visitor) { while ((type= type.getSuperclass()) != null) { if (!visitor.visit(type)) { return false; } } return true; } /** * Tests whether the two methods are erasure-equivalent. * @param method the first method * @param methodName the name of the second met...
/** * Method to visit a super class hierarchy defined by a given type. * The given type itself is not visited. * * @param type the type whose super class hierarchy is to be visited * @param visitor the visitor * @return <code>true</code> if all types were visited, * or <code>false</code> if the vi...
Method to visit a super class hierarchy defined by a given type. The given type itself is not visited
visitSuperclasses
{ "repo_name": "trylimits/Eclipse-Postfix-Code-Completion", "path": "luna/org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/dom/Bindings.java", "license": "epl-1.0", "size": 56530 }
[ "org.eclipse.jdt.core.dom.IMethodBinding", "org.eclipse.jdt.core.dom.ITypeBinding" ]
import org.eclipse.jdt.core.dom.IMethodBinding; import org.eclipse.jdt.core.dom.ITypeBinding;
import org.eclipse.jdt.core.dom.*;
[ "org.eclipse.jdt" ]
org.eclipse.jdt;
2,248,494
public boolean removeFirst(String name, boolean ignoreCase) { boolean changed = false; Parameter param = null; for (final Iterator<E> iter = iterator(); iter.hasNext() && !changed;) { param = iter.next(); if (equals(param.getName(), name, ignoreCase)) { ...
boolean function(String name, boolean ignoreCase) { boolean changed = false; Parameter param = null; for (final Iterator<E> iter = iterator(); iter.hasNext() && !changed;) { param = iter.next(); if (equals(param.getName(), name, ignoreCase)) { iter.remove(); changed = true; } } return changed; }
/** * Removes from this list the first entry whose name equals the specified * name ignoring the case or not. * * @param name * The name of the entries to be removed. * @param ignoreCase * Indicates if the name comparison is case insensitive. * @return fals...
Removes from this list the first entry whose name equals the specified name ignoring the case or not
removeFirst
{ "repo_name": "theanuradha/debrief", "path": "org.mwc.asset.comms/docs/restlet_src/org.restlet/org/restlet/util/Series.java", "license": "epl-1.0", "size": 18811 }
[ "java.util.Iterator", "org.restlet.data.Parameter" ]
import java.util.Iterator; import org.restlet.data.Parameter;
import java.util.*; import org.restlet.data.*;
[ "java.util", "org.restlet.data" ]
java.util; org.restlet.data;
1,671,911
NodeList getNodes(EvaluationContext sContext) throws Exception;
NodeList getNodes(EvaluationContext sContext) throws Exception;
/** * Creates a tree of instances of nodes give an evaluation context.</br> The * context can hold variables that can be used in SpEL expressions in the * template set in a NodeDefinition.</br> The result is a list of nodes * having the same sort order than the template tree hierarchy. * ...
Creates a tree of instances of nodes give an evaluation context. The context can hold variables that can be used in SpEL expressions in the template set in a NodeDefinition. The result is a list of nodes having the same sort order than the template tree hierarchy
getNodes
{ "repo_name": "acxio/AGIA", "path": "agia-tasks/src/main/java/fr/acxio/tools/agia/alfresco/configuration/NodeFactory.java", "license": "apache-2.0", "size": 2255 }
[ "fr.acxio.tools.agia.alfresco.domain.NodeList", "org.springframework.expression.EvaluationContext" ]
import fr.acxio.tools.agia.alfresco.domain.NodeList; import org.springframework.expression.EvaluationContext;
import fr.acxio.tools.agia.alfresco.domain.*; import org.springframework.expression.*;
[ "fr.acxio.tools", "org.springframework.expression" ]
fr.acxio.tools; org.springframework.expression;
2,720,658
public boolean matches(String expr) { return Pattern.matches(expr, this); }
boolean function(String expr) { return Pattern.matches(expr, this); }
/** * Determines whether this string matches a given regular expression. * * @param expr the regular expression to be matched. * @return {@code true} if the expression matches, otherwise {@code false}. * @throws PatternSyntaxException if the syntax of the supplied regular expression is not vali...
Determines whether this string matches a given regular expression
matches
{ "repo_name": "kaustubh-walokar/grpc-poll-service", "path": "lib/netty/codec/src/main/java/io/netty/handler/codec/AsciiString.java", "license": "bsd-3-clause", "size": 50306 }
[ "java.util.regex.Pattern" ]
import java.util.regex.Pattern;
import java.util.regex.*;
[ "java.util" ]
java.util;
809,133
Observable<ServiceResponse<Void>> paramStringWithServiceResponseAsync(String scenario, String value);
Observable<ServiceResponse<Void>> paramStringWithServiceResponseAsync(String scenario, String value);
/** * Send a post request with header values "scenario": "valid", "value": "The quick brown fox jumps over the lazy dog" or "scenario": "null", "value": null or "scenario": "empty", "value": "". * * @param scenario Send a post request with header values "scenario": "valid" or "null" or "empty" * @pa...
Send a post request with header values "scenario": "valid", "value": "The quick brown fox jumps over the lazy dog" or "scenario": "null", "value": null or "scenario": "empty", "value": ""
paramStringWithServiceResponseAsync
{ "repo_name": "anudeepsharma/autorest", "path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/header/Headers.java", "license": "mit", "size": 53377 }
[ "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.rest.ServiceResponse;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
1,768,930
@Override public String getVersion() { try { return execute0("version"); } catch (IOException e) { throw new IllegalStateException(e); } }
String function() { try { return execute0(STR); } catch (IOException e) { throw new IllegalStateException(e); } }
/** * Get profiler agent version, e.g. "1.0" * * @return Version string */
Get profiler agent version, e.g. "1.0"
getVersion
{ "repo_name": "jvm-profiling-tools/async-profiler", "path": "src/api/one/profiler/AsyncProfiler.java", "license": "apache-2.0", "size": 6688 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
929,223
@Override public Dimension getPreferredSize() { return new Dimension(loipe.getWidth() * UNIT, loipe.getHeight() * UNIT); }
Dimension function() { return new Dimension(loipe.getWidth() * UNIT, loipe.getHeight() * UNIT); }
/** * Gets the preferred size of this component. * * @return a dimension object indicating this component's preferred size. */
Gets the preferred size of this component
getPreferredSize
{ "repo_name": "camilstaps/OO1415", "path": "Week4 Drawing loipes/src/oo15loipe/LoipePlaatje.java", "license": "mit", "size": 5676 }
[ "java.awt.Dimension" ]
import java.awt.Dimension;
import java.awt.*;
[ "java.awt" ]
java.awt;
194,748
@Test public void testBroadcastEventNoRecords() throws Exception { int numberOfChannels = 4; int bufferSize = 32; @SuppressWarnings("unchecked") Queue<BufferConsumer>[] queues = new Queue[numberOfChannels]; for (int i = 0; i < numberOfChannels; i++) { queues[i] = new ArrayDeque<>(); } TestPooledB...
void function() throws Exception { int numberOfChannels = 4; int bufferSize = 32; @SuppressWarnings(STR) Queue<BufferConsumer>[] queues = new Queue[numberOfChannels]; for (int i = 0; i < numberOfChannels; i++) { queues[i] = new ArrayDeque<>(); } TestPooledBufferProvider bufferProvider = new TestPooledBufferProvider(Int...
/** * Tests broadcasting events when no records have been emitted yet. */
Tests broadcasting events when no records have been emitted yet
testBroadcastEventNoRecords
{ "repo_name": "mbode/flink", "path": "flink-runtime/src/test/java/org/apache/flink/runtime/io/network/api/writer/RecordWriterTest.java", "license": "apache-2.0", "size": 21608 }
[ "java.util.ArrayDeque", "java.util.Queue", "org.apache.flink.runtime.checkpoint.CheckpointOptions", "org.apache.flink.runtime.io.network.api.CheckpointBarrier", "org.apache.flink.runtime.io.network.buffer.BufferConsumer", "org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent", "org.apach...
import java.util.ArrayDeque; import java.util.Queue; import org.apache.flink.runtime.checkpoint.CheckpointOptions; import org.apache.flink.runtime.io.network.api.CheckpointBarrier; import org.apache.flink.runtime.io.network.buffer.BufferConsumer; import org.apache.flink.runtime.io.network.partition.consumer.BufferOrEve...
import java.util.*; import org.apache.flink.runtime.checkpoint.*; import org.apache.flink.runtime.io.network.api.*; import org.apache.flink.runtime.io.network.buffer.*; import org.apache.flink.runtime.io.network.partition.consumer.*; import org.apache.flink.runtime.io.network.util.*; import org.junit.*;
[ "java.util", "org.apache.flink", "org.junit" ]
java.util; org.apache.flink; org.junit;
1,762,965
Set<String> getOpenConnectionIds();
Set<String> getOpenConnectionIds();
/** * Return set of connection ids that have not yet addClosedId. * * @return set of open connection ids * @since 1.4.5 */
Return set of connection ids that have not yet addClosedId
getOpenConnectionIds
{ "repo_name": "ttddyy/datasource-proxy", "path": "src/main/java/net/ttddyy/dsproxy/ConnectionIdManager.java", "license": "mit", "size": 620 }
[ "java.util.Set" ]
import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
240,715
private void addDateRangeExample() { add(new WHeading(HeadingLevel.H2, "Example of a date range component")); WFieldSet dateRange = new WFieldSet("Enter the expected arrival and departure dates."); add(dateRange); WPanel dateRangePanel = new WPanel(); dateRangePanel.setLayout(new FlowLayout(FlowLayout.LE...
void function() { add(new WHeading(HeadingLevel.H2, STR)); WFieldSet dateRange = new WFieldSet(STR); add(dateRange); WPanel dateRangePanel = new WPanel(); dateRangePanel.setLayout(new FlowLayout(FlowLayout.LEFT, Size.MEDIUM)); dateRange.add(dateRangePanel); final WDateField arrivalDate = new WDateField(); final WDateFi...
/** * Add date range example. */
Add date range example
addDateRangeExample
{ "repo_name": "ricksbrown/wcomponents", "path": "wcomponents-examples/src/main/java/com/github/bordertech/wcomponents/examples/theme/WDateFieldExample.java", "license": "gpl-3.0", "size": 7877 }
[ "com.github.bordertech.wcomponents.HeadingLevel", "com.github.bordertech.wcomponents.Size", "com.github.bordertech.wcomponents.WDateField", "com.github.bordertech.wcomponents.WFieldSet", "com.github.bordertech.wcomponents.WHeading", "com.github.bordertech.wcomponents.WLabel", "com.github.bordertech.wcom...
import com.github.bordertech.wcomponents.HeadingLevel; import com.github.bordertech.wcomponents.Size; import com.github.bordertech.wcomponents.WDateField; import com.github.bordertech.wcomponents.WFieldSet; import com.github.bordertech.wcomponents.WHeading; import com.github.bordertech.wcomponents.WLabel; import com.gi...
import com.github.bordertech.wcomponents.*; import com.github.bordertech.wcomponents.layout.*; import com.github.bordertech.wcomponents.subordinate.*;
[ "com.github.bordertech" ]
com.github.bordertech;
1,471,620
@Override @GET @Path("/concept/id/{terminology}/{terminologyVersion}/{terminologyId}/children") @ApiOperation(value = "Find concept children.", notes = "Gets a list of search results for each child concept.", response = Concept.class) @Produces({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML ...
@Path(STR) @ApiOperation(value = STR, notes = STR, response = Concept.class) @Produces({ MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML }) SearchResultList function( @ApiParam(value = STR, required = true) @PathParam(STR) String id, @ApiParam(value = STR, required = true) @PathParam(STR) String terminology, @Api...
/** * Find child concepts. * * @param id the id * @param terminology the terminology * @param terminologyVersion the terminology version * @param authToken the auth token * @return the search result list * @throws Exception the exception */
Find child concepts
findChildConcepts
{ "repo_name": "IHTSDO/OTF-Mapping-Service", "path": "rest/src/main/java/org/ihtsdo/otf/mapping/rest/impl/ContentServiceRestImpl.java", "license": "apache-2.0", "size": 104573 }
[ "io.swagger.annotations.ApiOperation", "io.swagger.annotations.ApiParam", "javax.ws.rs.HeaderParam", "javax.ws.rs.Path", "javax.ws.rs.PathParam", "javax.ws.rs.Produces", "javax.ws.rs.core.MediaType", "org.apache.log4j.Logger", "org.ihtsdo.otf.mapping.helpers.MapUserRole", "org.ihtsdo.otf.mapping.h...
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import javax.ws.rs.HeaderParam; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.core.MediaType; import org.apache.log4j.Logger; import org.ihtsdo.otf.mapping.helpers.MapUserRole; im...
import io.swagger.annotations.*; import javax.ws.rs.*; import javax.ws.rs.core.*; import org.apache.log4j.*; import org.ihtsdo.otf.mapping.helpers.*; import org.ihtsdo.otf.mapping.jpa.services.*; import org.ihtsdo.otf.mapping.rf2.*; import org.ihtsdo.otf.mapping.services.*;
[ "io.swagger.annotations", "javax.ws", "org.apache.log4j", "org.ihtsdo.otf" ]
io.swagger.annotations; javax.ws; org.apache.log4j; org.ihtsdo.otf;
1,538,385
@SideOnly(Side.CLIENT) public boolean hasReducedDebug() { return this.hasReducedDebug; }
@SideOnly(Side.CLIENT) boolean function() { return this.hasReducedDebug; }
/** * Whether the "reducedDebugInfo" option is active for this player. */
Whether the "reducedDebugInfo" option is active for this player
hasReducedDebug
{ "repo_name": "dogjaw2233/tiu-s-mod", "path": "build/tmp/recompileMc/sources/net/minecraft/entity/player/EntityPlayer.java", "license": "lgpl-2.1", "size": 90554 }
[ "net.minecraftforge.fml.relauncher.Side", "net.minecraftforge.fml.relauncher.SideOnly" ]
import net.minecraftforge.fml.relauncher.Side; import net.minecraftforge.fml.relauncher.SideOnly;
import net.minecraftforge.fml.relauncher.*;
[ "net.minecraftforge.fml" ]
net.minecraftforge.fml;
1,377,909
@Scheduled(cron = "0 0 0 * * ?") public void removeOldPersistentTokens() { LocalDate now = new LocalDate(); persistentTokenRepository.findByTokenDateBefore(now.minusMonths(1)).stream().forEach(token ->{ log.debug("Deleting token {}", token.getSeries()); User user = token....
@Scheduled(cron = STR) void function() { LocalDate now = new LocalDate(); persistentTokenRepository.findByTokenDateBefore(now.minusMonths(1)).stream().forEach(token ->{ log.debug(STR, token.getSeries()); User user = token.getUser(); user.getPersistentTokens().remove(token); persistentTokenRepository.delete(token); }); ...
/** * Persistent Token are used for providing automatic authentication, they should be automatically deleted after * 30 days. * <p/> * <p> * This is scheduled to get fired everyday, at midnight. * </p> */
Persistent Token are used for providing automatic authentication, they should be automatically deleted after 30 days. This is scheduled to get fired everyday, at midnight.
removeOldPersistentTokens
{ "repo_name": "SaschaMoellering/event-app", "path": "src/main/java/io/autoscaling/eventapp/service/UserService.java", "license": "apache-2.0", "size": 6475 }
[ "io.autoscaling.eventapp.domain.User", "org.joda.time.LocalDate", "org.springframework.scheduling.annotation.Scheduled" ]
import io.autoscaling.eventapp.domain.User; import org.joda.time.LocalDate; import org.springframework.scheduling.annotation.Scheduled;
import io.autoscaling.eventapp.domain.*; import org.joda.time.*; import org.springframework.scheduling.annotation.*;
[ "io.autoscaling.eventapp", "org.joda.time", "org.springframework.scheduling" ]
io.autoscaling.eventapp; org.joda.time; org.springframework.scheduling;
877,484
public boolean addComponentParts(World worldIn, Random randomIn, StructureBoundingBox structureBoundingBoxIn) { if (this.averageGroundLvl < 0) { this.averageGroundLvl = this.getAverageGroundLevel(worldIn, structureBoundingBoxIn); ...
boolean function(World worldIn, Random randomIn, StructureBoundingBox structureBoundingBoxIn) { if (this.averageGroundLvl < 0) { this.averageGroundLvl = this.getAverageGroundLevel(worldIn, structureBoundingBoxIn); if (this.averageGroundLvl < 0) { return true; } this.boundingBox.offset(0, this.averageGroundLvl - this.bo...
/** * second Part of Structure generating, this for example places Spiderwebs, Mob Spawners, it closes * Mineshafts at the end, it adds Fences... */
second Part of Structure generating, this for example places Spiderwebs, Mob Spawners, it closes Mineshafts at the end, it adds Fences..
addComponentParts
{ "repo_name": "Severed-Infinity/technium", "path": "build/tmp/recompileMc/sources/net/minecraft/world/gen/structure/StructureVillagePieces.java", "license": "gpl-3.0", "size": 136529 }
[ "java.util.Random", "net.minecraft.block.BlockStairs", "net.minecraft.block.material.Material", "net.minecraft.block.state.IBlockState", "net.minecraft.init.Blocks", "net.minecraft.util.EnumFacing", "net.minecraft.world.World" ]
import java.util.Random; import net.minecraft.block.BlockStairs; import net.minecraft.block.material.Material; import net.minecraft.block.state.IBlockState; import net.minecraft.init.Blocks; import net.minecraft.util.EnumFacing; import net.minecraft.world.World;
import java.util.*; import net.minecraft.block.*; import net.minecraft.block.material.*; import net.minecraft.block.state.*; import net.minecraft.init.*; import net.minecraft.util.*; import net.minecraft.world.*;
[ "java.util", "net.minecraft.block", "net.minecraft.init", "net.minecraft.util", "net.minecraft.world" ]
java.util; net.minecraft.block; net.minecraft.init; net.minecraft.util; net.minecraft.world;
1,691,388
private void testDelayed(int blobSize, boolean sendZeroSizedBuffers) throws Exception { RequestAndResult requestAndResult = new RequestAndResult(blobSize); requestAndResultsList.add(requestAndResult); MockReadableStreamChannel putChannel = new MockReadableStreamChannel(blobSize, sendZeroSizedBuffers); ...
void function(int blobSize, boolean sendZeroSizedBuffers) throws Exception { RequestAndResult requestAndResult = new RequestAndResult(blobSize); requestAndResultsList.add(requestAndResult); MockReadableStreamChannel putChannel = new MockReadableStreamChannel(blobSize, sendZeroSizedBuffers); FutureResult<String> future ...
/** * Helper method to put a blob with a channel that does not have all the data at once. * @param blobSize the size of the blob to put. * @param sendZeroSizedBuffers whether this test should involve making the channel send zero-sized buffers between * sending data buffers. */
Helper method to put a blob with a channel that does not have all the data at once
testDelayed
{ "repo_name": "xiahome/ambry", "path": "ambry-router/src/test/java/com.github.ambry.router/PutManagerTest.java", "license": "apache-2.0", "size": 45694 }
[ "java.nio.ByteBuffer" ]
import java.nio.ByteBuffer;
import java.nio.*;
[ "java.nio" ]
java.nio;
857,397
ServiceFuture<Void> postOptionalIntegerParameterAsync(Integer bodyParameter, final ServiceCallback<Void> serviceCallback);
ServiceFuture<Void> postOptionalIntegerParameterAsync(Integer bodyParameter, final ServiceCallback<Void> serviceCallback);
/** * Test explicitly optional integer. Please put null. * * @param bodyParameter the Integer value * @param serviceCallback the async ServiceCallback to handle successful and failed responses. * @return the {@link ServiceFuture} object */
Test explicitly optional integer. Please put null
postOptionalIntegerParameterAsync
{ "repo_name": "anudeepsharma/autorest", "path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/requiredoptional/Explicits.java", "license": "mit", "size": 43451 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
775,674
public List<KmeliaPublication> getLinkedPublications(KmeliaPublication publication, String userId);
List<KmeliaPublication> function(KmeliaPublication publication, String userId);
/** * Gets the publications linked with the specified one and for which the specified user is * authorized to access. * * @param publication the publication from which linked publications are get. * @param userId the unique identifier of a user. It allows to check if a linked publication is * accessib...
Gets the publications linked with the specified one and for which the specified user is authorized to access
getLinkedPublications
{ "repo_name": "CecileBONIN/Silverpeas-Components", "path": "kmelia/kmelia-ejb/src/main/java/com/stratelia/webactiv/kmelia/control/ejb/KmeliaBm.java", "license": "agpl-3.0", "size": 25457 }
[ "com.stratelia.webactiv.kmelia.model.KmeliaPublication", "java.util.List" ]
import com.stratelia.webactiv.kmelia.model.KmeliaPublication; import java.util.List;
import com.stratelia.webactiv.kmelia.model.*; import java.util.*;
[ "com.stratelia.webactiv", "java.util" ]
com.stratelia.webactiv; java.util;
2,048,160
public String startLocal() throws IOException, InterruptedException { return jcmd(CMD_START_LOCAL); }
String function() throws IOException, InterruptedException { return jcmd(CMD_START_LOCAL); }
/** * `jcmd <app> ManagementAgent.start_local` * @return The JCMD output * @throws IOException * @throws InterruptedException */
`jcmd ManagementAgent.start_local`
startLocal
{ "repo_name": "FauxFaux/jdk9-jdk", "path": "test/sun/management/jmxremote/startstop/ManagementAgentJcmd.java", "license": "gpl-2.0", "size": 7992 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
911,852
Builder addCondition(Criterion criterion);
Builder addCondition(Criterion criterion);
/** * Add a filtering condition. * * @param criterion new criterion * @return a filtering builder */
Add a filtering condition
addCondition
{ "repo_name": "packet-tracker/onos", "path": "core/api/src/main/java/org/onosproject/net/flowobjective/FilteringObjective.java", "license": "apache-2.0", "size": 4498 }
[ "org.onosproject.net.flow.criteria.Criterion" ]
import org.onosproject.net.flow.criteria.Criterion;
import org.onosproject.net.flow.criteria.*;
[ "org.onosproject.net" ]
org.onosproject.net;
2,656,986
public ResultMatcher isUnavailableForLegalReasons() { return matcher(HttpStatus.valueOf(451)); }
ResultMatcher function() { return matcher(HttpStatus.valueOf(451)); }
/** * Assert the response status code is {@code HttpStatus.UNAVAILABLE_FOR_LEGAL_REASONS} (451). * @since 4.3 */
Assert the response status code is HttpStatus.UNAVAILABLE_FOR_LEGAL_REASONS (451)
isUnavailableForLegalReasons
{ "repo_name": "spring-projects/spring-framework", "path": "spring-test/src/main/java/org/springframework/test/web/servlet/result/StatusResultMatchers.java", "license": "apache-2.0", "size": 17758 }
[ "org.springframework.http.HttpStatus", "org.springframework.test.web.servlet.ResultMatcher" ]
import org.springframework.http.HttpStatus; import org.springframework.test.web.servlet.ResultMatcher;
import org.springframework.http.*; import org.springframework.test.web.servlet.*;
[ "org.springframework.http", "org.springframework.test" ]
org.springframework.http; org.springframework.test;
1,833,025
public void setBirthDate(Date birthDate) { this.birthDate = birthDate; }
void function(Date birthDate) { this.birthDate = birthDate; }
/** * Sets the birth date. * * @param birthDate the new birth date */
Sets the birth date
setBirthDate
{ "repo_name": "tlin-fei/ds4p", "path": "DS4P/consent2share/core/src/main/java/gov/samhsa/consent2share/service/dto/SignupDto.java", "license": "bsd-3-clause", "size": 4330 }
[ "java.util.Date" ]
import java.util.Date;
import java.util.*;
[ "java.util" ]
java.util;
2,558,090
@Function(name = "setInt32", arity = 2) public static Object setInt32(ExecutionContext cx, Object thisValue, Object byteOffset, Object value, Object littleEndian) { SetViewValue(cx, thisValue, byteOffset, littleEndian, ElementType.Int32, value); return UNDEFINED; ...
@Function(name = STR, arity = 2) static Object function(ExecutionContext cx, Object thisValue, Object byteOffset, Object value, Object littleEndian) { SetViewValue(cx, thisValue, byteOffset, littleEndian, ElementType.Int32, value); return UNDEFINED; }
/** * 24.2.4.17 DataView.prototype.setInt32(byteOffset, value [, littleEndian ]) * * @param cx * the execution context * @param thisValue * the function this-value * @param byteOffset * the byte offset * @...
24.2.4.17 DataView.prototype.setInt32(byteOffset, value [, littleEndian ])
setInt32
{ "repo_name": "jugglinmike/es6draft", "path": "src/main/java/com/github/anba/es6draft/runtime/objects/binary/DataViewPrototype.java", "license": "mit", "size": 17368 }
[ "com.github.anba.es6draft.runtime.ExecutionContext", "com.github.anba.es6draft.runtime.internal.Properties", "com.github.anba.es6draft.runtime.objects.binary.DataViewConstructor" ]
import com.github.anba.es6draft.runtime.ExecutionContext; import com.github.anba.es6draft.runtime.internal.Properties; import com.github.anba.es6draft.runtime.objects.binary.DataViewConstructor;
import com.github.anba.es6draft.runtime.*; import com.github.anba.es6draft.runtime.internal.*; import com.github.anba.es6draft.runtime.objects.binary.*;
[ "com.github.anba" ]
com.github.anba;
1,757,075
public static String authAuthEa(String authorField) { String fixedAuthorField = AuthorList.fixAuthorForAlphabetization(authorField); String[] tokens = fixedAuthorField.split("\\s+\\band\\b\\s+"); if (tokens.length == 0) { return ""; } StringBuilder author = new ...
static String function(String authorField) { String fixedAuthorField = AuthorList.fixAuthorForAlphabetization(authorField); String[] tokens = fixedAuthorField.split(STR); if (tokens.length == 0) { return STR,STR,STR.ea"); } return author.toString(); }
/** * auth.auth.ea format: * Isaac Newton and James Maxwell and Albert Einstein (1960) * Isaac Newton and James Maxwell (1960) * give: * Newton.Maxwell.ea * Newton.Maxwell */
auth.auth.ea format: Isaac Newton and James Maxwell and Albert Einstein (1960) Isaac Newton and James Maxwell (1960) give: Newton.Maxwell.ea Newton.Maxwell
authAuthEa
{ "repo_name": "iksmada/DC-UFSCar-ES2-201601-GrupoDilema", "path": "src/main/java/net/sf/jabref/logic/labelpattern/LabelPatternUtil.java", "license": "gpl-2.0", "size": 54874 }
[ "net.sf.jabref.model.entry.AuthorList" ]
import net.sf.jabref.model.entry.AuthorList;
import net.sf.jabref.model.entry.*;
[ "net.sf.jabref" ]
net.sf.jabref;
577,757
public CArray vector(Vector3D vector) { return vector(vector, Target.UNKNOWN); }
CArray function(Vector3D vector) { return vector(vector, Target.UNKNOWN); }
/** * Gets a vector object, given a Vector. * * @param vector the Vector * @return the vector array */
Gets a vector object, given a Vector
vector
{ "repo_name": "itstake/CommandHelper", "path": "src/main/java/com/laytonsmith/core/ObjectGenerator.java", "license": "gpl-3.0", "size": 45822 }
[ "com.laytonsmith.PureUtilities", "com.laytonsmith.core.constructs.CArray", "com.laytonsmith.core.constructs.Target" ]
import com.laytonsmith.PureUtilities; import com.laytonsmith.core.constructs.CArray; import com.laytonsmith.core.constructs.Target;
import com.laytonsmith.*; import com.laytonsmith.core.constructs.*;
[ "com.laytonsmith", "com.laytonsmith.core" ]
com.laytonsmith; com.laytonsmith.core;
324,335
@Auditable(parameters = { "sourceNodeRef", "sourceParentRef", "targetParentRef", "newName" }) public FileInfo moveFrom(NodeRef sourceNodeRef, NodeRef sourceParentRef, NodeRef targetParentRef, String newName) throws FileExistsException, FileNotFoundException;
@Auditable(parameters = { STR, STR, STR, STR }) FileInfo function(NodeRef sourceNodeRef, NodeRef sourceParentRef, NodeRef targetParentRef, String newName) throws FileExistsException, FileNotFoundException;
/** * Move a file or folder to a new name and/or location. * <p> * If both the parent folder and name remain the same, then nothing is done. * <p/> * It is possible to specify <i>which</i> is the parent node when moving nodes; nodes * can reside in multiple locations. * ...
Move a file or folder to a new name and/or location. If both the parent folder and name remain the same, then nothing is done. It is possible to specify which is the parent node when moving nodes; nodes can reside in multiple locations
moveFrom
{ "repo_name": "daniel-he/community-edition", "path": "projects/repository/source/java/org/alfresco/service/cmr/model/FileFolderService.java", "license": "lgpl-3.0", "size": 21841 }
[ "org.alfresco.service.Auditable", "org.alfresco.service.cmr.repository.NodeRef" ]
import org.alfresco.service.Auditable; import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.*; import org.alfresco.service.cmr.repository.*;
[ "org.alfresco.service" ]
org.alfresco.service;
838,650
T visitMultiKeyMessageArgs(@NotNull DuroParser.MultiKeyMessageArgsContext ctx);
T visitMultiKeyMessageArgs(@NotNull DuroParser.MultiKeyMessageArgsContext ctx);
/** * Visit a parse tree produced by {@link DuroParser#multiKeyMessageArgs}. * @param ctx the parse tree * @return the visitor result */
Visit a parse tree produced by <code>DuroParser#multiKeyMessageArgs</code>
visitMultiKeyMessageArgs
{ "repo_name": "jakobehmsen/duro", "path": "eclipse/src/duro/reflang/antlr4/DuroVisitor.java", "license": "mit", "size": 11411 }
[ "org.antlr.v4.runtime.misc.NotNull" ]
import org.antlr.v4.runtime.misc.NotNull;
import org.antlr.v4.runtime.misc.*;
[ "org.antlr.v4" ]
org.antlr.v4;
1,341,105
public double curvature(double t) { return 2 * a / pow(hypot(1, 2 * a * t), 3); } // ========================================================== // methods implementing the ContinuousCurve2D interface
double function(double t) { return 2 * a / pow(hypot(1, 2 * a * t), 3); }
/** * Returns the curvature of the parabola at the given position. */
Returns the curvature of the parabola at the given position
curvature
{ "repo_name": "pokowaka/android-geom", "path": "geom/src/main/java/math/geom2d/conic/Parabola2D.java", "license": "lgpl-2.1", "size": 20182 }
[ "java.lang.Math" ]
import java.lang.Math;
import java.lang.*;
[ "java.lang" ]
java.lang;
1,325,570
public List<ItemDTO> getRelations(Long id, String system) { Session session = StoreHibernateUtil.getSessionFactory().openSession(); try { List<ItemDTO> results = executeRelationQuery(session, getFirstRelationQueryString(system), id, system); LOGGER.debug("Number of Results Q1: {}", results.size());...
List<ItemDTO> function(Long id, String system) { Session session = StoreHibernateUtil.getSessionFactory().openSession(); try { List<ItemDTO> results = executeRelationQuery(session, getFirstRelationQueryString(system), id, system); LOGGER.debug(STR, results.size()); Set<ItemDTO> items = new HashSet<ItemDTO>(results); re...
/** * Get the relations by the id * * @param id The id * @param system The system to filter the relation on if it exists * @return The list of related items */
Get the relations by the id
getRelations
{ "repo_name": "anu-doi/metadata-stores", "path": "store/src/main/java/au/edu/anu/metadatastores/store/search/SearchService.java", "license": "gpl-3.0", "size": 9692 }
[ "au.edu.anu.metadatastores.services.store.StoreHibernateUtil", "java.util.HashSet", "java.util.List", "java.util.Set", "org.hibernate.Session" ]
import au.edu.anu.metadatastores.services.store.StoreHibernateUtil; import java.util.HashSet; import java.util.List; import java.util.Set; import org.hibernate.Session;
import au.edu.anu.metadatastores.services.store.*; import java.util.*; import org.hibernate.*;
[ "au.edu.anu", "java.util", "org.hibernate" ]
au.edu.anu; java.util; org.hibernate;
1,549,070
public static void main(String[] args) { testX(); // FIXME move after parseArgs() and set graphicsEnv if text selected // will need to test SelfExtractor and comment parseArgs() to ensure // no side effects in the future. SelfExtractor extractor = null; try { boolean verbose = false; extractor = new ...
static void function(String[] args) { testX(); SelfExtractor extractor = null; try { boolean verbose = false; extractor = new SelfExtractor(); extractor.init(); extractor.extract(verbose, graphicsEnv); } catch (Exception e) { e.printStackTrace(); String tempDir = STR; if(extractor != null){ tempDir = extractor.getExtra...
/** * Run method to use from the command line. This is fired via an entry in the * MANIFEST.MF in the Jar *@param args The command line arguments */
Run method to use from the command line. This is fired via an entry in the MANIFEST.MF in the Jar
main
{ "repo_name": "neoautus/lucidj", "path": "extras/AntInstaller/AntInstaller-beta0.8/src/org/tp23/antinstaller/selfextract/SelfExtractor.java", "license": "apache-2.0", "size": 14252 }
[ "org.tp23.antinstaller.InstallException", "org.tp23.antinstaller.runtime.ExecInstall", "org.tp23.antinstaller.runtime.exe.FilterChain", "org.tp23.antinstaller.runtime.exe.FilterFactory" ]
import org.tp23.antinstaller.InstallException; import org.tp23.antinstaller.runtime.ExecInstall; import org.tp23.antinstaller.runtime.exe.FilterChain; import org.tp23.antinstaller.runtime.exe.FilterFactory;
import org.tp23.antinstaller.*; import org.tp23.antinstaller.runtime.*; import org.tp23.antinstaller.runtime.exe.*;
[ "org.tp23.antinstaller" ]
org.tp23.antinstaller;
286,759
synchronized void putBlock(Callable<?> block,String key) { mFutures.put(key, mService.submit(block)); }
synchronized void putBlock(Callable<?> block,String key) { mFutures.put(key, mService.submit(block)); }
/** * Puts a block into the Queue and saves the futures for future references, the caller is responsible for keeping the keys unique. * @param block the block to push. * @param key the key to save the future with. */
Puts a block into the Queue and saves the futures for future references, the caller is responsible for keeping the keys unique
putBlock
{ "repo_name": "johanrisch/ezRest", "path": "ezrest/src/main/java/evertsson/risch/ezDispatch/ezThread.java", "license": "mit", "size": 1849 }
[ "java.util.concurrent.Callable" ]
import java.util.concurrent.Callable;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
2,563,157
@Override public Enumeration<String> getAttributeNames() { Vector<String> v = new Vector<String>(); v.addAll(m_attributes.keySet()); return v.elements(); }
Enumeration<String> function() { Vector<String> v = new Vector<String>(); v.addAll(m_attributes.keySet()); return v.elements(); }
/** * Return the names of all defined request attributes for this request.<p> * * @return the names of all defined request attributes for this request * * @see javax.servlet.ServletRequest#getAttributeNames */
Return the names of all defined request attributes for this request
getAttributeNames
{ "repo_name": "alkacon/opencms-core", "path": "src/org/opencms/flex/CmsFlexRequest.java", "license": "lgpl-2.1", "size": 32251 }
[ "java.util.Enumeration", "java.util.Vector" ]
import java.util.Enumeration; import java.util.Vector;
import java.util.*;
[ "java.util" ]
java.util;
852,284
public void initTable(final int totalCount, final PaginationListner paginationListner, final List<Record> recordList, final SelectionHandlers selectHandler, final boolean fireEventForFirstRow, final OrderingListner orderingListner, final boolean isOrderedEntity) { initTable(totalCount, paginationListner, rec...
void function(final int totalCount, final PaginationListner paginationListner, final List<Record> recordList, final SelectionHandlers selectHandler, final boolean fireEventForFirstRow, final OrderingListner orderingListner, final boolean isOrderedEntity) { initTable(totalCount, paginationListner, recordList, selectHand...
/** * Creates the table with the given record list. * * @param totalCount int. The size of record list. * @param paginationListner {@link PaginationListner} The instance of PaginationListner. * @param recordList {@link List} <{@link Record}> The list of records. * @param selectHandler {@link SelectionHan...
Creates the table with the given record list
initTable
{ "repo_name": "ungerik/ephesoft", "path": "Ephesoft_Community_Release_4.0.2.0/source/dcma-gwt/dcma-gwt-core/src/main/java/com/ephesoft/dcma/gwt/core/client/ui/table/ListView.java", "license": "agpl-3.0", "size": 18741 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,369,666
public void subscribeToPermission(String permission, Permissible permissible);
void function(String permission, Permissible permissible);
/** * Subscribes the given Permissible for information about the requested * Permission, by name. * <p> * If the specified Permission changes in any form, the Permissible will * be asked to recalculate. * * @param permission Permission to subscribe to * @param permissible Permiss...
Subscribes the given Permissible for information about the requested Permission, by name. If the specified Permission changes in any form, the Permissible will be asked to recalculate
subscribeToPermission
{ "repo_name": "GlowstoneMC/Glowkit-Legacy", "path": "src/main/java/org/bukkit/plugin/PluginManager.java", "license": "gpl-3.0", "size": 9553 }
[ "org.bukkit.permissions.Permissible" ]
import org.bukkit.permissions.Permissible;
import org.bukkit.permissions.*;
[ "org.bukkit.permissions" ]
org.bukkit.permissions;
1,204,253
public AttributeTable getAuthAttrs() { if (authAttrs == null) { return null; } return new AttributeTable(authAttrs); }
AttributeTable function() { if (authAttrs == null) { return null; } return new AttributeTable(authAttrs); }
/** * return a table of the digested attributes indexed by * the OID of the attribute. */
return a table of the digested attributes indexed by the OID of the attribute
getAuthAttrs
{ "repo_name": "sake/bouncycastle-java", "path": "src/org/bouncycastle/cms/CMSAuthenticatedData.java", "license": "mit", "size": 8766 }
[ "org.bouncycastle.asn1.cms.AttributeTable" ]
import org.bouncycastle.asn1.cms.AttributeTable;
import org.bouncycastle.asn1.cms.*;
[ "org.bouncycastle.asn1" ]
org.bouncycastle.asn1;
1,824,439
//// generic methods public static Object newGroupInParallel(String className, Class<?>[] genericParameters, Object[][] params) throws ClassNotFoundException, ClassNotReifiableException, ActiveObjectCreationException, NodeException { Node[] nodeList = new Node[1]; nodeLi...
static Object function(String className, Class<?>[] genericParameters, Object[][] params) throws ClassNotFoundException, ClassNotReifiableException, ActiveObjectCreationException, NodeException { Node[] nodeList = new Node[1]; nodeList[0] = NodeFactory.getDefaultNode(); return PAGroup.newGroupInParallel(className, gene...
/** * Creates an object representing a group (a typed group) and creates members on the default node. * @param className the name of the (upper) class of the group's member. * @param params the array that contain the parameters used to build the group's member. * If <code>params</code> is <code>null...
Creates an object representing a group (a typed group) and creates members on the default node
newGroupInParallel
{ "repo_name": "lpellegr/programming", "path": "programming-core/src/main/java/org/objectweb/proactive/api/PAGroup.java", "license": "agpl-3.0", "size": 79338 }
[ "org.objectweb.proactive.ActiveObjectCreationException", "org.objectweb.proactive.core.mop.ClassNotReifiableException", "org.objectweb.proactive.core.node.Node", "org.objectweb.proactive.core.node.NodeException", "org.objectweb.proactive.core.node.NodeFactory" ]
import org.objectweb.proactive.ActiveObjectCreationException; import org.objectweb.proactive.core.mop.ClassNotReifiableException; import org.objectweb.proactive.core.node.Node; import org.objectweb.proactive.core.node.NodeException; import org.objectweb.proactive.core.node.NodeFactory;
import org.objectweb.proactive.*; import org.objectweb.proactive.core.mop.*; import org.objectweb.proactive.core.node.*;
[ "org.objectweb.proactive" ]
org.objectweb.proactive;
1,769,606
public static final <T extends ImageView> T gray(final Fragment root, final int id) { return gray(root.getActivity(), id); }
static final <T extends ImageView> T function(final Fragment root, final int id) { return gray(root.getActivity(), id); }
/** * Find view and change it color matrix to gray-scale mode. Emulate effect of none enabled button. * * @param root parent instance * @param id unique identifier of the view * @return found view instance. */
Find view and change it color matrix to gray-scale mode. Emulate effect of none enabled button
gray
{ "repo_name": "OleksandrKucherenko/spacefish", "path": "_libs/artfulbits-sdk/src/main/com/artfulbits/utils/Use.java", "license": "mit", "size": 46048 }
[ "android.support.v4.app.Fragment", "android.widget.ImageView" ]
import android.support.v4.app.Fragment; import android.widget.ImageView;
import android.support.v4.app.*; import android.widget.*;
[ "android.support", "android.widget" ]
android.support; android.widget;
154,573
private JSONObject fetchJSONFromUrl(String urlString) throws JSONException { BufferedReader reader = null; try { URLConnection urlConnection = new URL(urlString).openConnection(); reader = new BufferedReader(new InputStreamReader( urlConnection.getInputStr...
JSONObject function(String urlString) throws JSONException { BufferedReader reader = null; try { URLConnection urlConnection = new URL(urlString).openConnection(); reader = new BufferedReader(new InputStreamReader( urlConnection.getInputStream(), STR)); StringBuilder sb = new StringBuilder(); String line; while ((line ...
/** * Download a JSON file from a server, parse the content and return the JSON * object. * * @return result JSONObject containing the parsed representation. */
Download a JSON file from a server, parse the content and return the JSON object
fetchJSONFromUrl
{ "repo_name": "DMCsys/smartalkaudio", "path": "storage/UniversalMusicPlayer_v01/mobile/src/main/java/com/example/android/uamp/model/RemoteJSONSource.java", "license": "gpl-3.0", "size": 6483 }
[ "com.example.android.uamp.utils.LogHelper", "java.io.BufferedReader", "java.io.IOException", "java.io.InputStreamReader", "java.net.URLConnection", "org.json.JSONException", "org.json.JSONObject" ]
import com.example.android.uamp.utils.LogHelper; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.net.URLConnection; import org.json.JSONException; import org.json.JSONObject;
import com.example.android.uamp.utils.*; import java.io.*; import java.net.*; import org.json.*;
[ "com.example.android", "java.io", "java.net", "org.json" ]
com.example.android; java.io; java.net; org.json;
1,831,279
@Test public void testPublicCloneable() { XYDrawableAnnotation a1 = new XYDrawableAnnotation(10.0, 20.0, 100.0, 200.0, new TestDrawable()); assertTrue(a1 instanceof PublicCloneable); }
void function() { XYDrawableAnnotation a1 = new XYDrawableAnnotation(10.0, 20.0, 100.0, 200.0, new TestDrawable()); assertTrue(a1 instanceof PublicCloneable); }
/** * Checks that this class implements PublicCloneable. */
Checks that this class implements PublicCloneable
testPublicCloneable
{ "repo_name": "greearb/jfreechart-fse-ct", "path": "src/test/java/org/jfree/chart/annotations/XYDrawableAnnotationTest.java", "license": "lgpl-2.1", "size": 7715 }
[ "org.jfree.chart.util.PublicCloneable", "org.junit.Assert" ]
import org.jfree.chart.util.PublicCloneable; import org.junit.Assert;
import org.jfree.chart.util.*; import org.junit.*;
[ "org.jfree.chart", "org.junit" ]
org.jfree.chart; org.junit;
405,513
getViewService().createNode(element, view, SysMLGraphicalTypes.LABEL_SYSML_DIMENSION_NAME_ID, ViewUtil.APPEND, persisted, getPreferencesHint()); // this action needs to be done after the compartments creation super.decorateView(containerView, view, element, semanticHint, index, persisted); } // Start of user co...
getViewService().createNode(element, view, SysMLGraphicalTypes.LABEL_SYSML_DIMENSION_NAME_ID, ViewUtil.APPEND, persisted, getPreferencesHint()); super.decorateView(containerView, view, element, semanticHint, index, persisted); }
/** * Creates Dimension view and add Label and Compartment nodes */
Creates Dimension view and add Label and Compartment nodes
decorateView
{ "repo_name": "bmaggi/Papyrus-SysML11", "path": "plugins/diagram/org.eclipse.papyrus.sysml.diagram.common/src-gen/org/eclipse/papyrus/sysml/diagram/common/factory/DimensionClassifierViewFactory.java", "license": "epl-1.0", "size": 1515 }
[ "org.eclipse.gmf.runtime.diagram.core.util.ViewUtil", "org.eclipse.papyrus.sysml.diagram.common.utils.SysMLGraphicalTypes" ]
import org.eclipse.gmf.runtime.diagram.core.util.ViewUtil; import org.eclipse.papyrus.sysml.diagram.common.utils.SysMLGraphicalTypes;
import org.eclipse.gmf.runtime.diagram.core.util.*; import org.eclipse.papyrus.sysml.diagram.common.utils.*;
[ "org.eclipse.gmf", "org.eclipse.papyrus" ]
org.eclipse.gmf; org.eclipse.papyrus;
2,123,793
public SearchResultsDTO search(final String search) { final ProcessGroup rootGroup = flowController.getGroup(flowController.getRootGroupId()); final SearchResultsDTO results = new SearchResultsDTO(); search(results, search, rootGroup); return results; }
SearchResultsDTO function(final String search) { final ProcessGroup rootGroup = flowController.getGroup(flowController.getRootGroupId()); final SearchResultsDTO results = new SearchResultsDTO(); search(results, search, rootGroup); return results; }
/** * Searches this controller for the specified term. * * @param search search * @return result */
Searches this controller for the specified term
search
{ "repo_name": "InspurUSA/nifi", "path": "nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/controller/ControllerFacade.java", "license": "apache-2.0", "size": 86923 }
[ "org.apache.nifi.groups.ProcessGroup", "org.apache.nifi.web.api.dto.search.SearchResultsDTO" ]
import org.apache.nifi.groups.ProcessGroup; import org.apache.nifi.web.api.dto.search.SearchResultsDTO;
import org.apache.nifi.groups.*; import org.apache.nifi.web.api.dto.search.*;
[ "org.apache.nifi" ]
org.apache.nifi;
1,286,771
interface RemovalListener<K, V> { void onRemoval(RemovalNotification<K, V> notification); } static final class RemovalNotification<K, V> extends ImmutableEntry<K, V> { private static final long serialVersionUID = 0; private final RemovalCause cause; RemovalNotification(@Nullable K key, ...
interface RemovalListener<K, V> { void onRemoval(RemovalNotification<K, V> notification); } static final class RemovalNotification<K, V> extends ImmutableEntry<K, V> { private static final long serialVersionUID = 0; private final RemovalCause cause; RemovalNotification(@Nullable K key, @Nullable V value, RemovalCause c...
/** * Notifies the listener that a removal occurred at some point in the past. */
Notifies the listener that a removal occurred at some point in the past
onRemoval
{ "repo_name": "10xEngineer/My-Wallet-Android", "path": "src/com/google/common/collect/MapMaker.java", "license": "gpl-3.0", "size": 36715 }
[ "javax.annotation.Nullable" ]
import javax.annotation.Nullable;
import javax.annotation.*;
[ "javax.annotation" ]
javax.annotation;
2,689,593
@Test public void checkSearchingVariantSetsReturnsSome() throws AvroRemoteException { final SearchVariantSetsRequest req = SearchVariantSetsRequest.newBuilder().setDatasetId(TestData.getDatasetId()).build(); final SearchVariantSetsResponse resp = client.variants.searchVariantSets(req...
void function() throws AvroRemoteException { final SearchVariantSetsRequest req = SearchVariantSetsRequest.newBuilder().setDatasetId(TestData.getDatasetId()).build(); final SearchVariantSetsResponse resp = client.variants.searchVariantSets(req); final List<VariantSet> sets = resp.getVariantSets(); assertThat(sets).isNo...
/** * Fetch variant sets and make sure we get some. * * @throws AvroRemoteException if there's a communication problem or server exception ({@link GAException}) */
Fetch variant sets and make sure we get some
checkSearchingVariantSetsReturnsSome
{ "repo_name": "hjellinek/compliance", "path": "cts-java/src/test/java/org/ga4gh/cts/api/variants/VariantSetsSearchIT.java", "license": "apache-2.0", "size": 3371 }
[ "java.util.List", "org.apache.avro.AvroRemoteException", "org.assertj.core.api.Assertions", "org.ga4gh.cts.api.TestData", "org.ga4gh.methods.SearchVariantSetsRequest", "org.ga4gh.methods.SearchVariantSetsResponse", "org.ga4gh.models.VariantSet" ]
import java.util.List; import org.apache.avro.AvroRemoteException; import org.assertj.core.api.Assertions; import org.ga4gh.cts.api.TestData; import org.ga4gh.methods.SearchVariantSetsRequest; import org.ga4gh.methods.SearchVariantSetsResponse; import org.ga4gh.models.VariantSet;
import java.util.*; import org.apache.avro.*; import org.assertj.core.api.*; import org.ga4gh.cts.api.*; import org.ga4gh.methods.*; import org.ga4gh.models.*;
[ "java.util", "org.apache.avro", "org.assertj.core", "org.ga4gh.cts", "org.ga4gh.methods", "org.ga4gh.models" ]
java.util; org.apache.avro; org.assertj.core; org.ga4gh.cts; org.ga4gh.methods; org.ga4gh.models;
2,407,555
EAttribute getException_Name();
EAttribute getException_Name();
/** * Returns the meta object for the attribute '{@link com.mguidi.soa.soa.Exception#getName <em>Name</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the attribute '<em>Name</em>'. * @see com.mguidi.soa.soa.Exception#getName() * @see #getException() * @genera...
Returns the meta object for the attribute '<code>com.mguidi.soa.soa.Exception#getName Name</code>'.
getException_Name
{ "repo_name": "mguidi/SOA-Code-Factory", "path": "com.mguidi.soa/src-gen/com/mguidi/soa/soa/SoaPackage.java", "license": "apache-2.0", "size": 49882 }
[ "org.eclipse.emf.ecore.EAttribute" ]
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
398,849
public Screen getScreen() { return screen; }
Screen function() { return screen; }
/** * Returns the screen of this raspi lcd. * * @return the screen */
Returns the screen of this raspi lcd
getScreen
{ "repo_name": "GerritK/RaspiLCD-K", "path": "Core/src/net/gerritk/raspberry/lcd/RaspiLCD.java", "license": "apache-2.0", "size": 8611 }
[ "net.gerritk.raspberry.lcd.interfaces.Screen" ]
import net.gerritk.raspberry.lcd.interfaces.Screen;
import net.gerritk.raspberry.lcd.interfaces.*;
[ "net.gerritk.raspberry" ]
net.gerritk.raspberry;
1,755,311
private static List<String> getProtocols() { if (JavaVersion.current().compareTo(JavaVersion.parse("12")) < 0) { return List.of("TLSv1.2"); } else { JavaVersion full = AccessController.doPrivileged( (PrivilegedAction<JavaVersion>) () -> Jav...
static List<String> function() { if (JavaVersion.current().compareTo(JavaVersion.parse("12")) < 0) { return List.of(STR); } else { JavaVersion full = AccessController.doPrivileged( (PrivilegedAction<JavaVersion>) () -> JavaVersion.parse(System.getProperty(STR))); if (full.compareTo(JavaVersion.parse(STR)) < 0) { return...
/** * The {@link HttpsServer} in the JDK has issues with TLSv1.3 when running in a JDK prior to * 12.0.1 so we pin to TLSv1.2 when running on an earlier JDK */
The <code>HttpsServer</code> in the JDK has issues with TLSv1.3 when running in a JDK prior to 12.0.1 so we pin to TLSv1.2 when running on an earlier JDK
getProtocols
{ "repo_name": "robin13/elasticsearch", "path": "x-pack/plugin/monitoring/src/internalClusterTest/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterSslIT.java", "license": "apache-2.0", "size": 10035 }
[ "java.security.AccessController", "java.security.PrivilegedAction", "java.util.List", "org.elasticsearch.bootstrap.JavaVersion", "org.elasticsearch.xpack.core.XPackSettings" ]
import java.security.AccessController; import java.security.PrivilegedAction; import java.util.List; import org.elasticsearch.bootstrap.JavaVersion; import org.elasticsearch.xpack.core.XPackSettings;
import java.security.*; import java.util.*; import org.elasticsearch.bootstrap.*; import org.elasticsearch.xpack.core.*;
[ "java.security", "java.util", "org.elasticsearch.bootstrap", "org.elasticsearch.xpack" ]
java.security; java.util; org.elasticsearch.bootstrap; org.elasticsearch.xpack;
2,192,979
public JsonWriter value(double value) throws IOException { if (Double.isNaN(value) || Double.isInfinite(value)) { throw new IllegalArgumentException("Numeric values must be finite, but was " + value); } writeDeferredName(); beforeValue(false); out.appe...
JsonWriter function(double value) throws IOException { if (Double.isNaN(value) Double.isInfinite(value)) { throw new IllegalArgumentException(STR + value); } writeDeferredName(); beforeValue(false); out.append(Double.toString(value)); return this; }
/** * Encodes {@code value}. * * @param value a finite value. May not be {@link Double#isNaN() NaNs} or * {@link Double#isInfinite() infinities}. * @return this writer. */
Encodes value
value
{ "repo_name": "michal-skrabacz/gson-realm", "path": "gson-realm/src/main/java/com/google/gson/stream/JsonWriter.java", "license": "apache-2.0", "size": 20675 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
803,073
protected QueryResponse query(SolrParams params) throws Exception { return query(true, params); } /** * Returns the QueryResponse from {@link #queryServer}
QueryResponse function(SolrParams params) throws Exception { return query(true, params); } /** * Returns the QueryResponse from {@link #queryServer}
/** * Sets distributed params. * Returns the QueryResponse from {@link #queryServer}, */
Sets distributed params. Returns the QueryResponse from <code>#queryServer</code>
query
{ "repo_name": "pengzong1111/solr4", "path": "solr/test-framework/src/java/org/apache/solr/BaseDistributedSearchTestCase.java", "license": "apache-2.0", "size": 30764 }
[ "org.apache.solr.client.solrj.response.QueryResponse", "org.apache.solr.common.params.SolrParams" ]
import org.apache.solr.client.solrj.response.QueryResponse; import org.apache.solr.common.params.SolrParams;
import org.apache.solr.client.solrj.response.*; import org.apache.solr.common.params.*;
[ "org.apache.solr" ]
org.apache.solr;
2,695,399
public static Bitmap takeScreenshot(Activity activity) { View view = activity.getWindow().getDecorView(); view.setDrawingCacheEnabled(true); view.buildDrawingCache(); Bitmap bitmap = view.getDrawingCache(); Rect rect = new Rect(); activity.getWindow().getDecorView().getWindowVisibleDisplayFrame(rect); ...
static Bitmap function(Activity activity) { View view = activity.getWindow().getDecorView(); view.setDrawingCacheEnabled(true); view.buildDrawingCache(); Bitmap bitmap = view.getDrawingCache(); Rect rect = new Rect(); activity.getWindow().getDecorView().getWindowVisibleDisplayFrame(rect); int statusBarHeight = rect.top...
/** * Take screenshot without status bar. * * @param activity * @return screenshot bitmap. */
Take screenshot without status bar
takeScreenshot
{ "repo_name": "usersource/anno", "path": "anno_app/platforms/android/src/io/usersource/annoplugin/utils/AnnoUtils.java", "license": "mpl-2.0", "size": 16307 }
[ "android.app.Activity", "android.graphics.Bitmap", "android.graphics.Rect", "android.view.View" ]
import android.app.Activity; import android.graphics.Bitmap; import android.graphics.Rect; import android.view.View;
import android.app.*; import android.graphics.*; import android.view.*;
[ "android.app", "android.graphics", "android.view" ]
android.app; android.graphics; android.view;
2,758,404
public static void translateRightHandeSide(HasReplaceableChildren element, ColumnType type, Map<String, Object> parameters) { ValidateArgument.required(element, "element"); ValidateArgument.required(type, "type"); ValidateArgument.required(parameters, "parameters"); if(element.getFirstElementOfType(I...
static void function(HasReplaceableChildren element, ColumnType type, Map<String, Object> parameters) { ValidateArgument.required(element, STR); ValidateArgument.required(type, "type"); ValidateArgument.required(parameters, STR); if(element.getFirstElementOfType(IntervalLiteral.class) != null){ return; } if(element.isI...
/** * Translate the right-hand-side of a predicate. * * Translate user generated queries to queries that can * run against the actual database. * * @param element * @param type * @param parameters */
Translate the right-hand-side of a predicate. Translate user generated queries to queries that can run against the actual database
translateRightHandeSide
{ "repo_name": "Sage-Bionetworks/Synapse-Repository-Services", "path": "lib/lib-table-cluster/src/main/java/org/sagebionetworks/table/cluster/SQLTranslatorUtils.java", "license": "apache-2.0", "size": 44697 }
[ "java.util.Map", "org.sagebionetworks.repo.model.table.ColumnType", "org.sagebionetworks.table.query.model.HasReplaceableChildren", "org.sagebionetworks.table.query.model.IntervalLiteral", "org.sagebionetworks.table.query.model.MySqlFunction", "org.sagebionetworks.table.query.model.StringOverride", "org...
import java.util.Map; import org.sagebionetworks.repo.model.table.ColumnType; import org.sagebionetworks.table.query.model.HasReplaceableChildren; import org.sagebionetworks.table.query.model.IntervalLiteral; import org.sagebionetworks.table.query.model.MySqlFunction; import org.sagebionetworks.table.query.model.String...
import java.util.*; import org.sagebionetworks.repo.model.table.*; import org.sagebionetworks.table.query.model.*; import org.sagebionetworks.util.*;
[ "java.util", "org.sagebionetworks.repo", "org.sagebionetworks.table", "org.sagebionetworks.util" ]
java.util; org.sagebionetworks.repo; org.sagebionetworks.table; org.sagebionetworks.util;
1,056,919
public void unregisterAnnotation(Class<? extends Annotation> anno);
void function(Class<? extends Annotation> anno);
/** * Unregisters given annotation. * <p> * By default, if an registered annotation is unregistered, its validator * will also be unregistered. * * @param anno * the object class of annotation need to be unregistered */
Unregisters given annotation. By default, if an registered annotation is unregistered, its validator will also be unregistered
unregisterAnnotation
{ "repo_name": "haint/jgentle", "path": "src/org/jgentleframework/core/handling/AnnotationRegister.java", "license": "apache-2.0", "size": 4952 }
[ "java.lang.annotation.Annotation" ]
import java.lang.annotation.Annotation;
import java.lang.annotation.*;
[ "java.lang" ]
java.lang;
242,693
public BulkProcessor add(ActionRequest<?> request) { return add(request, null); }
BulkProcessor function(ActionRequest<?> request) { return add(request, null); }
/** * Adds either a delete or an index request. */
Adds either a delete or an index request
add
{ "repo_name": "xuzha/elasticsearch", "path": "core/src/main/java/org/elasticsearch/action/bulk/BulkProcessor.java", "license": "apache-2.0", "size": 13420 }
[ "org.elasticsearch.action.ActionRequest" ]
import org.elasticsearch.action.ActionRequest;
import org.elasticsearch.action.*;
[ "org.elasticsearch.action" ]
org.elasticsearch.action;
1,107,961
public void propertyChange(PropertyChangeEvent e) { changed = true; // forward event to listeners firePropertyChange(e.getPropertyName(), e.getOldValue(), e.getNewValue()); }
void function(PropertyChangeEvent e) { changed = true; firePropertyChange(e.getPropertyName(), e.getOldValue(), e.getNewValue()); }
/** * Listens for property change events from XMLTable. * * @param e the property change event */
Listens for property change events from XMLTable
propertyChange
{ "repo_name": "OpenSourcePhysics/osp", "path": "src/org/opensourcephysics/controls/XMLTableInspector.java", "license": "gpl-3.0", "size": 5883 }
[ "java.beans.PropertyChangeEvent" ]
import java.beans.PropertyChangeEvent;
import java.beans.*;
[ "java.beans" ]
java.beans;
1,163,626
private static List<ImmutableBytesWritable> getRegionStartKeys(List<RegionLocator> regionLocators, boolean writeMultipleTables) throws IOException { ArrayList<ImmutableBytesWritable> ret = new ArrayList<>(); for(RegionLocator regionLo...
static List<ImmutableBytesWritable> function(List<RegionLocator> regionLocators, boolean writeMultipleTables) throws IOException { ArrayList<ImmutableBytesWritable> ret = new ArrayList<>(); for(RegionLocator regionLocator : regionLocators) { TableName tableName = regionLocator.getName(); LOG.info(STR + tableName); byte...
/** * Return the start keys of all of the regions in this table, * as a list of ImmutableBytesWritable. */
Return the start keys of all of the regions in this table, as a list of ImmutableBytesWritable
getRegionStartKeys
{ "repo_name": "HubSpot/hbase", "path": "hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/HFileOutputFormat2.java", "license": "apache-2.0", "size": 44108 }
[ "java.io.IOException", "java.util.ArrayList", "java.util.List", "org.apache.hadoop.hbase.TableName", "org.apache.hadoop.hbase.client.RegionLocator", "org.apache.hadoop.hbase.io.ImmutableBytesWritable", "org.apache.hadoop.hbase.util.Bytes" ]
import java.io.IOException; import java.util.ArrayList; import java.util.List; import org.apache.hadoop.hbase.TableName; import org.apache.hadoop.hbase.client.RegionLocator; import org.apache.hadoop.hbase.io.ImmutableBytesWritable; import org.apache.hadoop.hbase.util.Bytes;
import java.io.*; import java.util.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.io.*; import org.apache.hadoop.hbase.util.*;
[ "java.io", "java.util", "org.apache.hadoop" ]
java.io; java.util; org.apache.hadoop;
831,434
@Nullable public WorkbookPivotTable put(@Nonnull final WorkbookPivotTable newWorkbookPivotTable) throws ClientException { return send(HttpMethod.PUT, newWorkbookPivotTable); }
WorkbookPivotTable function(@Nonnull final WorkbookPivotTable newWorkbookPivotTable) throws ClientException { return send(HttpMethod.PUT, newWorkbookPivotTable); }
/** * Creates a WorkbookPivotTable with a new object * * @param newWorkbookPivotTable the object to create/update * @return the created WorkbookPivotTable * @throws ClientException this exception occurs if the request was unable to complete for any reason */
Creates a WorkbookPivotTable with a new object
put
{ "repo_name": "microsoftgraph/msgraph-sdk-java", "path": "src/main/java/com/microsoft/graph/requests/WorkbookPivotTableRequest.java", "license": "mit", "size": 6172 }
[ "com.microsoft.graph.core.ClientException", "com.microsoft.graph.http.HttpMethod", "com.microsoft.graph.models.WorkbookPivotTable", "javax.annotation.Nonnull" ]
import com.microsoft.graph.core.ClientException; import com.microsoft.graph.http.HttpMethod; import com.microsoft.graph.models.WorkbookPivotTable; import javax.annotation.Nonnull;
import com.microsoft.graph.core.*; import com.microsoft.graph.http.*; import com.microsoft.graph.models.*; import javax.annotation.*;
[ "com.microsoft.graph", "javax.annotation" ]
com.microsoft.graph; javax.annotation;
632,838
public void setPopupSize(Point size) { popup.setPopupSize(size); }
void function(Point size) { popup.setPopupSize(size); }
/** * Set the size, in pixels, of the content proposal popup. This size will be used the next time the content proposal * popup is opened. * * @param size * a Point specifying the desired width and height, in pixels, of the content proposal popup. */
Set the size, in pixels, of the content proposal popup. This size will be used the next time the content proposal popup is opened
setPopupSize
{ "repo_name": "fqqb/yamcs-studio", "path": "bundles/org.csstudio.autocomplete/src/org/csstudio/autocomplete/ui/content/ContentProposalAdapter.java", "license": "epl-1.0", "size": 42143 }
[ "org.eclipse.swt.graphics.Point" ]
import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.graphics.*;
[ "org.eclipse.swt" ]
org.eclipse.swt;
2,503,875
public ForumBoard getBoard(int boardid) throws ScriptException { throw new ScriptException(); }
ForumBoard function(int boardid) throws ScriptException { throw new ScriptException(); }
/** * Returns a ForumBoard object of the given board ID, if nothing is found it returns null. * * @param boardid the board ID * @return ForumBoard object, null if nothing was found. * @see ForumBoard * @throws ScriptException if the fun...
Returns a ForumBoard object of the given board ID, if nothing is found it returns null
getBoard
{ "repo_name": "craftfire/Bifrost", "path": "src/main/java/com/craftfire/bifrost/classes/forum/ForumScript.java", "license": "lgpl-3.0", "size": 18872 }
[ "com.craftfire.bifrost.exceptions.ScriptException" ]
import com.craftfire.bifrost.exceptions.ScriptException;
import com.craftfire.bifrost.exceptions.*;
[ "com.craftfire.bifrost" ]
com.craftfire.bifrost;
1,395,281
public List<String> getPaymentRequestUrls() { ArrayList<String> urls = new ArrayList<>(); while (true) { int i = urls.size(); String paramName = FIELD_PAYMENT_REQUEST_URL + (i > 0 ? Integer.toString(i) : ""); String url = (String) parameterMap.get(paramName); ...
List<String> function() { ArrayList<String> urls = new ArrayList<>(); while (true) { int i = urls.size(); String paramName = FIELD_PAYMENT_REQUEST_URL + (i > 0 ? Integer.toString(i) : ""); String url = (String) parameterMap.get(paramName); if (url == null) break; urls.add(url); } Collections.reverse(urls); return urls;...
/** * Returns the URLs where a payment request (as specified in BIP 70) may be fetched. The first URL is the main URL, * all subsequent URLs are fallbacks. */
Returns the URLs where a payment request (as specified in BIP 70) may be fetched. The first URL is the main URL, all subsequent URLs are fallbacks
getPaymentRequestUrls
{ "repo_name": "blockchain/bitcoinj", "path": "core/src/main/java/org/bitcoinj/uri/BitcoinURI.java", "license": "apache-2.0", "size": 16799 }
[ "java.util.ArrayList", "java.util.Collections", "java.util.List" ]
import java.util.ArrayList; import java.util.Collections; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,776,676
void setTypeCode(ParticipationType value);
void setTypeCode(ParticipationType value);
/** * Sets the value of the '{@link org.openhealthtools.mdht.uml.cda.Participant2#getTypeCode <em>Type Code</em>}' attribute. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Type Code</em>' attribute. * @see org.openhealthtools.mdht.uml.hl7.vocab.ParticipationTy...
Sets the value of the '<code>org.openhealthtools.mdht.uml.cda.Participant2#getTypeCode Type Code</code>' attribute.
setTypeCode
{ "repo_name": "drbgfc/mdht", "path": "cda/plugins/org.openhealthtools.mdht.uml.cda/src/org/openhealthtools/mdht/uml/cda/Participant2.java", "license": "epl-1.0", "size": 15162 }
[ "org.openhealthtools.mdht.uml.hl7.vocab.ParticipationType" ]
import org.openhealthtools.mdht.uml.hl7.vocab.ParticipationType;
import org.openhealthtools.mdht.uml.hl7.vocab.*;
[ "org.openhealthtools.mdht" ]
org.openhealthtools.mdht;
550,835
static public ObjectName register(String serviceName, String nameName, Object theMbean) { final MBeanServer mbs = ManagementFactory.getPlatformMBeanServer(); ObjectName name = getMBeanName(serviceName, nameName); try { mbs.registerMBean(theMbean, name); LOG....
static ObjectName function(String serviceName, String nameName, Object theMbean) { final MBeanServer mbs = ManagementFactory.getPlatformMBeanServer(); ObjectName name = getMBeanName(serviceName, nameName); try { mbs.registerMBean(theMbean, name); LOG.debug(STR+ name); return name; } catch (InstanceAlreadyExistsExceptio...
/** * Register the MBean using our standard MBeanName format * "hadoop:service=<serviceName>,name=<nameName>" * Where the <serviceName> and <nameName> are the supplied parameters * * @param serviceName * @param nameName * @param theMbean - the MBean to register * @return the named used to regist...
Register the MBean using our standard MBeanName format "hadoop:service=,name=" Where the and are the supplied parameters
register
{ "repo_name": "robzor92/hops", "path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/metrics2/util/MBeans.java", "license": "apache-2.0", "size": 4614 }
[ "java.lang.management.ManagementFactory", "javax.management.InstanceAlreadyExistsException", "javax.management.MBeanServer", "javax.management.ObjectName" ]
import java.lang.management.ManagementFactory; import javax.management.InstanceAlreadyExistsException; import javax.management.MBeanServer; import javax.management.ObjectName;
import java.lang.management.*; import javax.management.*;
[ "java.lang", "javax.management" ]
java.lang; javax.management;
2,142,247
public static ShareCode deconstruct(String resourceId, String shareCode, String secretKey) throws ShareCodeValidationException { checkForEmptyParameters(resourceId, shareCode, secretKey); // Deshuffle the shuffled shareCode using the resourceId as the seed. String deshuffled = deshuffleString(shareCode, re...
static ShareCode function(String resourceId, String shareCode, String secretKey) throws ShareCodeValidationException { checkForEmptyParameters(resourceId, shareCode, secretKey); String deshuffled = deshuffleString(shareCode, resourceId + secretKey); String signature = deshuffled.substring(deshuffled.length() - SIGNATUR...
/** * Deconstruct the share code from the provided resourceId and already constructed share code. * The resourceId will be used as the seed to deshuffle the share code. * * @param resourceId * the resource id * @param shareCode * the already-constructed share code * @param secretK...
Deconstruct the share code from the provided resourceId and already constructed share code. The resourceId will be used as the seed to deshuffle the share code
deconstruct
{ "repo_name": "SirmaITT/conservation-space-1.7.0", "path": "docker/sirma-platform/platform/seip-parent/platform/commons/commons-rest-security/src/main/java/com/sirma/itt/seip/shared/ShareCodeUtils.java", "license": "lgpl-3.0", "size": 7478 }
[ "com.sirma.itt.seip.shared.exception.ShareCodeValidationException", "java.util.Date" ]
import com.sirma.itt.seip.shared.exception.ShareCodeValidationException; import java.util.Date;
import com.sirma.itt.seip.shared.exception.*; import java.util.*;
[ "com.sirma.itt", "java.util" ]
com.sirma.itt; java.util;
2,042,612
private static void usage() { JCommander jc = new JCommander(new CommandLineArgs()); jc.usage(); }
static void function() { JCommander jc = new JCommander(new CommandLineArgs()); jc.usage(); }
/** * Prints out CLI/JCommander argument usage. */
Prints out CLI/JCommander argument usage
usage
{ "repo_name": "etaylor8086/prime-randomizer", "path": "src/main/java/com/etaylor8086/metroidprime/App.java", "license": "gpl-3.0", "size": 2975 }
[ "com.beust.jcommander.JCommander" ]
import com.beust.jcommander.JCommander;
import com.beust.jcommander.*;
[ "com.beust.jcommander" ]
com.beust.jcommander;
870,461
protected void buildRequiredValidUntilFilterIfNeeded(final SamlRegisteredService service, final List<MetadataFilter> metadataFilterList) { if (service.getMetadataMaxValidity() > 0) { final RequiredValidUntilFilter requiredValidUntilFilter = new RequiredValidUntilFilter(service.getMet...
void function(final SamlRegisteredService service, final List<MetadataFilter> metadataFilterList) { if (service.getMetadataMaxValidity() > 0) { final RequiredValidUntilFilter requiredValidUntilFilter = new RequiredValidUntilFilter(service.getMetadataMaxValidity()); metadataFilterList.add(requiredValidUntilFilter); LOGG...
/** * Build required valid until filter if needed. See {@link RequiredValidUntilFilter}. * * @param service the service * @param metadataFilterList the metadata filter list */
Build required valid until filter if needed. See <code>RequiredValidUntilFilter</code>
buildRequiredValidUntilFilterIfNeeded
{ "repo_name": "creamer/cas", "path": "support/cas-server-support-saml-idp/src/main/java/org/apereo/cas/support/saml/services/idp/metadata/cache/ChainingMetadataResolverCacheLoader.java", "license": "apache-2.0", "size": 19397 }
[ "java.util.List", "org.apereo.cas.support.saml.services.SamlRegisteredService", "org.opensaml.saml.metadata.resolver.filter.MetadataFilter", "org.opensaml.saml.metadata.resolver.filter.impl.RequiredValidUntilFilter" ]
import java.util.List; import org.apereo.cas.support.saml.services.SamlRegisteredService; import org.opensaml.saml.metadata.resolver.filter.MetadataFilter; import org.opensaml.saml.metadata.resolver.filter.impl.RequiredValidUntilFilter;
import java.util.*; import org.apereo.cas.support.saml.services.*; import org.opensaml.saml.metadata.resolver.filter.*; import org.opensaml.saml.metadata.resolver.filter.impl.*;
[ "java.util", "org.apereo.cas", "org.opensaml.saml" ]
java.util; org.apereo.cas; org.opensaml.saml;
2,578,840
public AbstractHessianInput getHessian2Input(InputStream is) { return new Hessian2Input(is); }
AbstractHessianInput function(InputStream is) { return new Hessian2Input(is); }
/** * Gets the hessian2 input. * * @param is * the is * * @return the hessian2 input */
Gets the hessian2 input
getHessian2Input
{ "repo_name": "mv2a/yajsw", "path": "src/ahessian/src/main/java/org/rzo/netty/ahessian/rpc/client/HessianProxyFactory.java", "license": "apache-2.0", "size": 18359 }
[ "com.caucho.hessian4.io.AbstractHessianInput", "java.io.InputStream", "org.rzo.netty.ahessian.rpc.io.Hessian2Input" ]
import com.caucho.hessian4.io.AbstractHessianInput; import java.io.InputStream; import org.rzo.netty.ahessian.rpc.io.Hessian2Input;
import com.caucho.hessian4.io.*; import java.io.*; import org.rzo.netty.ahessian.rpc.io.*;
[ "com.caucho.hessian4", "java.io", "org.rzo.netty" ]
com.caucho.hessian4; java.io; org.rzo.netty;
2,660,154
protected long handleSuspendTimeouts() { long smallestTimeout = Long.MAX_VALUE; synchronized (suspendLock) { if (suspendQueue.isEmpty()) { return smallestTimeout; } if (isDestroyed()) { return smallestTimeout; } } List timeouts = new ArrayList(); List copyS...
long function() { long smallestTimeout = Long.MAX_VALUE; synchronized (suspendLock) { if (suspendQueue.isEmpty()) { return smallestTimeout; } if (isDestroyed()) { return smallestTimeout; } } List timeouts = new ArrayList(); List copySuspendQueue = null; synchronized (suspendLock) { copySuspendQueue = new ArrayList(susp...
/** * Iterates through a copy of suspendQueue and handles any requests that have timed out. * <p> * Synchronizes on suspendLock. * * @return the next smallest timeout in the suspendQueue */
Iterates through a copy of suspendQueue and handles any requests that have timed out. Synchronizes on suspendLock
handleSuspendTimeouts
{ "repo_name": "jdeppe-pivotal/geode", "path": "geode-core/src/main/java/org/apache/geode/distributed/internal/locks/DLockGrantor.java", "license": "apache-2.0", "size": 125739 }
[ "java.util.ArrayList", "java.util.List", "org.apache.geode.distributed.internal.locks.DLockRequestProcessor", "org.apache.geode.internal.Assert", "org.apache.geode.internal.logging.log4j.LogMarker" ]
import java.util.ArrayList; import java.util.List; import org.apache.geode.distributed.internal.locks.DLockRequestProcessor; import org.apache.geode.internal.Assert; import org.apache.geode.internal.logging.log4j.LogMarker;
import java.util.*; import org.apache.geode.distributed.internal.locks.*; import org.apache.geode.internal.*; import org.apache.geode.internal.logging.log4j.*;
[ "java.util", "org.apache.geode" ]
java.util; org.apache.geode;
510,651
public GeoBoundingBoxQueryBuilder setCornersOGC(GeoPoint bottomLeft, GeoPoint topRight) { return setCorners(topRight.getLat(), bottomLeft.getLon(), bottomLeft.getLat(), topRight.getLon()); }
GeoBoundingBoxQueryBuilder function(GeoPoint bottomLeft, GeoPoint topRight) { return setCorners(topRight.getLat(), bottomLeft.getLon(), bottomLeft.getLat(), topRight.getLon()); }
/** * Adds corners in OGC standard bbox/ envelop format. * * @param bottomLeft bottom left corner of bounding box. * @param topRight top right corner of bounding box. */
Adds corners in OGC standard bbox/ envelop format
setCornersOGC
{ "repo_name": "a2lin/elasticsearch", "path": "core/src/main/java/org/elasticsearch/index/query/GeoBoundingBoxQueryBuilder.java", "license": "apache-2.0", "size": 22019 }
[ "org.elasticsearch.common.geo.GeoPoint" ]
import org.elasticsearch.common.geo.GeoPoint;
import org.elasticsearch.common.geo.*;
[ "org.elasticsearch.common" ]
org.elasticsearch.common;
991,386
@Override public void visitPropertyRead(AbstractNode n, Set<ObjectLabel> objs, PKeys propertyname, State state, boolean check_unknown) { if (!scan_phase) { return; } // warn about potential loss of precision if (check_unknown && checkPropertyNameImpreciseMayInterfereW...
void function(AbstractNode n, Set<ObjectLabel> objs, PKeys propertyname, State state, boolean check_unknown) { if (!scan_phase) { return; } if (check_unknown && checkPropertyNameImpreciseMayInterfereWithBuiltInProperties(propertyname)) { addMessage(n, Status.INFO, Severity.LOW, STR); } if (propertyname.isMaybeSingleStr...
/** * Checks for reads from unknown properties; * also registers a read operation on abstract objects. * Properties named 'length' on array objects are ignored. */
Checks for reads from unknown properties; also registers a read operation on abstract objects. Properties named 'length' on array objects are ignored
visitPropertyRead
{ "repo_name": "cs-au-dk/TAJS", "path": "src/dk/brics/tajs/monitoring/AnalysisMonitor.java", "license": "apache-2.0", "size": 66064 }
[ "dk.brics.tajs.flowgraph.AbstractNode", "dk.brics.tajs.flowgraph.Function", "dk.brics.tajs.lattice.ObjectLabel", "dk.brics.tajs.lattice.PKey", "dk.brics.tajs.lattice.PKeys", "dk.brics.tajs.lattice.State", "dk.brics.tajs.lattice.Value", "dk.brics.tajs.solver.Message", "dk.brics.tajs.util.Collections"...
import dk.brics.tajs.flowgraph.AbstractNode; import dk.brics.tajs.flowgraph.Function; import dk.brics.tajs.lattice.ObjectLabel; import dk.brics.tajs.lattice.PKey; import dk.brics.tajs.lattice.PKeys; import dk.brics.tajs.lattice.State; import dk.brics.tajs.lattice.Value; import dk.brics.tajs.solver.Message; import dk.br...
import dk.brics.tajs.flowgraph.*; import dk.brics.tajs.lattice.*; import dk.brics.tajs.solver.*; import dk.brics.tajs.util.*; import java.util.*;
[ "dk.brics.tajs", "java.util" ]
dk.brics.tajs; java.util;
2,700,142
public static int getOptimalDrawerWidth(Context context) { int possibleMinDrawerWidth = UIUtils.getScreenWidth(context) - UIUtils.getActionBarHeight(context); int maxDrawerWidth = context.getResources().getDimensionPixelSize(R.dimen.material_drawer_width); return Math.min(possibleMinDrawerWi...
static int function(Context context) { int possibleMinDrawerWidth = UIUtils.getScreenWidth(context) - UIUtils.getActionBarHeight(context); int maxDrawerWidth = context.getResources().getDimensionPixelSize(R.dimen.material_drawer_width); return Math.min(possibleMinDrawerWidth, maxDrawerWidth); }
/** * helper to calculate the optimal drawer width * * @param context * @return */
helper to calculate the optimal drawer width
getOptimalDrawerWidth
{ "repo_name": "MaTriXy/MaterialDrawer", "path": "library/src/main/java/com/mikepenz/materialdrawer/util/DrawerUIUtils.java", "license": "apache-2.0", "size": 9871 }
[ "android.content.Context", "com.mikepenz.materialize.util.UIUtils" ]
import android.content.Context; import com.mikepenz.materialize.util.UIUtils;
import android.content.*; import com.mikepenz.materialize.util.*;
[ "android.content", "com.mikepenz.materialize" ]
android.content; com.mikepenz.materialize;
1,851,673
Translator t = new PackageTranslator(PACKAGE, locale); final StringBuilder tableHeader1 = new StringBuilder(); final StringBuilder tableHeader2 = new StringBuilder(); final StringBuilder tableContent = new StringBuilder(); final StringBuilder table = new StringBuilder(); final S...
Translator t = new PackageTranslator(PACKAGE, locale); final StringBuilder tableHeader1 = new StringBuilder(); final StringBuilder tableHeader2 = new StringBuilder(); final StringBuilder tableContent = new StringBuilder(); final StringBuilder table = new StringBuilder(); final String sequentialNumber = t.translate(STR)...
/** * The results from assessable nodes are written to one row per user into an excel-sheet. An assessable node will only appear if it is producing at least one of the * following variables: score, passed, attempts, comments. * * @param identities * @param myNodes * @param course * @...
The results from assessable nodes are written to one row per user into an excel-sheet. An assessable node will only appear if it is producing at least one of the following variables: score, passed, attempts, comments
createCourseResultsOverviewTable
{ "repo_name": "huihoo/olat", "path": "OLAT-LMS/src/main/java/org/olat/lms/course/archiver/ScoreAccountingHelper.java", "license": "apache-2.0", "size": 14377 }
[ "java.util.Iterator", "java.util.List", "org.olat.data.basesecurity.Identity", "org.olat.lms.course.assessment.AssessmentHelper", "org.olat.lms.course.assessment.AssessmentManager", "org.olat.lms.course.nodes.AssessableCourseNode", "org.olat.lms.course.run.scoring.ScoreEvaluation", "org.olat.lms.cours...
import java.util.Iterator; import java.util.List; import org.olat.data.basesecurity.Identity; import org.olat.lms.course.assessment.AssessmentHelper; import org.olat.lms.course.assessment.AssessmentManager; import org.olat.lms.course.nodes.AssessableCourseNode; import org.olat.lms.course.run.scoring.ScoreEvaluation; im...
import java.util.*; import org.olat.data.basesecurity.*; import org.olat.lms.course.assessment.*; import org.olat.lms.course.nodes.*; import org.olat.lms.course.run.scoring.*; import org.olat.lms.course.run.userview.*; import org.olat.lms.security.*; import org.olat.lms.user.propertyhandler.*; import org.olat.presentat...
[ "java.util", "org.olat.data", "org.olat.lms", "org.olat.presentation", "org.olat.system" ]
java.util; org.olat.data; org.olat.lms; org.olat.presentation; org.olat.system;
1,976,345
protected void _format(SarlCapacity capacity, IFormattableDocument document) { formatAnnotations(capacity, document, XbaseFormatterPreferenceKeys.newLineAfterClassAnnotations); formatModifiers(capacity, document); final ISemanticRegionsFinder regionFor = this.textRegionExtensions.regionFor(capacity); docum...
void function(SarlCapacity capacity, IFormattableDocument document) { formatAnnotations(capacity, document, XbaseFormatterPreferenceKeys.newLineAfterClassAnnotations); formatModifiers(capacity, document); final ISemanticRegionsFinder regionFor = this.textRegionExtensions.regionFor(capacity); document.append(regionFor.k...
/** Format the given SARL capacity. * * @param capacity the SARL component. * @param document the document. */
Format the given SARL capacity
_format
{ "repo_name": "sarl/sarl", "path": "main/coreplugins/io.sarl.lang/src/io/sarl/lang/formatting2/SARLFormatter.java", "license": "apache-2.0", "size": 28278 }
[ "io.sarl.lang.sarl.SarlCapacity", "org.eclipse.xtext.formatting2.IFormattableDocument", "org.eclipse.xtext.formatting2.regionaccess.ISemanticRegionsFinder", "org.eclipse.xtext.xbase.formatting2.XbaseFormatterPreferenceKeys" ]
import io.sarl.lang.sarl.SarlCapacity; import org.eclipse.xtext.formatting2.IFormattableDocument; import org.eclipse.xtext.formatting2.regionaccess.ISemanticRegionsFinder; import org.eclipse.xtext.xbase.formatting2.XbaseFormatterPreferenceKeys;
import io.sarl.lang.sarl.*; import org.eclipse.xtext.formatting2.*; import org.eclipse.xtext.formatting2.regionaccess.*; import org.eclipse.xtext.xbase.formatting2.*;
[ "io.sarl.lang", "org.eclipse.xtext" ]
io.sarl.lang; org.eclipse.xtext;
1,126,696
Map<String, Object> create(InputStream content, String contentType, String name, String principal);
Map<String, Object> create(InputStream content, String contentType, String name, String principal);
/** * Write content to persistent storage. * * @param content the content to persist * @param contentType MIME content type * @param name name of content * @param principal the caller security principal (username) * @return Metadata for the newly created resource */
Write content to persistent storage
create
{ "repo_name": "technipelago/grails-crm-content", "path": "src/java/grails/plugins/crm/content/CrmContentProvider.java", "license": "apache-2.0", "size": 4581 }
[ "java.io.InputStream", "java.util.Map" ]
import java.io.InputStream; import java.util.Map;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
1,139,653
@Override protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) { super.collectNewChildDescriptors(newChildDescriptors, object); }
void function(Collection<Object> newChildDescriptors, Object object) { super.collectNewChildDescriptors(newChildDescriptors, object); }
/** * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing * the children that can be created under this object. <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated */
This adds <code>org.eclipse.emf.edit.command.CommandParameter</code>s describing the children that can be created under this object.
collectNewChildDescriptors
{ "repo_name": "enterpriseDomain/ClassMaker", "path": "bundles/org.enterprisedomain.classmaker.edit/src/org/enterprisedomain/classmaker/provider/CompletionNotificationAdapterItemProvider.java", "license": "apache-2.0", "size": 4875 }
[ "java.util.Collection" ]
import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
2,685,316
private boolean checkComparison(String operator, Node equality, int i) { Node target = equality.jjtGetChild(i).jjtGetChild(0).jjtGetChild(0); return target instanceof ASTLiteral && getComparisonTargets().get(operator).contains(target.getImage()); }
boolean function(String operator, Node equality, int i) { Node target = equality.jjtGetChild(i).jjtGetChild(0).jjtGetChild(0); return target instanceof ASTLiteral && getComparisonTargets().get(operator).contains(target.getImage()); }
/** * Checks if the equality expression passed in is of comparing against the * value passed in as i * * @param equality * @param i * The ordinal in the equality expression to check * @return true if the value in position i is one of the comparison targets, else false ...
Checks if the equality expression passed in is of comparing against the value passed in as i
checkComparison
{ "repo_name": "byronka/xenos", "path": "utils/pmd-bin-5.2.2/src/pmd-java/src/main/java/net/sourceforge/pmd/lang/java/rule/AbstractInefficientZeroCheck.java", "license": "mit", "size": 4680 }
[ "net.sourceforge.pmd.lang.ast.Node", "net.sourceforge.pmd.lang.java.ast.ASTLiteral" ]
import net.sourceforge.pmd.lang.ast.Node; import net.sourceforge.pmd.lang.java.ast.ASTLiteral;
import net.sourceforge.pmd.lang.ast.*; import net.sourceforge.pmd.lang.java.ast.*;
[ "net.sourceforge.pmd" ]
net.sourceforge.pmd;
371,809
public SwapFixedIborDefinition[] getUnderlyingSwap() { return _underlyingSwap; }
SwapFixedIborDefinition[] function() { return _underlyingSwap; }
/** * Gets the swaps underlying the swaption. There is one swap for each expiration date. * @return The underlying swaps. */
Gets the swaps underlying the swaption. There is one swap for each expiration date
getUnderlyingSwap
{ "repo_name": "charles-cooper/idylfin", "path": "src/com/opengamma/analytics/financial/instrument/swaption/SwaptionBermudaFixedIborDefinition.java", "license": "apache-2.0", "size": 6136 }
[ "com.opengamma.analytics.financial.instrument.swap.SwapFixedIborDefinition" ]
import com.opengamma.analytics.financial.instrument.swap.SwapFixedIborDefinition;
import com.opengamma.analytics.financial.instrument.swap.*;
[ "com.opengamma.analytics" ]
com.opengamma.analytics;
2,264,098
@POST @Path("data") DataMetadataDto getDataMetadata(DataMetadataGetRequestDto metadataGetRequestDto);
@Path("data") DataMetadataDto getDataMetadata(DataMetadataGetRequestDto metadataGetRequestDto);
/** * Returns the data metadata. * * @param metadataGetRequestDto metadata request * @return data metadata */
Returns the data metadata
getDataMetadata
{ "repo_name": "tgianos/metacat", "path": "metacat-client/src/main/java/com/netflix/metacat/client/api/MetadataV1.java", "license": "apache-2.0", "size": 3942 }
[ "com.netflix.metacat.common.dto.DataMetadataDto", "com.netflix.metacat.common.dto.DataMetadataGetRequestDto", "javax.ws.rs.Path" ]
import com.netflix.metacat.common.dto.DataMetadataDto; import com.netflix.metacat.common.dto.DataMetadataGetRequestDto; import javax.ws.rs.Path;
import com.netflix.metacat.common.dto.*; import javax.ws.rs.*;
[ "com.netflix.metacat", "javax.ws" ]
com.netflix.metacat; javax.ws;
2,013,971
default Capabilities merge(Capabilities other) { HashMap<String, Object> map = new HashMap<>(asMap()); if (other != null) { map.putAll(other.asMap()); } return new ImmutableCapabilities(map); }
default Capabilities merge(Capabilities other) { HashMap<String, Object> map = new HashMap<>(asMap()); if (other != null) { map.putAll(other.asMap()); } return new ImmutableCapabilities(map); }
/** * Merge two {@link Capabilities} together and return the union of the two as a new * {@link Capabilities} instance. Capabilities from {@code other} will override those in * {@code this}. */
Merge two <code>Capabilities</code> together and return the union of the two as a new <code>Capabilities</code> instance. Capabilities from other will override those in this
merge
{ "repo_name": "asolntsev/selenium", "path": "java/client/src/org/openqa/selenium/Capabilities.java", "license": "apache-2.0", "size": 3335 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
609,780
public static void main(final String[] args) throws ParseException { final testImport ti = new testImport("tester"); ti.testImportSingleLine(); ti.testImportQuotedLine(); ti.testImportNarrative(); }
static void function(final String[] args) throws ParseException { final testImport ti = new testImport(STR); ti.testImportSingleLine(); ti.testImportQuotedLine(); ti.testImportNarrative(); }
/** do some narrative import checking * * @param args * @throws ParseException */
do some narrative import checking
main
{ "repo_name": "theanuradha/debrief", "path": "org.mwc.debrief.legacy/src/Debrief/ReaderWriter/Replay/ImportNarrative.java", "license": "epl-1.0", "size": 9912 }
[ "java.text.ParseException" ]
import java.text.ParseException;
import java.text.*;
[ "java.text" ]
java.text;
2,353,761
public void killAll(boolean close) { if (mConfiguration.mRestrictedMode){ return; } if (mLoadedTasksOriginal.size() == 0) { if(close){ hide(true); } return; } Iterator<TaskDescription> nextTask = mLoadedTasksOr...
void function(boolean close) { if (mConfiguration.mRestrictedMode){ return; } if (mLoadedTasksOriginal.size() == 0) { if(close){ hide(true); } return; } Iterator<TaskDescription> nextTask = mLoadedTasksOriginal.iterator(); while (nextTask.hasNext()) { TaskDescription ad = nextTask.next(); if (ad.isLocked()) { continue;...
/** * killall will always remove all tasks - also those that are * filtered out (not active) * @param close */
killall will always remove all tasks - also those that are filtered out (not active)
killAll
{ "repo_name": "BlissRoms/platform_packages_apps_OmniSwitch", "path": "src/org/omnirom/omniswitch/SwitchManager.java", "license": "gpl-3.0", "size": 19770 }
[ "android.util.Log", "java.util.Iterator" ]
import android.util.Log; import java.util.Iterator;
import android.util.*; import java.util.*;
[ "android.util", "java.util" ]
android.util; java.util;
1,829,524
public Entity getLightning() { return bolt; }
Entity function() { return bolt; }
/** * Gets the bolt which is striking the creeper. * * @return lightning entity */
Gets the bolt which is striking the creeper
getLightning
{ "repo_name": "dested/Bukkit-Maps", "path": "src/main/java/org/bukkit/event/entity/CreeperPowerEvent.java", "license": "gpl-3.0", "size": 2259 }
[ "org.bukkit.entity.Entity" ]
import org.bukkit.entity.Entity;
import org.bukkit.entity.*;
[ "org.bukkit.entity" ]
org.bukkit.entity;
227,980
public UpgradeCommand completeUpgrade() throws IOException { return new UpgradeCommand(UpgradeCommand.UC_ACTION_REPORT_STATUS, getVersion(), (short)100); }
UpgradeCommand function() throws IOException { return new UpgradeCommand(UpgradeCommand.UC_ACTION_REPORT_STATUS, getVersion(), (short)100); }
/** * Complete upgrade and return a status complete command for broadcasting. * * Data-nodes finish upgrade at different times. * The data-node needs to re-confirm with the name-node that the upgrade * is complete while other nodes are still upgrading. */
Complete upgrade and return a status complete command for broadcasting. Data-nodes finish upgrade at different times. The data-node needs to re-confirm with the name-node that the upgrade is complete while other nodes are still upgrading
completeUpgrade
{ "repo_name": "gabrielborgesmagalhaes/hadoop-hdfs", "path": "src/java/org/apache/hadoop/hdfs/server/datanode/UpgradeObjectDatanode.java", "license": "apache-2.0", "size": 5150 }
[ "java.io.IOException", "org.apache.hadoop.hdfs.server.protocol.UpgradeCommand" ]
import java.io.IOException; import org.apache.hadoop.hdfs.server.protocol.UpgradeCommand;
import java.io.*; import org.apache.hadoop.hdfs.server.protocol.*;
[ "java.io", "org.apache.hadoop" ]
java.io; org.apache.hadoop;
2,583,917
@Test public void testClearProperties_2() { try { TextMessage message = senderSession.createTextMessage(); message.setText("foo"); message.clearProperties(); Assert.assertEquals("sec. 3.5.7 Clearing a message's property entries does not clear the value of its bo...
void function() { try { TextMessage message = senderSession.createTextMessage(); message.setText("foo"); message.clearProperties(); Assert.assertEquals(STR, "foo", message.getText()); } catch (JMSException e) { fail(e); } }
/** * Test that the <code>Message.clearProperties()</code> method does not clear the * value of the Message's body. */
Test that the <code>Message.clearProperties()</code> method does not clear the value of the Message's body
testClearProperties_2
{ "repo_name": "ryanemerson/activemq-artemis", "path": "tests/joram-tests/src/test/java/org/objectweb/jtests/jms/conform/message/properties/MessagePropertyTest.java", "license": "apache-2.0", "size": 10943 }
[ "javax.jms.JMSException", "javax.jms.TextMessage", "org.junit.Assert" ]
import javax.jms.JMSException; import javax.jms.TextMessage; import org.junit.Assert;
import javax.jms.*; import org.junit.*;
[ "javax.jms", "org.junit" ]
javax.jms; org.junit;
289,604
protected void addTransportVFSLockingPropertyDescriptor(Object object) { itemPropertyDescriptors.add(createItemPropertyDescriptor( ((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_InboundEndpoint_transportVFSLocking_feature"), getString("_UI...
void function(Object object) { itemPropertyDescriptors.add(createItemPropertyDescriptor( ((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), EsbPackage.Literals.INBOUND_ENDPOINT__TRANSPORT_VFS_LOCKING, true, false, false, ItemPropertyDesc...
/** * This adds a property descriptor for the Transport VFS Locking feature. * <!-- begin-user-doc --> <!-- end-user-doc --> * * @generated NOT */
This adds a property descriptor for the Transport VFS Locking feature.
addTransportVFSLockingPropertyDescriptor
{ "repo_name": "nwnpallewela/devstudio-tooling-esb", "path": "plugins/org.wso2.developerstudio.eclipse.gmf.esb.edit/src/org/wso2/developerstudio/eclipse/gmf/esb/provider/InboundEndpointItemProvider.java", "license": "apache-2.0", "size": 165854 }
[ "org.eclipse.emf.edit.provider.ComposeableAdapterFactory", "org.eclipse.emf.edit.provider.ItemPropertyDescriptor", "org.wso2.developerstudio.eclipse.gmf.esb.EsbPackage" ]
import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; import org.wso2.developerstudio.eclipse.gmf.esb.EsbPackage;
import org.eclipse.emf.edit.provider.*; import org.wso2.developerstudio.eclipse.gmf.esb.*;
[ "org.eclipse.emf", "org.wso2.developerstudio" ]
org.eclipse.emf; org.wso2.developerstudio;
2,530,724
private void write(NaturalLanguageSyntax attribute) throws IOException { String name = ((Attribute) attribute).getName(); out.writeByte(IppValueTag.NATURAL_LANGUAGE); out.writeShort(name.length()); out.write(name.getBytes()); out.writeShort(attribute.getValue().length()); out...
void function(NaturalLanguageSyntax attribute) throws IOException { String name = ((Attribute) attribute).getName(); out.writeByte(IppValueTag.NATURAL_LANGUAGE); out.writeShort(name.length()); out.write(name.getBytes()); out.writeShort(attribute.getValue().length()); out.write(attribute.getValue().getBytes()); }
/** * Writes an attribute in NaturalLanguageSyntax into the stream. * @param attribute the attribute * @param out the stream to write to * @throws IOException if thrown by the stream */
Writes an attribute in NaturalLanguageSyntax into the stream
write
{ "repo_name": "embecosm/avr32-gcc", "path": "libjava/classpath/gnu/javax/print/ipp/IppRequest.java", "license": "gpl-2.0", "size": 30898 }
[ "gnu.javax.print.ipp.attribute.NaturalLanguageSyntax", "java.io.IOException", "javax.print.attribute.Attribute" ]
import gnu.javax.print.ipp.attribute.NaturalLanguageSyntax; import java.io.IOException; import javax.print.attribute.Attribute;
import gnu.javax.print.ipp.attribute.*; import java.io.*; import javax.print.attribute.*;
[ "gnu.javax.print", "java.io", "javax.print" ]
gnu.javax.print; java.io; javax.print;
1,977,693
public void sendMessage(final ServerMessageToClient serverMessage) { server.sendMessage(serverMessage); }
void function(final ServerMessageToClient serverMessage) { server.sendMessage(serverMessage); }
/** * Sends a message to the client context stored in the message by delegating this call to * {@link SwiftSocketServer#sendMessage(ServerMessageToClient)}. * * @param serverMessage The message to send to the client associated with it. */
Sends a message to the client context stored in the message by delegating this call to <code>SwiftSocketServer#sendMessage(ServerMessageToClient)</code>
sendMessage
{ "repo_name": "bbottema/swift-socket-server", "path": "server/src/main/java/org/codemonkey/swiftworldserver/WorldServer.java", "license": "apache-2.0", "size": 9148 }
[ "org.codemonkey.swiftsocketserver.ServerMessageToClient" ]
import org.codemonkey.swiftsocketserver.ServerMessageToClient;
import org.codemonkey.swiftsocketserver.*;
[ "org.codemonkey.swiftsocketserver" ]
org.codemonkey.swiftsocketserver;
2,460,135
public static ArrayList<IonType> getImplementedIonTypes() { ArrayList<IonType> result = new ArrayList<>(); result.add(IonType.ELEMENTARY_ION); result.add(IonType.GLYCAN); result.add(IonType.IMMONIUM_ION); result.add(IonType.PEPTIDE_FRAGMENT_ION); result.add(IonType.TA...
static ArrayList<IonType> function() { ArrayList<IonType> result = new ArrayList<>(); result.add(IonType.ELEMENTARY_ION); result.add(IonType.GLYCAN); result.add(IonType.IMMONIUM_ION); result.add(IonType.PEPTIDE_FRAGMENT_ION); result.add(IonType.TAG_FRAGMENT_ION); result.add(IonType.PRECURSOR_ION); result.add(IonType.RE...
/** * Returns the implemented ion types. * * @return the implemented ion types */
Returns the implemented ion types
getImplementedIonTypes
{ "repo_name": "compomics/compomics-utilities", "path": "src/main/java/com/compomics/util/experiment/biology/ions/Ion.java", "license": "apache-2.0", "size": 13731 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
1,128,855
public void waitForProcesses(ProcessStart... procStarts) throws InterruptedException { for (ProcessStart procStart : procStarts) { final int exitValue = procStart.proc.waitFor(); String procType = procStart.isLocator ? "locator" : "server"; if (procStart.version != null) { procType...
void function(ProcessStart... procStarts) throws InterruptedException { for (ProcessStart procStart : procStarts) { final int exitValue = procStart.proc.waitFor(); String procType = procStart.isLocator ? STR : STR; if (procStart.version != null) { procType += (STR + procStart.version); } else { procType = STR + procTyp...
/** * Wait for locators/servers encapsulated by {@link ProcessStart} to finish * startup. */
Wait for locators/servers encapsulated by <code>ProcessStart</code> to finish startup
waitForProcesses
{ "repo_name": "SnappyDataInc/snappy-store", "path": "gemfirexd/tools/src/dunit/java/com/pivotal/gemfirexd/BackwardCompatabilityTestBase.java", "license": "apache-2.0", "size": 33438 }
[ "io.snappydata.test.util.TestException" ]
import io.snappydata.test.util.TestException;
import io.snappydata.test.util.*;
[ "io.snappydata.test" ]
io.snappydata.test;
2,836,659
public static Message createTopicMessage(JSONEntity message, String topicArn, String messageId, String receiptHandle) throws JSONObjectAdapterException, JSONException{ String messageJson = EntityFactory.createJSONStringForEntity(message); JSONObject jsonObj = new JSONObject(); jsonObj.put("MessageId", "d70646...
static Message function(JSONEntity message, String topicArn, String messageId, String receiptHandle) throws JSONObjectAdapterException, JSONException{ String messageJson = EntityFactory.createJSONStringForEntity(message); JSONObject jsonObj = new JSONObject(); jsonObj.put(STR, STR); jsonObj.put(STR, topicArn); jsonObj....
/** * When a message is first published to a topic, then pushed to a queue, queue message body contains the entire topic message body. * The topic message body then contains the original message. * @param message * @param messageId * @param receiptHandle * @return * @throws JSONObjectAdapterException *...
When a message is first published to a topic, then pushed to a queue, queue message body contains the entire topic message body. The topic message body then contains the original message
createTopicMessage
{ "repo_name": "xschildw/Synapse-Repository-Services", "path": "lib/lib-worker/src/main/java/org/sagebionetworks/asynchronous/workers/sqs/MessageUtils.java", "license": "apache-2.0", "size": 9544 }
[ "com.amazonaws.services.sqs.model.Message", "org.json.JSONException", "org.json.JSONObject", "org.sagebionetworks.schema.adapter.JSONEntity", "org.sagebionetworks.schema.adapter.JSONObjectAdapterException", "org.sagebionetworks.schema.adapter.org.json.EntityFactory" ]
import com.amazonaws.services.sqs.model.Message; import org.json.JSONException; import org.json.JSONObject; import org.sagebionetworks.schema.adapter.JSONEntity; import org.sagebionetworks.schema.adapter.JSONObjectAdapterException; import org.sagebionetworks.schema.adapter.org.json.EntityFactory;
import com.amazonaws.services.sqs.model.*; import org.json.*; import org.sagebionetworks.schema.adapter.*; import org.sagebionetworks.schema.adapter.org.json.*;
[ "com.amazonaws.services", "org.json", "org.sagebionetworks.schema" ]
com.amazonaws.services; org.json; org.sagebionetworks.schema;
1,667,302
private void assertMonitoringDocSourceNode(final Map<String, Object> sourceNode) { assertEquals(6, sourceNode.size()); final NodesInfoResponse nodesResponse = client().admin().cluster().prepareNodesInfo().clear().get(); assertEquals(1, nodesResponse.getNodes().size()); final Disco...
void function(final Map<String, Object> sourceNode) { assertEquals(6, sourceNode.size()); final NodesInfoResponse nodesResponse = client().admin().cluster().prepareNodesInfo().clear().get(); assertEquals(1, nodesResponse.getNodes().size()); final DiscoveryNode node = nodesResponse.getNodes().stream().findFirst().get()....
/** * Asserts that the source_node information (provided as a Map) of a monitoring document correspond to * the current local node information */
Asserts that the source_node information (provided as a Map) of a monitoring document correspond to the current local node information
assertMonitoringDocSourceNode
{ "repo_name": "jmluy/elasticsearch", "path": "x-pack/plugin/monitoring/src/internalClusterTest/java/org/elasticsearch/xpack/monitoring/integration/MonitoringIT.java", "license": "apache-2.0", "size": 20859 }
[ "java.util.Map", "org.elasticsearch.action.admin.cluster.node.info.NodesInfoResponse", "org.elasticsearch.cluster.node.DiscoveryNode", "org.hamcrest.Matchers" ]
import java.util.Map; import org.elasticsearch.action.admin.cluster.node.info.NodesInfoResponse; import org.elasticsearch.cluster.node.DiscoveryNode; import org.hamcrest.Matchers;
import java.util.*; import org.elasticsearch.action.admin.cluster.node.info.*; import org.elasticsearch.cluster.node.*; import org.hamcrest.*;
[ "java.util", "org.elasticsearch.action", "org.elasticsearch.cluster", "org.hamcrest" ]
java.util; org.elasticsearch.action; org.elasticsearch.cluster; org.hamcrest;
2,353,215
@CacheEvict(value={AgendaTreeDefinition.Cache.NAME, AgendaDefinition.Cache.NAME, ContextDefinition.Cache.NAME}, allEntries = true) public AgendaDefinition createAgenda(AgendaDefinition agenda);
@CacheEvict(value={AgendaTreeDefinition.Cache.NAME, AgendaDefinition.Cache.NAME, ContextDefinition.Cache.NAME}, allEntries = true) AgendaDefinition function(AgendaDefinition agenda);
/** * This will create a {@link AgendaDefinition} exactly like the parameter passed in. * * @param agenda The Agenda to create * @throws IllegalArgumentException if the Agenda is null * @throws IllegalStateException if the Agenda already exists in the system */
This will create a <code>AgendaDefinition</code> exactly like the parameter passed in
createAgenda
{ "repo_name": "ua-eas/ua-rice-2.1.9", "path": "krms/impl/src/main/java/org/kuali/rice/krms/impl/repository/AgendaBoService.java", "license": "apache-2.0", "size": 7683 }
[ "org.kuali.rice.krms.api.repository.agenda.AgendaDefinition", "org.kuali.rice.krms.api.repository.agenda.AgendaTreeDefinition", "org.kuali.rice.krms.api.repository.context.ContextDefinition", "org.springframework.cache.annotation.CacheEvict" ]
import org.kuali.rice.krms.api.repository.agenda.AgendaDefinition; import org.kuali.rice.krms.api.repository.agenda.AgendaTreeDefinition; import org.kuali.rice.krms.api.repository.context.ContextDefinition; import org.springframework.cache.annotation.CacheEvict;
import org.kuali.rice.krms.api.repository.agenda.*; import org.kuali.rice.krms.api.repository.context.*; import org.springframework.cache.annotation.*;
[ "org.kuali.rice", "org.springframework.cache" ]
org.kuali.rice; org.springframework.cache;
2,646,572
private void verifyDifferentDirs(FSImage img, long expectedImgSize, long expectedEditsSize) { StorageDirectory sd = null; for (Iterator<StorageDirectory> it = img.dirIterator(); it.hasNext();) { sd = it.next(); if (sd.getStorageDirType().isOfType(NameNodeDirType.IMAGE)) { File imf = FSImage.getImag...
void function(FSImage img, long expectedImgSize, long expectedEditsSize) { StorageDirectory sd = null; for (Iterator<StorageDirectory> it = img.dirIterator(); it.hasNext();) { sd = it.next(); if (sd.getStorageDirType().isOfType(NameNodeDirType.IMAGE)) { File imf = FSImage.getImageFile(sd, NameNodeFile.IMAGE); LOG.info(...
/** * verify that edits log and fsimage are in different directories and of a * correct size */
verify that edits log and fsimage are in different directories and of a correct size
verifyDifferentDirs
{ "repo_name": "shot/hadoop-source-reading", "path": "src/test/org/apache/hadoop/hdfs/server/namenode/TestStartup.java", "license": "apache-2.0", "size": 10413 }
[ "java.io.File", "java.util.Iterator", "org.apache.hadoop.hdfs.server.common.Storage", "org.apache.hadoop.hdfs.server.namenode.FSImage" ]
import java.io.File; import java.util.Iterator; import org.apache.hadoop.hdfs.server.common.Storage; import org.apache.hadoop.hdfs.server.namenode.FSImage;
import java.io.*; import java.util.*; import org.apache.hadoop.hdfs.server.common.*; import org.apache.hadoop.hdfs.server.namenode.*;
[ "java.io", "java.util", "org.apache.hadoop" ]
java.io; java.util; org.apache.hadoop;
604,319
ISchema getISchema(ISchemaName schemaName) throws MetaException;
ISchema getISchema(ISchemaName schemaName) throws MetaException;
/** * Get an ISchema by name. * @param schemaName schema descriptor * @return ISchema * @throws MetaException general database exception */
Get an ISchema by name
getISchema
{ "repo_name": "lirui-apache/hive", "path": "standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/RawStore.java", "license": "apache-2.0", "size": 94780 }
[ "org.apache.hadoop.hive.metastore.api.ISchema", "org.apache.hadoop.hive.metastore.api.ISchemaName", "org.apache.hadoop.hive.metastore.api.MetaException" ]
import org.apache.hadoop.hive.metastore.api.ISchema; import org.apache.hadoop.hive.metastore.api.ISchemaName; import org.apache.hadoop.hive.metastore.api.MetaException;
import org.apache.hadoop.hive.metastore.api.*;
[ "org.apache.hadoop" ]
org.apache.hadoop;
2,483,170
@SuppressWarnings("unchecked") public List<TacticalBattleReport> listGameNation(final Game thisGame, final Nation nation) { final Session session = getSessionFactory().getCurrentSession(); final List<TacticalBattleReport> list = new ArrayList<TacticalBattleReport>(); final Criteria crit...
@SuppressWarnings(STR) List<TacticalBattleReport> function(final Game thisGame, final Nation nation) { final Session session = getSessionFactory().getCurrentSession(); final List<TacticalBattleReport> list = new ArrayList<TacticalBattleReport>(); final Criteria criteria1 = session.createCriteria(TacticalBattleReport.cl...
/** * Listing all TacticalBattleReport from the database owned by the specific nation. * * @param thisGame the game to select. * @param nation the nation to select. * @return a list of all the Armies. */
Listing all TacticalBattleReport from the database owned by the specific nation
listGameNation
{ "repo_name": "EaW1805/data", "path": "src/main/java/com/eaw1805/data/managers/battles/TacticalBattleReportManager.java", "license": "mit", "size": 8664 }
[ "com.eaw1805.data.model.Game", "com.eaw1805.data.model.Nation", "com.eaw1805.data.model.army.comparators.TacticalBattleOrder", "com.eaw1805.data.model.battles.TacticalBattleReport", "java.util.ArrayList", "java.util.List", "org.hibernate.Criteria", "org.hibernate.Session", "org.hibernate.criterion.O...
import com.eaw1805.data.model.Game; import com.eaw1805.data.model.Nation; import com.eaw1805.data.model.army.comparators.TacticalBattleOrder; import com.eaw1805.data.model.battles.TacticalBattleReport; import java.util.ArrayList; import java.util.List; import org.hibernate.Criteria; import org.hibernate.Session; import...
import com.eaw1805.data.model.*; import com.eaw1805.data.model.army.comparators.*; import com.eaw1805.data.model.battles.*; import java.util.*; import org.hibernate.*; import org.hibernate.criterion.*;
[ "com.eaw1805.data", "java.util", "org.hibernate", "org.hibernate.criterion" ]
com.eaw1805.data; java.util; org.hibernate; org.hibernate.criterion;
1,408,909
@Test public void testInterpolatedOnYieldCurveGenerator1() { final DiscountingMethodCurveTypeSetUp setup = new DiscountingMethodCurveTypeSetUp() .forDiscounting(DISCOUNTING_ID) .withInterpolator(NamedInterpolator1dFactory.of(LinearInterpolator1dAdapter.NAME)) .continuousInterpolationOnYi...
void function() { final DiscountingMethodCurveTypeSetUp setup = new DiscountingMethodCurveTypeSetUp() .forDiscounting(DISCOUNTING_ID) .withInterpolator(NamedInterpolator1dFactory.of(LinearInterpolator1dAdapter.NAME)) .continuousInterpolationOnYield(); assertTrue(setup.buildCurveGenerator(ZonedDateTime.now()) instanceof...
/** * Tests the curve generator when interpolation on yield is explicitly chosen. */
Tests the curve generator when interpolation on yield is explicitly chosen
testInterpolatedOnYieldCurveGenerator1
{ "repo_name": "McLeodMoores/starling", "path": "projects/analytics/src/test/java/com/mcleodmoores/analytics/financial/curve/interestrate/curvebuilder/DiscountingMethodCurveTypeSetUpTest.java", "license": "apache-2.0", "size": 33324 }
[ "com.opengamma.analytics.financial.curve.interestrate.generator.GeneratorCurveYieldInterpolated", "com.opengamma.analytics.financial.curve.interestrate.generator.GeneratorCurveYieldInterpolatedNode", "com.opengamma.analytics.math.interpolation.factory.LinearInterpolator1dAdapter", "com.opengamma.analytics.mat...
import com.opengamma.analytics.financial.curve.interestrate.generator.GeneratorCurveYieldInterpolated; import com.opengamma.analytics.financial.curve.interestrate.generator.GeneratorCurveYieldInterpolatedNode; import com.opengamma.analytics.math.interpolation.factory.LinearInterpolator1dAdapter; import com.opengamma.an...
import com.opengamma.analytics.financial.curve.interestrate.generator.*; import com.opengamma.analytics.math.interpolation.factory.*; import org.testng.*; import org.threeten.bp.*;
[ "com.opengamma.analytics", "org.testng", "org.threeten.bp" ]
com.opengamma.analytics; org.testng; org.threeten.bp;
838,793
protected void disableTextSelection() { Style body = Document.get().getBody().getStyle(); body.setProperty("MozUserSelect", "none"); body.setProperty("WebkitUserSelect", "none"); body.setProperty("UserSelect", "none"); _disableTextSelection(); }
void function() { Style body = Document.get().getBody().getStyle(); body.setProperty(STR, "none"); body.setProperty(STR, "none"); body.setProperty(STR, "none"); _disableTextSelection(); }
/** * Utiltity method that disables all selection functionality on the document. * This avoids the nasty (and involuntary) selection effect that otherwise happens * when dragging the mouse */
Utiltity method that disables all selection functionality on the document. This avoids the nasty (and involuntary) selection effect that otherwise happens when dragging the mouse
disableTextSelection
{ "repo_name": "klokan/yuma.min.js", "path": "src/main/java/at/ait/dme/yumaJS/client/annotation/editors/selection/Selection.java", "license": "gpl-3.0", "size": 1700 }
[ "com.google.gwt.dom.client.Document", "com.google.gwt.dom.client.Style" ]
import com.google.gwt.dom.client.Document; import com.google.gwt.dom.client.Style;
import com.google.gwt.dom.client.*;
[ "com.google.gwt" ]
com.google.gwt;
181,452
private JPanel buildFilesToSubmitPane(List<ImportErrorObject> toSubmit) { JPanel panel = new JPanel(); //panel.setBackground(UIUtilities.WINDOW_BACKGROUND_COLOR); panel.setOpaque(false); double tableSize[][] = {{TableLayout.FILL}, // columns {TableLayout.FILL}}; /...
JPanel function(List<ImportErrorObject> toSubmit) { JPanel panel = new JPanel(); panel.setOpaque(false); double tableSize[][] = {{TableLayout.FILL}, {TableLayout.FILL}}; TableLayout layout = new TableLayout(tableSize); panel.setLayout(layout); panel.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); table = ne...
/** * Builds and lays out the panel hosting the collection of files to submit. * * @return See above. */
Builds and lays out the panel hosting the collection of files to submit
buildFilesToSubmitPane
{ "repo_name": "joshmoore/openmicroscopy", "path": "components/insight/SRC/org/openmicroscopy/shoola/util/ui/MessengerDialog.java", "license": "gpl-2.0", "size": 25904 }
[ "info.clearthought.layout.TableLayout", "java.util.List", "javax.swing.BorderFactory", "javax.swing.JPanel", "javax.swing.JScrollPane", "org.openmicroscopy.shoola.util.file.ImportErrorObject" ]
import info.clearthought.layout.TableLayout; import java.util.List; import javax.swing.BorderFactory; import javax.swing.JPanel; import javax.swing.JScrollPane; import org.openmicroscopy.shoola.util.file.ImportErrorObject;
import info.clearthought.layout.*; import java.util.*; import javax.swing.*; import org.openmicroscopy.shoola.util.file.*;
[ "info.clearthought.layout", "java.util", "javax.swing", "org.openmicroscopy.shoola" ]
info.clearthought.layout; java.util; javax.swing; org.openmicroscopy.shoola;
927,911
public void setCredentials(Element el, String username, String password, Credentials c) { if(c==null) return; if(c.getUsername()!=null)el.setAttribute(username,c.getUsername()); if(c.getPassword()!=null)el.setAttribute(password,c.getPassword()); }
void function(Element el, String username, String password, Credentials c) { if(c==null) return; if(c.getUsername()!=null)el.setAttribute(username,c.getUsername()); if(c.getPassword()!=null)el.setAttribute(password,c.getPassword()); }
/** * sets a Credentials to a XML Element * @param el * @param username * @param password * @param credentials */
sets a Credentials to a XML Element
setCredentials
{ "repo_name": "paulklinkenberg/Lucee4", "path": "lucee-java/lucee-core/src/lucee/runtime/schedule/StorageUtil.java", "license": "lgpl-2.1", "size": 14914 }
[ "org.w3c.dom.Element" ]
import org.w3c.dom.Element;
import org.w3c.dom.*;
[ "org.w3c.dom" ]
org.w3c.dom;
2,070,836
private void HandleResponse(byte[] buffer) { Envelopes.ResponseEnvelope responseEnvelop; try { responseEnvelop = Envelopes.ResponseEnvelope.parseFrom(buffer); } catch (InvalidProtocolBufferException e) { Helper.Log("Parsing response failed " + e); return; ...
void function(byte[] buffer) { Envelopes.ResponseEnvelope responseEnvelop; try { responseEnvelop = Envelopes.ResponseEnvelope.parseFrom(buffer); } catch (InvalidProtocolBufferException e) { Helper.Log(STR + e); return; } long requestId = responseEnvelop.getRequestId(); if (requestId == 0 !requestMap.containsKey(request...
/** * checks buffer for {@link Envelopes.ResponseEnvelope RequestType} and calls the associated method * * @param buffer return value of readDataSteam */
checks buffer for <code>Envelopes.ResponseEnvelope RequestType</code> and calls the associated method
HandleResponse
{ "repo_name": "MaT-PT/PoGoIV_xposed", "path": "app/src/main/java/de/chuparch0pper/android/xposed/pogoiv/IVChecker.java", "license": "mit", "size": 37929 }
[ "com.github.aeonlucid.pogoprotos.networking.Envelopes", "com.github.aeonlucid.pogoprotos.networking.Requests", "com.google.protobuf.ByteString", "com.google.protobuf.InvalidProtocolBufferException", "java.util.List" ]
import com.github.aeonlucid.pogoprotos.networking.Envelopes; import com.github.aeonlucid.pogoprotos.networking.Requests; import com.google.protobuf.ByteString; import com.google.protobuf.InvalidProtocolBufferException; import java.util.List;
import com.github.aeonlucid.pogoprotos.networking.*; import com.google.protobuf.*; import java.util.*;
[ "com.github.aeonlucid", "com.google.protobuf", "java.util" ]
com.github.aeonlucid; com.google.protobuf; java.util;
460,783
void generateExpression(ExpressionClassBuilder acb, MethodBuilder mb) throws StandardException { if (routineInfo != null) { if (!routineInfo.calledOnNullInput() && routineInfo.getParameterCount() != 0) returnsNullOnNullState = acb.newFieldDeclaration(Modifier.PRIVATE, "boolean"); } // re...
void generateExpression(ExpressionClassBuilder acb, MethodBuilder mb) throws StandardException { if (routineInfo != null) { if (!routineInfo.calledOnNullInput() && routineInfo.getParameterCount() != 0) returnsNullOnNullState = acb.newFieldDeclaration(Modifier.PRIVATE, STR); } if (returnsNullOnNullState != null) { mb.pu...
/** * Do code generation for this method call * * @param acb The ExpressionClassBuilder for the class we're generating * @param mb The method the expression will go into * * * @exception StandardException Thrown on error */
Do code generation for this method call
generateExpression
{ "repo_name": "scnakandala/derby", "path": "java/engine/org/apache/derby/impl/sql/compile/StaticMethodCallNode.java", "license": "apache-2.0", "size": 52208 }
[ "java.lang.reflect.Method", "java.lang.reflect.Modifier", "java.sql.ParameterMetaData", "org.apache.derby.catalog.types.RoutineAliasInfo", "org.apache.derby.iapi.error.StandardException", "org.apache.derby.iapi.reference.ClassName", "org.apache.derby.iapi.services.classfile.VMOpcode", "org.apache.derb...
import java.lang.reflect.Method; import java.lang.reflect.Modifier; import java.sql.ParameterMetaData; import org.apache.derby.catalog.types.RoutineAliasInfo; import org.apache.derby.iapi.error.StandardException; import org.apache.derby.iapi.reference.ClassName; import org.apache.derby.iapi.services.classfile.VMOpcode;...
import java.lang.reflect.*; import java.sql.*; import org.apache.derby.catalog.types.*; import org.apache.derby.iapi.error.*; import org.apache.derby.iapi.reference.*; import org.apache.derby.iapi.services.classfile.*; import org.apache.derby.iapi.services.compiler.*; import org.apache.derby.iapi.sql.conn.*; import org...
[ "java.lang", "java.sql", "org.apache.derby" ]
java.lang; java.sql; org.apache.derby;
1,718,632
private static String validateAlias(final String alias) { NullArgumentException.validateNotNull(alias, "Alias"); if (!alias.startsWith("/")) { throw new IllegalArgumentException( "Alias does not start with slash (/)"); } // "/" must be allowed if (alias.length() > 1 && alias.endsWith("/")) { thr...
static String function(final String alias) { NullArgumentException.validateNotNull(alias, "Alias"); if (!alias.startsWith("/")) { throw new IllegalArgumentException( STR); } if (alias.length() > 1 && alias.endsWith("/")) { throw new IllegalArgumentException(STR); } return alias; }
/** * Validates that aan alias conforms to OSGi specs requirements. See OSGi R4 * Http Service specs for details about alias validation. * * @param alias to validate * @return received alias if validation succeeds * @throws IllegalArgumentException if validation fails */
Validates that aan alias conforms to OSGi specs requirements. See OSGi R4 Http Service specs for details about alias validation
validateAlias
{ "repo_name": "lostiniceland/org.ops4j.pax.web", "path": "pax-web-spi/src/main/java/org/ops4j/pax/web/service/spi/model/ServletModel.java", "license": "apache-2.0", "size": 7758 }
[ "org.ops4j.lang.NullArgumentException" ]
import org.ops4j.lang.NullArgumentException;
import org.ops4j.lang.*;
[ "org.ops4j.lang" ]
org.ops4j.lang;
796,592