method
stringlengths
13
441k
clean_method
stringlengths
7
313k
doc
stringlengths
17
17.3k
comment
stringlengths
3
1.42k
method_name
stringlengths
1
273
extra
dict
imports
list
imports_info
stringlengths
19
34.8k
cluster_imports_info
stringlengths
15
3.66k
libraries
list
libraries_info
stringlengths
6
661
id
int64
0
2.92M
@Override public void looseMarshal(OpenWireFormat wireFormat, Object o, DataOutput dataOut) throws IOException { MessageAck info = (MessageAck) o; super.looseMarshal(wireFormat, o, dataOut); looseMarshalCachedObject(wireFormat, info.getDestination(), dataOut); looseMarshalCached...
void function(OpenWireFormat wireFormat, Object o, DataOutput dataOut) throws IOException { MessageAck info = (MessageAck) o; super.looseMarshal(wireFormat, o, dataOut); looseMarshalCachedObject(wireFormat, info.getDestination(), dataOut); looseMarshalCachedObject(wireFormat, info.getTransactionId(), dataOut); looseMar...
/** * Write the booleans that this object uses to a BooleanStream */
Write the booleans that this object uses to a BooleanStream
looseMarshal
{ "repo_name": "tabish121/OpenWire", "path": "openwire-legacy/src/main/java/io/openwire/codec/v4/MessageAckMarshaller.java", "license": "apache-2.0", "size": 6372 }
[ "io.openwire.codec.OpenWireFormat", "io.openwire.commands.MessageAck", "java.io.DataOutput", "java.io.IOException" ]
import io.openwire.codec.OpenWireFormat; import io.openwire.commands.MessageAck; import java.io.DataOutput; import java.io.IOException;
import io.openwire.codec.*; import io.openwire.commands.*; import java.io.*;
[ "io.openwire.codec", "io.openwire.commands", "java.io" ]
io.openwire.codec; io.openwire.commands; java.io;
2,278,303
public void setChartEngine(JFreeChartPlotEngine engine) { if (engine == null) { throw new IllegalArgumentException("engine must not be null!"); } this.engine = engine; setPlotConfiguration(engine.getPlotInstance().getMasterPlotConfiguration()); }
void function(JFreeChartPlotEngine engine) { if (engine == null) { throw new IllegalArgumentException(STR); } this.engine = engine; setPlotConfiguration(engine.getPlotInstance().getMasterPlotConfiguration()); }
/** * Sets the current {@link JFreeChartPlotEngine} for this dialog. * * @param engine */
Sets the current <code>JFreeChartPlotEngine</code> for this dialog
setChartEngine
{ "repo_name": "boob-sbcm/3838438", "path": "src/main/java/com/rapidminer/gui/new_plotter/gui/dialog/ManageParallelLinesDialog.java", "license": "agpl-3.0", "size": 17022 }
[ "com.rapidminer.gui.new_plotter.engine.jfreechart.JFreeChartPlotEngine" ]
import com.rapidminer.gui.new_plotter.engine.jfreechart.JFreeChartPlotEngine;
import com.rapidminer.gui.new_plotter.engine.jfreechart.*;
[ "com.rapidminer.gui" ]
com.rapidminer.gui;
179,141
public Calendar getCalendar(String calName) throws SchedulerException { throw new SchedulerException("Operation not supported for remote schedulers."); }
Calendar function(String calName) throws SchedulerException { throw new SchedulerException(STR); }
/** * <p> * Calls th0e equivalent method on the 'proxied' <code>QuartzScheduler</code>, * passing the <code>SchedulingContext</code> associated with this * instance. * </p> */
Calls th0e equivalent method on the 'proxied' <code>QuartzScheduler</code>, passing the <code>SchedulingContext</code> associated with this instance.
getCalendar
{ "repo_name": "xqiang26/quartz-source-node", "path": "src/main/java/org/quartz/impl/RemoteMBeanScheduler.java", "license": "apache-2.0", "size": 31863 }
[ "org.quartz.Calendar", "org.quartz.SchedulerException" ]
import org.quartz.Calendar; import org.quartz.SchedulerException;
import org.quartz.*;
[ "org.quartz" ]
org.quartz;
2,290,763
void addRestDefinitions(Collection<RestDefinition> restDefinitions) throws Exception; /** * Sets a custom {@link org.apache.camel.spi.RestConfiguration}
void addRestDefinitions(Collection<RestDefinition> restDefinitions) throws Exception; /** * Sets a custom {@link org.apache.camel.spi.RestConfiguration}
/** * Adds a collection of rest definitions to the context * * @param restDefinitions the rest(s) definition to add */
Adds a collection of rest definitions to the context
addRestDefinitions
{ "repo_name": "tlehoux/camel", "path": "camel-core/src/main/java/org/apache/camel/CamelContext.java", "license": "apache-2.0", "size": 77596 }
[ "java.util.Collection", "org.apache.camel.model.rest.RestDefinition", "org.apache.camel.spi.RestConfiguration" ]
import java.util.Collection; import org.apache.camel.model.rest.RestDefinition; import org.apache.camel.spi.RestConfiguration;
import java.util.*; import org.apache.camel.model.rest.*; import org.apache.camel.spi.*;
[ "java.util", "org.apache.camel" ]
java.util; org.apache.camel;
1,646,495
public Iterator<Variable> getReferencedClassVariablesIterator() { return getReferencedClassVariables().values().iterator(); }
Iterator<Variable> function() { return getReferencedClassVariables().values().iterator(); }
/** * Gets an iterator for the referenced class variables. The * remove operation is not supported. * @return an iterator for the referenced class variables */
Gets an iterator for the referenced class variables. The remove operation is not supported
getReferencedClassVariablesIterator
{ "repo_name": "Selventa/model-builder", "path": "tools/groovy/src/src/main/org/codehaus/groovy/ast/VariableScope.java", "license": "apache-2.0", "size": 6080 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
1,324,413
public static void setLogLevel(String logLevel) { if ("VERBOSE".equals(logLevel)) LOGLEVEL = VERBOSE; else if ("DEBUG".equals(logLevel)) LOGLEVEL = DEBUG; else if ("INFO".equals(logLevel)) LOGLEVEL = INFO; else if ("WARN".equals(logLevel)) LOGLEVEL = WARN; else if ("ERROR".eq...
static void function(String logLevel) { if (STR.equals(logLevel)) LOGLEVEL = VERBOSE; else if ("DEBUG".equals(logLevel)) LOGLEVEL = DEBUG; else if ("INFO".equals(logLevel)) LOGLEVEL = INFO; else if ("WARN".equals(logLevel)) LOGLEVEL = WARN; else if ("ERROR".equals(logLevel)) LOGLEVEL = ERROR; Log.i(STR, STR + logLevel ...
/** * Set the current log level. * * @param logLevel */
Set the current log level
setLogLevel
{ "repo_name": "wufan123/cordova-plugin-push", "path": "src/android/LOG.java", "license": "apache-2.0", "size": 5891 }
[ "android.util.Log" ]
import android.util.Log;
import android.util.*;
[ "android.util" ]
android.util;
181,889
private static int calculateHeadersSize(HttpMethodBase httpMethod) { int headerSize = httpMethod.getStatusLine().toString().length()+2; // add a \r\n Header[] rh = httpMethod.getResponseHeaders(); for (int i = 0; i < rh.length; i++) { headerSize += rh[i].toString().length(); // a...
static int function(HttpMethodBase httpMethod) { int headerSize = httpMethod.getStatusLine().toString().length()+2; Header[] rh = httpMethod.getResponseHeaders(); for (int i = 0; i < rh.length; i++) { headerSize += rh[i].toString().length(); } headerSize += 2; return headerSize; }
/** * Calculate response headers size * * @return the size response headers (in bytes) */
Calculate response headers size
calculateHeadersSize
{ "repo_name": "ThiagoGarciaAlves/jmeter", "path": "src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java", "license": "apache-2.0", "size": 52270 }
[ "org.apache.commons.httpclient.Header", "org.apache.commons.httpclient.HttpMethodBase" ]
import org.apache.commons.httpclient.Header; import org.apache.commons.httpclient.HttpMethodBase;
import org.apache.commons.httpclient.*;
[ "org.apache.commons" ]
org.apache.commons;
2,642,099
public static ItemFolder[] mergeArray(ItemFolder[] i, ItemFolder[] o, ItemFolder[] d, ItemFolder[] s, ItemFolder[] t) { ItemFolder[] it...
static ItemFolder[] function(ItemFolder[] i, ItemFolder[] o, ItemFolder[] d, ItemFolder[] s, ItemFolder[] t) { ItemFolder[] itemFolder; int length = 0; int ilength = 0; int olength = 0; int dlength = 0; int slength = 0; int tlength = 0; if (i != null) { ilength = i.length; length = ilength; } if (o != null) { olength =...
/** * merge arrays * * @param i CrcSyncItemInfo[] * @param o CrcSyncItemInfo[] * @param d CrcSyncItemInfo[] * @param s CrcSyncItemInfo[] * @param t CrcSyncItemInfo[] * @return CrcSyncItemInfo[] */
merge arrays
mergeArray
{ "repo_name": "accesstest3/cfunambol", "path": "modules/email/email-core/src/main/java/com/funambol/email/util/Utility.java", "license": "agpl-3.0", "size": 53607 }
[ "com.funambol.email.model.ItemFolder" ]
import com.funambol.email.model.ItemFolder;
import com.funambol.email.model.*;
[ "com.funambol.email" ]
com.funambol.email;
1,496,447
static int hashCodeAsciiSafe(byte[] bytes, int startPos, int length) { int hash = HASH_CODE_ASCII_SEED; final int remainingBytes = length & 7; final int end = startPos + remainingBytes; for (int i = startPos - 8 + length; i >= end; i -= 8) { hash = PlatformDependent0.hash...
static int hashCodeAsciiSafe(byte[] bytes, int startPos, int length) { int hash = HASH_CODE_ASCII_SEED; final int remainingBytes = length & 7; final int end = startPos + remainingBytes; for (int i = startPos - 8 + length; i >= end; i -= 8) { hash = PlatformDependent0.hashCodeAsciiCompute(getLongSafe(bytes, i), hash); }...
/** * Package private for testing purposes only! */
Package private for testing purposes only
hashCodeAsciiSafe
{ "repo_name": "artgon/netty", "path": "common/src/main/java/io/netty/util/internal/PlatformDependent.java", "license": "apache-2.0", "size": 59109 }
[ "io.netty.util.internal.PlatformDependent0" ]
import io.netty.util.internal.PlatformDependent0;
import io.netty.util.internal.*;
[ "io.netty.util" ]
io.netty.util;
2,811,890
protected void iterateProxy( final IndentationCounter counter, final Element parent, final Collection list ) { final boolean shouldExist = ( list != null ) && ( list.size() > 0 ); final Element element = updateElement( counter, parent, "proxies", shouldExist ); if ( shouldExist ) ...
void function( final IndentationCounter counter, final Element parent, final Collection list ) { final boolean shouldExist = ( list != null ) && ( list.size() > 0 ); final Element element = updateElement( counter, parent, STR, shouldExist ); if ( shouldExist ) { final Iterator it = list.iterator(); Iterator elIt = elem...
/** * Method iterateProxy. * @param counter * @param parent * @param list */
Method iterateProxy
iterateProxy
{ "repo_name": "release-engineering/pom-manipulation-ext", "path": "common/src/main/java/org/commonjava/maven/ext/common/jdom/JDOMSettingsConverter.java", "license": "apache-2.0", "size": 27626 }
[ "java.util.Collection", "java.util.Iterator", "org.apache.maven.settings.Proxy", "org.commonjava.maven.ext.common.jdom.Utils", "org.jdom2.Element" ]
import java.util.Collection; import java.util.Iterator; import org.apache.maven.settings.Proxy; import org.commonjava.maven.ext.common.jdom.Utils; import org.jdom2.Element;
import java.util.*; import org.apache.maven.settings.*; import org.commonjava.maven.ext.common.jdom.*; import org.jdom2.*;
[ "java.util", "org.apache.maven", "org.commonjava.maven", "org.jdom2" ]
java.util; org.apache.maven; org.commonjava.maven; org.jdom2;
235,543
static ContentResponse executeHttpPost(HttpClient httpClient, String url, String resource, JsonElement parameters, @Nullable String sessionId) throws InterruptedException, TimeoutException, ExecutionException { Request response = httpClient.newRequest(String.format("%s/%s%s", url, WEB_API, resou...
static ContentResponse executeHttpPost(HttpClient httpClient, String url, String resource, JsonElement parameters, @Nullable String sessionId) throws InterruptedException, TimeoutException, ExecutionException { Request response = httpClient.newRequest(String.format(STR, url, WEB_API, resource), 80).scheme("http") .agen...
/** * Helper function to execute a HTTP post request * * @param httpClient httpClient to use for communication * @param url IP or hostname or the device * @param resource web API resource to post to * @param sessionId optional session ID * @param parameters the JSON content to post ...
Helper function to execute a HTTP post request
executeHttpPost
{ "repo_name": "openhab/openhab2", "path": "bundles/org.openhab.binding.kostalinverter/src/main/java/org/openhab/binding/internal/kostal/inverter/thirdgeneration/ThirdGenerationHttpHelper.java", "license": "epl-1.0", "size": 6865 }
[ "com.google.gson.JsonElement", "java.util.concurrent.ExecutionException", "java.util.concurrent.TimeUnit", "java.util.concurrent.TimeoutException", "org.eclipse.jdt.annotation.Nullable", "org.eclipse.jetty.client.HttpClient", "org.eclipse.jetty.client.api.ContentResponse", "org.eclipse.jetty.client.ap...
import com.google.gson.JsonElement; import java.util.concurrent.ExecutionException; import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; import org.eclipse.jdt.annotation.Nullable; import org.eclipse.jetty.client.HttpClient; import org.eclipse.jetty.client.api.ContentResponse; import org....
import com.google.gson.*; import java.util.concurrent.*; import org.eclipse.jdt.annotation.*; import org.eclipse.jetty.client.*; import org.eclipse.jetty.client.api.*; import org.eclipse.jetty.client.util.*; import org.eclipse.jetty.http.*;
[ "com.google.gson", "java.util", "org.eclipse.jdt", "org.eclipse.jetty" ]
com.google.gson; java.util; org.eclipse.jdt; org.eclipse.jetty;
10,871
public boolean handleServiceExtension(TWSDLParserContext context, TWSDLExtensible parent, Element e) { return false; }
boolean function(TWSDLParserContext context, TWSDLExtensible parent, Element e) { return false; }
/** * Callback for <code>wsdl:service</code> * * @param context Parser context that will be passed on by the wsdl parser * @param parent The Parent element within which the extensibility element is defined * @param e The extensibility elemenet * @return false if there was some error...
Callback for <code>wsdl:service</code>
handleServiceExtension
{ "repo_name": "axDev-JDK/jaxws", "path": "src/share/jaxws_classes/com/sun/tools/internal/ws/api/wsdl/TWSDLExtensionHandler.java", "license": "gpl-2.0", "size": 10984 }
[ "org.w3c.dom.Element" ]
import org.w3c.dom.Element;
import org.w3c.dom.*;
[ "org.w3c.dom" ]
org.w3c.dom;
1,563,294
public final Provider getProvider() { return provider; }
final Provider function() { return provider; }
/** * Returns the {@code Provider} of the certificate factory represented by * the certificate. * * @return the provider of this certificate factory. */
Returns the Provider of the certificate factory represented by the certificate
getProvider
{ "repo_name": "JSDemos/android-sdk-20", "path": "src/java/security/cert/CertificateFactory.java", "license": "apache-2.0", "size": 11321 }
[ "java.security.Provider" ]
import java.security.Provider;
import java.security.*;
[ "java.security" ]
java.security;
2,792,523
public DateTime creationTime() { return this.creationTime; }
DateTime function() { return this.creationTime; }
/** * Get the creationTime value. * * @return the creationTime value */
Get the creationTime value
creationTime
{ "repo_name": "hovsepm/azure-sdk-for-java", "path": "batchai/resource-manager/v2018_03_01/src/main/java/com/microsoft/azure/management/batchai/v2018_03_01/implementation/FileServerInner.java", "license": "mit", "size": 5881 }
[ "org.joda.time.DateTime" ]
import org.joda.time.DateTime;
import org.joda.time.*;
[ "org.joda.time" ]
org.joda.time;
876,099
@SuppressWarnings("unchecked") public static <T> ProxyAndInfo<T> createNonHAProxy( Configuration conf, InetSocketAddress nnAddr, Class<T> xface, UserGroupInformation ugi, boolean withRetries, AtomicBoolean fallbackToSimpleAuth) throws IOException { Text dtService = SecurityUtil.buildTokenServi...
@SuppressWarnings(STR) static <T> ProxyAndInfo<T> function( Configuration conf, InetSocketAddress nnAddr, Class<T> xface, UserGroupInformation ugi, boolean withRetries, AtomicBoolean fallbackToSimpleAuth) throws IOException { Text dtService = SecurityUtil.buildTokenService(nnAddr); T proxy; if (xface == ClientProtocol....
/** * Creates an explicitly non-HA-enabled proxy object. Most of the time you * don't want to use this, and should instead use {@link NameNodeProxies#createProxy}. * * @param conf the configuration object * @param nnAddr address of the remote NN to connect to * @param xface the IPC interface which sho...
Creates an explicitly non-HA-enabled proxy object. Most of the time you don't want to use this, and should instead use <code>NameNodeProxies#createProxy</code>
createNonHAProxy
{ "repo_name": "DislabNJU/Hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/NameNodeProxies.java", "license": "apache-2.0", "size": 25945 }
[ "java.io.IOException", "java.net.InetSocketAddress", "java.util.concurrent.atomic.AtomicBoolean", "org.apache.hadoop.conf.Configuration", "org.apache.hadoop.hdfs.protocol.ClientProtocol", "org.apache.hadoop.hdfs.server.protocol.JournalProtocol", "org.apache.hadoop.hdfs.server.protocol.NamenodeProtocol",...
import java.io.IOException; import java.net.InetSocketAddress; import java.util.concurrent.atomic.AtomicBoolean; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.hdfs.protocol.ClientProtocol; import org.apache.hadoop.hdfs.server.protocol.JournalProtocol; import org.apache.hadoop.hdfs.server.protoco...
import java.io.*; import java.net.*; import java.util.concurrent.atomic.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.hdfs.protocol.*; import org.apache.hadoop.hdfs.server.protocol.*; import org.apache.hadoop.io.*; import org.apache.hadoop.ipc.*; import org.apache.hadoop.security.*; import org.apache.had...
[ "java.io", "java.net", "java.util", "org.apache.hadoop" ]
java.io; java.net; java.util; org.apache.hadoop;
2,731,719
@Test public final void testRenderListHead() { ListHead head = new ListHead(); Object header; m_renderer.renderListHead(head); assertEquals(2, head.getChildren().size()); header = head.getChildren().get(1); assertTrue(header instanceof ListHeader); assertEquals("Age", ((ListHeader)header...
final void function() { ListHead head = new ListHead(); Object header; m_renderer.renderListHead(head); assertEquals(2, head.getChildren().size()); header = head.getChildren().get(1); assertTrue(header instanceof ListHeader); assertEquals("Age", ((ListHeader)header).getLabel()); }
/** * Test method for {@link org.adempiere.webui.component.WListItemRenderer#renderListHead(org.adempiere.webui.component.ListHead)}. */
Test method for <code>org.adempiere.webui.component.WListItemRenderer#renderListHead(org.adempiere.webui.component.ListHead)</code>
testRenderListHead
{ "repo_name": "erpcya/adempierePOS", "path": "zkwebui/WEB-INF/src/org/adempiere/webui/component/test/WListItemRendererTest.java", "license": "gpl-2.0", "size": 6510 }
[ "org.adempiere.webui.component.ListHead", "org.adempiere.webui.component.ListHeader", "org.junit.Assert" ]
import org.adempiere.webui.component.ListHead; import org.adempiere.webui.component.ListHeader; import org.junit.Assert;
import org.adempiere.webui.component.*; import org.junit.*;
[ "org.adempiere.webui", "org.junit" ]
org.adempiere.webui; org.junit;
242,846
public String[] queryNodeStatAssignUsers(UUID templateId, UUID statId){ Set<UUID> roleIdSet = new HashSet<UUID>(); Action[] actionArray = this.queryStatActions(statId); for(Action action : actionArray){ Role[] roleArray = this.queryActionRoles(action.getId()); for(Role role : roleArray){ role...
String[] function(UUID templateId, UUID statId){ Set<UUID> roleIdSet = new HashSet<UUID>(); Action[] actionArray = this.queryStatActions(statId); for(Action action : actionArray){ Role[] roleArray = this.queryActionRoles(action.getId()); for(Role role : roleArray){ roleIdSet.add(role.getId()); } } Set<String> userSet =...
/** * (non-Javadoc) * <p> Title:queryNodeStatAssignUsers</p> * <p> Description:TODO</p> * @param templateId * @param statId * @return * @see com.sogou.qadev.service.cynthia.bean.Flow#queryNodeStatAssignUsers(com.sogou.qadev.service.cynthia.bean.UUID, com.sogou.qadev.service.cynthia.bean.UUID) */
(non-Javadoc) Title:queryNodeStatAssignUsers Description:TODO
queryNodeStatAssignUsers
{ "repo_name": "yioye/Cynthia", "path": "src/main/java/com/sogou/qadev/service/cynthia/bean/impl/FlowImpl.java", "license": "gpl-2.0", "size": 46682 }
[ "com.sogou.qadev.service.cynthia.bean.Action", "com.sogou.qadev.service.cynthia.bean.Right", "com.sogou.qadev.service.cynthia.bean.Role", "java.util.Arrays", "java.util.HashSet", "java.util.Set" ]
import com.sogou.qadev.service.cynthia.bean.Action; import com.sogou.qadev.service.cynthia.bean.Right; import com.sogou.qadev.service.cynthia.bean.Role; import java.util.Arrays; import java.util.HashSet; import java.util.Set;
import com.sogou.qadev.service.cynthia.bean.*; import java.util.*;
[ "com.sogou.qadev", "java.util" ]
com.sogou.qadev; java.util;
142,545
@Override public Map<K, ICacheElement<K, V>> processGetMultiple( String cacheName, Set<K> keys, long requesterId ) throws IOException { CompositeCache<K, V> cache = getCacheManager().getCache( cacheName ); boolean keepLocal = !remoteHttpCacheServerAttributes.isAllowClusterGet(...
Map<K, ICacheElement<K, V>> function( String cacheName, Set<K> keys, long requesterId ) throws IOException { CompositeCache<K, V> cache = getCacheManager().getCache( cacheName ); boolean keepLocal = !remoteHttpCacheServerAttributes.isAllowClusterGet(); if ( keepLocal ) { return cache.localGetMultiple( keys ); } else { ...
/** * Processes a get request. * <p> * If isAllowClusterGet is enabled we will treat this as a normal request of non-remote * origination. * <p> * @param cacheName * @param keys * @param requesterId * @return Map * @throws IOException */
Processes a get request. If isAllowClusterGet is enabled we will treat this as a normal request of non-remote origination.
processGetMultiple
{ "repo_name": "tikue/jcs2-snapshot", "path": "src/java/org/apache/commons/jcs/auxiliary/remote/http/server/RemoteHttpCacheService.java", "license": "apache-2.0", "size": 8106 }
[ "java.io.IOException", "java.util.Map", "java.util.Set", "org.apache.commons.jcs.engine.behavior.ICacheElement", "org.apache.commons.jcs.engine.control.CompositeCache" ]
import java.io.IOException; import java.util.Map; import java.util.Set; import org.apache.commons.jcs.engine.behavior.ICacheElement; import org.apache.commons.jcs.engine.control.CompositeCache;
import java.io.*; import java.util.*; import org.apache.commons.jcs.engine.behavior.*; import org.apache.commons.jcs.engine.control.*;
[ "java.io", "java.util", "org.apache.commons" ]
java.io; java.util; org.apache.commons;
2,319,604
public void installUI(JComponent a) { for (int i = 0; i < uis.size(); i++) { ((ComponentUI) (uis.elementAt(i))).installUI(a); } }
void function(JComponent a) { for (int i = 0; i < uis.size(); i++) { ((ComponentUI) (uis.elementAt(i))).installUI(a); } }
/** * Invokes the <code>installUI</code> method on each UI handled by this object. */
Invokes the <code>installUI</code> method on each UI handled by this object
installUI
{ "repo_name": "rokn/Count_Words_2015", "path": "testing/openjdk2/jdk/src/share/classes/javax/swing/plaf/multi/MultiFileChooserUI.java", "license": "mit", "size": 10478 }
[ "javax.swing.JComponent", "javax.swing.plaf.ComponentUI" ]
import javax.swing.JComponent; import javax.swing.plaf.ComponentUI;
import javax.swing.*; import javax.swing.plaf.*;
[ "javax.swing" ]
javax.swing;
2,263,270
public void addBootstrapViews(List<Properties> bootstrapViews) { if (this.extensionBootstrapViews == null) { this.extensionBootstrapViews = new ArrayList<Properties>(); } this.extensionBootstrapViews.addAll(bootstrapViews); }
void function(List<Properties> bootstrapViews) { if (this.extensionBootstrapViews == null) { this.extensionBootstrapViews = new ArrayList<Properties>(); } this.extensionBootstrapViews.addAll(bootstrapViews); }
/** * Sets the bootstrap views * */
Sets the bootstrap views
addBootstrapViews
{ "repo_name": "Alfresco/alfresco-repository", "path": "src/main/java/org/alfresco/repo/importer/ImporterBootstrap.java", "license": "lgpl-3.0", "size": 24087 }
[ "java.util.ArrayList", "java.util.List", "java.util.Properties" ]
import java.util.ArrayList; import java.util.List; import java.util.Properties;
import java.util.*;
[ "java.util" ]
java.util;
1,816,677
public void addWaypoints(List<Coord2D> points){ final Altitude alt = mMission.getLastAltitude(); final List<MissionItem> missionItemsToAdd = new ArrayList<MissionItem>(points.size()); for(Coord2D point: points){ Waypoint waypoint = new Waypoint(mMission, new Coord3D(point, alt));...
void function(List<Coord2D> points){ final Altitude alt = mMission.getLastAltitude(); final List<MissionItem> missionItemsToAdd = new ArrayList<MissionItem>(points.size()); for(Coord2D point: points){ Waypoint waypoint = new Waypoint(mMission, new Coord3D(point, alt)); mMissionItems.add(new MissionItemRender(this, wayp...
/** * Add a set of waypoints generated around the passed 2D points. * TODO: replace Coord2D with library's classes such as android.graphics.Point * @param points list of points used to generate the mission waypoints */
Add a set of waypoints generated around the passed 2D points
addWaypoints
{ "repo_name": "0359xiaodong/droidplanner", "path": "Android/src/org/droidplanner/android/mission/MissionRender.java", "license": "gpl-3.0", "size": 11513 }
[ "java.util.ArrayList", "java.util.List", "org.droidplanner.android.mission.item.MissionItemRender", "org.droidplanner.core.helpers.coordinates.Coord2D", "org.droidplanner.core.helpers.coordinates.Coord3D", "org.droidplanner.core.helpers.units.Altitude", "org.droidplanner.core.mission.MissionItem", "or...
import java.util.ArrayList; import java.util.List; import org.droidplanner.android.mission.item.MissionItemRender; import org.droidplanner.core.helpers.coordinates.Coord2D; import org.droidplanner.core.helpers.coordinates.Coord3D; import org.droidplanner.core.helpers.units.Altitude; import org.droidplanner.core.mission...
import java.util.*; import org.droidplanner.android.mission.item.*; import org.droidplanner.core.helpers.coordinates.*; import org.droidplanner.core.helpers.units.*; import org.droidplanner.core.mission.*; import org.droidplanner.core.mission.waypoints.*;
[ "java.util", "org.droidplanner.android", "org.droidplanner.core" ]
java.util; org.droidplanner.android; org.droidplanner.core;
2,140,799
EAttribute getConstructor_Json();
EAttribute getConstructor_Json();
/** * Returns the meta object for the attribute '{@link net.blimster.gwt.threejs.wdl.threeJsWrapperDescriptionLanguage.Constructor#isJson <em>Json</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the attribute '<em>Json</em>'. * @see net.blimster.gwt.threejs.wdl.thr...
Returns the meta object for the attribute '<code>net.blimster.gwt.threejs.wdl.threeJsWrapperDescriptionLanguage.Constructor#isJson Json</code>'.
getConstructor_Json
{ "repo_name": "Blimster/three4g", "path": "net.blimster.gwt.threejs.wdl/src-gen/net/blimster/gwt/threejs/wdl/threeJsWrapperDescriptionLanguage/ThreeJsWrapperDescriptionLanguagePackage.java", "license": "lgpl-3.0", "size": 48992 }
[ "org.eclipse.emf.ecore.EAttribute" ]
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
2,479,088
public synchronized HorizontalHeaderTable getHorizontalHeader() throws IOException { HorizontalHeaderTable horizontalHeader = (HorizontalHeaderTable)tables.get( HorizontalHeaderTable.TAG ); if (horizontalHeader != null && !horizontalHeader.getInitialized()) { readTable(horizo...
synchronized HorizontalHeaderTable function() throws IOException { HorizontalHeaderTable horizontalHeader = (HorizontalHeaderTable)tables.get( HorizontalHeaderTable.TAG ); if (horizontalHeader != null && !horizontalHeader.getInitialized()) { readTable(horizontalHeader); } return horizontalHeader; }
/** * Get the hhea table for this TTF. * * @return The hhea table. */
Get the hhea table for this TTF
getHorizontalHeader
{ "repo_name": "BezrukovM/veraPDF-pdfbox", "path": "fontbox/src/main/java/org/apache/fontbox/ttf/TrueTypeFont.java", "license": "apache-2.0", "size": 18927 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,606,333
private String kekMaterialDescAsJson() { Map<String, String> kekMaterialDesc = getKEKMaterialsDescription(); if (kekMaterialDesc == null) kekMaterialDesc = Collections.emptyMap(); return Jackson.toJsonString(kekMaterialDesc); }
String function() { Map<String, String> kekMaterialDesc = getKEKMaterialsDescription(); if (kekMaterialDesc == null) kekMaterialDesc = Collections.emptyMap(); return Jackson.toJsonString(kekMaterialDesc); }
/** * Returns the key-encrypting-key material description as a non-null json * string; */
Returns the key-encrypting-key material description as a non-null json string
kekMaterialDescAsJson
{ "repo_name": "aws/aws-sdk-java", "path": "aws-java-sdk-s3/src/main/java/com/amazonaws/services/s3/internal/crypto/v1/ContentCryptoMaterial.java", "license": "apache-2.0", "size": 47199 }
[ "com.amazonaws.util.json.Jackson", "java.util.Collections", "java.util.Map" ]
import com.amazonaws.util.json.Jackson; import java.util.Collections; import java.util.Map;
import com.amazonaws.util.json.*; import java.util.*;
[ "com.amazonaws.util", "java.util" ]
com.amazonaws.util; java.util;
2,236,451
ItemStatisticBuilder item(ItemType item);
ItemStatisticBuilder item(ItemType item);
/** * Sets the {@link ItemType} of this {@link ItemStatistic}. * * @param item The item * @return This builder, for chaining */
Sets the <code>ItemType</code> of this <code>ItemStatistic</code>
item
{ "repo_name": "Kiskae/SpongeAPI", "path": "src/main/java/org/spongepowered/api/statistic/StatisticBuilder.java", "license": "mit", "size": 6349 }
[ "org.spongepowered.api.item.ItemType" ]
import org.spongepowered.api.item.ItemType;
import org.spongepowered.api.item.*;
[ "org.spongepowered.api" ]
org.spongepowered.api;
2,801,875
public Observable<ServiceResponse<Void>> cancelAtTenantScopeWithServiceResponseAsync(String deploymentName) { if (deploymentName == null) { throw new IllegalArgumentException("Parameter deploymentName is required and cannot be null."); } if (this.client.apiVersion() == null) { ...
Observable<ServiceResponse<Void>> function(String deploymentName) { if (deploymentName == null) { throw new IllegalArgumentException(STR); } if (this.client.apiVersion() == null) { throw new IllegalArgumentException(STR); }
/** * Cancels a currently running template deployment. * You can cancel a deployment only if the provisioningState is Accepted or Running. After the deployment is canceled, the provisioningState is set to Canceled. Canceling a template deployment stops the currently running template deployment and leaves the ...
Cancels a currently running template deployment. You can cancel a deployment only if the provisioningState is Accepted or Running. After the deployment is canceled, the provisioningState is set to Canceled. Canceling a template deployment stops the currently running template deployment and leaves the resources partiall...
cancelAtTenantScopeWithServiceResponseAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/resources/mgmt-v2020_06_01/src/main/java/com/microsoft/azure/management/resources/v2020_06_01/implementation/DeploymentsInner.java", "license": "mit", "size": 445517 }
[ "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.rest.ServiceResponse;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
1,455,941
public static void serialize(final Map propertyList, final List comments, final File file) throws IOException, SAXException, TransformerConfigurationException { SAXTransformerFactory sf = (SAXTransformerFactory) ...
static void function(final Map propertyList, final List comments, final File file) throws IOException, SAXException, TransformerConfigurationException { SAXTransformerFactory sf = (SAXTransformerFactory) SAXTransformerFactory.newInstance(); TransformerHandler handler = sf.newTransformerHandler(); FileOutputStream os = ...
/** * Serializes a property list into a Cocoa XML Property List document. * @param propertyList property list. * @param file destination. * @param comments comments to insert into document. * @throws SAXException if exception during serialization. * @throws TransformerConfigurationExceptio...
Serializes a property list into a Cocoa XML Property List document
serialize
{ "repo_name": "dscho/cpptasks", "path": "src/main/java/net/sf/antcontrib/cpptasks/apple/PropertyListSerialization.java", "license": "apache-2.0", "size": 8881 }
[ "java.io.File", "java.io.FileOutputStream", "java.io.IOException", "java.util.Iterator", "java.util.List", "java.util.Map", "javax.xml.transform.TransformerConfigurationException", "javax.xml.transform.sax.SAXTransformerFactory", "javax.xml.transform.sax.TransformerHandler", "javax.xml.transform.s...
import java.io.File; import java.io.FileOutputStream; import java.io.IOException; import java.util.Iterator; import java.util.List; import java.util.Map; import javax.xml.transform.TransformerConfigurationException; import javax.xml.transform.sax.SAXTransformerFactory; import javax.xml.transform.sax.TransformerHandler;...
import java.io.*; import java.util.*; import javax.xml.transform.*; import javax.xml.transform.sax.*; import javax.xml.transform.stream.*; import org.xml.sax.*; import org.xml.sax.helpers.*;
[ "java.io", "java.util", "javax.xml", "org.xml.sax" ]
java.io; java.util; javax.xml; org.xml.sax;
1,964,359
public void setReceiver(SocketAddress receiver) { this.receiver = receiver; }
void function(SocketAddress receiver) { this.receiver = receiver; }
/** * Sets the intended receiver address. This must be set when writing to the * channel. * * @param receiver * the receiver address. */
Sets the intended receiver address. This must be set when writing to the channel
setReceiver
{ "repo_name": "jasonwee/videoOnCloud", "path": "src/java/play/learn/java/design/reactor/NioDatagramChannel.java", "license": "apache-2.0", "size": 4415 }
[ "java.net.SocketAddress" ]
import java.net.SocketAddress;
import java.net.*;
[ "java.net" ]
java.net;
1,788,391
public NBTTagCompound getNBTCompound() { NBTTagCompound nbttagcompound = new NBTTagCompound(); nbttagcompound.setString("name", this.serverName); nbttagcompound.setString("ip", this.serverIP); if (this.serverIcon != null) { nbttagcompound.setString("icon", th...
NBTTagCompound function() { NBTTagCompound nbttagcompound = new NBTTagCompound(); nbttagcompound.setString("name", this.serverName); nbttagcompound.setString("ip", this.serverIP); if (this.serverIcon != null) { nbttagcompound.setString("icon", this.serverIcon); } if (this.resourceMode == ServerData.ServerResourceMode.E...
/** * Returns an NBTTagCompound with the server's name, IP and maybe acceptTextures. */
Returns an NBTTagCompound with the server's name, IP and maybe acceptTextures
getNBTCompound
{ "repo_name": "tomtomtom09/CampCraft", "path": "build/tmp/recompileMc/sources/net/minecraft/client/multiplayer/ServerData.java", "license": "gpl-3.0", "size": 4639 }
[ "net.minecraft.nbt.NBTTagCompound" ]
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.*;
[ "net.minecraft.nbt" ]
net.minecraft.nbt;
151,270
@Legacy(style = "sky-cellList-widget") String cellListWidget(); }
@Legacy(style = STR) String cellListWidget(); }
/** * Applied to the widget. */
Applied to the widget
cellListWidget
{ "repo_name": "SkyRocketGWT/skyrocketgwt", "path": "skyrocket-core/src/main/java/com/skyrocketgwt/core/client/cellview/appearance/DefaultSkyCellListAppearance.java", "license": "apache-2.0", "size": 6486 }
[ "com.skyrocketgwt.core.client.resource.Legacy" ]
import com.skyrocketgwt.core.client.resource.Legacy;
import com.skyrocketgwt.core.client.resource.*;
[ "com.skyrocketgwt.core" ]
com.skyrocketgwt.core;
1,397,768
public static void createSAML11TimedConditions(SAML11AssertionType assertion, long durationInMilis, long clockSkew) throws ConfigurationException, IssueInstantMissingException { XMLGregorianCalendar issueInstant = assertion.getIssueInstant(); if (issueInstant == null) throw n...
static void function(SAML11AssertionType assertion, long durationInMilis, long clockSkew) throws ConfigurationException, IssueInstantMissingException { XMLGregorianCalendar issueInstant = assertion.getIssueInstant(); if (issueInstant == null) throw new IssueInstantMissingException(ErrorCodes.NULL_ISSUE_INSTANT); XMLGre...
/** * Add validity conditions to the SAML2 Assertion * * @param assertion * @param durationInMilis * * @throws ConfigurationException * @throws IssueInstantMissingException */
Add validity conditions to the SAML2 Assertion
createSAML11TimedConditions
{ "repo_name": "chameleon82/keycloak", "path": "saml-core/src/main/java/org/keycloak/saml/processing/core/saml/v2/util/AssertionUtil.java", "license": "apache-2.0", "size": 22336 }
[ "java.security.PublicKey", "javax.xml.datatype.XMLGregorianCalendar", "org.keycloak.dom.saml.v1.assertion.SAML11AssertionType", "org.keycloak.dom.saml.v1.assertion.SAML11ConditionsType", "org.keycloak.saml.common.ErrorCodes", "org.keycloak.saml.common.exceptions.ConfigurationException", "org.keycloak.sa...
import java.security.PublicKey; import javax.xml.datatype.XMLGregorianCalendar; import org.keycloak.dom.saml.v1.assertion.SAML11AssertionType; import org.keycloak.dom.saml.v1.assertion.SAML11ConditionsType; import org.keycloak.saml.common.ErrorCodes; import org.keycloak.saml.common.exceptions.ConfigurationException; im...
import java.security.*; import javax.xml.datatype.*; import org.keycloak.dom.saml.v1.assertion.*; import org.keycloak.saml.common.*; import org.keycloak.saml.common.exceptions.*; import org.keycloak.saml.common.exceptions.fed.*;
[ "java.security", "javax.xml", "org.keycloak.dom", "org.keycloak.saml" ]
java.security; javax.xml; org.keycloak.dom; org.keycloak.saml;
1,842,666
public static int read(InputStream input, byte[] buffer) throws IOException { return read(input, buffer, 0, buffer.length); }
static int function(InputStream input, byte[] buffer) throws IOException { return read(input, buffer, 0, buffer.length); }
/** * Read bytes from an input stream. * This implementation guarantees that it will read as many bytes * as possible before giving up; this may not always be the case for * subclasses of {@link InputStream}. * * @param input where to read input from * @param buffer destination ...
Read bytes from an input stream. This implementation guarantees that it will read as many bytes as possible before giving up; this may not always be the case for subclasses of <code>InputStream</code>
read
{ "repo_name": "trivium-io/trivium-core", "path": "src/io/trivium/dep/org/apache/commons/io/IOUtils.java", "license": "apache-2.0", "size": 97969 }
[ "java.io.IOException", "java.io.InputStream" ]
import java.io.IOException; import java.io.InputStream;
import java.io.*;
[ "java.io" ]
java.io;
2,665,252
if (metadata == null) { final ReferenceResolver resolver = Context.resolver(context); if ((uuid == null || (metadata = resolver.resolve(context, type, uuid )) == null) && (xlink == null || (metadata = resolver.resolve(context, type, xlink)) == null)) { ...
if (metadata == null) { final ReferenceResolver resolver = Context.resolver(context); if ((uuid == null (metadata = resolver.resolve(context, type, uuid )) == null) && (xlink == null (metadata = resolver.resolve(context, type, xlink)) == null)) { int count = 0; SpecializedIdentifier<?>[] identifiers = new SpecializedId...
/** * If the given metadata object is null, tries to get an instance from the identifiers * declared in this {@code ObjectReference}. If the given metadata object is non-null, * assigns to that object the identifiers declared in this {@code ObjectReference}. * * <p>This method is invoked at unm...
If the given metadata object is null, tries to get an instance from the identifiers declared in this ObjectReference. If the given metadata object is non-null, assigns to that object the identifiers declared in this ObjectReference. This method is invoked at unmarshalling time by <code>PropertyType#resolve(Context)</co...
resolve
{ "repo_name": "apache/sis", "path": "core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/gco/ObjectReference.java", "license": "apache-2.0", "size": 7272 }
[ "org.apache.sis.internal.jaxb.Context", "org.apache.sis.internal.jaxb.SpecializedIdentifier", "org.apache.sis.util.ArraysExt", "org.apache.sis.xml.IdentifiedObject", "org.apache.sis.xml.IdentifierMap", "org.apache.sis.xml.IdentifierSpace", "org.apache.sis.xml.ReferenceResolver" ]
import org.apache.sis.internal.jaxb.Context; import org.apache.sis.internal.jaxb.SpecializedIdentifier; import org.apache.sis.util.ArraysExt; import org.apache.sis.xml.IdentifiedObject; import org.apache.sis.xml.IdentifierMap; import org.apache.sis.xml.IdentifierSpace; import org.apache.sis.xml.ReferenceResolver;
import org.apache.sis.internal.jaxb.*; import org.apache.sis.util.*; import org.apache.sis.xml.*;
[ "org.apache.sis" ]
org.apache.sis;
341,865
public void testLogInitTrimsToLength() { final int numExtraEntries = 205; // Manually write to the log file to create the situation where there are too many lines // in the file boolean successfullyWroteFile; try { // Manually open the file and append a bunch of ...
void function() { final int numExtraEntries = 205; boolean successfullyWroteFile; try { BufferedWriter bufferedWriter = new BufferedWriter(new OutputStreamWriter( mMockContext.openFileOutput(Log.FILENAME, Context.MODE_APPEND))); for (int i = 0; i < Log.CIRCULAR_BUFFER_SIZE + numExtraEntries; i++) { bufferedWriter.write...
/** * Scenario: * Given Log is uninitialized and I have an overfull log file * When I call init * Then the log file is trimmed */
Scenario: Given Log is uninitialized and I have an overfull log file When I call init Then the log file is trimmed
testLogInitTrimsToLength
{ "repo_name": "oanda/android-logging-library", "path": "lib/src/androidTest/java/com/oanda/logging/LogTests.java", "license": "apache-2.0", "size": 22243 }
[ "android.content.Context", "java.io.BufferedWriter", "java.io.IOException", "java.io.OutputStreamWriter" ]
import android.content.Context; import java.io.BufferedWriter; import java.io.IOException; import java.io.OutputStreamWriter;
import android.content.*; import java.io.*;
[ "android.content", "java.io" ]
android.content; java.io;
1,880,895
public Map<String, String> getPseudoOperationParameters() { return m_pseudoOpParams; }
Map<String, String> function() { return m_pseudoOpParams; }
/** * Returns a map of the pseudo-operation parameters; these are query or header parameters. * used to indicate pseudo-operations, such as ?wsdl * @return the pseudo-operation parameter map */
Returns a map of the pseudo-operation parameters; these are query or header parameters. used to indicate pseudo-operations, such as ?wsdl
getPseudoOperationParameters
{ "repo_name": "vthangathurai/SOA-Runtime", "path": "soa-server/src/main/java/org/ebayopensource/turmeric/runtime/spf/pipeline/RequestMetaContext.java", "license": "apache-2.0", "size": 4324 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
936,121
public void updateCommonJsp() { // List of pages to update List<String> pageList = new ArrayList<String>(); Collections.addAll(pageList, "dataAccessFailure", "resourceNotFound", "uncaughtException", "index", "login"); // 3rd party add-ons could customize default Roo...
void function() { List<String> pageList = new ArrayList<String>(); Collections.addAll(pageList, STR, STR, STR, "index", "login"); Map<String, String> rooUriMap = new HashMap<String, String>(); rooUriMap.put(XMLNS_FIELD, FORM_FIELDS_PATH); rooUriMap.put(XMLNS_FORM, STR); rooUriMap.put(XMLNS_TABLE, FORM_FIELDS_PATH); roo...
/** * Updates all JSP pages of target controller to use JQuery * * @param controller * @param controllerAnnotation */
Updates all JSP pages of target controller to use JQuery
updateCommonJsp
{ "repo_name": "gvSIGAssociation/gvnix", "path": "addon-web-mvc/addon/src/main/java/org/gvnix/addon/web/mvc/addon/jquery/JQueryOperationsImpl.java", "license": "gpl-3.0", "size": 34045 }
[ "java.util.ArrayList", "java.util.Collections", "java.util.HashMap", "java.util.List", "java.util.Map" ]
import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
388,301
@Override int receiveEnergy(EnumFacing facing, int maxReceive, boolean simulate);
int receiveEnergy(EnumFacing facing, int maxReceive, boolean simulate);
/** * Add energy to an IEnergyReceiver, internal distribution is left entirely to the IEnergyReceiver. * * @param from * Orientation the energy is received from. * @param maxReceive * Maximum amount of energy to receive. * @param simulate * If TRUE, the charge will only ...
Add energy to an IEnergyReceiver, internal distribution is left entirely to the IEnergyReceiver
receiveEnergy
{ "repo_name": "Lomeli12/PowerTools", "path": "src/main/java/cofh/api/energy/IEnergyHandler.java", "license": "lgpl-3.0", "size": 1800 }
[ "net.minecraft.util.EnumFacing" ]
import net.minecraft.util.EnumFacing;
import net.minecraft.util.*;
[ "net.minecraft.util" ]
net.minecraft.util;
1,343,092
public EMLComposer session(Session session) { this.session = session; return this; }
EMLComposer function(Session session) { this.session = session; return this; }
/** * Assigns custom session. Any property will be ignored. */
Assigns custom session. Any property will be ignored
session
{ "repo_name": "vilmospapp/jodd", "path": "jodd-mail/src/main/java/jodd/mail/EMLComposer.java", "license": "bsd-2-clause", "size": 4152 }
[ "javax.mail.Session" ]
import javax.mail.Session;
import javax.mail.*;
[ "javax.mail" ]
javax.mail;
911,680
public void exportService(JavaType className, String serviceName, String portTypeName, String targetNamespace, String addressName);
void function(JavaType className, String serviceName, String portTypeName, String targetNamespace, String addressName);
/** * <p> * Exports a class to Web Service. * </p> * <p> * If the class to export as web service doesn't exist it will be created * automatically in 'src/main/java' directory inside the package defined. * </p> * * @param className class to export. * @param serviceName ...
Exports a class to Web Service. If the class to export as web service doesn't exist it will be created automatically in 'src/main/java' directory inside the package defined.
exportService
{ "repo_name": "osroca/gvnix", "path": "addon-service/addon/src/main/java/org/gvnix/service/roo/addon/addon/ws/export/WSExportOperations.java", "license": "gpl-3.0", "size": 4450 }
[ "org.springframework.roo.model.JavaType" ]
import org.springframework.roo.model.JavaType;
import org.springframework.roo.model.*;
[ "org.springframework.roo" ]
org.springframework.roo;
1,189,843
@Override protected ConvertedDocument conversionImplementation(InputStream input, java.io.File doc) throws IOException { Metadata metadata = new Metadata(); BodyContentHandler handler = new BodyContentHandler(maxBuffer); try { parser.parse(input, handler, metadat...
ConvertedDocument function(InputStream input, java.io.File doc) throws IOException { Metadata metadata = new Metadata(); BodyContentHandler handler = new BodyContentHandler(maxBuffer); try { parser.parse(input, handler, metadata, ctx); } catch (Exception xerr) { throw new IOException(STR, xerr); } finally { input.close...
/** * Common implementation -- take an input stream and return a ConvertedDoc; * * @param input * @param doc * @return * @throws IOException * if underlying Tika parser/writer had an IO problem, an parser * problem, or MAX_TEXT_SIZE is reached. */
Common implementation -- take an input stream and return a ConvertedDoc
conversionImplementation
{ "repo_name": "voyagersearch/Xponents", "path": "XText/src/main/java/org/opensextant/xtext/converters/DefaultConverter.java", "license": "apache-2.0", "size": 4361 }
[ "java.io.IOException", "java.io.InputStream", "org.apache.tika.metadata.Metadata", "org.apache.tika.metadata.TikaCoreProperties", "org.apache.tika.sax.BodyContentHandler", "org.opensextant.util.FileUtility", "org.opensextant.util.TextUtils", "org.opensextant.xtext.ConvertedDocument" ]
import java.io.IOException; import java.io.InputStream; import org.apache.tika.metadata.Metadata; import org.apache.tika.metadata.TikaCoreProperties; import org.apache.tika.sax.BodyContentHandler; import org.opensextant.util.FileUtility; import org.opensextant.util.TextUtils; import org.opensextant.xtext.ConvertedDocum...
import java.io.*; import org.apache.tika.metadata.*; import org.apache.tika.sax.*; import org.opensextant.util.*; import org.opensextant.xtext.*;
[ "java.io", "org.apache.tika", "org.opensextant.util", "org.opensextant.xtext" ]
java.io; org.apache.tika; org.opensextant.util; org.opensextant.xtext;
466,378
protected Paint getPaint(PDColor color) throws IOException { PDColorSpace colorSpace = color.getColorSpace(); if (!(colorSpace instanceof PDPattern)) { float[] rgb = colorSpace.toRGB(color.getComponents()); return new Color(rgb[0], rgb[1], rgb[2]); ...
Paint function(PDColor color) throws IOException { PDColorSpace colorSpace = color.getColorSpace(); if (!(colorSpace instanceof PDPattern)) { float[] rgb = colorSpace.toRGB(color.getComponents()); return new Color(rgb[0], rgb[1], rgb[2]); } else { PDPattern patternSpace = (PDPattern)colorSpace; PDAbstractPattern patter...
/** * Returns an AWT paint for the given PDColor. */
Returns an AWT paint for the given PDColor
getPaint
{ "repo_name": "mdamt/pdfbox", "path": "pdfbox/src/main/java/org/apache/pdfbox/rendering/PageDrawer.java", "license": "apache-2.0", "size": 34519 }
[ "java.awt.Color", "java.awt.Paint", "java.io.IOException", "org.apache.pdfbox.pdmodel.graphics.color.PDColor", "org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace", "org.apache.pdfbox.pdmodel.graphics.color.PDPattern", "org.apache.pdfbox.pdmodel.graphics.pattern.PDAbstractPattern", "org.apache.pdfb...
import java.awt.Color; import java.awt.Paint; import java.io.IOException; import org.apache.pdfbox.pdmodel.graphics.color.PDColor; import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace; import org.apache.pdfbox.pdmodel.graphics.color.PDPattern; import org.apache.pdfbox.pdmodel.graphics.pattern.PDAbstractPattern;...
import java.awt.*; import java.io.*; import org.apache.pdfbox.pdmodel.graphics.color.*; import org.apache.pdfbox.pdmodel.graphics.pattern.*; import org.apache.pdfbox.pdmodel.graphics.shading.*; import org.apache.pdfbox.util.*;
[ "java.awt", "java.io", "org.apache.pdfbox" ]
java.awt; java.io; org.apache.pdfbox;
891,587
public void testCloning() { Vector v1 = new Vector(1.0, 2.0); assertFalse(v1 instanceof Cloneable); }
void function() { Vector v1 = new Vector(1.0, 2.0); assertFalse(v1 instanceof Cloneable); }
/** * Immutable class is not cloneable. */
Immutable class is not cloneable
testCloning
{ "repo_name": "linuxuser586/jfreechart", "path": "tests/org/jfree/data/xy/junit/VectorTests.java", "license": "lgpl-2.1", "size": 4128 }
[ "org.jfree.data.xy.Vector" ]
import org.jfree.data.xy.Vector;
import org.jfree.data.xy.*;
[ "org.jfree.data" ]
org.jfree.data;
1,537,275
public final Vec2 getLocalCenter() { return m_sweep.localCenter; }
final Vec2 function() { return m_sweep.localCenter; }
/** * Get the local position of the center of mass. Do not modify. */
Get the local position of the center of mass. Do not modify
getLocalCenter
{ "repo_name": "jbox2d/jbox2d", "path": "jbox2d-library/src/main/java/org/jbox2d/dynamics/Body.java", "license": "bsd-2-clause", "size": 33153 }
[ "org.jbox2d.common.Vec2" ]
import org.jbox2d.common.Vec2;
import org.jbox2d.common.*;
[ "org.jbox2d.common" ]
org.jbox2d.common;
1,730,333
public static MetaData addAliasToMetaData(MetaData metaData, String indexName) { AliasMetaData aliasMetaData = AliasMetaData.newAliasMetaDataBuilder(SECURITY_MAIN_ALIAS).build(); MetaData.Builder metaDataBuilder = new MetaData.Builder(metaData); IndexMetaData indexMetaData = metaData.index(i...
static MetaData function(MetaData metaData, String indexName) { AliasMetaData aliasMetaData = AliasMetaData.newAliasMetaDataBuilder(SECURITY_MAIN_ALIAS).build(); MetaData.Builder metaDataBuilder = new MetaData.Builder(metaData); IndexMetaData indexMetaData = metaData.index(indexName); metaDataBuilder.put(IndexMetaData....
/** * Adds the index alias {@code .security} to the underlying concrete index. */
Adds the index alias .security to the underlying concrete index
addAliasToMetaData
{ "repo_name": "coding0011/elasticsearch", "path": "x-pack/plugin/security/src/test/java/org/elasticsearch/xpack/security/test/SecurityTestUtils.java", "license": "apache-2.0", "size": 4448 }
[ "org.elasticsearch.cluster.metadata.AliasMetaData", "org.elasticsearch.cluster.metadata.IndexMetaData", "org.elasticsearch.cluster.metadata.MetaData" ]
import org.elasticsearch.cluster.metadata.AliasMetaData; import org.elasticsearch.cluster.metadata.IndexMetaData; import org.elasticsearch.cluster.metadata.MetaData;
import org.elasticsearch.cluster.metadata.*;
[ "org.elasticsearch.cluster" ]
org.elasticsearch.cluster;
1,520,072
@Test public void testNonEmptyOFAgentSet() throws IOException { expect(mockOFAgentService.agents()).andReturn(agents).anyTimes(); replay(mockOFAgentService); final WebTarget wt = target(); assertNotNull("WebTarget is null", wt); assertNotNull("WebTarget request is null",...
void function() throws IOException { expect(mockOFAgentService.agents()).andReturn(agents).anyTimes(); replay(mockOFAgentService); final WebTarget wt = target(); assertNotNull(STR, wt); assertNotNull(STR, wt.request()); final String response = wt.path(STR).request().get(String.class); final JsonObject result = Json.par...
/** * Tests the result of the rest api GET when there are OFAgents. * * @throws IOException IO exception */
Tests the result of the rest api GET when there are OFAgents
testNonEmptyOFAgentSet
{ "repo_name": "gkatsikas/onos", "path": "apps/ofagent/src/test/java/org/onosproject/ofagent/rest/OFAgentWebResourceTest.java", "license": "apache-2.0", "size": 20970 }
[ "com.eclipsesource.json.Json", "com.eclipsesource.json.JsonObject", "java.io.IOException", "javax.ws.rs.client.WebTarget", "org.easymock.EasyMock", "org.hamcrest.Matchers", "org.junit.Assert" ]
import com.eclipsesource.json.Json; import com.eclipsesource.json.JsonObject; import java.io.IOException; import javax.ws.rs.client.WebTarget; import org.easymock.EasyMock; import org.hamcrest.Matchers; import org.junit.Assert;
import com.eclipsesource.json.*; import java.io.*; import javax.ws.rs.client.*; import org.easymock.*; import org.hamcrest.*; import org.junit.*;
[ "com.eclipsesource.json", "java.io", "javax.ws", "org.easymock", "org.hamcrest", "org.junit" ]
com.eclipsesource.json; java.io; javax.ws; org.easymock; org.hamcrest; org.junit;
1,305,585
public GridCommunicationClient reserveClient(ClusterNode node, int connIdx) throws IgniteCheckedException { assert node != null; assert (connIdx >= 0 && connIdx < cfg.connectionsPerNode()) || !(cfg.usePairedConnections() && usePairedConnections(node, attrs.pairedConnection())) : connIdx; if...
GridCommunicationClient function(ClusterNode node, int connIdx) throws IgniteCheckedException { assert node != null; assert (connIdx >= 0 && connIdx < cfg.connectionsPerNode()) !(cfg.usePairedConnections() && usePairedConnections(node, attrs.pairedConnection())) : connIdx; if (locNodeSupplier.get().isClient()) { if (no...
/** * Returns existing or just created client to node. * * @param node Node to which client should be open. * @param connIdx Connection index. * @return The existing or just created client. * @throws IgniteCheckedException Thrown if any exception occurs. */
Returns existing or just created client to node
reserveClient
{ "repo_name": "samaitra/ignite", "path": "modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/internal/ConnectionClientPool.java", "license": "apache-2.0", "size": 31202 }
[ "java.util.concurrent.TimeUnit", "org.apache.ignite.IgniteCheckedException", "org.apache.ignite.cluster.ClusterNode", "org.apache.ignite.internal.IgniteFutureTimeoutCheckedException", "org.apache.ignite.internal.IgniteTooManyOpenFilesException", "org.apache.ignite.internal.cluster.ClusterTopologyCheckedEx...
import java.util.concurrent.TimeUnit; import org.apache.ignite.IgniteCheckedException; import org.apache.ignite.cluster.ClusterNode; import org.apache.ignite.internal.IgniteFutureTimeoutCheckedException; import org.apache.ignite.internal.IgniteTooManyOpenFilesException; import org.apache.ignite.internal.cluster.Cluster...
import java.util.concurrent.*; import org.apache.ignite.*; import org.apache.ignite.cluster.*; import org.apache.ignite.internal.*; import org.apache.ignite.internal.cluster.*; import org.apache.ignite.internal.util.future.*; import org.apache.ignite.internal.util.nio.*; import org.apache.ignite.internal.util.typedef.i...
[ "java.util", "org.apache.ignite" ]
java.util; org.apache.ignite;
2,837,581
void removeViewInstance(ViewInstanceEntity viewInstanceDefinition);
void removeViewInstance(ViewInstanceEntity viewInstanceDefinition);
/** * Remove the handler for the given view instance. * * @param viewInstanceDefinition the view instance */
Remove the handler for the given view instance
removeViewInstance
{ "repo_name": "radicalbit/ambari", "path": "ambari-server/src/main/java/org/apache/ambari/server/view/ViewInstanceHandlerList.java", "license": "apache-2.0", "size": 1548 }
[ "org.apache.ambari.server.orm.entities.ViewInstanceEntity" ]
import org.apache.ambari.server.orm.entities.ViewInstanceEntity;
import org.apache.ambari.server.orm.entities.*;
[ "org.apache.ambari" ]
org.apache.ambari;
1,908,621
private Type parseIterableAbbreviatedType() { lexer.eat(TypeLexer.OPEN_BR); Type iterated = parseUnionType(); Type result = null; if (lexer.lookingAt(TypeLexer.PLUS)) { lexer.eat(TypeLexer.PLUS); result = unit.getNonemptyIterableType(iterated); } else ...
Type function() { lexer.eat(TypeLexer.OPEN_BR); Type iterated = parseUnionType(); Type result = null; if (lexer.lookingAt(TypeLexer.PLUS)) { lexer.eat(TypeLexer.PLUS); result = unit.getNonemptyIterableType(iterated); } else if (lexer.lookingAt(TypeLexer.STAR)) { lexer.eat(TypeLexer.STAR); result = unit.getIterableType(...
/** * Spec says: * <blockquote><pre> * IterableType: "{" UnionType ("*"|"+") "}" * </blockquote></pre> */
Spec says: <code> IterableType: "{" UnionType ("*"|"+") "}" </code>
parseIterableAbbreviatedType
{ "repo_name": "ceylon/ceylon-model", "path": "src/com/redhat/ceylon/model/loader/TypeParser.java", "license": "apache-2.0", "size": 27925 }
[ "com.redhat.ceylon.model.typechecker.model.Type" ]
import com.redhat.ceylon.model.typechecker.model.Type;
import com.redhat.ceylon.model.typechecker.model.*;
[ "com.redhat.ceylon" ]
com.redhat.ceylon;
258,251
private static void attachModelToResource(RentalAgency model, Resource resource) { resource.getContents().add(model); }
static void function(RentalAgency model, Resource resource) { resource.getContents().add(model); }
/** * Store model element in the resource. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
Store model element in the resource.
attachModelToResource
{ "repo_name": "opcoach/training", "path": "Old/GMF/com.opcoach.training.rental.diagram/src/com/opcoach/training/rental/diagram/part/RentalDiagramEditorUtil.java", "license": "epl-1.0", "size": 13404 }
[ "com.opcoach.training.rental.RentalAgency", "org.eclipse.emf.ecore.resource.Resource" ]
import com.opcoach.training.rental.RentalAgency; import org.eclipse.emf.ecore.resource.Resource;
import com.opcoach.training.rental.*; import org.eclipse.emf.ecore.resource.*;
[ "com.opcoach.training", "org.eclipse.emf" ]
com.opcoach.training; org.eclipse.emf;
605,893
public void onClickListGreetings(View unused) {
void function(View unused) {
/** * This method is invoked when the "List Greetings" button is clicked. See activity_main.xml for * the dynamic reference to this method. */
This method is invoked when the "List Greetings" button is clicked. See activity_main.xml for the dynamic reference to this method
onClickListGreetings
{ "repo_name": "googlearchive/appengine-endpoints-helloendpoints-android", "path": "HelloEndpointsProject/HelloEndpoints/src/main/java/com/google/devrel/samples/helloendpoints/MainActivity.java", "license": "apache-2.0", "size": 20092 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
2,793,630
return createSingleTextPreference( name, "attribute.displayName." + name, TextDisplay.TEXT, null); }
return createSingleTextPreference( name, STR + name, TextDisplay.TEXT, null); }
/** * Define a single-valued text input preferences. This method is a convenient wrapper for the * most common expected use case and assumes null values for the default value and a predictable * label. * * @param name * @param label * @return */
Define a single-valued text input preferences. This method is a convenient wrapper for the most common expected use case and assumes null values for the default value and a predictable label
createSingleTextPreference
{ "repo_name": "jl1955/uPortal5", "path": "uPortal-portlets/src/main/java/org/apereo/portal/portlets/account/PreferenceInputFactory.java", "license": "apache-2.0", "size": 6030 }
[ "org.apereo.portal.portletpublishing.xml.TextDisplay" ]
import org.apereo.portal.portletpublishing.xml.TextDisplay;
import org.apereo.portal.portletpublishing.xml.*;
[ "org.apereo.portal" ]
org.apereo.portal;
339,178
@ServiceMethod(returns = ReturnType.SINGLE) private Mono<Response<PipelineJobOperationStatusInner>> getWithResponseAsync( String resourceGroupName, String accountName, String pipelineJobName, String operationId, Context context) { if (this.client.getEndpoint() == null) { return Mono ...
@ServiceMethod(returns = ReturnType.SINGLE) Mono<Response<PipelineJobOperationStatusInner>> function( String resourceGroupName, String accountName, String pipelineJobName, String operationId, Context context) { if (this.client.getEndpoint() == null) { return Mono .error( new IllegalArgumentException( STR)); } if (this....
/** * Get the operation status of a pipeline job with the given operationId. * * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName The Azure Video Analyzer account name. * @param pipelineJobName The pipeline job name. * @param opera...
Get the operation status of a pipeline job with the given operationId
getWithResponseAsync
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/videoanalyzer/azure-resourcemanager-videoanalyzer/src/main/java/com/azure/resourcemanager/videoanalyzer/implementation/PipelineJobOperationStatusesClientImpl.java", "license": "mit", "size": 12691 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.Response", "com.azure.core.util.Context", "com.azure.resourcemanager.videoanalyzer.fluent.models.PipelineJobOperationStatusInner" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.videoanalyzer.fluent.models.PipelineJobOperationStatusInner;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.videoanalyzer.fluent.models.*;
[ "com.azure.core", "com.azure.resourcemanager" ]
com.azure.core; com.azure.resourcemanager;
2,467,766
static public String printView(NetView v) { if (v == null) return "null"; StringBuffer sb = new StringBuffer(); Object leadObj = v.getLeadMember(); InternalDistributedMember lead = leadObj==null? null : new InternalDistributedMember(v.getLeadMember()); sb.app...
static String function(NetView v) { if (v == null) return "null"; StringBuffer sb = new StringBuffer(); Object leadObj = v.getLeadMember(); InternalDistributedMember lead = leadObj==null? null : new InternalDistributedMember(v.getLeadMember()); sb.append("["); Iterator it = v.iterator(); while (it.hasNext()) { Internal...
/** * Print a membership view (list of {@link InternalDistributedMember}s) * * @param v the list * @return String */
Print a membership view (list of <code>InternalDistributedMember</code>s)
printView
{ "repo_name": "fengshao0907/incubator-geode", "path": "gemfire-core/src/main/java/com/gemstone/gemfire/distributed/internal/DistributionManager.java", "license": "apache-2.0", "size": 176212 }
[ "com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember", "com.gemstone.gemfire.distributed.internal.membership.NetView", "java.util.Iterator" ]
import com.gemstone.gemfire.distributed.internal.membership.InternalDistributedMember; import com.gemstone.gemfire.distributed.internal.membership.NetView; import java.util.Iterator;
import com.gemstone.gemfire.distributed.internal.membership.*; import java.util.*;
[ "com.gemstone.gemfire", "java.util" ]
com.gemstone.gemfire; java.util;
2,507,988
public static boolean seekForV1OrV11Tag(ByteBuffer byteBuffer) { byte[] buffer = new byte[FIELD_TAGID_LENGTH]; // read the TAG value byteBuffer.get(buffer, 0, FIELD_TAGID_LENGTH); return (Arrays.equals(buffer, TAG_ID)); }
static boolean function(ByteBuffer byteBuffer) { byte[] buffer = new byte[FIELD_TAGID_LENGTH]; byteBuffer.get(buffer, 0, FIELD_TAGID_LENGTH); return (Arrays.equals(buffer, TAG_ID)); }
/** * Does a v1tag or a v11tag exist * * @return whether tag exists within the byteBuffer */
Does a v1tag or a v11tag exist
seekForV1OrV11Tag
{ "repo_name": "thawee/musixmate", "path": "library/jaudiotagger226/src/main/java/org/jaudiotagger/tag/id3/AbstractID3v1Tag.java", "license": "apache-2.0", "size": 5166 }
[ "java.nio.ByteBuffer", "java.util.Arrays" ]
import java.nio.ByteBuffer; import java.util.Arrays;
import java.nio.*; import java.util.*;
[ "java.nio", "java.util" ]
java.nio; java.util;
1,515,575
public static void writeData(Tag tag, SodfWrapper data, SodfCallback callback) throws CompressionAlgorithmNotFoundException{ if (data.compressionAlgorithm == null) SodfFramework.writeData(tag, data.data, data.app, callback, null); else SodfFramework.writeData(tag, data.data, data.app, callback, Compressor.alogri...
static void function(Tag tag, SodfWrapper data, SodfCallback callback) throws CompressionAlgorithmNotFoundException{ if (data.compressionAlgorithm == null) SodfFramework.writeData(tag, data.data, data.app, callback, null); else SodfFramework.writeData(tag, data.data, data.app, callback, Compressor.alogrithmSelector(dat...
/** * Write data on a NFC tag. * @param tag The tag where the data is written on * @param data The data set, which is written on the tag * @throws CompressionAlgorithmNotFoundException If the specified compression in the data was not found and is not null */
Write data on a NFC tag
writeData
{ "repo_name": "LAL-Apps/sodf", "path": "SmartFoodEnvironment/src/lal/sodf/framework/SodfFramework.java", "license": "mit", "size": 5553 }
[ "android.nfc.Tag" ]
import android.nfc.Tag;
import android.nfc.*;
[ "android.nfc" ]
android.nfc;
2,307,740
String submac = macAddress.substring(0, 8).toLowerCase(Locale.UK); try { ArrayList<Vendor> vendorList = Vendor.getByMac(submac); if (vendorList.size() > 0) { return Vendor.getByMac(submac).get(0); } } catch (EvercamException e) { if (Constants.ENABLE_LOGGING) { e.printStackTrace(); } ...
String submac = macAddress.substring(0, 8).toLowerCase(Locale.UK); try { ArrayList<Vendor> vendorList = Vendor.getByMac(submac); if (vendorList.size() > 0) { return Vendor.getByMac(submac).get(0); } } catch (EvercamException e) { if (Constants.ENABLE_LOGGING) { e.printStackTrace(); } return null; } return null; }
/** * Query Evercam API to get camera vendor by MAC address. * * @param macAddress * Full MAC address read from device. */
Query Evercam API to get camera vendor by MAC address
getCameraVendorByMac
{ "repo_name": "evercam/evercam-discovery-java", "path": "src/io/evercam/network/query/EvercamQuery.java", "license": "apache-2.0", "size": 6861 }
[ "io.evercam.EvercamException", "io.evercam.Vendor", "io.evercam.network.Constants", "java.util.ArrayList", "java.util.Locale" ]
import io.evercam.EvercamException; import io.evercam.Vendor; import io.evercam.network.Constants; import java.util.ArrayList; import java.util.Locale;
import io.evercam.*; import io.evercam.network.*; import java.util.*;
[ "io.evercam", "io.evercam.network", "java.util" ]
io.evercam; io.evercam.network; java.util;
168,534
public CloudObject asCloudObject(); /** * Returns true if the coding is deterministic. * * <p> In order for a {@code Coder} to be considered deterministic, * the following must be true: * <ul> * <li>two values that compare as equal (via {@code Object.equals()}
CloudObject function(); /** * Returns true if the coding is deterministic. * * <p> In order for a {@code Coder} to be considered deterministic, * the following must be true: * <ul> * <li>two values that compare as equal (via {@code Object.equals()}
/** * Returns the {@link CloudObject} that represents this {@code Coder}. */
Returns the <code>CloudObject</code> that represents this Coder
asCloudObject
{ "repo_name": "haocafes/DataflowJavaSDK", "path": "sdk/src/main/java/com/google/cloud/dataflow/sdk/coders/Coder.java", "license": "apache-2.0", "size": 9037 }
[ "com.google.cloud.dataflow.sdk.util.CloudObject" ]
import com.google.cloud.dataflow.sdk.util.CloudObject;
import com.google.cloud.dataflow.sdk.util.*;
[ "com.google.cloud" ]
com.google.cloud;
2,396,903
static double[] calculatePrecessionCorrection(double rightAscensionRad, double declinationRad, ZonedDateTime observationTime) { double deltaT = observationTime.until(j2000Reference, ChronoUnit.SECONDS) / 365.0 / 86400.0; double deltaRightAscension = (precessionFactorM + precessionFactorN * Math.sin(...
static double[] calculatePrecessionCorrection(double rightAscensionRad, double declinationRad, ZonedDateTime observationTime) { double deltaT = observationTime.until(j2000Reference, ChronoUnit.SECONDS) / 365.0 / 86400.0; double deltaRightAscension = (precessionFactorM + precessionFactorN * Math.sin(rightAscensionRad) *...
/** * Calculate the corrections for right ascension in declination * that are needed because of Earth's precession. * <p> * The formulas are approximations found here * http://www.cv.nrao.edu/~rfisher/Ephemerides/earth_rot.html * <p> * TODO Check with the "Explanatory Supplements for ...
Calculate the corrections for right ascension in declination that are needed because of Earth's precession. The formulas are approximations found here HREF TODO Check with the "Explanatory Supplements for the Astronomical Almanac"
calculatePrecessionCorrection
{ "repo_name": "fact-project/fact-tools", "path": "src/main/java/fact/coordinates/EquatorialCoordinate.java", "license": "gpl-3.0", "size": 6154 }
[ "java.time.ZonedDateTime", "java.time.temporal.ChronoUnit" ]
import java.time.ZonedDateTime; import java.time.temporal.ChronoUnit;
import java.time.*; import java.time.temporal.*;
[ "java.time" ]
java.time;
218,113
@Override protected Connection chooseConnection(final RequestMessage msg) throws TimeoutException, ConnectionException { final Iterator<Host> possibleHosts = this.cluster.loadBalancingStrategy().select(msg); if (!possibleHosts.hasNext()) throw new TimeoutException("Timed out wait...
Connection function(final RequestMessage msg) throws TimeoutException, ConnectionException { final Iterator<Host> possibleHosts = this.cluster.loadBalancingStrategy().select(msg); if (!possibleHosts.hasNext()) throw new TimeoutException(STR); final Host bestHost = this.cluster.loadBalancingStrategy().select(msg).next()...
/** * Uses a {@link LoadBalancingStrategy} to choose the best {@link Host} and then selects the best connection * from that host's connection pool. */
Uses a <code>LoadBalancingStrategy</code> to choose the best <code>Host</code> and then selects the best connection from that host's connection pool
chooseConnection
{ "repo_name": "dalaro/incubator-tinkerpop", "path": "gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/Client.java", "license": "apache-2.0", "size": 23065 }
[ "java.util.Iterator", "java.util.concurrent.TimeUnit", "java.util.concurrent.TimeoutException", "org.apache.tinkerpop.gremlin.driver.exception.ConnectionException", "org.apache.tinkerpop.gremlin.driver.message.RequestMessage" ]
import java.util.Iterator; import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; import org.apache.tinkerpop.gremlin.driver.exception.ConnectionException; import org.apache.tinkerpop.gremlin.driver.message.RequestMessage;
import java.util.*; import java.util.concurrent.*; import org.apache.tinkerpop.gremlin.driver.exception.*; import org.apache.tinkerpop.gremlin.driver.message.*;
[ "java.util", "org.apache.tinkerpop" ]
java.util; org.apache.tinkerpop;
1,171,429
public ServiceResponse listMethods(final ServiceRequest request) throws SOAPException;
ServiceResponse function(final ServiceRequest request) throws SOAPException;
/** * Calls listMethods meta service that lists all the services offered by a * service provider. Returns a list of ProducerMember objects wrapped in * ServiceResponse object's responseData variable. * * @param request the ServiceRequest object to be sent * @return ServiceResponse that hol...
Calls listMethods meta service that lists all the services offered by a service provider. Returns a list of ProducerMember objects wrapped in ServiceResponse object's responseData variable
listMethods
{ "repo_name": "petkivim/xrd4j", "path": "src/client/src/main/java/com/pkrete/xrd4j/client/LoadBalancedSOAPClient.java", "license": "mit", "size": 4429 }
[ "com.pkrete.xrd4j.common.message.ServiceRequest", "com.pkrete.xrd4j.common.message.ServiceResponse", "javax.xml.soap.SOAPException" ]
import com.pkrete.xrd4j.common.message.ServiceRequest; import com.pkrete.xrd4j.common.message.ServiceResponse; import javax.xml.soap.SOAPException;
import com.pkrete.xrd4j.common.message.*; import javax.xml.soap.*;
[ "com.pkrete.xrd4j", "javax.xml" ]
com.pkrete.xrd4j; javax.xml;
2,153,876
VariableDeclaration getVarDecl();
VariableDeclaration getVarDecl();
/** * Returns the value of the '<em><b>Var Decl</b></em>' containment reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the value of the '<em>Var Decl</em>' containment reference. * @see #setVarDecl(VariableDeclaration) * @see de.uni_hildesheim.sse.vil.rt.rtVil.RtVilPackage#...
Returns the value of the 'Var Decl' containment reference.
getVarDecl
{ "repo_name": "SSEHUB/EASyProducer", "path": "Plugins/Instantiation/de.uni_hildesheim.sse.vil.rt/src-gen/de/uni_hildesheim/sse/vil/rt/rtVil/BreakdownElement.java", "license": "apache-2.0", "size": 3562 }
[ "de.uni_hildesheim.sse.vil.expressions.expressionDsl.VariableDeclaration" ]
import de.uni_hildesheim.sse.vil.expressions.expressionDsl.VariableDeclaration;
import de.uni_hildesheim.sse.vil.expressions.*;
[ "de.uni_hildesheim.sse" ]
de.uni_hildesheim.sse;
474,054
public ComponentDetailView getComponentDetails(String componentId);
ComponentDetailView function(String componentId);
/** * Return the details object of the component attached to the given id. (the * full view) * * @param componentId * @return */
Return the details object of the component attached to the given id. (the full view)
getComponentDetails
{ "repo_name": "tyler-travis/openstorefront", "path": "server/openstorefront/openstorefront-core/model/src/main/java/edu/usu/sdl/openstorefront/core/api/ComponentService.java", "license": "apache-2.0", "size": 14837 }
[ "edu.usu.sdl.openstorefront.core.view.ComponentDetailView" ]
import edu.usu.sdl.openstorefront.core.view.ComponentDetailView;
import edu.usu.sdl.openstorefront.core.view.*;
[ "edu.usu.sdl" ]
edu.usu.sdl;
1,173,240
private void addTrip() { // Show a dialog box dialog = new MaterialDialog.Builder(AddNewTrip.this) .title(R.string.app_name) .content("Please wait...") .progress(true, 0) .show(); String uri = Constants.apilink + "trip/add-tri...
void function() { dialog = new MaterialDialog.Builder(AddNewTrip.this) .title(R.string.app_name) .content(STR) .progress(true, 0) .show(); String uri = Constants.apilink + STR + userid + STR + tripname + STR + startdate + STR + cityid; Log.e(STR, uri);
/** * Calls API to add new trip */
Calls API to add new trip
addTrip
{ "repo_name": "gugakatsi/Travel-Mate", "path": "Android/app/src/main/java/tie/hackathon/travelguide/AddNewTrip.java", "license": "mit", "size": 9982 }
[ "android.util.Log", "com.afollestad.materialdialogs.MaterialDialog" ]
import android.util.Log; import com.afollestad.materialdialogs.MaterialDialog;
import android.util.*; import com.afollestad.materialdialogs.*;
[ "android.util", "com.afollestad.materialdialogs" ]
android.util; com.afollestad.materialdialogs;
1,341,045
private DatagramSocket openNetworkSocket () throws SQLException { // Use a MulticastSocket (rather than a DatagramSocket) to allow multiple nodes on the same machine to bind to the same port. // Configure the Multicast socket to send/receive using any local address, or bind the multicast socket to a specific ad...
DatagramSocket function () throws SQLException { MulticastSocket skt = null; try { discoveryPort = GaianDBConfig.getDiscoveryPort(); skt = new MulticastSocket(); String defaultIP = getDefaultLocalIP(); defaultInterface = InetAddress.getByName(defaultIP); skt.setTimeToLive(50); joinMulticastGroupPerInterface( skt, DEFAU...
/** * This method prepares the necessary socket for network discovery of gaian nodes */
This method prepares the necessary socket for network discovery of gaian nodes
openNetworkSocket
{ "repo_name": "gaiandb/gaiandb", "path": "java/Prototype/Connectors/com/ibm/gaiandb/jdbc/discoveryclient/GaianConnectionSeeker.java", "license": "epl-1.0", "size": 26244 }
[ "com.ibm.gaiandb.GaianDBConfig", "com.ibm.gaiandb.diags.GDBMessages", "java.net.DatagramSocket", "java.net.InetAddress", "java.net.MulticastSocket", "java.sql.SQLException" ]
import com.ibm.gaiandb.GaianDBConfig; import com.ibm.gaiandb.diags.GDBMessages; import java.net.DatagramSocket; import java.net.InetAddress; import java.net.MulticastSocket; import java.sql.SQLException;
import com.ibm.gaiandb.*; import com.ibm.gaiandb.diags.*; import java.net.*; import java.sql.*;
[ "com.ibm.gaiandb", "java.net", "java.sql" ]
com.ibm.gaiandb; java.net; java.sql;
2,023,476
private Node generateCritRefElementRef(Node outboundRelElem, Node elementRefNode, XmlProcessor hqmfXmlProcessor) throws XPathExpressionException { String ext = getElementRefExt(elementRefNode, measureExport.getSimpleXMLProcessor()); String root = elementRefNode.getAttributes().getNamedItem(ID).getNodeValue();...
Node function(Node outboundRelElem, Node elementRefNode, XmlProcessor hqmfXmlProcessor) throws XPathExpressionException { String ext = getElementRefExt(elementRefNode, measureExport.getSimpleXMLProcessor()); String root = elementRefNode.getAttributes().getNamedItem(ID).getNodeValue(); Node idNodeQDM = hqmfXmlProcessor....
/** * Generate crit ref element ref. * * @param outboundRelElem * the outbound rel elem * @param elementRefNode * the element ref node * @param hqmfXmlProcessor * the hqmf xml processor * @return the node * @throws XPathExpressionException * the x path ...
Generate crit ref element ref
generateCritRefElementRef
{ "repo_name": "MeasureAuthoringTool/MeasureAuthoringTool_LatestSprint", "path": "mat/src/main/java/mat/server/hqmf/qdm_5_4/HQMFClauseLogicGenerator.java", "license": "cc0-1.0", "size": 134287 }
[ "javax.xml.xpath.XPathExpressionException", "org.w3c.dom.Node" ]
import javax.xml.xpath.XPathExpressionException; import org.w3c.dom.Node;
import javax.xml.xpath.*; import org.w3c.dom.*;
[ "javax.xml", "org.w3c.dom" ]
javax.xml; org.w3c.dom;
1,109,488
protected String getColumnList(List<String> columns) { StringBuilder b=new StringBuilder(); boolean first=true; for (String column:columns) { if (!first) { b.append(","); } else { first =false; } b.append(column); } return b.toString(); }
String function(List<String> columns) { StringBuilder b=new StringBuilder(); boolean first=true; for (String column:columns) { if (!first) { b.append(","); } else { first =false; } b.append(column); } return b.toString(); }
/** * Takes a list of columns as <code>String</code> values and returns them as * a <code>String</code> of comma-separated values. * * @param columns * - The list of columns to process. * @return A <code>String</code> of comma-separated values. */
Takes a list of columns as <code>String</code> values and returns them as a <code>String</code> of comma-separated values
getColumnList
{ "repo_name": "dotCMS/core", "path": "dotCMS/src/main/java/com/dotmarketing/startup/AbstractJDBCStartupTask.java", "license": "gpl-3.0", "size": 55065 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
2,912,037
public static Task getTask( String grassXml ) throws Exception { String featureNamespaces = "http://xml.org/sax/features/namespaces"; String featureNamespacePrefixes = "http://xml.org/sax/features/namespace-prefixes"; JAXBContext jaxbContext = JAXBContext.newInstance(GrassInterface.class);
static Task function( String grassXml ) throws Exception { String featureNamespaces = STRhttp: JAXBContext jaxbContext = JAXBContext.newInstance(GrassInterface.class);
/** * Get the jaxb grass {@link Task} for a given xml string. * * @param grassXml te xml string to parse. * @return the grass task. * @throws Exception */
Get the jaxb grass <code>Task</code> for a given xml string
getTask
{ "repo_name": "silviafranceschi/jgrasstools", "path": "grass/src/main/java/org/jgrasstools/grass/utils/GrassUtils.java", "license": "gpl-3.0", "size": 23336 }
[ "javax.xml.bind.JAXBContext", "org.jgrasstools.grass.dtd64.GrassInterface", "org.jgrasstools.grass.dtd64.Task" ]
import javax.xml.bind.JAXBContext; import org.jgrasstools.grass.dtd64.GrassInterface; import org.jgrasstools.grass.dtd64.Task;
import javax.xml.bind.*; import org.jgrasstools.grass.dtd64.*;
[ "javax.xml", "org.jgrasstools.grass" ]
javax.xml; org.jgrasstools.grass;
1,195,684
public PlayQueueInfo getPlayQueue() throws Exception { HttpServletRequest request = WebContextFactory.get().getHttpServletRequest(); HttpServletResponse response = WebContextFactory.get().getHttpServletResponse(); Player player = getCurrentPlayer(request, response); return convert(re...
PlayQueueInfo function() throws Exception { HttpServletRequest request = WebContextFactory.get().getHttpServletRequest(); HttpServletResponse response = WebContextFactory.get().getHttpServletResponse(); Player player = getCurrentPlayer(request, response); return convert(request, player, false); }
/** * Returns the play queue for the player of the current user. * * @return The play queue. */
Returns the play queue for the player of the current user
getPlayQueue
{ "repo_name": "langera/libresonic", "path": "libresonic-main/src/main/java/org/libresonic/player/ajax/PlayQueueService.java", "license": "gpl-3.0", "size": 34299 }
[ "javax.servlet.http.HttpServletRequest", "javax.servlet.http.HttpServletResponse", "org.directwebremoting.WebContextFactory", "org.libresonic.player.domain.Player" ]
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.directwebremoting.WebContextFactory; import org.libresonic.player.domain.Player;
import javax.servlet.http.*; import org.directwebremoting.*; import org.libresonic.player.domain.*;
[ "javax.servlet", "org.directwebremoting", "org.libresonic.player" ]
javax.servlet; org.directwebremoting; org.libresonic.player;
437,292
@Override public void writeMappings(Collection<IMappingConsumer> consumers) { MappingSet<MappingField> fields = new MappingSet<MappingField>(); MappingSet<MappingMethod> methods = new MappingSet<MappingMethod>(); for (IMappingConsumer mappings : consumers) { fields.a...
void function(Collection<IMappingConsumer> consumers) { MappingSet<MappingField> fields = new MappingSet<MappingField>(); MappingSet<MappingMethod> methods = new MappingSet<MappingMethod>(); for (IMappingConsumer mappings : consumers) { fields.addAll(mappings.getFieldMappings(this.type)); methods.addAll(mappings.getMet...
/** * Write out generated mappings */
Write out generated mappings
writeMappings
{ "repo_name": "SpongePowered/Mixin", "path": "src/ap/java/org/spongepowered/tools/obfuscation/ObfuscationEnvironment.java", "license": "mit", "size": 13111 }
[ "java.util.Collection", "org.spongepowered.asm.obfuscation.mapping.common.MappingField", "org.spongepowered.asm.obfuscation.mapping.common.MappingMethod", "org.spongepowered.tools.obfuscation.mapping.IMappingConsumer" ]
import java.util.Collection; import org.spongepowered.asm.obfuscation.mapping.common.MappingField; import org.spongepowered.asm.obfuscation.mapping.common.MappingMethod; import org.spongepowered.tools.obfuscation.mapping.IMappingConsumer;
import java.util.*; import org.spongepowered.asm.obfuscation.mapping.common.*; import org.spongepowered.tools.obfuscation.mapping.*;
[ "java.util", "org.spongepowered.asm", "org.spongepowered.tools" ]
java.util; org.spongepowered.asm; org.spongepowered.tools;
982,949
private static ContextMenuCoordinator openContextMenuByJs(Tab tab, String jsCode) throws TimeoutException { final OnContextMenuShownHelper helper = new OnContextMenuShownHelper(); ContextMenuHelper.setMenuShownCallbackForTests((coordinator) -> { helper.notifyCalled(coordinato...
static ContextMenuCoordinator function(Tab tab, String jsCode) throws TimeoutException { final OnContextMenuShownHelper helper = new OnContextMenuShownHelper(); ContextMenuHelper.setMenuShownCallbackForTests((coordinator) -> { helper.notifyCalled(coordinator); ContextMenuHelper.setMenuShownCallbackForTests(null); }); i...
/** * Opens a context menu. * @param tab The tab to open a context menu for. * @param jsCode The javascript to get the DOM node to long press to * open the context menu for. * @return The {@link ContextMenuCoordi...
Opens a context menu
openContextMenuByJs
{ "repo_name": "ric2b/Vivaldi-browser", "path": "chromium/chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/contextmenu/ContextMenuUtils.java", "license": "bsd-3-clause", "size": 10840 }
[ "java.util.concurrent.TimeoutException", "org.chromium.chrome.browser.contextmenu.ContextMenuCoordinator", "org.chromium.chrome.browser.contextmenu.ContextMenuHelper", "org.chromium.chrome.browser.tab.Tab", "org.chromium.content_public.browser.test.util.DOMUtils" ]
import java.util.concurrent.TimeoutException; import org.chromium.chrome.browser.contextmenu.ContextMenuCoordinator; import org.chromium.chrome.browser.contextmenu.ContextMenuHelper; import org.chromium.chrome.browser.tab.Tab; import org.chromium.content_public.browser.test.util.DOMUtils;
import java.util.concurrent.*; import org.chromium.chrome.browser.contextmenu.*; import org.chromium.chrome.browser.tab.*; import org.chromium.content_public.browser.test.util.*;
[ "java.util", "org.chromium.chrome", "org.chromium.content_public" ]
java.util; org.chromium.chrome; org.chromium.content_public;
2,588,214
void pathTailNotFound(TreePath tp, Object source);
void pathTailNotFound(TreePath tp, Object source);
/** * reached end of branch in source before end of specified path - * the specified path does not exist in the source * * @param tp TODO * @param source TODO */
reached end of branch in source before end of specified path - the specified path does not exist in the source
pathTailNotFound
{ "repo_name": "netplex/json-smart-v2", "path": "json-smart-action/src/main/java/net/minidev/json/actions/navigate/NavigateAction.java", "license": "apache-2.0", "size": 3567 }
[ "net.minidev.json.actions.path.TreePath" ]
import net.minidev.json.actions.path.TreePath;
import net.minidev.json.actions.path.*;
[ "net.minidev.json" ]
net.minidev.json;
1,516,897
public String getOriginatingServletPath(HttpServletRequest request) { String servletPath = (String) request.getAttribute(WebUtils.FORWARD_SERVLET_PATH_ATTRIBUTE); if (servletPath == null) { servletPath = request.getServletPath(); } return servletPath; }
String function(HttpServletRequest request) { String servletPath = (String) request.getAttribute(WebUtils.FORWARD_SERVLET_PATH_ATTRIBUTE); if (servletPath == null) { servletPath = request.getServletPath(); } return servletPath; }
/** * Return the servlet path for the given request, detecting an include request * URL if called within a RequestDispatcher include. * @param request current HTTP request * @return the servlet path */
Return the servlet path for the given request, detecting an include request URL if called within a RequestDispatcher include
getOriginatingServletPath
{ "repo_name": "leogoing/spring_jeesite", "path": "spring-web-4.0/org/springframework/web/util/UrlPathHelper.java", "license": "apache-2.0", "size": 20664 }
[ "javax.servlet.http.HttpServletRequest" ]
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.*;
[ "javax.servlet" ]
javax.servlet;
1,244,063
public static String flavor(int flavor) { // flavors = { DISABLEOVERRIDE, RESTRICTED, TRANSLATE } // !DISABLEOVERRIDE = ENABLEOVERRIDE // !RESTRICTED = TOSUBCLASS // !TRANSLATE = ? StringBuffer buf = new StringBuffer(); buf.append(((flavor & CIMFlavor.DISABLEOVERRIDE) > 0 ? DISABLEOVERRIDE : ENABLE...
static String function(int flavor) { StringBuffer buf = new StringBuffer(); buf.append(((flavor & CIMFlavor.DISABLEOVERRIDE) > 0 ? DISABLEOVERRIDE : ENABLEOVERRIDE)); buf.append(' ' + ((flavor & CIMFlavor.RESTRICTED) > 0 ? RESTRICTED : TOSUBCLASS)); if ((flavor & CIMFlavor.TRANSLATE) > 0) buf.append(' ' + TRANSLATABLE)...
/** * <pre> * flavor = ENABLEOVERRIDE | DISABLEOVERRIDE | RESTRICTED | TOSUBCLASS | TRANSLATABLE * </pre> * * @param flavor * @return the MOF string */
<code> flavor = ENABLEOVERRIDE | DISABLEOVERRIDE | RESTRICTED | TOSUBCLASS | TRANSLATABLE </code>
flavor
{ "repo_name": "acleasby/sblim2", "path": "src/main/java/org/sblim/cimclient/internal/util/MOF.java", "license": "epl-1.0", "size": 25698 }
[ "javax.cim.CIMFlavor" ]
import javax.cim.CIMFlavor;
import javax.cim.*;
[ "javax.cim" ]
javax.cim;
729,098
@Override public void write(byte b[], int off, int len) throws IOException { checkThreshold(len); getStream().write(b, off, len); written += len; }
void function(byte b[], int off, int len) throws IOException { checkThreshold(len); getStream().write(b, off, len); written += len; }
/** * Writes <code>len</code> bytes from the specified byte array starting at * offset <code>off</code> to this output stream. * * @param b The byte array from which the data will be written. * @param off The start offset in the byte array. * @param len The number of bytes to write. ...
Writes <code>len</code> bytes from the specified byte array starting at offset <code>off</code> to this output stream
write
{ "repo_name": "plumer/codana", "path": "tomcat_files/7.0.0/ThresholdingOutputStream.java", "license": "mit", "size": 7316 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,605,320
protected void doPaintObjects(PaintPanel panel, Graphics g, List<Polygon> locations) { String label; Rectangle rect; Color labelColor; labelColor = getColor(); g.setFont(getLabelFont()); for (Polygon poly : locations) { if (poly == null) continue; if (getUseColorsPerType()...
void function(PaintPanel panel, Graphics g, List<Polygon> locations) { String label; Rectangle rect; Color labelColor; labelColor = getColor(); g.setFont(getLabelFont()); for (Polygon poly : locations) { if (poly == null) continue; if (getUseColorsPerType()) { if (m_Overlays.hasColor(poly)) labelColor = m_Overlays.getC...
/** * Performs the actual painting of the objects. * * @param panel the panel this overlay is for * @param g the graphics context * @param locations the locations to paint */
Performs the actual painting of the objects
doPaintObjects
{ "repo_name": "waikato-datamining/adams-base", "path": "adams-imaging/src/main/java/adams/gui/visualization/image/SimplePointOverlayFromReport.java", "license": "gpl-3.0", "size": 4393 }
[ "java.awt.Color", "java.awt.Graphics", "java.awt.Polygon", "java.awt.Rectangle", "java.util.List" ]
import java.awt.Color; import java.awt.Graphics; import java.awt.Polygon; import java.awt.Rectangle; import java.util.List;
import java.awt.*; import java.util.*;
[ "java.awt", "java.util" ]
java.awt; java.util;
1,571,375
public void handleGET(CoapExchange exchange) { exchange.respond(ResponseCode.METHOD_NOT_ALLOWED); }
void function(CoapExchange exchange) { exchange.respond(ResponseCode.METHOD_NOT_ALLOWED); }
/** * Handles the GET request in the given CoAPExchange. By default it responds * with a 4.05 (Method Not Allowed). Override this method to respond * differently to GET requests. Possible response codes for GET requests are * Content (2.05) and Valid (2.03). * * @param exchange the CoapExchange for the sim...
Handles the GET request in the given CoAPExchange. By default it responds with a 4.05 (Method Not Allowed). Override this method to respond differently to GET requests. Possible response codes for GET requests are Content (2.05) and Valid (2.03)
handleGET
{ "repo_name": "iotoasis/SI", "path": "si-onem2m-src/IITP_IoT_2_7/src/extlib/java/org/eclipse/californium/core/CoapResource.java", "license": "bsd-2-clause", "size": 28416 }
[ "org.eclipse.californium.core.coap.CoAP", "org.eclipse.californium.core.server.resources.CoapExchange" ]
import org.eclipse.californium.core.coap.CoAP; import org.eclipse.californium.core.server.resources.CoapExchange;
import org.eclipse.californium.core.coap.*; import org.eclipse.californium.core.server.resources.*;
[ "org.eclipse.californium" ]
org.eclipse.californium;
1,913,233
@Test public void missingLocationPolicy() { try { mTestStream = new FileInStream(mStatus, InStreamOptions.defaults().setReadType(ReadType.CACHE).setLocationPolicy(null), mContext); } catch (NullPointerException e) { Assert.assertEquals(PreconditionMessage.FILE_WRITE_LOCATION_POLICY_UNS...
void function() { try { mTestStream = new FileInStream(mStatus, InStreamOptions.defaults().setReadType(ReadType.CACHE).setLocationPolicy(null), mContext); } catch (NullPointerException e) { Assert.assertEquals(PreconditionMessage.FILE_WRITE_LOCATION_POLICY_UNSPECIFIED.toString(), e.getMessage()); } }
/** * Tests that the correct exception message is produced when the location policy is not specified. */
Tests that the correct exception message is produced when the location policy is not specified
missingLocationPolicy
{ "repo_name": "WilliamZapata/alluxio", "path": "core/client/fs/src/test/java/alluxio/client/file/FileInStreamTest.java", "license": "apache-2.0", "size": 21305 }
[ "org.junit.Assert" ]
import org.junit.Assert;
import org.junit.*;
[ "org.junit" ]
org.junit;
535,557
@ServiceMethod(returns = ReturnType.SINGLE) Mono<Response<Flux<ByteBuffer>>> createOrUpdateAtSubscriptionScopeWithResponseAsync( String deploymentName, DeploymentInner parameters);
@ServiceMethod(returns = ReturnType.SINGLE) Mono<Response<Flux<ByteBuffer>>> createOrUpdateAtSubscriptionScopeWithResponseAsync( String deploymentName, DeploymentInner parameters);
/** * You can provide the template and parameters directly in the request or link to JSON files. * * @param deploymentName The name of the deployment. * @param parameters Deployment operation parameters. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws...
You can provide the template and parameters directly in the request or link to JSON files
createOrUpdateAtSubscriptionScopeWithResponseAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-resources/src/main/java/com/azure/resourcemanager/resources/fluent/DeploymentsClient.java", "license": "mit", "size": 209954 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.Response", "com.azure.resourcemanager.resources.fluent.models.DeploymentInner", "java.nio.ByteBuffer" ]
import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.core.http.rest.Response; import com.azure.resourcemanager.resources.fluent.models.DeploymentInner; import java.nio.ByteBuffer;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.resourcemanager.resources.fluent.models.*; import java.nio.*;
[ "com.azure.core", "com.azure.resourcemanager", "java.nio" ]
com.azure.core; com.azure.resourcemanager; java.nio;
2,429,629
protected static ResultSet getAztRegimens(Connection conn, Long patientId) { ResultSet rs = null; try { String sql = "SELECT regimen_visit_date AS regimen_visit_date\n" + "FROM zeprs.encounter, zeprs.arvregimen\n" + "WHERE encounter.id = arvregimen.id\n" + "AND encounter.patient_...
static ResultSet function(Connection conn, Long patientId) { ResultSet rs = null; try { String sql = STR + STR + STR + STR + STR + STR; PreparedStatement ps = conn.prepareStatement(sql); ps.setLong(1, patientId); rs = ps.executeQuery(); } catch (Exception ex) { log.error(ex); } return rs; }
/** * Fetch a list of AZT ARV regimen_visit_dates. Get the first one. * @param conn * @param patientId * @return */
Fetch a list of AZT ARV regimen_visit_dates. Get the first one
getAztRegimens
{ "repo_name": "chrisekelley/zeprs", "path": "src/zeprs/org/cidrz/project/zeprs/report/ZEPRSUtils.java", "license": "apache-2.0", "size": 79024 }
[ "java.sql.Connection", "java.sql.PreparedStatement", "java.sql.ResultSet" ]
import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet;
import java.sql.*;
[ "java.sql" ]
java.sql;
2,582,709
public void removeApplicationParameter(String name) { synchronized (applicationParameters) { // Make sure this parameter is currently present int n = -1; for (int i = 0; i < applicationParameters.length; i++) { if (name.equals(applicationParameter...
void function(String name) { synchronized (applicationParameters) { int n = -1; for (int i = 0; i < applicationParameters.length; i++) { if (name.equals(applicationParameters[i].getName())) { n = i; break; } } if (n < 0) return; int j = 0; ApplicationParameter results[] = new ApplicationParameter[applicationParameters....
/** * Remove the application parameter with the specified name from * the set for this application. * * @param name Name of the application parameter to remove */
Remove the application parameter with the specified name from the set for this application
removeApplicationParameter
{ "repo_name": "c-rainstorm/jerrydog", "path": "src/main/java/org/apache/catalina/core/StandardDefaultContext.java", "license": "gpl-3.0", "size": 40782 }
[ "org.apache.catalina.deploy.ApplicationParameter" ]
import org.apache.catalina.deploy.ApplicationParameter;
import org.apache.catalina.deploy.*;
[ "org.apache.catalina" ]
org.apache.catalina;
974,370
if((path == null) || (path.length() == 0)) { throw new IOException("No configuration for (" + name + ")"); } File dir = new File(path); if(dir.exists()) { if(!dir.isDirectory()) { throw new IOException("Dir(" + name + ") at (" + path + ") exists but is not a directory!"); } } else { if(...
if((path == null) (path.length() == 0)) { throw new IOException(STR + name + ")"); } File dir = new File(path); if(dir.exists()) { if(!dir.isDirectory()) { throw new IOException("Dir(" + name + STR + path + STR); } } else { if(!dir.mkdirs()) { throw new IOException(STR + name +STR + path + ")"); } } return dir; }
/** * Ensure that the path pointed to by 'path' is a directory, if possible * @param path * @param name * @return File that is a created directory * @throws IOException */
Ensure that the path pointed to by 'path' is a directory, if possible
ensureDir
{ "repo_name": "ato/wayback", "path": "wayback-core/src/main/java/org/archive/wayback/util/DirMaker.java", "license": "lgpl-2.1", "size": 2085 }
[ "java.io.File", "java.io.IOException" ]
import java.io.File; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
504,934
public StaticSitesClient getStaticSites() { return this.staticSites; } private final WebAppsClient webApps;
StaticSitesClient function() { return this.staticSites; } private final WebAppsClient webApps;
/** * Gets the StaticSitesClient object to access its operations. * * @return the StaticSitesClient object. */
Gets the StaticSitesClient object to access its operations
getStaticSites
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-appservice/src/main/java/com/azure/resourcemanager/appservice/implementation/WebSiteManagementClientImpl.java", "license": "mit", "size": 15159 }
[ "com.azure.resourcemanager.appservice.fluent.StaticSitesClient", "com.azure.resourcemanager.appservice.fluent.WebAppsClient" ]
import com.azure.resourcemanager.appservice.fluent.StaticSitesClient; import com.azure.resourcemanager.appservice.fluent.WebAppsClient;
import com.azure.resourcemanager.appservice.fluent.*;
[ "com.azure.resourcemanager" ]
com.azure.resourcemanager;
697,710
EAttribute getVirtualAttribute_Name();
EAttribute getVirtualAttribute_Name();
/** * Returns the meta object for the attribute '{@link fta_bdsl.VirtualAttribute#getName <em>Name</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for the attribute '<em>Name</em>'. * @see fta_bdsl.VirtualAttribute#getName() * @see #getVirtualAttribute() * @generated ...
Returns the meta object for the attribute '<code>fta_bdsl.VirtualAttribute#getName Name</code>'.
getVirtualAttribute_Name
{ "repo_name": "jesusc/bento", "path": "tests/test-outputs/bento.sirius.tests.metamodels.output/src/fta_bdsl/Fta_bdslPackage.java", "license": "epl-1.0", "size": 88357 }
[ "org.eclipse.emf.ecore.EAttribute" ]
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
2,414,057
private JPanel getFilterSettingsPanel() { if (filterSettingsPanel == null) { GridBagConstraints gridBagConstraints6 = new GridBagConstraints(); gridBagConstraints6.gridx = 0; gridBagConstraints6.fill = GridBagConstraints.HORIZONTAL; gridBagConstraints6.gridy = 0; GridBagConstraints gridBagConstraint...
JPanel function() { if (filterSettingsPanel == null) { GridBagConstraints gridBagConstraints6 = new GridBagConstraints(); gridBagConstraints6.gridx = 0; gridBagConstraints6.fill = GridBagConstraints.HORIZONTAL; gridBagConstraints6.gridy = 0; GridBagConstraints gridBagConstraints5 = new GridBagConstraints(); gridBagCons...
/** * This method initializes filterSettingsPanel * * @return javax.swing.JPanel */
This method initializes filterSettingsPanel
getFilterSettingsPanel
{ "repo_name": "gilles-fabre/ezRPC", "path": "LogReporter/LogReporterTool/com/reporter/WindowSettingsDialog.java", "license": "lgpl-3.0", "size": 15643 }
[ "java.awt.GridBagConstraints", "java.awt.GridBagLayout", "java.awt.Insets", "javax.swing.JPanel" ]
import java.awt.GridBagConstraints; import java.awt.GridBagLayout; import java.awt.Insets; import javax.swing.JPanel;
import java.awt.*; import javax.swing.*;
[ "java.awt", "javax.swing" ]
java.awt; javax.swing;
1,864,855
public void dropIndex( Policy policy, String namespace, String setName, String indexName ) throws AerospikeException; //------------------------------------------------------- // User administration //-------------------------------------------------------
void function( Policy policy, String namespace, String setName, String indexName ) throws AerospikeException;
/** * Delete secondary index. * This method is only supported by Aerospike 3 servers. * * @param policy generic configuration parameters, pass in null for defaults * @param namespace namespace - equivalent to database name * @param setName optional set name - equivalent to database table * @para...
Delete secondary index. This method is only supported by Aerospike 3 servers
dropIndex
{ "repo_name": "wgpshashank/aerospike-client-java", "path": "client/src/com/aerospike/client/IAerospikeClient.java", "license": "apache-2.0", "size": 41552 }
[ "com.aerospike.client.policy.Policy" ]
import com.aerospike.client.policy.Policy;
import com.aerospike.client.policy.*;
[ "com.aerospike.client" ]
com.aerospike.client;
1,984,760
public Iterator iterator() { return new Iterator() { private int index = start; private int lastReturnedIndex = -1; private boolean isFirst = full;
Iterator function() { return new Iterator() { private int index = start; private int lastReturnedIndex = -1; private boolean isFirst = full;
/** * Returns an iterator over this buffer's elements. * * @return an iterator over this buffer's elements */
Returns an iterator over this buffer's elements
iterator
{ "repo_name": "ProfilingLabs/Usemon2", "path": "usemon-agent-commons-java/src/main/java/com/usemon/lib/org/apache/commons/collections/buffer/BoundedFifoBuffer.java", "license": "mpl-2.0", "size": 11914 }
[ "java.util.Iterator" ]
import java.util.Iterator;
import java.util.*;
[ "java.util" ]
java.util;
2,373,709
public int getStepIndexFromFile(BatchStepFileDescriptor batchStepFile) { File runFile = batchStepFile.getStepFile(); if (runFile != null) { List<String> contents = getFileContents(runFile); if (contents.size() > 0) { return Integer.parseInt(contents.get(0)); ...
int function(BatchStepFileDescriptor batchStepFile) { File runFile = batchStepFile.getStepFile(); if (runFile != null) { List<String> contents = getFileContents(runFile); if (contents.size() > 0) { return Integer.parseInt(contents.get(0)); } } return -1; }
/** * Returns the index of the step contained in the file * * @param batchStepFile the file from which to retrieve the step index * @return the step index, or -1 if there was no content in the file */
Returns the index of the step contained in the file
getStepIndexFromFile
{ "repo_name": "quikkian-ua-devops/will-financials", "path": "kfs-core/src/main/java/org/kuali/kfs/sys/context/BatchContainerDirectory.java", "license": "agpl-3.0", "size": 19504 }
[ "java.io.File", "java.util.List" ]
import java.io.File; import java.util.List;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
766,257
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code."> @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { processRequest(request, response)...
void function(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { processRequest(request, response); } catch (Exception ex) { } }
/** * Handles the HTTP <code>GET</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>GET</code> method
doGet
{ "repo_name": "AngelAlpanez/ausiasYield2014", "path": "src/main/java/net/daw/control/JspControl.java", "license": "gpl-2.0", "size": 10058 }
[ "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;
1,626,861
public static boolean isExpression(RowExpression rowExpression) { return (rowExpression instanceof OriginalExpression); } private static final class OriginalExpression extends RowExpression { private final Expression expression; OriginalExpression(Expressio...
static boolean function(RowExpression rowExpression) { return (rowExpression instanceof OriginalExpression); } private static final class OriginalExpression extends RowExpression { private final Expression expression; OriginalExpression(Expression expression) { this.expression = requireNonNull(expression, STR); }
/** * Check if the given {@param rowExpression} is an Expression. */
Check if the given rowExpression is an Expression
isExpression
{ "repo_name": "mvp/presto", "path": "presto-main/src/main/java/com/facebook/presto/sql/relational/OriginalExpressionUtils.java", "license": "apache-2.0", "size": 4170 }
[ "com.facebook.presto.spi.relation.RowExpression", "com.facebook.presto.sql.tree.Expression", "java.util.Objects" ]
import com.facebook.presto.spi.relation.RowExpression; import com.facebook.presto.sql.tree.Expression; import java.util.Objects;
import com.facebook.presto.spi.relation.*; import com.facebook.presto.sql.tree.*; import java.util.*;
[ "com.facebook.presto", "java.util" ]
com.facebook.presto; java.util;
719,367
SQLiteLoaderObserver registerLoader(final SQLiteLoader loader, final String table) { Logger.d(TAG, "Add Loader Observer: %s", table); final SQLiteLoaderObserver entry = new SQLiteLoaderObserver(loader, table); mActiveLoaders.add(entry); return entry; }
SQLiteLoaderObserver registerLoader(final SQLiteLoader loader, final String table) { Logger.d(TAG, STR, table); final SQLiteLoaderObserver entry = new SQLiteLoaderObserver(loader, table); mActiveLoaders.add(entry); return entry; }
/** * Register a loader for maintaining notify changes * * @param loader The {@link SQLiteLoader} loader to register * @param table The table name * @return The {@link SQLiteLoaderObserver} that was created. Use this to * unregister the loader entry */
Register a loader for maintaining notify changes
registerLoader
{ "repo_name": "ashokslsk/yelo-android", "path": "app/src/main/java/red/yelo/data/YeloSQLiteOpenHelper.java", "license": "apache-2.0", "size": 11151 }
[ "red.yelo.utils.Logger" ]
import red.yelo.utils.Logger;
import red.yelo.utils.*;
[ "red.yelo.utils" ]
red.yelo.utils;
2,676,839
public void test_fill$IIII() { // Test for method void java.util.Arrays.fill(int [], int, int, int) int val = Integer.MAX_VALUE; int d[] = new int[1000]; Arrays.fill(d, 400, d.length, val); for (int i = 0; i < 400; i++) assertTrue("Filled elements not in range", !...
public void test_fill$IIII() { int val = Integer.MAX_VALUE; int d[] = new int[1000]; Arrays.fill(d, 400, d.length, val); for (int i = 0; i < 400; i++) assertTrue(STR, !(d[i] == val)); for (int i = 400; i < d.length; i++) assertTrue(STR, d[i] == val); try { Arrays.fill(d, 10, 0, val); fail(STR); } catch (IllegalArgument...
/** * java.util.Arrays#fill(int[], int, int, int) */
java.util.Arrays#fill(int[], int, int, int)
test_fill$IIII
{ "repo_name": "mirego/j2objc", "path": "jre_emul/android/platform/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ArraysTest.java", "license": "apache-2.0", "size": 207868 }
[ "java.util.Arrays" ]
import java.util.Arrays;
import java.util.*;
[ "java.util" ]
java.util;
1,183,325
public boolean checkModuleEventRegistered(String eventName,WXModule module) { if (module != null) { List<String> events = module.getEventCallbacks(eventName); if (events != null && events.size() > 0) { return true; } } return false; }
boolean function(String eventName,WXModule module) { if (module != null) { List<String> events = module.getEventCallbacks(eventName); if (events != null && events.size() > 0) { return true; } } return false; }
/** * Check whether the current module registered the event * @param eventName EventName register in weex * @param module Events occur in this Module * @return register->true */
Check whether the current module registered the event
checkModuleEventRegistered
{ "repo_name": "cxfeng1/weex", "path": "android/sdk/src/main/java/com/taobao/weex/WXSDKInstance.java", "license": "apache-2.0", "size": 56425 }
[ "com.taobao.weex.common.WXModule", "java.util.List" ]
import com.taobao.weex.common.WXModule; import java.util.List;
import com.taobao.weex.common.*; import java.util.*;
[ "com.taobao.weex", "java.util" ]
com.taobao.weex; java.util;
2,639,782
@Test(expectedExceptions = IllegalArgumentException.class) public void testNullDataSource3() { HistoricalTimeSeriesProviderGetRequest.createGetLatest(IDS.iterator().next(), null, DATA_PROVIDER, DATA_FIELD); }
@Test(expectedExceptions = IllegalArgumentException.class) void function() { HistoricalTimeSeriesProviderGetRequest.createGetLatest(IDS.iterator().next(), null, DATA_PROVIDER, DATA_FIELD); }
/** * Tests that the data source cannot be null. */
Tests that the data source cannot be null
testNullDataSource3
{ "repo_name": "McLeodMoores/starling", "path": "projects/provider/src/test/java/com/opengamma/provider/historicaltimeseries/HistoricalTimeSeriesProviderGetRequestTest.java", "license": "apache-2.0", "size": 10932 }
[ "com.opengamma.provider.historicaltimeseries.HistoricalTimeSeriesProviderGetRequest", "org.testng.annotations.Test" ]
import com.opengamma.provider.historicaltimeseries.HistoricalTimeSeriesProviderGetRequest; import org.testng.annotations.Test;
import com.opengamma.provider.historicaltimeseries.*; import org.testng.annotations.*;
[ "com.opengamma.provider", "org.testng.annotations" ]
com.opengamma.provider; org.testng.annotations;
2,264,646
public void save(File file, FileConfiguration config) { this.file = file; // Location settings config.set("sign.location.world", block.getLocation().getWorld().getName()); config.set("sign.location.x", block.getLocation().getBlockX()); config.set("sign.location.y", block.getLocation().getBlockY()); ...
void function(File file, FileConfiguration config) { this.file = file; config.set(STR, block.getLocation().getWorld().getName()); config.set(STR, block.getLocation().getBlockX()); config.set(STR, block.getLocation().getBlockY()); config.set(STR, block.getLocation().getBlockZ()); config.set(STR, course.getName()); }
/** * Save the information for the sign. * * @param config the config file for the sign */
Save the information for the sign
save
{ "repo_name": "CodingBadgers/MineKart", "path": "minekart/src/main/java/uk/thecodingbadgers/minekart/lobby/LobbySign.java", "license": "gpl-2.0", "size": 6116 }
[ "java.io.File", "org.bukkit.configuration.file.FileConfiguration" ]
import java.io.File; import org.bukkit.configuration.file.FileConfiguration;
import java.io.*; import org.bukkit.configuration.file.*;
[ "java.io", "org.bukkit.configuration" ]
java.io; org.bukkit.configuration;
930,145
public static SynergyNetPosition getLocalDeviceLocationPosOnly() { PositionConfigPrefsItem prefs = new PositionConfigPrefsItem(); float tableLocationX = prefs.getXPos(); float tableLocationY = prefs.getYPos(); int currentConnectionsCount = AppSystemControlComms.get().getNumberOfTablesOnline() - 1; ...
static SynergyNetPosition function() { PositionConfigPrefsItem prefs = new PositionConfigPrefsItem(); float tableLocationX = prefs.getXPos(); float tableLocationY = prefs.getYPos(); int currentConnectionsCount = AppSystemControlComms.get().getNumberOfTablesOnline() - 1; if (prefs.getDeveloperMode()) { if (prefs.getHori...
/** * Gets the local device location pos only. * * @return the local device location pos only */
Gets the local device location pos only
getLocalDeviceLocationPosOnly
{ "repo_name": "synergynet/synergynet3.1", "path": "synergynet3.1-parent/synergynet3-appsystem-core/src/main/java/synergynet3/positioning/SynergyNetPositioning.java", "license": "bsd-3-clause", "size": 4907 }
[ "com.jme3.math.FastMath" ]
import com.jme3.math.FastMath;
import com.jme3.math.*;
[ "com.jme3.math" ]
com.jme3.math;
557,781
public SwitchNode setCases(final LexicalContext lc, final List<CaseNode> cases, final CaseNode defaultCase) { return setCases(lc, cases, defaultCase == null ? -1 : cases.indexOf(defaultCase)); }
SwitchNode function(final LexicalContext lc, final List<CaseNode> cases, final CaseNode defaultCase) { return setCases(lc, cases, defaultCase == null ? -1 : cases.indexOf(defaultCase)); }
/** * Set or reset the list of cases in this switch * @param lc lexical context * @param cases a list of cases, case nodes * @param defaultCase a case in the list that is the default - must be in the list or class will assert * @return new switch node or same if no state was changed */
Set or reset the list of cases in this switch
setCases
{ "repo_name": "malaporte/kaziranga", "path": "src/jdk/nashorn/internal/ir/SwitchNode.java", "license": "gpl-2.0", "size": 9222 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
369,037
public void addBatch() throws SQLException { synchronized (checkClosed().getConnectionMutex()) { if (this.batchedArgs == null) { this.batchedArgs = new ArrayList<Object>(); } for (int i = 0; i < this.parameterValues.length; i++) { checkAll...
void function() throws SQLException { synchronized (checkClosed().getConnectionMutex()) { if (this.batchedArgs == null) { this.batchedArgs = new ArrayList<Object>(); } for (int i = 0; i < this.parameterValues.length; i++) { checkAllParametersSet(this.parameterValues[i], this.parameterStreams[i], i); } this.batchedArgs....
/** * JDBC 2.0 Add a set of parameters to the batch. * * @exception SQLException * if a database-access error occurs. * * @see StatementImpl#addBatch */
JDBC 2.0 Add a set of parameters to the batch
addBatch
{ "repo_name": "swankjesse/mysql-connector-j", "path": "src/com/mysql/jdbc/PreparedStatement.java", "license": "gpl-2.0", "size": 198268 }
[ "java.sql.SQLException", "java.util.ArrayList" ]
import java.sql.SQLException; import java.util.ArrayList;
import java.sql.*; import java.util.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
2,904,639
public KeyStore getTrustKeyStore() { return getKeyStore(); }
KeyStore function() { return getKeyStore(); }
/** * Abstraction for getting Trusted KeyStore * * @return KeyStore instance */
Abstraction for getting Trusted KeyStore
getTrustKeyStore
{ "repo_name": "maheshika/wso2-synapse", "path": "modules/securevault/src/main/java/org/apache/synapse/securevault/keystore/TrustKeyStoreWrapper.java", "license": "apache-2.0", "size": 1409 }
[ "java.security.KeyStore" ]
import java.security.KeyStore;
import java.security.*;
[ "java.security" ]
java.security;
662,847
@SuppressWarnings("unchecked") T[] array = (T[]) Array.newInstance(clazz, values.length); for (int i = 0; i < values.length; i++) { array[i] = values[i]; } return array; }
@SuppressWarnings(STR) T[] array = (T[]) Array.newInstance(clazz, values.length); for (int i = 0; i < values.length; i++) { array[i] = values[i]; } return array; }
/** * Returns an array * * @deprecated do not use this method, the implementation doesn't make a lot * of sense and furthermore, the whole method is somewhat * pointless. * @param <T> * generic type of the items to place into an array * @param clazz * ...
Returns an array
asArray
{ "repo_name": "SphericalElephant/android-http", "path": "app/src/main/java/at/diamonddogs/util/Utils.java", "license": "apache-2.0", "size": 14973 }
[ "java.lang.reflect.Array" ]
import java.lang.reflect.Array;
import java.lang.reflect.*;
[ "java.lang" ]
java.lang;
2,152,172
public void setContent(Collection<CmsListItem> listItems) { if (m_metadata.isSelfManaged()) { m_filteredItems = new ArrayList<CmsListItem>(listItems); m_originalItems = null; } else { m_filteredItems = null; m_originalItems = new ArrayList<CmsListItem...
void function(Collection<CmsListItem> listItems) { if (m_metadata.isSelfManaged()) { m_filteredItems = new ArrayList<CmsListItem>(listItems); m_originalItems = null; } else { m_filteredItems = null; m_originalItems = new ArrayList<CmsListItem>(listItems); } }
/** * Sets the list item to display in the list.<p> * * @param listItems a collection of {@link CmsListItem} objects */
Sets the list item to display in the list
setContent
{ "repo_name": "ggiudetti/opencms-core", "path": "src-modules/org/opencms/workplace/list/CmsHtmlList.java", "license": "lgpl-2.1", "size": 37966 }
[ "java.util.ArrayList", "java.util.Collection" ]
import java.util.ArrayList; import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
2,248,747