method
stringlengths
13
441k
clean_method
stringlengths
7
313k
doc
stringlengths
17
17.3k
comment
stringlengths
3
1.42k
method_name
stringlengths
1
273
extra
dict
imports
list
imports_info
stringlengths
19
34.8k
cluster_imports_info
stringlengths
15
3.66k
libraries
list
libraries_info
stringlengths
6
661
id
int64
0
2.92M
public List<String> parse(final String line) { final StringBuffer sb = new StringBuffer(); this.list.clear(); // recycle to initial state int i = 0; if ( line.length() == 0 ) { this.list.add( line ); return this.list; }...
List<String> function(final String line) { final StringBuffer sb = new StringBuffer(); this.list.clear(); int i = 0; if ( line.length() == 0 ) { this.list.add( line ); return this.list; } do { sb.setLength( 0 ); if ( i < line.length() && line.charAt( i ) == '"' ) { i = advQuoted( line, sb, ++i ); } else { i = advPlain(...
/** * parse: break the input String into fields * * @return java.util.Iterator containing each field from the original as * a String, in order. */
parse: break the input String into fields
parse
{ "repo_name": "rokn/Count_Words_2015", "path": "testing/drools-master/drools-decisiontables/src/main/java/org/drools/decisiontable/parser/csv/CsvLineParser.java", "license": "mit", "size": 5603 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,762,097
protected final void emit_resolved_getstatic(FieldReference fieldRef) { RVMField field = fieldRef.peekResolvedField(); Offset fieldOffset = field.getOffset(); TypeReference fieldType = fieldRef.getFieldContentsType(); if (MemoryManagerConstants.NEEDS_GETSTATIC_READ_BARRIER && fieldType.isReferenceType...
final void function(FieldReference fieldRef) { RVMField field = fieldRef.peekResolvedField(); Offset fieldOffset = field.getOffset(); TypeReference fieldType = fieldRef.getFieldContentsType(); if (MemoryManagerConstants.NEEDS_GETSTATIC_READ_BARRIER && fieldType.isReferenceType() && !field.isUntraced()) { Barriers.compi...
/** * Emit code to implement a getstatic * @param fieldRef the referenced field */
Emit code to implement a getstatic
emit_resolved_getstatic
{ "repo_name": "ut-osa/laminar", "path": "jikesrvm-3.0.0/rvm/src/org/jikesrvm/compilers/baseline/ppc/BaselineCompilerImpl.java", "license": "bsd-3-clause", "size": 181446 }
[ "org.jikesrvm.classloader.FieldReference", "org.jikesrvm.classloader.RVMField", "org.jikesrvm.classloader.TypeReference", "org.jikesrvm.mm.mminterface.MemoryManagerConstants", "org.vmmagic.unboxed.Offset" ]
import org.jikesrvm.classloader.FieldReference; import org.jikesrvm.classloader.RVMField; import org.jikesrvm.classloader.TypeReference; import org.jikesrvm.mm.mminterface.MemoryManagerConstants; import org.vmmagic.unboxed.Offset;
import org.jikesrvm.classloader.*; import org.jikesrvm.mm.mminterface.*; import org.vmmagic.unboxed.*;
[ "org.jikesrvm.classloader", "org.jikesrvm.mm", "org.vmmagic.unboxed" ]
org.jikesrvm.classloader; org.jikesrvm.mm; org.vmmagic.unboxed;
2,834,771
public static long getTimeSpanByNow(final Date date, @TimeConstants.Unit final int unit) { return getTimeSpan(date, new Date(), unit); }
static long function(final Date date, @TimeConstants.Unit final int unit) { return getTimeSpan(date, new Date(), unit); }
/** * Return the time span by now, in unit. * * @param date The date. * @param unit The unit of time span. * <ul> * <li>{@link TimeConstants#MSEC}</li> * <li>{@link TimeConstants#SEC }</li> * <li>{@link TimeConstants#MIN }</li> ...
Return the time span by now, in unit
getTimeSpanByNow
{ "repo_name": "didi/DoraemonKit", "path": "Android/dokit-util/src/main/java/com/didichuxing/doraemonkit/util/TimeUtils.java", "license": "apache-2.0", "size": 58527 }
[ "com.didichuxing.doraemonkit.constant.TimeConstants", "java.util.Date" ]
import com.didichuxing.doraemonkit.constant.TimeConstants; import java.util.Date;
import com.didichuxing.doraemonkit.constant.*; import java.util.*;
[ "com.didichuxing.doraemonkit", "java.util" ]
com.didichuxing.doraemonkit; java.util;
362,379
public void setCombinedTool(Behavior combinedTool) { this.combinedTool = combinedTool; if (currentMapTool == null) return; if (currentMapTool instanceof CompoundBehavior) { ((CompoundBehavior)currentMapTool).addMapBehavior(combinedTool, true); } else { currentMapTool = new CompoundBehavior(new B...
void function(Behavior combinedTool) { this.combinedTool = combinedTool; if (currentMapTool == null) return; if (currentMapTool instanceof CompoundBehavior) { ((CompoundBehavior)currentMapTool).addMapBehavior(combinedTool, true); } else { currentMapTool = new CompoundBehavior(new Behavior[] {currentMapTool}); ((Compoun...
/** * <p>Sets a tool to be used in combination with the current tool of this <code>MapControl</code>.</p> * * @param combinedTool a tool to be used in combination with the current tool of <code>MapControl</code> */
Sets a tool to be used in combination with the current tool of this <code>MapControl</code>
setCombinedTool
{ "repo_name": "iCarto/siga", "path": "libFMap/src/com/iver/cit/gvsig/fmap/MapControl.java", "license": "gpl-3.0", "size": 69175 }
[ "com.iver.cit.gvsig.fmap.tools.Behavior", "com.iver.cit.gvsig.fmap.tools.CompoundBehavior" ]
import com.iver.cit.gvsig.fmap.tools.Behavior; import com.iver.cit.gvsig.fmap.tools.CompoundBehavior;
import com.iver.cit.gvsig.fmap.tools.*;
[ "com.iver.cit" ]
com.iver.cit;
1,477,112
Location getWhere();
Location getWhere();
/** * Get the location where the action is taking place. * * @return the where */
Get the location where the action is taking place
getWhere
{ "repo_name": "oskopek/TransportEditor", "path": "transport-core/src/main/java/com/oskopek/transport/model/domain/action/Action.java", "license": "mit", "size": 3028 }
[ "com.oskopek.transport.model.problem.Location" ]
import com.oskopek.transport.model.problem.Location;
import com.oskopek.transport.model.problem.*;
[ "com.oskopek.transport" ]
com.oskopek.transport;
371,955
public static void stop(QueueNetwork Network) throws jmt.common.exception.NetException { NetNode node; if (Network.getState() == QueueNetwork.STATE_RUNNING) { ListIterator<NetNode> nodes = Network.getNodes().listIterator(); while (nodes.hasNext()) { node = nodes.next(); node.send(NetEvent.EVEN...
static void function(QueueNetwork Network) throws jmt.common.exception.NetException { NetNode node; if (Network.getState() == QueueNetwork.STATE_RUNNING) { ListIterator<NetNode> nodes = Network.getNodes().listIterator(); while (nodes.hasNext()) { node = nodes.next(); node.send(NetEvent.EVENT_STOP, null, 0.0, NodeSectio...
/** Stops the NetSystem Engine and terminates the simulation. * @param Network Reference to the netowrk to be stopped. * @throws jmt.common.exception.NetException */
Stops the NetSystem Engine and terminates the simulation
stop
{ "repo_name": "HOMlab/QN-ACTR-Release", "path": "QN-ACTR Java/src/jmt/engine/QueueNet/NetSystem.java", "license": "lgpl-3.0", "size": 10620 }
[ "java.util.ListIterator" ]
import java.util.ListIterator;
import java.util.*;
[ "java.util" ]
java.util;
60,076
public boolean isValidAlias(String alias) { Preconditions.checkNotNull(alias); for (final String s : this.aliases) if (s.equalsIgnoreCase(alias)) return true; return nameLookup.containsValue(alias); }
boolean function(String alias) { Preconditions.checkNotNull(alias); for (final String s : this.aliases) if (s.equalsIgnoreCase(alias)) return true; return nameLookup.containsValue(alias); }
/** * Determines if the given alias is a valid alias for any supported OS'. If * the alias is not a registered alias or name of an OS then false is returned. * * @param alias Name Alias * @return True if valid OS, otherwise false. */
Determines if the given alias is a valid alias for any supported OS'. If the alias is not a registered alias or name of an OS then false is returned
isValidAlias
{ "repo_name": "Matt529/CCAutotyper", "path": "src/com/mattc/autotyper/util/OS.java", "license": "gpl-3.0", "size": 17674 }
[ "com.google.common.base.Preconditions" ]
import com.google.common.base.Preconditions;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
1,661,257
public static int checkedMultiply(int a, int b) { long result = (long) a * b; checkNoOverflow(result == (int) result); return (int) result; }
static int function(int a, int b) { long result = (long) a * b; checkNoOverflow(result == (int) result); return (int) result; }
/** * Returns the product of {@code a} and {@code b}, provided it does not overflow. * * @throws ArithmeticException if {@code a * b} overflows in signed {@code int} arithmetic */
Returns the product of a and b, provided it does not overflow
checkedMultiply
{ "repo_name": "10xEngineer/My-Wallet-Android", "path": "src/com/google/common/math/IntMath.java", "license": "gpl-3.0", "size": 18313 }
[ "com.google.common.math.MathPreconditions" ]
import com.google.common.math.MathPreconditions;
import com.google.common.math.*;
[ "com.google.common" ]
com.google.common;
2,053,717
public static IWorkingCopyManager getWorkingCopyManager() { return JavaPlugin.getDefault().getWorkingCopyManager(); }
static IWorkingCopyManager function() { return JavaPlugin.getDefault().getWorkingCopyManager(); }
/** * Returns the working copy manager for the Java UI plug-in. * * @return the working copy manager for the Java UI plug-in */
Returns the working copy manager for the Java UI plug-in
getWorkingCopyManager
{ "repo_name": "trylimits/Eclipse-Postfix-Code-Completion", "path": "luna/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java", "license": "epl-1.0", "size": 45169 }
[ "org.eclipse.jdt.internal.ui.JavaPlugin" ]
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.*;
[ "org.eclipse.jdt" ]
org.eclipse.jdt;
1,614,877
public SignificantTermsBuilder include(String regex, int flags) { if (includeTerms != null) { throw new ElasticsearchIllegalArgumentException("exclude clause must be an array of strings or a regex, not both"); } this.includePattern = regex; this.includeFlags = flags; ...
SignificantTermsBuilder function(String regex, int flags) { if (includeTerms != null) { throw new ElasticsearchIllegalArgumentException(STR); } this.includePattern = regex; this.includeFlags = flags; return this; }
/** * Define a regular expression that will determine what terms should be aggregated. The regular expression is based * on the {@link java.util.regex.Pattern} class. * * @see java.util.regex.Pattern#compile(String, int) */
Define a regular expression that will determine what terms should be aggregated. The regular expression is based on the <code>java.util.regex.Pattern</code> class
include
{ "repo_name": "dantuffery/elasticsearch", "path": "src/main/java/org/elasticsearch/search/aggregations/bucket/significant/SignificantTermsBuilder.java", "license": "apache-2.0", "size": 10047 }
[ "org.elasticsearch.ElasticsearchIllegalArgumentException" ]
import org.elasticsearch.ElasticsearchIllegalArgumentException;
import org.elasticsearch.*;
[ "org.elasticsearch" ]
org.elasticsearch;
2,459,310
@Nullable public static String javaScriptEscapeForRegEx (@Nullable final String sInput) { if (StringHelper.hasNoText (sInput)) return sInput; final char [] aInput = sInput.toCharArray (); if (!StringHelper.containsAny (aInput, CHARS_TO_MASK_REGEX)) return sInput; // At last each char...
static String function (@Nullable final String sInput) { if (StringHelper.hasNoText (sInput)) return sInput; final char [] aInput = sInput.toCharArray (); if (!StringHelper.containsAny (aInput, CHARS_TO_MASK_REGEX)) return sInput; final char [] ret = new char [aInput.length * 2]; int nIndex = 0; for (final char cCurren...
/** * Turn special regular expression characters into escaped characters * conforming to JavaScript.<br> * Reference: <a href= * "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions" * >MDN Regular Expressions</a> * * @param sInput * the input string * @re...
Turn special regular expression characters into escaped characters conforming to JavaScript. Reference: MDN Regular Expressions
javaScriptEscapeForRegEx
{ "repo_name": "phax/ph-oton", "path": "ph-oton-html/src/main/java/com/helger/html/js/JSMarshaller.java", "license": "apache-2.0", "size": 12508 }
[ "com.helger.commons.collection.ArrayHelper", "com.helger.commons.string.StringHelper", "javax.annotation.Nullable" ]
import com.helger.commons.collection.ArrayHelper; import com.helger.commons.string.StringHelper; import javax.annotation.Nullable;
import com.helger.commons.collection.*; import com.helger.commons.string.*; import javax.annotation.*;
[ "com.helger.commons", "javax.annotation" ]
com.helger.commons; javax.annotation;
771,818
public void constructTraceFile(String filename){ TraceEntryTree tree = TraceEntryTree.generateTraceEntryTree(lines); String tracePath = "data" + File.separatorChar + "traces" + File.separatorChar; FileWriter writer; try { String json = TraceToJSON.generateJSON(tree); writer = new FileWriter(tracePath +...
void function(String filename){ TraceEntryTree tree = TraceEntryTree.generateTraceEntryTree(lines); String tracePath = "data" + File.separatorChar + STR + File.separatorChar; FileWriter writer; try { String json = TraceToJSON.generateJSON(tree); writer = new FileWriter(tracePath + filename + STR); writer.write(json); w...
/** * Writes the Trace to a JSONFile * * @param The name of the file to write the trace to * */
Writes the Trace to a JSONFile
constructTraceFile
{ "repo_name": "davidstreader/JavaAutomata", "path": "src/main/tracer/Trace.java", "license": "gpl-2.0", "size": 2102 }
[ "java.io.File", "java.io.FileWriter", "java.io.IOException" ]
import java.io.File; import java.io.FileWriter; import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
924,502
private HL7InQueueProcessor getHL7InQueueProcessor() { if (processor == null) { processor = new HL7InQueueProcessor(); } return processor; }
HL7InQueueProcessor function() { if (processor == null) { processor = new HL7InQueueProcessor(); } return processor; }
/** * Get the HL7 In queue queue processor. * * @return an instance of the HL7 In queue processor */
Get the HL7 In queue queue processor
getHL7InQueueProcessor
{ "repo_name": "sintjuri/openmrs-core", "path": "web/src/main/java/org/openmrs/hl7/web/HL7InQueueProcessorServlet.java", "license": "mpl-2.0", "size": 2116 }
[ "org.openmrs.hl7.HL7InQueueProcessor" ]
import org.openmrs.hl7.HL7InQueueProcessor;
import org.openmrs.hl7.*;
[ "org.openmrs.hl7" ]
org.openmrs.hl7;
2,023,272
private void handleSetHtmlTitle(Object obj){ ActionBar actionBar = getActionBar(); if (actionBar == null){ return; } actionBar.setTitle(Html.fromHtml((String) obj)); }
void function(Object obj){ ActionBar actionBar = getActionBar(); if (actionBar == null){ return; } actionBar.setTitle(Html.fromHtml((String) obj)); }
/** * Sets Actionbar html title * @param obj */
Sets Actionbar html title
handleSetHtmlTitle
{ "repo_name": "konstantinbueschel/actionbarextras", "path": "src/com/alcoapps/actionbarextras/ActionbarextrasModule.java", "license": "mit", "size": 44033 }
[ "android.support.v7.app.ActionBar", "android.text.Html" ]
import android.support.v7.app.ActionBar; import android.text.Html;
import android.support.v7.app.*; import android.text.*;
[ "android.support", "android.text" ]
android.support; android.text;
89,358
private String probsToString(Vector<Double> probs) { StringBuffer txt = new StringBuffer(" "); for (int i = 0; i < probs.size(); i++) { txt.append("" + (probs.elementAt(i)).doubleValue() + " "); } return txt.toString(); }
String function(Vector<Double> probs) { StringBuffer txt = new StringBuffer(" "); for (int i = 0; i < probs.size(); i++) { txt.append(STR "); } return txt.toString(); }
/** * Print the probabilities after testing * * @param probs vector with probability values * @return string with probability values printed */
Print the probabilities after testing
probsToString
{ "repo_name": "umple/umple", "path": "Umplificator/UmplifiedProjects/weka-umplified-0/src/main/java/weka/estimators/CheckEstimator.java", "license": "mit", "size": 64280 }
[ "java.util.Vector" ]
import java.util.Vector;
import java.util.*;
[ "java.util" ]
java.util;
2,817,037
private static void checkNotSyntheticConstructor(Tree tree) { if (tree instanceof MethodTree && ASTHelpers.isGeneratedConstructor((MethodTree) tree)) { throw new IllegalArgumentException("Cannot edit synthetic AST nodes"); } } }
static void function(Tree tree) { if (tree instanceof MethodTree && ASTHelpers.isGeneratedConstructor((MethodTree) tree)) { throw new IllegalArgumentException(STR); } } }
/** * Prevent attempts to modify implicit default constructurs, since they are one of the few * synthetic constructs added to the AST early enough to be visible from Error Prone. */
Prevent attempts to modify implicit default constructurs, since they are one of the few synthetic constructs added to the AST early enough to be visible from Error Prone
checkNotSyntheticConstructor
{ "repo_name": "google/error-prone", "path": "check_api/src/main/java/com/google/errorprone/fixes/SuggestedFix.java", "license": "apache-2.0", "size": 14169 }
[ "com.google.errorprone.util.ASTHelpers", "com.sun.source.tree.MethodTree", "com.sun.source.tree.Tree" ]
import com.google.errorprone.util.ASTHelpers; import com.sun.source.tree.MethodTree; import com.sun.source.tree.Tree;
import com.google.errorprone.util.*; import com.sun.source.tree.*;
[ "com.google.errorprone", "com.sun.source" ]
com.google.errorprone; com.sun.source;
2,806,635
@Test public void testNegativeNullName() throws Exception { assertFalse(new AddBudgetVersionEvent("", (Document) proposal, (String)null).invokeRuleMethod(new BudgetVersionRule())); }
void function() throws Exception { assertFalse(new AddBudgetVersionEvent("", (Document) proposal, (String)null).invokeRuleMethod(new BudgetVersionRule())); }
/** * * This method tests the Null Name field (a.k.a. documentDescription/newBudgetVersionName) negative case. * @throws Exception */
This method tests the Null Name field (a.k.a. documentDescription/newBudgetVersionName) negative case
testNegativeNullName
{ "repo_name": "blackcathacker/kc.preclean", "path": "coeus-code/src/test/java/org/kuali/kra/proposaldevelopment/rules/BudgetVersionRuleTest.java", "license": "apache-2.0", "size": 5086 }
[ "org.junit.Assert", "org.kuali.coeus.common.budget.framework.version.AddBudgetVersionEvent", "org.kuali.coeus.common.budget.impl.version.BudgetVersionRule", "org.kuali.rice.krad.document.Document" ]
import org.junit.Assert; import org.kuali.coeus.common.budget.framework.version.AddBudgetVersionEvent; import org.kuali.coeus.common.budget.impl.version.BudgetVersionRule; import org.kuali.rice.krad.document.Document;
import org.junit.*; import org.kuali.coeus.common.budget.framework.version.*; import org.kuali.coeus.common.budget.impl.version.*; import org.kuali.rice.krad.document.*;
[ "org.junit", "org.kuali.coeus", "org.kuali.rice" ]
org.junit; org.kuali.coeus; org.kuali.rice;
1,668,719
public okhttp3.Call getIdentityLinksAsync(String id, String type, final ApiCallback<List<IdentityLinkDto>> _callback) throws ApiException { okhttp3.Call localVarCall = getIdentityLinksValidateBeforeCall(id, type, _callback); Type localVarReturnType = new TypeToken<List<IdentityLinkDto>>(){}.getType...
okhttp3.Call function(String id, String type, final ApiCallback<List<IdentityLinkDto>> _callback) throws ApiException { okhttp3.Call localVarCall = getIdentityLinksValidateBeforeCall(id, type, _callback); Type localVarReturnType = new TypeToken<List<IdentityLinkDto>>(){}.getType(); localVarApiClient.executeAsync(localV...
/** * (asynchronously) * Gets the identity links for a task by id, which are the users and groups that are in *some* relation to it (including assignee and owner). * @param id The id of the task to retrieve the identity links for. (required) * @param type Filter by the type of links to include. (op...
(asynchronously) Gets the identity links for a task by id, which are the users and groups that are in *some* relation to it (including assignee and owner)
getIdentityLinksAsync
{ "repo_name": "camunda/camunda-consulting", "path": "snippets/camunda-openapi-client/camunda-openapi-client/src/gen/java/main/com/camunda/consulting/openapi/client/handler/TaskIdentityLinkApi.java", "license": "apache-2.0", "size": 21538 }
[ "com.camunda.consulting.openapi.client.handler.ApiCallback", "com.camunda.consulting.openapi.client.handler.ApiException", "com.camunda.consulting.openapi.client.model.IdentityLinkDto", "com.google.gson.reflect.TypeToken", "java.lang.reflect.Type", "java.util.List" ]
import com.camunda.consulting.openapi.client.handler.ApiCallback; import com.camunda.consulting.openapi.client.handler.ApiException; import com.camunda.consulting.openapi.client.model.IdentityLinkDto; import com.google.gson.reflect.TypeToken; import java.lang.reflect.Type; import java.util.List;
import com.camunda.consulting.openapi.client.handler.*; import com.camunda.consulting.openapi.client.model.*; import com.google.gson.reflect.*; import java.lang.reflect.*; import java.util.*;
[ "com.camunda.consulting", "com.google.gson", "java.lang", "java.util" ]
com.camunda.consulting; com.google.gson; java.lang; java.util;
2,455,768
public void testJoinTableSetCreationComposite() throws Exception { try { perform1toNJoinTableSetCreationComposite(); } finally { clean(AbstractCompositeClassHolder.class); clean(AbstractCompositeBase.class); c...
void function() throws Exception { try { perform1toNJoinTableSetCreationComposite(); } finally { clean(AbstractCompositeClassHolder.class); clean(AbstractCompositeBase.class); clean(ConcreteCompositeSub1.class); clean(ConcreteCompositeSub2.class); } }
/** * Test for having abstract elements in a join-table Set, and creating container/elements. */
Test for having abstract elements in a join-table Set, and creating container/elements
testJoinTableSetCreationComposite
{ "repo_name": "hopecee/texsts", "path": "jdo/identity/src/test/org/datanucleus/tests/application/AbstractClassesTest.java", "license": "apache-2.0", "size": 24747 }
[ "org.jpox.samples.abstractclasses.AbstractCompositeBase", "org.jpox.samples.abstractclasses.AbstractCompositeClassHolder", "org.jpox.samples.abstractclasses.ConcreteCompositeSub1", "org.jpox.samples.abstractclasses.ConcreteCompositeSub2" ]
import org.jpox.samples.abstractclasses.AbstractCompositeBase; import org.jpox.samples.abstractclasses.AbstractCompositeClassHolder; import org.jpox.samples.abstractclasses.ConcreteCompositeSub1; import org.jpox.samples.abstractclasses.ConcreteCompositeSub2;
import org.jpox.samples.abstractclasses.*;
[ "org.jpox.samples" ]
org.jpox.samples;
2,774,250
public static synchronized void printStatistics() throws IOException { for (Map.Entry<Class<? extends FileSystem>, Statistics> pair: statisticsTable.entrySet()) { System.out.println(" FileSystem " + pair.getKey().getName() + ": " + pair.getValue()); } } // ...
static synchronized void function() throws IOException { for (Map.Entry<Class<? extends FileSystem>, Statistics> pair: statisticsTable.entrySet()) { System.out.println(STR + pair.getKey().getName() + STR + pair.getValue()); } } private static boolean symlinksEnabled = false; private static Configuration conf = null;
/** * Print all statistics for all file systems */
Print all statistics for all file systems
printStatistics
{ "repo_name": "joyghosh/hadoop", "path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java", "license": "gpl-3.0", "size": 116427 }
[ "java.io.IOException", "java.util.Map", "org.apache.hadoop.conf.Configuration" ]
import java.io.IOException; import java.util.Map; import org.apache.hadoop.conf.Configuration;
import java.io.*; import java.util.*; import org.apache.hadoop.conf.*;
[ "java.io", "java.util", "org.apache.hadoop" ]
java.io; java.util; org.apache.hadoop;
1,307,835
public static boolean makeDirs(String filePath) { String folderName = getFolderName(filePath); if (StringUtils.isEmpty(folderName)) { return false; } File folder = new File(folderName); return (folder.exists() && folder.isDirectory()) || folder.mkdirs(); }
static boolean function(String filePath) { String folderName = getFolderName(filePath); if (StringUtils.isEmpty(folderName)) { return false; } File folder = new File(folderName); return (folder.exists() && folder.isDirectory()) folder.mkdirs(); }
/** * Creates the directory named by the trailing filename of this file, including the complete directory path required * to create this directory. <br/> * <br/> * <ul> * <strong>Attentions:</strong> * <li>makeDirs("C:\\Users\\Trinea") can only create users folder</li> * <li>makeFolde...
Creates the directory named by the trailing filename of this file, including the complete directory path required to create this directory. Attentions:
makeDirs
{ "repo_name": "flylzd/FreeCSDN", "path": "kocore/src/main/java/com/lemon/library/kocore/utils/IOUtils.java", "license": "apache-2.0", "size": 56063 }
[ "java.io.File" ]
import java.io.File;
import java.io.*;
[ "java.io" ]
java.io;
716,767
@ServiceMethod(returns = ReturnType.SINGLE) private Mono<Response<List<VirtualMachineExtensionImageInner>>> listTypesWithResponseAsync( String location, String publisherName, Context context) { if (this.client.getEndpoint() == null) { return Mono .error( ...
@ServiceMethod(returns = ReturnType.SINGLE) Mono<Response<List<VirtualMachineExtensionImageInner>>> function( String location, String publisherName, Context context) { if (this.client.getEndpoint() == null) { return Mono .error( new IllegalArgumentException( STR)); } if (location == null) { return Mono.error(new Illega...
/** * Gets a list of virtual machine extension image types. * * @param location The name of a supported Azure region. * @param publisherName The publisherName parameter. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters f...
Gets a list of virtual machine extension image types
listTypesWithResponseAsync
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/resourcemanager/azure-resourcemanager-compute/src/main/java/com/azure/resourcemanager/compute/implementation/VirtualMachineExtensionImagesClientImpl.java", "license": "mit", "size": 31356 }
[ "com.azure.core.annotation.ReturnType", "com.azure.core.annotation.ServiceMethod", "com.azure.core.http.rest.Response", "com.azure.core.util.Context", "com.azure.resourcemanager.compute.fluent.models.VirtualMachineExtensionImageInner", "java.util.List" ]
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.compute.fluent.models.VirtualMachineExtensionImageInner; import java.util.List;
import com.azure.core.annotation.*; import com.azure.core.http.rest.*; import com.azure.core.util.*; import com.azure.resourcemanager.compute.fluent.models.*; import java.util.*;
[ "com.azure.core", "com.azure.resourcemanager", "java.util" ]
com.azure.core; com.azure.resourcemanager; java.util;
726,385
public void setRotationAngles(float p_78087_1_, float p_78087_2_, float p_78087_3_, float p_78087_4_, float p_78087_5_, float p_78087_6_, Entity p_78087_7_) { super.setRotationAngles(p_78087_1_, p_78087_2_, p_78087_3_, p_78087_4_, p_78087_5_, p_78087_6_, p_78087_7_); if (this.headModel != null) { for (Mode...
void function(float p_78087_1_, float p_78087_2_, float p_78087_3_, float p_78087_4_, float p_78087_5_, float p_78087_6_, Entity p_78087_7_) { super.setRotationAngles(p_78087_1_, p_78087_2_, p_78087_3_, p_78087_4_, p_78087_5_, p_78087_6_, p_78087_7_); if (this.headModel != null) { for (ModelRendererTurbo part : this.he...
/** * Sets the model's various rotation angles. For bipeds, par1 and par2 are used for animating the movement of arms * and legs, where par1 represents the time(so that arms and legs swing back and forth) and par2 represents how * "far" arms and legs can swing at most. */
Sets the model's various rotation angles. For bipeds, par1 and par2 are used for animating the movement of arms and legs, where par1 represents the time(so that arms and legs swing back and forth) and par2 represents how "far" arms and legs can swing at most
setRotationAngles
{ "repo_name": "KILLER-CHIEF/Halocraft-KCWM", "path": "java/net/killerchief/halocraft/client/models/armor/ModelArmorVisor.java", "license": "gpl-2.0", "size": 5229 }
[ "net.killerchief.turbomodelthingy.ModelRendererTurbo", "net.minecraft.entity.Entity" ]
import net.killerchief.turbomodelthingy.ModelRendererTurbo; import net.minecraft.entity.Entity;
import net.killerchief.turbomodelthingy.*; import net.minecraft.entity.*;
[ "net.killerchief.turbomodelthingy", "net.minecraft.entity" ]
net.killerchief.turbomodelthingy; net.minecraft.entity;
1,072,124
protected boolean canSeeColumnFamily(Key key) { boolean visible = true; if (seekColumnFamilies != null) { ByteSequence columnFamily = key.getColumnFamilyData(); if (seekColumnFamiliesInclusive) visible = seekColumnFamilies.contains(columnFamily); else visible = !seekColumnFam...
boolean function(Key key) { boolean visible = true; if (seekColumnFamilies != null) { ByteSequence columnFamily = key.getColumnFamilyData(); if (seekColumnFamiliesInclusive) visible = seekColumnFamilies.contains(columnFamily); else visible = !seekColumnFamilies.contains(columnFamily); } return visible; }
/** * Indicates whether or not {@code key} can be seen, according to the fetched column families for * this iterator. * * @param key * the key whose column family is to be tested * @return {@code true} if {@code key}'s column family is one of those fetched in the set passed * to ou...
Indicates whether or not key can be seen, according to the fetched column families for this iterator
canSeeColumnFamily
{ "repo_name": "phrocker/accumulo-1", "path": "core/src/main/java/org/apache/accumulo/core/iterators/user/TransformingIterator.java", "license": "apache-2.0", "size": 30130 }
[ "org.apache.accumulo.core.data.ByteSequence", "org.apache.accumulo.core.data.Key" ]
import org.apache.accumulo.core.data.ByteSequence; import org.apache.accumulo.core.data.Key;
import org.apache.accumulo.core.data.*;
[ "org.apache.accumulo" ]
org.apache.accumulo;
2,569,067
@Override public void notifyChanged(Notification notification) { updateChildren(notification); super.notifyChanged(notification); }
void function(Notification notification) { updateChildren(notification); super.notifyChanged(notification); }
/** * This handles model notifications by calling {@link #updateChildren} to update any cached * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */
This handles model notifications by calling <code>#updateChildren</code> to update any cached children and by creating a viewer notification, which it passes to <code>#fireNotifyChanged</code>.
notifyChanged
{ "repo_name": "diverse-project/k3", "path": "k3-samples-incomplete/cellular_automata/org.kermeta.language.sample.cellularautomata.geometry.model.edit/src/geometry/provider/GeometryItemProvider.java", "license": "epl-1.0", "size": 2921 }
[ "org.eclipse.emf.common.notify.Notification" ]
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
1,850,976
// <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 { processRequest(request, response); ...
void function(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { processRequest(request, response); }
/** * 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": "ccsu-cs416F15/CS416ClassDemos", "path": "HW2Soln/src/java/edu/ccsu/hw2soln/AjaxVotesServlet.java", "license": "mit", "size": 2827 }
[ "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,690,936
public static <T> T toObject(String jsonString, Class<?> targetClass) throws IOException { Assert.notNull("targetClass", targetClass); try { return UtilGenerics.cast(mapper.readValue(jsonString, targetClass)); } catch (IOException e) { throw e; } catch (Except...
static <T> T function(String jsonString, Class<?> targetClass) throws IOException { Assert.notNull(STR, targetClass); try { return UtilGenerics.cast(mapper.readValue(jsonString, targetClass)); } catch (IOException e) { throw e; } catch (Exception e) { throw new IOException(e); } }
/** * Converts the given json string to the specified type. * <p>SCIPIO: 2.1.0: Added to support avoiding this class.</p> * @param targetClass * @return an object of the specified type * @throws IOException */
Converts the given json string to the specified type
toObject
{ "repo_name": "ilscipio/scipio-erp", "path": "framework/base/src/org/ofbiz/base/lang/JSON.java", "license": "apache-2.0", "size": 5057 }
[ "java.io.IOException", "org.ofbiz.base.util.Assert", "org.ofbiz.base.util.UtilGenerics" ]
import java.io.IOException; import org.ofbiz.base.util.Assert; import org.ofbiz.base.util.UtilGenerics;
import java.io.*; import org.ofbiz.base.util.*;
[ "java.io", "org.ofbiz.base" ]
java.io; org.ofbiz.base;
709,741
@Override protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) { super.collectNewChildDescriptors(newChildDescriptors, object); }
void function(Collection<Object> newChildDescriptors, Object object) { super.collectNewChildDescriptors(newChildDescriptors, object); }
/** * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children * that can be created under this object. * <!-- begin-user-doc --> * <!-- end-user-doc --> * * @generated */
This adds <code>org.eclipse.emf.edit.command.CommandParameter</code>s describing the children that can be created under this object.
collectNewChildDescriptors
{ "repo_name": "ylussaud/M2Doc", "path": "plugins/org.obeonetwork.m2doc.genconf.edit/src-gen/org/obeonetwork/m2doc/genconf/provider/IntegerDefinitionItemProvider.java", "license": "epl-1.0", "size": 4551 }
[ "java.util.Collection" ]
import java.util.Collection;
import java.util.*;
[ "java.util" ]
java.util;
2,062,555
@Message(id = 310, value = "duration cannot be negative while creating single action timer") IllegalArgumentException invalidDurationActionTimer();
@Message(id = 310, value = STR) IllegalArgumentException invalidDurationActionTimer();
/** * Creates an exception indicating duration cannot be negative while creating single action timer * * @return an {@link IllegalArgumentException} for the error. */
Creates an exception indicating duration cannot be negative while creating single action timer
invalidDurationActionTimer
{ "repo_name": "golovnin/wildfly", "path": "ejb3/src/main/java/org/jboss/as/ejb3/logging/EjbLogger.java", "license": "lgpl-2.1", "size": 147179 }
[ "org.jboss.logging.annotations.Message" ]
import org.jboss.logging.annotations.Message;
import org.jboss.logging.annotations.*;
[ "org.jboss.logging" ]
org.jboss.logging;
1,150,676
public Set<TaskId> cachedTasksIds() { // A client could contain some inactive tasks whose states are still kept on the local storage in the following scenarios: // 1) the client is actively maintaining standby tasks by maintaining their states from the change log. // 2) the client has just g...
Set<TaskId> function() { final HashSet<TaskId> tasks = new HashSet<>(); final File[] stateDirs = taskCreator.stateDirectory().listTaskDirectories(); if (stateDirs != null) { for (final File dir : stateDirs) { try { final TaskId id = TaskId.parse(dir.getName()); if (new File(dir, ProcessorStateManager.CHECKPOINT_FILE_NA...
/** * Returns ids of tasks whose states are kept on the local storage. */
Returns ids of tasks whose states are kept on the local storage
cachedTasksIds
{ "repo_name": "gf53520/kafka", "path": "streams/src/main/java/org/apache/kafka/streams/processor/internals/TaskManager.java", "license": "apache-2.0", "size": 19253 }
[ "java.io.File", "java.util.HashSet", "java.util.Set", "org.apache.kafka.streams.errors.TaskIdFormatException", "org.apache.kafka.streams.processor.TaskId" ]
import java.io.File; import java.util.HashSet; import java.util.Set; import org.apache.kafka.streams.errors.TaskIdFormatException; import org.apache.kafka.streams.processor.TaskId;
import java.io.*; import java.util.*; import org.apache.kafka.streams.errors.*; import org.apache.kafka.streams.processor.*;
[ "java.io", "java.util", "org.apache.kafka" ]
java.io; java.util; org.apache.kafka;
1,016,395
private String locateNextString (String current) { LinkedList<String> keys = new LinkedList<String>(); keys.addAll(slides.keySet()); Iterator<String> iter = keys.iterator(); // Null sanity check if (keys.size() == 0) { return null; } // Check if ...
String function (String current) { LinkedList<String> keys = new LinkedList<String>(); keys.addAll(slides.keySet()); Iterator<String> iter = keys.iterator(); if (keys.size() == 0) { return null; } if (current == null) { if (keys.size() == 0) { return null; } else { return keys.get(0); } } while (iter.hasNext() && !iter...
/** * Returns the String key in <code>slides</code> next in iteration order after the given one. If we're at the last entry, or <code>slides</code> does not contain the given key, returns the first key. If there are no keys, returns null. * * @param current the current String * @return the String a...
Returns the String key in <code>slides</code> next in iteration order after the given one. If we're at the last entry, or <code>slides</code> does not contain the given key, returns the first key. If there are no keys, returns null
locateNextString
{ "repo_name": "MathSquared/ResultsWizard2", "path": "ResultsWizard2/src/mathsquared/resultswizard2/ProtocolSelector.java", "license": "mit", "size": 10089 }
[ "java.util.Iterator", "java.util.LinkedList" ]
import java.util.Iterator; import java.util.LinkedList;
import java.util.*;
[ "java.util" ]
java.util;
735,281
static Class<?> javaxToolsJavac(String packageName, String className, String source) { String fullClassName = packageName + "." + className; StringWriter writer = new StringWriter(); JavaFileManager fileManager = new ClassFileManager(JAVA_COMPILER .getStan...
static Class<?> javaxToolsJavac(String packageName, String className, String source) { String fullClassName = packageName + "." + className; StringWriter writer = new StringWriter(); JavaFileManager fileManager = new ClassFileManager(JAVA_COMPILER .getStandardFileManager(null, null, null)); ArrayList<JavaFileObject> co...
/** * Compile using the standard java compiler. * * @param packageName the package name * @param className the class name * @param source the source code * @return the class */
Compile using the standard java compiler
javaxToolsJavac
{ "repo_name": "florianerhard/gedi", "path": "GediCore/src/gedi/util/orm/CompilerTool.java", "license": "apache-2.0", "size": 14051 }
[ "java.io.StringWriter", "java.util.ArrayList", "javax.tools.JavaFileManager", "javax.tools.JavaFileObject" ]
import java.io.StringWriter; import java.util.ArrayList; import javax.tools.JavaFileManager; import javax.tools.JavaFileObject;
import java.io.*; import java.util.*; import javax.tools.*;
[ "java.io", "java.util", "javax.tools" ]
java.io; java.util; javax.tools;
1,960,938
public ServiceFuture<Void> deleteAsync(String resourceGroupName, String sqlVirtualMachineGroupName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, sqlVirtualMachineGroupName), serviceCallback); }
ServiceFuture<Void> function(String resourceGroupName, String sqlVirtualMachineGroupName, final ServiceCallback<Void> serviceCallback) { return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, sqlVirtualMachineGroupName), serviceCallback); }
/** * Deletes a SQL virtual machine group. * * @param resourceGroupName Name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal. * @param sqlVirtualMachineGroupName Name of the SQL virtual machine group. * @param service...
Deletes a SQL virtual machine group
deleteAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/sqlvirtualmachine/mgmt-v2017_03_01_preview/src/main/java/com/microsoft/azure/management/sqlvirtualmachine/v2017_03_01_preview/implementation/SqlVirtualMachineGroupsInner.java", "license": "mit", "size": 82749 }
[ "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceFuture" ]
import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceFuture;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
526,108
@Override public boolean supports(PortalEvent event) { return false; }
boolean function(PortalEvent event) { return false; }
/** * Check if the converter supports the specific event. Subclassess * should override. * * @param event the event to check * @return false */
Check if the converter supports the specific event. Subclassess should override
supports
{ "repo_name": "timlevett/uPortal", "path": "uportal-war/src/main/java/org/jasig/portal/events/tincan/converters/AbstractPortalEventToLrsStatementConverter.java", "license": "apache-2.0", "size": 4232 }
[ "org.jasig.portal.events.PortalEvent" ]
import org.jasig.portal.events.PortalEvent;
import org.jasig.portal.events.*;
[ "org.jasig.portal" ]
org.jasig.portal;
605,107
public void startPrefixMapping (String prefix, String uri) throws SAXException { if (contentHandler != null) { contentHandler.startPrefixMapping(prefix, uri); } }
void function (String prefix, String uri) throws SAXException { if (contentHandler != null) { contentHandler.startPrefixMapping(prefix, uri); } }
/** * Filter a start Namespace prefix mapping event. * * @param prefix The Namespace prefix. * @param uri The Namespace URI. * @exception org.xml.sax.SAXException The client may throw * an exception during processing. */
Filter a start Namespace prefix mapping event
startPrefixMapping
{ "repo_name": "FauxFaux/jdk9-jaxp", "path": "src/java.xml/share/classes/org/xml/sax/helpers/XMLFilterImpl.java", "license": "gpl-2.0", "size": 21751 }
[ "org.xml.sax.SAXException" ]
import org.xml.sax.SAXException;
import org.xml.sax.*;
[ "org.xml.sax" ]
org.xml.sax;
1,474,403
interface WithVirtualNetworkRules { WithCreate withVirtualNetworkRules(List<VirtualNetworkRule> virtualNetworkRules); } interface WithCreate extends Creatable<DatabaseAccount>, Resource.DefinitionWithTags<WithCreate>, DefinitionStages.WithCapabilities, Definiti...
interface WithVirtualNetworkRules { WithCreate withVirtualNetworkRules(List<VirtualNetworkRule> virtualNetworkRules); } interface WithCreate extends Creatable<DatabaseAccount>, Resource.DefinitionWithTags<WithCreate>, DefinitionStages.WithCapabilities, DefinitionStages.WithConnectorOffer, DefinitionStages.WithConsisten...
/** * Specifies virtualNetworkRules. * @param virtualNetworkRules List of Virtual Network ACL rules configured for the Cosmos DB account * @return the next definition stage */
Specifies virtualNetworkRules
withVirtualNetworkRules
{ "repo_name": "navalev/azure-sdk-for-java", "path": "sdk/cosmosdb/mgmt-v2015_04_08/src/main/java/com/microsoft/azure/management/cosmosdb/v2015_04_08/DatabaseAccount.java", "license": "mit", "size": 11567 }
[ "com.microsoft.azure.arm.model.Appliable", "com.microsoft.azure.arm.model.Creatable", "com.microsoft.azure.arm.resources.models.Resource", "java.util.List" ]
import com.microsoft.azure.arm.model.Appliable; import com.microsoft.azure.arm.model.Creatable; import com.microsoft.azure.arm.resources.models.Resource; import java.util.List;
import com.microsoft.azure.arm.model.*; import com.microsoft.azure.arm.resources.models.*; import java.util.*;
[ "com.microsoft.azure", "java.util" ]
com.microsoft.azure; java.util;
634,203
private void makePurchase(JSONArray args, CallbackContext callbackContext) throws JSONException { // Retain the callback and wait mMakePurchaseCbContext = callbackContext; retainCallBack(mMakePurchaseCbContext); // Instance the given product Id to be purchase final String productId = args.getString(0); /...
void function(JSONArray args, CallbackContext callbackContext) throws JSONException { mMakePurchaseCbContext = callbackContext; retainCallBack(mMakePurchaseCbContext); final String productId = args.getString(0); mDevPayload = args.optString(1);
/** * Make the Product Purchase * * @param args Product Id to be purchased and DeveloperPayload * @param callbackContext Instance **/
Make the Product Purchase
makePurchase
{ "repo_name": "claydotio/phonegap-plugin-wizPurchase", "path": "platforms/android/src/jp/wizcorp/phonegap/plugin/wizPurchase/WizPurchasePlugin.java", "license": "mit", "size": 26935 }
[ "org.apache.cordova.CallbackContext", "org.json.JSONArray", "org.json.JSONException" ]
import org.apache.cordova.CallbackContext; import org.json.JSONArray; import org.json.JSONException;
import org.apache.cordova.*; import org.json.*;
[ "org.apache.cordova", "org.json" ]
org.apache.cordova; org.json;
2,315,374
public void updateCurrentPosition(CurrentPosition c) { db.updateCurrentPosition(c); }
void function(CurrentPosition c) { db.updateCurrentPosition(c); }
/** * Updates a current position using DatabaseHelper. * * @param c the current position to update */
Updates a current position using DatabaseHelper
updateCurrentPosition
{ "repo_name": "floschu/eREADer", "path": "eREADer/app/src/main/java/at/ac/tuwien/ims/ereader/Services/BookService.java", "license": "gpl-2.0", "size": 18773 }
[ "at.ac.tuwien.ims.ereader.Entities" ]
import at.ac.tuwien.ims.ereader.Entities;
import at.ac.tuwien.ims.ereader.*;
[ "at.ac.tuwien" ]
at.ac.tuwien;
2,674,214
public boolean onLongClickDir(@NonNull View view, @NonNull DirViewHolder viewHolder) { return false; }
boolean function(@NonNull View view, @NonNull DirViewHolder viewHolder) { return false; }
/** * Long clicking a non-selectable item does nothing by default. * * @param view which was long clicked. Not used in default implementation. * @param viewHolder for the clicked view * @return true if the callback consumed the long click, false otherwise. */
Long clicking a non-selectable item does nothing by default
onLongClickDir
{ "repo_name": "spacecowboy/NoNonsense-FilePicker", "path": "library/src/main/java/com/nononsenseapps/filepicker/AbstractFilePickerFragment.java", "license": "mpl-2.0", "size": 34238 }
[ "android.support.annotation.NonNull", "android.view.View" ]
import android.support.annotation.NonNull; import android.view.View;
import android.support.annotation.*; import android.view.*;
[ "android.support", "android.view" ]
android.support; android.view;
2,823,228
private static List<QuestionTag> fetch(Connection connection, boolean distinctTags) throws ApplicationException { List<QuestionTag> result = null; if (!distinctTags) { // build query StringBuilder query = new StringBuilder("SELECT * FROM "); query.append(TagsData...
static List<QuestionTag> function(Connection connection, boolean distinctTags) throws ApplicationException { List<QuestionTag> result = null; if (!distinctTags) { StringBuilder query = new StringBuilder(STR); query.append(TagsDatabaseAccess.TABLE); query.append(";"); } else { StringBuilder query = new StringBuilder(STR...
/** * Fetches an Instance from the Database. * * @return * the Instance * @throws ApplicationException */
Fetches an Instance from the Database
fetch
{ "repo_name": "EEXCESS/cgwap", "path": "src/java/data_access/TagsDatabaseAccess.java", "license": "mit", "size": 15682 }
[ "java.sql.Connection", "java.sql.PreparedStatement", "java.sql.SQLException", "java.util.List" ]
import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.SQLException; import java.util.List;
import java.sql.*; import java.util.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
797,677
public Object removeField(final String iFieldName) { checkForLoading(); checkForFields(); final boolean knownProperty = _fieldValues.containsKey(iFieldName); final Object oldValue = _fieldValues.get(iFieldName); if (knownProperty && _trackingChanges) { // SAVE THE OLD VALUE IN A SE...
Object function(final String iFieldName) { checkForLoading(); checkForFields(); final boolean knownProperty = _fieldValues.containsKey(iFieldName); final Object oldValue = _fieldValues.get(iFieldName); if (knownProperty && _trackingChanges) { if (_fieldOriginalValues == null) _fieldOriginalValues = new HashMap<String, ...
/** * Removes a field. */
Removes a field
removeField
{ "repo_name": "nengxu/OrientDB", "path": "core/src/main/java/com/orientechnologies/orient/core/record/impl/ODocument.java", "license": "apache-2.0", "size": 50521 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
1,002,909
public CTNode getNode(PBLoc loc) { return getNode(loc.terminalId, loc.height); }
CTNode function(PBLoc loc) { return getNode(loc.terminalId, loc.height); }
/** * Returns the node in this tree using the specific PropBank location. * @param loc the PropBank location. * @return the node in this tree using the specific PropBank location. */
Returns the node in this tree using the specific PropBank location
getNode
{ "repo_name": "clearnlp/clearnlp", "path": "src/main/java/com/clearnlp/constituent/CTTree.java", "license": "bsd-2-clause", "size": 11887 }
[ "com.clearnlp.propbank.PBLoc" ]
import com.clearnlp.propbank.PBLoc;
import com.clearnlp.propbank.*;
[ "com.clearnlp.propbank" ]
com.clearnlp.propbank;
1,837,944
public AuthenticatedUser authenticate(MessageContext msgContext);
AuthenticatedUser function(MessageContext msgContext);
/** Authenticate a user from a username/password pair. * * @param msgContext the MessageContext containing authentication info * @return an AuthenticatedUser or null */
Authenticate a user from a username/password pair
authenticate
{ "repo_name": "hugosato/apache-axis", "path": "src/org/apache/axis/security/SecurityProvider.java", "license": "apache-2.0", "size": 1678 }
[ "org.apache.axis.MessageContext" ]
import org.apache.axis.MessageContext;
import org.apache.axis.*;
[ "org.apache.axis" ]
org.apache.axis;
1,802,199
public static Account addTestAccount() { return addTestAccount(DEFAULT_ACCOUNT); }
static Account function() { return addTestAccount(DEFAULT_ACCOUNT); }
/** * Add an account with the default name. */
Add an account with the default name
addTestAccount
{ "repo_name": "endlessm/chromium-browser", "path": "chrome/test/android/javatests/src/org/chromium/chrome/test/util/browser/signin/SigninTestUtil.java", "license": "bsd-3-clause", "size": 8461 }
[ "android.accounts.Account" ]
import android.accounts.Account;
import android.accounts.*;
[ "android.accounts" ]
android.accounts;
162,497
public boolean isResident(Player player);
boolean function(Player player);
/** * Checks if this player is resident. * * @param player the player * @return true, if is resident */
Checks if this player is resident
isResident
{ "repo_name": "Tabinol/FactoidAPI", "path": "src/main/java/me/tabinol/factoidapi/lands/ILand.java", "license": "gpl-3.0", "size": 12685 }
[ "org.bukkit.entity.Player" ]
import org.bukkit.entity.Player;
import org.bukkit.entity.*;
[ "org.bukkit.entity" ]
org.bukkit.entity;
2,836,258
TaskStatus process(); class TaskStatus { private final boolean finished; private final ListenableFuture<Void> continuationFuture; private TaskStatus(boolean finished, ListenableFuture<Void> continuationFuture) { this.finished = finished; this.continu...
TaskStatus process(); class TaskStatus { private final boolean finished; private final ListenableFuture<Void> continuationFuture; private TaskStatus(boolean finished, ListenableFuture<Void> continuationFuture) { this.finished = finished; this.continuationFuture = continuationFuture; }
/** * Process the task either fully, or in part. * * @return a finished status if the task is complete, otherwise includes a continuation future to indicate * when it should be continued to be processed. */
Process the task either fully, or in part
process
{ "repo_name": "ebyhr/presto", "path": "plugin/trino-hive/src/main/java/io/trino/plugin/hive/util/ResumableTask.java", "license": "apache-2.0", "size": 1884 }
[ "com.google.common.util.concurrent.ListenableFuture" ]
import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.*;
[ "com.google.common" ]
com.google.common;
1,913,916
@Message(id = 4, value = "Class not instantiated") IllegalArgumentException classNotInstantiated(@Cause Throwable cause);
@Message(id = 4, value = STR) IllegalArgumentException classNotInstantiated(@Cause Throwable cause);
/** * Creates an exception indicating the class was not instantiated. * * @param cause the cause of the error. * * @return an {@link IllegalArgumentException} for the error. */
Creates an exception indicating the class was not instantiated
classNotInstantiated
{ "repo_name": "xasx/wildfly", "path": "sar/src/main/java/org/jboss/as/service/logging/SarLogger.java", "license": "lgpl-2.1", "size": 9349 }
[ "org.jboss.logging.annotations.Cause", "org.jboss.logging.annotations.Message" ]
import org.jboss.logging.annotations.Cause; import org.jboss.logging.annotations.Message;
import org.jboss.logging.annotations.*;
[ "org.jboss.logging" ]
org.jboss.logging;
2,047,238
private void shortcutDocIdsToLoad(SearchContext context) { final int[] docIdsToLoad; int docsOffset = 0; final Suggest suggest = context.queryResult().suggest(); int numSuggestDocs = 0; final List<CompletionSuggestion> completionSuggestions; if (suggest != null && sug...
void function(SearchContext context) { final int[] docIdsToLoad; int docsOffset = 0; final Suggest suggest = context.queryResult().suggest(); int numSuggestDocs = 0; final List<CompletionSuggestion> completionSuggestions; if (suggest != null && suggest.hasScoreDocs()) { completionSuggestions = suggest.filter(Completion...
/** * Shortcut ids to load, we load only "from" and up to "size". The phase controller * handles this as well since the result is always size * shards for Q_T_F */
Shortcut ids to load, we load only "from" and up to "size". The phase controller handles this as well since the result is always size * shards for Q_T_F
shortcutDocIdsToLoad
{ "repo_name": "jprante/elasticsearch-server", "path": "server/src/main/java/org/elasticsearch/search/SearchService.java", "license": "apache-2.0", "size": 46909 }
[ "java.util.Collections", "java.util.List", "org.apache.lucene.search.TopDocs", "org.elasticsearch.search.suggest.Suggest", "org.elasticsearch.search.suggest.completion.CompletionSuggestion" ]
import java.util.Collections; import java.util.List; import org.apache.lucene.search.TopDocs; import org.elasticsearch.search.suggest.Suggest; import org.elasticsearch.search.suggest.completion.CompletionSuggestion;
import java.util.*; import org.apache.lucene.search.*; import org.elasticsearch.search.suggest.*; import org.elasticsearch.search.suggest.completion.*;
[ "java.util", "org.apache.lucene", "org.elasticsearch.search" ]
java.util; org.apache.lucene; org.elasticsearch.search;
1,006,993
public Timestamp getTimestamp (String columnName, Calendar calendar) throws SQLException { validateResultSet(); return resultSet_.getTimestamp(columnName, calendar); }
Timestamp function (String columnName, Calendar calendar) throws SQLException { validateResultSet(); return resultSet_.getTimestamp(columnName, calendar); }
/** * Returns the value of a column as a java.sql.Timestamp object * using a calendar other than the default. This can be used to * get values from columns with SQL types CHAR, VARCHAR, DATE, * and TIMESTAMP. * * @param columnName The column name. * @param calendar The calendar....
Returns the value of a column as a java.sql.Timestamp object using a calendar other than the default. This can be used to get values from columns with SQL types CHAR, VARCHAR, DATE, and TIMESTAMP
getTimestamp
{ "repo_name": "devjunix/libjt400-java", "path": "src/com/ibm/as400/access/AS400JDBCRowSet.java", "license": "epl-1.0", "size": 312119 }
[ "java.sql.SQLException", "java.sql.Timestamp", "java.util.Calendar" ]
import java.sql.SQLException; import java.sql.Timestamp; import java.util.Calendar;
import java.sql.*; import java.util.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
1,759,511
if(!methods.containsKey((Class<BindableEvent>)clazz)){ Class implementor = eventImplementations.get((Class<BindableEvent>)clazz); Method method = null; for(Method m : implementor.getMethods()){ if(m.getName().equals("_instantiate") && (m.getModifiers() & Modifier.STAT...
if(!methods.containsKey((Class<BindableEvent>)clazz)){ Class implementor = eventImplementations.get((Class<BindableEvent>)clazz); Method method = null; for(Method m : implementor.getMethods()){ if(m.getName().equals(STR) && (m.getModifiers() & Modifier.STATIC) != 0){ method = m; break; } } if(method == null){ System.er...
/** * Finds the _instantiate method in an event, and caches it for later use. * @param clazz */
Finds the _instantiate method in an event, and caches it for later use
warmup
{ "repo_name": "KamranMackey/CommandHelper", "path": "src/main/java/com/laytonsmith/core/events/EventBuilder.java", "license": "mit", "size": 5236 }
[ "java.lang.reflect.Method", "java.lang.reflect.Modifier" ]
import java.lang.reflect.Method; import java.lang.reflect.Modifier;
import java.lang.reflect.*;
[ "java.lang" ]
java.lang;
1,232,911
@Test public void testEvaluate() { Vector x = Vector.of(Real.valueOf(0.0), Real.valueOf(0.0)); assertEquals(0.0, function.f(x), Maths.EPSILON); x.setReal(0, 1.0); x.setReal(1, 2.0); assertEquals(4000001, function.f(x), Maths.EPSILON); }
void function() { Vector x = Vector.of(Real.valueOf(0.0), Real.valueOf(0.0)); assertEquals(0.0, function.f(x), Maths.EPSILON); x.setReal(0, 1.0); x.setReal(1, 2.0); assertEquals(4000001, function.f(x), Maths.EPSILON); }
/** * Test of evaluate method, of class {@link Elliptic}. */
Test of evaluate method, of class <code>Elliptic</code>
testEvaluate
{ "repo_name": "filinep/cilib", "path": "library/src/test/java/net/sourceforge/cilib/functions/continuous/unconstrained/EllipticTest.java", "license": "gpl-3.0", "size": 1090 }
[ "net.sourceforge.cilib.math.Maths", "net.sourceforge.cilib.type.types.Real", "net.sourceforge.cilib.type.types.container.Vector", "org.junit.Assert" ]
import net.sourceforge.cilib.math.Maths; import net.sourceforge.cilib.type.types.Real; import net.sourceforge.cilib.type.types.container.Vector; import org.junit.Assert;
import net.sourceforge.cilib.math.*; import net.sourceforge.cilib.type.types.*; import net.sourceforge.cilib.type.types.container.*; import org.junit.*;
[ "net.sourceforge.cilib", "org.junit" ]
net.sourceforge.cilib; org.junit;
739,659
public Token refreshToken(String userName, String refreshToken);
Token function(String userName, String refreshToken);
/** * Request a new access token when the current one is expired * * @param userName * @param refreshToken * @return a new Token with the access if refreshToken works, empty Token * otherwise */
Request a new access token when the current one is expired
refreshToken
{ "repo_name": "muilpp/Spotify-song-suggester", "path": "src/main/java/xyz/spotifyrecommender/model/SpotifyAPI.java", "license": "apache-2.0", "size": 1999 }
[ "xyz.spotifyrecommender.model.webservicedata.Token" ]
import xyz.spotifyrecommender.model.webservicedata.Token;
import xyz.spotifyrecommender.model.webservicedata.*;
[ "xyz.spotifyrecommender.model" ]
xyz.spotifyrecommender.model;
704,593
@Test(expected=ModelClassException.class) public void testImplementsNoPickerWithDifferentImplementations() { factory.unbindImplementationPicker(firstImplementationPicker, firstImplementationPickerProps); Resource res = getMockResourceWithProps(); factory.getAdapter(res, SampleServiceInt...
@Test(expected=ModelClassException.class) void function() { factory.unbindImplementationPicker(firstImplementationPicker, firstImplementationPickerProps); Resource res = getMockResourceWithProps(); factory.getAdapter(res, SampleServiceInterface.class); } /* -- disabled because this cannot work in unit test where the ad...
/** * Try to adapt in a case where there is no picker available. * The case where the class is the adapter still works. */
Try to adapt in a case where there is no picker available. The case where the class is the adapter still works
testImplementsNoPickerWithDifferentImplementations
{ "repo_name": "tteofili/sling", "path": "bundles/extensions/models/impl/src/test/java/org/apache/sling/models/impl/ImplementsExtendsTest.java", "license": "apache-2.0", "size": 12463 }
[ "org.apache.sling.api.resource.Resource", "org.apache.sling.models.factory.ModelClassException", "org.apache.sling.models.testmodels.classes.implextend.ImplementsInterfacePropertyModel", "org.apache.sling.models.testmodels.classes.implextend.SampleServiceInterface", "org.junit.Assert", "org.junit.Test" ]
import org.apache.sling.api.resource.Resource; import org.apache.sling.models.factory.ModelClassException; import org.apache.sling.models.testmodels.classes.implextend.ImplementsInterfacePropertyModel; import org.apache.sling.models.testmodels.classes.implextend.SampleServiceInterface; import org.junit.Assert; import o...
import org.apache.sling.api.resource.*; import org.apache.sling.models.factory.*; import org.apache.sling.models.testmodels.classes.implextend.*; import org.junit.*;
[ "org.apache.sling", "org.junit" ]
org.apache.sling; org.junit;
321,312
public static java.util.List extractOrderSpecimenList(ims.domain.ILightweightDomainFactory domainFactory, ims.ocrr.vo.OrderSpecimenListVoCollection voCollection) { return extractOrderSpecimenList(domainFactory, voCollection, null, new HashMap()); }
static java.util.List function(ims.domain.ILightweightDomainFactory domainFactory, ims.ocrr.vo.OrderSpecimenListVoCollection voCollection) { return extractOrderSpecimenList(domainFactory, voCollection, null, new HashMap()); }
/** * Create the ims.ocrr.orderingresults.domain.objects.OrderSpecimen list from the value object collection. * @param domainFactory - used to create existing (persistent) domain objects. * @param voCollection - the collection of value objects */
Create the ims.ocrr.orderingresults.domain.objects.OrderSpecimen list from the value object collection
extractOrderSpecimenList
{ "repo_name": "IMS-MAXIMS/openMAXIMS", "path": "Source Library/openmaxims_workspace/ValueObjects/src/ims/ocrr/vo/domain/OrderSpecimenListVoAssembler.java", "license": "agpl-3.0", "size": 25619 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
815,167
@SuppressWarnings("unchecked") static public String getFieldFromMultiPartForm(HttpServletRequest req, String fieldName) throws Exception { String fieldValue = null; ServletFileUpload upload = new ServletFileUpload(); List<FileItem> items = upload.parseRequest(req); // Process t...
@SuppressWarnings(STR) static String function(HttpServletRequest req, String fieldName) throws Exception { String fieldValue = null; ServletFileUpload upload = new ServletFileUpload(); List<FileItem> items = upload.parseRequest(req); Iterator<FileItem> iter = items.iterator(); while (iter.hasNext()) { FileItem item = i...
/** * * Get the given value field from the Servlet request if exist. * Returns null if the passed fieldName isn't present in the request. * * @param req * @param fieldName * @return String * @throws Exception */
Get the given value field from the Servlet request if exist. Returns null if the passed fieldName isn't present in the request
getFieldFromMultiPartForm
{ "repo_name": "amitjoy/kura", "path": "kura/org.eclipse.kura.web2/src/main/java/org/eclipse/kura/web/server/KuraRemoteServiceServlet.java", "license": "epl-1.0", "size": 7133 }
[ "java.util.Iterator", "java.util.List", "javax.servlet.http.HttpServletRequest", "org.apache.commons.fileupload.FileItem", "org.apache.commons.fileupload.servlet.ServletFileUpload" ]
import java.util.Iterator; import java.util.List; import javax.servlet.http.HttpServletRequest; import org.apache.commons.fileupload.FileItem; import org.apache.commons.fileupload.servlet.ServletFileUpload;
import java.util.*; import javax.servlet.http.*; import org.apache.commons.fileupload.*; import org.apache.commons.fileupload.servlet.*;
[ "java.util", "javax.servlet", "org.apache.commons" ]
java.util; javax.servlet; org.apache.commons;
1,923,613
@Nonnull @SuppressWarnings("rawtypes") AggregateOperation<A, R> withAccumulateFns(BiConsumerEx... accumulateFns); /** * Returns a copy of this aggregate operation, but with the {@code finish}
@SuppressWarnings(STR) AggregateOperation<A, R> withAccumulateFns(BiConsumerEx... accumulateFns); /** * Returns a copy of this aggregate operation, but with the {@code finish}
/** * Returns a copy of this aggregate operation, but with all the {@code * accumulate} primitives replaced with the ones supplied here. The * argument at position {@code i} replaces the primitive at index {@code * i}, as returned by {@link #accumulateFn(int)}. * <p> * The functions must b...
Returns a copy of this aggregate operation, but with all the accumulate primitives replaced with the ones supplied here. The argument at position i replaces the primitive at index i, as returned by <code>#accumulateFn(int)</code>. The functions must be stateless and Processor#isCooperative() cooperative
withAccumulateFns
{ "repo_name": "gurbuzali/hazelcast-jet", "path": "hazelcast-jet-core/src/main/java/com/hazelcast/jet/aggregate/AggregateOperation.java", "license": "apache-2.0", "size": 16303 }
[ "com.hazelcast.function.BiConsumerEx" ]
import com.hazelcast.function.BiConsumerEx;
import com.hazelcast.function.*;
[ "com.hazelcast.function" ]
com.hazelcast.function;
1,393,127
private void checkStripeExecutorView(StripedExecutor execSvc, SystemView<StripedExecutorTaskView> view, String poolName) throws Exception { CountDownLatch latch = new CountDownLatch(1); execSvc.execute(0, new TestRunnable(latch, 0)); execSvc.execute(0, new TestRunnable(latch, 1)); ...
void function(StripedExecutor execSvc, SystemView<StripedExecutorTaskView> view, String poolName) throws Exception { CountDownLatch latch = new CountDownLatch(1); execSvc.execute(0, new TestRunnable(latch, 0)); execSvc.execute(0, new TestRunnable(latch, 1)); execSvc.execute(1, new TestRunnable(latch, 2)); execSvc.execu...
/** * Checks striped executor system view. * * @param execSvc Striped executor. * @param view System view. * @param poolName Executor name. */
Checks striped executor system view
checkStripeExecutorView
{ "repo_name": "ascherbakoff/ignite", "path": "modules/core/src/test/java/org/apache/ignite/internal/metric/SystemViewSelfTest.java", "license": "apache-2.0", "size": 84009 }
[ "java.util.Iterator", "java.util.concurrent.CountDownLatch", "org.apache.ignite.internal.util.StripedExecutor", "org.apache.ignite.spi.systemview.view.StripedExecutorTaskView", "org.apache.ignite.spi.systemview.view.SystemView", "org.apache.ignite.testframework.GridTestUtils" ]
import java.util.Iterator; import java.util.concurrent.CountDownLatch; import org.apache.ignite.internal.util.StripedExecutor; import org.apache.ignite.spi.systemview.view.StripedExecutorTaskView; import org.apache.ignite.spi.systemview.view.SystemView; import org.apache.ignite.testframework.GridTestUtils;
import java.util.*; import java.util.concurrent.*; import org.apache.ignite.internal.util.*; import org.apache.ignite.spi.systemview.view.*; import org.apache.ignite.testframework.*;
[ "java.util", "org.apache.ignite" ]
java.util; org.apache.ignite;
2,784,173
double getNextValue() throws IllegalStateException; /** * Returns a * {@link org.apache.commons.math.stat.descriptive.StatisticalSummary}
double getNextValue() throws IllegalStateException; /** * Returns a * {@link org.apache.commons.math.stat.descriptive.StatisticalSummary}
/** * Generates a random value from this distribution. * <strong>Preconditions:</strong><ul> * <li>the distribution must be loaded before invoking this method</li></ul> * @return the random value. * * @throws IllegalStateException if the distribution has not been loaded */
Generates a random value from this distribution. Preconditions: the distribution must be loaded before invoking this method
getNextValue
{ "repo_name": "haisamido/SFDaaS", "path": "src/org/apache/commons/math/random/EmpiricalDistribution.java", "license": "lgpl-3.0", "size": 4781 }
[ "org.apache.commons.math.stat.descriptive.StatisticalSummary" ]
import org.apache.commons.math.stat.descriptive.StatisticalSummary;
import org.apache.commons.math.stat.descriptive.*;
[ "org.apache.commons" ]
org.apache.commons;
40,592
private void forEachNonSubBlockDepthFirst0( BasicBlock next, BasicBlock.Visitor v, BitSet visited) { v.visitBlock(next); visited.set(next.getLabel()); IntList successors = next.getSuccessors(); int sz = successors.size(); for (int i = 0; i < sz; i++) { ...
void function( BasicBlock next, BasicBlock.Visitor v, BitSet visited) { v.visitBlock(next); visited.set(next.getLabel()); IntList successors = next.getSuccessors(); int sz = successors.size(); for (int i = 0; i < sz; i++) { int succ = successors.get(i); if (visited.get(succ)) { continue; } if (isSubroutineCaller(next) ...
/** * Visits each block once in depth-first successor order, ignoring * {@code jsr} targets. Worker for {@link #forEachNonSubBlockDepthFirst}. * * @param next next block to visit * @param v callback interface * @param visited set of blocks already visited */
Visits each block once in depth-first successor order, ignoring jsr targets. Worker for <code>#forEachNonSubBlockDepthFirst</code>
forEachNonSubBlockDepthFirst0
{ "repo_name": "MarkRunWu/buck", "path": "third-party/java/dx-from-kitkat/src/com/android/dx/cf/code/Ropper.java", "license": "apache-2.0", "size": 59948 }
[ "com.android.dx.rop.code.BasicBlock", "com.android.dx.util.IntList", "java.util.BitSet" ]
import com.android.dx.rop.code.BasicBlock; import com.android.dx.util.IntList; import java.util.BitSet;
import com.android.dx.rop.code.*; import com.android.dx.util.*; import java.util.*;
[ "com.android.dx", "java.util" ]
com.android.dx; java.util;
2,317,842
public void setOwnerSettings() { if (model.getState() == DISCARDED) throw new IllegalArgumentException("This method cannot be " + "invoked in the DISCARDED state."); ImageDisplay d = getBrowser().getLastSelectedDisplay(); if (d instanceof WellSampleNode) firePropertyChange(SET__OWNER_RND_SETTIN...
void function() { if (model.getState() == DISCARDED) throw new IllegalArgumentException(STR + STR); ImageDisplay d = getBrowser().getLastSelectedDisplay(); if (d instanceof WellSampleNode) firePropertyChange(SET__OWNER_RND_SETTINGS_PROPERTY, null, getBrowser().getSelectedDataObjects()); else firePropertyChange(SET__OWN...
/** * Implemented as specified by the {@link DataBrowser} interface. * @see DataBrowser#setOwnerSettings() */
Implemented as specified by the <code>DataBrowser</code> interface
setOwnerSettings
{ "repo_name": "knabar/openmicroscopy", "path": "components/insight/SRC/org/openmicroscopy/shoola/agents/dataBrowser/view/DataBrowserComponent.java", "license": "gpl-2.0", "size": 57362 }
[ "org.openmicroscopy.shoola.agents.dataBrowser.browser.ImageDisplay", "org.openmicroscopy.shoola.agents.dataBrowser.browser.WellSampleNode" ]
import org.openmicroscopy.shoola.agents.dataBrowser.browser.ImageDisplay; import org.openmicroscopy.shoola.agents.dataBrowser.browser.WellSampleNode;
import org.openmicroscopy.shoola.agents.*;
[ "org.openmicroscopy.shoola" ]
org.openmicroscopy.shoola;
684,130
private static int validateTimePrecisionMode(Configuration config, Field field, ValidationOutput problems) { if (config.hasKey(TIME_PRECISION_MODE.name())) { final String timePrecisionMode = config.getString(TIME_PRECISION_MODE.name()); if (TemporalPrecisionMode.ADAPTIVE.getValue().equals(timePrecisio...
static int function(Configuration config, Field field, ValidationOutput problems) { if (config.hasKey(TIME_PRECISION_MODE.name())) { final String timePrecisionMode = config.getString(TIME_PRECISION_MODE.name()); if (TemporalPrecisionMode.ADAPTIVE.getValue().equals(timePrecisionMode)) { problems.accept(TIME_PRECISION_MO...
/** * Validate the time.precision.mode configuration. * * If {@code adaptive} is specified, this option has the potential to cause overflow which is why the * option was deprecated and no longer supported for this connector. */
Validate the time.precision.mode configuration. If adaptive is specified, this option has the potential to cause overflow which is why the option was deprecated and no longer supported for this connector
validateTimePrecisionMode
{ "repo_name": "data-integrations/database-delta-plugins", "path": "mysql-delta-plugins/src/main/java/io/debezium/connector/mysql/MySqlConnectorConfig.java", "license": "apache-2.0", "size": 59385 }
[ "io.debezium.config.Configuration", "io.debezium.config.Field", "io.debezium.jdbc.TemporalPrecisionMode" ]
import io.debezium.config.Configuration; import io.debezium.config.Field; import io.debezium.jdbc.TemporalPrecisionMode;
import io.debezium.config.*; import io.debezium.jdbc.*;
[ "io.debezium.config", "io.debezium.jdbc" ]
io.debezium.config; io.debezium.jdbc;
62,514
public static void removeReferences(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource, org.ontoware.rdf2go.model.node.Node value) { Base.remove(model, instanceResource, REFERENCES, value); }
static void function(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource, org.ontoware.rdf2go.model.node.Node value) { Base.remove(model, instanceResource, REFERENCES, value); }
/** * Removes a value of property References as an RDF2Go node * * @param model an RDF2Go model * @param resource an RDF2Go resource * @param value the value to be removed [Generated from RDFReactor template * rule #remove1static] */
Removes a value of property References as an RDF2Go node
removeReferences
{ "repo_name": "m0ep/master-thesis", "path": "source/apis/rdf2go/rdf2go-foaf/src/main/java/com/xmlns/foaf/Thing.java", "license": "mit", "size": 274766 }
[ "org.ontoware.rdf2go.model.Model", "org.ontoware.rdfreactor.runtime.Base" ]
import org.ontoware.rdf2go.model.Model; import org.ontoware.rdfreactor.runtime.Base;
import org.ontoware.rdf2go.model.*; import org.ontoware.rdfreactor.runtime.*;
[ "org.ontoware.rdf2go", "org.ontoware.rdfreactor" ]
org.ontoware.rdf2go; org.ontoware.rdfreactor;
2,809,740
public void addTab(TabSpec tabSpec) { if (tabSpec.mIndicatorStrategy == null) { throw new IllegalArgumentException("you must specify a way to create the tab indicator."); } if (tabSpec.mContentStrategy == null) { throw new IllegalArgumentException("you must specify ...
void function(TabSpec tabSpec) { if (tabSpec.mIndicatorStrategy == null) { throw new IllegalArgumentException(STR); } if (tabSpec.mContentStrategy == null) { throw new IllegalArgumentException(STR); } View tabIndicator = tabSpec.mIndicatorStrategy.createIndicatorView(); tabIndicator.setOnKeyListener(mTabKeyListener); i...
/** * Add a tab. * @param tabSpec Specifies how to create the indicator and content. */
Add a tab
addTab
{ "repo_name": "mateor/pdroid", "path": "android-4.0.3_r1/trunk/frameworks/base/core/java/android/widget/TabHost.java", "license": "gpl-3.0", "size": 23064 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
2,550,281
public synchronized void refresh() { Package newPkg = m_pollerConfig.getPackage(m_pkg.getName()); if (newPkg == null) { ThreadCategory.getInstance(PollableServiceConfig.class).warn("Package named "+m_pkg.getName()+" no longer exists."); } m_pkg = newPkg; m_configS...
synchronized void function() { Package newPkg = m_pollerConfig.getPackage(m_pkg.getName()); if (newPkg == null) { ThreadCategory.getInstance(PollableServiceConfig.class).warn(STR+m_pkg.getName()+STR); } m_pkg = newPkg; m_configService = findService(m_pkg); m_parameters = null; }
/** * Uses the existing package name to try and re-obtain the package from the poller config factory. * Should be called when the poller config has been reloaded. */
Uses the existing package name to try and re-obtain the package from the poller config factory. Should be called when the poller config has been reloaded
refresh
{ "repo_name": "tharindum/opennms_dashboard", "path": "opennms-services/src/main/java/org/opennms/netmgt/poller/pollables/PollableServiceConfig.java", "license": "gpl-2.0", "size": 9283 }
[ "org.opennms.core.utils.ThreadCategory", "org.opennms.netmgt.config.poller.Package" ]
import org.opennms.core.utils.ThreadCategory; import org.opennms.netmgt.config.poller.Package;
import org.opennms.core.utils.*; import org.opennms.netmgt.config.poller.*;
[ "org.opennms.core", "org.opennms.netmgt" ]
org.opennms.core; org.opennms.netmgt;
1,436,390
private void refreshContents() { for (final Entry<String, ItemPanel> entry : slotPanels.entrySet()) { final ItemPanel entitySlot = entry.getValue(); if (entitySlot != null) { // Set the parent entity for all slots, even if they are not // visible. They may become visible without zone changes ent...
void function() { for (final Entry<String, ItemPanel> entry : slotPanels.entrySet()) { final ItemPanel entitySlot = entry.getValue(); if (entitySlot != null) { entitySlot.setParent(player); final RPSlot slot = player.getSlot(entry.getKey()); if (slot == null) { continue; } final Iterator<RPObject> iter = slot.iterator(...
/** * Updates the player slot panels. */
Updates the player slot panels
refreshContents
{ "repo_name": "acsid/stendhal", "path": "src/games/stendhal/client/gui/Character.java", "license": "gpl-2.0", "size": 9138 }
[ "games.stendhal.client.GameObjects", "games.stendhal.client.entity.IEntity", "java.util.Iterator", "java.util.Map" ]
import games.stendhal.client.GameObjects; import games.stendhal.client.entity.IEntity; import java.util.Iterator; import java.util.Map;
import games.stendhal.client.*; import games.stendhal.client.entity.*; import java.util.*;
[ "games.stendhal.client", "java.util" ]
games.stendhal.client; java.util;
2,881,945
Supplier<ControllableProcess> getControllableProcessFactory() { return controllableProcessFactory; } } public enum Command { START("start", "assign-buckets", "disable-default-server", "rebalance", SERVER_BIND_ADDRESS, "server-port", "force", "debug", "help"), STATUS("status", "memb...
Supplier<ControllableProcess> getControllableProcessFactory() { return controllableProcessFactory; } } public enum Command { START("start", STR, STR, STR, SERVER_BIND_ADDRESS, STR, "force", "debug", "help"), STATUS(STR, STR, "pid", "dir", "debug", "help"), STOP("stop", STR, "pid", "dir", "debug", "help"), UNSPECIFIED(S...
/** * Gets the factory used to get a {@code ControllableProcess} when starting the server. * * @return the controllable process factory */
Gets the factory used to get a ControllableProcess when starting the server
getControllableProcessFactory
{ "repo_name": "smgoller/geode", "path": "geode-core/src/main/java/org/apache/geode/distributed/ServerLauncher.java", "license": "apache-2.0", "size": 106858 }
[ "java.util.Arrays", "java.util.Collections", "java.util.List", "java.util.function.Supplier", "org.apache.commons.lang3.StringUtils", "org.apache.geode.internal.process.ControllableProcess" ]
import java.util.Arrays; import java.util.Collections; import java.util.List; import java.util.function.Supplier; import org.apache.commons.lang3.StringUtils; import org.apache.geode.internal.process.ControllableProcess;
import java.util.*; import java.util.function.*; import org.apache.commons.lang3.*; import org.apache.geode.internal.process.*;
[ "java.util", "org.apache.commons", "org.apache.geode" ]
java.util; org.apache.commons; org.apache.geode;
1,296,117
public void addClassPath(ClassLoader loader) { String classpath = null; if (loader instanceof DynamicClassLoader) classpath = ((DynamicClassLoader) loader).getClassPath(); else classpath = CauchoSystem.getClassPath(); addClassPath(classpath); }
void function(ClassLoader loader) { String classpath = null; if (loader instanceof DynamicClassLoader) classpath = ((DynamicClassLoader) loader).getClassPath(); else classpath = CauchoSystem.getClassPath(); addClassPath(classpath); }
/** * Adds the classpath for the loader as paths in the MergePath. * * @param loader class loader whose classpath should be used to search. */
Adds the classpath for the loader as paths in the MergePath
addClassPath
{ "repo_name": "CleverCloud/Quercus", "path": "resin/src/main/java/com/caucho/vfs/MergePath.java", "license": "gpl-2.0", "size": 17450 }
[ "com.caucho.loader.DynamicClassLoader", "com.caucho.server.util.CauchoSystem" ]
import com.caucho.loader.DynamicClassLoader; import com.caucho.server.util.CauchoSystem;
import com.caucho.loader.*; import com.caucho.server.util.*;
[ "com.caucho.loader", "com.caucho.server" ]
com.caucho.loader; com.caucho.server;
219,288
public Dimension minimumLayoutSize(Container parent) { // TODO Auto-generated method stub return null; }
Dimension function(Container parent) { return null; }
/** * Calculates the minimum size dimensions for the specified * container, given the components it contains. */
Calculates the minimum size dimensions for the specified container, given the components it contains
minimumLayoutSize
{ "repo_name": "rob-work/iwbcff", "path": "src/becta/viewer/controls/ToolbarLayout.java", "license": "bsd-2-clause", "size": 13802 }
[ "java.awt.Container", "java.awt.Dimension" ]
import java.awt.Container; import java.awt.Dimension;
import java.awt.*;
[ "java.awt" ]
java.awt;
1,118,186
public static File readFile(DataInput in) throws IOException { InternalDataSerializer.checkIn(in); String s = readString(in); File file = null; if (s != null) { file = new File(s); } if (logger.isTraceEnabled(LogMarker.SERIALIZER_VERBOSE)) { logger.trace(LogMarker.SERIALIZER_VERBO...
static File function(DataInput in) throws IOException { InternalDataSerializer.checkIn(in); String s = readString(in); File file = null; if (s != null) { file = new File(s); } if (logger.isTraceEnabled(LogMarker.SERIALIZER_VERBOSE)) { logger.trace(LogMarker.SERIALIZER_VERBOSE, STR, file); } return file; } /** * Writes ...
/** * Reads an instance of <code>File</code> from a <code>DataInput</code>. The return value may be * <code>null</code>. * * @throws IOException A problem occurs while reading from <code>in</code> */
Reads an instance of <code>File</code> from a <code>DataInput</code>. The return value may be <code>null</code>
readFile
{ "repo_name": "jdeppe-pivotal/geode", "path": "geode-core/src/main/java/org/apache/geode/DataSerializer.java", "license": "apache-2.0", "size": 104615 }
[ "java.io.DataInput", "java.io.DataOutput", "java.io.File", "java.io.IOException", "java.net.InetAddress", "org.apache.geode.internal.InternalDataSerializer", "org.apache.geode.internal.logging.log4j.LogMarker" ]
import java.io.DataInput; import java.io.DataOutput; import java.io.File; import java.io.IOException; import java.net.InetAddress; import org.apache.geode.internal.InternalDataSerializer; import org.apache.geode.internal.logging.log4j.LogMarker;
import java.io.*; import java.net.*; import org.apache.geode.internal.*; import org.apache.geode.internal.logging.log4j.*;
[ "java.io", "java.net", "org.apache.geode" ]
java.io; java.net; org.apache.geode;
2,016,176
public final void setFileExtensions(String... extensions) { if (extensions == null) { throw new IllegalArgumentException("Extensions array can not be null"); } fileExtensions = new String[extensions.length]; for (int i = 0; i < extensions.length; i++) { final...
final void function(String... extensions) { if (extensions == null) { throw new IllegalArgumentException(STR); } fileExtensions = new String[extensions.length]; for (int i = 0; i < extensions.length; i++) { final String extension = extensions[i]; if (Utils.startsWithChar(extension, '.')) { fileExtensions[i] = extension...
/** * Sets the file extensions that identify the files that pass the * filter of this FileSetCheck. * @param extensions the set of file extensions. A missing * initial '.' character of an extension is automatically added. * @throws IllegalArgumentException is arument is null */
Sets the file extensions that identify the files that pass the filter of this FileSetCheck
setFileExtensions
{ "repo_name": "Godin/checkstyle", "path": "src/main/java/com/puppycrawl/tools/checkstyle/api/AbstractFileSetCheck.java", "license": "lgpl-2.1", "size": 6072 }
[ "com.puppycrawl.tools.checkstyle.Utils" ]
import com.puppycrawl.tools.checkstyle.Utils;
import com.puppycrawl.tools.checkstyle.*;
[ "com.puppycrawl.tools" ]
com.puppycrawl.tools;
877,775
public @Nullable(Nullable.Prevalence.NEVER) EpochTime to() { return m_to; }
@Nullable(Nullable.Prevalence.NEVER) EpochTime function() { return m_to; }
/** * Returns the "to" date passed into the constructor, * or {@link com.idevicesinc.sweetblue.utils.EpochTime#NULL} if <code>null</code> * was originally passed in. */
Returns the "to" date passed into the constructor, or <code>com.idevicesinc.sweetblue.utils.EpochTime#NULL</code> if <code>null</code> was originally passed in
to
{ "repo_name": "TheTypoMaster/SweetBlue", "path": "src/com/idevicesinc/sweetblue/utils/EpochTimeRange.java", "license": "gpl-3.0", "size": 5709 }
[ "com.idevicesinc.sweetblue.annotations.Nullable" ]
import com.idevicesinc.sweetblue.annotations.Nullable;
import com.idevicesinc.sweetblue.annotations.*;
[ "com.idevicesinc.sweetblue" ]
com.idevicesinc.sweetblue;
1,500,261
@Override public void tightUnmarshal(OpenWireFormat wireFormat, Object o, DataInput dataIn, BooleanStream bs) throws IOException { super.tightUnmarshal(wireFormat, o, dataIn, bs); }
void function(OpenWireFormat wireFormat, Object o, DataInput dataIn, BooleanStream bs) throws IOException { super.tightUnmarshal(wireFormat, o, dataIn, bs); }
/** * Un-marshal an object instance from the data input stream * * @param o * the object to un-marshal * @param dataIn * the data input stream to build the object from * @throws IOException */
Un-marshal an object instance from the data input stream
tightUnmarshal
{ "repo_name": "tabish121/OpenWire", "path": "openwire-core/src/main/java/io/openwire/codec/v9/OpenWireMapMessageMarshaller.java", "license": "apache-2.0", "size": 3476 }
[ "io.openwire.codec.BooleanStream", "io.openwire.codec.OpenWireFormat", "java.io.DataInput", "java.io.IOException" ]
import io.openwire.codec.BooleanStream; import io.openwire.codec.OpenWireFormat; import java.io.DataInput; import java.io.IOException;
import io.openwire.codec.*; import java.io.*;
[ "io.openwire.codec", "java.io" ]
io.openwire.codec; java.io;
1,372,502
public final double getAndSet(double newValue) { long next = doubleToRawLongBits(newValue); return longBitsToDouble(updater.getAndSet(this, next)); }
final double function(double newValue) { long next = doubleToRawLongBits(newValue); return longBitsToDouble(updater.getAndSet(this, next)); }
/** * Atomically sets to the given value and returns the old value. * * @param newValue the new value * @return the previous value */
Atomically sets to the given value and returns the old value
getAndSet
{ "repo_name": "DavesMan/guava", "path": "guava/src/com/google/common/util/concurrent/AtomicDouble.java", "license": "apache-2.0", "size": 7813 }
[ "java.lang.Double" ]
import java.lang.Double;
import java.lang.*;
[ "java.lang" ]
java.lang;
1,484,801
public static void fadeViewTo(@NonNull final View view, final int visibility) { final int durationMs = 1000; final boolean animationNeeded = view.getVisibility() != visibility; if (!animationNeeded) { return; }
static void function(@NonNull final View view, final int visibility) { final int durationMs = 1000; final boolean animationNeeded = view.getVisibility() != visibility; if (!animationNeeded) { return; }
/** * Animates the fade in/out of view within a specific duration. * * @param view The view to animate. * @param visibility Visibility to set after the view has finished animating. */
Animates the fade in/out of view within a specific duration
fadeViewTo
{ "repo_name": "edx/edx-app-android", "path": "OpenEdXMobile/src/main/java/org/edx/mobile/util/ViewAnimationUtil.java", "license": "apache-2.0", "size": 4764 }
[ "android.view.View", "androidx.annotation.NonNull" ]
import android.view.View; import androidx.annotation.NonNull;
import android.view.*; import androidx.annotation.*;
[ "android.view", "androidx.annotation" ]
android.view; androidx.annotation;
2,359,179
public void clearBuffer() { rawDataQueueBuffer.clear(); } private DataProcessor() { Log.i(TAG, "DataProcessor started."); }
void function() { rawDataQueueBuffer.clear(); } private DataProcessor() { Log.i(TAG, STR); }
/** * Clear the current buffer. */
Clear the current buffer
clearBuffer
{ "repo_name": "Sam-Hendriksen/SquashT", "path": "Android/Gradle/SquashTracker/app/src/main/java/com/hendriksen/processors/DataProcessor.java", "license": "mit", "size": 18022 }
[ "android.util.Log" ]
import android.util.Log;
import android.util.*;
[ "android.util" ]
android.util;
2,039,563
@POST @Consumes({MediaType.APPLICATION_JSON, MediaType.APPLICATION_FORM_URLENCODED}) @Produces(MediaType.APPLICATION_JSON) @ApiOperation("Creates or updates a feed.") @ApiResponses( @ApiResponse(code = 200, message = "Returns the feed including any error messages.", response = NifiFeed.class...
@Consumes({MediaType.APPLICATION_JSON, MediaType.APPLICATION_FORM_URLENCODED}) @Produces(MediaType.APPLICATION_JSON) @ApiOperation(STR) @ApiResponses( @ApiResponse(code = 200, message = STR, response = NifiFeed.class) ) Response function(@Nonnull final FeedMetadata feedMetadata) { NifiFeed feed; try { feed = getMetadat...
/** * Creates a new Feed using the specified metadata. * * @param feedMetadata the feed metadata * @return the feed */
Creates a new Feed using the specified metadata
createFeed
{ "repo_name": "rashidaligee/kylo", "path": "services/feed-manager-service/feed-manager-controller/src/main/java/com/thinkbiganalytics/feedmgr/rest/controller/FeedRestController.java", "license": "apache-2.0", "size": 40840 }
[ "com.thinkbiganalytics.feedmgr.rest.model.FeedMetadata", "com.thinkbiganalytics.feedmgr.rest.model.NifiFeed", "com.thinkbiganalytics.feedmgr.service.feed.DuplicateFeedNameException", "io.swagger.annotations.ApiOperation", "io.swagger.annotations.ApiResponse", "io.swagger.annotations.ApiResponses", "java...
import com.thinkbiganalytics.feedmgr.rest.model.FeedMetadata; import com.thinkbiganalytics.feedmgr.rest.model.NifiFeed; import com.thinkbiganalytics.feedmgr.service.feed.DuplicateFeedNameException; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiResponse; import io.swagger.annotations.ApiRe...
import com.thinkbiganalytics.feedmgr.rest.model.*; import com.thinkbiganalytics.feedmgr.service.feed.*; import io.swagger.annotations.*; import javax.annotation.*; import javax.ws.rs.*; import javax.ws.rs.core.*; import org.hibernate.*;
[ "com.thinkbiganalytics.feedmgr", "io.swagger.annotations", "javax.annotation", "javax.ws", "org.hibernate" ]
com.thinkbiganalytics.feedmgr; io.swagger.annotations; javax.annotation; javax.ws; org.hibernate;
2,390,962
@Generated @Selector("setBackgroundInsets:") public native void setBackgroundInsets(@ByValue NSDirectionalEdgeInsets value);
@Selector(STR) native void function(@ByValue NSDirectionalEdgeInsets value);
/** * Insets (or outsets, if negative) for the background and stroke, relative to the edges of the containing view. These also apply to the custom view. Default is NSDirectionalEdgeInsetsZero. */
Insets (or outsets, if negative) for the background and stroke, relative to the edges of the containing view. These also apply to the custom view. Default is NSDirectionalEdgeInsetsZero
setBackgroundInsets
{ "repo_name": "multi-os-engine/moe-core", "path": "moe.apple/moe.platform.ios/src/main/java/apple/uikit/UIBackgroundConfiguration.java", "license": "apache-2.0", "size": 16562 }
[ "org.moe.natj.general.ann.ByValue", "org.moe.natj.objc.ann.Selector" ]
import org.moe.natj.general.ann.ByValue; import org.moe.natj.objc.ann.Selector;
import org.moe.natj.general.ann.*; import org.moe.natj.objc.ann.*;
[ "org.moe.natj" ]
org.moe.natj;
466,279
protected void handleModuleForAxisDescription(String serviceGroupId, AxisModule module, String xpathStr, boolean engage) throws Exception { boolean isStarted = getServiceGroupFilePM().isTransactionStarted(serviceGroupId); if (!isStarted) { ...
void function(String serviceGroupId, AxisModule module, String xpathStr, boolean engage) throws Exception { boolean isStarted = getServiceGroupFilePM().isTransactionStarted(serviceGroupId); if (!isStarted) { getServiceGroupFilePM().beginTransaction(serviceGroupId); } String version = PersistenceUtils.getModuleVersion(m...
/** * Engage or disengage module at the given resource path. * * @param serviceGroupId serviceGroupId * @param module - AxisModule instance * @param xpathStr - registry path of a service group, service, operation etc * @param engage - engage or disengage *...
Engage or disengage module at the given resource path
handleModuleForAxisDescription
{ "repo_name": "maheshika/carbon4-kernel", "path": "core/org.wso2.carbon.core/src/main/java/org/wso2/carbon/core/persistence/AbstractPersistenceManager.java", "license": "apache-2.0", "size": 33126 }
[ "org.apache.axiom.om.OMElement", "org.apache.axis2.description.AxisModule", "org.wso2.carbon.core.Resources" ]
import org.apache.axiom.om.OMElement; import org.apache.axis2.description.AxisModule; import org.wso2.carbon.core.Resources;
import org.apache.axiom.om.*; import org.apache.axis2.description.*; import org.wso2.carbon.core.*;
[ "org.apache.axiom", "org.apache.axis2", "org.wso2.carbon" ]
org.apache.axiom; org.apache.axis2; org.wso2.carbon;
2,245,230
@WebMethod @WebResult(name = "rval", targetNamespace = "https://www.google.com/apis/ads/publisher/v201411") @RequestWrapper(localName = "createContentMetadataKeyHierarchies", targetNamespace = "https://www.google.com/apis/ads/publisher/v201411", className = "com.google.api.ads.dfp.jaxws.v201411.ContentMetad...
@WebResult(name = "rval", targetNamespace = STRcreateContentMetadataKeyHierarchiesSTRhttps: @ResponseWrapper(localName = "createContentMetadataKeyHierarchiesResponseSTRhttps: List<ContentMetadataKeyHierarchy> function( @WebParam(name = "contentMetadataKeyHierarchiesSTRhttps: List<ContentMetadataKeyHierarchy> contentMet...
/** * * Creates new {@link ContentMetadataKeyHierarchy} objects. * * The following fields are required: * <ul> * <li>{@link ContentMetadataKeyHierarchy#id}</li> * <li>{@link ContentMetadataKeyHierarchy#name}</li> * <li>{@l...
Creates new <code>ContentMetadataKeyHierarchy</code> objects. The following fields are required: <code>ContentMetadataKeyHierarchy#id</code> <code>ContentMetadataKeyHierarchy#name</code> <code>ContentMetadataKeyHierarchy#hierarchyLevels</code>
createContentMetadataKeyHierarchies
{ "repo_name": "stoksey69/googleads-java-lib", "path": "modules/dfp_appengine/src/main/java/com/google/api/ads/dfp/jaxws/v201411/ContentMetadataKeyHierarchyServiceInterface.java", "license": "apache-2.0", "size": 8451 }
[ "java.util.List", "javax.jws.WebParam", "javax.jws.WebResult", "javax.xml.ws.ResponseWrapper" ]
import java.util.List; import javax.jws.WebParam; import javax.jws.WebResult; import javax.xml.ws.ResponseWrapper;
import java.util.*; import javax.jws.*; import javax.xml.ws.*;
[ "java.util", "javax.jws", "javax.xml" ]
java.util; javax.jws; javax.xml;
556,047
protected List<CmsResource> allInFolderPriorityDate(CmsObject cms, String param, boolean tree, boolean asc) throws CmsException { CmsCollectorData data = new CmsCollectorData(param); String foldername = CmsResource.getFolderPath(data.getFileName()); CmsResourceFilter filter = CmsResour...
List<CmsResource> function(CmsObject cms, String param, boolean tree, boolean asc) throws CmsException { CmsCollectorData data = new CmsCollectorData(param); String foldername = CmsResource.getFolderPath(data.getFileName()); CmsResourceFilter filter = CmsResourceFilter.DEFAULT.addRequireType(data.getType()).addExcludeF...
/** * Returns a list of all resource in a specified folder sorted by priority, then date ascending or descending.<p> * * @param cms the current OpenCms user context * @param param the folder name to use * @param tree if true, look in folder and all child folders, if false, look only in given f...
Returns a list of all resource in a specified folder sorted by priority, then date ascending or descending
allInFolderPriorityDate
{ "repo_name": "serrapos/opencms-core", "path": "src/org/opencms/file/collectors/CmsPriorityResourceCollector.java", "license": "lgpl-2.1", "size": 12068 }
[ "java.util.Collections", "java.util.List", "org.opencms.file.CmsObject", "org.opencms.file.CmsResource", "org.opencms.file.CmsResourceFilter", "org.opencms.main.CmsException" ]
import java.util.Collections; import java.util.List; import org.opencms.file.CmsObject; import org.opencms.file.CmsResource; import org.opencms.file.CmsResourceFilter; import org.opencms.main.CmsException;
import java.util.*; import org.opencms.file.*; import org.opencms.main.*;
[ "java.util", "org.opencms.file", "org.opencms.main" ]
java.util; org.opencms.file; org.opencms.main;
2,470,875
public static String insertIptablesRule(Chain chain, brooklyn.util.net.Protocol protocol, int port, Policy policy) { return addIptablesRule("-I", chain, Optional.<String> absent(), protocol, port, policy); }
static String function(Chain chain, brooklyn.util.net.Protocol protocol, int port, Policy policy) { return addIptablesRule("-I", chain, Optional.<String> absent(), protocol, port, policy); }
/** * Returns the command that inserts a rule on top of the iptables' rules to all interfaces. * * @return Returns the command that inserts a rule on top of the iptables' * rules. */
Returns the command that inserts a rule on top of the iptables' rules to all interfaces
insertIptablesRule
{ "repo_name": "neykov/incubator-brooklyn", "path": "utils/common/src/main/java/brooklyn/util/ssh/IptablesCommands.java", "license": "apache-2.0", "size": 7959 }
[ "com.google.common.base.Optional" ]
import com.google.common.base.Optional;
import com.google.common.base.*;
[ "com.google.common" ]
com.google.common;
188,592
@NotNull @Size(max = 20) public String getSchoolGuidanceTeacherTel() { return (String) get(18); }
@Size(max = 20) String function() { return (String) get(18); }
/** * Getter for <code>isy.internship_college.school_guidance_teacher_tel</code>. */
Getter for <code>isy.internship_college.school_guidance_teacher_tel</code>
getSchoolGuidanceTeacherTel
{ "repo_name": "zbeboy/ISY", "path": "src/main/java/top/zbeboy/isy/domain/tables/records/InternshipCollegeRecord.java", "license": "mit", "size": 13492 }
[ "javax.validation.constraints.Size" ]
import javax.validation.constraints.Size;
import javax.validation.constraints.*;
[ "javax.validation" ]
javax.validation;
630,693
@SuppressWarnings("unchecked") private void addInlineDiffs(Delta delta) { List<String> orig = (List<String>) delta.getOriginal().getLines(); List<String> rev = (List<String>) delta.getRevised().getLines(); LinkedList<String> origList = new LinkedList<String>(); for (Character character : join(orig...
@SuppressWarnings(STR) void function(Delta delta) { List<String> orig = (List<String>) delta.getOriginal().getLines(); List<String> rev = (List<String>) delta.getRevised().getLines(); LinkedList<String> origList = new LinkedList<String>(); for (Character character : join(orig, "\n").toCharArray()) { origList.add(charac...
/** * Add the inline diffs for given delta * @param delta the given delta */
Add the inline diffs for given delta
addInlineDiffs
{ "repo_name": "veggiespam/zap-extensions", "path": "addOns/diff/src/main/java/org/zaproxy/zap/extension/diff/ZapDiffRowGenerator.java", "license": "apache-2.0", "size": 16400 }
[ "java.util.Arrays", "java.util.Collections", "java.util.LinkedList", "java.util.List" ]
import java.util.Arrays; import java.util.Collections; import java.util.LinkedList; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,309,180
public static void loadFileTreeList() { // ExStart:LoadFileTreeListForStoragePath try { // Setup GroupDocs.Viewer config ViewerConfig config = Utilities.getConfiguration(); // Create image handler ViewerImageHandler imageHandler = new ViewerImageHandler(config); // Load file tree list for ViewerC...
static void function() { try { ViewerConfig config = Utilities.getConfiguration(); ViewerImageHandler imageHandler = new ViewerImageHandler(config); FileListContainer container = imageHandler.getFileList(); for (FileDescription node : container.getFiles()) { if (node.isDirectory()) { System.out.println(STR + node.getGu...
/** * Loads file tree list for the storage path * */
Loads file tree list for the storage path
loadFileTreeList
{ "repo_name": "saqibmasood/GroupDocs.Viewer-for-Java", "path": "Examples/GroupDocs.Viewer.Examples.Java/src/main/java/com/groupdocs/viewer/examples/ViewGenerator.java", "license": "mit", "size": 89611 }
[ "com.groupdocs.viewer.config.ViewerConfig", "com.groupdocs.viewer.domain.FileDescription", "com.groupdocs.viewer.domain.containers.FileListContainer", "com.groupdocs.viewer.handler.ViewerImageHandler" ]
import com.groupdocs.viewer.config.ViewerConfig; import com.groupdocs.viewer.domain.FileDescription; import com.groupdocs.viewer.domain.containers.FileListContainer; import com.groupdocs.viewer.handler.ViewerImageHandler;
import com.groupdocs.viewer.config.*; import com.groupdocs.viewer.domain.*; import com.groupdocs.viewer.domain.containers.*; import com.groupdocs.viewer.handler.*;
[ "com.groupdocs.viewer" ]
com.groupdocs.viewer;
1,396,064
public BigInteger getPrimeExponentQ() { return this.primeExponentQ; }
BigInteger function() { return this.primeExponentQ; }
/** * Returns the primeExponentQ. * * @return the primeExponentQ */
Returns the primeExponentQ
getPrimeExponentQ
{ "repo_name": "rokn/Count_Words_2015", "path": "testing/openjdk/jdk/src/share/classes/java/security/spec/RSAPrivateCrtKeySpec.java", "license": "mit", "size": 4339 }
[ "java.math.BigInteger" ]
import java.math.BigInteger;
import java.math.*;
[ "java.math" ]
java.math;
517,938
private ProtocolSummary getProtocolRow(ResultSet results) throws SQLException { ProtocolSummary protocol = new ProtocolSummary(); Long id = new Long(results.getLong("reference_id")); protocol.set_reference_id(id); protocol.set_title(results.getString("title")); protocol.set_autho...
ProtocolSummary function(ResultSet results) throws SQLException { ProtocolSummary protocol = new ProtocolSummary(); Long id = new Long(results.getLong(STR)); protocol.set_reference_id(id); protocol.set_title(results.getString("title")); protocol.set_authors(results.getString(STR)); return protocol; }
/** * create ProtocolSummary object out of single row of result set */
create ProtocolSummary object out of single row of result set
getProtocolRow
{ "repo_name": "tair/tairwebapp", "path": "src/org/tair/search/ProtocolSearcher.java", "license": "gpl-3.0", "size": 18522 }
[ "java.sql.ResultSet", "java.sql.SQLException" ]
import java.sql.ResultSet; import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
1,472,753
EClass getForkedToken();
EClass getForkedToken();
/** * Returns the meta object for class '{@link org.gemoc.activitydiagram.concurrent.xactivitydiagrammt.activitydiagram.ForkedToken <em>Forked Token</em>}'. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @return the meta object for class '<em>Forked Token</em>'. * @see org.gemoc.activitydiagram.concurren...
Returns the meta object for class '<code>org.gemoc.activitydiagram.concurrent.xactivitydiagrammt.activitydiagram.ForkedToken Forked Token</code>'.
getForkedToken
{ "repo_name": "gemoc/activitydiagram", "path": "dev/gemoc_concurrent/language_workbench/org.gemoc.activitydiagram.concurrent/src-gen/org/gemoc/activitydiagram/concurrent/xactivitydiagrammt/activitydiagram/ActivitydiagramPackage.java", "license": "epl-1.0", "size": 147901 }
[ "org.eclipse.emf.ecore.EClass" ]
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
544,069
private static long getMaxDimension( MatrixIndexes key, MatrixValue value, boolean row ) { if( value instanceof MatrixCell ) return row ? key.getRowIndex() : key.getColumnIndex(); else if( value instanceof MatrixBlock ) return row ? value.getNumRows() : value.getNumColumns(); return 0; }
static long function( MatrixIndexes key, MatrixValue value, boolean row ) { if( value instanceof MatrixCell ) return row ? key.getRowIndex() : key.getColumnIndex(); else if( value instanceof MatrixBlock ) return row ? value.getNumRows() : value.getNumColumns(); return 0; }
/** * Returns the maximum row or column dimension of the given key and value pair. * * @param key matrix indexes * @param value MatrixValue of either type MatrixCell or MatrixBlock * @param row if true return row dimension, else return column dimension * @return maximum row or column dimension, or 0 if Ma...
Returns the maximum row or column dimension of the given key and value pair
getMaxDimension
{ "repo_name": "deroneriksson/incubator-systemml", "path": "src/main/java/org/apache/sysml/runtime/matrix/mapred/MRBaseForCommonInstructions.java", "license": "apache-2.0", "size": 13683 }
[ "org.apache.sysml.runtime.matrix.data.MatrixBlock", "org.apache.sysml.runtime.matrix.data.MatrixCell", "org.apache.sysml.runtime.matrix.data.MatrixIndexes", "org.apache.sysml.runtime.matrix.data.MatrixValue" ]
import org.apache.sysml.runtime.matrix.data.MatrixBlock; import org.apache.sysml.runtime.matrix.data.MatrixCell; import org.apache.sysml.runtime.matrix.data.MatrixIndexes; import org.apache.sysml.runtime.matrix.data.MatrixValue;
import org.apache.sysml.runtime.matrix.data.*;
[ "org.apache.sysml" ]
org.apache.sysml;
904,866
public void setValidator(Validator validator) { this.validator = validator; }
void function(Validator validator) { this.validator = validator; }
/** * Set the bean validator used to validate property fields. * @param validator the validator */
Set the bean validator used to validate property fields
setValidator
{ "repo_name": "javyzheng/spring-boot", "path": "spring-boot/src/main/java/org/springframework/boot/context/properties/ConfigurationPropertiesBindingPostProcessor.java", "license": "apache-2.0", "size": 16943 }
[ "org.springframework.validation.Validator" ]
import org.springframework.validation.Validator;
import org.springframework.validation.*;
[ "org.springframework.validation" ]
org.springframework.validation;
2,260,610
@Override public int getLoopPositionByFrame() { int bytesPerChannelForFrame = TinySound.FORMAT.getFrameSize() / TinySound.FORMAT.getChannels(); long byteIndex = this.reference.getLoopPosition(); return (int)(byteIndex / bytesPerChannelForFrame); }
int function() { int bytesPerChannelForFrame = TinySound.FORMAT.getFrameSize() / TinySound.FORMAT.getChannels(); long byteIndex = this.reference.getLoopPosition(); return (int)(byteIndex / bytesPerChannelForFrame); }
/** * Get the loop position of this MemMusic by sample frame. * @return loop position by sample frame */
Get the loop position of this MemMusic by sample frame
getLoopPositionByFrame
{ "repo_name": "TyrfingX/TyrLib", "path": "com.tyrfing.games.tyrlib3.tinysound/src/com/tyrfing/games/tyrlib3/tinysound/internal/MemMusic.java", "license": "mit", "size": 14338 }
[ "com.tyrfing.games.tyrlib3.tinysound.TinySound" ]
import com.tyrfing.games.tyrlib3.tinysound.TinySound;
import com.tyrfing.games.tyrlib3.tinysound.*;
[ "com.tyrfing.games" ]
com.tyrfing.games;
1,930,740
public void createEmptyObject(String key) throws QiniuException { com.qiniu.http.Response response = mUploadManager.put(new byte[0], key, mAuth.uploadToken(mBucketName, key)); response.close(); }
void function(String key) throws QiniuException { com.qiniu.http.Response response = mUploadManager.put(new byte[0], key, mAuth.uploadToken(mBucketName, key)); response.close(); }
/** * Creates empty Object in Qiniu kodo. * @param key empty Object key */
Creates empty Object in Qiniu kodo
createEmptyObject
{ "repo_name": "aaudiber/alluxio", "path": "underfs/kodo/src/main/java/alluxio/underfs/kodo/KodoClient.java", "license": "apache-2.0", "size": 5848 }
[ "com.qiniu.common.QiniuException" ]
import com.qiniu.common.QiniuException;
import com.qiniu.common.*;
[ "com.qiniu.common" ]
com.qiniu.common;
2,150,874
String getServiceUrl(final WgsBoundingBox boundingBox, final int zoom);
String getServiceUrl(final WgsBoundingBox boundingBox, final int zoom);
/** * Called after if needsUpdate has returned true. * * @param boundingBox * bounding box for screen view of the map (coordinates in WGS84) * @param zoom * zoom level used * @return url for retrieving displayed kml. */
Called after if needsUpdate has returned true
getServiceUrl
{ "repo_name": "camptocamp/maps-lib-nutiteq", "path": "src/com/nutiteq/kml/KmlService.java", "license": "gpl-2.0", "size": 1229 }
[ "com.nutiteq.components.WgsBoundingBox" ]
import com.nutiteq.components.WgsBoundingBox;
import com.nutiteq.components.*;
[ "com.nutiteq.components" ]
com.nutiteq.components;
990,766
public void setCountryCode(String country, boolean persist) { try { mService.setCountryCode(country, persist); } catch (RemoteException e) { } }
void function(String country, boolean persist) { try { mService.setCountryCode(country, persist); } catch (RemoteException e) { } }
/** * Set the country code. * @param countryCode country code in ISO 3166 format. * @param persist {@code true} if this needs to be remembered * * @hide */
Set the country code
setCountryCode
{ "repo_name": "rex-xxx/mt6572_x201", "path": "frameworks/base/wifi/java/android/net/wifi/WifiManager.java", "license": "gpl-2.0", "size": 82514 }
[ "android.os.RemoteException" ]
import android.os.RemoteException;
import android.os.*;
[ "android.os" ]
android.os;
1,882,738
public Observable<ServiceResponse<ExpressRouteCircuitStatsInner>> getStatsWithServiceResponseAsync(String resourceGroupName, String circuitName) { if (resourceGroupName == null) { throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); } ...
Observable<ServiceResponse<ExpressRouteCircuitStatsInner>> function(String resourceGroupName, String circuitName) { if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (circuitName == null) { throw new IllegalArgumentException(STR); } if (this.client.subscriptionId() == null) { throw new Ille...
/** * Gets all the stats from an express route circuit in a resource group. * * @param resourceGroupName The name of the resource group. * @param circuitName The name of the express route circuit. * @throws IllegalArgumentException thrown if parameters fail the validation * @return the obs...
Gets all the stats from an express route circuit in a resource group
getStatsWithServiceResponseAsync
{ "repo_name": "selvasingh/azure-sdk-for-java", "path": "sdk/network/mgmt-v2019_11_01/src/main/java/com/microsoft/azure/management/network/v2019_11_01/implementation/ExpressRouteCircuitsInner.java", "license": "mit", "size": 117005 }
[ "com.microsoft.rest.ServiceResponse" ]
import com.microsoft.rest.ServiceResponse;
import com.microsoft.rest.*;
[ "com.microsoft.rest" ]
com.microsoft.rest;
1,227,891
public void put(DataSink destDataSink, boolean space, boolean newline) throws SQLException, IOException, AS400SecurityException, ErrorCompletingRequestException, InterruptedException, ObjectDoesNotExistException, RequestNotSupportedException { put(destDataSink, false, space, newline); }
void function(DataSink destDataSink, boolean space, boolean newline) throws SQLException, IOException, AS400SecurityException, ErrorCompletingRequestException, InterruptedException, ObjectDoesNotExistException, RequestNotSupportedException { put(destDataSink, false, space, newline); }
/** * Put our object to the destination with an optional newline and/or * optional trailing blank space if to STD * * @param destDataSink destination * @param space true if add a blank space to end of string * @param newline true if newline should be appended, false if space * appende...
Put our object to the destination with an optional newline and/or optional trailing blank space if to STD
put
{ "repo_name": "jwoehr/Ubloid", "path": "AndroidStudioProject/ubloid/app/src/main/java/ublu/util/Putter.java", "license": "bsd-2-clause", "size": 10450 }
[ "com.ibm.as400.access.AS400SecurityException", "com.ibm.as400.access.ErrorCompletingRequestException", "com.ibm.as400.access.ObjectDoesNotExistException", "com.ibm.as400.access.RequestNotSupportedException", "java.io.IOException", "java.sql.SQLException" ]
import com.ibm.as400.access.AS400SecurityException; import com.ibm.as400.access.ErrorCompletingRequestException; import com.ibm.as400.access.ObjectDoesNotExistException; import com.ibm.as400.access.RequestNotSupportedException; import java.io.IOException; import java.sql.SQLException;
import com.ibm.as400.access.*; import java.io.*; import java.sql.*;
[ "com.ibm.as400", "java.io", "java.sql" ]
com.ibm.as400; java.io; java.sql;
526,439
ILSMDiskComponentId getComponentId() throws HyracksDataException;
ILSMDiskComponentId getComponentId() throws HyracksDataException;
/** * Return the component Id of this disk component from its metadata * @return * @throws HyracksDataException */
Return the component Id of this disk component from its metadata
getComponentId
{ "repo_name": "heriram/incubator-asterixdb", "path": "hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/api/ILSMDiskComponent.java", "license": "apache-2.0", "size": 1776 }
[ "org.apache.hyracks.api.exceptions.HyracksDataException" ]
import org.apache.hyracks.api.exceptions.HyracksDataException;
import org.apache.hyracks.api.exceptions.*;
[ "org.apache.hyracks" ]
org.apache.hyracks;
713,488
private static URL getResource(String name) { return FrameworkApplication.class.getResource(name); } // ********** constructor/initialization ********** private FrameworkApplication(Logger logger, Preferences preferences, boolean firstExecution, boolean developmentMode) { super(); this.firstEx...
static URL function(String name) { return FrameworkApplication.class.getResource(name); } private FrameworkApplication(Logger logger, Preferences preferences, boolean firstExecution, boolean developmentMode) { super(); this.firstExecution = firstExecution; this.logger = logger; this.developmentMode = developmentMode; t...
/** * Return the URL of the specified resource on the classpath. */
Return the URL of the specified resource on the classpath
getResource
{ "repo_name": "bfg-repo-cleaner-demos/eclipselink.runtime-bfg-strip-big-blobs", "path": "utils/eclipselink.utils.workbench/framework/source/org/eclipse/persistence/tools/workbench/framework/internal/FrameworkApplication.java", "license": "epl-1.0", "size": 35396 }
[ "java.util.logging.Logger", "java.util.prefs.Preferences" ]
import java.util.logging.Logger; import java.util.prefs.Preferences;
import java.util.logging.*; import java.util.prefs.*;
[ "java.util" ]
java.util;
2,547,694
@SkylarkCallable(name = "default_shell_env", structField = true, doc = "A dictionary representing the default environment. It maps variables " + "to their values (strings).") public ImmutableMap<String, String> getDefaultShellEnvironment() { return defaultShellEnvironment; }
@SkylarkCallable(name = STR, structField = true, doc = STR + STR) ImmutableMap<String, String> function() { return defaultShellEnvironment; }
/** * Returns the default shell environment */
Returns the default shell environment
getDefaultShellEnvironment
{ "repo_name": "Krasnyanskiy/bazel", "path": "src/main/java/com/google/devtools/build/lib/analysis/config/BuildConfiguration.java", "license": "apache-2.0", "size": 74047 }
[ "com.google.common.collect.ImmutableMap", "com.google.devtools.build.lib.syntax.SkylarkCallable" ]
import com.google.common.collect.ImmutableMap; import com.google.devtools.build.lib.syntax.SkylarkCallable;
import com.google.common.collect.*; import com.google.devtools.build.lib.syntax.*;
[ "com.google.common", "com.google.devtools" ]
com.google.common; com.google.devtools;
2,725,071
@Override public ChatGroupMember rename(Name name) { return new ChatGroupMember(name, null); }
ChatGroupMember function(Name name) { return new ChatGroupMember(name, null); }
/** * Rename this table */
Rename this table
rename
{ "repo_name": "seventhroot/elysium", "path": "bukkit/rpk-chat-bukkit/src/main/java/com/rpkit/chat/bukkit/database/jooq/rpkit/tables/ChatGroupMember.java", "license": "apache-2.0", "size": 4494 }
[ "org.jooq.Name" ]
import org.jooq.Name;
import org.jooq.*;
[ "org.jooq" ]
org.jooq;
46,644
public static ConfigurationData readConfigurationData(final URL url) throws IOException { List<ConfigurationFormat> formats = getFormats(url); return readConfigurationData(url, formats.toArray(new ConfigurationFormat[formats.size()])); }
static ConfigurationData function(final URL url) throws IOException { List<ConfigurationFormat> formats = getFormats(url); return readConfigurationData(url, formats.toArray(new ConfigurationFormat[formats.size()])); }
/** * Tries to read configuration data from a given URL, hereby traversing all known formats in order of precedence. * Hereby the formats are first filtered to check if the URL is acceptable, before the input is being parsed. * * @param url the url from where to read, not null. * @return the Co...
Tries to read configuration data from a given URL, hereby traversing all known formats in order of precedence. Hereby the formats are first filtered to check if the URL is acceptable, before the input is being parsed
readConfigurationData
{ "repo_name": "syzer/incubator-tamaya", "path": "modules/formats/src/main/java/org/apache/tamaya/format/ConfigurationFormats.java", "license": "apache-2.0", "size": 6957 }
[ "java.io.IOException", "java.util.List" ]
import java.io.IOException; import java.util.List;
import java.io.*; import java.util.*;
[ "java.io", "java.util" ]
java.io; java.util;
333,152