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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
@Override
public void remove( final String cacheName, final K key, final long requesterId )
throws IOException
{
final CacheElement<K, V> ce = new CacheElement<>( cacheName, key, null );
final LateralElementDescriptor<K, V> led =
new LateralElementDescriptor<>(ce, Lat... | void function( final String cacheName, final K key, final long requesterId ) throws IOException { final CacheElement<K, V> ce = new CacheElement<>( cacheName, key, null ); final LateralElementDescriptor<K, V> led = new LateralElementDescriptor<>(ce, LateralCommand.REMOVE, requesterId); sender.send( led ); } | /**
* Wraps the key in a LateralElementDescriptor.
* <p>
* @see org.apache.commons.jcs3.engine.behavior.ICacheServiceNonLocal#remove(String, Object, long)
*/ | Wraps the key in a LateralElementDescriptor. | remove | {
"repo_name": "apache/commons-jcs",
"path": "commons-jcs-core/src/main/java/org/apache/commons/jcs3/auxiliary/lateral/socket/tcp/LateralTCPService.java",
"license": "apache-2.0",
"size": 14898
} | [
"java.io.IOException",
"org.apache.commons.jcs3.auxiliary.lateral.LateralCommand",
"org.apache.commons.jcs3.auxiliary.lateral.LateralElementDescriptor",
"org.apache.commons.jcs3.engine.CacheElement"
] | import java.io.IOException; import org.apache.commons.jcs3.auxiliary.lateral.LateralCommand; import org.apache.commons.jcs3.auxiliary.lateral.LateralElementDescriptor; import org.apache.commons.jcs3.engine.CacheElement; | import java.io.*; import org.apache.commons.jcs3.auxiliary.lateral.*; import org.apache.commons.jcs3.engine.*; | [
"java.io",
"org.apache.commons"
] | java.io; org.apache.commons; | 1,833,435 |
public static double getFlatness(final Shape shape) {
final Rectangle2D bounds = shape.getBounds2D();
final double dx = bounds.getWidth();
final double dy = bounds.getHeight();
return max(0.025 * min(dx, dy), 0.001 * max(dx, dy));
} | static double function(final Shape shape) { final Rectangle2D bounds = shape.getBounds2D(); final double dx = bounds.getWidth(); final double dy = bounds.getHeight(); return max(0.025 * min(dx, dy), 0.001 * max(dx, dy)); } | /**
* Returns a suggested value for the {@code flatness} argument in {@link
* Shape#getPathIterator(AffineTransform,double)} for the specified shape.
*
* @param shape The shape for which to compute a flatness factor.
* @return The suggested flatness factor.
*/ | Returns a suggested value for the flatness argument in <code>Shape#getPathIterator(AffineTransform,double)</code> for the specified shape | getFlatness | {
"repo_name": "geotools/geotools",
"path": "modules/library/referencing/src/main/java/org/geotools/geometry/util/ShapeUtilities.java",
"license": "lgpl-2.1",
"size": 29507
} | [
"java.awt.Shape",
"java.awt.geom.Rectangle2D",
"java.lang.Math"
] | import java.awt.Shape; import java.awt.geom.Rectangle2D; import java.lang.Math; | import java.awt.*; import java.awt.geom.*; import java.lang.*; | [
"java.awt",
"java.lang"
] | java.awt; java.lang; | 1,638,455 |
@SuppressLint("NewApi")
private void checkForPush(Context context) {
Log.v("Main Screen", "Checking for push time");
// Fetch current time and time stored in file
Calendar current = Calendar.getInstance();
Calendar last = Calendar.getInstance();
SharedPreferences sp = Pr... | @SuppressLint(STR) void function(Context context) { Log.v(STR, STR); Calendar current = Calendar.getInstance(); Calendar last = Calendar.getInstance(); SharedPreferences sp = PreferenceManager .getDefaultSharedPreferences(context); Long lastTimestamp = sp.getLong(STR, 0l); last.setTimeInMillis(lastTimestamp); if (DateU... | /**
* Checks if it is time to push the daily notification to the database.
*/ | Checks if it is time to push the daily notification to the database | checkForPush | {
"repo_name": "JohannesV/Fall_Prevention_2013",
"path": "FallPrevention/src/ntnu/stud/valens/demonstration/widget/WidgetProvider.java",
"license": "apache-2.0",
"size": 9332
} | [
"android.annotation.SuppressLint",
"android.content.Context",
"android.content.SharedPreferences",
"android.preference.PreferenceManager",
"android.text.format.DateUtils",
"android.util.Log",
"java.sql.Timestamp",
"java.util.Calendar"
] | import android.annotation.SuppressLint; import android.content.Context; import android.content.SharedPreferences; import android.preference.PreferenceManager; import android.text.format.DateUtils; import android.util.Log; import java.sql.Timestamp; import java.util.Calendar; | import android.annotation.*; import android.content.*; import android.preference.*; import android.text.format.*; import android.util.*; import java.sql.*; import java.util.*; | [
"android.annotation",
"android.content",
"android.preference",
"android.text",
"android.util",
"java.sql",
"java.util"
] | android.annotation; android.content; android.preference; android.text; android.util; java.sql; java.util; | 702,219 |
@NotNull
@Override
public ChronoPattern mutate(@NotNull ChronoSeries chronoSeries) {
if (seriesPosition >= requireNonNull(chronoSeries).getSize()) {
//start from beginning of series
return new ChronoPattern(chronoScaleUnit, 0, temporalValue);
}
Instant nextTi... | ChronoPattern function(@NotNull ChronoSeries chronoSeries) { if (seriesPosition >= requireNonNull(chronoSeries).getSize()) { return new ChronoPattern(chronoScaleUnit, 0, temporalValue); } Instant nextTimestamp = chronoSeries.getTimestamp(seriesPosition); LocalDateTime nextDateTime = nextTimestamp.atZone(ZoneOffset.UTC)... | /**
* Creates a new ChronoPattern which has progressed in the ChronoSeries by one step.
*
* @param chronoSeries time series data to traverse
* @return new ChronoPattern of the same chrono scale unit with updated temporal pattern value
*/ | Creates a new ChronoPattern which has progressed in the ChronoSeries by one step | mutate | {
"repo_name": "BFergerson/Chronetic",
"path": "src/main/java/io/chronetic/evolution/pool/allele/ChronoPattern.java",
"license": "apache-2.0",
"size": 3932
} | [
"io.chronetic.data.ChronoSeries",
"java.time.Instant",
"java.time.LocalDateTime",
"java.time.ZoneOffset",
"java.util.Objects",
"org.jetbrains.annotations.NotNull"
] | import io.chronetic.data.ChronoSeries; import java.time.Instant; import java.time.LocalDateTime; import java.time.ZoneOffset; import java.util.Objects; import org.jetbrains.annotations.NotNull; | import io.chronetic.data.*; import java.time.*; import java.util.*; import org.jetbrains.annotations.*; | [
"io.chronetic.data",
"java.time",
"java.util",
"org.jetbrains.annotations"
] | io.chronetic.data; java.time; java.util; org.jetbrains.annotations; | 736,612 |
@Test
public void testPreferredBlockSize () {
replication = 3;
preferredBlockSize = 128*1024*1024;
INodeFile inf = createINodeFile(replication, preferredBlockSize);
assertEquals("True has to be returned in this case", preferredBlockSize,
inf.getPreferredBlockSize());
} | void function () { replication = 3; preferredBlockSize = 128*1024*1024; INodeFile inf = createINodeFile(replication, preferredBlockSize); assertEquals(STR, preferredBlockSize, inf.getPreferredBlockSize()); } | /**
* Test for the PreferredBlockSize value. Sets a value and checks if it was
* set correct.
*/ | Test for the PreferredBlockSize value. Sets a value and checks if it was set correct | testPreferredBlockSize | {
"repo_name": "ict-carch/hadoop-plus",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/namenode/TestINodeFile.java",
"license": "apache-2.0",
"size": 33287
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 2,544,590 |
public String sha1(File file) {
return Utils.bytesToHex(
Utils.pathToSha1(
file.getAbsolutePath()));
} | String function(File file) { return Utils.bytesToHex( Utils.pathToSha1( file.getAbsolutePath())); } | /**
* Calculates the local sha1 for a file.
*/ | Calculates the local sha1 for a file | sha1 | {
"repo_name": "hflynn/openmicroscopy",
"path": "components/blitz/src/omero/client.java",
"license": "gpl-2.0",
"size": 40445
} | [
"java.io.File"
] | import java.io.File; | import java.io.*; | [
"java.io"
] | java.io; | 2,623,616 |
public List<MethodAST> getMethods() {
return methods;
}
| List<MethodAST> function() { return methods; } | /**
* List of methods.
*/ | List of methods | getMethods | {
"repo_name": "codeflows/mini-eiffel",
"path": "src/minieiffel/semantics/Signature.java",
"license": "mit",
"size": 1219
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,733,440 |
@Test
public void testFileRenamingOverwrite() throws IOException, PortalServiceException {
service.generateStageInDirectory(job);
final byte[] file1Data = new byte[] {1, 2, 3};
final byte[] file2Data = new byte[] {4, 3, 1};
OutputStream file1 = service.writeFile(job, "testFile... | void function() throws IOException, PortalServiceException { service.generateStageInDirectory(job); final byte[] file1Data = new byte[] {1, 2, 3}; final byte[] file2Data = new byte[] {4, 3, 1}; OutputStream file1 = service.writeFile(job, STR); OutputStream file2 = service.writeFile(job, STR); file1.write(file1Data); fi... | /**
* Tests that creating and renaming files in a job staging area works when the target file already exists
*
* @throws IOException
* @throws PortalServiceException
*/ | Tests that creating and renaming files in a job staging area works when the target file already exists | testFileRenamingOverwrite | {
"repo_name": "victortey/portal-core",
"path": "src/test/java/org/auscope/portal/core/services/cloud/TestFileStagingService.java",
"license": "lgpl-3.0",
"size": 19978
} | [
"java.io.IOException",
"java.io.OutputStream",
"org.auscope.portal.core.services.PortalServiceException",
"org.junit.Assert"
] | import java.io.IOException; import java.io.OutputStream; import org.auscope.portal.core.services.PortalServiceException; import org.junit.Assert; | import java.io.*; import org.auscope.portal.core.services.*; import org.junit.*; | [
"java.io",
"org.auscope.portal",
"org.junit"
] | java.io; org.auscope.portal; org.junit; | 2,237,382 |
@Generated
@Selector("setMaximumDrawableCount:")
public native void setMaximumDrawableCount(@NUInt long value); | @Selector(STR) native void function(@NUInt long value); | /**
* Controls the number maximum number of drawables in the swap queue. The
* default value is 3. Values set outside of range [2, 3] are ignored and an
* exception will be thrown.
*/ | Controls the number maximum number of drawables in the swap queue. The default value is 3. Values set outside of range [2, 3] are ignored and an exception will be thrown | setMaximumDrawableCount | {
"repo_name": "multi-os-engine/moe-core",
"path": "moe.apple/moe.platform.ios/src/main/java/apple/quartzcore/CAMetalLayer.java",
"license": "apache-2.0",
"size": 13534
} | [
"org.moe.natj.general.ann.NUInt",
"org.moe.natj.objc.ann.Selector"
] | import org.moe.natj.general.ann.NUInt; import org.moe.natj.objc.ann.Selector; | import org.moe.natj.general.ann.*; import org.moe.natj.objc.ann.*; | [
"org.moe.natj"
] | org.moe.natj; | 794,026 |
@SimpleProperty(
description = "The name of a file containing the background image for the canvas",
category = PropertyCategory.APPEARANCE)
public String BackgroundImage() {
return backgroundImagePath;
} | @SimpleProperty( description = STR, category = PropertyCategory.APPEARANCE) String function() { return backgroundImagePath; } | /**
* Returns the path of the canvas background image.
*
* @return the path of the canvas background image
*/ | Returns the path of the canvas background image | BackgroundImage | {
"repo_name": "AlanRosenthal/appinventor-sources",
"path": "appinventor/components/src/com/google/appinventor/components/runtime/Canvas.java",
"license": "mit",
"size": 52141
} | [
"com.google.appinventor.components.annotations.PropertyCategory",
"com.google.appinventor.components.annotations.SimpleProperty"
] | import com.google.appinventor.components.annotations.PropertyCategory; import com.google.appinventor.components.annotations.SimpleProperty; | import com.google.appinventor.components.annotations.*; | [
"com.google.appinventor"
] | com.google.appinventor; | 2,474,688 |
public static boolean canOpenIndex(Logger logger, Path indexLocation, ShardId shardId, NodeEnvironment.ShardLocker shardLocker) throws IOException {
try {
tryOpenIndex(indexLocation, shardId, shardLocker, logger);
} catch (Exception ex) {
logger.trace((Supplier<?>) () -> new ... | static boolean function(Logger logger, Path indexLocation, ShardId shardId, NodeEnvironment.ShardLocker shardLocker) throws IOException { try { tryOpenIndex(indexLocation, shardId, shardLocker, logger); } catch (Exception ex) { logger.trace((Supplier<?>) () -> new ParameterizedMessage(STR, indexLocation), ex); return f... | /**
* Returns <code>true</code> iff the given location contains an index an the index
* can be successfully opened. This includes reading the segment infos and possible
* corruption markers.
*/ | Returns <code>true</code> iff the given location contains an index an the index can be successfully opened. This includes reading the segment infos and possible corruption markers | canOpenIndex | {
"repo_name": "maddin2016/elasticsearch",
"path": "core/src/main/java/org/elasticsearch/index/store/Store.java",
"license": "apache-2.0",
"size": 67230
} | [
"java.io.IOException",
"java.nio.file.Path",
"org.apache.logging.log4j.Logger",
"org.apache.logging.log4j.message.ParameterizedMessage",
"org.apache.logging.log4j.util.Supplier",
"org.elasticsearch.env.NodeEnvironment",
"org.elasticsearch.index.shard.ShardId"
] | import java.io.IOException; import java.nio.file.Path; import org.apache.logging.log4j.Logger; import org.apache.logging.log4j.message.ParameterizedMessage; import org.apache.logging.log4j.util.Supplier; import org.elasticsearch.env.NodeEnvironment; import org.elasticsearch.index.shard.ShardId; | import java.io.*; import java.nio.file.*; import org.apache.logging.log4j.*; import org.apache.logging.log4j.message.*; import org.apache.logging.log4j.util.*; import org.elasticsearch.env.*; import org.elasticsearch.index.shard.*; | [
"java.io",
"java.nio",
"org.apache.logging",
"org.elasticsearch.env",
"org.elasticsearch.index"
] | java.io; java.nio; org.apache.logging; org.elasticsearch.env; org.elasticsearch.index; | 205,720 |
public static synchronized List<String> getFieldNames()
{
if (fieldNames == null)
{
fieldNames = new ArrayList<String>();
fieldNames.add("ObjectID");
fieldNames.add("FirstName");
fieldNames.add("LastName");
fieldNames.add("LoginName");
... | static synchronized List<String> function() { if (fieldNames == null) { fieldNames = new ArrayList<String>(); fieldNames.add(STR); fieldNames.add(STR); fieldNames.add(STR); fieldNames.add(STR); fieldNames.add("Email"); fieldNames.add(STR); fieldNames.add("Salt"); fieldNames.add(STR); fieldNames.add("Phone"); fieldNames... | /**
* Generate a list of field names.
*
* @return a list of field names
*/ | Generate a list of field names | getFieldNames | {
"repo_name": "trackplus/Genji",
"path": "src/main/java/com/aurel/track/persist/BaseTPerson.java",
"license": "gpl-3.0",
"size": 1013508
} | [
"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,207,091 |
public Set<String> getDetailPageTypes(CmsObject cms) {
return getCacheState(isOnline(cms)).getDetailPageTypes();
} | Set<String> function(CmsObject cms) { return getCacheState(isOnline(cms)).getDetailPageTypes(); } | /**
* Gets the set of types for which detail pages are defined.<p>
*
* @param cms the current CMS context
*
* @return the set of types for which detail pages are defined
*/ | Gets the set of types for which detail pages are defined | getDetailPageTypes | {
"repo_name": "ggiudetti/opencms-core",
"path": "src/org/opencms/ade/configuration/CmsADEManager.java",
"license": "lgpl-2.1",
"size": 50482
} | [
"java.util.Set",
"org.opencms.file.CmsObject"
] | import java.util.Set; import org.opencms.file.CmsObject; | import java.util.*; import org.opencms.file.*; | [
"java.util",
"org.opencms.file"
] | java.util; org.opencms.file; | 548,141 |
@Override
protected AmazonKinesisClient createClient(final ProcessContext context, final AWSCredentials credentials, final ClientConfiguration config) {
getLogger().info("Creating client using aws credentials");
return createClient(context, new AWSStaticCredentialsProvider(credentials), config)... | AmazonKinesisClient function(final ProcessContext context, final AWSCredentials credentials, final ClientConfiguration config) { getLogger().info(STR); return createClient(context, new AWSStaticCredentialsProvider(credentials), config); } | /**
* Create client using AWSCredentails
*
* @deprecated use {@link #createClient(ProcessContext, AWSCredentialsProvider, ClientConfiguration)} instead
*/ | Create client using AWSCredentails | createClient | {
"repo_name": "MikeThomsen/nifi",
"path": "nifi-nar-bundles/nifi-aws-bundle/nifi-aws-abstract-processors/src/main/java/org/apache/nifi/processors/aws/kinesis/stream/AbstractKinesisStreamProcessor.java",
"license": "apache-2.0",
"size": 2890
} | [
"com.amazonaws.ClientConfiguration",
"com.amazonaws.auth.AWSCredentials",
"com.amazonaws.auth.AWSStaticCredentialsProvider",
"com.amazonaws.services.kinesis.AmazonKinesisClient",
"org.apache.nifi.processor.ProcessContext"
] | import com.amazonaws.ClientConfiguration; import com.amazonaws.auth.AWSCredentials; import com.amazonaws.auth.AWSStaticCredentialsProvider; import com.amazonaws.services.kinesis.AmazonKinesisClient; import org.apache.nifi.processor.ProcessContext; | import com.amazonaws.*; import com.amazonaws.auth.*; import com.amazonaws.services.kinesis.*; import org.apache.nifi.processor.*; | [
"com.amazonaws",
"com.amazonaws.auth",
"com.amazonaws.services",
"org.apache.nifi"
] | com.amazonaws; com.amazonaws.auth; com.amazonaws.services; org.apache.nifi; | 2,488,620 |
protected final Graphics2D createTextGraphics(double x, double y, double w,
double h, double rotation, boolean clip, String align,
String valign)
{
Graphics2D g2 = state.g;
updateFont();
if (rotation != 0)
{
g2 = (Graphics2D) state.g.create();
double rad = rotation * (Math.PI / 180);
g2.rot... | final Graphics2D function(double x, double y, double w, double h, double rotation, boolean clip, String align, String valign) { Graphics2D g2 = state.g; updateFont(); if (rotation != 0) { g2 = (Graphics2D) state.g.create(); double rad = rotation * (Math.PI / 180); g2.rotate(rad, x, y); } if (clip && w > 0 && h > 0) { i... | /**
* Returns a new graphics instance with the correct color and font for
* text rendering.
*/ | Returns a new graphics instance with the correct color and font for text rendering | createTextGraphics | {
"repo_name": "jgraph/mxgraph",
"path": "java/src/com/mxgraph/canvas/mxGraphicsCanvas2D.java",
"license": "apache-2.0",
"size": 36666
} | [
"java.awt.Graphics2D",
"java.awt.geom.Point2D",
"java.awt.geom.Rectangle2D"
] | import java.awt.Graphics2D; import java.awt.geom.Point2D; import java.awt.geom.Rectangle2D; | import java.awt.*; import java.awt.geom.*; | [
"java.awt"
] | java.awt; | 2,119,222 |
@OnClassLoadEvent(classNameRegexp = "org.jboss.weld.environment.deployment.WeldBeanDeploymentArchive")
public static void transform(CtClass clazz, ClassPool classPool) throws NotFoundException, CannotCompileException {
CtClass[] constructorParams = new CtClass[] {
classPool.get("java.lang.S... | @OnClassLoadEvent(classNameRegexp = STR) static void function(CtClass clazz, ClassPool classPool) throws NotFoundException, CannotCompileException { CtClass[] constructorParams = new CtClass[] { classPool.get(STR), classPool.get(STR), classPool.get(STR), classPool.get(STR) }; StringBuilder src = new StringBuilder("{");... | /**
* Basic WeldBeanDeploymentArchive transformation.
*
* @param clazz
* @param classPool
* @throws NotFoundException
* @throws CannotCompileException
*/ | Basic WeldBeanDeploymentArchive transformation | transform | {
"repo_name": "ntkphung/HotswapAgent",
"path": "plugin/hotswap-agent-weld-plugin/src/main/java/org/hotswap/agent/plugin/weld/BeanDeploymentArchiveTransformer.java",
"license": "gpl-2.0",
"size": 3999
} | [
"org.hotswap.agent.annotation.OnClassLoadEvent",
"org.hotswap.agent.javassist.CannotCompileException",
"org.hotswap.agent.javassist.ClassPool",
"org.hotswap.agent.javassist.CtClass",
"org.hotswap.agent.javassist.CtConstructor",
"org.hotswap.agent.javassist.NotFoundException",
"org.hotswap.agent.util.Plu... | import org.hotswap.agent.annotation.OnClassLoadEvent; import org.hotswap.agent.javassist.CannotCompileException; import org.hotswap.agent.javassist.ClassPool; import org.hotswap.agent.javassist.CtClass; import org.hotswap.agent.javassist.CtConstructor; import org.hotswap.agent.javassist.NotFoundException; import org.ho... | import org.hotswap.agent.annotation.*; import org.hotswap.agent.javassist.*; import org.hotswap.agent.util.*; | [
"org.hotswap.agent"
] | org.hotswap.agent; | 2,742,895 |
public static void bind(ServerSocket socket, InetSocketAddress address,
int backlog) throws IOException {
try {
socket.bind(address, backlog);
} catch (BindException e) {
BindException bindException = new BindException("Problem binding to " + address
... | static void function(ServerSocket socket, InetSocketAddress address, int backlog) throws IOException { try { socket.bind(address, backlog); } catch (BindException e) { BindException bindException = new BindException(STR + address + STR + e.getMessage()); bindException.initCause(e); throw bindException; } catch (SocketE... | /**
* A convenience method to bind to a given address and report
* better exceptions if the address is not a valid host.
* @param socket the socket to bind
* @param address the address to bind to
* @param backlog the number of connections allowed in the queue
* @throws BindException if the address ca... | A convenience method to bind to a given address and report better exceptions if the address is not a valid host | bind | {
"repo_name": "submergerock/avatar-hadoop",
"path": "src/core/org/apache/hadoop/ipc/Server.java",
"license": "apache-2.0",
"size": 47109
} | [
"java.io.IOException",
"java.net.BindException",
"java.net.InetSocketAddress",
"java.net.ServerSocket",
"java.net.SocketException",
"java.net.UnknownHostException",
"java.nio.ByteBuffer",
"org.apache.hadoop.io.Writable"
] | import java.io.IOException; import java.net.BindException; import java.net.InetSocketAddress; import java.net.ServerSocket; import java.net.SocketException; import java.net.UnknownHostException; import java.nio.ByteBuffer; import org.apache.hadoop.io.Writable; | import java.io.*; import java.net.*; import java.nio.*; import org.apache.hadoop.io.*; | [
"java.io",
"java.net",
"java.nio",
"org.apache.hadoop"
] | java.io; java.net; java.nio; org.apache.hadoop; | 1,667,094 |
public void updateEmoji(@NonNull final Emoji emoji) {
if (!emoji.equals(currentEmoji)) {
currentEmoji = emoji;
setImageDrawable(emoji.getDrawable(this.getContext()));
}
} | void function(@NonNull final Emoji emoji) { if (!emoji.equals(currentEmoji)) { currentEmoji = emoji; setImageDrawable(emoji.getDrawable(this.getContext())); } } | /**
* Updates the emoji image directly. This should be called only for updating the variant
* displayed (of the same base emoji), since it does not run asynchronously and does not update
* the internal listeners.
*
* @param emoji The new emoji variant to show.
*/ | Updates the emoji image directly. This should be called only for updating the variant displayed (of the same base emoji), since it does not run asynchronously and does not update the internal listeners | updateEmoji | {
"repo_name": "vanniktech/Emoji",
"path": "emoji/src/main/java/com/vanniktech/emoji/EmojiImageView.java",
"license": "apache-2.0",
"size": 5354
} | [
"androidx.annotation.NonNull",
"com.vanniktech.emoji.emoji.Emoji"
] | import androidx.annotation.NonNull; import com.vanniktech.emoji.emoji.Emoji; | import androidx.annotation.*; import com.vanniktech.emoji.emoji.*; | [
"androidx.annotation",
"com.vanniktech.emoji"
] | androidx.annotation; com.vanniktech.emoji; | 2,066,924 |
@Config("ness.discovery.root")
@Default("/ness/srvc")
public String getRoot()
{
return "/ness/srvc";
} | @Config(STR) @Default(STR) String function() { return STR; } | /**
* Root of the service discovery tree. Defaults to "/ness/srvc".
*/ | Root of the service discovery tree. Defaults to "/ness/srvc" | getRoot | {
"repo_name": "NessComputing/service-discovery",
"path": "server/src/main/java/com/nesscomputing/service/discovery/server/DiscoveryServerConfig.java",
"license": "apache-2.0",
"size": 988
} | [
"org.skife.config.Config",
"org.skife.config.Default"
] | import org.skife.config.Config; import org.skife.config.Default; | import org.skife.config.*; | [
"org.skife.config"
] | org.skife.config; | 496,719 |
@Test
public void testSpecifiedDefaultSpecifiedPrefixWriteAttributeNoDeclarationGeneration() throws Exception {
final String EXPECTED_OUTPUT = "<?xml version=\"1.0\" ?>"
+ "<root xmlns=\"http://example.org/uniqueURI\" xmlns:p=\"http://example.org/myURI\" p:attrName=\"value\">"
... | void function() throws Exception { final String EXPECTED_OUTPUT = STR1.0\STR + STRhttp: + STR + STR; startDocumentSpecifiedDefaultNamespace(xmlStreamWriter); xmlStreamWriter.writeNamespace("p", STRpSTRhttp: xmlStreamWriter.writeCharacters(STR); String actualOutput = endDocumentEmptyDefaultNamespace(xmlStreamWriter); if... | /**
* Current default namespace is "http://example.org/uniqueURI".
*
* writeAttribute("p", "http://example.org/myURI", "attrName", "value")
*
* requires no fixup, but should generate a declaration for "p":
* xmlns:p="http://example.org/myURI" if necessary
*
* test case where it i... | Current default namespace is "HREF". writeAttribute("p", "HREF", "attrName", "value") requires no fixup, but should generate a declaration for "p": xmlns:p="HREF" if necessary test case where it is not necessary to generate a declaration | testSpecifiedDefaultSpecifiedPrefixWriteAttributeNoDeclarationGeneration | {
"repo_name": "md-5/jdk10",
"path": "test/jaxp/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NamespaceTest.java",
"license": "gpl-2.0",
"size": 64867
} | [
"org.testng.Assert"
] | import org.testng.Assert; | import org.testng.*; | [
"org.testng"
] | org.testng; | 2,855,924 |
public String checksumRows(final Table table) throws Exception {
Scan scan = new Scan();
ResultScanner results = table.getScanner(scan);
MessageDigest digest = MessageDigest.getInstance("MD5");
for (Result res : results) {
digest.update(res.getRow());
}
results.close();
return diges... | String function(final Table table) throws Exception { Scan scan = new Scan(); ResultScanner results = table.getScanner(scan); MessageDigest digest = MessageDigest.getInstance("MD5"); for (Result res : results) { digest.update(res.getRow()); } results.close(); return digest.toString(); } public static final byte[][] ROW... | /**
* Return an md5 digest of the entire contents of a table.
*/ | Return an md5 digest of the entire contents of a table | checksumRows | {
"repo_name": "SeekerResource/hbase",
"path": "hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java",
"license": "apache-2.0",
"size": 145665
} | [
"java.security.MessageDigest",
"org.apache.hadoop.hbase.client.Result",
"org.apache.hadoop.hbase.client.ResultScanner",
"org.apache.hadoop.hbase.client.Scan",
"org.apache.hadoop.hbase.client.Table",
"org.apache.hadoop.hbase.util.Bytes"
] | import java.security.MessageDigest; import org.apache.hadoop.hbase.client.Result; import org.apache.hadoop.hbase.client.ResultScanner; import org.apache.hadoop.hbase.client.Scan; import org.apache.hadoop.hbase.client.Table; import org.apache.hadoop.hbase.util.Bytes; | import java.security.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.util.*; | [
"java.security",
"org.apache.hadoop"
] | java.security; org.apache.hadoop; | 16,763 |
public Builder setAlgorithmParameterSpec(@NonNull AlgorithmParameterSpec spec) {
if (spec == null) {
throw new NullPointerException("spec == null");
}
mSpec = spec;
return this;
} | Builder function(@NonNull AlgorithmParameterSpec spec) { if (spec == null) { throw new NullPointerException(STR); } mSpec = spec; return this; } | /**
* Sets the algorithm-specific key generation parameters. For example, for RSA keys this may
* be an instance of {@link java.security.spec.RSAKeyGenParameterSpec} whereas for EC keys
* this may be an instance of {@link java.security.spec.ECGenParameterSpec}.
*
* <p>These ... | Sets the algorithm-specific key generation parameters. For example, for RSA keys this may be an instance of <code>java.security.spec.RSAKeyGenParameterSpec</code> whereas for EC keys this may be an instance of <code>java.security.spec.ECGenParameterSpec</code>. These key generation parameters must match other explicitl... | setAlgorithmParameterSpec | {
"repo_name": "Ant-Droid/android_frameworks_base_OLD",
"path": "keystore/java/android/security/keystore/KeyGenParameterSpec.java",
"license": "apache-2.0",
"size": 44139
} | [
"android.annotation.NonNull",
"java.security.spec.AlgorithmParameterSpec"
] | import android.annotation.NonNull; import java.security.spec.AlgorithmParameterSpec; | import android.annotation.*; import java.security.spec.*; | [
"android.annotation",
"java.security"
] | android.annotation; java.security; | 1,028,981 |
public void setNodeDao(NodeDao nodeDao) {
m_nodeDao = nodeDao;
} | void function(NodeDao nodeDao) { m_nodeDao = nodeDao; } | /**
* Sets the NodeDao object for this instance.
*
* @param nodeDao the NodeDao object to use
*/ | Sets the NodeDao object for this instance | setNodeDao | {
"repo_name": "RangerRick/opennms",
"path": "integrations/opennms-vmware/src/main/java/org/opennms/netmgt/poller/monitors/VmwareCimMonitor.java",
"license": "gpl-2.0",
"size": 10733
} | [
"org.opennms.netmgt.dao.NodeDao"
] | import org.opennms.netmgt.dao.NodeDao; | import org.opennms.netmgt.dao.*; | [
"org.opennms.netmgt"
] | org.opennms.netmgt; | 1,219,687 |
RemoteNodeType getRemoteNodeType(NodeType type) throws RemoteException;
/**
* Returns a remote adapter for the given local item definition.
* This method will return an adapter that implements <i>only</i> the
* {@link ItemDefinition ItemDefinition} interface. The caller may want to introspect
... | RemoteNodeType getRemoteNodeType(NodeType type) throws RemoteException; /** * Returns a remote adapter for the given local item definition. * This method will return an adapter that implements <i>only</i> the * {@link ItemDefinition ItemDefinition} interface. The caller may want to introspect * the local item definitio... | /**
* Returns a remote adapter for the given local node type.
*
* @param type local node type
* @return remote node type adapter
* @throws RemoteException on RMI errors
*/ | Returns a remote adapter for the given local node type | getRemoteNodeType | {
"repo_name": "apache/jackrabbit",
"path": "jackrabbit-jcr-rmi/src/main/java/org/apache/jackrabbit/rmi/server/RemoteAdapterFactory.java",
"license": "apache-2.0",
"size": 17504
} | [
"java.rmi.RemoteException",
"javax.jcr.nodetype.ItemDefinition",
"javax.jcr.nodetype.NodeDefinition",
"javax.jcr.nodetype.NodeType",
"javax.jcr.nodetype.PropertyDefinition",
"org.apache.jackrabbit.rmi.remote.RemoteNodeType"
] | import java.rmi.RemoteException; import javax.jcr.nodetype.ItemDefinition; import javax.jcr.nodetype.NodeDefinition; import javax.jcr.nodetype.NodeType; import javax.jcr.nodetype.PropertyDefinition; import org.apache.jackrabbit.rmi.remote.RemoteNodeType; | import java.rmi.*; import javax.jcr.nodetype.*; import org.apache.jackrabbit.rmi.remote.*; | [
"java.rmi",
"javax.jcr",
"org.apache.jackrabbit"
] | java.rmi; javax.jcr; org.apache.jackrabbit; | 1,491,759 |
Versioned<V> value(); | Versioned<V> value(); | /**
* Returns the value of this node.
*
* @return node value (and version)
*/ | Returns the value of this node | value | {
"repo_name": "atomix/atomix",
"path": "core/src/main/java/io/atomix/core/tree/DocumentTreeNode.java",
"license": "apache-2.0",
"size": 1780
} | [
"io.atomix.utils.time.Versioned"
] | import io.atomix.utils.time.Versioned; | import io.atomix.utils.time.*; | [
"io.atomix.utils"
] | io.atomix.utils; | 896,672 |
@Override
public TemDistributionAccountingLine getAccountDistributionnewSourceLine() {
return accountDistributionnewSourceLine;
}
| TemDistributionAccountingLine function() { return accountDistributionnewSourceLine; } | /**
* Gets the accountDistributionnewSourceLine attribute.
*
* @return Returns the accountDistributionnewSourceLine.
*/ | Gets the accountDistributionnewSourceLine attribute | getAccountDistributionnewSourceLine | {
"repo_name": "ua-eas/ua-kfs-5.3",
"path": "work/src/org/kuali/kfs/module/tem/document/web/struts/TravelFormBase.java",
"license": "agpl-3.0",
"size": 42795
} | [
"org.kuali.kfs.module.tem.businessobject.TemDistributionAccountingLine"
] | import org.kuali.kfs.module.tem.businessobject.TemDistributionAccountingLine; | import org.kuali.kfs.module.tem.businessobject.*; | [
"org.kuali.kfs"
] | org.kuali.kfs; | 2,151,981 |
ServiceFuture<Void> paramDatetimeAsync(String scenario, DateTime value, final ServiceCallback<Void> serviceCallback); | ServiceFuture<Void> paramDatetimeAsync(String scenario, DateTime value, final ServiceCallback<Void> serviceCallback); | /**
* Send a post request with header values "scenario": "valid", "value": "2010-01-01T12:34:56Z" or "scenario": "min", "value": "0001-01-01T00:00:00Z".
*
* @param scenario Send a post request with header values "scenario": "valid" or "min"
* @param value Send a post request with header values "2010... | Send a post request with header values "scenario": "valid", "value": "2010-01-01T12:34:56Z" or "scenario": "min", "value": "0001-01-01T00:00:00Z" | paramDatetimeAsync | {
"repo_name": "lmazuel/autorest",
"path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/header/Headers.java",
"license": "mit",
"size": 69419
} | [
"com.microsoft.rest.ServiceCallback",
"com.microsoft.rest.ServiceFuture",
"org.joda.time.DateTime"
] | import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture; import org.joda.time.DateTime; | import com.microsoft.rest.*; import org.joda.time.*; | [
"com.microsoft.rest",
"org.joda.time"
] | com.microsoft.rest; org.joda.time; | 1,733,513 |
@Override
public long getPos() throws IOException {
return ((Seekable)in).getPos();
} | long function() throws IOException { return ((Seekable)in).getPos(); } | /**
* Get the current position in the input stream.
*
* @return current position in the input stream
*/ | Get the current position in the input stream | getPos | {
"repo_name": "apurtell/hadoop",
"path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FSDataInputStream.java",
"license": "apache-2.0",
"size": 9457
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 2,770,528 |
@Test
public void testUnchecked() {
Future<String> future = Future.value("hi");
try {
String s = Await.result(future);
Assert.assertEquals("hi", s);
} catch (Exception e) {
Throwables.unchecked(e);
}
} | void function() { Future<String> future = Future.value("hi"); try { String s = Await.result(future); Assert.assertEquals("hi", s); } catch (Exception e) { Throwables.unchecked(e); } } | /**
* Note the lack of `throws Excepton` on the method declaration.
*/ | Note the lack of `throws Excepton` on the method declaration | testUnchecked | {
"repo_name": "folone/util",
"path": "util-core/src/test/java/com/twitter/util/ThrowablesCompilationTest.java",
"license": "apache-2.0",
"size": 477
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 1,596,606 |
@ServiceMethod(returns = ReturnType.SINGLE)
public PollerFlux<PollResult<Void>, Void> beginDeleteByIdAsync(String resourceId, String apiVersion) {
Mono<Response<Flux<ByteBuffer>>> mono = deleteByIdWithResponseAsync(resourceId, apiVersion);
return this
.client
.<Void, Void... | @ServiceMethod(returns = ReturnType.SINGLE) PollerFlux<PollResult<Void>, Void> function(String resourceId, String apiVersion) { Mono<Response<Flux<ByteBuffer>>> mono = deleteByIdWithResponseAsync(resourceId, apiVersion); return this .client .<Void, Void>getLroResult( mono, this.client.getHttpPipeline(), Void.class, Voi... | /**
* Deletes a resource by ID.
*
* @param resourceId The fully qualified ID of the resource, including the resource name and resource type. Use the
* format,
* /subscriptions/{guid}/resourceGroups/{resource-group-name}/{resource-provider-namespace}/{resource-type}/{resource-name}.
... | Deletes a resource by ID | beginDeleteByIdAsync | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/resourcemanagerhybrid/azure-resourcemanager-resources/src/main/java/com/azure/resourcemanager/resources/implementation/ResourcesClientImpl.java",
"license": "mit",
"size": 224761
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.core.http.rest.Response",
"com.azure.core.management.polling.PollResult",
"com.azure.core.util.polling.PollerFlux",
"java.nio.ByteBuffer"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.core.management.polling.PollResult; import com.azure.core.util.polling.PollerFlux; import java.nio.ByteBuffer; | import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.management.polling.*; import com.azure.core.util.polling.*; import java.nio.*; | [
"com.azure.core",
"java.nio"
] | com.azure.core; java.nio; | 1,613,207 |
public static ZonedDateTimeMatcher sameInstant(ZonedDateTime date) {
return new ZonedDateTimeMatcher(date);
} | static ZonedDateTimeMatcher function(ZonedDateTime date) { return new ZonedDateTimeMatcher(date); } | /**
* Creates a matcher that matches when the examined string reprensents the same instant as the reference datetime
* @param date the reference datetime against which the examined string is checked
*/ | Creates a matcher that matches when the examined string reprensents the same instant as the reference datetime | sameInstant | {
"repo_name": "benoyprakash/java-hostel",
"path": "JHipster-hostel/src/test/java/com/hostel/web/rest/TestUtil.java",
"license": "apache-2.0",
"size": 4418
} | [
"java.time.ZonedDateTime"
] | import java.time.ZonedDateTime; | import java.time.*; | [
"java.time"
] | java.time; | 2,618,039 |
private void startLocalOutputBuild(String workspaceName) throws ExecutorInitException {
try (AutoProfiler p = AutoProfiler.profiled("Starting local output build", ProfilerTask.INFO)) {
Path outputPath = env.getDirectories().getOutputPath(workspaceName);
Path localOutputPath = env.getDirectories().getL... | void function(String workspaceName) throws ExecutorInitException { try (AutoProfiler p = AutoProfiler.profiled(STR, ProfilerTask.INFO)) { Path outputPath = env.getDirectories().getOutputPath(workspaceName); Path localOutputPath = env.getDirectories().getLocalOutputPath(); if (outputPath.isSymbolicLink()) { try { output... | /**
* Prepare for a local output build.
*/ | Prepare for a local output build | startLocalOutputBuild | {
"repo_name": "iamthearm/bazel",
"path": "src/main/java/com/google/devtools/build/lib/buildtool/ExecutionTool.java",
"license": "apache-2.0",
"size": 31638
} | [
"com.google.devtools.build.lib.actions.ExecutorInitException",
"com.google.devtools.build.lib.profiler.AutoProfiler",
"com.google.devtools.build.lib.profiler.ProfilerTask",
"com.google.devtools.build.lib.vfs.Path",
"java.io.IOException"
] | import com.google.devtools.build.lib.actions.ExecutorInitException; import com.google.devtools.build.lib.profiler.AutoProfiler; import com.google.devtools.build.lib.profiler.ProfilerTask; import com.google.devtools.build.lib.vfs.Path; import java.io.IOException; | import com.google.devtools.build.lib.actions.*; import com.google.devtools.build.lib.profiler.*; import com.google.devtools.build.lib.vfs.*; import java.io.*; | [
"com.google.devtools",
"java.io"
] | com.google.devtools; java.io; | 2,244,052 |
public static Generator<Matrix4x4F> create()
{
return new Matrix4x4FGenerator(PrimitiveGenerators.doubles(
GeneratorConstants.BOUND_LARGE_FLOAT_LOWER,
GeneratorConstants.BOUND_LARGE_FLOAT_UPPER
));
} | static Generator<Matrix4x4F> function() { return new Matrix4x4FGenerator(PrimitiveGenerators.doubles( GeneratorConstants.BOUND_LARGE_FLOAT_LOWER, GeneratorConstants.BOUND_LARGE_FLOAT_UPPER )); } | /**
* Create a generator initialized with a default component generator.
*
* @return A generator
*/ | Create a generator initialized with a default component generator | create | {
"repo_name": "io7m/jtensors",
"path": "com.io7m.jtensors.generators/src/main/java/com/io7m/jtensors/generators/Matrix4x4FGenerator.java",
"license": "isc",
"size": 3826
} | [
"com.io7m.jtensors.core.unparameterized.matrices.Matrix4x4F",
"net.java.quickcheck.Generator",
"net.java.quickcheck.generator.PrimitiveGenerators"
] | import com.io7m.jtensors.core.unparameterized.matrices.Matrix4x4F; import net.java.quickcheck.Generator; import net.java.quickcheck.generator.PrimitiveGenerators; | import com.io7m.jtensors.core.unparameterized.matrices.*; import net.java.quickcheck.*; import net.java.quickcheck.generator.*; | [
"com.io7m.jtensors",
"net.java.quickcheck"
] | com.io7m.jtensors; net.java.quickcheck; | 1,317,562 |
void initializeComponent(Application application);
}
public static Application app = null;
public static File tempDirectory;
public static final String LOG_TAG = "com.daxslab.mail";
private static final String DATABASE_VERSION_CACHE = "database_version_cache";
private static... | void initializeComponent(Application application); } public static Application app = null; public static File tempDirectory; public static final String LOG_TAG = STR; private static final String DATABASE_VERSION_CACHE = STR; private static final String KEY_LAST_ACCOUNT_DATABASE_VERSION = STR; private static List<Applic... | /**
* Called when the Application instance is available and ready.
*
* @param application
* The application instance. Never <code>null</code>.
* @throws Exception
*/ | Called when the Application instance is available and ready | initializeComponent | {
"repo_name": "daxslab/daxSmail",
"path": "src/com/daxslab/mail/K9.java",
"license": "apache-2.0",
"size": 52453
} | [
"android.app.Application",
"java.io.File",
"java.util.ArrayList",
"java.util.List"
] | import android.app.Application; import java.io.File; import java.util.ArrayList; import java.util.List; | import android.app.*; import java.io.*; import java.util.*; | [
"android.app",
"java.io",
"java.util"
] | android.app; java.io; java.util; | 1,304,477 |
public static int updateRow (PreparedStatement ps,long updateWhere) {
try {
int val=0;
synchronized(lock) {
val = counter++;
}
ps.setInt(1,val);
ps.setLong(2,updateWhere);
return(ps.executeUpdate());
} catch (SQLException se) {
se.printStackTrace();
return 0;
}
} | static int function (PreparedStatement ps,long updateWhere) { try { int val=0; synchronized(lock) { val = counter++; } ps.setInt(1,val); ps.setLong(2,updateWhere); return(ps.executeUpdate()); } catch (SQLException se) { se.printStackTrace(); return 0; } } | /**
* update a row in the table
* updateWhere is the value of the t_key row which needs to be updated
* return number of rows updated
*/ | update a row in the table updateWhere is the value of the t_key row which needs to be updated return number of rows updated | updateRow | {
"repo_name": "WhiteBearSolutions/WBSAirback",
"path": "packages/wbsairback-java/wbsairback-java-7.0.1/usr/share/wbsairback/java/demo/db/programs/nserverdemo/NsSampleClientThread.java",
"license": "apache-2.0",
"size": 13691
} | [
"java.sql.PreparedStatement",
"java.sql.SQLException"
] | import java.sql.PreparedStatement; import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 2,387,856 |
@Override
public Credentials getCredentials() {
return credentials;
} | Credentials function() { return credentials; } | /**
* Returns the credentials given during authentication by this user.
*
* @return
* The credentials given during authentication by this user.
*/ | Returns the credentials given during authentication by this user | getCredentials | {
"repo_name": "Calvin-CS/Agora",
"path": "guacamole-client/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/glyptodon/guacamole/auth/jdbc/user/AuthenticatedUser.java",
"license": "gpl-3.0",
"size": 5797
} | [
"org.glyptodon.guacamole.net.auth.Credentials"
] | import org.glyptodon.guacamole.net.auth.Credentials; | import org.glyptodon.guacamole.net.auth.*; | [
"org.glyptodon.guacamole"
] | org.glyptodon.guacamole; | 15,578 |
public void removeCreationListener(CreatedJingleSessionListener createdJingleSessionListener) {
this.creationListeners.remove(createdJingleSessionListener);
} | void function(CreatedJingleSessionListener createdJingleSessionListener) { this.creationListeners.remove(createdJingleSessionListener); } | /**
* Removes a CreatedJingleSessionListener.
* This listener will be called when a session is created by the JingleManager instance.
*
* @param createdJingleSessionListener
*/ | Removes a CreatedJingleSessionListener. This listener will be called when a session is created by the JingleManager instance | removeCreationListener | {
"repo_name": "UzxMx/java-bells",
"path": "lib-src/smack_src_3_3_0/jingle/extension/source/org/jivesoftware/smackx/jingle/JingleManager.java",
"license": "bsd-3-clause",
"size": 25845
} | [
"org.jivesoftware.smackx.jingle.listeners.CreatedJingleSessionListener"
] | import org.jivesoftware.smackx.jingle.listeners.CreatedJingleSessionListener; | import org.jivesoftware.smackx.jingle.listeners.*; | [
"org.jivesoftware.smackx"
] | org.jivesoftware.smackx; | 2,348,666 |
final Map<String, List<AnalystClassItem>> map =
new HashMap<String, List<AnalystClassItem>>();
boolean first = true;
for (final String line : section.getLines()) {
if (!first) {
final List<String> cols = EncogFileSection.splitColumns(line);
... | final Map<String, List<AnalystClassItem>> map = new HashMap<String, List<AnalystClassItem>>(); boolean first = true; for (final String line : section.getLines()) { if (!first) { final List<String> cols = EncogFileSection.splitColumns(line); if (cols.size() < COLUMN_FOUR) { throw new AnalystError(STR + line); } final St... | /**
* Handle loading the data classes.
* <p/>
* @param section
* The section being loaded.
*/ | Handle loading the data classes. | handleDataClasses | {
"repo_name": "ladygagapowerbot/bachelor-thesis-implementation",
"path": "lib/Encog/src/main/java/org/encog/app/analyst/script/ScriptLoad.java",
"license": "mit",
"size": 18420
} | [
"java.util.ArrayList",
"java.util.Collections",
"java.util.HashMap",
"java.util.List",
"java.util.Map",
"org.encog.app.analyst.AnalystError",
"org.encog.persist.EncogFileSection"
] | import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; import org.encog.app.analyst.AnalystError; import org.encog.persist.EncogFileSection; | import java.util.*; import org.encog.app.analyst.*; import org.encog.persist.*; | [
"java.util",
"org.encog.app",
"org.encog.persist"
] | java.util; org.encog.app; org.encog.persist; | 2,760,476 |
public void setAccrualTransactionsExceptionReportWriterService(ReportWriterService accrualTransactionsExceptionReportWriterService) {
this.accrualTransactionsExceptionReportWriterService = accrualTransactionsExceptionReportWriterService;
}
| void function(ReportWriterService accrualTransactionsExceptionReportWriterService) { this.accrualTransactionsExceptionReportWriterService = accrualTransactionsExceptionReportWriterService; } | /**
* Sets the accrualTransactionsExceptionReportWriterService.
*
* @param accrualTransactionsExceptionReportWriterService
*/ | Sets the accrualTransactionsExceptionReportWriterService | setAccrualTransactionsExceptionReportWriterService | {
"repo_name": "ua-eas/ua-kfs-5.3",
"path": "work/src/org/kuali/kfs/module/endow/batch/service/impl/CreateAccrualTransactionsServiceImpl.java",
"license": "agpl-3.0",
"size": 26191
} | [
"org.kuali.kfs.sys.service.ReportWriterService"
] | import org.kuali.kfs.sys.service.ReportWriterService; | import org.kuali.kfs.sys.service.*; | [
"org.kuali.kfs"
] | org.kuali.kfs; | 1,406,538 |
public void setDocFileVersionPersistence(
DocFileVersionPersistence docFileVersionPersistence) {
this.docFileVersionPersistence = docFileVersionPersistence;
} | void function( DocFileVersionPersistence docFileVersionPersistence) { this.docFileVersionPersistence = docFileVersionPersistence; } | /**
* Sets the doc file version persistence.
*
* @param docFileVersionPersistence the doc file version persistence
*/ | Sets the doc file version persistence | setDocFileVersionPersistence | {
"repo_name": "openegovplatform/OEPv2",
"path": "oep-core-dossiermgt-portlet/docroot/WEB-INF/src/org/oep/core/dossiermgt/service/base/ProfileDataServiceBaseImpl.java",
"license": "apache-2.0",
"size": 50258
} | [
"org.oep.core.dossiermgt.service.persistence.DocFileVersionPersistence"
] | import org.oep.core.dossiermgt.service.persistence.DocFileVersionPersistence; | import org.oep.core.dossiermgt.service.persistence.*; | [
"org.oep.core"
] | org.oep.core; | 1,832,794 |
public static void triggerRPMoveOperation(
com.azure.resourcemanager.recoveryservicesbackup.RecoveryServicesBackupManager manager) {
manager
.resourceProviders()
.moveRecoveryPoint(
"testVault",
"netsdktestrg",
"Azure",
... | static void function( com.azure.resourcemanager.recoveryservicesbackup.RecoveryServicesBackupManager manager) { manager .resourceProviders() .moveRecoveryPoint( STR, STR, "Azure", STR, STR, STR, new MoveRPAcrossTiersRequest() .withObjectType(STR) .withSourceTierType(RecoveryPointTierType.HARDENED_RP) .withTargetTierTyp... | /**
* Sample code: Trigger RP Move Operation.
*
* @param manager Entry point to RecoveryServicesBackupManager.
*/ | Sample code: Trigger RP Move Operation | triggerRPMoveOperation | {
"repo_name": "Azure/azure-sdk-for-java",
"path": "sdk/recoveryservicesbackup/azure-resourcemanager-recoveryservicesbackup/src/samples/java/com/azure/resourcemanager/recoveryservicesbackup/generated/ResourceProviderMoveRecoveryPointSamples.java",
"license": "mit",
"size": 1675
} | [
"com.azure.core.util.Context",
"com.azure.resourcemanager.recoveryservicesbackup.models.MoveRPAcrossTiersRequest",
"com.azure.resourcemanager.recoveryservicesbackup.models.RecoveryPointTierType"
] | import com.azure.core.util.Context; import com.azure.resourcemanager.recoveryservicesbackup.models.MoveRPAcrossTiersRequest; import com.azure.resourcemanager.recoveryservicesbackup.models.RecoveryPointTierType; | import com.azure.core.util.*; import com.azure.resourcemanager.recoveryservicesbackup.models.*; | [
"com.azure.core",
"com.azure.resourcemanager"
] | com.azure.core; com.azure.resourcemanager; | 959,758 |
public void testCase3_ResultCodeStartGroup() throws NoSuchMethodException,
IllegalArgumentException, IllegalAccessException, NoSuchFieldException,
InterruptedException, InvocationTargetException {
mActivity = getActivity();
Logger.d(TAG, "testCase3_ResultCodeStartGroup() entr... | void function() throws NoSuchMethodException, IllegalArgumentException, IllegalAccessException, NoSuchFieldException, InterruptedException, InvocationTargetException { mActivity = getActivity(); Logger.d(TAG, STR); Field filedStartGroup = Utils.getPrivateField(PluginProxyActivity.class, STR); waitForLoadContact(); Inte... | /**
* Test to start a group chat.
*
* @throws NoSuchMethodException
* @throws InvocationTargetException
* @throws IllegalAccessException
* @throws IllegalArgumentException
* @throws NoSuchFieldException
* @throws InterruptedException
* @throws InvocationTargetException
... | Test to start a group chat | testCase3_ResultCodeStartGroup | {
"repo_name": "rex-xxx/mt6572_x201",
"path": "mediatek/packages/apps/RCSe/core/tests/src/com/mediatek/rcse/test/activity/PluginProxyActivityTest.java",
"license": "gpl-2.0",
"size": 56842
} | [
"android.app.Activity",
"android.app.Instrumentation",
"android.content.Intent",
"com.mediatek.rcse.activities.ChatScreenActivity",
"com.mediatek.rcse.activities.PluginProxyActivity",
"com.mediatek.rcse.api.Logger",
"com.mediatek.rcse.api.Participant",
"com.mediatek.rcse.plugin.message.PluginGroupChat... | import android.app.Activity; import android.app.Instrumentation; import android.content.Intent; import com.mediatek.rcse.activities.ChatScreenActivity; import com.mediatek.rcse.activities.PluginProxyActivity; import com.mediatek.rcse.api.Logger; import com.mediatek.rcse.api.Participant; import com.mediatek.rcse.plugin.... | import android.app.*; import android.content.*; import com.mediatek.rcse.activities.*; import com.mediatek.rcse.api.*; import com.mediatek.rcse.plugin.message.*; import com.mediatek.rcse.test.*; import java.lang.reflect.*; import java.util.*; | [
"android.app",
"android.content",
"com.mediatek.rcse",
"java.lang",
"java.util"
] | android.app; android.content; com.mediatek.rcse; java.lang; java.util; | 2,609,798 |
public @NotNull String getNamespaceURI(); | @NotNull String function(); | /**
* Gets the namespace URI of this header element.
*
* @return
* this string must be interned.
*/ | Gets the namespace URI of this header element | getNamespaceURI | {
"repo_name": "samskivert/ikvm-openjdk",
"path": "build/linux-amd64/impsrc/com/sun/xml/internal/ws/api/message/Header.java",
"license": "gpl-2.0",
"size": 12432
} | [
"com.sun.istack.internal.NotNull"
] | import com.sun.istack.internal.NotNull; | import com.sun.istack.internal.*; | [
"com.sun.istack"
] | com.sun.istack; | 486,050 |
private void commandEcobee(final String itemName, final Command command) {
if (command instanceof State) {
updateEcobee(itemName, (State) command);
}
} | void function(final String itemName, final Command command) { if (command instanceof State) { updateEcobee(itemName, (State) command); } } | /**
* Perform the given {@code command} against all targets referenced in {@code itemName}.
*
* @param command
* the command to execute
* @param the
* target(s) against which to execute this command
*/ | Perform the given command against all targets referenced in itemName | commandEcobee | {
"repo_name": "magcode/openhab",
"path": "bundles/binding/org.openhab.binding.ecobee/src/main/java/org/openhab/binding/ecobee/internal/EcobeeBinding.java",
"license": "epl-1.0",
"size": 37150
} | [
"org.openhab.core.types.Command",
"org.openhab.core.types.State"
] | import org.openhab.core.types.Command; import org.openhab.core.types.State; | import org.openhab.core.types.*; | [
"org.openhab.core"
] | org.openhab.core; | 1,382,778 |
void setEncoding(@NotNull String encodingType); | void setEncoding(@NotNull String encodingType); | /**
* Sets the encoding used for submitting this form.
*
* @param encodingType
* the form's encoding
*/ | Sets the encoding used for submitting this form | setEncoding | {
"repo_name": "riuvshin/che-plugins",
"path": "plugin-ssh/che-plugin-ssh-ext-sshkey/src/main/java/org/eclipse/che/ide/ext/ssh/client/upload/UploadSshKeyView.java",
"license": "epl-1.0",
"size": 2850
} | [
"javax.validation.constraints.NotNull"
] | import javax.validation.constraints.NotNull; | import javax.validation.constraints.*; | [
"javax.validation"
] | javax.validation; | 156,977 |
@Override
public ChannelPromise setFailure(Throwable cause) {
if (allowFailure()) {
++doneCount;
lastFailure = cause;
if (allPromisesDone()) {
return setPromise();
}
}
return this;
... | ChannelPromise function(Throwable cause) { if (allowFailure()) { ++doneCount; lastFailure = cause; if (allPromisesDone()) { return setPromise(); } } return this; } | /**
* Fail this object if it has not already been failed.
* <p>
* This method will NOT throw an {@link IllegalStateException} if called multiple times
* because that may be expected.
*/ | Fail this object if it has not already been failed. This method will NOT throw an <code>IllegalStateException</code> if called multiple times because that may be expected | setFailure | {
"repo_name": "Techcable/netty",
"path": "codec-http2/src/main/java/io/netty/handler/codec/http2/Http2CodecUtil.java",
"license": "apache-2.0",
"size": 14180
} | [
"io.netty.channel.ChannelPromise"
] | import io.netty.channel.ChannelPromise; | import io.netty.channel.*; | [
"io.netty.channel"
] | io.netty.channel; | 2,590,194 |
List<DocumentType> getDocumentTypes(String userId) ;
| List<DocumentType> getDocumentTypes(String userId) ; | /**
* Liefert eine Liste aller verfügbaren Belegarten die für die Zeiterfassung verwendet werden können.</br>
* <p>Belegarten sind typischerweise Angebot, Auftrag, Los oder Projekt</p>
*
* @param userId der am HELIUM V Server angemeldete Benutzer
* @return eine (leere) Liste von verfü... | Liefert eine Liste aller verfügbaren Belegarten die für die Zeiterfassung verwendet werden können. Belegarten sind typischerweise Angebot, Auftrag, Los oder Projekt | getDocumentTypes | {
"repo_name": "heliumv/restapi",
"path": "src/com/heliumv/api/worktime/IWorktimeApi.java",
"license": "agpl-3.0",
"size": 8085
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,584,166 |
public Builder agentEmails(List<String> agentEmails) {
request.agentEmails = agentEmails;
return this;
}
} | Builder function(List<String> agentEmails) { request.agentEmails = agentEmails; return this; } } | /**
* Set agent emails
*
* @param agentEmails agent emails list
* @return builder self reference
*/ | Set agent emails | agentEmails | {
"repo_name": "CallFire/callfire-api-1.1-client-java",
"path": "callfire-api-1.1-client-core/src/main/java/com/callfire/api11/client/api/ccc/model/request/AddAgentsRequest.java",
"license": "mit",
"size": 2566
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,093,236 |
protected TableColumn addColumn(TableColumnMeta colMeta) {
TableColumn column = new TableColumn(this, colMeta);
columns.put(column.getName(), column);
return column;
}
| TableColumn function(TableColumnMeta colMeta) { TableColumn column = new TableColumn(this, colMeta); columns.put(column.getName(), column); return column; } | /**
* Add a column that's defined in xml metadata.
* Assumes that a column named colMeta.getName() doesn't already exist in <code>columns</code>.
* @param colMeta
* @return
*/ | Add a column that's defined in xml metadata. Assumes that a column named colMeta.getName() doesn't already exist in <code>columns</code> | addColumn | {
"repo_name": "wakaleo/maven-schemaspy-plugin",
"path": "src/main/java/net/sourceforge/schemaspy/model/Table.java",
"license": "mit",
"size": 38392
} | [
"net.sourceforge.schemaspy.model.xml.TableColumnMeta"
] | import net.sourceforge.schemaspy.model.xml.TableColumnMeta; | import net.sourceforge.schemaspy.model.xml.*; | [
"net.sourceforge.schemaspy"
] | net.sourceforge.schemaspy; | 1,022,659 |
public int getStunEnabled() {
return getPreferenceBooleanValue(SipConfigManager.ENABLE_STUN)?1:0;
}
| int function() { return getPreferenceBooleanValue(SipConfigManager.ENABLE_STUN)?1:0; } | /**
* Get whether turn is enabled
* @return 1 if enabled (pjstyle)
*/ | Get whether turn is enabled | getStunEnabled | {
"repo_name": "mycelial/spore",
"path": "src/com/csipsimple/utils/PreferencesProviderWrapper.java",
"license": "lgpl-3.0",
"size": 19353
} | [
"com.csipsimple.api.SipConfigManager"
] | import com.csipsimple.api.SipConfigManager; | import com.csipsimple.api.*; | [
"com.csipsimple.api"
] | com.csipsimple.api; | 1,609,952 |
void addSecrets(Collection<TemporarySecret> secrets) throws DbException; | void addSecrets(Collection<TemporarySecret> secrets) throws DbException; | /**
* Stores the given temporary secrets and deletes any secrets that have
* been made obsolete.
*/ | Stores the given temporary secrets and deletes any secrets that have been made obsolete | addSecrets | {
"repo_name": "biddyweb/briar",
"path": "briar-api/src/org/briarproject/api/db/DatabaseComponent.java",
"license": "gpl-3.0",
"size": 12165
} | [
"java.util.Collection",
"org.briarproject.api.transport.TemporarySecret"
] | import java.util.Collection; import org.briarproject.api.transport.TemporarySecret; | import java.util.*; import org.briarproject.api.transport.*; | [
"java.util",
"org.briarproject.api"
] | java.util; org.briarproject.api; | 740,365 |
@Override
public void looseUnmarshal(OpenWireFormat wireFormat, Object o, DataInput dataIn) throws IOException {
super.looseUnmarshal(wireFormat, o, dataIn);
ConsumerInfo info = (ConsumerInfo) o;
info.setConsumerId((ConsumerId) looseUnmarsalCachedObject(wireFormat, dataIn));
inf... | void function(OpenWireFormat wireFormat, Object o, DataInput dataIn) throws IOException { super.looseUnmarshal(wireFormat, o, dataIn); ConsumerInfo info = (ConsumerInfo) o; info.setConsumerId((ConsumerId) looseUnmarsalCachedObject(wireFormat, dataIn)); info.setBrowser(dataIn.readBoolean()); info.setDestination((OpenWir... | /**
* Un-marshal an object instance from the data input stream
*
* @param o
* the object to un-marshal
* @param dataIn
* the data input stream to build the object from
* @throws IOException
*/ | Un-marshal an object instance from the data input stream | looseUnmarshal | {
"repo_name": "tabish121/OpenWire",
"path": "openwire-legacy/src/main/java/io/openwire/codec/v2/ConsumerInfoMarshaller.java",
"license": "apache-2.0",
"size": 9232
} | [
"io.openwire.codec.OpenWireFormat",
"io.openwire.commands.BrokerId",
"io.openwire.commands.ConsumerId",
"io.openwire.commands.ConsumerInfo",
"io.openwire.commands.OpenWireDestination",
"java.io.DataInput",
"java.io.IOException"
] | import io.openwire.codec.OpenWireFormat; import io.openwire.commands.BrokerId; import io.openwire.commands.ConsumerId; import io.openwire.commands.ConsumerInfo; import io.openwire.commands.OpenWireDestination; import java.io.DataInput; import java.io.IOException; | import io.openwire.codec.*; import io.openwire.commands.*; import java.io.*; | [
"io.openwire.codec",
"io.openwire.commands",
"java.io"
] | io.openwire.codec; io.openwire.commands; java.io; | 725,185 |
Map<ControllerInput, BindableButton> getControllerBinds(); | Map<ControllerInput, BindableButton> getControllerBinds(); | /**
* All binds for {@link ControllerInput}, registered with {@link #registerBinds()}.
*/ | All binds for <code>ControllerInput</code>, registered with <code>#registerBinds()</code> | getControllerBinds | {
"repo_name": "Malanius/Terasology",
"path": "engine/src/main/java/org/terasology/engine/subsystem/config/BindsManager.java",
"license": "apache-2.0",
"size": 4351
} | [
"java.util.Map",
"org.terasology.input.BindableButton",
"org.terasology.input.ControllerInput"
] | import java.util.Map; import org.terasology.input.BindableButton; import org.terasology.input.ControllerInput; | import java.util.*; import org.terasology.input.*; | [
"java.util",
"org.terasology.input"
] | java.util; org.terasology.input; | 878,355 |
public static void writeSimpleTextNodeIfNotNull(XMLStreamWriter writer, String prefix, String namespaceURI, String nodeName, String text, WhiteSpaceHandling whiteSpace, boolean tryUsingCData)
throws XMLStreamException
{
if(text != null)
{
writeSimpleTextNode(writer, prefix, namespaceURI, nodeName, tex... | static void function(XMLStreamWriter writer, String prefix, String namespaceURI, String nodeName, String text, WhiteSpaceHandling whiteSpace, boolean tryUsingCData) throws XMLStreamException { if(text != null) { writeSimpleTextNode(writer, prefix, namespaceURI, nodeName, text, whiteSpace, tryUsingCData); } } | /**
* Writes a <nodeName> node containing the given text if text is not null.
* <p/>
* If tryUsingCData is true and the text does not contain the CData end token,
* the text will be written using writeCData. Otherwise writeCharacters is used.
*
* @param writer
* @param prefix the prefi... | Writes a <nodeName> node containing the given text if text is not null. If tryUsingCData is true and the text does not contain the CData end token, the text will be written using writeCData. Otherwise writeCharacters is used | writeSimpleTextNodeIfNotNull | {
"repo_name": "166MMX/sulky",
"path": "sulky-stax/src/main/java/de/huxhorn/sulky/stax/StaxUtilities.java",
"license": "apache-2.0",
"size": 24631
} | [
"javax.xml.stream.XMLStreamException",
"javax.xml.stream.XMLStreamWriter"
] | import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamWriter; | import javax.xml.stream.*; | [
"javax.xml"
] | javax.xml; | 1,774,457 |
public Modifier getAccessLevel() {
return f.getAccessLevel();
} | Modifier function() { return f.getAccessLevel(); } | /**
* Provides a hint about the access level of the class represented by this
* file object. If the access level is not known or if this file object does
* not represent a class file this method returns {@code null}.
*
* @return the access level
*/ | Provides a hint about the access level of the class represented by this file object. If the access level is not known or if this file object does not represent a class file this method returns null | getAccessLevel | {
"repo_name": "ceylon/ceylon",
"path": "compiler-java/src/org/eclipse/ceylon/compiler/java/codegen/CeylonFileObject.java",
"license": "apache-2.0",
"size": 5321
} | [
"org.eclipse.ceylon.javax.lang.model.element.Modifier"
] | import org.eclipse.ceylon.javax.lang.model.element.Modifier; | import org.eclipse.ceylon.javax.lang.model.element.*; | [
"org.eclipse.ceylon"
] | org.eclipse.ceylon; | 1,144,314 |
public void updateItem(Item item) {
itemRegistry.update(item);
} | void function(Item item) { itemRegistry.update(item); } | /**
* Updates an item.
*
* @param item
* item (must not be null)
*/ | Updates an item | updateItem | {
"repo_name": "WetwareLabs/smarthome",
"path": "bundles/core/org.eclipse.smarthome.core.thing/src/main/java/org/eclipse/smarthome/core/thing/setup/ThingSetupManager.java",
"license": "epl-1.0",
"size": 27488
} | [
"org.eclipse.smarthome.core.items.Item"
] | import org.eclipse.smarthome.core.items.Item; | import org.eclipse.smarthome.core.items.*; | [
"org.eclipse.smarthome"
] | org.eclipse.smarthome; | 2,434,522 |
public final int setSessionPort(int port)
throws InvalidConfigurationException {
// Inform listeners, validate the configuration change
int sts = fireConfigurationChange(ConfigId.NetBIOSSessionPort, new Integer(port));
m_sessPort = port;
// Return the change status
return s... | final int function(int port) throws InvalidConfigurationException { int sts = fireConfigurationChange(ConfigId.NetBIOSSessionPort, new Integer(port)); m_sessPort = port; return sts; } | /**
* Set the session port to listen on for incoming session requests.
*
* @param port int
* @return int
* @exception InvalidConfigurationException
*/ | Set the session port to listen on for incoming session requests | setSessionPort | {
"repo_name": "arcusys/Liferay-CIFS",
"path": "source/java/org/alfresco/jlan/smb/server/CIFSConfigSection.java",
"license": "gpl-3.0",
"size": 34821
} | [
"org.alfresco.jlan.server.config.ConfigId",
"org.alfresco.jlan.server.config.InvalidConfigurationException"
] | import org.alfresco.jlan.server.config.ConfigId; import org.alfresco.jlan.server.config.InvalidConfigurationException; | import org.alfresco.jlan.server.config.*; | [
"org.alfresco.jlan"
] | org.alfresco.jlan; | 1,365,374 |
@Override
public SsMediaSource createMediaSource(MediaItem mediaItem) {
checkNotNull(mediaItem.localConfiguration);
@Nullable ParsingLoadable.Parser<? extends SsManifest> manifestParser = this.manifestParser;
if (manifestParser == null) {
manifestParser = new SsManifestParser();
... | SsMediaSource function(MediaItem mediaItem) { checkNotNull(mediaItem.localConfiguration); @Nullable ParsingLoadable.Parser<? extends SsManifest> manifestParser = this.manifestParser; if (manifestParser == null) { manifestParser = new SsManifestParser(); } List<StreamKey> streamKeys = mediaItem.localConfiguration.stream... | /**
* Returns a new {@link SsMediaSource} using the current parameters.
*
* @param mediaItem The {@link MediaItem}.
* @return The new {@link SsMediaSource}.
* @throws NullPointerException if {@link MediaItem#localConfiguration} is {@code null}.
*/ | Returns a new <code>SsMediaSource</code> using the current parameters | createMediaSource | {
"repo_name": "google/ExoPlayer",
"path": "library/smoothstreaming/src/main/java/com/google/android/exoplayer2/source/smoothstreaming/SsMediaSource.java",
"license": "apache-2.0",
"size": 23855
} | [
"androidx.annotation.Nullable",
"com.google.android.exoplayer2.MediaItem",
"com.google.android.exoplayer2.offline.FilteringManifestParser",
"com.google.android.exoplayer2.offline.StreamKey",
"com.google.android.exoplayer2.source.smoothstreaming.manifest.SsManifest",
"com.google.android.exoplayer2.source.s... | import androidx.annotation.Nullable; import com.google.android.exoplayer2.MediaItem; import com.google.android.exoplayer2.offline.FilteringManifestParser; import com.google.android.exoplayer2.offline.StreamKey; import com.google.android.exoplayer2.source.smoothstreaming.manifest.SsManifest; import com.google.android.ex... | import androidx.annotation.*; import com.google.android.exoplayer2.*; import com.google.android.exoplayer2.offline.*; import com.google.android.exoplayer2.source.smoothstreaming.manifest.*; import com.google.android.exoplayer2.upstream.*; import com.google.android.exoplayer2.util.*; import java.util.*; | [
"androidx.annotation",
"com.google.android",
"java.util"
] | androidx.annotation; com.google.android; java.util; | 1,539,046 |
public Bitmap getSyncedFaviconImageForURL(Profile profile, String pageUrl) {
assert mNativeFaviconHelper != 0;
return nativeGetSyncedFaviconImageForURL(mNativeFaviconHelper, profile, pageUrl);
} | Bitmap function(Profile profile, String pageUrl) { assert mNativeFaviconHelper != 0; return nativeGetSyncedFaviconImageForURL(mNativeFaviconHelper, profile, pageUrl); } | /**
* Get 16x16 Favicon bitmap for the requested arguments. Only retrives favicons in synced
* session storage. (e.g. favicons synced from other devices).
* TODO(apiccion): provide a way to obtain higher resolution favicons.
* @param profile Profile used for the FaviconService construction.
*... | Get 16x16 Favicon bitmap for the requested arguments. Only retrives favicons in synced session storage. (e.g. favicons synced from other devices). TODO(apiccion): provide a way to obtain higher resolution favicons | getSyncedFaviconImageForURL | {
"repo_name": "patrickm/chromium.src",
"path": "chrome/android/java/src/org/chromium/chrome/browser/favicon/FaviconHelper.java",
"license": "bsd-3-clause",
"size": 4838
} | [
"android.graphics.Bitmap",
"org.chromium.chrome.browser.profiles.Profile"
] | import android.graphics.Bitmap; import org.chromium.chrome.browser.profiles.Profile; | import android.graphics.*; import org.chromium.chrome.browser.profiles.*; | [
"android.graphics",
"org.chromium.chrome"
] | android.graphics; org.chromium.chrome; | 2,656,575 |
public static List<Cell> getFromStoreFile(HStore store, byte[] row, NavigableSet<byte[]> columns)
throws IOException {
Get get = new Get(row);
Map<byte[], NavigableSet<byte[]>> s = get.getFamilyMap();
s.put(store.getColumnFamilyDescriptor().getName(), columns);
return getFromStoreFile(store, get)... | static List<Cell> function(HStore store, byte[] row, NavigableSet<byte[]> columns) throws IOException { Get get = new Get(row); Map<byte[], NavigableSet<byte[]>> s = get.getFamilyMap(); s.put(store.getColumnFamilyDescriptor().getName(), columns); return getFromStoreFile(store, get); } | /**
* Do a small get/scan against one store. This is required because store has no actual methods of
* querying itself, and relies on StoreScanner.
*/ | Do a small get/scan against one store. This is required because store has no actual methods of querying itself, and relies on StoreScanner | getFromStoreFile | {
"repo_name": "ndimiduk/hbase",
"path": "hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtil.java",
"license": "apache-2.0",
"size": 151074
} | [
"java.io.IOException",
"java.util.List",
"java.util.Map",
"java.util.NavigableSet",
"org.apache.hadoop.hbase.client.Get",
"org.apache.hadoop.hbase.regionserver.HStore"
] | import java.io.IOException; import java.util.List; import java.util.Map; import java.util.NavigableSet; import org.apache.hadoop.hbase.client.Get; import org.apache.hadoop.hbase.regionserver.HStore; | import java.io.*; import java.util.*; import org.apache.hadoop.hbase.client.*; import org.apache.hadoop.hbase.regionserver.*; | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 756,914 |
public static String getProperty(String key) {
Object value = configuration.get(key);
String strValue;
if (value == null) {
return null;
}
if (value instanceof List) {
value = ((List) value).get(0);
}
if (value instanceof String) {
... | static String function(String key) { Object value = configuration.get(key); String strValue; if (value == null) { return null; } if (value instanceof List) { value = ((List) value).get(0); } if (value instanceof String) { strValue = (String) value; } else { strValue = String.valueOf(value); } strValue = fillURLPlacehol... | /**
* Read configuration elements from the identity.xml
*
* @param key Element Name as specified from the parent elements in the XML structure.
* To read the element value of b in {@code<a><b>text</b></a>}, the property
* name should be passed as "a.b"
* @return Eleme... | Read configuration elements from the identity.xml | getProperty | {
"repo_name": "omindu/carbon-identity-framework",
"path": "components/identity-core/org.wso2.carbon.identity.core/src/main/java/org/wso2/carbon/identity/core/util/IdentityUtil.java",
"license": "apache-2.0",
"size": 66257
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 93,151 |
@Test
public void testConfModificationFederationOnly() {
final HdfsConfiguration conf = new HdfsConfiguration();
String nsId = "ns1";
conf.set(DFS_NAMESERVICES, nsId);
conf.set(DFS_NAMESERVICE_ID, nsId);
// Set the nameservice specific keys with nameserviceId in the config key
for (Str... | void function() { final HdfsConfiguration conf = new HdfsConfiguration(); String nsId = "ns1"; conf.set(DFS_NAMESERVICES, nsId); conf.set(DFS_NAMESERVICE_ID, nsId); for (String key : NameNode.NAMENODE_SPECIFIC_KEYS) { conf.set(DFSUtil.addKeySuffixes(key, nsId), key); } NameNode.initializeGenericKeys(conf, nsId, null); ... | /**
* Test to ensure nameservice specific keys in the configuration are
* copied to generic keys when the namenode starts.
*/ | Test to ensure nameservice specific keys in the configuration are copied to generic keys when the namenode starts | testConfModificationFederationOnly | {
"repo_name": "korrelate/hadoop",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestDFSUtil.java",
"license": "apache-2.0",
"size": 35533
} | [
"org.apache.hadoop.hdfs.server.namenode.NameNode",
"org.junit.Assert"
] | import org.apache.hadoop.hdfs.server.namenode.NameNode; import org.junit.Assert; | import org.apache.hadoop.hdfs.server.namenode.*; import org.junit.*; | [
"org.apache.hadoop",
"org.junit"
] | org.apache.hadoop; org.junit; | 2,248,019 |
public Object getSelectedNodeObject() {
Object returnObject, selectedObject;
Object[] pathObjects;
TreePath tPath;
tPath = this.getSelectionPath();
returnObject = null;
if (tPath != null) {
pathObjects = tPath.getPath();
... | Object function() { Object returnObject, selectedObject; Object[] pathObjects; TreePath tPath; tPath = this.getSelectionPath(); returnObject = null; if (tPath != null) { pathObjects = tPath.getPath(); if (pathObjects != null) { selectedObject = pathObjects[pathObjects.length - 1]; if (selectedObject instanceof DefaultM... | /**
* Returns the UserObject for the selected Tree Node.
* Returns null is no object is selected or there is another error.
*
* @return
*/ | Returns the UserObject for the selected Tree Node. Returns null is no object is selected or there is another error | getSelectedNodeObject | {
"repo_name": "alecdhuse/Folding-Map",
"path": "FoldingMap/src/co/foldingmap/GUISupport/components/checkBoxTree/LayersTree.java",
"license": "gpl-3.0",
"size": 6347
} | [
"javax.swing.tree.DefaultMutableTreeNode",
"javax.swing.tree.TreePath"
] | import javax.swing.tree.DefaultMutableTreeNode; import javax.swing.tree.TreePath; | import javax.swing.tree.*; | [
"javax.swing"
] | javax.swing; | 1,831,996 |
public void valueForPathChanged(TreePath path, Object newValue)
{
DefaultMutableTreeNode aNode = (DefaultMutableTreeNode)path.getLastPathComponent();
TreeData treeData = (TreeData)aNode.getUserObject();
treeData.setString((String)newValue);
treeData.setColor(Color.green);
nodeChanged(... | void function(TreePath path, Object newValue) { DefaultMutableTreeNode aNode = (DefaultMutableTreeNode)path.getLastPathComponent(); TreeData treeData = (TreeData)aNode.getUserObject(); treeData.setString((String)newValue); treeData.setColor(Color.green); nodeChanged(aNode); } | /**
* Subclassed to message setString() to the changed path item.
*/ | Subclassed to message setString() to the changed path item | valueForPathChanged | {
"repo_name": "nightscape/JMathLib",
"path": "src/jmathlib/tools/treeanalyser/SampleTreeModel.java",
"license": "lgpl-3.0",
"size": 1295
} | [
"java.awt.Color",
"javax.swing.tree.DefaultMutableTreeNode",
"javax.swing.tree.TreePath"
] | import java.awt.Color; import javax.swing.tree.DefaultMutableTreeNode; import javax.swing.tree.TreePath; | import java.awt.*; import javax.swing.tree.*; | [
"java.awt",
"javax.swing"
] | java.awt; javax.swing; | 1,731,826 |
private void updateItem(int slot) {
ItemStack source = getItem(slot);
slots[slot] = source == null ? null : source.clone();
} | void function(int slot) { ItemStack source = getItem(slot); slots[slot] = source == null ? null : source.clone(); } | /**
* Update the given slot with the current value from the inventory.
* @param slot The slot to update.
*/ | Update the given slot with the current value from the inventory | updateItem | {
"repo_name": "Tonodus/WaterGleam",
"path": "src/main/java/net/glowstone/inventory/EquipmentMonitor.java",
"license": "mit",
"size": 3013
} | [
"org.bukkit.inventory.ItemStack"
] | import org.bukkit.inventory.ItemStack; | import org.bukkit.inventory.*; | [
"org.bukkit.inventory"
] | org.bukkit.inventory; | 2,158,232 |
public Observable<ServiceResponse<NetworkInterfaceIPConfigurationInner>> getWithServiceResponseAsync(String resourceGroupName, String networkInterfaceName, String ipConfigurationName) {
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required a... | Observable<ServiceResponse<NetworkInterfaceIPConfigurationInner>> function(String resourceGroupName, String networkInterfaceName, String ipConfigurationName) { if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (networkInterfaceName == null) { throw new IllegalArgumentException(STR); } if (i... | /**
* Gets the specified network interface ip configuration.
*
* @param resourceGroupName The name of the resource group.
* @param networkInterfaceName The name of the network interface.
* @param ipConfigurationName The name of the ip configuration name.
* @throws IllegalArgumentException ... | Gets the specified network interface ip configuration | getWithServiceResponseAsync | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2018_04_01/src/main/java/com/microsoft/azure/management/network/v2018_04_01/implementation/NetworkInterfaceIPConfigurationsInner.java",
"license": "mit",
"size": 23822
} | [
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.rest.ServiceResponse; | import com.microsoft.rest.*; | [
"com.microsoft.rest"
] | com.microsoft.rest; | 1,951,061 |
default void forEachPropertyPair(AbstractBlockBase<?> block, BiConsumer<String, String> action) {
// no extra properties per default
} | default void forEachPropertyPair(AbstractBlockBase<?> block, BiConsumer<String, String> action) { } | /**
* Applies {@code action} to all extra property pairs (name, value) of {@code block}.
*
* @param block a block from {@link #getBlocks()}.
* @param action a {@link BiConsumer consumer}.
*/ | Applies action to all extra property pairs (name, value) of block | forEachPropertyPair | {
"repo_name": "rschatz/graal-core",
"path": "graal/com.oracle.graal.compiler.common/src/com/oracle/graal/compiler/common/cfg/PrintableCFG.java",
"license": "gpl-2.0",
"size": 1803
} | [
"java.util.function.BiConsumer"
] | import java.util.function.BiConsumer; | import java.util.function.*; | [
"java.util"
] | java.util; | 382,704 |
private static BufferedImage resizeImage(BufferedImage img, double width, double height) {
int w = (int)width;
int h = (int)height;
BufferedImage result = new BufferedImage(w, h, img.getType());
Graphics2D g = result.createGraphics();
g.setRenderingHint(RenderingHints.KEY_INT... | static BufferedImage function(BufferedImage img, double width, double height) { int w = (int)width; int h = (int)height; BufferedImage result = new BufferedImage(w, h, img.getType()); Graphics2D g = result.createGraphics(); g.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BICUBIC)... | /**
* Returns resized image
* NB - useful reference on high quality image resizing can be found here:
* http://today.java.net/pub/a/today/2007/04/03/perils-of-image-getscaledinstance.html
* @param width the required width
* @param height the frequired height
* @param img the image to be ... | Returns resized image NB - useful reference on high quality image resizing can be found here: HREF | resizeImage | {
"repo_name": "mlist/grails-openseadragon-plugin",
"path": "src/java/org/nanocan/io/DeepZoomConverter.java",
"license": "gpl-3.0",
"size": 16640
} | [
"java.awt.Graphics2D",
"java.awt.RenderingHints",
"java.awt.image.BufferedImage"
] | import java.awt.Graphics2D; import java.awt.RenderingHints; import java.awt.image.BufferedImage; | import java.awt.*; import java.awt.image.*; | [
"java.awt"
] | java.awt; | 2,380,905 |
public Map getElementHandlers()
{
return elementHandlers;
} | Map function() { return elementHandlers; } | /**
* Returns the map of element handlers.
*
* @return the map of element handlers
*/ | Returns the map of element handlers | getElementHandlers | {
"repo_name": "delafer/j7project",
"path": "jasper352/csb-jasperreport-dep/src/net/sf/jasperreports/engine/export/DefaultElementHandlerBundle.java",
"license": "gpl-2.0",
"size": 3278
} | [
"java.util.Map"
] | import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 905,435 |
public synchronized MimeBodyPart getTextBodyPart()
throws MessagingException {
return (MimeBodyPart)getBodyPart(0);
} | synchronized MimeBodyPart function() throws MessagingException { return (MimeBodyPart)getBodyPart(0); } | /**
* Return the body part containing the message to be presented to
* the user, usually just a text/plain part.
*/ | Return the body part containing the message to be presented to the user, usually just a text/plain part | getTextBodyPart | {
"repo_name": "arthurzaczek/kolab-android",
"path": "javamail/com/sun/mail/dsn/MultipartReport.java",
"license": "gpl-3.0",
"size": 13865
} | [
"javax.mail.MessagingException",
"javax.mail.internet.MimeBodyPart"
] | import javax.mail.MessagingException; import javax.mail.internet.MimeBodyPart; | import javax.mail.*; import javax.mail.internet.*; | [
"javax.mail"
] | javax.mail; | 2,802,639 |
public void removeNode(final Txn transaction, final StoredNode node, NodePath currentPath, String content) {
final DocumentImpl doc = (DocumentImpl)node.getOwnerDocument();
| void function(final Txn transaction, final StoredNode node, NodePath currentPath, String content) { final DocumentImpl doc = (DocumentImpl)node.getOwnerDocument(); | /** Removes the Node Reference from the database.
* The index will be updated later, i.e. after all nodes have been physically
* removed. See {@link #endRemove(org.exist.storage.txn.Txn)}.
* removeNode() just adds the node ids to the list in elementIndex
* for later removal.
*/ | Removes the Node Reference from the database. The index will be updated later, i.e. after all nodes have been physically removed. See <code>#endRemove(org.exist.storage.txn.Txn)</code>. removeNode() just adds the node ids to the list in elementIndex for later removal | removeNode | {
"repo_name": "NCIP/cadsr-cgmdr-nci-uk",
"path": "src/org/exist/storage/NativeBroker.java",
"license": "bsd-3-clause",
"size": 139503
} | [
"org.exist.dom.DocumentImpl",
"org.exist.dom.StoredNode",
"org.exist.storage.txn.Txn"
] | import org.exist.dom.DocumentImpl; import org.exist.dom.StoredNode; import org.exist.storage.txn.Txn; | import org.exist.dom.*; import org.exist.storage.txn.*; | [
"org.exist.dom",
"org.exist.storage"
] | org.exist.dom; org.exist.storage; | 2,553,553 |
void migrate(VirtualDeploymentUnit vdu);
/**
* This operation allows executing specific commands on certain allocated virtualised resources.
* Examples on compute resources can include (but not limited to): start, stop, pause, suspend,
* capture snapshot, etc.
*
* @param vimInstance the {@link BaseV... | void migrate(VirtualDeploymentUnit vdu); /** * This operation allows executing specific commands on certain allocated virtualised resources. * Examples on compute resources can include (but not limited to): start, stop, pause, suspend, * capture snapshot, etc. * * @param vimInstance the {@link BaseVimInstance} on which... | /**
* This operation allows moving virtualised resources between locations. For instance, the
* operation performs the migration of a computing resource from one host to another host; while
* for a storage resource, it migrates the resource from one storage location to another.
*
* @param vdu the {@link ... | This operation allows moving virtualised resources between locations. For instance, the operation performs the migration of a computing resource from one host to another host; while for a storage resource, it migrates the resource from one storage location to another | migrate | {
"repo_name": "openbaton/NFVO",
"path": "vim-int/src/main/java/org/openbaton/nfvo/vim_interfaces/resource_management/ResourceManagement.java",
"license": "apache-2.0",
"size": 6695
} | [
"java.util.concurrent.Future",
"org.openbaton.catalogue.mano.descriptor.VirtualDeploymentUnit",
"org.openbaton.catalogue.mano.record.VNFCInstance",
"org.openbaton.catalogue.nfvo.viminstances.BaseVimInstance"
] | import java.util.concurrent.Future; import org.openbaton.catalogue.mano.descriptor.VirtualDeploymentUnit; import org.openbaton.catalogue.mano.record.VNFCInstance; import org.openbaton.catalogue.nfvo.viminstances.BaseVimInstance; | import java.util.concurrent.*; import org.openbaton.catalogue.mano.descriptor.*; import org.openbaton.catalogue.mano.record.*; import org.openbaton.catalogue.nfvo.viminstances.*; | [
"java.util",
"org.openbaton.catalogue"
] | java.util; org.openbaton.catalogue; | 1,328,447 |
public void setBorderLeftWidth(MeasurementCSSImpl borderLeftWidth)
{
this.borderLeftWidth = borderLeftWidth;
} | void function(MeasurementCSSImpl borderLeftWidth) { this.borderLeftWidth = borderLeftWidth; } | /**
* Sets the border width
*
* @param borderLeftWidth
*/ | Sets the border width | setBorderLeftWidth | {
"repo_name": "GedMarc/JWebSwing",
"path": "src/main/java/com/jwebmp/core/htmlbuilder/css/borders/BorderLeftCSSImpl.java",
"license": "gpl-3.0",
"size": 3852
} | [
"com.jwebmp.core.htmlbuilder.css.measurement.MeasurementCSSImpl"
] | import com.jwebmp.core.htmlbuilder.css.measurement.MeasurementCSSImpl; | import com.jwebmp.core.htmlbuilder.css.measurement.*; | [
"com.jwebmp.core"
] | com.jwebmp.core; | 2,547,969 |
public CriteriaSet getKEKResolverCriteria() {
return kekResolverCriteria;
} | CriteriaSet function() { return kekResolverCriteria; } | /**
* Get the optional static set of criteria used when resolving credentials based on the KeyInfo of an EncryptedKey
* element.
*
* @return the static criteria set to use
*/ | Get the optional static set of criteria used when resolving credentials based on the KeyInfo of an EncryptedKey element | getKEKResolverCriteria | {
"repo_name": "Safewhere/kombit-service-java",
"path": "XmlTooling/src/org/opensaml/xml/encryption/Decrypter.java",
"license": "mit",
"size": 47926
} | [
"org.opensaml.xml.security.CriteriaSet"
] | import org.opensaml.xml.security.CriteriaSet; | import org.opensaml.xml.security.*; | [
"org.opensaml.xml"
] | org.opensaml.xml; | 865,849 |
//-----------------------------------------------------------------------
@SuppressWarnings({"rawtypes", "unchecked"})
private enum ComparableComparator implements Comparator {
INSTANCE;
@Override
public int compare(final Object obj1, final Object obj2) {
return ((Co... | @SuppressWarnings({STR, STR}) enum ComparableComparator implements Comparator { INSTANCE; public int function(final Object obj1, final Object obj2) { return ((Comparable) obj1).compareTo(obj2); } } | /**
* Comparable based compare implementation.
*
* @param obj1 left hand side of comparison
* @param obj2 right hand side of comparison
* @return negative, 0, positive comparison value
*/ | Comparable based compare implementation | compare | {
"repo_name": "MeRPG/EndHQ-Libraries",
"path": "src/org/apache/commons/lang3/Range.java",
"license": "apache-2.0",
"size": 18083
} | [
"java.util.Comparator"
] | import java.util.Comparator; | import java.util.*; | [
"java.util"
] | java.util; | 1,446,498 |
void encryptElement(Document xmlDocument, Key encryptSymmetricKey,
EncryptedKey encryptedKey, Element element)
throws XMLEncryptionException, Exception {
String algorithmURI = XMLCipher.AES_128;
XMLCipher xmlCipher = XMLCipher.getInstance(algorithmURI);
xmlCipher.init(XMLCipher.ENCRYPT_MODE, encryptSym... | void encryptElement(Document xmlDocument, Key encryptSymmetricKey, EncryptedKey encryptedKey, Element element) throws XMLEncryptionException, Exception { String algorithmURI = XMLCipher.AES_128; XMLCipher xmlCipher = XMLCipher.getInstance(algorithmURI); xmlCipher.init(XMLCipher.ENCRYPT_MODE, encryptSymmetricKey); Encry... | /**
* Encrypt element.
*
* @param xmlDocument
* the xml document
* @param encryptSymmetricKey
* the encrypt symmetric key
* @param encryptedKey
* the encrypted key
* @param element
* the element
* @throws XMLEncryptionException
* the xML e... | Encrypt element | encryptElement | {
"repo_name": "tlin-fei/ds4p",
"path": "DS4P/access-control-service/document-segmentation/service/src/main/java/gov/samhsa/acs/documentsegmentation/tools/DocumentEncrypterImpl.java",
"license": "bsd-3-clause",
"size": 6012
} | [
"java.security.Key",
"org.apache.xml.security.encryption.EncryptedData",
"org.apache.xml.security.encryption.EncryptedKey",
"org.apache.xml.security.encryption.XMLCipher",
"org.apache.xml.security.encryption.XMLEncryptionException",
"org.apache.xml.security.keys.KeyInfo",
"org.w3c.dom.Document",
"org.... | import java.security.Key; import org.apache.xml.security.encryption.EncryptedData; import org.apache.xml.security.encryption.EncryptedKey; import org.apache.xml.security.encryption.XMLCipher; import org.apache.xml.security.encryption.XMLEncryptionException; import org.apache.xml.security.keys.KeyInfo; import org.w3c.do... | import java.security.*; import org.apache.xml.security.encryption.*; import org.apache.xml.security.keys.*; import org.w3c.dom.*; | [
"java.security",
"org.apache.xml",
"org.w3c.dom"
] | java.security; org.apache.xml; org.w3c.dom; | 2,537,305 |
public Container getBody();
| Container function(); | /**
* returns the body of the panel
* @return
*/ | returns the body of the panel | getBody | {
"repo_name": "eucleed/hatzouf",
"path": "iot.ui/src/org/castafiore/ui/ex/panel/Panel.java",
"license": "apache-2.0",
"size": 1848
} | [
"org.castafiore.ui.Container"
] | import org.castafiore.ui.Container; | import org.castafiore.ui.*; | [
"org.castafiore.ui"
] | org.castafiore.ui; | 2,794,071 |
private byte[] doRSADecryption(byte[] data) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, IllegalBlockSizeException, BadPaddingException {
Cipher cipher = Cipher.getInstance("RSA/ECB/PKCS1PADDING");
cipher.init(Cipher.DECRYPT_MODE, this.privateKey);
byte[] crypted = cipher.do... | byte[] function(byte[] data) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, IllegalBlockSizeException, BadPaddingException { Cipher cipher = Cipher.getInstance(STR); cipher.init(Cipher.DECRYPT_MODE, this.privateKey); byte[] crypted = cipher.doFinal(data); return crypted; } | /**
* Decrypt data with this.privateKey (Uses RSA only)
*
* @param data data to decrypt
* @return decrypted data
* @throws NoSuchAlgorithmException
* @throws NoSuchPaddingException
* @throws InvalidKeyException
* @throws IllegalBlockSizeException
* @throws BadPaddingException
*/ | Decrypt data with this.privateKey (Uses RSA only) | doRSADecryption | {
"repo_name": "wessnerj/CastleCrypt",
"path": "java/de/meetr/hdr/castle_crypt/CastleCrypt.java",
"license": "lgpl-3.0",
"size": 13088
} | [
"java.security.InvalidKeyException",
"java.security.NoSuchAlgorithmException",
"javax.crypto.BadPaddingException",
"javax.crypto.Cipher",
"javax.crypto.IllegalBlockSizeException",
"javax.crypto.NoSuchPaddingException"
] | import java.security.InvalidKeyException; import java.security.NoSuchAlgorithmException; import javax.crypto.BadPaddingException; import javax.crypto.Cipher; import javax.crypto.IllegalBlockSizeException; import javax.crypto.NoSuchPaddingException; | import java.security.*; import javax.crypto.*; | [
"java.security",
"javax.crypto"
] | java.security; javax.crypto; | 651,896 |
@SuppressWarnings("unchecked")
public void testQueryRowCount() throws ApplicationException
{
BlNonNullDataType searchObject = new BlNonNullDataType();
Collection results = search("gov.nih.nci.cacoresdk.domain.other.datatype.BlNonNullDataType",searchObject );
assertNotNull(results);
assertEquals(2,res... | @SuppressWarnings(STR) void function() throws ApplicationException { BlNonNullDataType searchObject = new BlNonNullDataType(); Collection results = search(STR,searchObject ); assertNotNull(results); assertEquals(2,results.size()); } | /**
* Uses Nested Search Criteria for search
* Verifies that the results are returned
* Verifies size of the result set
*
* @throws ApplicationException
*/ | Uses Nested Search Criteria for search Verifies that the results are returned Verifies size of the result set | testQueryRowCount | {
"repo_name": "NCIP/cacore-sdk",
"path": "sdk-toolkit/iso-example-project/junit/src/test/gov/nih/nci/cacoresdk/domain/other/datatype/BlNonNullDataTypeTest.java",
"license": "bsd-3-clause",
"size": 4768
} | [
"gov.nih.nci.cacoresdk.domain.other.datatype.BlNonNullDataType",
"gov.nih.nci.system.applicationservice.ApplicationException",
"java.util.Collection"
] | import gov.nih.nci.cacoresdk.domain.other.datatype.BlNonNullDataType; import gov.nih.nci.system.applicationservice.ApplicationException; import java.util.Collection; | import gov.nih.nci.cacoresdk.domain.other.datatype.*; import gov.nih.nci.system.applicationservice.*; import java.util.*; | [
"gov.nih.nci",
"java.util"
] | gov.nih.nci; java.util; | 692,501 |
public static void runExternalCMD(String command){
try {
Process p = Runtime.getRuntime().exec(new String[]{"/bin/sh", "-c", command});
BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream()));
BufferedReader stdError = new BufferedReader(new InputStreamReader(p.getErrorStre... | static void function(String command){ try { Process p = Runtime.getRuntime().exec(new String[]{STR, "-c", command}); BufferedReader stdInput = new BufferedReader(new InputStreamReader(p.getInputStream())); BufferedReader stdError = new BufferedReader(new InputStreamReader(p.getErrorStream())); String s; System.out.prin... | /**
* Runs a command in a shell and waits for it to finish. Output is send to the console.
* @param command
*/ | Runs a command in a shell and waits for it to finish. Output is send to the console | runExternalCMD | {
"repo_name": "BiosemanticsDotOrg/GeneDiseasePaper",
"path": "java/Common/src/org/erasmusmc/utilities/LinuxUtilities.java",
"license": "agpl-3.0",
"size": 2580
} | [
"java.io.BufferedReader",
"java.io.IOException",
"java.io.InputStreamReader"
] | import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; | import java.io.*; | [
"java.io"
] | java.io; | 1,087,865 |
SecurityContext getContext(); | SecurityContext getContext(); | /**
* Returns a snapshot of the current security context, which can be used to
* restore the context at a later time.
*
* @return snapshot of the current security context
*/ | Returns a snapshot of the current security context, which can be used to restore the context at a later time | getContext | {
"repo_name": "cdegroot/river",
"path": "src/net/jini/security/policy/SecurityContextSource.java",
"license": "apache-2.0",
"size": 2472
} | [
"net.jini.security.SecurityContext"
] | import net.jini.security.SecurityContext; | import net.jini.security.*; | [
"net.jini.security"
] | net.jini.security; | 193,317 |
@CommandLineFlags.Add({"enable-features="
+ ChromeFeatureList.CONTEXT_MENU_SEARCH_WITH_GOOGLE_LENS + "<FakeStudyName",
"force-fieldtrials=FakeStudyName/Enabled",
"force-fieldtrial-params=FakeStudyName.Enabled:sendSrc/true"})
@Test
@SmallTest
public void
ge... | @CommandLineFlags.Add({STR + ChromeFeatureList.CONTEXT_MENU_SEARCH_WITH_GOOGLE_LENS + STR, STR, STR}) void function() { final String contentUrl = STRhttp: STRIntent with image has incorrect URISTRgoogleapp: + STR + STR, intentWithContentUri.getData().toString()); Assert.assertEquals(STR, Intent.ACTION_VIEW, intentWithC... | /**
* Test {@link LensUtils#getShareWithGoogleLensIntent()} method when image src is available and
* enabled by finch.
*/ | Test <code>LensUtils#getShareWithGoogleLensIntent()</code> method when image src is available and enabled by finch | getShareWithGoogleLensIntentSrcEnabledAndAddedTest | {
"repo_name": "endlessm/chromium-browser",
"path": "chrome/android/javatests/src/org/chromium/chrome/browser/share/LensUtilsTest.java",
"license": "bsd-3-clause",
"size": 17041
} | [
"android.content.Intent",
"org.chromium.base.test.util.CommandLineFlags",
"org.chromium.chrome.browser.flags.ChromeFeatureList",
"org.junit.Assert"
] | import android.content.Intent; import org.chromium.base.test.util.CommandLineFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; import org.junit.Assert; | import android.content.*; import org.chromium.base.test.util.*; import org.chromium.chrome.browser.flags.*; import org.junit.*; | [
"android.content",
"org.chromium.base",
"org.chromium.chrome",
"org.junit"
] | android.content; org.chromium.base; org.chromium.chrome; org.junit; | 574,967 |
@Test
public void testQueryOnSingleDataStore() throws Exception {
Region region = PartitionedRegionTestHelper.createPartitionedRegion(regionName, "100", 0);
PortfolioData[] portfolios = new PortfolioData[100];
for (int j = 0; j < 100; j++) {
portfolios[j] = new PortfolioData(j);
}
PRQueryP... | void function() throws Exception { Region region = PartitionedRegionTestHelper.createPartitionedRegion(regionName, "100", 0); PortfolioData[] portfolios = new PortfolioData[100]; for (int j = 0; j < 100; j++) { portfolios[j] = new PortfolioData(j); } PRQueryProcessor.TEST_NUM_THREADS = 10; try { populateData(region, po... | /**
* Tests the execution of query on a PartitionedRegion created on a single data store. <br>
* 1. Creates a PR with redundancy=0 on a single VM. 2. Puts some test Objects in cache. 3. Fires
* queries on the data and verifies the result.
*
*/ | Tests the execution of query on a PartitionedRegion created on a single data store. 1. Creates a PR with redundancy=0 on a single VM. 2. Puts some test Objects in cache. 3. Fires queries on the data and verifies the result | testQueryOnSingleDataStore | {
"repo_name": "pdxrunner/geode",
"path": "geode-core/src/integrationTest/java/org/apache/geode/cache/query/partitioned/PRQueryNumThreadsJUnitTest.java",
"license": "apache-2.0",
"size": 5006
} | [
"org.apache.geode.cache.Region",
"org.apache.geode.cache.query.SelectResults",
"org.apache.geode.cache.query.data.PortfolioData",
"org.apache.geode.internal.Assert",
"org.apache.geode.internal.cache.PRQueryProcessor",
"org.apache.geode.internal.cache.PartitionedRegionTestHelper"
] | import org.apache.geode.cache.Region; import org.apache.geode.cache.query.SelectResults; import org.apache.geode.cache.query.data.PortfolioData; import org.apache.geode.internal.Assert; import org.apache.geode.internal.cache.PRQueryProcessor; import org.apache.geode.internal.cache.PartitionedRegionTestHelper; | import org.apache.geode.cache.*; import org.apache.geode.cache.query.*; import org.apache.geode.cache.query.data.*; import org.apache.geode.internal.*; import org.apache.geode.internal.cache.*; | [
"org.apache.geode"
] | org.apache.geode; | 2,890,794 |
public SecurityMetadataSource createSecurityMetadataSource( ActionConfig actionConfig, Object object );
| SecurityMetadataSource function( ActionConfig actionConfig, Object object ); | /**
* Creates an SecurityMetadataSource for a specified secure object based on
* the required authorities for the action config. The
* SecurityMetadataSource may include additional attributes if needed.
*
* @param actionConfig the actionConfig to get required authorities from.
* @par... | Creates an SecurityMetadataSource for a specified secure object based on the required authorities for the action config. The SecurityMetadataSource may include additional attributes if needed | createSecurityMetadataSource | {
"repo_name": "troyel/dhis2-core",
"path": "dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/security/authority/RequiredAuthoritiesProvider.java",
"license": "bsd-3-clause",
"size": 3277
} | [
"com.opensymphony.xwork2.config.entities.ActionConfig",
"org.springframework.security.access.SecurityMetadataSource"
] | import com.opensymphony.xwork2.config.entities.ActionConfig; import org.springframework.security.access.SecurityMetadataSource; | import com.opensymphony.xwork2.config.entities.*; import org.springframework.security.access.*; | [
"com.opensymphony.xwork2",
"org.springframework.security"
] | com.opensymphony.xwork2; org.springframework.security; | 2,009,295 |
void removeAddressInfo(SimpleString address, SecurityAuth auth, boolean force) throws Exception; | void removeAddressInfo(SimpleString address, SecurityAuth auth, boolean force) throws Exception; | /**
* Remove an {@code AddressInfo} from the broker.
*
* @param address the {@code AddressInfo} to remove
* @param auth authorization information; {@code null} is valid
* @param force It will disconnect everything from the address including queues and consumers
* @throws Exception
*/ | Remove an AddressInfo from the broker | removeAddressInfo | {
"repo_name": "iweiss/activemq-artemis",
"path": "artemis-server/src/main/java/org/apache/activemq/artemis/core/server/ActiveMQServer.java",
"license": "apache-2.0",
"size": 31258
} | [
"org.apache.activemq.artemis.api.core.SimpleString",
"org.apache.activemq.artemis.core.security.SecurityAuth"
] | import org.apache.activemq.artemis.api.core.SimpleString; import org.apache.activemq.artemis.core.security.SecurityAuth; | import org.apache.activemq.artemis.api.core.*; import org.apache.activemq.artemis.core.security.*; | [
"org.apache.activemq"
] | org.apache.activemq; | 1,051,983 |
void deleteSnapshots(Pattern pattern) throws IOException; | void deleteSnapshots(Pattern pattern) throws IOException; | /**
* Delete existing snapshots whose names match the pattern passed.
*
* @param pattern pattern for names of the snapshot to match
* @throws IOException if a remote or network exception occurs
*/ | Delete existing snapshots whose names match the pattern passed | deleteSnapshots | {
"repo_name": "francisliu/hbase",
"path": "hbase-client/src/main/java/org/apache/hadoop/hbase/client/Admin.java",
"license": "apache-2.0",
"size": 106428
} | [
"java.io.IOException",
"java.util.regex.Pattern"
] | import java.io.IOException; import java.util.regex.Pattern; | import java.io.*; import java.util.regex.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 1,803,708 |
private void fillCharBuf()
throws IOException
{
charBuffer.clear();
outer:
while (!flushed) {
CoderResult coderResult;
int charBufferPositionBefore = charBuffer.position();
if (!decodingFinished) {
coderResult = decoder.decode(byteBuffer, charBuffer, all... | void function() throws IOException { charBuffer.clear(); outer: while (!flushed) { CoderResult coderResult; int charBufferPositionBefore = charBuffer.position(); if (!decodingFinished) { coderResult = decoder.decode(byteBuffer, charBuffer, allInputConsumed); if (allInputConsumed) { decodingFinished = true; } } else { c... | /**
* Fill charBuffer with new character data. This method returns if
* either the charBuffer has been filled completely with decoded
* character data, or if EOF is reached in the underlying
* InputStream. When this method returns, charBuffer is flipped
* and ready to be read from.
*/ | Fill charBuffer with new character data. This method returns if either the charBuffer has been filled completely with decoded character data, or if EOF is reached in the underlying InputStream. When this method returns, charBuffer is flipped and ready to be read from | fillCharBuf | {
"repo_name": "SanDisk-Open-Source/SSD_Dashboard",
"path": "uefi/gcc/gcc-4.6.3/libjava/classpath/tools/gnu/classpath/tools/NotifyingInputStreamReader.java",
"license": "gpl-2.0",
"size": 14375
} | [
"java.io.IOException",
"java.nio.charset.CoderResult"
] | import java.io.IOException; import java.nio.charset.CoderResult; | import java.io.*; import java.nio.charset.*; | [
"java.io",
"java.nio"
] | java.io; java.nio; | 277,154 |
public interface TreeTableModel extends TreeModel
{
public int getColumnCount(); | interface TreeTableModel extends TreeModel { public int function(); | /**
* Returns the number ofs availible column.
*/ | Returns the number ofs availible column | getColumnCount | {
"repo_name": "tntim96/rhino-jscover-repackaged",
"path": "toolsrc/jscover/mozilla/javascript/tools/debugger/treetable/TreeTableModel.java",
"license": "mpl-2.0",
"size": 3158
} | [
"javax.swing.tree.TreeModel"
] | import javax.swing.tree.TreeModel; | import javax.swing.tree.*; | [
"javax.swing"
] | javax.swing; | 2,662,122 |
public IType getType(Class<?> type) {
return getTypeRepository().getType(type);
} | IType function(Class<?> type) { return getTypeRepository().getType(type); } | /**
* Retrieves the external type for the given Java type.
*
* @param type The Java type to wrap with an external form
* @return The external form of the given type
*/ | Retrieves the external type for the given Java type | getType | {
"repo_name": "RallySoftware/eclipselink.runtime",
"path": "jpa/org.eclipse.persistence.jpa.jpql/src/org/eclipse/persistence/jpa/jpql/tools/model/query/AbstractStateObject.java",
"license": "epl-1.0",
"size": 22504
} | [
"org.eclipse.persistence.jpa.jpql.tools.spi.IType"
] | import org.eclipse.persistence.jpa.jpql.tools.spi.IType; | import org.eclipse.persistence.jpa.jpql.tools.spi.*; | [
"org.eclipse.persistence"
] | org.eclipse.persistence; | 2,158,172 |
public void changeViewPosition(int incx, int incy) {
Point viewp = _scr.getViewport().getViewPosition();
_scr.getViewport().setViewSize(getPreferredSize());
_scr.getViewport().setViewPosition(new Point(viewp.x + incx, viewp.y + incy));
}
| void function(int incx, int incy) { Point viewp = _scr.getViewport().getViewPosition(); _scr.getViewport().setViewSize(getPreferredSize()); _scr.getViewport().setViewPosition(new Point(viewp.x + incx, viewp.y + incy)); } | /**
* Changes the viewposition of the drawpanel and recalculates the optimal drawpanelsize
*/ | Changes the viewposition of the drawpanel and recalculates the optimal drawpanelsize | changeViewPosition | {
"repo_name": "schuellerf/umlet",
"path": "umlet-swing/src/main/java/com/baselet/diagram/DrawPanel.java",
"license": "gpl-3.0",
"size": 20448
} | [
"java.awt.Point"
] | import java.awt.Point; | import java.awt.*; | [
"java.awt"
] | java.awt; | 2,841,415 |
@ConfigurationConverter
static SecretKey buildSecretKey(ConverterContext context) {
try {
return SecurityUtil.createSecretKey(context.getRawValue());
} catch (SecurityException e) {
throw new ConfigurationException(e);
}
} | static SecretKey buildSecretKey(ConverterContext context) { try { return SecurityUtil.createSecretKey(context.getRawValue()); } catch (SecurityException e) { throw new ConfigurationException(e); } } | /**
* Builds the secret key.
*
* @param context
* the context
* @return the secret key
*/ | Builds the secret key | buildSecretKey | {
"repo_name": "SirmaITT/conservation-space-1.7.0",
"path": "docker/sirma-platform/platform/seip-parent/platform/security/security-impl/src/main/java/com/sirma/itt/seip/security/configuration/SecurityConfigurationImpl.java",
"license": "lgpl-3.0",
"size": 18057
} | [
"com.sirma.itt.seip.configuration.ConfigurationException",
"com.sirma.itt.seip.configuration.convert.ConverterContext",
"com.sirma.itt.seip.security.exception.SecurityException",
"com.sirma.itt.seip.security.util.SecurityUtil",
"javax.crypto.SecretKey"
] | import com.sirma.itt.seip.configuration.ConfigurationException; import com.sirma.itt.seip.configuration.convert.ConverterContext; import com.sirma.itt.seip.security.exception.SecurityException; import com.sirma.itt.seip.security.util.SecurityUtil; import javax.crypto.SecretKey; | import com.sirma.itt.seip.configuration.*; import com.sirma.itt.seip.configuration.convert.*; import com.sirma.itt.seip.security.exception.*; import com.sirma.itt.seip.security.util.*; import javax.crypto.*; | [
"com.sirma.itt",
"javax.crypto"
] | com.sirma.itt; javax.crypto; | 1,623,065 |
@Test
public void allIteratorResolvedCorrectly() throws Exception {
String configXml = "xml/test-config.xml";
String inputConversionXml = "xml/for-operation/test-for-operation-basic.xml";
ConversionXmlProvider conversionProvider = new ConversionXmlProvider(
Resou... | void function() throws Exception { String configXml = STR; String inputConversionXml = STR; ConversionXmlProvider conversionProvider = new ConversionXmlProvider( ResourceHelper.getResourceInputStream(inputConversionXml), inputConversionXml, new FakeFormat()); ConfigXmlProvider configProvider = new ConfigXmlProvider(Res... | /**
* Checks that iterators are resolved in expected places: dynamic names/values, to/from/count of for operation.
*
* @throws Exception unexpected exceptions
*/ | Checks that iterators are resolved in expected places: dynamic names/values, to/from/count of for operation | allIteratorResolvedCorrectly | {
"repo_name": "DSRCorporation/imf-conversion",
"path": "imf-conversion-core/src/test/java/com/netflix/imfutility/conversion/executor/ConversionExecutorForTest.java",
"license": "gpl-3.0",
"size": 16815
} | [
"com.netflix.imfutility.FakeFormat",
"com.netflix.imfutility.config.ConfigXmlProvider",
"com.netflix.imfutility.conversion.ConversionXmlProvider",
"com.netflix.imfutility.conversion.templateParameter.context.TemplateParameterContextProvider",
"com.netflix.imfutility.resources.ResourceHelper",
"com.netflix... | import com.netflix.imfutility.FakeFormat; import com.netflix.imfutility.config.ConfigXmlProvider; import com.netflix.imfutility.conversion.ConversionXmlProvider; import com.netflix.imfutility.conversion.templateParameter.context.TemplateParameterContextProvider; import com.netflix.imfutility.resources.ResourceHelper; i... | import com.netflix.imfutility.*; import com.netflix.imfutility.config.*; import com.netflix.imfutility.conversion.*; import com.netflix.imfutility.resources.*; import com.netflix.imfutility.util.*; import org.junit.*; | [
"com.netflix.imfutility",
"org.junit"
] | com.netflix.imfutility; org.junit; | 535,015 |
InterledgerAddress getAddress(); | InterledgerAddress getAddress(); | /**
* Returns the Interledger address of the account.
*/ | Returns the Interledger address of the account | getAddress | {
"repo_name": "everis-innolab/interledger-ledger",
"path": "src/main/java/com/everis/everledger/ifaces/account/IfaceILPAccountInfo.java",
"license": "apache-2.0",
"size": 1269
} | [
"org.interledger.InterledgerAddress"
] | import org.interledger.InterledgerAddress; | import org.interledger.*; | [
"org.interledger"
] | org.interledger; | 1,226,171 |
public int read(ByteBuffer dst) throws IOException {
while (true) {
if (!dst.hasRemaining())
return 0;
if (!isHandShakeComplete()) {
if (isBlocking()) {
while (!isHandShakeComplete()) {
processHandshake();
}
} else {
processHandshake();
if (!isHandShakeComplete()) {
... | int function(ByteBuffer dst) throws IOException { while (true) { if (!dst.hasRemaining()) return 0; if (!isHandShakeComplete()) { if (isBlocking()) { while (!isHandShakeComplete()) { processHandshake(); } } else { processHandshake(); if (!isHandShakeComplete()) { return 0; } } } int purged = readRemaining(dst); if (pur... | /**
* Blocks when in blocking mode until at least one byte has been decoded.<br>
* When not in blocking mode 0 may be returned.
*
* @return the number of bytes read.
**/ | Blocks when in blocking mode until at least one byte has been decoded. When not in blocking mode 0 may be returned | read | {
"repo_name": "becast/Java-WebSocket",
"path": "src/main/java/org/java_websocket/SSLSocketChannel2.java",
"license": "mit",
"size": 12463
} | [
"java.io.IOException",
"java.nio.ByteBuffer",
"javax.net.ssl.SSLEngineResult"
] | import java.io.IOException; import java.nio.ByteBuffer; import javax.net.ssl.SSLEngineResult; | import java.io.*; import java.nio.*; import javax.net.ssl.*; | [
"java.io",
"java.nio",
"javax.net"
] | java.io; java.nio; javax.net; | 2,770,169 |
protected void parseOperationsLR(Symbol ops[], TokenList tokens, Sequence sequence) {
if( tokens.size == 0 )
return;
TokenList.Token token = tokens.first;
if( token.getType() != Type.VARIABLE )
throw new RuntimeException("The first token in an equation needs to be ... | void function(Symbol ops[], TokenList tokens, Sequence sequence) { if( tokens.size == 0 ) return; TokenList.Token token = tokens.first; if( token.getType() != Type.VARIABLE ) throw new RuntimeException(STR+token); boolean hasLeft = false; while( token != null ) { if( token.getType() == Type.FUNCTION ) { throw new Runti... | /**
* Parses operations where the input comes from variables to its left and right
*
* @param ops List of operations which should be parsed
* @param tokens List of all the tokens
* @param sequence List of operation sequence
*/ | Parses operations where the input comes from variables to its left and right | parseOperationsLR | {
"repo_name": "sizuest/EMod",
"path": "ch.ethz.inspire.emod/ejml-v0.26-src/main/equation/src/org/ejml/equation/Equation.java",
"license": "gpl-3.0",
"size": 46589
} | [
"org.ejml.equation.TokenList"
] | import org.ejml.equation.TokenList; | import org.ejml.equation.*; | [
"org.ejml.equation"
] | org.ejml.equation; | 2,256,681 |
public Configuration getConfig() {
return config;
}
| Configuration function() { return config; } | /**
* Returns the loaded configuration object.
*
* @return the configuration
*/ | Returns the loaded configuration object | getConfig | {
"repo_name": "lxil/easyhomework",
"path": "easyhomework/src/com/homework/auth/util/ConfigManager.java",
"license": "epl-1.0",
"size": 1688
} | [
"org.apache.commons.configuration.Configuration"
] | import org.apache.commons.configuration.Configuration; | import org.apache.commons.configuration.*; | [
"org.apache.commons"
] | org.apache.commons; | 468,669 |
private static boolean doesMarkerStartSegment(int markerSecondByte) {
if (markerSecondByte == JfifUtil.MARKER_TEM) {
return false;
}
if (markerSecondByte >= JfifUtil.MARKER_RST0 && markerSecondByte <= JfifUtil.MARKER_RST7) {
return false;
}
return markerSecondByte != JfifUtil.MARKER_... | static boolean function(int markerSecondByte) { if (markerSecondByte == JfifUtil.MARKER_TEM) { return false; } if (markerSecondByte >= JfifUtil.MARKER_RST0 && markerSecondByte <= JfifUtil.MARKER_RST7) { return false; } return markerSecondByte != JfifUtil.MARKER_EOI && markerSecondByte != JfifUtil.MARKER_SOI; } | /**
* Not every marker is followed by associated segment
*/ | Not every marker is followed by associated segment | doesMarkerStartSegment | {
"repo_name": "MaTriXy/fresco",
"path": "imagepipeline/src/main/java/com/facebook/imagepipeline/decoder/ProgressiveJpegParser.java",
"license": "bsd-3-clause",
"size": 9682
} | [
"com.facebook.imageutils.JfifUtil"
] | import com.facebook.imageutils.JfifUtil; | import com.facebook.imageutils.*; | [
"com.facebook.imageutils"
] | com.facebook.imageutils; | 2,669,662 |
RecordMetaData getMetaData(); | RecordMetaData getMetaData(); | /**
* Get the RecordMetaData for this record
*
* @return Metadata for this record (or null, if none has been set)
*/ | Get the RecordMetaData for this record | getMetaData | {
"repo_name": "huitseeker/DataVec",
"path": "datavec-api/src/main/java/org/datavec/api/records/Record.java",
"license": "apache-2.0",
"size": 1792
} | [
"org.datavec.api.records.metadata.RecordMetaData"
] | import org.datavec.api.records.metadata.RecordMetaData; | import org.datavec.api.records.metadata.*; | [
"org.datavec.api"
] | org.datavec.api; | 139,359 |
private void removeUnauthorizedData(List aList, Boolean isAuthorisedUser,
Boolean hasPrivilegeOnID,QueryResultObjectDataBean queryResultObjectDataBean)
{
if (isAuthorisedUser)
{
//If user is not authorized to see identified data then
//replace identified column values by ##
if (!hasPrivilegeO... | void function(List aList, Boolean isAuthorisedUser, Boolean hasPrivilegeOnID,QueryResultObjectDataBean queryResultObjectDataBean) { if (isAuthorisedUser) { if (!hasPrivilegeOnID) { removeUnauthorizedFieldsData(aList,true,queryResultObjectDataBean); } } else { removeUnauthorizedFieldsData(aList,false,queryResultObjectDa... | /**
* Remove the data that the user is not authorized to see.
* @param aList List of records
* @param isAuthorisedUser to specify if the user is authorized or not
* @param hasPrivilegeOnID to specify if the user has privilege to view identified data
* @param queryResultObjectDataBean Object of QueryResul... | Remove the data that the user is not authorized to see | removeUnauthorizedData | {
"repo_name": "NCIP/catissue-advanced-query",
"path": "software/AdvancedQuery/src/main/java/edu/wustl/query/security/QueryCsmCacheManager.java",
"license": "bsd-3-clause",
"size": 45241
} | [
"edu.wustl.query.beans.QueryResultObjectDataBean",
"java.util.List"
] | import edu.wustl.query.beans.QueryResultObjectDataBean; import java.util.List; | import edu.wustl.query.beans.*; import java.util.*; | [
"edu.wustl.query",
"java.util"
] | edu.wustl.query; java.util; | 2,328,380 |
@Override
public NamingEnumeration<SearchResult> search(String name,
Attributes matchingAttributes) throws NamingException {
throw new OperationNotSupportedException();
} | NamingEnumeration<SearchResult> function(String name, Attributes matchingAttributes) throws NamingException { throw new OperationNotSupportedException(); } | /**
* Searches in a single context for objects that contain a specified set
* of attributes. This method returns all the attributes of such objects.
* It is equivalent to supplying null as the atributesToReturn parameter
* to the method search(Name, Attributes, String[]).
*
* @param na... | Searches in a single context for objects that contain a specified set of attributes. This method returns all the attributes of such objects. It is equivalent to supplying null as the atributesToReturn parameter to the method search(Name, Attributes, String[]) | search | {
"repo_name": "mayonghui2112/helloWorld",
"path": "sourceCode/apache-tomcat-7.0.82-src/java/org/apache/naming/resources/WARDirContext.java",
"license": "apache-2.0",
"size": 32481
} | [
"javax.naming.NamingEnumeration",
"javax.naming.NamingException",
"javax.naming.OperationNotSupportedException",
"javax.naming.directory.Attributes",
"javax.naming.directory.SearchResult"
] | import javax.naming.NamingEnumeration; import javax.naming.NamingException; import javax.naming.OperationNotSupportedException; import javax.naming.directory.Attributes; import javax.naming.directory.SearchResult; | import javax.naming.*; import javax.naming.directory.*; | [
"javax.naming"
] | javax.naming; | 593,708 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.