method
stringlengths
13
441k
clean_method
stringlengths
7
313k
doc
stringlengths
17
17.3k
comment
stringlengths
3
1.42k
method_name
stringlengths
1
273
extra
dict
imports
list
imports_info
stringlengths
19
34.8k
cluster_imports_info
stringlengths
15
3.66k
libraries
list
libraries_info
stringlengths
6
661
id
int64
0
2.92M
public void updateScrollableAreaLimit() { if (mScrollableAreaBoundingBox == null || !isLayedOut()) { return; } if (mScrollableAreaLimit == null) { mScrollableAreaLimit = new RectF(); } Projection.toMapPixels(mScrollableAreaBoundingBox, getZoomLevel(fal...
void function() { if (mScrollableAreaBoundingBox == null !isLayedOut()) { return; } if (mScrollableAreaLimit == null) { mScrollableAreaLimit = new RectF(); } Projection.toMapPixels(mScrollableAreaBoundingBox, getZoomLevel(false), mScrollableAreaLimit); }
/** * Everytime we update the zoom or the view size we must re compute the real scrollable area * limit in pixels */
Everytime we update the zoom or the view size we must re compute the real scrollable area limit in pixels
updateScrollableAreaLimit
{ "repo_name": "AmericanRedCross/OpenMapKitAndroid", "path": "MapboxAndroidSDK/src/main/java/com/mapbox/mapboxsdk/views/MapView.java", "license": "bsd-3-clause", "size": 77021 }
[ "android.graphics.RectF", "com.mapbox.mapboxsdk.views.util.Projection" ]
import android.graphics.RectF; import com.mapbox.mapboxsdk.views.util.Projection;
import android.graphics.*; import com.mapbox.mapboxsdk.views.util.*;
[ "android.graphics", "com.mapbox.mapboxsdk" ]
android.graphics; com.mapbox.mapboxsdk;
70,525
public Timestamp getDateNextRun(); public static final String COLUMNNAME_Description = "Description";
Timestamp function(); public static final String COLUMNNAME_Description = STR;
/** Get Date next run. * Date the process will run next */
Get Date next run. Date the process will run next
getDateNextRun
{ "repo_name": "geneos/adempiere", "path": "base/src/org/compiere/model/I_R_RequestProcessor.java", "license": "gpl-2.0", "size": 8967 }
[ "java.sql.Timestamp" ]
import java.sql.Timestamp;
import java.sql.*;
[ "java.sql" ]
java.sql;
880,045
public com.sk89q.worldedit.Vector getWorldEditLocation() { Location loc = player.getEyeLocation(); return new WorldVector(BukkitUtil.getLocalWorld(loc.getWorld()), loc.getX(), loc.getY(), loc.getZ()); }
com.sk89q.worldedit.Vector function() { Location loc = player.getEyeLocation(); return new WorldVector(BukkitUtil.getLocalWorld(loc.getWorld()), loc.getX(), loc.getY(), loc.getZ()); }
/** * Get the world edit representation of a players location * * @return A world edit vector representation of a players location */
Get the world edit representation of a players location
getWorldEditLocation
{ "repo_name": "CodingBadgers/MineKart", "path": "minekart/src/main/java/uk/thecodingbadgers/minekart/jockey/Jockey.java", "license": "gpl-2.0", "size": 13881 }
[ "com.sk89q.worldedit.WorldVector", "com.sk89q.worldedit.bukkit.BukkitUtil", "org.bukkit.Location", "org.bukkit.util.Vector" ]
import com.sk89q.worldedit.WorldVector; import com.sk89q.worldedit.bukkit.BukkitUtil; import org.bukkit.Location; import org.bukkit.util.Vector;
import com.sk89q.worldedit.*; import com.sk89q.worldedit.bukkit.*; import org.bukkit.*; import org.bukkit.util.*;
[ "com.sk89q.worldedit", "org.bukkit", "org.bukkit.util" ]
com.sk89q.worldedit; org.bukkit; org.bukkit.util;
322,064
@Test public void testModelCollectionCopy() throws Exception { Logger.getLogger(getClass()).debug("TEST " + name.getMethodName()); CopyConstructorTester tester = new CopyConstructorTester(object); tester.proxy(Report.class, 1, r1); tester.proxy(Report.class, 2, r2); tester.proxy(ReportResult.cl...
void function() throws Exception { Logger.getLogger(getClass()).debug(STR + name.getMethodName()); CopyConstructorTester tester = new CopyConstructorTester(object); tester.proxy(Report.class, 1, r1); tester.proxy(Report.class, 2, r2); tester.proxy(ReportResult.class, 1, i1); tester.proxy(ReportResult.class, 2, i2); ass...
/** * Test deep copy constructor. * * @throws Exception the exception */
Test deep copy constructor
testModelCollectionCopy
{ "repo_name": "WestCoastInformatics/UMLS-Terminology-Server", "path": "jpa-model/src/test/java/com/wci/umls/server/jpa/test/report/ReportResultItemJpaUnitTest.java", "license": "apache-2.0", "size": 5050 }
[ "com.wci.umls.server.helpers.CopyConstructorTester", "com.wci.umls.server.model.report.Report", "com.wci.umls.server.model.report.ReportResult", "com.wci.umls.server.model.report.ReportResultItem", "org.apache.log4j.Logger", "org.junit.Assert" ]
import com.wci.umls.server.helpers.CopyConstructorTester; import com.wci.umls.server.model.report.Report; import com.wci.umls.server.model.report.ReportResult; import com.wci.umls.server.model.report.ReportResultItem; import org.apache.log4j.Logger; import org.junit.Assert;
import com.wci.umls.server.helpers.*; import com.wci.umls.server.model.report.*; import org.apache.log4j.*; import org.junit.*;
[ "com.wci.umls", "org.apache.log4j", "org.junit" ]
com.wci.umls; org.apache.log4j; org.junit;
1,420,374
public GeometryIndex getPreviousVertex(GeometryIndex index) { return null; }
GeometryIndex function(GeometryIndex index) { return null; }
/** * Given a certain index, find the previous vertex in line. * * @param index * The index to start out from. Must point to either a vertex or and edge. * @return Returns the previous vertex index. Note that no geometry is given, and so no actual checking is done. It * just returns the ...
Given a certain index, find the previous vertex in line
getPreviousVertex
{ "repo_name": "geomajas/geomajas-project-client-gwt", "path": "plugin/editing/editing-javascript-api/src/main/java/org/geomajas/plugin/editing/jsapi/client/service/JsGeometryIndexService.java", "license": "agpl-3.0", "size": 11965 }
[ "org.geomajas.plugin.editing.client.service.GeometryIndex" ]
import org.geomajas.plugin.editing.client.service.GeometryIndex;
import org.geomajas.plugin.editing.client.service.*;
[ "org.geomajas.plugin" ]
org.geomajas.plugin;
1,299,673
@Test public void testInvalidateWaiting() throws Exception { GenericKeyedObjectPoolConfig config = new GenericKeyedObjectPoolConfig(); config.setMaxTotal(2); config.setBlockWhenExhausted(true); config.setMinIdlePerKey(0); config.setMaxWaitMillis(-1); conf...
void function() throws Exception { GenericKeyedObjectPoolConfig config = new GenericKeyedObjectPoolConfig(); config.setMaxTotal(2); config.setBlockWhenExhausted(true); config.setMinIdlePerKey(0); config.setMaxWaitMillis(-1); config.setNumTestsPerEvictionRun(Integer.MAX_VALUE); config.setTestOnBorrow(true); config.setTe...
/** * Verify that threads blocked waiting on a depleted pool get served when a checked out instance * is invalidated. * * JIRA: POOL-240 */
Verify that threads blocked waiting on a depleted pool get served when a checked out instance is invalidated
testInvalidateWaiting
{ "repo_name": "kinow/commons-pool", "path": "src/test/java/org/apache/commons/pool2/impl/TestGenericKeyedObjectPool.java", "license": "apache-2.0", "size": 77198 }
[ "java.util.concurrent.Callable", "java.util.concurrent.ExecutorService", "java.util.concurrent.Executors", "java.util.concurrent.Future", "java.util.concurrent.Semaphore" ]
import java.util.concurrent.Callable; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Future; import java.util.concurrent.Semaphore;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
1,337,116
@Source("horizontal-prev.png") ImageResource horizontalPrev();
@Source(STR) ImageResource horizontalPrev();
/** * The horizontal prev image * * @return {@link ImageResource} the horizontal prev image */
The horizontal prev image
horizontalPrev
{ "repo_name": "lamirand-g/ItemLayout", "path": "itemlayout/src/main/java/org/vaadin/addon/itemlayout/widgetset/client/model/ResourceBundle.java", "license": "apache-2.0", "size": 1952 }
[ "com.google.gwt.resources.client.ImageResource" ]
import com.google.gwt.resources.client.ImageResource;
import com.google.gwt.resources.client.*;
[ "com.google.gwt" ]
com.google.gwt;
2,239,152
private static String quoteString(String s) { if (s == null) { return ""; } int len = s.length(); StringBuffer buf = new StringBuffer(len + 2); buf.append('"'); for (int off = 0; off < len; ) { int quote = s.indexOf('"', off); int slash = s.indexOf('\\', off); if (quote >= 0 && (slash < 0 ...
static String function(String s) { if (s == null) { return STR'); for (int off = 0; off < len; ) { int quote = s.indexOf('STR\\\STR\\\\STR'); return buf.toString(); } private static class Request { final CodeSource codeSource; final Certificate[] certs; final Principal[] principals; final Permission[] perms; Request(Pr...
/** * Returns a quoted version of the argument, such that it would result in * the argument if read from a file with the standard String syntax. */
Returns a quoted version of the argument, such that it would result in the argument if read from a file with the standard String syntax
quoteString
{ "repo_name": "trasukg/river-qa-2.2", "path": "src/com/sun/jini/tool/DebugDynamicPolicyProvider.java", "license": "apache-2.0", "size": 16000 }
[ "java.security.CodeSource", "java.security.Permission", "java.security.Principal", "java.security.ProtectionDomain", "java.security.cert.Certificate" ]
import java.security.CodeSource; import java.security.Permission; import java.security.Principal; import java.security.ProtectionDomain; import java.security.cert.Certificate;
import java.security.*; import java.security.cert.*;
[ "java.security" ]
java.security;
1,310,127
public void aliasPackage(final String name, final String pkgName) { if (packageAliasingMapper == null) { throw new InitializationException("No " + PackageAliasingMapper.class.getName() + " available"); } packageAliasingMapper.addPackageAlias(name, pkgName); }
void function(final String name, final String pkgName) { if (packageAliasingMapper == null) { throw new InitializationException(STR + PackageAliasingMapper.class.getName() + STR); } packageAliasingMapper.addPackageAlias(name, pkgName); }
/** * Alias a package to a shorter name to be used in XML elements. * * @param name Short name * @param pkgName package to be aliased * @throws InitializationException if no {@link DefaultImplementationsMapper} or no {@link PackageAliasingMapper} is * available * @since 1...
Alias a package to a shorter name to be used in XML elements
aliasPackage
{ "repo_name": "Groostav/xstream", "path": "xstream/src/java/com/thoughtworks/xstream/XStream.java", "license": "bsd-3-clause", "size": 90961 }
[ "com.thoughtworks.xstream.mapper.PackageAliasingMapper" ]
import com.thoughtworks.xstream.mapper.PackageAliasingMapper;
import com.thoughtworks.xstream.mapper.*;
[ "com.thoughtworks.xstream" ]
com.thoughtworks.xstream;
967,943
@Override public Grid operate(Grid src, Grid dst) { throw new UnsupportedOperationException(); }
Grid function(Grid src, Grid dst) { throw new UnsupportedOperationException(); }
/** * * Do not call this method. * * @param src * @param dst * @return */
Do not call this method
operate
{ "repo_name": "OSUCartography/PyramidShader", "path": "src/edu/oregonstate/cartography/grid/operators/MinMaxOperator.java", "license": "gpl-3.0", "size": 3978 }
[ "edu.oregonstate.cartography.grid.Grid" ]
import edu.oregonstate.cartography.grid.Grid;
import edu.oregonstate.cartography.grid.*;
[ "edu.oregonstate.cartography" ]
edu.oregonstate.cartography;
2,394,473
public static void convert(String input, String output) throws FormatException, IOException { IFormatReader reader = new ImageReader(); try { ServiceFactory factory = new ServiceFactory(); OMEXMLService service = factory.getInstance(OMEXMLService.class); reader.setMetadataStore(service...
static void function(String input, String output) throws FormatException, IOException { IFormatReader reader = new ImageReader(); try { ServiceFactory factory = new ServiceFactory(); OMEXMLService service = factory.getInstance(OMEXMLService.class); reader.setMetadataStore(service.createOMEXMLMetadata()); } catch (Depen...
/** * Convenience method for converting the specified input file to the * specified output file. The ImageReader and ImageWriter classes are used * for input and output, respectively. To use other IFormatReader or * IFormatWriter implementation, * @see convert(IFormatReader, IFormatWriter, String). ...
Convenience method for converting the specified input file to the specified output file. The ImageReader and ImageWriter classes are used for input and output, respectively. To use other IFormatReader or IFormatWriter implementation
convert
{ "repo_name": "ximenesuk/bioformats", "path": "components/scifio/src/loci/formats/FormatTools.java", "license": "gpl-2.0", "size": 38113 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,310,889
EReference getParameterValueMapping_Parameter();
EReference getParameterValueMapping_Parameter();
/** * Returns the meta object for the reference '{@link ca.mcgill.cs.sel.ram.ParameterValueMapping#getParameter <em>Parameter</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the reference '<em>Parameter</em>'. * @see ca.mcgill.cs.sel.ram.ParameterValueMap...
Returns the meta object for the reference '<code>ca.mcgill.cs.sel.ram.ParameterValueMapping#getParameter Parameter</code>'.
getParameterValueMapping_Parameter
{ "repo_name": "mjorod/textram", "path": "tool/ca.mcgill.sel.ram/src/ca/mcgill/cs/sel/ram/RamPackage.java", "license": "mit", "size": 271132 }
[ "org.eclipse.emf.ecore.EReference" ]
import org.eclipse.emf.ecore.EReference;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,065,354
protected File[] getFiles() { Vector v = new Vector(); final int size = filesets.size(); for (int i = 0; i < size; i++) { FileSet fs = (FileSet) filesets.elementAt(i); DirectoryScanner ds = fs.getDirectoryScanner(getProject()); ds.scan(); Strin...
File[] function() { Vector v = new Vector(); final int size = filesets.size(); for (int i = 0; i < size; i++) { FileSet fs = (FileSet) filesets.elementAt(i); DirectoryScanner ds = fs.getDirectoryScanner(getProject()); ds.scan(); String[] f = ds.getIncludedFiles(); for (int j = 0; j < f.length; j++) { String pathname = ...
/** * Get all <code>.xml</code> files in the fileset. * * @return all files in the fileset that end with a '.xml'. */
Get all <code>.xml</code> files in the fileset
getFiles
{ "repo_name": "Mayo-WE01051879/mayosapp", "path": "Build/src/main/org/apache/tools/ant/taskdefs/optional/junit/XMLResultAggregator.java", "license": "mit", "size": 12797 }
[ "java.io.File", "java.util.Vector", "org.apache.tools.ant.DirectoryScanner", "org.apache.tools.ant.types.FileSet" ]
import java.io.File; import java.util.Vector; import org.apache.tools.ant.DirectoryScanner; import org.apache.tools.ant.types.FileSet;
import java.io.*; import java.util.*; import org.apache.tools.ant.*; import org.apache.tools.ant.types.*;
[ "java.io", "java.util", "org.apache.tools" ]
java.io; java.util; org.apache.tools;
402,672
public void maybeThrowPlaylistRefreshError(HlsUrl url) throws IOException { playlistBundles.get(url).mediaPlaylistLoader.maybeThrowError(); }
void function(HlsUrl url) throws IOException { playlistBundles.get(url).mediaPlaylistLoader.maybeThrowError(); }
/** * If the playlist is having trouble loading the playlist referenced by the given {@link HlsUrl}, * this method throws the underlying error. * * @param url The {@link HlsUrl}. * @throws IOException The underyling error. */
If the playlist is having trouble loading the playlist referenced by the given <code>HlsUrl</code>, this method throws the underlying error
maybeThrowPlaylistRefreshError
{ "repo_name": "michalliu/ExoPlayer", "path": "library/hls/src/main/java/com/google/android/exoplayer2/source/hls/playlist/HlsPlaylistTracker.java", "license": "apache-2.0", "size": 21353 }
[ "com.google.android.exoplayer2.source.hls.playlist.HlsMasterPlaylist", "java.io.IOException" ]
import com.google.android.exoplayer2.source.hls.playlist.HlsMasterPlaylist; import java.io.IOException;
import com.google.android.exoplayer2.source.hls.playlist.*; import java.io.*;
[ "com.google.android", "java.io" ]
com.google.android; java.io;
1,577,661
@Override public int run(String[] args) throws Exception { final List<String> nonFlagArgs = FlagParser.init(this, args); if (null == nonFlagArgs) { // The flags were not parsed. return 1; } // Load HBase configuration before connecting to Kiji. setConf(HBaseConfiguration.addHbaseRes...
int function(String[] args) throws Exception { final List<String> nonFlagArgs = FlagParser.init(this, args); if (null == nonFlagArgs) { return 1; } setConf(HBaseConfiguration.addHbaseResources(getConf())); final Job job = new Job(getConf(), STR); job.setInputFormatClass(KijiTableInputFormat.class); final KijiDataReques...
/** * Deletes all entries from the phonebook table from a specified US state. * * @param args The command line arguments (we expect a --state=XX arg here). * @return The status code for the application; 0 indicates success. * @throws Exception If there is an error running the Kiji program. */
Deletes all entries from the phonebook table from a specified US state
run
{ "repo_name": "kijiproject/kiji-phonebook", "path": "src/main/java/org/kiji/examples/phonebook/DeleteEntriesByState.java", "license": "apache-2.0", "size": 9000 }
[ "java.util.List", "org.apache.hadoop.hbase.HBaseConfiguration", "org.apache.hadoop.mapreduce.Job", "org.kiji.common.flags.FlagParser", "org.kiji.mapreduce.platform.KijiMRPlatformBridge", "org.kiji.schema.KijiDataRequest", "org.kiji.schema.KijiURI", "org.kiji.schema.mapreduce.KijiTableInputFormat" ]
import java.util.List; import org.apache.hadoop.hbase.HBaseConfiguration; import org.apache.hadoop.mapreduce.Job; import org.kiji.common.flags.FlagParser; import org.kiji.mapreduce.platform.KijiMRPlatformBridge; import org.kiji.schema.KijiDataRequest; import org.kiji.schema.KijiURI; import org.kiji.schema.mapreduce.Kij...
import java.util.*; import org.apache.hadoop.hbase.*; import org.apache.hadoop.mapreduce.*; import org.kiji.common.flags.*; import org.kiji.mapreduce.platform.*; import org.kiji.schema.*; import org.kiji.schema.mapreduce.*;
[ "java.util", "org.apache.hadoop", "org.kiji.common", "org.kiji.mapreduce", "org.kiji.schema" ]
java.util; org.apache.hadoop; org.kiji.common; org.kiji.mapreduce; org.kiji.schema;
2,713,083
private void processJobsFromPreviousVersions() { final ResourceResolver resolver = configuration.createResourceResolver(); if ( resolver != null ) { try { this.processJobsFromPreviousVersions(resolver.getResource(configuration.getPreviousVersionAnonPath())); ...
void function() { final ResourceResolver resolver = configuration.createResourceResolver(); if ( resolver != null ) { try { this.processJobsFromPreviousVersions(resolver.getResource(configuration.getPreviousVersionAnonPath())); this.processJobsFromPreviousVersions(resolver.getResource(configuration.getPreviousVersionId...
/** * Handle jobs from previous versions (<= 3.1.4) by moving them to the unassigned area */
Handle jobs from previous versions (<= 3.1.4) by moving them to the unassigned area
processJobsFromPreviousVersions
{ "repo_name": "nleite/sling", "path": "bundles/extensions/event/src/main/java/org/apache/sling/event/impl/jobs/tasks/UpgradeTask.java", "license": "apache-2.0", "size": 12427 }
[ "org.apache.sling.api.resource.PersistenceException", "org.apache.sling.api.resource.ResourceResolver" ]
import org.apache.sling.api.resource.PersistenceException; import org.apache.sling.api.resource.ResourceResolver;
import org.apache.sling.api.resource.*;
[ "org.apache.sling" ]
org.apache.sling;
2,730,932
public ElementEvents getEventsFor(Element element) { if (eventsFor != null) return eventsFor.get(element); return null; }
ElementEvents function(Element element) { if (eventsFor != null) return eventsFor.get(element); return null; }
/** * Set of events for a given element or null if the element has not * currently occurring events. * * @return A set of events or null if none occurring at that time. */
Set of events for a given element or null if the element has not currently occurring events
getEventsFor
{ "repo_name": "margaritis/gs-core", "path": "src/org/graphstream/ui/graphicGraph/StyleGroup.java", "license": "lgpl-3.0", "size": 22209 }
[ "org.graphstream.graph.Element" ]
import org.graphstream.graph.Element;
import org.graphstream.graph.*;
[ "org.graphstream.graph" ]
org.graphstream.graph;
406,637
@Scheduled(cron = "0 0 4 * * ?") public void cleanupUploadedFiles() { fileUploadService.cleanup(); }
@Scheduled(cron = STR) void function() { fileUploadService.cleanup(); }
/** * Scheduled every day at 4:00. If an user stop an upload, it * will be removed from memory */
Scheduled every day at 4:00. If an user stop an upload, it will be removed from memory
cleanupUploadedFiles
{ "repo_name": "offtherailz/OpenSDI-Manager2", "path": "src/modules/filemanager/src/main/java/it/geosolutions/opensdi2/mvc/BaseFileManager.java", "license": "gpl-3.0", "size": 21874 }
[ "org.springframework.scheduling.annotation.Scheduled" ]
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.scheduling.annotation.*;
[ "org.springframework.scheduling" ]
org.springframework.scheduling;
1,674,894
public void connect() { if (this.mWsClient.getReadyState() == READYSTATE.CLOSED) { // we need to create a new wsClient because a closed websocket cannot be reused try { createWsClient(mMeteorServerAddress); initWsClientSSL(); } catch (URISy...
void function() { if (this.mWsClient.getReadyState() == READYSTATE.CLOSED) { try { createWsClient(mMeteorServerAddress); initWsClientSSL(); } catch (URISyntaxException e) { } } if (!mConnectionStarted) { this.mWsClient.connect(); mConnectionStarted = true; } }
/** * Initiate connection to meteor server */
Initiate connection to meteor server
connect
{ "repo_name": "kenyee/java-ddp-client", "path": "src/main/java/com/keysolutions/ddpclient/DDPClient.java", "license": "apache-2.0", "size": 29693 }
[ "java.net.URISyntaxException" ]
import java.net.URISyntaxException;
import java.net.*;
[ "java.net" ]
java.net;
1,500,761
@Override protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); }
void function(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); }
/** * Handles the HTTP <code>POST</code> method. * * @param request servlet request * @param response servlet response * @throws ServletException if a servlet-specific error occurs * @throws IOException if an I/O error occurs */
Handles the HTTP <code>POST</code> method
doPost
{ "repo_name": "cerberustesting/cerberus-source", "path": "source/src/main/java/org/cerberus/servlet/crud/test/testcase/ExportTestCase.java", "license": "gpl-3.0", "size": 7090 }
[ "java.io.IOException", "javax.servlet.ServletException", "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse" ]
import java.io.IOException; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse;
import java.io.*; import javax.servlet.*; import javax.servlet.http.*;
[ "java.io", "javax.servlet" ]
java.io; javax.servlet;
2,891,440
private List<String> getChampionNames(String url) throws IOException { logger.log(Level.FINER, "get Champion Names from URL: " + url); List<String> result = new ArrayList<String>(); URL theUrl = new URL(url); BufferedReader in = new BufferedReader(new InputStreamReader(theUrl.openConnection().getInputStream...
List<String> function(String url) throws IOException { logger.log(Level.FINER, STR + url); List<String> result = new ArrayList<String>(); URL theUrl = new URL(url); BufferedReader in = new BufferedReader(new InputStreamReader(theUrl.openConnection().getInputStream())); String line; String json = STR\nSTR.*<div lang=\"e...
/** * gets the champion names from the given url * * @param url * given url * * @return list with all names * * @throws IOException */
gets the champion names from the given url
getChampionNames
{ "repo_name": "cf86/LoLToolKit", "path": "src/main/java/model/collector/WebsiteDataCollector.java", "license": "gpl-3.0", "size": 19928 }
[ "java.io.BufferedReader", "java.io.IOException", "java.io.InputStreamReader", "java.util.ArrayList", "java.util.Arrays", "java.util.List", "java.util.logging.Level" ]
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.logging.Level;
import java.io.*; import java.util.*; import java.util.logging.*;
[ "java.io", "java.util" ]
java.io; java.util;
617,320
private CacheEntry cacheLocked(ComponentName componentName, LauncherActivityInfoCompat info, UserHandleCompat user, boolean usePackageIcon, boolean useLowResIcon) { ComponentKey cacheKey = new ComponentKey(componentName, user); CacheEntry entry = mCache.get(cacheKey); if (entry =...
CacheEntry function(ComponentName componentName, LauncherActivityInfoCompat info, UserHandleCompat user, boolean usePackageIcon, boolean useLowResIcon) { ComponentKey cacheKey = new ComponentKey(componentName, user); CacheEntry entry = mCache.get(cacheKey); if (entry == null (entry.isLowResIcon && !useLowResIcon)) { en...
/** * Retrieves the entry from the cache. If the entry is not present, it creates a new entry. * This method is not thread safe, it must be called from a synchronized method. */
Retrieves the entry from the cache. If the entry is not present, it creates a new entry. This method is not thread safe, it must be called from a synchronized method
cacheLocked
{ "repo_name": "YAJATapps/FlickLauncher", "path": "src/com/android/launcher3/IconCache.java", "license": "apache-2.0", "size": 38511 }
[ "android.content.ComponentName", "android.text.TextUtils", "android.util.Log", "com.android.launcher3.compat.LauncherActivityInfoCompat", "com.android.launcher3.compat.UserHandleCompat", "com.android.launcher3.util.ComponentKey" ]
import android.content.ComponentName; import android.text.TextUtils; import android.util.Log; import com.android.launcher3.compat.LauncherActivityInfoCompat; import com.android.launcher3.compat.UserHandleCompat; import com.android.launcher3.util.ComponentKey;
import android.content.*; import android.text.*; import android.util.*; import com.android.launcher3.compat.*; import com.android.launcher3.util.*;
[ "android.content", "android.text", "android.util", "com.android.launcher3" ]
android.content; android.text; android.util; com.android.launcher3;
949,923
@XmlElement(name = "title") public String getTitle() { return title; }
@XmlElement(name = "title") String function() { return title; }
/** * Catalog Category's title * */
Catalog Category's title
getTitle
{ "repo_name": "emcvipr/controller-client-java", "path": "models/src/main/java/com/emc/vipr/model/catalog/CatalogCategoryRestRep.java", "license": "apache-2.0", "size": 2296 }
[ "javax.xml.bind.annotation.XmlElement" ]
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.*;
[ "javax.xml" ]
javax.xml;
72,341
public void setAllowCompression(boolean allowCompression) { if (httpClient instanceof DefaultHttpClient) { HttpClientUtil.setAllowCompression((DefaultHttpClient) httpClient, allowCompression); } else { throw new UnsupportedOperationException( "HttpClient instance was not of type DefaultH...
void function(boolean allowCompression) { if (httpClient instanceof DefaultHttpClient) { HttpClientUtil.setAllowCompression((DefaultHttpClient) httpClient, allowCompression); } else { throw new UnsupportedOperationException( STR); } }
/** * Allow server->client communication to be compressed. Currently gzip and * deflate are supported. If the server supports compression the response will * be compressed. This method is only allowed if the http client is of type * DefatulHttpClient. */
Allow server->client communication to be compressed. Currently gzip and deflate are supported. If the server supports compression the response will be compressed. This method is only allowed if the http client is of type DefatulHttpClient
setAllowCompression
{ "repo_name": "cscorley/solr-only-mirror", "path": "solrj/src/java/org/apache/solr/client/solrj/impl/HttpSolrServer.java", "license": "apache-2.0", "size": 29058 }
[ "org.apache.http.impl.client.DefaultHttpClient" ]
import org.apache.http.impl.client.DefaultHttpClient;
import org.apache.http.impl.client.*;
[ "org.apache.http" ]
org.apache.http;
1,009,103
public int mkCol(final String url) throws IOException { lazyInitialise(url); final MkColMethod mkcol = new MkColMethod(url); try { return client.executeMethod(mkcol); } finally { mkcol.releaseConnection(); } }
int function(final String url) throws IOException { lazyInitialise(url); final MkColMethod mkcol = new MkColMethod(url); try { return client.executeMethod(mkcol); } finally { mkcol.releaseConnection(); } }
/** * DOCUMENT ME! * * @param url DOCUMENT ME! * * @return DOCUMENT ME! * * @throws IOException DOCUMENT ME! */
DOCUMENT ME
mkCol
{ "repo_name": "cismet/cismet-commons", "path": "src/main/java/de/cismet/commons/security/WebDavClient.java", "license": "lgpl-3.0", "size": 11508 }
[ "java.io.IOException", "org.apache.jackrabbit.webdav.client.methods.MkColMethod" ]
import java.io.IOException; import org.apache.jackrabbit.webdav.client.methods.MkColMethod;
import java.io.*; import org.apache.jackrabbit.webdav.client.methods.*;
[ "java.io", "org.apache.jackrabbit" ]
java.io; org.apache.jackrabbit;
110,178
public StringArray getFeature3() { if (FeatureStructure2_Type.featOkTst && ((FeatureStructure2_Type)jcasType).casFeat_feature3 == null) jcasType.jcas.throwFeatMissing("feature3", "org.apache.uima.lucas.indexer.types.test.FeatureStructure2"); return (StringArray)(jcasType.ll_cas.ll_getFSForRef(jcasTyp...
StringArray function() { if (FeatureStructure2_Type.featOkTst && ((FeatureStructure2_Type)jcasType).casFeat_feature3 == null) jcasType.jcas.throwFeatMissing(STR, STR); return (StringArray)(jcasType.ll_cas.ll_getFSForRef(jcasType.ll_cas.ll_getRefValue(addr, ((FeatureStructure2_Type)jcasType).casFeatCode_feature3)));}
/** getter for feature3 - gets * @generated */
getter for feature3 - gets
getFeature3
{ "repo_name": "christianherta/BBC-DaaS", "path": "uima_components/uima_components/lucas/src/test/java/org/apache/uima/lucas/indexer/types/test/FeatureStructure2.java", "license": "apache-2.0", "size": 5516 }
[ "org.apache.uima.jcas.cas.StringArray" ]
import org.apache.uima.jcas.cas.StringArray;
import org.apache.uima.jcas.cas.*;
[ "org.apache.uima" ]
org.apache.uima;
2,634,734
public static void registerAll() { // First register Politics commands new PoliticsCommands().register(); // Then register Universe commands new UniverseCommands().register(); // Now register all Group commands for (final GroupLevel level : Politics.getUniverseManag...
static void function() { new PoliticsCommands().register(); new UniverseCommands().register(); for (final GroupLevel level : Politics.getUniverseManager().getGroupLevels()) { new GroupCommands(level).register(); } }
/** * Registers all of the commands in Politics */
Registers all of the commands in Politics
registerAll
{ "repo_name": "VolumetricPixels/Politics", "path": "src/main/java/com/volumetricpixels/politics/command/Commands.java", "license": "agpl-3.0", "size": 2612 }
[ "com.volumetricpixels.politics.Politics", "com.volumetricpixels.politics.command.group.GroupCommands", "com.volumetricpixels.politics.command.politics.PoliticsCommands", "com.volumetricpixels.politics.command.universe.UniverseCommands", "com.volumetricpixels.politics.group.level.GroupLevel" ]
import com.volumetricpixels.politics.Politics; import com.volumetricpixels.politics.command.group.GroupCommands; import com.volumetricpixels.politics.command.politics.PoliticsCommands; import com.volumetricpixels.politics.command.universe.UniverseCommands; import com.volumetricpixels.politics.group.level.GroupLevel;
import com.volumetricpixels.politics.*; import com.volumetricpixels.politics.command.group.*; import com.volumetricpixels.politics.command.politics.*; import com.volumetricpixels.politics.command.universe.*; import com.volumetricpixels.politics.group.level.*;
[ "com.volumetricpixels.politics" ]
com.volumetricpixels.politics;
1,837,052
public Future<CommandResult> removeGroupResponse(Integer status, Integer groupId) { RemoveGroupResponse command = new RemoveGroupResponse(); // Set the fields command.setStatus(status); command.setGroupId(groupId); return send(command); }
Future<CommandResult> function(Integer status, Integer groupId) { RemoveGroupResponse command = new RemoveGroupResponse(); command.setStatus(status); command.setGroupId(groupId); return send(command); }
/** * The Remove Group Response * * @param status {@link Integer} Status * @param groupId {@link Integer} Group ID * @return the {@link Future<CommandResult>} command result future */
The Remove Group Response
removeGroupResponse
{ "repo_name": "cschwer/com.zsmartsystems.zigbee", "path": "com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclGroupsCluster.java", "license": "epl-1.0", "size": 10171 }
[ "com.zsmartsystems.zigbee.CommandResult", "com.zsmartsystems.zigbee.zcl.clusters.groups.RemoveGroupResponse", "java.util.concurrent.Future" ]
import com.zsmartsystems.zigbee.CommandResult; import com.zsmartsystems.zigbee.zcl.clusters.groups.RemoveGroupResponse; import java.util.concurrent.Future;
import com.zsmartsystems.zigbee.*; import com.zsmartsystems.zigbee.zcl.clusters.groups.*; import java.util.concurrent.*;
[ "com.zsmartsystems.zigbee", "java.util" ]
com.zsmartsystems.zigbee; java.util;
333,968
FileResponse getFile(FileRequest request, DpsHeaders headers);
FileResponse getFile(FileRequest request, DpsHeaders headers);
/** * GetFile return URL for file downloading. * * @param request location request * @param headers request headers * @return a paginated file location result. * @throws ConstraintViolationException if request is invalid */
GetFile return URL for file downloading
getFile
{ "repo_name": "google/framework-for-osdu", "path": "osdu-r2/os-delivery/delivery-core/src/main/java/org/opengroup/osdu/delivery/provider/interfaces/FileService.java", "license": "apache-2.0", "size": 1242 }
[ "org.opengroup.osdu.core.common.model.file.FileRequest", "org.opengroup.osdu.core.common.model.file.FileResponse", "org.opengroup.osdu.core.common.model.http.DpsHeaders" ]
import org.opengroup.osdu.core.common.model.file.FileRequest; import org.opengroup.osdu.core.common.model.file.FileResponse; import org.opengroup.osdu.core.common.model.http.DpsHeaders;
import org.opengroup.osdu.core.common.model.file.*; import org.opengroup.osdu.core.common.model.http.*;
[ "org.opengroup.osdu" ]
org.opengroup.osdu;
19,610
public List<String> getSearchServices() throws NoResponseException, XMPPErrorException, NotConnectedException { ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(con); return discoManager.findServices(UserSearch.NAMESPACE, false, false); }
List<String> function() throws NoResponseException, XMPPErrorException, NotConnectedException { ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(con); return discoManager.findServices(UserSearch.NAMESPACE, false, false); }
/** * Returns a collection of search services found on the server. * * @return a Collection of search services found on the server. * @throws XMPPErrorException * @throws NoResponseException * @throws NotConnectedException */
Returns a collection of search services found on the server
getSearchServices
{ "repo_name": "Soo000/SooChat", "path": "src/org/jivesoftware/smackx/search/UserSearchManager.java", "license": "apache-2.0", "size": 3882 }
[ "java.util.List", "org.jivesoftware.smack.SmackException", "org.jivesoftware.smack.XMPPException", "org.jivesoftware.smackx.disco.ServiceDiscoveryManager" ]
import java.util.List; import org.jivesoftware.smack.SmackException; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
import java.util.*; import org.jivesoftware.smack.*; import org.jivesoftware.smackx.disco.*;
[ "java.util", "org.jivesoftware.smack", "org.jivesoftware.smackx" ]
java.util; org.jivesoftware.smack; org.jivesoftware.smackx;
2,377,618
void disable(ScheduledExecutorService scheduler);
void disable(ScheduledExecutorService scheduler);
/** * Will disable this service. Disabling of the service typically means * invoking it's operation that is annotated with @OnDisabled. * * @param scheduler * implementation of {@link ScheduledExecutorService} used to * initiate service disabling task */
Will disable this service. Disabling of the service typically means invoking it's operation that is annotated with @OnDisabled
disable
{ "repo_name": "WilliamNouet/nifi", "path": "nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core-api/src/main/java/org/apache/nifi/controller/service/ControllerServiceNode.java", "license": "apache-2.0", "size": 7705 }
[ "java.util.concurrent.ScheduledExecutorService" ]
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.*;
[ "java.util" ]
java.util;
2,094,158
@Override public Iterable<UserPoint> getUserPoints() { return storage.getUserPoints(); }
Iterable<UserPoint> function() { return storage.getUserPoints(); }
/** * Implementa IExperience.getUserPoints(). * * @return Insieme enumerabile di punti utente. */
Implementa IExperience.getUserPoints()
getUserPoints
{ "repo_name": "tobiatesan/serleena-android", "path": "serleena/app/src/main/java/com/kyloth/serleena/model/Experience.java", "license": "mit", "size": 4772 }
[ "com.kyloth.serleena.common.UserPoint" ]
import com.kyloth.serleena.common.UserPoint;
import com.kyloth.serleena.common.*;
[ "com.kyloth.serleena" ]
com.kyloth.serleena;
1,068,810
@Test public void testMergeWithNoSourceTable() { final MergeStatement statement = new MergeStatement() .from(new SelectStatement(new FieldLiteral("Z02").as("transactionCode"), new FieldLiteral("Modified example description").as("transactionDescription"))) .into(new TableReference("TransactionCod...
void function() { final MergeStatement statement = new MergeStatement() .from(new SelectStatement(new FieldLiteral("Z02").as(STR), new FieldLiteral(STR).as(STR))) .into(new TableReference(STR)); assertEquals(STR, String.format(STR + STR + STR), HumanReadableStatementHelper.generateDataUpgradeString(statement, null)); }
/** * Tests the generation of merge statement text when there is no source table. */
Tests the generation of merge statement text when there is no source table
testMergeWithNoSourceTable
{ "repo_name": "alfasoftware/morf", "path": "morf-core/src/test/java/org/alfasoftware/morf/upgrade/TestHumanReadableStatementHelper.java", "license": "apache-2.0", "size": 45364 }
[ "org.alfasoftware.morf.sql.MergeStatement", "org.alfasoftware.morf.sql.SelectStatement", "org.alfasoftware.morf.sql.element.FieldLiteral", "org.alfasoftware.morf.sql.element.TableReference", "org.junit.Assert" ]
import org.alfasoftware.morf.sql.MergeStatement; import org.alfasoftware.morf.sql.SelectStatement; import org.alfasoftware.morf.sql.element.FieldLiteral; import org.alfasoftware.morf.sql.element.TableReference; import org.junit.Assert;
import org.alfasoftware.morf.sql.*; import org.alfasoftware.morf.sql.element.*; import org.junit.*;
[ "org.alfasoftware.morf", "org.junit" ]
org.alfasoftware.morf; org.junit;
868,745
public static boolean containsPropertyExpression(Component component, String propertyName, boolean collectionMatch) { boolean hasExpression = false; Map<String, String> propertyExpressions = component.getPropertyExpressions(); if (collectionMatch) { for (Stri...
static boolean function(Component component, String propertyName, boolean collectionMatch) { boolean hasExpression = false; Map<String, String> propertyExpressions = component.getPropertyExpressions(); if (collectionMatch) { for (String expressionPropertyName : propertyExpressions.keySet()) { if (expressionPropertyName...
/** * Determines whether the given component contains an expression for the given property name * * @param component component instance to check for expressions * @param propertyName name of the property to determine if there is an expression for * @param collectionMatch if set to true wil...
Determines whether the given component contains an expression for the given property name
containsPropertyExpression
{ "repo_name": "ua-eas/ksd-kc5.2.1-rice2.3.6-ua", "path": "rice-framework/krad-web-framework/src/main/java/org/kuali/rice/krad/uif/util/ComponentUtils.java", "license": "apache-2.0", "size": 32922 }
[ "java.util.Map", "org.kuali.rice.krad.uif.component.Component" ]
import java.util.Map; import org.kuali.rice.krad.uif.component.Component;
import java.util.*; import org.kuali.rice.krad.uif.component.*;
[ "java.util", "org.kuali.rice" ]
java.util; org.kuali.rice;
1,747,003
public DalRequest createForUpload(String dalCommandUrl, List<Pair<String,String>> parameters, String rand_num, String namesInOrder, String signature, Factory<InputStream> factory);
DalRequest function(String dalCommandUrl, List<Pair<String,String>> parameters, String rand_num, String namesInOrder, String signature, Factory<InputStream> factory);
/** * Create a new DalRequest to upload data which is provided by the factory. * @param dalCommandUrl the full URL to the DAL server * @param parameters * @param rand_num * @param namesInOrder * @param signature * @param factory * @return an instance of DalRequest */
Create a new DalRequest to upload data which is provided by the factory
createForUpload
{ "repo_name": "kddart/libJava-DAL", "path": "src/main/com/diversityarrays/dalclient/http/DalHttpFactory.java", "license": "apache-2.0", "size": 3455 }
[ "com.diversityarrays.dalclient.util.Pair", "java.io.InputStream", "java.util.List", "org.apache.commons.collections15.Factory" ]
import com.diversityarrays.dalclient.util.Pair; import java.io.InputStream; import java.util.List; import org.apache.commons.collections15.Factory;
import com.diversityarrays.dalclient.util.*; import java.io.*; import java.util.*; import org.apache.commons.collections15.*;
[ "com.diversityarrays.dalclient", "java.io", "java.util", "org.apache.commons" ]
com.diversityarrays.dalclient; java.io; java.util; org.apache.commons;
802,935
public ServiceFuture<EventHubResourceInner> getAsync(String resourceGroupName, String namespaceName, String eventHubName, final ServiceCallback<EventHubResourceInner> serviceCallback) { return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, namespaceName, eventHubName), serviceCall...
ServiceFuture<EventHubResourceInner> function(String resourceGroupName, String namespaceName, String eventHubName, final ServiceCallback<EventHubResourceInner> serviceCallback) { return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, namespaceName, eventHubName), serviceCallback); }
/** * Gets an Event Hubs description for the specified Event Hub. * * @param resourceGroupName Name of the resource group within the azure subscription. * @param namespaceName The Namespace name * @param eventHubName The Event Hub name * @param serviceCallback the async ServiceCallback to ...
Gets an Event Hubs description for the specified Event Hub
getAsync
{ "repo_name": "martinsawicki/azure-sdk-for-java", "path": "azure-mgmt-eventhub/src/main/java/com/microsoft/azure/management/eventhub/implementation/EventHubsInner.java", "license": "mit", "size": 94388 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
452,864
public void testCloning() { StackedAreaRenderer r1 = new StackedAreaRenderer(); StackedAreaRenderer r2 = null; try { r2 = (StackedAreaRenderer) r1.clone(); } catch (CloneNotSupportedException e) { e.printStackTrace(); } assertTrue(r1 !=...
void function() { StackedAreaRenderer r1 = new StackedAreaRenderer(); StackedAreaRenderer r2 = null; try { r2 = (StackedAreaRenderer) r1.clone(); } catch (CloneNotSupportedException e) { e.printStackTrace(); } assertTrue(r1 != r2); assertTrue(r1.getClass() == r2.getClass()); assertTrue(r1.equals(r2)); }
/** * Confirm that cloning works. */
Confirm that cloning works
testCloning
{ "repo_name": "JSansalone/JFreeChart", "path": "tests/org/jfree/chart/renderer/category/junit/StackedAreaRendererTests.java", "license": "lgpl-2.1", "size": 5930 }
[ "org.jfree.chart.renderer.category.StackedAreaRenderer" ]
import org.jfree.chart.renderer.category.StackedAreaRenderer;
import org.jfree.chart.renderer.category.*;
[ "org.jfree.chart" ]
org.jfree.chart;
2,837,710
private static void throwExpectationNotMet(String expectationName, Properties expectations, String receivedValue, Exception e) throws UnmetExpectationException { throw new UnmetExpectationException("expecatation not met, name: '" + expectationName + "', expected value: '" + expectations.getPropert...
static void function(String expectationName, Properties expectations, String receivedValue, Exception e) throws UnmetExpectationException { throw new UnmetExpectationException(STR + expectationName + STR + expectations.getProperty(expectationName) + STR + receivedValue + "'", e); }
/** * Throws {@link UnmetExpectationException} with unmet expectation details. * @throws UnmetExpectationException */
Throws <code>UnmetExpectationException</code> with unmet expectation details
throwExpectationNotMet
{ "repo_name": "openaire/iis", "path": "iis-wf/iis-wf-metadataextraction/src/test/java/eu/dnetlib/iis/wf/metadataextraction/MetadataExtractorMain.java", "license": "apache-2.0", "size": 9365 }
[ "java.util.Properties" ]
import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
384,185
@Override public boolean updateOEMInfo(OEMDataVO dataVO,WhitelistService apiClientServices) throws WLMPortalException { log.info("OEMClientServiceImpl.updateOEMInfo >>"); boolean result = false; try { apiClientServices.updateOEM(new OemData(dataVO.getOemName(), dataVO.getOemDescription())); result = tru...
boolean function(OEMDataVO dataVO,WhitelistService apiClientServices) throws WLMPortalException { log.info(STR); boolean result = false; try { apiClientServices.updateOEM(new OemData(dataVO.getOemName(), dataVO.getOemDescription())); result = true; } catch (Exception e) { log.error(e.getMessage()); throw ConnectionUtil...
/** * Method to update OEM into a Rest Services * * @param dataVO * @param apiClientServices * @return Boolean variable e.g true if OEM is updated successfully * @throws WLMPortalException */
Method to update OEM into a Rest Services
updateOEMInfo
{ "repo_name": "xe1gyq/OpenAttestation", "path": "portals/WhiteListPortal/src/main/java/com/intel/mountwilson/Service/OEMClientServiceImpl.java", "license": "bsd-3-clause", "size": 5428 }
[ "com.intel.mountwilson.common.WLMPortalException", "com.intel.mountwilson.datamodel.OEMDataVO", "com.intel.mountwilson.util.ConnectionUtil", "com.intel.mtwilson.WhitelistService", "com.intel.mtwilson.datatypes.OemData" ]
import com.intel.mountwilson.common.WLMPortalException; import com.intel.mountwilson.datamodel.OEMDataVO; import com.intel.mountwilson.util.ConnectionUtil; import com.intel.mtwilson.WhitelistService; import com.intel.mtwilson.datatypes.OemData;
import com.intel.mountwilson.common.*; import com.intel.mountwilson.datamodel.*; import com.intel.mountwilson.util.*; import com.intel.mtwilson.*; import com.intel.mtwilson.datatypes.*;
[ "com.intel.mountwilson", "com.intel.mtwilson" ]
com.intel.mountwilson; com.intel.mtwilson;
799,427
private static void setDefaultRequireInstanceForInstanceIdentifier(YangType<?> type) { if (type.getDataType() == YangDataTypes.INSTANCE_IDENTIFIER) { ((YangType<Boolean>) type).setDataTypeExtendedInfo(true); } }
static void function(YangType<?> type) { if (type.getDataType() == YangDataTypes.INSTANCE_IDENTIFIER) { ((YangType<Boolean>) type).setDataTypeExtendedInfo(true); } }
/** * Sets the default require instance value as true when the type is instance identifier. * * @param type type to which the value has to be set */
Sets the default require instance value as true when the type is instance identifier
setDefaultRequireInstanceForInstanceIdentifier
{ "repo_name": "VinodKumarS-Huawei/ietf96yang", "path": "utils/yangutils/plugin/src/main/java/org/onosproject/yangutils/parser/impl/listeners/TypeListener.java", "license": "apache-2.0", "size": 15614 }
[ "org.onosproject.yangutils.datamodel.YangType", "org.onosproject.yangutils.datamodel.utils.builtindatatype.YangDataTypes" ]
import org.onosproject.yangutils.datamodel.YangType; import org.onosproject.yangutils.datamodel.utils.builtindatatype.YangDataTypes;
import org.onosproject.yangutils.datamodel.*; import org.onosproject.yangutils.datamodel.utils.builtindatatype.*;
[ "org.onosproject.yangutils" ]
org.onosproject.yangutils;
315,789
void saveOrUpdateAdContentAssets(List<Asset> entities);
void saveOrUpdateAdContentAssets(List<Asset> entities);
/** * TODO Comment... * @param entities */
TODO Comment..
saveOrUpdateAdContentAssets
{ "repo_name": "ajoshow/ex-data-capture", "path": "mock-common/src/main/java/com/ajoshow/mock/service/AdContentService.java", "license": "mit", "size": 805 }
[ "com.ajoshow.mock.repository.entity.Asset", "java.util.List" ]
import com.ajoshow.mock.repository.entity.Asset; import java.util.List;
import com.ajoshow.mock.repository.entity.*; import java.util.*;
[ "com.ajoshow.mock", "java.util" ]
com.ajoshow.mock; java.util;
1,325,029
@Override public void showOfflineModeDialog() { new MaterialDialog.Builder().init(getActivity()) .setTitle(R.string.offline_mode) .setMessage(R.string.dialog_message_offline_sync_alert) .setPositiveButton(R.string.dialog_action_go_online, this) ...
void function() { new MaterialDialog.Builder().init(getActivity()) .setTitle(R.string.offline_mode) .setMessage(R.string.dialog_message_offline_sync_alert) .setPositiveButton(R.string.dialog_action_go_online, this) .setNegativeButton(R.string.dialog_action_cancel, this) .createMaterialDialog() .show(); }
/** * This Method will called whenever user trying to sync the client payload in * offline mode. */
This Method will called whenever user trying to sync the client payload in offline mode
showOfflineModeDialog
{ "repo_name": "coderaashir/android-client", "path": "mifosng-android/src/main/java/com/mifos/mifosxdroid/offline/syncclientpayloads/SyncClientPayloadsFragment.java", "license": "mpl-2.0", "size": 11291 }
[ "com.mifos.mifosxdroid.core.MaterialDialog" ]
import com.mifos.mifosxdroid.core.MaterialDialog;
import com.mifos.mifosxdroid.core.*;
[ "com.mifos.mifosxdroid" ]
com.mifos.mifosxdroid;
1,772,679
int computeBlockReconstructionWork(int blocksToProcess) { List<List<BlockInfo>> blocksToReconstruct = null; namesystem.writeLock(); try { // Choose the blocks to be reconstructed blocksToReconstruct = neededReconstruction .chooseLowRedundancyBlocks(blocksToProcess); } finally { ...
int computeBlockReconstructionWork(int blocksToProcess) { List<List<BlockInfo>> blocksToReconstruct = null; namesystem.writeLock(); try { blocksToReconstruct = neededReconstruction .chooseLowRedundancyBlocks(blocksToProcess); } finally { namesystem.writeUnlock(); } return computeReconstructionWorkForBlocks(blocksToReco...
/** * Scan blocks in {@link #neededReconstruction} and assign reconstruction * (replication or erasure coding) work to data-nodes they belong to. * * The number of process blocks equals either twice the number of live * data-nodes or the number of low redundancy blocks whichever is less. * * @retur...
Scan blocks in <code>#neededReconstruction</code> and assign reconstruction (replication or erasure coding) work to data-nodes they belong to. The number of process blocks equals either twice the number of live data-nodes or the number of low redundancy blocks whichever is less
computeBlockReconstructionWork
{ "repo_name": "ronny-macmaster/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java", "license": "apache-2.0", "size": 186353 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,651,457
public int getMetaFromState(IBlockState state) { return ((EnumFacing)state.getValue(FACING)).getIndex(); }
int function(IBlockState state) { return ((EnumFacing)state.getValue(FACING)).getIndex(); }
/** * Convert the BlockState into the correct metadata value */
Convert the BlockState into the correct metadata value
getMetaFromState
{ "repo_name": "crafter6464/EnderCraft", "path": "src/main/java/com/crafter6464/endercraft/machines/ender_furnace/Ender_Furnace.java", "license": "gpl-3.0", "size": 7851 }
[ "net.minecraft.block.state.IBlockState", "net.minecraft.util.EnumFacing" ]
import net.minecraft.block.state.IBlockState; import net.minecraft.util.EnumFacing;
import net.minecraft.block.state.*; import net.minecraft.util.*;
[ "net.minecraft.block", "net.minecraft.util" ]
net.minecraft.block; net.minecraft.util;
1,134,682
public X509Certificate[] getX509Certificates(byte[] data, boolean reverse) throws WSSecurityException { InputStream in = new ByteArrayInputStream(data); CertPath path = null; try { CertificateFactory factory = CertificateFactory.getInstance("X.509"); path = fa...
X509Certificate[] function(byte[] data, boolean reverse) throws WSSecurityException { InputStream in = new ByteArrayInputStream(data); CertPath path = null; try { CertificateFactory factory = CertificateFactory.getInstance("X.509"); path = factory.generateCertPath(in); } catch (CertificateException e) { throw new WSSec...
/** * Construct an array of X509Certificate's from the byte array. * <p/> * * @param data The <code>byte</code> array containing the X509 data * @param reverse If set the first certificate in input data will * the last in the array * @return An array of X509 certific...
Construct an array of X509Certificate's from the byte array.
getX509Certificates
{ "repo_name": "madurangasiriwardena/wso2-wss4j", "path": "modules/wss4j/src/org/apache/ws/security/components/crypto/BouncyCastle.java", "license": "apache-2.0", "size": 7251 }
[ "java.io.ByteArrayInputStream", "java.io.InputStream", "java.security.cert.CertPath", "java.security.cert.CertificateException", "java.security.cert.CertificateFactory", "java.security.cert.X509Certificate", "java.util.Iterator", "java.util.List", "org.apache.ws.security.WSSecurityException" ]
import java.io.ByteArrayInputStream; import java.io.InputStream; import java.security.cert.CertPath; import java.security.cert.CertificateException; import java.security.cert.CertificateFactory; import java.security.cert.X509Certificate; import java.util.Iterator; import java.util.List; import org.apache.ws.security.WS...
import java.io.*; import java.security.cert.*; import java.util.*; import org.apache.ws.security.*;
[ "java.io", "java.security", "java.util", "org.apache.ws" ]
java.io; java.security; java.util; org.apache.ws;
2,799,541
List<Campaign> findActive();
List<Campaign> findActive();
/** * Looks for all currently active {@link Campaign}s. * * @return {@link List} of newly active {@link Campaign}s. */
Looks for all currently active <code>Campaign</code>s
findActive
{ "repo_name": "physalix-enrollment/physalix", "path": "Campaign/src/main/java/hsa/awp/campaign/dao/ICampaignDao.java", "license": "gpl-3.0", "size": 2041 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,436,836
public EnumAction getItemUseAction(ItemStack par1ItemStack) { return EnumAction.drink; }
EnumAction function(ItemStack par1ItemStack) { return EnumAction.drink; }
/** * returns the action that specifies what animation to play when the items is being used */
returns the action that specifies what animation to play when the items is being used
getItemUseAction
{ "repo_name": "DirectCodeGraveyard/Minetweak", "path": "src/main/java/net/minecraft/item/ItemBucketMilk.java", "license": "lgpl-3.0", "size": 1557 }
[ "net.minecraft.utils.enums.EnumAction" ]
import net.minecraft.utils.enums.EnumAction;
import net.minecraft.utils.enums.*;
[ "net.minecraft.utils" ]
net.minecraft.utils;
642,468
public Iterator getArrayDesigns() { return ! arrayDesigns.isEmpty() ? arrayDesigns.iterator() : null; } public int arrayDesignCount () { return arrayDesigns.size(); }
Iterator function() { return ! arrayDesigns.isEmpty() ? arrayDesigns.iterator() : null; } public int arrayDesignCount () { return arrayDesigns.size(); }
/** * Retrieves all arraydesigns associates to this array element * * @return ArrayDesigns as an <code>Iterator</code> of <code>TfcArrayDesign</code> * objects, or <code>null</code> if no arraydesigns associate to it */
Retrieves all arraydesigns associates to this array element
getArrayDesigns
{ "repo_name": "tair/tairwebapp", "path": "src/org/tair/querytools/ArrayElementDetail.java", "license": "gpl-3.0", "size": 20742 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
1,944,641
public List<String> requiredMembers() { return this.requiredMembers; }
List<String> function() { return this.requiredMembers; }
/** * Get the requiredMembers property: The private link resource required member names. * * @return the requiredMembers value. */
Get the requiredMembers property: The private link resource required member names
requiredMembers
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/postgresql/azure-resourcemanager-postgresql/src/main/java/com/azure/resourcemanager/postgresql/models/PrivateLinkResourceProperties.java", "license": "mit", "size": 1618 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,891,798
@Override public Task create(long taskId) { Task task = new TaskImpl(); task.setNew(true); task.setPrimaryKey(taskId); return task; }
Task function(long taskId) { Task task = new TaskImpl(); task.setNew(true); task.setPrimaryKey(taskId); return task; }
/** * Creates a new task with the primary key. Does not add the task to the database. * * @param taskId the primary key for the new task * @return the new task */
Creates a new task with the primary key. Does not add the task to the database
create
{ "repo_name": "rivetlogic/liferay-todos", "path": "modules/todos-service/todos-service-service/src/main/java/com/rivetlogic/todo/service/persistence/impl/TaskPersistenceImpl.java", "license": "gpl-3.0", "size": 38220 }
[ "com.rivetlogic.todo.model.Task", "com.rivetlogic.todo.model.impl.TaskImpl" ]
import com.rivetlogic.todo.model.Task; import com.rivetlogic.todo.model.impl.TaskImpl;
import com.rivetlogic.todo.model.*; import com.rivetlogic.todo.model.impl.*;
[ "com.rivetlogic.todo" ]
com.rivetlogic.todo;
461,179
public static void print(PrintStream ps) { ps.println(launcher_name + " version \"" + java_version + "\""); ps.println(java_runtime_name + " (build " + java_runtime_version + ")"); String java_vm_name = System.getProperty("java.vm.na...
static void function(PrintStream ps) { ps.println(launcher_name + STRSTR\STR (build STR)STRjava.vm.nameSTRjava.vm.versionSTRjava.vm.infoSTR (build STR, STR)"); }
/** * Give a stream, it will print version info on it. */
Give a stream, it will print version info on it
print
{ "repo_name": "Distrotech/icedtea7", "path": "generated/sun/misc/Version.java", "license": "gpl-2.0", "size": 11083 }
[ "java.io.PrintStream" ]
import java.io.PrintStream;
import java.io.*;
[ "java.io" ]
java.io;
1,469,233
public List<Argument> getArguments() { return m_arguments; }
List<Argument> function() { return m_arguments; }
/** * Gets the arguments. * * @return the arguments */
Gets the arguments
getArguments
{ "repo_name": "santiontanon/fterm", "path": "src/ftl/argumentation/core/ArgumentationTree.java", "license": "bsd-3-clause", "size": 16290 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,099,144
public static String[] getParameterArray(List<String> parameterList) { String[] stringArray = new String[((Vector<String>) parameterList) .size()]; for (int i = 0; i < stringArray.length; i++) { stringArray[i] = (String) parameterList.get(i); } return stringArray; }
static String[] function(List<String> parameterList) { String[] stringArray = new String[((Vector<String>) parameterList) .size()]; for (int i = 0; i < stringArray.length; i++) { stringArray[i] = (String) parameterList.get(i); } return stringArray; }
/** * Gets the parameter array. * * @param parameterList * the parameter list * @return the parameter array */
Gets the parameter array
getParameterArray
{ "repo_name": "chanakaudaya/developer-studio", "path": "app-server/org.wso2.developerstudio.eclipse.artifact.axis2/src/org/wso2/developerstudio/eclipse/artifact/axis2/utils/Axis2ParametersUtils.java", "license": "apache-2.0", "size": 8899 }
[ "java.util.List", "java.util.Vector" ]
import java.util.List; import java.util.Vector;
import java.util.*;
[ "java.util" ]
java.util;
199,043
public static String toString(InputStream in,String encoding) throws IOException { return toString(in, encoding==null?null:Charset.forName(encoding)); }
static String function(InputStream in,String encoding) throws IOException { return toString(in, encoding==null?null:Charset.forName(encoding)); }
/** Read input stream to string. */
Read input stream to string
toString
{ "repo_name": "sdw2330976/Research-jetty-9.2.5", "path": "jetty-util/src/main/java/org/eclipse/jetty/util/IO.java", "license": "apache-2.0", "size": 13976 }
[ "java.io.IOException", "java.io.InputStream", "java.nio.charset.Charset" ]
import java.io.IOException; import java.io.InputStream; import java.nio.charset.Charset;
import java.io.*; import java.nio.charset.*;
[ "java.io", "java.nio" ]
java.io; java.nio;
1,344,296
@Transactional(propagation = Propagation.SUPPORTS, readOnly = true) public com.iucn.whp.dbservice.model.inscription_criteria_lkp getinscription_criteria_lkp( int criteria_id) throws com.liferay.portal.kernel.exception.PortalException, com.liferay.portal.kernel.exception.SystemException;
@Transactional(propagation = Propagation.SUPPORTS, readOnly = true) com.iucn.whp.dbservice.model.inscription_criteria_lkp function( int criteria_id) throws com.liferay.portal.kernel.exception.PortalException, com.liferay.portal.kernel.exception.SystemException;
/** * Returns the inscription_criteria_lkp with the primary key. * * @param criteria_id the primary key of the inscription_criteria_lkp * @return the inscription_criteria_lkp * @throws PortalException if a inscription_criteria_lkp with the primary key could not be found * @throws SystemException if a system excep...
Returns the inscription_criteria_lkp with the primary key
getinscription_criteria_lkp
{ "repo_name": "iucn-whp/world-heritage-outlook", "path": "portlets/iucn-dbservice-portlet/docroot/WEB-INF/service/com/iucn/whp/dbservice/service/inscription_criteria_lkpLocalService.java", "license": "gpl-2.0", "size": 12239 }
[ "com.liferay.portal.kernel.exception.PortalException", "com.liferay.portal.kernel.exception.SystemException", "com.liferay.portal.kernel.transaction.Propagation", "com.liferay.portal.kernel.transaction.Transactional" ]
import com.liferay.portal.kernel.exception.PortalException; import com.liferay.portal.kernel.exception.SystemException; import com.liferay.portal.kernel.transaction.Propagation; import com.liferay.portal.kernel.transaction.Transactional;
import com.liferay.portal.kernel.exception.*; import com.liferay.portal.kernel.transaction.*;
[ "com.liferay.portal" ]
com.liferay.portal;
1,406,302
private static int byteCompaction(int mode, int[] codewords, Charset encoding, int codeIndex, StringBuilder result) { ByteArrayOutputStream decodedBytes = new ByteArrayOu...
static int function(int mode, int[] codewords, Charset encoding, int codeIndex, StringBuilder result) { ByteArrayOutputStream decodedBytes = new ByteArrayOutputStream(); int count = 0; long value = 0; boolean end = false; switch (mode) { case BYTE_COMPACTION_MODE_LATCH: int[] byteCompactedCodewords = new int[6]; int ne...
/** * Byte Compaction mode (see 5.4.3) permits all 256 possible 8-bit byte values to be encoded. * This includes all ASCII characters value 0 to 127 inclusive and provides for international * character set support. * * @param mode The byte compaction mode i.e. 901 or 924 * @param codewords The ar...
Byte Compaction mode (see 5.4.3) permits all 256 possible 8-bit byte values to be encoded. This includes all ASCII characters value 0 to 127 inclusive and provides for international character set support
byteCompaction
{ "repo_name": "china-zhuangxuxin/LKFramework", "path": "lichkin-framework-android/google-zxing-20170626/src/com/google/zxing/pdf417/decoder/DecodedBitStreamParser.java", "license": "mit", "size": 24532 }
[ "java.io.ByteArrayOutputStream", "java.nio.charset.Charset" ]
import java.io.ByteArrayOutputStream; import java.nio.charset.Charset;
import java.io.*; import java.nio.charset.*;
[ "java.io", "java.nio" ]
java.io; java.nio;
289,333
public final void setSqlMapClient(SqlMapClient sqlMapClient) { if (!this.externalTemplate) { this.sqlMapClientTemplate.setSqlMapClient(sqlMapClient); } }
final void function(SqlMapClient sqlMapClient) { if (!this.externalTemplate) { this.sqlMapClientTemplate.setSqlMapClient(sqlMapClient); } }
/** * Set the iBATIS Database Layer SqlMapClient to work with. * Either this or a "sqlMapClientTemplate" is required. * @see #setSqlMapClientTemplate */
Set the iBATIS Database Layer SqlMapClient to work with. Either this or a "sqlMapClientTemplate" is required
setSqlMapClient
{ "repo_name": "kingtang/spring-learn", "path": "spring-orm/src/main/java/org/springframework/orm/ibatis/support/SqlMapClientDaoSupport.java", "license": "gpl-3.0", "size": 3700 }
[ "com.ibatis.sqlmap.client.SqlMapClient" ]
import com.ibatis.sqlmap.client.SqlMapClient;
import com.ibatis.sqlmap.client.*;
[ "com.ibatis.sqlmap" ]
com.ibatis.sqlmap;
2,183,616
public XSAttributeDeclaration getAttributeDeclaration(String name, String namespace, String loc) { SchemaGrammar sg = (SchemaGrammar)fGrammarMap.get(null2EmptyString(namespace)); if (sg == null) { ...
XSAttributeDeclaration function(String name, String namespace, String loc) { SchemaGrammar sg = (SchemaGrammar)fGrammarMap.get(null2EmptyString(namespace)); if (sg == null) { return null; } return sg.getGlobalAttributeDecl(name, loc); }
/** * Convenience method. Returns a top-level attribute declaration. * @param name The name of the declaration. * @param namespace The namespace of the definition, otherwise null. * @param loc The schema location where the component was defined * @return A top-level attribute declaration or nul...
Convenience method. Returns a top-level attribute declaration
getAttributeDeclaration
{ "repo_name": "itgeeker/jdk", "path": "src/com/sun/org/apache/xerces/internal/impl/xs/XSModelImpl.java", "license": "apache-2.0", "size": 32014 }
[ "com.sun.org.apache.xerces.internal.xs.XSAttributeDeclaration" ]
import com.sun.org.apache.xerces.internal.xs.XSAttributeDeclaration;
import com.sun.org.apache.xerces.internal.xs.*;
[ "com.sun.org" ]
com.sun.org;
2,157,058
public static Task createAsync(Connection c, PIF taggedPIF, Long tag, Network network) throws BadServerResponse, XenAPIException, XmlRpcException { String method_call = "Async.VLAN.create"; String session = c.getSessionReference(); Object[] method_params = {Marshalling.t...
static Task function(Connection c, PIF taggedPIF, Long tag, Network network) throws BadServerResponse, XenAPIException, XmlRpcException { String method_call = STR; String session = c.getSessionReference(); Object[] method_params = {Marshalling.toXMLRPC(session), Marshalling.toXMLRPC(taggedPIF), Marshalling.toXMLRPC(tag...
/** * Create a VLAN mux/demuxer * * @param taggedPIF PIF which receives the tagged traffic * @param tag VLAN tag to use * @param network Network to receive the untagged traffic * @return Task */
Create a VLAN mux/demuxer
createAsync
{ "repo_name": "guzy/OnceCenter", "path": "src/com/once/xenapi/VLAN.java", "license": "apache-2.0", "size": 14859 }
[ "com.once.xenapi.Types", "java.util.Map", "org.apache.xmlrpc.XmlRpcException" ]
import com.once.xenapi.Types; import java.util.Map; import org.apache.xmlrpc.XmlRpcException;
import com.once.xenapi.*; import java.util.*; import org.apache.xmlrpc.*;
[ "com.once.xenapi", "java.util", "org.apache.xmlrpc" ]
com.once.xenapi; java.util; org.apache.xmlrpc;
1,392,875
public Future<SummaryCollection> processPartition(ExecutorService execSrv, int modulus, int remainder) { PartitionFuture future = new PartitionFuture(TraceUtil.traceInfo(), execSrv, modulus, remainder); future.initiateProcessing(); return future; }
Future<SummaryCollection> function(ExecutorService execSrv, int modulus, int remainder) { PartitionFuture future = new PartitionFuture(TraceUtil.traceInfo(), execSrv, modulus, remainder); future.initiateProcessing(); return future; }
/** * This methods reads a subset of file paths into memory and groups them by location. Then it * request summaries for files from each location/tablet server. */
This methods reads a subset of file paths into memory and groups them by location. Then it request summaries for files from each location/tablet server
processPartition
{ "repo_name": "keith-turner/accumulo", "path": "core/src/main/java/org/apache/accumulo/core/summary/Gatherer.java", "license": "apache-2.0", "size": 24764 }
[ "java.util.concurrent.ExecutorService", "java.util.concurrent.Future", "org.apache.accumulo.core.trace.TraceUtil" ]
import java.util.concurrent.ExecutorService; import java.util.concurrent.Future; import org.apache.accumulo.core.trace.TraceUtil;
import java.util.concurrent.*; import org.apache.accumulo.core.trace.*;
[ "java.util", "org.apache.accumulo" ]
java.util; org.apache.accumulo;
268,699
private void initGrid() { setSelectionMode(getDefaultSelectionMode()); registerRpc(new GridServerRpc() {
void function() { setSelectionMode(getDefaultSelectionMode()); registerRpc(new GridServerRpc() {
/** * Grid initial setup */
Grid initial setup
initGrid
{ "repo_name": "synes/vaadin", "path": "server/src/com/vaadin/ui/Grid.java", "license": "apache-2.0", "size": 239096 }
[ "com.vaadin.shared.ui.grid.GridServerRpc" ]
import com.vaadin.shared.ui.grid.GridServerRpc;
import com.vaadin.shared.ui.grid.*;
[ "com.vaadin.shared" ]
com.vaadin.shared;
1,974,311
public BotsMode getRobotsTxtMode() { return robotsTxtMode; }
BotsMode function() { return robotsTxtMode; }
/** * Gets robots.txt mode. * @return robots.txt mode */
Gets robots.txt mode
getRobotsTxtMode
{ "repo_name": "Esri/geoportal-server", "path": "geoportal/src/com/esri/gpt/control/webharvest/client/arcgis/ArcGISInfo.java", "license": "apache-2.0", "size": 2755 }
[ "com.esri.gpt.framework.robots.BotsMode" ]
import com.esri.gpt.framework.robots.BotsMode;
import com.esri.gpt.framework.robots.*;
[ "com.esri.gpt" ]
com.esri.gpt;
1,165,509
EList<DropPrimaryKeyType> getDropPrimaryKey();
EList<DropPrimaryKeyType> getDropPrimaryKey();
/** * Returns the value of the '<em><b>Drop Primary Key</b></em>' containment reference list. * The list contents are of type {@link org.liquibase.xml.ns.dbchangelog.DropPrimaryKeyType}. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the value of the '<em>Drop Primary Key</em>' containment r...
Returns the value of the 'Drop Primary Key' containment reference list. The list contents are of type <code>org.liquibase.xml.ns.dbchangelog.DropPrimaryKeyType</code>.
getDropPrimaryKey
{ "repo_name": "Treehopper/EclipseAugments", "path": "liquibase-editor/eu.hohenegger.xsd.liquibase/src-gen/org/liquibase/xml/ns/dbchangelog/RollbackType.java", "license": "epl-1.0", "size": 44628 }
[ "org.eclipse.emf.common.util.EList" ]
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.common.util.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
733,295
public void put(int key, int value) { int i = ContainerHelpers.binarySearch(mKeys, mSize, key); if (i >= 0) { mValues[i] = value; } else { i = ~i; if (mSize >= mKeys.length) { int n = ArrayUtils.idealIntArraySize(mSize + 1); ...
void function(int key, int value) { int i = ContainerHelpers.binarySearch(mKeys, mSize, key); if (i >= 0) { mValues[i] = value; } else { i = ~i; if (mSize >= mKeys.length) { int n = ArrayUtils.idealIntArraySize(mSize + 1); int[] nkeys = new int[n]; int[] nvalues = new int[n]; System.arraycopy(mKeys, 0, nkeys, 0, mKeys....
/** * Adds a mapping from the specified key to the specified value, * replacing the previous mapping from the specified key if there * was one. */
Adds a mapping from the specified key to the specified value, replacing the previous mapping from the specified key if there was one
put
{ "repo_name": "haithemaraissia/j2objc", "path": "jre_emul/android/frameworks/base/core/java/android/util/SparseIntArray.java", "license": "apache-2.0", "size": 9431 }
[ "com.android.internal.util.ArrayUtils" ]
import com.android.internal.util.ArrayUtils;
import com.android.internal.util.*;
[ "com.android.internal" ]
com.android.internal;
387,925
void setSk(SelectionKey to);
void setSk(SelectionKey to);
/** * Set the selection key for this node. */
Set the selection key for this node
setSk
{ "repo_name": "resrugam/java-memcached-client", "path": "src/main/java/net/spy/memcached/MemcachedNode.java", "license": "mit", "size": 5740 }
[ "java.nio.channels.SelectionKey" ]
import java.nio.channels.SelectionKey;
import java.nio.channels.*;
[ "java.nio" ]
java.nio;
662,225
public void remove(String id) throws Exception { // delete from db log.debug("Entering SavedQueryManagerImpl.remove"); super.remove(id, SavedQuery.class); }
void function(String id) throws Exception { log.debug(STR); super.remove(id, SavedQuery.class); }
/** * Remove a SavedQuery by id * * @param id * the unique id for the SavedQueryto delete * * @exception Exception * when anything goes wrong. */
Remove a SavedQuery by id
remove
{ "repo_name": "NCIP/camod", "path": "software/camod/src/gov/nih/nci/camod/service/impl/SavedQueryManagerImpl.java", "license": "bsd-3-clause", "size": 22685 }
[ "gov.nih.nci.camod.domain.SavedQuery" ]
import gov.nih.nci.camod.domain.SavedQuery;
import gov.nih.nci.camod.domain.*;
[ "gov.nih.nci" ]
gov.nih.nci;
1,584,055
RESULT_TYPE visitCouponInflationZeroCouponMonthlyGearing(CouponInflationZeroCouponMonthlyGearingDefinition coupon);
RESULT_TYPE visitCouponInflationZeroCouponMonthlyGearing(CouponInflationZeroCouponMonthlyGearingDefinition coupon);
/** * Monthly inflation zero coupon with gearing method. * @param coupon A monthly inflation zero coupon with gearing * @return The result */
Monthly inflation zero coupon with gearing method
visitCouponInflationZeroCouponMonthlyGearing
{ "repo_name": "jerome79/OG-Platform", "path": "projects/OG-Analytics/src/main/java/com/opengamma/analytics/financial/instrument/InstrumentDefinitionVisitor.java", "license": "apache-2.0", "size": 78879 }
[ "com.opengamma.analytics.financial.instrument.inflation.CouponInflationZeroCouponMonthlyGearingDefinition" ]
import com.opengamma.analytics.financial.instrument.inflation.CouponInflationZeroCouponMonthlyGearingDefinition;
import com.opengamma.analytics.financial.instrument.inflation.*;
[ "com.opengamma.analytics" ]
com.opengamma.analytics;
2,216,892
@Override public String toShortCommandLine(Object obj) { List<String> parts; String[] options; options = getOptions(obj); parts = new ArrayList<>(); parts.add(obj.getClass().getSimpleName()); parts.add(options[0]); return joinOptions(parts.toArray(new String[parts.size()])); }
String function(Object obj) { List<String> parts; String[] options; options = getOptions(obj); parts = new ArrayList<>(); parts.add(obj.getClass().getSimpleName()); parts.add(options[0]); return joinOptions(parts.toArray(new String[parts.size()])); }
/** * Generates a commandline from the specified object. Uses a shortened * format, e.g., removing the package from the class. * * @param obj the object to create the commandline for * @return the generated commandline */
Generates a commandline from the specified object. Uses a shortened format, e.g., removing the package from the class
toShortCommandLine
{ "repo_name": "waikato-datamining/adams-base", "path": "adams-core/src/main/java/adams/core/option/BaseObjectCommandLineHandler.java", "license": "gpl-3.0", "size": 5903 }
[ "java.util.ArrayList", "java.util.List" ]
import java.util.ArrayList; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,150,477
public Object setData(String key, Object value) { if (_valueMap == null) _valueMap = new HashMap<String, Object>(); return _valueMap.put(key, value); }
Object function(String key, Object value) { if (_valueMap == null) _valueMap = new HashMap<String, Object>(); return _valueMap.put(key, value); }
/** * Sets custom data associated with this aspect * @param key - the value name * @param value - the value * @return - previously associated value or null */
Sets custom data associated with this aspect
setData
{ "repo_name": "bdaum/zoraPD", "path": "com.bdaum.zoom.model/src/com/bdaum/aoModeling/runtime/Aspect.java", "license": "gpl-2.0", "size": 2673 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
2,475,337
Set<DataElement> getExpressionDataElements( String expression, ParseType parseType );
Set<DataElement> getExpressionDataElements( String expression, ParseType parseType );
/** * Returns all data elements found in the given expression string, including * those found in data element operands. Returns an empty set if the given * expression is null. * * @param expression the expression string. * @param parseType the type of expression to parse. * @return a ...
Returns all data elements found in the given expression string, including those found in data element operands. Returns an empty set if the given expression is null
getExpressionDataElements
{ "repo_name": "hispindia/dhis2-Core", "path": "dhis-2/dhis-api/src/main/java/org/hisp/dhis/expression/ExpressionService.java", "license": "bsd-3-clause", "size": 11199 }
[ "java.util.Set", "org.hisp.dhis.dataelement.DataElement" ]
import java.util.Set; import org.hisp.dhis.dataelement.DataElement;
import java.util.*; import org.hisp.dhis.dataelement.*;
[ "java.util", "org.hisp.dhis" ]
java.util; org.hisp.dhis;
1,285,641
@Override @Column(name = "ACTV_IND", nullable = false, length = 1) public boolean isActive() { return active; }
@Column(name = STR, nullable = false, length = 1) boolean function() { return active; }
/** * Gets the active attribute. * * @return Returns the active. */
Gets the active attribute
isActive
{ "repo_name": "bhutchinson/kfs", "path": "kfs-tem/src/main/java/org/kuali/kfs/module/tem/businessobject/BaseTemProfile.java", "license": "agpl-3.0", "size": 16950 }
[ "javax.persistence.Column" ]
import javax.persistence.Column;
import javax.persistence.*;
[ "javax.persistence" ]
javax.persistence;
2,408,423
public List<InterfaceHttpData> getBodyHttpDatas() throws NotEnoughDataDecoderException { return decoder.getBodyHttpDatas(); } /** * This method returns a List of all HttpDatas with the given name from body.<br> * * If chunked, all chunks must have been offered using offer...
List<InterfaceHttpData> function() throws NotEnoughDataDecoderException { return decoder.getBodyHttpDatas(); } /** * This method returns a List of all HttpDatas with the given name from body.<br> * * If chunked, all chunks must have been offered using offer() method. * If not, NotEnoughDataDecoderException will be rais...
/** * This method returns a List of all HttpDatas from body.<br> * * If chunked, all chunks must have been offered using offer() method. * If not, NotEnoughDataDecoderException will be raised. * * @return the list of HttpDatas from Body part for POST method * @throws NotEnoughDataDeco...
This method returns a List of all HttpDatas from body. If chunked, all chunks must have been offered using offer() method. If not, NotEnoughDataDecoderException will be raised
getBodyHttpDatas
{ "repo_name": "KeyNexus/netty", "path": "src/main/java/org/jboss/netty/handler/codec/http/multipart/HttpPostRequestDecoder.java", "license": "apache-2.0", "size": 14058 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,671,621
public void setProperties(Properties properties) { if (properties != null) { this.properties = properties; } }
void function(Properties properties) { if (properties != null) { this.properties = properties; } }
/** * Set the display properties. * * @param properties The new properties. */
Set the display properties
setProperties
{ "repo_name": "iritgo/iritgo-aktario", "path": "aktario-framework/src/main/java/de/iritgo/aktario/core/gui/IWindow.java", "license": "apache-2.0", "size": 10759 }
[ "java.util.Properties" ]
import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
237,265
StateR<S, B> apply(A a); /** * Compose this {@code StateRK} with another by applying this one first, * then the other. * @param kUV the {@code StateRK} to be applied after this one * @param <C> the second {@code StateRK}'s return type * @return the composed {@code ...
StateR<S, B> apply(A a); /** * Compose this {@code StateRK} with another by applying this one first, * then the other. * @param kUV the {@code StateRK} to be applied after this one * @param <C> the second {@code StateRK}'s return type * @return the composed {@code StateRK}
/** * Apply this {@code StateRK} operation * @param a the input value * @return the result of the operation */
Apply this StateRK operation
apply
{ "repo_name": "jon-hanson/funcj", "path": "core/src/main/java/org/typemeta/funcj/kleisli/StateRK.java", "license": "mit", "size": 2306 }
[ "org.typemeta.funcj.control.StateR" ]
import org.typemeta.funcj.control.StateR;
import org.typemeta.funcj.control.*;
[ "org.typemeta.funcj" ]
org.typemeta.funcj;
337,629
protected Schema fetchSchemaByKey(MD5Digest key) throws SchemaRegistryException { String schemaUrl = this.url + GET_RESOURCE_BY_ID + key.asString(); GetMethod get = new GetMethod(schemaUrl); int statusCode; String schemaString; HttpClient httpClient = this.borrowClient(); try { statusC...
Schema function(MD5Digest key) throws SchemaRegistryException { String schemaUrl = this.url + GET_RESOURCE_BY_ID + key.asString(); GetMethod get = new GetMethod(schemaUrl); int statusCode; String schemaString; HttpClient httpClient = this.borrowClient(); try { statusCode = httpClient.executeMethod(get); schemaString = ...
/** * Fetch schema by key. */
Fetch schema by key
fetchSchemaByKey
{ "repo_name": "yukuai518/gobblin", "path": "gobblin-modules/gobblin-kafka-common/src/main/java/gobblin/kafka/schemareg/LiKafkaSchemaRegistry.java", "license": "apache-2.0", "size": 8990 }
[ "java.io.IOException", "org.apache.avro.Schema", "org.apache.commons.httpclient.HttpClient", "org.apache.commons.httpclient.HttpStatus", "org.apache.commons.httpclient.methods.GetMethod" ]
import java.io.IOException; import org.apache.avro.Schema; import org.apache.commons.httpclient.HttpClient; import org.apache.commons.httpclient.HttpStatus; import org.apache.commons.httpclient.methods.GetMethod;
import java.io.*; import org.apache.avro.*; import org.apache.commons.httpclient.*; import org.apache.commons.httpclient.methods.*;
[ "java.io", "org.apache.avro", "org.apache.commons" ]
java.io; org.apache.avro; org.apache.commons;
1,699,487
@SuppressWarnings("unchecked") // (1) should only fail if input stream is incorrect private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); map = (Map<K, V>) in.readObject(); // (1) }
@SuppressWarnings(STR) void function(final ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); map = (Map<K, V>) in.readObject(); }
/** * Read the map in using a custom routine. * * @param in the input stream * @throws IOException * @throws ClassNotFoundException * @since 3.1 */
Read the map in using a custom routine
readObject
{ "repo_name": "gonmarques/commons-collections", "path": "src/main/java/org/apache/commons/collections4/map/FixedSizeMap.java", "license": "apache-2.0", "size": 5786 }
[ "java.io.IOException", "java.io.ObjectInputStream", "java.util.Map" ]
import java.io.IOException; import java.io.ObjectInputStream; import java.util.Map;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
2,610,642
protected void unlinkPages(final Page page) throws IOException { //Mmmmh... is this null test accurate ? -pb if (page != null) { // Walk the chain and add it to the unused list page.header.setStatus(UNUSED); page.header.lsn = Lsn.LSN_INVALID; synchroni...
void function(final Page page) throws IOException { if (page != null) { page.header.setStatus(UNUSED); page.header.lsn = Lsn.LSN_INVALID; synchronized (fileHeader) { if (fileHeader.firstFreePage == Page.NO_PAGE) { fileHeader.setFirstFreePage(page.pageNum); page.header.setNextPage(Page.NO_PAGE); } else { final long firs...
/** * Unlinks a set of pages starting at the specified page. * * @param page The starting Page to unlink * @throws IOException If an exception occurs */
Unlinks a set of pages starting at the specified page
unlinkPages
{ "repo_name": "ljo/exist", "path": "src/org/exist/storage/btree/Paged.java", "license": "lgpl-2.1", "size": 38514 }
[ "java.io.IOException", "org.exist.storage.journal.Lsn" ]
import java.io.IOException; import org.exist.storage.journal.Lsn;
import java.io.*; import org.exist.storage.journal.*;
[ "java.io", "org.exist.storage" ]
java.io; org.exist.storage;
1,877,260
protected void executeInternal() throws MojoExecutionException, MojoFailureException { List<L10nReportItem> reportItems = new ArrayList<L10nReportItem>(); int nbErrors = validate(propertyDir, reportItems); if (nbErrors > 0) { if (ignoreFailure) { getLog().error("Validation has faile...
void function() throws MojoExecutionException, MojoFailureException { List<L10nReportItem> reportItems = new ArrayList<L10nReportItem>(); int nbErrors = validate(propertyDir, reportItems); if (nbErrors > 0) { if (ignoreFailure) { getLog().error(STR + nbErrors + STR); getLog().info(STR); } else { throw new MojoFailureEx...
/** * Plugin entry point for unit testing to allow re-use of a single initialized Mojo instance, for perf reasons. * * @throws MojoExecutionException * in case of unexpected exception during plugin execution * @throws MojoFailureException * in case validation detected errors...
Plugin entry point for unit testing to allow re-use of a single initialized Mojo instance, for perf reasons
executeInternal
{ "repo_name": "bhagyas/l10n-maven-plugin", "path": "src/main/java/com/googlecode/l10nmavenplugin/ValidateMojo.java", "license": "mit", "size": 19833 }
[ "com.googlecode.l10nmavenplugin.model.L10nReportItem", "java.util.ArrayList", "java.util.List", "org.apache.maven.plugin.MojoExecutionException", "org.apache.maven.plugin.MojoFailureException" ]
import com.googlecode.l10nmavenplugin.model.L10nReportItem; import java.util.ArrayList; import java.util.List; import org.apache.maven.plugin.MojoExecutionException; import org.apache.maven.plugin.MojoFailureException;
import com.googlecode.l10nmavenplugin.model.*; import java.util.*; import org.apache.maven.plugin.*;
[ "com.googlecode.l10nmavenplugin", "java.util", "org.apache.maven" ]
com.googlecode.l10nmavenplugin; java.util; org.apache.maven;
2,327,065
public static long hashSubRowLong( final ReadableTable table, final int[] hashColumns, final int row, final int seedIndex) { return getHashCode(table, hashColumns, row, seedIndex).asLong(); }
static long function( final ReadableTable table, final int[] hashColumns, final int row, final int seedIndex) { return getHashCode(table, hashColumns, row, seedIndex).asLong(); }
/** * Compute the hash code of the specified columns in the specified row of the given table. * * @param table the table containing the values to be hashed * @param hashColumns the columns to be hashed. Order matters * @param row the row containing the values to be hashed * @param seedIndex the index ...
Compute the hash code of the specified columns in the specified row of the given table
hashSubRowLong
{ "repo_name": "uwescience/myria", "path": "src/edu/washington/escience/myria/util/HashUtils.java", "license": "bsd-3-clause", "size": 9575 }
[ "edu.washington.escience.myria.storage.ReadableTable" ]
import edu.washington.escience.myria.storage.ReadableTable;
import edu.washington.escience.myria.storage.*;
[ "edu.washington.escience" ]
edu.washington.escience;
2,632,067
public void testParameterLessEqual() throws ServletException, JspException { LessEqualTag ge = new LessEqualTag(); ge.setPageContext(pageContext); ge.setParameter(PARAMETER_KEY); ge.setValue(LESSER_VAL); assertTrue( "Parameter Value (" + GREATER_VAL + ") is less th...
void function() throws ServletException, JspException { LessEqualTag ge = new LessEqualTag(); ge.setPageContext(pageContext); ge.setParameter(PARAMETER_KEY); ge.setValue(LESSER_VAL); assertTrue( STR + GREATER_VAL + STR + LESSER_VAL + ")", ge.condition()); }
/** * Verify the value stored in parameter using <code>LessEqualTag</code>. */
Verify the value stored in parameter using <code>LessEqualTag</code>
testParameterLessEqual
{ "repo_name": "codelibs/cl-struts", "path": "src/test/org/apache/struts/taglib/logic/TestLessEqualTag.java", "license": "apache-2.0", "size": 8871 }
[ "javax.servlet.ServletException", "javax.servlet.jsp.JspException" ]
import javax.servlet.ServletException; import javax.servlet.jsp.JspException;
import javax.servlet.*; import javax.servlet.jsp.*;
[ "javax.servlet" ]
javax.servlet;
960,733
private boolean tryDisableEvents(IgniteEx ignite) { if (!listenVisor.values().contains(true)) { listenVisor.clear(); ignite.events().disableLocal(VISOR_TASK_EVTS); } // Return actual state. It could stay the same if events explicitly enabled in configuration. ...
boolean function(IgniteEx ignite) { if (!listenVisor.values().contains(true)) { listenVisor.clear(); ignite.events().disableLocal(VISOR_TASK_EVTS); } return ignite.allEventsUserRecordable(VISOR_TASK_EVTS); }
/** * Check if collect events may be disable. * * @param ignite Grid. * @return {@code true} if task events should remain enabled. */
Check if collect events may be disable
tryDisableEvents
{ "repo_name": "tkpanther/ignite", "path": "modules/core/src/main/java/org/apache/ignite/internal/visor/compute/VisorComputeMonitoringHolder.java", "license": "apache-2.0", "size": 4105 }
[ "org.apache.ignite.internal.IgniteEx" ]
import org.apache.ignite.internal.IgniteEx;
import org.apache.ignite.internal.*;
[ "org.apache.ignite" ]
org.apache.ignite;
616,999
public static ASTNode renderPart(final SimplePageStore store, final PageInfo page, final String content, final LinkPartsHandler linkHandler, final LinkPartsHandler imageHandler, final Supplier<List<Macro>> macros) { CreoleASTBuilder visitor = new Visitor(store, page, linkHandler, imageHandler); return renderP...
static ASTNode function(final SimplePageStore store, final PageInfo page, final String content, final LinkPartsHandler linkHandler, final LinkPartsHandler imageHandler, final Supplier<List<Macro>> macros) { CreoleASTBuilder visitor = new Visitor(store, page, linkHandler, imageHandler); return renderPartWithVisitor(cont...
/** * Render only a part of a page. * * @param store The page store (may be null). * @param page The containing page. * @param content The content to render. * @param linkHandler Handler for resolving and rendering links * @param imageHandler Handler for resolving and rendering images * @param m...
Render only a part of a page
renderPart
{ "repo_name": "CoreFiling/reviki", "path": "renderer-src/net/hillsdon/reviki/wiki/renderer/creole/CreoleRenderer.java", "license": "apache-2.0", "size": 7048 }
[ "com.google.common.base.Supplier", "java.util.List", "net.hillsdon.reviki.vc.PageInfo", "net.hillsdon.reviki.vc.SimplePageStore", "net.hillsdon.reviki.wiki.renderer.creole.ast.ASTNode", "net.hillsdon.reviki.wiki.renderer.macro.Macro" ]
import com.google.common.base.Supplier; import java.util.List; import net.hillsdon.reviki.vc.PageInfo; import net.hillsdon.reviki.vc.SimplePageStore; import net.hillsdon.reviki.wiki.renderer.creole.ast.ASTNode; import net.hillsdon.reviki.wiki.renderer.macro.Macro;
import com.google.common.base.*; import java.util.*; import net.hillsdon.reviki.vc.*; import net.hillsdon.reviki.wiki.renderer.creole.ast.*; import net.hillsdon.reviki.wiki.renderer.macro.*;
[ "com.google.common", "java.util", "net.hillsdon.reviki" ]
com.google.common; java.util; net.hillsdon.reviki;
834,816
public void draftOutPublication(PublicationPK pubPK, NodePK topicPK, String userProfile);
void function(PublicationPK pubPK, NodePK topicPK, String userProfile);
/** * Change publication status from draft to valid (for publisher) or toValidate (for redactor) * * @param pubPK the id of the publication */
Change publication status from draft to valid (for publisher) or toValidate (for redactor)
draftOutPublication
{ "repo_name": "CecileBONIN/Silverpeas-Components", "path": "kmelia/kmelia-ejb/src/main/java/com/stratelia/webactiv/kmelia/control/ejb/KmeliaBm.java", "license": "agpl-3.0", "size": 25457 }
[ "com.stratelia.webactiv.util.node.model.NodePK", "com.stratelia.webactiv.util.publication.model.PublicationPK" ]
import com.stratelia.webactiv.util.node.model.NodePK; import com.stratelia.webactiv.util.publication.model.PublicationPK;
import com.stratelia.webactiv.util.node.model.*; import com.stratelia.webactiv.util.publication.model.*;
[ "com.stratelia.webactiv" ]
com.stratelia.webactiv;
2,048,162
public static Object invokeJdbcMethod(Method method, Object target, Object[] args) throws SQLException { try { return method.invoke(target, args); } catch (IllegalAccessException ex) { handleReflectionException(ex); } catch (InvocationTargetException ex) { if (ex.getTargetException() instanceof SQ...
static Object function(Method method, Object target, Object[] args) throws SQLException { try { return method.invoke(target, args); } catch (IllegalAccessException ex) { handleReflectionException(ex); } catch (InvocationTargetException ex) { if (ex.getTargetException() instanceof SQLException) { throw (SQLException) ex...
/** * Invoke the specified JDBC API {@link Method} against the supplied * target object with the supplied arguments. * @param method the method to invoke * @param target the target object to invoke the method on * @param args the invocation arguments (may be <code>null</code>) * @return the invocation resul...
Invoke the specified JDBC API <code>Method</code> against the supplied target object with the supplied arguments
invokeJdbcMethod
{ "repo_name": "qiuhd2015/anima", "path": "src/main/java/org/hdl/anima/common/utils/ReflectionUtils.java", "license": "gpl-3.0", "size": 22247 }
[ "java.lang.reflect.InvocationTargetException", "java.lang.reflect.Method", "java.sql.SQLException" ]
import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.sql.SQLException;
import java.lang.reflect.*; import java.sql.*;
[ "java.lang", "java.sql" ]
java.lang; java.sql;
2,717,358
public boolean removePlot(Plot plot, boolean callEvent) { if (plot == null) { return false; } if (callEvent) { EventUtil.manager.callDelete(plot); } if (plot.getArea().removePlot(plot.getId())) { PlotId last = (PlotId) plot.getArea().getMet...
boolean function(Plot plot, boolean callEvent) { if (plot == null) { return false; } if (callEvent) { EventUtil.manager.callDelete(plot); } if (plot.getArea().removePlot(plot.getId())) { PlotId last = (PlotId) plot.getArea().getMeta(STR); int last_max = Math.max(Math.abs(last.x), Math.abs(last.y)); int this_max = Math....
/** * Unregister a plot from local memory (does not call DB) * @param plot * @param callEvent If to call an event about the plot being removed * @return true if plot existed | false if it didn't */
Unregister a plot from local memory (does not call DB)
removePlot
{ "repo_name": "SynergyMC/PlotSquared", "path": "Core/src/main/java/com/intellectualcrafters/plot/PS.java", "license": "gpl-3.0", "size": 93631 }
[ "com.intellectualcrafters.plot.object.Plot", "com.intellectualcrafters.plot.object.PlotId", "com.intellectualcrafters.plot.util.EventUtil" ]
import com.intellectualcrafters.plot.object.Plot; import com.intellectualcrafters.plot.object.PlotId; import com.intellectualcrafters.plot.util.EventUtil;
import com.intellectualcrafters.plot.object.*; import com.intellectualcrafters.plot.util.*;
[ "com.intellectualcrafters.plot" ]
com.intellectualcrafters.plot;
617,383
public void newWindowLauncher() { SecondaryColumnKeysDialog secondaryColumnDialog = new SecondaryColumnKeysDialog(shell, propertyDialogButtonBar, buttonWithLabelConfig); if (getProperties().get(propertyName) == null) { setProperties(propertyName, new LinkedHashMap<String, String>()); } secondaryColumn...
void function() { SecondaryColumnKeysDialog secondaryColumnDialog = new SecondaryColumnKeysDialog(shell, propertyDialogButtonBar, buttonWithLabelConfig); if (getProperties().get(propertyName) == null) { setProperties(propertyName, new LinkedHashMap<String, String>()); } secondaryColumnDialog.setSourceFieldsFromPropagat...
/** * New window launcher. */
New window launcher
newWindowLauncher
{ "repo_name": "capitalone/Hydrograph", "path": "hydrograph.ui/hydrograph.ui.propertywindow/src/main/java/hydrograph/ui/propertywindow/widgets/customwidgets/secondarykeys/SecondaryColumnKeysWidget.java", "license": "apache-2.0", "size": 9075 }
[ "java.util.LinkedHashMap" ]
import java.util.LinkedHashMap;
import java.util.*;
[ "java.util" ]
java.util;
2,603,342
public List<Long> getContentChildrenIds() { List<Long> childrenIds = null; if (content != null) { try { childrenIds = content.getChildrenIds(); } catch (TskCoreException ex) { logger.log(Level.SEVERE, "Error getting children ids, for content: ...
List<Long> function() { List<Long> childrenIds = null; if (content != null) { try { childrenIds = content.getChildrenIds(); } catch (TskCoreException ex) { logger.log(Level.SEVERE, STR + content, ex); } } return childrenIds; }
/** * Return ids of children of the underlying content. The ids can be treated * as keys - useful for lazy loading. * * @return list of content ids of children content. */
Return ids of children of the underlying content. The ids can be treated as keys - useful for lazy loading
getContentChildrenIds
{ "repo_name": "millmanorama/autopsy", "path": "Core/src/org/sleuthkit/autopsy/datamodel/AbstractContentNode.java", "license": "apache-2.0", "size": 7963 }
[ "java.util.List", "java.util.logging.Level", "org.sleuthkit.datamodel.TskCoreException" ]
import java.util.List; import java.util.logging.Level; import org.sleuthkit.datamodel.TskCoreException;
import java.util.*; import java.util.logging.*; import org.sleuthkit.datamodel.*;
[ "java.util", "org.sleuthkit.datamodel" ]
java.util; org.sleuthkit.datamodel;
2,771,567
@Override public ResourceAttributeContainer instantiate(QName elementName) { return instantiate(elementName, this); }
ResourceAttributeContainer function(QName elementName) { return instantiate(elementName, this); }
/** * This may not be really "clean" as it actually does two steps instead of one. But it is useful. */
This may not be really "clean" as it actually does two steps instead of one. But it is useful
instantiate
{ "repo_name": "PetrGasparik/midpoint", "path": "infra/schema/src/main/java/com/evolveum/midpoint/schema/processor/ObjectClassComplexTypeDefinitionImpl.java", "license": "apache-2.0", "size": 10331 }
[ "javax.xml.namespace.QName" ]
import javax.xml.namespace.QName;
import javax.xml.namespace.*;
[ "javax.xml" ]
javax.xml;
2,693,116
public applet addElement (String hashcode, Element element) { addElementToRegistry (hashcode, element); return (this); }
applet function (String hashcode, Element element) { addElementToRegistry (hashcode, element); return (this); }
/** * Adds an Element to the element. * * @param hashcode * name of element for hash table * @param element * Adds an Element to the element. */
Adds an Element to the element
addElement
{ "repo_name": "armenrz/adempiere", "path": "tools/src/org/apache/ecs/xhtml/applet.java", "license": "gpl-2.0", "size": 8588 }
[ "org.apache.ecs.Element" ]
import org.apache.ecs.Element;
import org.apache.ecs.*;
[ "org.apache.ecs" ]
org.apache.ecs;
1,870,862
void updateUser(SessionInfo sessionInfo, UserDTO userDataToUpdate, AsyncCallback<SesClientResponse> callback);
void updateUser(SessionInfo sessionInfo, UserDTO userDataToUpdate, AsyncCallback<SesClientResponse> callback);
/** * See {@link SesUserService#deleteUser(SessionInfo, String)} for documentation. * * @param callback * a callback handling the server response. * @see SesUserService#deleteUser(SessionInfo, String) */
See <code>SesUserService#deleteUser(SessionInfo, String)</code> for documentation
updateUser
{ "repo_name": "CarstenHollmann/SensorWebClient", "path": "sensorwebclient-ses-rpc/src/main/java/org/n52/shared/service/rpc/RpcSesUserServiceAsync.java", "license": "gpl-2.0", "size": 6978 }
[ "com.google.gwt.user.client.rpc.AsyncCallback", "org.n52.shared.responses.SesClientResponse", "org.n52.shared.serializable.pojos.UserDTO", "org.n52.shared.session.SessionInfo" ]
import com.google.gwt.user.client.rpc.AsyncCallback; import org.n52.shared.responses.SesClientResponse; import org.n52.shared.serializable.pojos.UserDTO; import org.n52.shared.session.SessionInfo;
import com.google.gwt.user.client.rpc.*; import org.n52.shared.responses.*; import org.n52.shared.serializable.pojos.*; import org.n52.shared.session.*;
[ "com.google.gwt", "org.n52.shared" ]
com.google.gwt; org.n52.shared;
1,890,931
public static <TSource> Enumerable<TSource> intersect( Enumerable<TSource> source0, Enumerable<TSource> source1, EqualityComparer<TSource> comparer) { return intersect(source0, source1, comparer, false); }
static <TSource> Enumerable<TSource> function( Enumerable<TSource> source0, Enumerable<TSource> source1, EqualityComparer<TSource> comparer) { return intersect(source0, source1, comparer, false); }
/** * Produces the set intersection of two sequences by * using the specified {@code EqualityComparer<TSource>} to compare * values, eliminate duplicates. */
Produces the set intersection of two sequences by using the specified EqualityComparer to compare values, eliminate duplicates
intersect
{ "repo_name": "googleinterns/calcite", "path": "linq4j/src/main/java/org/apache/calcite/linq4j/EnumerableDefaults.java", "license": "apache-2.0", "size": 146861 }
[ "org.apache.calcite.linq4j.function.EqualityComparer" ]
import org.apache.calcite.linq4j.function.EqualityComparer;
import org.apache.calcite.linq4j.function.*;
[ "org.apache.calcite" ]
org.apache.calcite;
444,525
protected static DesignElementHandle performInsertString( String expression, Object target ) throws SemanticException { // DataItemHandle dataHandle = SessionHandleAdapter.getInstance( ) // .getReportDesignHandle( ) // .getElementFactory( ) // .newDataItem( null ); DataItemHandle dataHandle = DesignEle...
static DesignElementHandle function( String expression, Object target ) throws SemanticException { DataItemHandle dataHandle = DesignElementFactory.getInstance( ) .newDataItem( null ); dataHandle.setResultSetColumn( expression ); InsertInLayoutRule rule = new LabelAddRule( target ); if ( rule.canInsert( ) ) { LabelHand...
/** * Inserts invalid column string into the target. Add label if possible * * @param expression * invalid column or other expression * @param target * insert target like cell or ListBandProxy * @return to be inserted data item * @throws SemanticException */
Inserts invalid column string into the target. Add label if possible
performInsertString
{ "repo_name": "sguan-actuate/birt", "path": "UI/org.eclipse.birt.report.designer.ui/src/org/eclipse/birt/report/designer/internal/ui/dnd/InsertInLayoutUtil.java", "license": "epl-1.0", "size": 77257 }
[ "org.eclipse.birt.report.designer.ui.newelement.DesignElementFactory", "org.eclipse.birt.report.model.api.DataItemHandle", "org.eclipse.birt.report.model.api.DesignElementHandle", "org.eclipse.birt.report.model.api.LabelHandle", "org.eclipse.birt.report.model.api.activity.SemanticException" ]
import org.eclipse.birt.report.designer.ui.newelement.DesignElementFactory; import org.eclipse.birt.report.model.api.DataItemHandle; import org.eclipse.birt.report.model.api.DesignElementHandle; import org.eclipse.birt.report.model.api.LabelHandle; import org.eclipse.birt.report.model.api.activity.SemanticException;
import org.eclipse.birt.report.designer.ui.newelement.*; import org.eclipse.birt.report.model.api.*; import org.eclipse.birt.report.model.api.activity.*;
[ "org.eclipse.birt" ]
org.eclipse.birt;
1,008,030
public List<IpcSchedule> getSchedules(String routeIdOrShortName) throws RemoteException;
List<IpcSchedule> function(String routeIdOrShortName) throws RemoteException;
/** * Returns list of IpcSchedule objects for the specified routeIdOrShortName * @param routeIdOrShortName * @return * @throws RemoteException */
Returns list of IpcSchedule objects for the specified routeIdOrShortName
getSchedules
{ "repo_name": "edsfocci/Transitime_core", "path": "transitime/src/main/java/org/transitime/ipc/interfaces/ConfigInterface.java", "license": "gpl-3.0", "size": 5990 }
[ "java.rmi.RemoteException", "java.util.List", "org.transitime.ipc.data.IpcSchedule" ]
import java.rmi.RemoteException; import java.util.List; import org.transitime.ipc.data.IpcSchedule;
import java.rmi.*; import java.util.*; import org.transitime.ipc.data.*;
[ "java.rmi", "java.util", "org.transitime.ipc" ]
java.rmi; java.util; org.transitime.ipc;
2,900,374
protected void dropEquipment(boolean wasRecentlyHit, int lootingModifier) { for (EntityEquipmentSlot entityequipmentslot : EntityEquipmentSlot.values()) { ItemStack itemstack = this.getItemStackFromSlot(entityequipmentslot); double d0; switch (entityequipment...
void function(boolean wasRecentlyHit, int lootingModifier) { for (EntityEquipmentSlot entityequipmentslot : EntityEquipmentSlot.values()) { ItemStack itemstack = this.getItemStackFromSlot(entityequipmentslot); double d0; switch (entityequipmentslot.getSlotType()) { case HAND: d0 = (double)this.inventoryHandsDropChances...
/** * Drop the equipment for this entity. */
Drop the equipment for this entity
dropEquipment
{ "repo_name": "TheGreatAndPowerfulWeegee/wipunknown", "path": "build/tmp/recompileMc/sources/net/minecraft/entity/EntityLiving.java", "license": "gpl-3.0", "size": 50426 }
[ "net.minecraft.enchantment.EnchantmentHelper", "net.minecraft.inventory.EntityEquipmentSlot", "net.minecraft.item.ItemStack" ]
import net.minecraft.enchantment.EnchantmentHelper; import net.minecraft.inventory.EntityEquipmentSlot; import net.minecraft.item.ItemStack;
import net.minecraft.enchantment.*; import net.minecraft.inventory.*; import net.minecraft.item.*;
[ "net.minecraft.enchantment", "net.minecraft.inventory", "net.minecraft.item" ]
net.minecraft.enchantment; net.minecraft.inventory; net.minecraft.item;
1,983,236
@LogMessage(level = ERROR) @Message(id = 7, value = "Failed to stop persistence unit service %s") void failedToStopPUService(@Cause Throwable cause, String name); // //@LogMessage(level = WARN) //@Message(id = 8, value = "Failed to get module attachment for %s") //void failedToGetModuleAtta...
@LogMessage(level = ERROR) @Message(id = 7, value = STR) void failedToStopPUService(@Cause Throwable cause, String name);
/** * Logs an error message indicating the persistence unit was not stopped * * @param cause the cause of the error. * @param name name of the persistence unit */
Logs an error message indicating the persistence unit was not stopped
failedToStopPUService
{ "repo_name": "jstourac/wildfly", "path": "jpa/subsystem/src/main/java/org/jboss/as/jpa/messages/JpaLogger.java", "license": "lgpl-2.1", "size": 35947 }
[ "org.jboss.logging.annotations.Cause", "org.jboss.logging.annotations.LogMessage", "org.jboss.logging.annotations.Message" ]
import org.jboss.logging.annotations.Cause; import org.jboss.logging.annotations.LogMessage; import org.jboss.logging.annotations.Message;
import org.jboss.logging.annotations.*;
[ "org.jboss.logging" ]
org.jboss.logging;
186,189
public static Blog setCurrentBlogToLastActive() { List<Map<String, Object>> accounts = WordPress.wpDB.getVisibleBlogs(); int lastBlogId = WordPress.wpDB.getLastBlogId(); if (lastBlogId != -1) { for (Map<String, Object> account : accounts) { int id = Integer.value...
static Blog function() { List<Map<String, Object>> accounts = WordPress.wpDB.getVisibleBlogs(); int lastBlogId = WordPress.wpDB.getLastBlogId(); if (lastBlogId != -1) { for (Map<String, Object> account : accounts) { int id = Integer.valueOf(account.get("id").toString()); if (id == lastBlogId) { setCurrentBlog(id); retu...
/** * Set the last active blog as the current blog. * * @return the current blog */
Set the last active blog as the current blog
setCurrentBlogToLastActive
{ "repo_name": "thirumalaivigneshmohan/MyApp_Android", "path": "WordPress/src/main/java/org/wordpress/android/WordPress.java", "license": "gpl-2.0", "size": 31227 }
[ "java.util.List", "java.util.Map", "org.wordpress.android.models.Blog" ]
import java.util.List; import java.util.Map; import org.wordpress.android.models.Blog;
import java.util.*; import org.wordpress.android.models.*;
[ "java.util", "org.wordpress.android" ]
java.util; org.wordpress.android;
1,824,749
public void setCompactionThreshold(String ks, String cf, int minimumCompactionThreshold, int maximumCompactionThreshold) { ColumnFamilyStoreMBean cfsProxy = getCfsProxy(ks, cf); cfsProxy.setCompactionThresholds(minimumCompactionThreshold, maximumCompactionThreshold); }
void function(String ks, String cf, int minimumCompactionThreshold, int maximumCompactionThreshold) { ColumnFamilyStoreMBean cfsProxy = getCfsProxy(ks, cf); cfsProxy.setCompactionThresholds(minimumCompactionThreshold, maximumCompactionThreshold); }
/** * Set the compaction threshold * * @param minimumCompactionThreshold minimum compaction threshold * @param maximumCompactionThreshold maximum compaction threshold */
Set the compaction threshold
setCompactionThreshold
{ "repo_name": "tommystendahl/cassandra", "path": "src/java/org/apache/cassandra/tools/NodeProbe.java", "license": "apache-2.0", "size": 63752 }
[ "org.apache.cassandra.db.ColumnFamilyStoreMBean" ]
import org.apache.cassandra.db.ColumnFamilyStoreMBean;
import org.apache.cassandra.db.*;
[ "org.apache.cassandra" ]
org.apache.cassandra;
390,939
@Override public void enterTypePrimitiveReal(@NotNull BigDataScriptParser.TypePrimitiveRealContext ctx) { }
@Override public void enterTypePrimitiveReal(@NotNull BigDataScriptParser.TypePrimitiveRealContext ctx) { }
/** * {@inheritDoc} * * <p>The default implementation does nothing.</p> */
The default implementation does nothing
exitExpressionParallel
{ "repo_name": "leepc12/BigDataScript", "path": "src/org/bds/antlr/BigDataScriptBaseListener.java", "license": "apache-2.0", "size": 36363 }
[ "org.antlr.v4.runtime.misc.NotNull" ]
import org.antlr.v4.runtime.misc.NotNull;
import org.antlr.v4.runtime.misc.*;
[ "org.antlr.v4" ]
org.antlr.v4;
449,858
static public TransformationService getTransformationService(BundleContext context, String transformationType) { if (context != null) { Logger logger = LoggerFactory.getLogger(TransformationHelper.class); String filter = "(smarthome.transform=" + transformationType + ")"; ...
static TransformationService function(BundleContext context, String transformationType) { if (context != null) { Logger logger = LoggerFactory.getLogger(TransformationHelper.class); String filter = STR + transformationType + ")"; try { Collection<ServiceReference<TransformationService>> refs = context.getServiceReferen...
/** * Queries the OSGi service registry for a service that provides a transformation service of * a given transformation type (e.g. REGEX, XSLT, etc.) * * @param transformationType the desired transformation type * @return a service instance or null, if none could be found */
Queries the OSGi service registry for a service that provides a transformation service of a given transformation type (e.g. REGEX, XSLT, etc.)
getTransformationService
{ "repo_name": "vilchev/eclipse-smarthome", "path": "bundles/core/org.eclipse.smarthome.core.transform/src/main/java/org/eclipse/smarthome/core/transform/TransformationHelper.java", "license": "epl-1.0", "size": 4385 }
[ "java.util.Collection", "org.osgi.framework.BundleContext", "org.osgi.framework.InvalidSyntaxException", "org.osgi.framework.ServiceReference", "org.slf4j.Logger", "org.slf4j.LoggerFactory" ]
import java.util.Collection; import org.osgi.framework.BundleContext; import org.osgi.framework.InvalidSyntaxException; import org.osgi.framework.ServiceReference; import org.slf4j.Logger; import org.slf4j.LoggerFactory;
import java.util.*; import org.osgi.framework.*; import org.slf4j.*;
[ "java.util", "org.osgi.framework", "org.slf4j" ]
java.util; org.osgi.framework; org.slf4j;
1,360,260
public List<ClientAuthenticationMethod> clientAuthenticationMethod() { return this.clientAuthenticationMethod; }
List<ClientAuthenticationMethod> function() { return this.clientAuthenticationMethod; }
/** * Get method of authentication supported by the token endpoint of this authorization server. Possible values are Basic and/or Body. When Body is specified, client credentials and other parameters are passed within the request body in the application/x-www-form-urlencoded format. * * @return the clien...
Get method of authentication supported by the token endpoint of this authorization server. Possible values are Basic and/or Body. When Body is specified, client credentials and other parameters are passed within the request body in the application/x-www-form-urlencoded format
clientAuthenticationMethod
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/apimanagement/mgmt-v2019_01_01/src/main/java/com/microsoft/azure/management/apimanagement/v2019_01_01/AuthorizationServerUpdateContract.java", "license": "mit", "size": 16780 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,038,703