method stringlengths 13 441k | clean_method stringlengths 7 313k | doc stringlengths 17 17.3k | comment stringlengths 3 1.42k | method_name stringlengths 1 273 | extra dict | imports list | imports_info stringlengths 19 34.8k | cluster_imports_info stringlengths 15 3.66k | libraries list | libraries_info stringlengths 6 661 | id int64 0 2.92M |
|---|---|---|---|---|---|---|---|---|---|---|---|
@Override
public void setObject(int parameterIndex, Object x) throws SQLException {
synchronized (checkClosed().getConnectionMutex()) {
super.setObject(parameterIndex, JDBC42Helper.convertJavaTimeToJavaSql(x));
}
} | void function(int parameterIndex, Object x) throws SQLException { synchronized (checkClosed().getConnectionMutex()) { super.setObject(parameterIndex, JDBC42Helper.convertJavaTimeToJavaSql(x)); } } | /**
* Support for java.time.LocalDate, java.time.LocalTime, java.time.LocalDateTime, java.time.OffsetTime and java.time.OffsetDateTime.
*
* @param parameterIndex
* @param x
* @throws SQLException
*/ | Support for java.time.LocalDate, java.time.LocalTime, java.time.LocalDateTime, java.time.OffsetTime and java.time.OffsetDateTime | setObject | {
"repo_name": "scopej/mysql-connector-j",
"path": "src/com/mysql/jdbc/JDBC42CallableStatement.java",
"license": "gpl-2.0",
"size": 8518
} | [
"java.sql.SQLException"
] | import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 1,504,445 |
@Test
public void pipeline_Fi_14() throws IOException {
final String methodName = FiTestUtil.getMethodName();
runCallWritePacketToDisk(methodName, 0, new DoosAction(methodName, 0));
} | void function() throws IOException { final String methodName = FiTestUtil.getMethodName(); runCallWritePacketToDisk(methodName, 0, new DoosAction(methodName, 0)); } | /**
* Streaming: Write a packet, DN0 throws a DiskOutOfSpaceError
* when it writes the data to disk.
* Client gets an IOException and determine DN0 bad.
*/ | Streaming: Write a packet, DN0 throws a DiskOutOfSpaceError when it writes the data to disk. Client gets an IOException and determine DN0 bad | pipeline_Fi_14 | {
"repo_name": "tseen/Federated-HDFS",
"path": "tseenliu/FedHDFS-hadoop-src/hadoop-hdfs-project/hadoop-hdfs/src/test/aop/org/apache/hadoop/hdfs/server/datanode/TestFiDataTransferProtocol.java",
"license": "apache-2.0",
"size": 11123
} | [
"java.io.IOException",
"org.apache.hadoop.fi.DataTransferTestUtil",
"org.apache.hadoop.fi.FiTestUtil"
] | import java.io.IOException; import org.apache.hadoop.fi.DataTransferTestUtil; import org.apache.hadoop.fi.FiTestUtil; | import java.io.*; import org.apache.hadoop.fi.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 2,293,841 |
private static <T> ConvertibleType<T> of(Type genericType) {
final Class<T> targetType;
if (genericType instanceof Class) {
targetType = (Class<T>)genericType;
} else if (genericType instanceof ParameterizedType) {
targetType = (Class<T>)((ParameterizedType)genericTyp... | static <T> ConvertibleType<T> function(Type genericType) { final Class<T> targetType; if (genericType instanceof Class) { targetType = (Class<T>)genericType; } else if (genericType instanceof ParameterizedType) { targetType = (Class<T>)((ParameterizedType)genericType).getRawType(); } else if (genericType.toString().equ... | /**
* Returns the conversion type for the generic type.
*/ | Returns the conversion type for the generic type | of | {
"repo_name": "aws/aws-sdk-java",
"path": "aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/datamodeling/ConvertibleType.java",
"license": "apache-2.0",
"size": 7207
} | [
"com.amazonaws.services.dynamodbv2.datamodeling.StandardAnnotationMaps",
"java.lang.reflect.ParameterizedType",
"java.lang.reflect.Type"
] | import com.amazonaws.services.dynamodbv2.datamodeling.StandardAnnotationMaps; import java.lang.reflect.ParameterizedType; import java.lang.reflect.Type; | import com.amazonaws.services.dynamodbv2.datamodeling.*; import java.lang.reflect.*; | [
"com.amazonaws.services",
"java.lang"
] | com.amazonaws.services; java.lang; | 1,607,234 |
public void toggleMetricsMode() {
MetricsMode mode = debugMetricsSystem.toggle();
PerformanceMonitor.setEnabled(mode.isPerformanceManagerMode());
} | void function() { MetricsMode mode = debugMetricsSystem.toggle(); PerformanceMonitor.setEnabled(mode.isPerformanceManagerMode()); } | /**
* Moves forward through the MetricsMode instances and displays the content of the next available one.
*/ | Moves forward through the MetricsMode instances and displays the content of the next available one | toggleMetricsMode | {
"repo_name": "Malanius/Terasology",
"path": "engine/src/main/java/org/terasology/rendering/nui/layers/ingame/metrics/DebugOverlay.java",
"license": "apache-2.0",
"size": 8166
} | [
"org.terasology.monitoring.PerformanceMonitor"
] | import org.terasology.monitoring.PerformanceMonitor; | import org.terasology.monitoring.*; | [
"org.terasology.monitoring"
] | org.terasology.monitoring; | 464,441 |
public void setOldNodes(Set oldNodes) { this.oldNodes = oldNodes; } | public void setOldNodes(Set oldNodes) { this.oldNodes = oldNodes; } | /**
* Implemented as specified by the {@link Layout} interface.
* @see Layout#getIndex()
*/ | Implemented as specified by the <code>Layout</code> interface | getIndex | {
"repo_name": "jballanc/openmicroscopy",
"path": "components/insight/SRC/org/openmicroscopy/shoola/agents/dataBrowser/layout/FlatLayout.java",
"license": "gpl-2.0",
"size": 4741
} | [
"java.util.Set"
] | import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 2,593,186 |
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
final View view = inflater.inflate(R.layout.fragment_friend_search, null);
listViewAdapter = new SearchListAdapter(getActivity());
init(view);
return view;
} | View function(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { final View view = inflater.inflate(R.layout.fragment_friend_search, null); listViewAdapter = new SearchListAdapter(getActivity()); init(view); return view; } | /**
* TODO Javadoc
*/ | TODO Javadoc | onCreateView | {
"repo_name": "RomanCPodolski/HMCheckin",
"path": "src/main/java/hm/edu/hmcheckin/ui/FriendSearchFragment.java",
"license": "mit",
"size": 5496
} | [
"android.os.Bundle",
"android.view.LayoutInflater",
"android.view.View",
"android.view.ViewGroup"
] | import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; | import android.os.*; import android.view.*; | [
"android.os",
"android.view"
] | android.os; android.view; | 1,728,944 |
private void write(List<Map<AttributeInterface, Object>> masterList, int num) throws Exception {
BufferedWriter bos = new BufferedWriter(new FileWriter(new File("c:/test" + num + ".csv")));
for (AttributeInterface a : allowedAttributes) {
bos.write(a.getName());
bos.write... | void function(List<Map<AttributeInterface, Object>> masterList, int num) throws Exception { BufferedWriter bos = new BufferedWriter(new FileWriter(new File(STR + num + ".csv"))); for (AttributeInterface a : allowedAttributes) { bos.write(a.getName()); bos.write(","); } bos.write("\n"); for (Map<AttributeInterface, Obje... | /**
* Writes output into csv file.
* @param masterList
* @param num
* @throws Exception
*/ | Writes output into csv file | write | {
"repo_name": "NCIP/cab2b",
"path": "software/cab2bWebApp/test/unit/java/edu/wustl/cab2bwebapp/bizlogic/executequery/CategoryToSpreadsheetTransformerTest.java",
"license": "bsd-3-clause",
"size": 13181
} | [
"edu.common.dynamicextensions.domaininterface.AttributeInterface",
"java.io.BufferedWriter",
"java.io.File",
"java.io.FileWriter",
"java.util.List",
"java.util.Map"
] | import edu.common.dynamicextensions.domaininterface.AttributeInterface; import java.io.BufferedWriter; import java.io.File; import java.io.FileWriter; import java.util.List; import java.util.Map; | import edu.common.dynamicextensions.domaininterface.*; import java.io.*; import java.util.*; | [
"edu.common.dynamicextensions",
"java.io",
"java.util"
] | edu.common.dynamicextensions; java.io; java.util; | 1,137,706 |
public void copyQuotedContent(final CharArrayBuffer buf, final ParserCursor cursor,
final StringBuilder dst) {
if (cursor.atEnd()) {
return;
}
int pos = cursor.getPos();
int indexFrom = cursor.getPos();
final int indexTo = cursor.getUpperBound();
... | void function(final CharArrayBuffer buf, final ParserCursor cursor, final StringBuilder dst) { if (cursor.atEnd()) { return; } int pos = cursor.getPos(); int indexFrom = cursor.getPos(); final int indexTo = cursor.getUpperBound(); char current = buf.charAt(pos); if (current != DQUOTE) { return; } pos++; indexFrom++; bo... | /**
* Transfers content enclosed with quote marks into the destination buffer.
*
* @param buf buffer with the sequence of chars to be parsed
* @param cursor defines the bounds and current position of the buffer
* @param dst destination buffer
*/ | Transfers content enclosed with quote marks into the destination buffer | copyQuotedContent | {
"repo_name": "cictourgune/MDP-Airbnb",
"path": "httpcomponents-core-4.4/httpcore/src/main/java/org/apache/http/message/TokenParser.java",
"license": "apache-2.0",
"size": 9868
} | [
"org.apache.http.util.CharArrayBuffer"
] | import org.apache.http.util.CharArrayBuffer; | import org.apache.http.util.*; | [
"org.apache.http"
] | org.apache.http; | 2,038,822 |
@GuardedBy("this")
ReferenceEntry<K, V> copyEntry(ReferenceEntry<K, V> original, ReferenceEntry<K, V> newNext) {
if (original.getKey() == null) {
// key collected
return null;
}
ValueReference<K, V> valueReference = original.getValueReference();
V value = valueReference.... | @GuardedBy("this") ReferenceEntry<K, V> copyEntry(ReferenceEntry<K, V> original, ReferenceEntry<K, V> newNext) { if (original.getKey() == null) { return null; } ValueReference<K, V> valueReference = original.getValueReference(); V value = valueReference.get(); if ((value == null) && valueReference.isActive()) { return ... | /**
* Copies {@code original} into a new entry chained to {@code newNext}. Returns the new entry,
* or {@code null} if {@code original} was already garbage collected.
*/ | Copies original into a new entry chained to newNext. Returns the new entry, or null if original was already garbage collected | copyEntry | {
"repo_name": "DavesMan/guava",
"path": "guava/src/com/google/common/cache/LocalCache.java",
"license": "apache-2.0",
"size": 153965
} | [
"javax.annotation.concurrent.GuardedBy"
] | import javax.annotation.concurrent.GuardedBy; | import javax.annotation.concurrent.*; | [
"javax.annotation"
] | javax.annotation; | 21,964 |
public final AlertDialog shareText(CharSequence text, CharSequence type) {
Intent intent = new Intent();
intent.addCategory(Intent.CATEGORY_DEFAULT);
intent.setAction(BS_PACKAGE + ".ENCODE");
intent.putExtra("ENCODE_TYPE", type);
intent.putExtra("ENCODE_DATA", text);
String targetAppPack... | final AlertDialog function(CharSequence text, CharSequence type) { Intent intent = new Intent(); intent.addCategory(Intent.CATEGORY_DEFAULT); intent.setAction(BS_PACKAGE + STR); intent.putExtra(STR, type); intent.putExtra(STR, text); String targetAppPackage = findTargetAppPackage(intent); if (targetAppPackage == null) ... | /**
* Shares the given text by encoding it as a barcode, such that another user can
* scan the text off the screen of the device.
*
* @param text the text string to encode as a barcode
* @param type type of data to encode. See {@code com.google.zxing.client.android.Contents.Type} constants.
* @r... | Shares the given text by encoding it as a barcode, such that another user can scan the text off the screen of the device | shareText | {
"repo_name": "nahueltori/aplinf-android-superprecios",
"path": "SuperPrecios/src/com/google/zxing/integration/android/IntentIntegrator.java",
"license": "gpl-2.0",
"size": 16197
} | [
"android.app.AlertDialog",
"android.content.Intent"
] | import android.app.AlertDialog; import android.content.Intent; | import android.app.*; import android.content.*; | [
"android.app",
"android.content"
] | android.app; android.content; | 2,523,181 |
@Override
protected OAuthValidator<HttpServletRequest> initValidator() throws OAuthProblemException, OAuthSystemException {
String requestTypeValue = getParam(OAuth.OAUTH_GRANT_TYPE);
if (OAuthUtils.isEmpty(requestTypeValue)) {
throw OAuthUtils.handleOAuthProblemException("Missing g... | OAuthValidator<HttpServletRequest> function() throws OAuthProblemException, OAuthSystemException { String requestTypeValue = getParam(OAuth.OAUTH_GRANT_TYPE); if (OAuthUtils.isEmpty(requestTypeValue)) { throw OAuthUtils.handleOAuthProblemException(STR); } Class<? extends OAuthValidator<HttpServletRequest>> clazz = OAut... | /**
* Initialize a grant type validator
*
* @return an instance of OAuthValidator
* @throws OAuthProblemException
* @throws OAuthSystemException
*/ | Initialize a grant type validator | initValidator | {
"repo_name": "prabathabey/carbon-identity",
"path": "components/oauth/org.wso2.carbon.identity.oauth/src/main/java/org/wso2/carbon/identity/oauth2/model/CarbonOAuthTokenRequest.java",
"license": "apache-2.0",
"size": 5331
} | [
"javax.servlet.http.HttpServletRequest",
"org.apache.oltu.oauth2.common.OAuth",
"org.apache.oltu.oauth2.common.exception.OAuthProblemException",
"org.apache.oltu.oauth2.common.exception.OAuthSystemException",
"org.apache.oltu.oauth2.common.utils.OAuthUtils",
"org.apache.oltu.oauth2.common.validators.OAuth... | import javax.servlet.http.HttpServletRequest; import org.apache.oltu.oauth2.common.OAuth; import org.apache.oltu.oauth2.common.exception.OAuthProblemException; import org.apache.oltu.oauth2.common.exception.OAuthSystemException; import org.apache.oltu.oauth2.common.utils.OAuthUtils; import org.apache.oltu.oauth2.common... | import javax.servlet.http.*; import org.apache.oltu.oauth2.common.*; import org.apache.oltu.oauth2.common.exception.*; import org.apache.oltu.oauth2.common.utils.*; import org.apache.oltu.oauth2.common.validators.*; import org.wso2.carbon.identity.oauth.config.*; | [
"javax.servlet",
"org.apache.oltu",
"org.wso2.carbon"
] | javax.servlet; org.apache.oltu; org.wso2.carbon; | 1,978,031 |
public int showCancelableIntent(Intent intent, IntentCallback callback, int errorId) {
Log.d(TAG, "Can't show intent as context is not an Activity: " + intent);
return START_INTENT_FAILURE;
} | int function(Intent intent, IntentCallback callback, int errorId) { Log.d(TAG, STR + intent); return START_INTENT_FAILURE; } | /**
* Shows an intent that could be canceled and returns the results to the callback object.
* @param intent The intent that needs to be showed.
* @param callback The object that will receive the results for the intent.
* @param errorId The ID of error string to be show if activity is paused b... | Shows an intent that could be canceled and returns the results to the callback object | showCancelableIntent | {
"repo_name": "sencha/chromium-spacewalk",
"path": "ui/android/java/src/org/chromium/ui/base/WindowAndroid.java",
"license": "bsd-3-clause",
"size": 11297
} | [
"android.content.Intent",
"android.util.Log"
] | import android.content.Intent; import android.util.Log; | import android.content.*; import android.util.*; | [
"android.content",
"android.util"
] | android.content; android.util; | 1,553,872 |
EReference getStateMachine_States(); | EReference getStateMachine_States(); | /**
* Returns the meta object for the containment reference list '{@link statemachine.StateMachine#getStates <em>States</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the containment reference list '<em>States</em>'.
* @see statemachine.StateMachine#getStates()
* @se... | Returns the meta object for the containment reference list '<code>statemachine.StateMachine#getStates States</code>'. | getStateMachine_States | {
"repo_name": "ujhelyiz/viatra2-programunderstanding",
"path": "metamodel/statemachine/src/statemachine/StatemachinePackage.java",
"license": "epl-1.0",
"size": 14513
} | [
"org.eclipse.emf.ecore.EReference"
] | import org.eclipse.emf.ecore.EReference; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 663,392 |
InputStream getContent(); | InputStream getContent(); | /**
* Returns the optional stream containing the payload data to include for
* this request. Not all requests will contain payload data.
*
* @return The optional stream containing the payload data to include for
* this request.
*/ | Returns the optional stream containing the payload data to include for this request. Not all requests will contain payload data | getContent | {
"repo_name": "flofreud/aws-sdk-java",
"path": "aws-java-sdk-core/src/main/java/com/amazonaws/SignableRequest.java",
"license": "apache-2.0",
"size": 4597
} | [
"java.io.InputStream"
] | import java.io.InputStream; | import java.io.*; | [
"java.io"
] | java.io; | 1,031,256 |
public boolean isGwtSerializable() {
Preconditions.checkState(
!_unsetProperties.contains(Metadata_Builder.Property.GWT_SERIALIZABLE),
"gwtSerializable not set");
return gwtSerializable;
}
private static final class Value extends Metadata {
// Store a nullable object instead of an Opt... | boolean function() { Preconditions.checkState( !_unsetProperties.contains(Metadata_Builder.Property.GWT_SERIALIZABLE), STR); return gwtSerializable; } private static final class Value extends Metadata { private final BuilderFactory builderFactory; private final QualifiedName generatedBuilder; private final TypeElement ... | /**
* Returns the value that will be returned by {@link Metadata#isGwtSerializable()}.
*
* @throws IllegalStateException if the field has not been set
*/ | Returns the value that will be returned by <code>Metadata#isGwtSerializable()</code> | isGwtSerializable | {
"repo_name": "hejunbinlan/FreeBuilder",
"path": "src/main/java/org/inferred/freebuilder/processor/Metadata_Builder.java",
"license": "apache-2.0",
"size": 38537
} | [
"com.google.common.base.Preconditions",
"com.google.common.collect.ImmutableList",
"com.google.common.collect.ImmutableMap",
"com.google.common.collect.ImmutableSet",
"javax.lang.model.element.TypeElement",
"org.inferred.freebuilder.processor.BuilderFactory",
"org.inferred.freebuilder.processor.Metadata... | import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableSet; import javax.lang.model.element.TypeElement; import org.inferred.freebuilder.processor.BuilderFactory; import org.inferred.freebuilde... | import com.google.common.base.*; import com.google.common.collect.*; import javax.lang.model.element.*; import org.inferred.freebuilder.processor.*; import org.inferred.freebuilder.processor.util.*; | [
"com.google.common",
"javax.lang",
"org.inferred.freebuilder"
] | com.google.common; javax.lang; org.inferred.freebuilder; | 1,034,018 |
public static void printLtl2dstar(DA<BitSet, AcceptanceRabin> dra, PrintStream out) throws PrismException {
AcceptanceRabin acceptance = dra.getAcceptance();
if (dra.getStartState() < 0) {
// No start state!
throw new PrismException("No start state in DA!");
}
out.println("DRA v2 explicit");
out.p... | static void function(DA<BitSet, AcceptanceRabin> dra, PrintStream out) throws PrismException { AcceptanceRabin acceptance = dra.getAcceptance(); if (dra.getStartState() < 0) { throw new PrismException(STR); } out.println(STR); out.println(STR + dra.size()); out.println(STR + acceptance.size()); out.println(STR + dra.ge... | /**
* Print the DRA in ltl2dstar v2 format to the output stream.
* @param out the output stream
*/ | Print the DRA in ltl2dstar v2 format to the output stream | printLtl2dstar | {
"repo_name": "nicodelpiano/prism",
"path": "src/automata/DA.java",
"license": "gpl-2.0",
"size": 11022
} | [
"java.io.PrintStream",
"java.util.BitSet"
] | import java.io.PrintStream; import java.util.BitSet; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 2,777,201 |
public String getUserName() throws SQLException {
if (JdbcDebugCfg.entryActive)
debug[methodId_getUserName].methodEntry();
try {
return connection_.uid_;
} finally {
if (JdbcDebugCfg.entryActive)
debug[methodId_getUserName].methodExit();
}
} | String function() throws SQLException { if (JdbcDebugCfg.entryActive) debug[methodId_getUserName].methodEntry(); try { return connection_.uid_; } finally { if (JdbcDebugCfg.entryActive) debug[methodId_getUserName].methodExit(); } } | /**
* Retrieves the user name as known to this database.
*
* @return the database user name
* @throws SQLException
* - if a database access error occurs
**/ | Retrieves the user name as known to this database | getUserName | {
"repo_name": "mashengchen/incubator-trafodion",
"path": "core/conn/jdbc_type2/src/main/java/org/apache/trafodion/jdbc/t2/SQLMXDatabaseMetaData.java",
"license": "apache-2.0",
"size": 191582
} | [
"java.sql.SQLException"
] | import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 2,236,184 |
@Override
public IModelDescriptor getSelectionModelDescriptor() {
return selectionModelDescriptor;
} | IModelDescriptor function() { return selectionModelDescriptor; } | /**
* Gets the selectionModelDescriptor.
*
* @return the selectionModelDescriptor.
*/ | Gets the selectionModelDescriptor | getSelectionModelDescriptor | {
"repo_name": "jspresso/jspresso-ce",
"path": "view/src/main/java/org/jspresso/framework/view/descriptor/basic/BasicCollectionViewDescriptor.java",
"license": "lgpl-3.0",
"size": 9811
} | [
"org.jspresso.framework.model.descriptor.IModelDescriptor"
] | import org.jspresso.framework.model.descriptor.IModelDescriptor; | import org.jspresso.framework.model.descriptor.*; | [
"org.jspresso.framework"
] | org.jspresso.framework; | 2,780,897 |
public static List<MutableDoubleTuple> deepCopy(
Collection<? extends DoubleTuple> tuples)
{
List<MutableDoubleTuple> result =
new ArrayList<MutableDoubleTuple>(tuples.size());
for (DoubleTuple t : tuples)
{
if (t == null)
{
... | static List<MutableDoubleTuple> function( Collection<? extends DoubleTuple> tuples) { List<MutableDoubleTuple> result = new ArrayList<MutableDoubleTuple>(tuples.size()); for (DoubleTuple t : tuples) { if (t == null) { result.add(null); } else { result.add(DoubleTuples.copy(t)); } } return result; } /** * Computes the c... | /**
* Returns a deep copy of the given collection of tuples. If any element
* of the given collection is <code>null</code>, then <code>null</code>
* will also be added to the target collection.
*
* @param tuples The input tuples
* @return The deep copy
*/ | Returns a deep copy of the given collection of tuples. If any element of the given collection is <code>null</code>, then <code>null</code> will also be added to the target collection | deepCopy | {
"repo_name": "javagl/ND",
"path": "nd-tuples/src/main/java/de/javagl/nd/tuples/d/DoubleTupleCollections.java",
"license": "mit",
"size": 23486
} | [
"de.javagl.nd.tuples.Tuple",
"java.util.ArrayList",
"java.util.Collection",
"java.util.List"
] | import de.javagl.nd.tuples.Tuple; import java.util.ArrayList; import java.util.Collection; import java.util.List; | import de.javagl.nd.tuples.*; import java.util.*; | [
"de.javagl.nd",
"java.util"
] | de.javagl.nd; java.util; | 517 |
@FIXVersion(introduced="5.0")
public TrdCapRptAckSideGroup deleteTrdCapRptAckSideGroup(int index) {
throw new UnsupportedOperationException(getUnsupportedTagMessage());
} | @FIXVersion(introduced="5.0") TrdCapRptAckSideGroup function(int index) { throw new UnsupportedOperationException(getUnsupportedTagMessage()); } | /**
* This method deletes a {@link TrdCapRptAckSideGroup} object from the existing array of <code>trdCapRptAckSideGroups</code>
* and shrink the static array with 1 place.<br/>
* If the array does not have the index position then a null object will be returned.)<br/>
* This method will also update <... | This method deletes a <code>TrdCapRptAckSideGroup</code> object from the existing array of <code>trdCapRptAckSideGroups</code> and shrink the static array with 1 place. If the array does not have the index position then a null object will be returned.) This method will also update <code>noSides</code> field to the prop... | deleteTrdCapRptAckSideGroup | {
"repo_name": "marvisan/HadesFIX",
"path": "Model/src/main/java/net/hades/fix/message/TradeCaptureReportAckMsg.java",
"license": "gpl-3.0",
"size": 118717
} | [
"net.hades.fix.message.anno.FIXVersion",
"net.hades.fix.message.group.TrdCapRptAckSideGroup"
] | import net.hades.fix.message.anno.FIXVersion; import net.hades.fix.message.group.TrdCapRptAckSideGroup; | import net.hades.fix.message.anno.*; import net.hades.fix.message.group.*; | [
"net.hades.fix"
] | net.hades.fix; | 544,624 |
public List<Column> asColumnObjects(Collection<Integer> cols) {
List<Column> objs = new ArrayList<Column>();
for(int i : cols) {
objs.add(this.memory.getObject(i));
}
return objs;
} | List<Column> function(Collection<Integer> cols) { List<Column> objs = new ArrayList<Column>(); for(int i : cols) { objs.add(this.memory.getObject(i)); } return objs; } | /**
* Returns a list of the {@link Column}s specified.
* @param cols the indexes of the {@link Column}s to return
* @return the specified list of columns
*/ | Returns a list of the <code>Column</code>s specified | asColumnObjects | {
"repo_name": "hgulcan/badr_htm",
"path": "src/main/java/org/numenta/nupic/Connections.java",
"license": "agpl-3.0",
"size": 51299
} | [
"java.util.ArrayList",
"java.util.Collection",
"java.util.List",
"org.numenta.nupic.model.Column"
] | import java.util.ArrayList; import java.util.Collection; import java.util.List; import org.numenta.nupic.model.Column; | import java.util.*; import org.numenta.nupic.model.*; | [
"java.util",
"org.numenta.nupic"
] | java.util; org.numenta.nupic; | 2,106,882 |
private int appendHeader(int field) {
switch (field) {
case PduHeaders.MMS_VERSION:
appendOctet(field);
int version = mPduHeader.getOctet(field);
if (0 == version) {
appendShortInteger(PduHeaders.CURRENT_MMS_VERSION);
... | int function(int field) { switch (field) { case PduHeaders.MMS_VERSION: appendOctet(field); int version = mPduHeader.getOctet(field); if (0 == version) { appendShortInteger(PduHeaders.CURRENT_MMS_VERSION); } else { appendShortInteger(version); } break; case PduHeaders.MESSAGE_ID: case PduHeaders.TRANSACTION_ID: byte[] ... | /**
* Append header to mMessage.
*/ | Append header to mMessage | appendHeader | {
"repo_name": "LinQingWei/Mms",
"path": "app/src/main/java/com/google/android/mms/pdu_alt/PduComposer.java",
"license": "apache-2.0",
"size": 38396
} | [
"android.text.TextUtils",
"java.util.Arrays"
] | import android.text.TextUtils; import java.util.Arrays; | import android.text.*; import java.util.*; | [
"android.text",
"java.util"
] | android.text; java.util; | 1,633,925 |
public void setValueFormat(DecimalFormat df) {
this.plot.setValueFormat(df);
}
| void function(DecimalFormat df) { this.plot.setValueFormat(df); } | /**
* Sets the value format for the thermometer.
*
* @param df the formatter.
*/ | Sets the value format for the thermometer | setValueFormat | {
"repo_name": "fluidware/Eastwood-Charts",
"path": "source/org/jfree/chart/plot/JThermometer.java",
"license": "lgpl-2.1",
"size": 10407
} | [
"java.text.DecimalFormat"
] | import java.text.DecimalFormat; | import java.text.*; | [
"java.text"
] | java.text; | 865,459 |
public void abort() throws IOException {
completeEdit(this, false);
}
private class FaultHidingOutputStream extends FilterOutputStream {
private FaultHidingOutputStream(OutputStream out) {
super(out);
} | void function() throws IOException { completeEdit(this, false); } private class FaultHidingOutputStream extends FilterOutputStream { private FaultHidingOutputStream(OutputStream out) { super(out); } | /**
* Aborts this edit. This releases the edit lock so another edit may be
* started on the same key.
*/ | Aborts this edit. This releases the edit lock so another edit may be started on the same key | abort | {
"repo_name": "Shaojia/ZHCarPocket",
"path": "MaintainService/src/com/coortouch/android/urlimagehelper/DiskLruCache.java",
"license": "mit",
"size": 33069
} | [
"java.io.FilterOutputStream",
"java.io.IOException",
"java.io.OutputStream"
] | import java.io.FilterOutputStream; import java.io.IOException; import java.io.OutputStream; | import java.io.*; | [
"java.io"
] | java.io; | 1,822,103 |
void onViewTap(View view, float x, float y);
}
private class AnimatedZoomRunnable implements Runnable {
// These are 'postScale' values, means they're compounded each iteration
static final float ANIMATION_SCALE_PER_ITERATION_IN = 1.07f;
static final float ANIMATION_SCALE_PER_ITERATION_OUT = 0.93f;
pr... | void onViewTap(View view, float x, float y); } private class AnimatedZoomRunnable implements Runnable { static final float ANIMATION_SCALE_PER_ITERATION_IN = 1.07f; static final float ANIMATION_SCALE_PER_ITERATION_OUT = 0.93f; private final float mFocalX, mFocalY; private final float mTargetZoom; private final float mD... | /**
* A callback to receive where the user taps on a ImageView. You will
* receive a callback if the user taps anywhere on the view, tapping on
* 'whitespace' will not be ignored.
*
* @param view
* - View the user tapped.
* @param x
* - where the user tapped from the left ... | A callback to receive where the user taps on a ImageView. You will receive a callback if the user taps anywhere on the view, tapping on 'whitespace' will not be ignored | onViewTap | {
"repo_name": "dreamchenzhou/MouseRace",
"path": "src/com/dreamchen/useful/mouserace/multipic/zoom/PhotoViewAttacher.java",
"license": "apache-2.0",
"size": 26193
} | [
"android.view.View"
] | import android.view.View; | import android.view.*; | [
"android.view"
] | android.view; | 2,414,539 |
public Observable<ServiceResponse<Void>> beginReimageWithServiceResponseAsync(String resourceGroupName, String vmScaleSetName, String instanceId) {
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
}
... | Observable<ServiceResponse<Void>> function(String resourceGroupName, String vmScaleSetName, String instanceId) { if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (vmScaleSetName == null) { throw new IllegalArgumentException(STR); } if (instanceId == null) { throw new IllegalArgumentExcepti... | /**
* Reimages (upgrade the operating system) a specific virtual machine in a VM scale set.
*
* @param resourceGroupName The name of the resource group.
* @param vmScaleSetName The name of the VM scale set.
* @param instanceId The instance ID of the virtual machine.
* @throws IllegalArgume... | Reimages (upgrade the operating system) a specific virtual machine in a VM scale set | beginReimageWithServiceResponseAsync | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/compute/mgmt-v2020_06_01/src/main/java/com/microsoft/azure/management/compute/v2020_06_01/implementation/VirtualMachineScaleSetVMsInner.java",
"license": "mit",
"size": 208201
} | [
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.rest.ServiceResponse; | import com.microsoft.rest.*; | [
"com.microsoft.rest"
] | com.microsoft.rest; | 335,974 |
@Deprecated public static <E> Iterable<E> unmodifiableIterable(
ImmutableCollection<E> iterable) {
return checkNotNull(iterable);
}
private static final class UnmodifiableIterable<T> extends FluentIterable<T> {
private final Iterable<T> iterable;
private UnmodifiableIterable(Iterable<T> iterab... | @Deprecated static <E> Iterable<E> function( ImmutableCollection<E> iterable) { return checkNotNull(iterable); } private static final class UnmodifiableIterable<T> extends FluentIterable<T> { private final Iterable<T> iterable; private UnmodifiableIterable(Iterable<T> iterable) { this.iterable = iterable; } | /**
* Simply returns its argument.
*
* @deprecated no need to use this
* @since 10.0
*/ | Simply returns its argument | unmodifiableIterable | {
"repo_name": "npvincent/guava",
"path": "guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/Iterables.java",
"license": "apache-2.0",
"size": 35923
} | [
"com.google.common.base.Preconditions"
] | import com.google.common.base.Preconditions; | import com.google.common.base.*; | [
"com.google.common"
] | com.google.common; | 1,163,212 |
public static Vertex vertexFromJson(final JsonNode json, final ElementFactory factory, final GraphSONMode mode,
final Set<String> propertyKeys) throws IOException {
final GraphSONUtility graphson = new GraphSONUtility(mode, factory, propertyKeys, null);
return... | static Vertex function(final JsonNode json, final ElementFactory factory, final GraphSONMode mode, final Set<String> propertyKeys) throws IOException { final GraphSONUtility graphson = new GraphSONUtility(mode, factory, propertyKeys, null); return graphson.vertexFromJson(json); } | /**
* Reads an individual Vertex from JSON. The vertex must match the accepted GraphSON format.
*
* @param json a single vertex in GraphSON format as Jackson JsonNode
* @param factory the factory responsible for constructing graph elements
* @param mode the mode of the Gra... | Reads an individual Vertex from JSON. The vertex must match the accepted GraphSON format | vertexFromJson | {
"repo_name": "echinopsii/net.echinopsii.3rdparty.blueprints",
"path": "blueprints-core/src/main/java/com/tinkerpop/blueprints/util/io/graphson/GraphSONUtility.java",
"license": "bsd-3-clause",
"size": 37947
} | [
"com.fasterxml.jackson.databind.JsonNode",
"com.tinkerpop.blueprints.Vertex",
"java.io.IOException",
"java.util.Set"
] | import com.fasterxml.jackson.databind.JsonNode; import com.tinkerpop.blueprints.Vertex; import java.io.IOException; import java.util.Set; | import com.fasterxml.jackson.databind.*; import com.tinkerpop.blueprints.*; import java.io.*; import java.util.*; | [
"com.fasterxml.jackson",
"com.tinkerpop.blueprints",
"java.io",
"java.util"
] | com.fasterxml.jackson; com.tinkerpop.blueprints; java.io; java.util; | 383,327 |
@PostConstruct
public void initApplication() throws IOException {
if (env.getActiveProfiles().length == 0) {
log.warn("No Spring profile configured, running with default configuration");
} else {
log.info("Running with Spring profile(s) : {}", Arrays.toString(env.getActiv... | void function() throws IOException { if (env.getActiveProfiles().length == 0) { log.warn(STR); } else { log.info(STR, Arrays.toString(env.getActiveProfiles())); Collection<String> activeProfiles = Arrays.asList(env.getActiveProfiles()); if (activeProfiles.contains(Constants.SPRING_PROFILE_DEVELOPMENT) && activeProfiles... | /**
* Initializes Apb.
* <p/>
* Spring profiles can be configured with a program arguments --spring.profiles.active=your-active-profile
* <p/>
* <p>
* You can find more information on how profiles work with JHipster on <a href="http://jhipster.github.io/profiles.html">http://jhipster.githu... | Initializes Apb. Spring profiles can be configured with a program arguments --spring.profiles.active=your-active-profile You can find more information on how profiles work with JHipster on HREF | initApplication | {
"repo_name": "Appverse/appverse-builder-api",
"path": "src/main/java/org/appverse/builder/Application.java",
"license": "mpl-2.0",
"size": 4459
} | [
"java.io.IOException",
"java.util.Arrays",
"java.util.Collection",
"org.appverse.builder.config.Constants"
] | import java.io.IOException; import java.util.Arrays; import java.util.Collection; import org.appverse.builder.config.Constants; | import java.io.*; import java.util.*; import org.appverse.builder.config.*; | [
"java.io",
"java.util",
"org.appverse.builder"
] | java.io; java.util; org.appverse.builder; | 2,854,367 |
public void load()
throws MBeanException, RuntimeOperationsException, InstanceNotFoundException; | void function() throws MBeanException, RuntimeOperationsException, InstanceNotFoundException; | /**
* Instantiates thisMBean instance with the data found for
* the MBean in the persistent store. The data loaded could include
* attribute and operation values.
*
* This method should be called during construction or initialization of this instance,
* and before the MBean is registered ... | Instantiates thisMBean instance with the data found for the MBean in the persistent store. The data loaded could include attribute and operation values. This method should be called during construction or initialization of this instance, and before the MBean is registered with the MBeanServer | load | {
"repo_name": "haikuowuya/android_system_code",
"path": "src/javax/management/PersistentMBean.java",
"license": "apache-2.0",
"size": 3054
} | [
"javax.management.InstanceNotFoundException",
"javax.management.MBeanException",
"javax.management.RuntimeOperationsException"
] | import javax.management.InstanceNotFoundException; import javax.management.MBeanException; import javax.management.RuntimeOperationsException; | import javax.management.*; | [
"javax.management"
] | javax.management; | 1,309,230 |
private void findDependentTypesRecursively(LibraryTypeWrapper masterType, HashSet<LibraryTypeWrapper> dependentTypesSet,
int dependencyDirection, int maxLevel,int currLevel)
throws Exception{
if(dependentTypesSet.contains(masterType))
return;
if(currLevel > maxLevel)
... | void function(LibraryTypeWrapper masterType, HashSet<LibraryTypeWrapper> dependentTypesSet, int dependencyDirection, int maxLevel,int currLevel) throws Exception{ if(dependentTypesSet.contains(masterType)) return; if(currLevel > maxLevel) return; dependentTypesSet.add(masterType); Set<LibraryTypeWrapper> dependentTypes... | /**
* Given a type it returns the list of dependent types
* @param masterType
* @param dependentTypesSet
* @param dependencyDirection
* @param maxLevel the number of levels for which you need the dependendent information , the initial type passed is at level zero
* @param currLevel the current level above o... | Given a type it returns the list of dependent types | findDependentTypesRecursively | {
"repo_name": "vthangathurai/SOA-Runtime",
"path": "codegen/codegen-tools/src/main/java/org/ebayopensource/turmeric/tools/library/SOAGlobalRegistryImpl.java",
"license": "apache-2.0",
"size": 41039
} | [
"java.util.HashSet",
"java.util.Set"
] | import java.util.HashSet; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 182,692 |
public Pair<String, InetAddress> getPublicIp() {
return _publicIp;
} | Pair<String, InetAddress> function() { return _publicIp; } | /**
* Return the value of the field publicIp <Ip, Hostname>
* @return the value of publicIp
*/ | Return the value of the field publicIp | getPublicIp | {
"repo_name": "leolewis/openvisualtraceroute",
"path": "org.leo.traceroute/src/org/leo/traceroute/core/geo/GeoService.java",
"license": "lgpl-3.0",
"size": 13251
} | [
"java.net.InetAddress",
"org.apache.commons.lang3.tuple.Pair"
] | import java.net.InetAddress; import org.apache.commons.lang3.tuple.Pair; | import java.net.*; import org.apache.commons.lang3.tuple.*; | [
"java.net",
"org.apache.commons"
] | java.net; org.apache.commons; | 1,132,922 |
Matrix getDisplayMatrix(); | Matrix getDisplayMatrix(); | /**
* Gets the Display Matrix of the currently displayed Drawable. The Rectangle is considered
* relative to this View and includes all scaling and translations.
*
* @return - true if rectangle was applied successfully
*/ | Gets the Display Matrix of the currently displayed Drawable. The Rectangle is considered relative to this View and includes all scaling and translations | getDisplayMatrix | {
"repo_name": "shengyuemao/LouJiReader",
"path": "LuoJI/src/com/louji/widgets/photoview/IPhotoView.java",
"license": "apache-2.0",
"size": 11986
} | [
"android.graphics.Matrix"
] | import android.graphics.Matrix; | import android.graphics.*; | [
"android.graphics"
] | android.graphics; | 2,352,421 |
public void updateFetchPositions(Set<TopicPartition> partitions) {
final Set<TopicPartition> needsOffsetReset = new HashSet<>();
// reset the fetch position to the committed position
for (TopicPartition tp : partitions) {
if (!subscriptions.isAssigned(tp) || subscriptions.hasVali... | void function(Set<TopicPartition> partitions) { final Set<TopicPartition> needsOffsetReset = new HashSet<>(); for (TopicPartition tp : partitions) { if (!subscriptions.isAssigned(tp) subscriptions.hasValidPosition(tp)) continue; if (subscriptions.isOffsetResetNeeded(tp)) { needsOffsetReset.add(tp); } else if (subscript... | /**
* Update the fetch positions for the provided partitions.
* @param partitions the partitions to update positions for
* @throws NoOffsetForPartitionException If no offset is stored for a given partition and no reset policy is available
*/ | Update the fetch positions for the provided partitions | updateFetchPositions | {
"repo_name": "rhauch/kafka",
"path": "clients/src/main/java/org/apache/kafka/clients/consumer/internals/Fetcher.java",
"license": "apache-2.0",
"size": 66905
} | [
"java.util.HashSet",
"java.util.Set",
"org.apache.kafka.common.TopicPartition"
] | import java.util.HashSet; import java.util.Set; import org.apache.kafka.common.TopicPartition; | import java.util.*; import org.apache.kafka.common.*; | [
"java.util",
"org.apache.kafka"
] | java.util; org.apache.kafka; | 474,014 |
public ConfigurationInfo getDeviceConfigurationInfo() {
try {
return ActivityManagerNative.getDefault().getDeviceConfigurationInfo();
} catch (RemoteException e) {
}
return null;
} | ConfigurationInfo function() { try { return ActivityManagerNative.getDefault().getDeviceConfigurationInfo(); } catch (RemoteException e) { } return null; } | /**
* Get the device configuration attributes.
*/ | Get the device configuration attributes | getDeviceConfigurationInfo | {
"repo_name": "indashnet/InDashNet.Open.UN2000",
"path": "android/frameworks/base/core/java/android/app/ActivityManager.java",
"license": "apache-2.0",
"size": 83290
} | [
"android.content.pm.ConfigurationInfo",
"android.os.RemoteException"
] | import android.content.pm.ConfigurationInfo; import android.os.RemoteException; | import android.content.pm.*; import android.os.*; | [
"android.content",
"android.os"
] | android.content; android.os; | 298,052 |
static public UIXCookie getUIXCookie(
HttpServletRequest request,
HttpServletResponse response,
boolean createIfNew)
{
if (request == null)
return null;
UIXCookie cookie = (UIXCookie) request.getAttribute(_COOKIE_KEY);
if ((cookie == null) && (response != null))
{
... | static UIXCookie function( HttpServletRequest request, HttpServletResponse response, boolean createIfNew) { if (request == null) return null; UIXCookie cookie = (UIXCookie) request.getAttribute(_COOKIE_KEY); if ((cookie == null) && (response != null)) { if (createIfNew _cookieExists(request)) { cookie = new UIXCookie(r... | /**
* Gets the UIXCookie. If "createIfNew" is true, this
* method must be called before starting to write the response.
* @param request the current servlet request
* @param response the current servlet response
* @param createIfNew if true, the cookie will be created if it
* does not already exist... | Gets the UIXCookie. If "createIfNew" is true, this method must be called before starting to write the response | getUIXCookie | {
"repo_name": "adamrduffy/trinidad-1.0.x",
"path": "trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/share/config/UIXCookie.java",
"license": "apache-2.0",
"size": 11423
} | [
"javax.servlet.http.HttpServletRequest",
"javax.servlet.http.HttpServletResponse"
] | import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.*; | [
"javax.servlet"
] | javax.servlet; | 1,514,261 |
private void addImports(JavaCompilationUnit unit) throws JavaModelException {
JavaAstElementFactory javaFactory = JavaAstElementFactory.getInstance();
if (this.util.getFieldNameToTypeReference().get(BASETYPE) != null
&& this.util.getFieldNameToTypeReference().get(BASETYPE).containsK... | void function(JavaCompilationUnit unit) throws JavaModelException { JavaAstElementFactory javaFactory = JavaAstElementFactory.getInstance(); if (this.util.getFieldNameToTypeReference().get(BASETYPE) != null && this.util.getFieldNameToTypeReference().get(BASETYPE).containsKey(referencedFieldTypeKey)) { for (String impor... | /**
* Adds all imports to the unit.
*
* @param unit
* the java compilation unit where all imports are added to.
* @throws JavaModelException
* if an error occurred transforming the model.
*/ | Adds all imports to the unit | addImports | {
"repo_name": "NABUCCO/org.nabucco.framework.generator",
"path": "org.nabucco.framework.generator.compiler/src/main/org/nabucco/framework/generator/compiler/transformation/java/view/common/combobox/NabuccoToJavaRcpViewComboBoxContentProviderVisitor.java",
"license": "epl-1.0",
"size": 14847
} | [
"org.eclipse.jdt.internal.compiler.ast.ImportReference",
"org.nabucco.framework.mda.model.java.JavaCompilationUnit",
"org.nabucco.framework.mda.model.java.JavaModelException",
"org.nabucco.framework.mda.model.java.ast.element.JavaAstElementFactory",
"org.nabucco.framework.mda.model.java.ast.produce.JavaAstM... | import org.eclipse.jdt.internal.compiler.ast.ImportReference; import org.nabucco.framework.mda.model.java.JavaCompilationUnit; import org.nabucco.framework.mda.model.java.JavaModelException; import org.nabucco.framework.mda.model.java.ast.element.JavaAstElementFactory; import org.nabucco.framework.mda.model.java.ast.pr... | import org.eclipse.jdt.internal.compiler.ast.*; import org.nabucco.framework.mda.model.java.*; import org.nabucco.framework.mda.model.java.ast.element.*; import org.nabucco.framework.mda.model.java.ast.produce.*; | [
"org.eclipse.jdt",
"org.nabucco.framework"
] | org.eclipse.jdt; org.nabucco.framework; | 1,485,430 |
public T setShardId(ShardId shardId) {
this.shardId = shardId;
return (T) this;
} | T function(ShardId shardId) { this.shardId = shardId; return (T) this; } | /**
* Sets the target shard id for the request. The shard id is set when a
* index/delete request is resolved by the transport action
*/ | Sets the target shard id for the request. The shard id is set when a index/delete request is resolved by the transport action | setShardId | {
"repo_name": "zhengxgs/elasticsearch-2.4.1",
"path": "core/src/main/java/org/elasticsearch/action/support/replication/ReplicationRequest.java",
"license": "apache-2.0",
"size": 8461
} | [
"org.elasticsearch.index.shard.ShardId"
] | import org.elasticsearch.index.shard.ShardId; | import org.elasticsearch.index.shard.*; | [
"org.elasticsearch.index"
] | org.elasticsearch.index; | 1,874,356 |
public void setEMailVerifyDate (Timestamp EMailVerifyDate)
{
set_ValueNoCheck (COLUMNNAME_EMailVerifyDate, EMailVerifyDate);
} | void function (Timestamp EMailVerifyDate) { set_ValueNoCheck (COLUMNNAME_EMailVerifyDate, EMailVerifyDate); } | /** Set EMail Verify.
@param EMailVerifyDate
Date Email was verified
*/ | Set EMail Verify | setEMailVerifyDate | {
"repo_name": "geneos/adempiere",
"path": "base/src/org/compiere/model/X_RV_BPartner.java",
"license": "gpl-2.0",
"size": 51998
} | [
"java.sql.Timestamp"
] | import java.sql.Timestamp; | import java.sql.*; | [
"java.sql"
] | java.sql; | 901,838 |
private void runCopyJob(final FileSystem inputFs, final Path inputRoot,
final FileSystem outputFs, final Path outputRoot,
final List<Pair<Path, Long>> snapshotFiles, final boolean verifyChecksum,
final String filesUser, final String filesGroup, final int filesMode,
final int mappers) throws IO... | void function(final FileSystem inputFs, final Path inputRoot, final FileSystem outputFs, final Path outputRoot, final List<Pair<Path, Long>> snapshotFiles, final boolean verifyChecksum, final String filesUser, final String filesGroup, final int filesMode, final int mappers) throws IOException, InterruptedException, Cla... | /**
* Run Map-Reduce Job to perform the files copy.
*/ | Run Map-Reduce Job to perform the files copy | runCopyJob | {
"repo_name": "lilonglai/hbase-0.96.2",
"path": "hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java",
"license": "apache-2.0",
"size": 32444
} | [
"java.io.IOException",
"java.util.List",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.fs.FileSystem",
"org.apache.hadoop.fs.Path",
"org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil",
"org.apache.hadoop.hbase.security.UserProvider",
"org.apache.hadoop.hbase.security.token.FsDelegation... | import java.io.IOException; import java.util.List; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.fs.FileSystem; import org.apache.hadoop.fs.Path; import org.apache.hadoop.hbase.mapreduce.TableMapReduceUtil; import org.apache.hadoop.hbase.security.UserProvider; import org.apache.hadoop.hbase.secu... | import java.io.*; import java.util.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.hbase.mapreduce.*; import org.apache.hadoop.hbase.security.*; import org.apache.hadoop.hbase.security.token.*; import org.apache.hadoop.hbase.util.*; import org.apache.hadoop.mapreduce.*; impor... | [
"java.io",
"java.util",
"org.apache.hadoop"
] | java.io; java.util; org.apache.hadoop; | 204,928 |
@Override
public int evalToBuffer(QueryContext context,
byte []buffer,
int offset)
throws SQLException
{
return -1;
} | int function(QueryContext context, byte []buffer, int offset) throws SQLException { return -1; } | /**
* Evaluates the expression to a buffer
*
* @param result the result buffer
*
* @return the length of the result
*/ | Evaluates the expression to a buffer | evalToBuffer | {
"repo_name": "dlitz/resin",
"path": "modules/resin/src/com/caucho/db/sql/NullExpr.java",
"license": "gpl-2.0",
"size": 2152
} | [
"java.sql.SQLException"
] | import java.sql.SQLException; | import java.sql.*; | [
"java.sql"
] | java.sql; | 2,504,001 |
public synchronized FieldIdItem intern(CstFieldRef field) {
if (field == null) {
throw new NullPointerException("field == null");
}
throwIfPrepared();
FieldIdItem result = fieldIds.get(field);
if (result == null) {
result = new FieldIdItem(field);
... | synchronized FieldIdItem function(CstFieldRef field) { if (field == null) { throw new NullPointerException(STR); } throwIfPrepared(); FieldIdItem result = fieldIds.get(field); if (result == null) { result = new FieldIdItem(field); fieldIds.put(field, result); } return result; } | /**
* Interns an element into this instance.
*
* @param field {@code non-null;} the reference to intern
* @return {@code non-null;} the interned reference
*/ | Interns an element into this instance | intern | {
"repo_name": "alibaba/atlas",
"path": "atlas-gradle-plugin/dexpatch/src/main/java/com/taobao/android/dx/dex/file/FieldIdsSection.java",
"license": "apache-2.0",
"size": 3775
} | [
"com.taobao.android.dx.rop.cst.CstFieldRef"
] | import com.taobao.android.dx.rop.cst.CstFieldRef; | import com.taobao.android.dx.rop.cst.*; | [
"com.taobao.android"
] | com.taobao.android; | 1,200,619 |
public JsonObject getHistoricalDataUsage(String startDate, String endDate, boolean detail) throws IoTFCReSTException {
final String METHOD = "getHistoricalDataUsage";
StringBuilder sb = new StringBuilder("https://");
sb.append(orgId).
append('.').
append(this.domain).append(BASIC_API_V0002_URL).
... | JsonObject function(String startDate, String endDate, boolean detail) throws IoTFCReSTException { final String METHOD = STR; StringBuilder sb = new StringBuilder(STR/usage/historical-dataSTRstartSTRendSTRdetailSTRgetSTRFailure in retrieving the historical data storage STR::STRBad RequestSTRUnexpected errorSTR", jsonRes... | /**
* Retrieve the amount of storage being used by historical event data
*
* @param startDate Start date in one of the following formats: YYYY (last day of the year),
* YYYY-MM (last day of the month), YYYY-MM-DD (specific day)
*
* @param endDate End date in one of the following formats: YYYY (last day o... | Retrieve the amount of storage being used by historical event data | getHistoricalDataUsage | {
"repo_name": "sathipal/iot-java",
"path": "src/main/java/com/ibm/iotf/client/api/APIClient.java",
"license": "epl-1.0",
"size": 124231
} | [
"com.google.gson.JsonObject",
"com.ibm.iotf.client.IoTFCReSTException"
] | import com.google.gson.JsonObject; import com.ibm.iotf.client.IoTFCReSTException; | import com.google.gson.*; import com.ibm.iotf.client.*; | [
"com.google.gson",
"com.ibm.iotf"
] | com.google.gson; com.ibm.iotf; | 743,571 |
public synchronized void addWordToUserDictionary(final String word) {
// Update the user dictionary provider
final Locale locale;
if (USER_DICTIONARY_ALL_LANGUAGES == mLocale) {
locale = null;
} else {
locale = LocaleUtils.constructLocaleFromString(mLocale);
... | synchronized void function(final String word) { final Locale locale; if (USER_DICTIONARY_ALL_LANGUAGES == mLocale) { locale = null; } else { locale = LocaleUtils.constructLocaleFromString(mLocale); } UserDictionaryCompatUtils.addWord(mContext, word, HISTORICAL_DEFAULT_USER_DICTIONARY_FREQUENCY, null, locale); } | /**
* Adds a word to the user dictionary and makes it persistent.
*
* @param word the word to add. If the word is capitalized, then the dictionary will
* recognize it as a capitalized word when searched.
*/ | Adds a word to the user dictionary and makes it persistent | addWordToUserDictionary | {
"repo_name": "slightfoot/android-kioskime",
"path": "src/com/android/inputmethod/latin/UserBinaryDictionary.java",
"license": "apache-2.0",
"size": 11824
} | [
"com.android.inputmethod.compat.UserDictionaryCompatUtils",
"java.util.Locale"
] | import com.android.inputmethod.compat.UserDictionaryCompatUtils; import java.util.Locale; | import com.android.inputmethod.compat.*; import java.util.*; | [
"com.android.inputmethod",
"java.util"
] | com.android.inputmethod; java.util; | 2,487,697 |
@ServiceMethod(returns = ReturnType.SINGLE)
InstanceFailoverGroupInner failover(String resourceGroupName, String locationName, String failoverGroupName); | @ServiceMethod(returns = ReturnType.SINGLE) InstanceFailoverGroupInner failover(String resourceGroupName, String locationName, String failoverGroupName); | /**
* Fails over from the current primary managed instance to this managed instance.
*
* @param resourceGroupName The name of the resource group that contains the resource. You can obtain this value
* from the Azure Resource Manager API or the portal.
* @param locationName The name of the r... | Fails over from the current primary managed instance to this managed instance | failover | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/resourcemanager/azure-resourcemanager-sql/src/main/java/com/azure/resourcemanager/sql/fluent/InstanceFailoverGroupsClient.java",
"license": "mit",
"size": 35445
} | [
"com.azure.core.annotation.ReturnType",
"com.azure.core.annotation.ServiceMethod",
"com.azure.resourcemanager.sql.fluent.models.InstanceFailoverGroupInner"
] | import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; import com.azure.resourcemanager.sql.fluent.models.InstanceFailoverGroupInner; | import com.azure.core.annotation.*; import com.azure.resourcemanager.sql.fluent.models.*; | [
"com.azure.core",
"com.azure.resourcemanager"
] | com.azure.core; com.azure.resourcemanager; | 235,416 |
public void close() throws IOException {
for (Appender appender : appenderList) {
appender.close();
}
stopWatch.stop();
} | void function() throws IOException { for (Appender appender : appenderList) { appender.close(); } stopWatch.stop(); } | /**
* Close the log. From this point on, no logging is done.
*
* @throws IOException
* if the <code>Logger</code> failed to close.
*/ | Close the log. From this point on, no logging is done | close | {
"repo_name": "smargav/android-api-library",
"path": "src/main/java/com/google/code/microlog4android/Logger.java",
"license": "apache-2.0",
"size": 12209
} | [
"com.google.code.microlog4android.appender.Appender",
"java.io.IOException"
] | import com.google.code.microlog4android.appender.Appender; import java.io.IOException; | import com.google.code.microlog4android.appender.*; import java.io.*; | [
"com.google.code",
"java.io"
] | com.google.code; java.io; | 2,678,061 |
private void searchTarget(
String SearchStr, OmniFile targetFile, JsonArray files, String url) {
if (DEBUG) {
LogUtil.log(LogUtil.LogType.CMD_SEARCH, "Search target: "
+ targetFile.getPath());
}
if (targetFile.getName().contains( SearchStr)) {
... | void function( String SearchStr, OmniFile targetFile, JsonArray files, String url) { if (DEBUG) { LogUtil.log(LogUtil.LogType.CMD_SEARCH, STR + targetFile.getPath()); } if (targetFile.getName().contains( SearchStr)) { files.add(targetFile.getFileObject(url)); } for (OmniFile file: targetFile.listFiles()) { if (file.isD... | /**
* Recursively search the target folder or volume for target files containing
* the search string.
*
* @param SearchStr
* @param targetFile
* @param files
* @param url
*/ | Recursively search the target folder or volume for target files containing the search string | searchTarget | {
"repo_name": "Nuvolect/SecureSuite-Android",
"path": "SecureSuite/src/main/java/com/nuvolect/securesuite/webserver/connector/CmdSearch.java",
"license": "gpl-3.0",
"size": 4281
} | [
"com.google.gson.JsonArray",
"com.nuvolect.securesuite.util.LogUtil",
"com.nuvolect.securesuite.util.OmniFile"
] | import com.google.gson.JsonArray; import com.nuvolect.securesuite.util.LogUtil; import com.nuvolect.securesuite.util.OmniFile; | import com.google.gson.*; import com.nuvolect.securesuite.util.*; | [
"com.google.gson",
"com.nuvolect.securesuite"
] | com.google.gson; com.nuvolect.securesuite; | 2,650,693 |
public static void createBugZillaReport(XmlRpcClient client, Throwable exception, String userSummary,
String completeDescription, String component, String version, String severity, String platform, String os,
File[] attachments, boolean attachProcess, boolean attachSystemProps, boolean attachLogFile) throws ... | static void function(XmlRpcClient client, Throwable exception, String userSummary, String completeDescription, String component, String version, String severity, String platform, String os, File[] attachments, boolean attachProcess, boolean attachSystemProps, boolean attachLogFile) throws Exception { File processFile =... | /**
* Creates the BugZilla bugreport.
*
* @param client
* the logged in BugZilla client
* @param exception
* the exception which was thrown by the bug
* @param userSummary
* summary of the bug
* @param completeDescription
* description of the bu... | Creates the BugZilla bugreport | createBugZillaReport | {
"repo_name": "transwarpio/rapidminer",
"path": "rapidMiner/rapidminer-studio-core/src/main/java/com/rapidminer/tools/BugReport.java",
"license": "gpl-3.0",
"size": 17995
} | [
"com.rapidminer.RapidMiner",
"com.rapidminer.gui.RapidMinerGUI",
"com.rapidminer.tools.plugin.Plugin",
"java.io.File",
"java.io.FileInputStream",
"java.util.HashMap",
"java.util.Map",
"java.util.logging.Level",
"org.apache.xmlrpc.client.XmlRpcClient"
] | import com.rapidminer.RapidMiner; import com.rapidminer.gui.RapidMinerGUI; import com.rapidminer.tools.plugin.Plugin; import java.io.File; import java.io.FileInputStream; import java.util.HashMap; import java.util.Map; import java.util.logging.Level; import org.apache.xmlrpc.client.XmlRpcClient; | import com.rapidminer.*; import com.rapidminer.gui.*; import com.rapidminer.tools.plugin.*; import java.io.*; import java.util.*; import java.util.logging.*; import org.apache.xmlrpc.client.*; | [
"com.rapidminer",
"com.rapidminer.gui",
"com.rapidminer.tools",
"java.io",
"java.util",
"org.apache.xmlrpc"
] | com.rapidminer; com.rapidminer.gui; com.rapidminer.tools; java.io; java.util; org.apache.xmlrpc; | 2,313,442 |
public void addSelectionListener(SelectionListener l); | void function(SelectionListener l); | /**
* Add a SelectionListener to this Selector's notification list.
* @param l the SelectionListener to add.
*/ | Add a SelectionListener to this Selector's notification list | addSelectionListener | {
"repo_name": "Uni-Sol/batik",
"path": "sources/org/apache/batik/gvt/Selector.java",
"license": "apache-2.0",
"size": 1871
} | [
"org.apache.batik.gvt.event.SelectionListener"
] | import org.apache.batik.gvt.event.SelectionListener; | import org.apache.batik.gvt.event.*; | [
"org.apache.batik"
] | org.apache.batik; | 1,454,738 |
public static <T> int upperBound(List<? extends Comparable<? super T>> list,
T key) {
int low = 0;
int high = list.size();
while (low < high) {
int mid = (low + high) >>> 1;
Comparable<? super T> midVal = list.get(mid);
int ret = midVal.compareTo(key);
if (ret <= 0)
... | static <T> int function(List<? extends Comparable<? super T>> list, T key) { int low = 0; int high = list.size(); while (low < high) { int mid = (low + high) >>> 1; Comparable<? super T> midVal = list.get(mid); int ret = midVal.compareTo(key); if (ret <= 0) low = mid + 1; else high = mid; } return low; } | /**
* Upper bound binary search. Find the index to the first element in the list
* that compares greater than the input key.
*
* @param <T>
* Type of the input key.
* @param list
* The list
* @param key
* The input key.
* @return The index to the desired element... | Upper bound binary search. Find the index to the first element in the list that compares greater than the input key | upperBound | {
"repo_name": "gndpig/hadoop",
"path": "src/core/org/apache/hadoop/io/file/tfile/Utils.java",
"license": "apache-2.0",
"size": 14919
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 344,918 |
AuditCommand command = new AuditPreviousStateCommand();
AuditablePayload payload = AuditCommandTest.getTestPayload();
AuditActivity activity = new AuditActivity();
// Correct test
activity = new AuditActivity();
command.execute(payload, activity);
assertEquals("REMOVED_STAT3", activity.getObjectPreviousS... | AuditCommand command = new AuditPreviousStateCommand(); AuditablePayload payload = AuditCommandTest.getTestPayload(); AuditActivity activity = new AuditActivity(); activity = new AuditActivity(); command.execute(payload, activity); assertEquals(STR, activity.getObjectPreviousState()); activity = new AuditActivity(); ((... | /**
* Tests the retrieval of the object previous state for specific instance.
*/ | Tests the retrieval of the object previous state for specific instance | testObjectPreviousStateCommand | {
"repo_name": "SirmaITT/conservation-space-1.7.0",
"path": "docker/sirma-platform/platform/seip-parent/platform/seip-audit/seip-audit-impl/src/test/java/com/sirma/itt/emf/audit/command/AuditPreviousStateCommandTest.java",
"license": "lgpl-3.0",
"size": 4222
} | [
"com.sirma.itt.emf.audit.activity.AuditActivity",
"com.sirma.itt.emf.audit.activity.AuditablePayload",
"com.sirma.itt.emf.audit.command.instance.AuditPreviousStateCommand",
"com.sirma.itt.seip.instance.properties.PropertiesChangeEvent",
"org.junit.Assert"
] | import com.sirma.itt.emf.audit.activity.AuditActivity; import com.sirma.itt.emf.audit.activity.AuditablePayload; import com.sirma.itt.emf.audit.command.instance.AuditPreviousStateCommand; import com.sirma.itt.seip.instance.properties.PropertiesChangeEvent; import org.junit.Assert; | import com.sirma.itt.emf.audit.activity.*; import com.sirma.itt.emf.audit.command.instance.*; import com.sirma.itt.seip.instance.properties.*; import org.junit.*; | [
"com.sirma.itt",
"org.junit"
] | com.sirma.itt; org.junit; | 2,026,103 |
private CustomJSONWriter append(String string) throws JSONException {
if (string == null) {
throw new JSONException("Null pointer");
}
if (this.mode == 'o' || this.mode == 'a') {
try {
if (this.comma && this.mode == 'a') {
this.writ... | CustomJSONWriter function(String string) throws JSONException { if (string == null) { throw new JSONException(STR); } if (this.mode == 'o' this.mode == 'a') { try { if (this.comma && this.mode == 'a') { this.writer.write(','); } this.writer.write(string); } catch (IOException e) { throw new JSONException(e); } if (this... | /**
* Append a value.
* @param string A string value.
* @return this
* @throws JSONException If the value is out of sequence.
*/ | Append a value | append | {
"repo_name": "fastcat-co/fastcatsearch",
"path": "server/src/main/java/org/fastcatsearch/util/CustomJSONWriter.java",
"license": "apache-2.0",
"size": 12081
} | [
"java.io.IOException",
"org.json.JSONException"
] | import java.io.IOException; import org.json.JSONException; | import java.io.*; import org.json.*; | [
"java.io",
"org.json"
] | java.io; org.json; | 2,479,130 |
protected void drawTickMarksVertical(Graphics2D g2, AxisState state,
Rectangle2D dataArea,
RectangleEdge edge) {
// FIXME: implement this...
}
| void function(Graphics2D g2, AxisState state, Rectangle2D dataArea, RectangleEdge edge) { } | /**
* Draws the tick marks for a vertical axis.
*
* @param g2 the graphics device.
* @param state the axis state.
* @param dataArea the data area.
* @param edge the edge.
*/ | Draws the tick marks for a vertical axis | drawTickMarksVertical | {
"repo_name": "nologic/nabs",
"path": "client/trunk/shared/libraries/jfreechart-1.0.5/source/org/jfree/chart/axis/PeriodAxis.java",
"license": "gpl-2.0",
"size": 44154
} | [
"java.awt.Graphics2D",
"java.awt.geom.Rectangle2D",
"org.jfree.ui.RectangleEdge"
] | import java.awt.Graphics2D; import java.awt.geom.Rectangle2D; import org.jfree.ui.RectangleEdge; | import java.awt.*; import java.awt.geom.*; import org.jfree.ui.*; | [
"java.awt",
"org.jfree.ui"
] | java.awt; org.jfree.ui; | 870,300 |
@Override
public Fragment getItem(int position) {
Fragment fragment = null;
switch (position) {
case 0:
fragment = ShoppingListsFragment.newInstance();
break;
case 1:
fragme... | Fragment function(int position) { Fragment fragment = null; switch (position) { case 0: fragment = ShoppingListsFragment.newInstance(); break; case 1: fragment = MealsFragment.newInstance(); break; default: fragment = ShoppingListsFragment.newInstance(); break; } return fragment; } | /**
* Use positions (0 and 1) to find and instantiate fragments with newInstance()
*
* @param position
*/ | Use positions (0 and 1) to find and instantiate fragments with newInstance() | getItem | {
"repo_name": "findjigar/Jabbar-ShoppingList",
"path": "app/src/main/java/com/jabbar/shoppinglist/ui/MainActivity.java",
"license": "apache-2.0",
"size": 5317
} | [
"android.support.v4.app.Fragment",
"com.jabbar.shoppinglist.ui.activeLists.ShoppingListsFragment",
"com.jabbar.shoppinglist.ui.meals.MealsFragment"
] | import android.support.v4.app.Fragment; import com.jabbar.shoppinglist.ui.activeLists.ShoppingListsFragment; import com.jabbar.shoppinglist.ui.meals.MealsFragment; | import android.support.v4.app.*; import com.jabbar.shoppinglist.ui.*; import com.jabbar.shoppinglist.ui.meals.*; | [
"android.support",
"com.jabbar.shoppinglist"
] | android.support; com.jabbar.shoppinglist; | 2,834,425 |
public static void write(char[] data, OutputStream output, Charset encoding) throws IOException {
if (data != null) {
output.write(new String(data).getBytes(Charsets.toCharset(encoding)));
}
} | static void function(char[] data, OutputStream output, Charset encoding) throws IOException { if (data != null) { output.write(new String(data).getBytes(Charsets.toCharset(encoding))); } } | /**
* Writes chars from a <code>char[]</code> to bytes on an
* <code>OutputStream</code> using the specified character encoding.
* <p>
* This method uses {@link String#String(char[])} and
* {@link String#getBytes(String)}.
*
* @param data the char array to write, do not modify durin... | Writes chars from a <code>char[]</code> to bytes on an <code>OutputStream</code> using the specified character encoding. This method uses <code>String#String(char[])</code> and <code>String#getBytes(String)</code> | write | {
"repo_name": "trivium-io/trivium-core",
"path": "src/io/trivium/dep/org/apache/commons/io/IOUtils.java",
"license": "apache-2.0",
"size": 97969
} | [
"java.io.IOException",
"java.io.OutputStream",
"java.nio.charset.Charset"
] | import java.io.IOException; import java.io.OutputStream; import java.nio.charset.Charset; | import java.io.*; import java.nio.charset.*; | [
"java.io",
"java.nio"
] | java.io; java.nio; | 2,665,213 |
@Override
public void setCharsetMapper(CharsetMapper mapper) {
CharsetMapper oldCharsetMapper = this.charsetMapper;
this.charsetMapper = mapper;
if( mapper != null )
this.charsetMapperClass= mapper.getClass().getName();
support.firePropertyChange("charsetMappe... | void function(CharsetMapper mapper) { CharsetMapper oldCharsetMapper = this.charsetMapper; this.charsetMapper = mapper; if( mapper != null ) this.charsetMapperClass= mapper.getClass().getName(); support.firePropertyChange(STR, oldCharsetMapper, this.charsetMapper); } | /**
* Set the Locale to character set mapper for this Context.
*
* @param mapper The new mapper
*/ | Set the Locale to character set mapper for this Context | setCharsetMapper | {
"repo_name": "pistolove/sourcecode4junit",
"path": "Source4Tomcat/src/org/apache/catalina/core/StandardContext.java",
"license": "apache-2.0",
"size": 202235
} | [
"org.apache.catalina.util.CharsetMapper"
] | import org.apache.catalina.util.CharsetMapper; | import org.apache.catalina.util.*; | [
"org.apache.catalina"
] | org.apache.catalina; | 1,872,323 |
protected void addVA_InPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_Dc_dc_converter_VA_In_feature"),
getString("_UI_PropertyDescriptor_de... | void function(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString(STR), getString(STR, STR, STR), VisGridPackage.eINSTANCE.getDc_dc_converter_VA_In(), true, false, false, ItemPropertyDescriptor.G... | /**
* This adds a property descriptor for the VA In feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | This adds a property descriptor for the VA In feature. | addVA_InPropertyDescriptor | {
"repo_name": "mikesligo/visGrid",
"path": "ie.tcd.gmf.visGrid.edit/src/visGrid/provider/Dc_dc_converterItemProvider.java",
"license": "gpl-3.0",
"size": 13947
} | [
"org.eclipse.emf.edit.provider.ComposeableAdapterFactory",
"org.eclipse.emf.edit.provider.ItemPropertyDescriptor"
] | import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; | import org.eclipse.emf.edit.provider.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 8,020 |
void submit(final FormEntity form, final Map<String, String> parameters,
final List<FileItem> files, String ipAddress) throws UploadException; | void submit(final FormEntity form, final Map<String, String> parameters, final List<FileItem> files, String ipAddress) throws UploadException; | /**
* Submit form.
* @param form - form to submit.
* @param parameters - form parameters.
* @param files - form parameters of FILE type.
*/ | Submit form | submit | {
"repo_name": "vosaocms/vosao",
"path": "api/src/org/vosao/business/FormBusiness.java",
"license": "lgpl-2.1",
"size": 1559
} | [
"java.util.List",
"java.util.Map",
"org.vosao.common.UploadException",
"org.vosao.entity.FormEntity",
"org.vosao.utils.FileItem"
] | import java.util.List; import java.util.Map; import org.vosao.common.UploadException; import org.vosao.entity.FormEntity; import org.vosao.utils.FileItem; | import java.util.*; import org.vosao.common.*; import org.vosao.entity.*; import org.vosao.utils.*; | [
"java.util",
"org.vosao.common",
"org.vosao.entity",
"org.vosao.utils"
] | java.util; org.vosao.common; org.vosao.entity; org.vosao.utils; | 2,689,831 |
public Path sharedDataFile() {
return sharedDataFile;
} | Path function() { return sharedDataFile; } | /**
* The shared data location
*/ | The shared data location | sharedDataFile | {
"repo_name": "HonzaKral/elasticsearch",
"path": "server/src/main/java/org/elasticsearch/env/Environment.java",
"license": "apache-2.0",
"size": 12533
} | [
"java.nio.file.Path"
] | import java.nio.file.Path; | import java.nio.file.*; | [
"java.nio"
] | java.nio; | 2,777,435 |
@SuppressWarnings("unchecked")
public static void addNamedOutput(Job job, String namedOutput,
Class<? extends OutputFormat> outputFormatClass,
Schema keySchema, Schema valueSchema) {
checkNamedOutputName(job, namedOutput, true);
Configuration conf = job.getConfiguration();
conf.set(MULTIPLE_... | @SuppressWarnings(STR) static void function(Job job, String namedOutput, Class<? extends OutputFormat> outputFormatClass, Schema keySchema, Schema valueSchema) { checkNamedOutputName(job, namedOutput, true); Configuration conf = job.getConfiguration(); conf.set(MULTIPLE_OUTPUTS, conf.get(MULTIPLE_OUTPUTS, STR STR.keysc... | /**
* Adds a named output for the job.
* <p/>
*
* @param job job to add the named output
* @param namedOutput named output name, it has to be a word, letters
* and numbers only, cannot be the word 'part' as
* that is reserved for... | Adds a named output for the job. | addNamedOutput | {
"repo_name": "zolyfarkas/avro",
"path": "lang/java/mapred/src/main/java/org/apache/avro/mapreduce/AvroMultipleOutputs.java",
"license": "apache-2.0",
"size": 20816
} | [
"org.apache.avro.Schema",
"org.apache.hadoop.conf.Configuration",
"org.apache.hadoop.mapreduce.Job",
"org.apache.hadoop.mapreduce.OutputFormat"
] | import org.apache.avro.Schema; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.mapreduce.Job; import org.apache.hadoop.mapreduce.OutputFormat; | import org.apache.avro.*; import org.apache.hadoop.conf.*; import org.apache.hadoop.mapreduce.*; | [
"org.apache.avro",
"org.apache.hadoop"
] | org.apache.avro; org.apache.hadoop; | 356,912 |
@Override
public int read() throws java.io.IOException {
// Do we need to get data?
if( position < 0 ) {
if( encode ) {
byte[] b3 = new byte[3];
int numBinaryBytes = 0;
for( int i = 0; i < 3... | int function() throws java.io.IOException { if( position < 0 ) { if( encode ) { byte[] b3 = new byte[3]; int numBinaryBytes = 0; for( int i = 0; i < 3; i++ ) { int b = in.read(); if( b >= 0 ) { b3[i] = (byte)b; numBinaryBytes++; } else { break; } } if( numBinaryBytes > 0 ) { encode3to4( b3, 0, numBinaryBytes, buffer, 0... | /**
* Reads enough of the input stream to convert
* to/from Base64 and returns the next byte.
*
* @return next byte
* @since 1.3
*/ | Reads enough of the input stream to convert to/from Base64 and returns the next byte | read | {
"repo_name": "symcomp/org.symcomp.openmath",
"path": "src/main/java/org/symcomp/openmath/Base64.java",
"license": "apache-2.0",
"size": 77717
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 981,530 |
private static void computeArmyArtillery(String line, Writer sqlWriter) throws IOException {
Matcher m = Pattern.compile("([^&]*)&([^&]*)&([^&]*)&([^&]*)&([^&]*)&([^&]*)&([^&]*)&([^&]*)\\\\\\\\\\\\ghline.*").matcher(line);
if (m.matches()) {
String header = m.group(1);
List<S... | static void function(String line, Writer sqlWriter) throws IOException { Matcher m = Pattern.compile(STR).matcher(line); if (m.matches()) { String header = m.group(1); List<String> classes = extractClassesFromArmyArtilleryHeader(header); if (classes.isEmpty()) { String country = extractCountryFromArmyArtilleryHeader(he... | /**
* Creates the combat result table insertions for this line.
*
* @param line the line to compute.
* @param sqlWriter the writer with all database instructions.
* @throws IOException if the writer fails.
*/ | Creates the combat result table insertions for this line | computeArmyArtillery | {
"repo_name": "FogiaFr/tools",
"path": "src/main/java/com/mkl/tools/eu/tables/TablesGenerator.java",
"license": "mit",
"size": 99451
} | [
"java.io.IOException",
"java.io.Writer",
"java.util.List",
"java.util.regex.Matcher",
"java.util.regex.Pattern",
"org.apache.commons.lang3.StringUtils",
"org.apache.commons.lang3.math.NumberUtils"
] | import java.io.IOException; import java.io.Writer; import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern; import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.math.NumberUtils; | import java.io.*; import java.util.*; import java.util.regex.*; import org.apache.commons.lang3.*; import org.apache.commons.lang3.math.*; | [
"java.io",
"java.util",
"org.apache.commons"
] | java.io; java.util; org.apache.commons; | 780,774 |
@ApiModelProperty(example = "null", value = "")
public Double getTotalTaxRate() {
return totalTaxRate;
} | @ApiModelProperty(example = "null", value = "") Double function() { return totalTaxRate; } | /**
* Get totalTaxRate
* @return totalTaxRate
**/ | Get totalTaxRate | getTotalTaxRate | {
"repo_name": "PitneyBowes/LocationIntelligenceSDK-Java",
"path": "src/main/java/pb/locationintelligence/model/SalesTaxRate.java",
"license": "apache-2.0",
"size": 5531
} | [
"io.swagger.annotations.ApiModelProperty"
] | import io.swagger.annotations.ApiModelProperty; | import io.swagger.annotations.*; | [
"io.swagger.annotations"
] | io.swagger.annotations; | 2,788,514 |
public void addSignInInterceptor(ProviderSignInInterceptor<?> interceptor) {
Class<?> serviceApiType = GenericTypeResolver.resolveTypeArgument(interceptor.getClass(), ProviderSignInInterceptor.class);
signInInterceptors.add(serviceApiType, interceptor);
} | void function(ProviderSignInInterceptor<?> interceptor) { Class<?> serviceApiType = GenericTypeResolver.resolveTypeArgument(interceptor.getClass(), ProviderSignInInterceptor.class); signInInterceptors.add(serviceApiType, interceptor); } | /**
* Adds a ConnectInterceptor to receive callbacks during the connection process.
* Useful for programmatic configuration.
* @param interceptor the connect interceptor to add
*/ | Adds a ConnectInterceptor to receive callbacks during the connection process. Useful for programmatic configuration | addSignInInterceptor | {
"repo_name": "okohub/spring-social",
"path": "spring-social-web/src/main/java/org/springframework/social/connect/web/ProviderSignInController.java",
"license": "apache-2.0",
"size": 15715
} | [
"org.springframework.core.GenericTypeResolver"
] | import org.springframework.core.GenericTypeResolver; | import org.springframework.core.*; | [
"org.springframework.core"
] | org.springframework.core; | 153,394 |
public static Change translateAttributesToOtherUnits(final Unit unitGivingAttributes, final Collection<Unit> unitsThatWillGetAttributes, final Territory t)
{
final CompositeChange changes = new CompositeChange();
// must look for m_hits, m_unitDamage,
final TripleAUnit taUnit = (TripleAUnit) unitGivingAttribu... | static Change function(final Unit unitGivingAttributes, final Collection<Unit> unitsThatWillGetAttributes, final Territory t) { final CompositeChange changes = new CompositeChange(); final TripleAUnit taUnit = (TripleAUnit) unitGivingAttributes; final int combatDamage = taUnit.getHits(); final IntegerMap<Unit> hits = n... | /**
* Currently made for translating unit damage from one unit to another unit. Will adjust damage to be within max damage for the new units.
*
* @param unitGivingAttributes
* @param unitsThatWillGetAttributes
* @param t
* @return change for unit's properties
*/ | Currently made for translating unit damage from one unit to another unit. Will adjust damage to be within max damage for the new units | translateAttributesToOtherUnits | {
"repo_name": "tea-dragon/triplea",
"path": "src/main/java/games/strategy/triplea/TripleAUnit.java",
"license": "gpl-2.0",
"size": 19979
} | [
"games.strategy.engine.data.Change",
"games.strategy.engine.data.ChangeFactory",
"games.strategy.engine.data.CompositeChange",
"games.strategy.engine.data.Territory",
"games.strategy.engine.data.Unit",
"games.strategy.util.IntegerMap",
"java.util.Collection"
] | import games.strategy.engine.data.Change; import games.strategy.engine.data.ChangeFactory; import games.strategy.engine.data.CompositeChange; import games.strategy.engine.data.Territory; import games.strategy.engine.data.Unit; import games.strategy.util.IntegerMap; import java.util.Collection; | import games.strategy.engine.data.*; import games.strategy.util.*; import java.util.*; | [
"games.strategy.engine",
"games.strategy.util",
"java.util"
] | games.strategy.engine; games.strategy.util; java.util; | 1,640,224 |
public Set<ResourceRecord> execute( DirContext ctx, Name base ) throws Exception
{
if ( question == null )
{
return null;
}
Attributes matchAttrs = new BasicAttributes( true );
matchAttrs.put( new BasicAttribute( DnsAttribute.NAME, question.getDomainName() )... | Set<ResourceRecord> function( DirContext ctx, Name base ) throws Exception { if ( question == null ) { return null; } Attributes matchAttrs = new BasicAttributes( true ); matchAttrs.put( new BasicAttribute( DnsAttribute.NAME, question.getDomainName() ) ); matchAttrs.put( new BasicAttribute( DnsAttribute.TYPE, question.... | /**
* Note that the base is a relative path from the exiting context.
* It is not a Dn.
*/ | Note that the base is a relative path from the exiting context. It is not a Dn | execute | {
"repo_name": "drankye/directory-server",
"path": "protocol-dns/src/main/java/org/apache/directory/server/dns/store/jndi/operations/GetFlatRecord.java",
"license": "apache-2.0",
"size": 4778
} | [
"java.util.HashSet",
"java.util.Set",
"javax.naming.Name",
"javax.naming.NamingEnumeration",
"javax.naming.directory.Attributes",
"javax.naming.directory.BasicAttribute",
"javax.naming.directory.BasicAttributes",
"javax.naming.directory.DirContext",
"javax.naming.directory.SearchResult",
"org.apac... | import java.util.HashSet; import java.util.Set; import javax.naming.Name; import javax.naming.NamingEnumeration; import javax.naming.directory.Attributes; import javax.naming.directory.BasicAttribute; import javax.naming.directory.BasicAttributes; import javax.naming.directory.DirContext; import javax.naming.directory.... | import java.util.*; import javax.naming.*; import javax.naming.directory.*; import org.apache.directory.server.dns.messages.*; import org.apache.directory.server.dns.store.*; | [
"java.util",
"javax.naming",
"org.apache.directory"
] | java.util; javax.naming; org.apache.directory; | 2,605,504 |
public void setConfirm(ConfirmEntry entry) {
confirm = entry;
} | void function(ConfirmEntry entry) { confirm = entry; } | /**
* Sets the confirm.
*
* @param entry the new confirm
*/ | Sets the confirm | setConfirm | {
"repo_name": "Tabinol/Factoid",
"path": "src/main/java/me/tabinol/factoid/config/players/PlayerConfEntry.java",
"license": "gpl-3.0",
"size": 7206
} | [
"me.tabinol.factoid.commands.ConfirmEntry"
] | import me.tabinol.factoid.commands.ConfirmEntry; | import me.tabinol.factoid.commands.*; | [
"me.tabinol.factoid"
] | me.tabinol.factoid; | 163,577 |
public void testSelectorDisplayLabel( ) throws Exception
{
createDesign( ULocale.ENGLISH );
StyleHandle style = designHandle.getElementFactory( ).newStyle(
"testing-matrix" ); //$NON-NLS-1$
assertEquals( "Testing Matrix", style.getDisplayLabel( ) ); //$NON-NLS-1$
} | void function( ) throws Exception { createDesign( ULocale.ENGLISH ); StyleHandle style = designHandle.getElementFactory( ).newStyle( STR ); assertEquals( STR, style.getDisplayLabel( ) ); } | /**
* Tests the display lable of the extension defined selector.
*
* @throws Exception
*/ | Tests the display lable of the extension defined selector | testSelectorDisplayLabel | {
"repo_name": "sguan-actuate/birt",
"path": "model/org.eclipse.birt.report.model.tests/test/org/eclipse/birt/report/model/extension/ReportItemExtensionTest.java",
"license": "epl-1.0",
"size": 71610
} | [
"com.ibm.icu.util.ULocale",
"org.eclipse.birt.report.model.api.StyleHandle"
] | import com.ibm.icu.util.ULocale; import org.eclipse.birt.report.model.api.StyleHandle; | import com.ibm.icu.util.*; import org.eclipse.birt.report.model.api.*; | [
"com.ibm.icu",
"org.eclipse.birt"
] | com.ibm.icu; org.eclipse.birt; | 1,147,060 |
public static long copyFile(File input, OutputStream output) throws IOException {
final FileInputStream fis = new FileInputStream(input);
try {
return IOUtils.copyLarge(fis, output);
} finally {
fis.close();
}
}
| static long function(File input, OutputStream output) throws IOException { final FileInputStream fis = new FileInputStream(input); try { return IOUtils.copyLarge(fis, output); } finally { fis.close(); } } | /**
* Copy bytes from a <code>File</code> to an <code>OutputStream</code>.
* <p>
* This method buffers the input internally, so there is no need to use a <code>BufferedInputStream</code>.
* </p>
*
* @param input
* the <code>File</code> to read from
* @param out... | Copy bytes from a <code>File</code> to an <code>OutputStream</code>. This method buffers the input internally, so there is no need to use a <code>BufferedInputStream</code>. | copyFile | {
"repo_name": "0x90sled/droidtowers",
"path": "main/source/org/apach3/commons/io/FileUtils.java",
"license": "mit",
"size": 112889
} | [
"java.io.File",
"java.io.FileInputStream",
"java.io.IOException",
"java.io.OutputStream"
] | import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.OutputStream; | import java.io.*; | [
"java.io"
] | java.io; | 1,637,078 |
static public final float atan2(float y, float x) {
float add, mul;
if (x < 0) {
if (y < 0) {
y = -y;
mul = 1;
} else {
mul = -1;
}
x = -x;
add = -PI;
} else {
if (y < 0) {... | static final float function(float y, float x) { float add, mul; if (x < 0) { if (y < 0) { y = -y; mul = 1; } else { mul = -1; } x = -x; add = -PI; } else { if (y < 0) { y = -y; mul = -1; } else { mul = 1; } add = 0; } float invDiv = 1 / ((x < y ? y : x) * INV_ATAN2_DIM_MINUS_1); if (invDiv == Float.POSITIVE_INFINITY) {... | /**
* Returns atan2 in radians from a lookup table.
*/ | Returns atan2 in radians from a lookup table | atan2 | {
"repo_name": "axelrindle/ParticleEffectLib",
"path": "src/main/java/de/lalo5/particleeffectlib/util/MathUtils.java",
"license": "mit",
"size": 11028
} | [
"java.util.Random"
] | import java.util.Random; | import java.util.*; | [
"java.util"
] | java.util; | 18,613 |
if (sp == null) {
return;
}
for (NodeConnector p : sp) {
this.nodeConnectors.add(p);
}
} | if (sp == null) { return; } for (NodeConnector p : sp) { this.nodeConnectors.add(p); } } | /**
* Add NodeConnectors to a subnet
*
* @param sp Set of NodeConnectors to add to the subnet
*/ | Add NodeConnectors to a subnet | addNodeConnectors | {
"repo_name": "lbchen/odl-mod",
"path": "opendaylight/switchmanager/api/src/main/java/org/opendaylight/controller/switchmanager/Subnet.java",
"license": "epl-1.0",
"size": 7044
} | [
"org.opendaylight.controller.sal.core.NodeConnector"
] | import org.opendaylight.controller.sal.core.NodeConnector; | import org.opendaylight.controller.sal.core.*; | [
"org.opendaylight.controller"
] | org.opendaylight.controller; | 229,032 |
Serializable createReference(); | Serializable createReference(); | /**
* Create a reference object of the class to serialize.
*
* @return the reference object
* @since 1.0
*/ | Create a reference object of the class to serialize | createReference | {
"repo_name": "glinmac/commons-id",
"path": "src/test/org/apache/commons/id/test/AssertSerialization.java",
"license": "apache-2.0",
"size": 15347
} | [
"java.io.Serializable"
] | import java.io.Serializable; | import java.io.*; | [
"java.io"
] | java.io; | 1,114,118 |
public OtpConnection connect(final OtpPeer other) throws IOException,
UnknownHostException, OtpAuthException {
return new OtpConnection(this, other);
} | OtpConnection function(final OtpPeer other) throws IOException, UnknownHostException, OtpAuthException { return new OtpConnection(this, other); } | /**
* Open a connection to a remote node.
*
* @param other
* the remote node to which you wish to connect.
*
* @return a connection to the remote node.
*
* @exception java.net.UnknownHostException
* if the remote host could not be found.
*
... | Open a connection to a remote node | connect | {
"repo_name": "CloudI/CloudI",
"path": "src/api/java/com/ericsson/otp/erlang/OtpSelf.java",
"license": "mit",
"size": 10666
} | [
"java.io.IOException",
"java.net.UnknownHostException"
] | import java.io.IOException; import java.net.UnknownHostException; | import java.io.*; import java.net.*; | [
"java.io",
"java.net"
] | java.io; java.net; | 596,320 |
public boolean hasDecimals() throws XBRLException {
if (getType().equals("org.xbrlapi.impl.FractionItemImpl")) return true;
if (getDataRootElement().hasAttribute("decimals")) {
return true;
}
return false;
}
| boolean function() throws XBRLException { if (getType().equals(STR)) return true; if (getDataRootElement().hasAttribute(STR)) { return true; } return false; } | /**
* Returns true if the fact has a decimals attribute.
* @return true if the fact has a decimals attribute and false otherwise.
* @throws XBRLException
* @see org.xbrlapi.NumericItem#hasDecimals()
*/ | Returns true if the fact has a decimals attribute | hasDecimals | {
"repo_name": "martinggww/Programming",
"path": "XBRL/xbrl-api/module-api/src/main/java/org/xbrlapi/impl/NumericItemImpl.java",
"license": "gpl-2.0",
"size": 3289
} | [
"org.xbrlapi.utilities.XBRLException"
] | import org.xbrlapi.utilities.XBRLException; | import org.xbrlapi.utilities.*; | [
"org.xbrlapi.utilities"
] | org.xbrlapi.utilities; | 761,478 |
private ExampleSet applyOnDataIntegers(ExampleSet exampleSet) {
// selecting transformation attributes and creating new numeric attributes
LinkedList<Attribute> nominalAttributes = new LinkedList<Attribute>();
LinkedList<Attribute> transformedAttributes = new LinkedList<Attribute>();
for (Attribute att... | ExampleSet function(ExampleSet exampleSet) { LinkedList<Attribute> nominalAttributes = new LinkedList<Attribute>(); LinkedList<Attribute> transformedAttributes = new LinkedList<Attribute>(); for (Attribute attribute : exampleSet.getAttributes()) { if (!attribute.isNumerical()) { nominalAttributes.add(attribute); transf... | /**
* Transforms the numerical attributes to integer values (corresponding to the internal mapping).
*/ | Transforms the numerical attributes to integer values (corresponding to the internal mapping) | applyOnDataIntegers | {
"repo_name": "rapidminer/rapidminer-5",
"path": "src/com/rapidminer/operator/preprocessing/filter/NominalToNumericModel.java",
"license": "agpl-3.0",
"size": 18256
} | [
"com.rapidminer.example.Attribute",
"com.rapidminer.example.Attributes",
"com.rapidminer.example.Example",
"com.rapidminer.example.ExampleSet",
"com.rapidminer.example.table.AttributeFactory",
"com.rapidminer.tools.Ontology",
"java.util.Iterator",
"java.util.LinkedList"
] | import com.rapidminer.example.Attribute; import com.rapidminer.example.Attributes; import com.rapidminer.example.Example; import com.rapidminer.example.ExampleSet; import com.rapidminer.example.table.AttributeFactory; import com.rapidminer.tools.Ontology; import java.util.Iterator; import java.util.LinkedList; | import com.rapidminer.example.*; import com.rapidminer.example.table.*; import com.rapidminer.tools.*; import java.util.*; | [
"com.rapidminer.example",
"com.rapidminer.tools",
"java.util"
] | com.rapidminer.example; com.rapidminer.tools; java.util; | 2,825,673 |
public void onClick(View view) {
// Make sure the user has chosen a project before trying to add finds
SharedPreferences sp = PreferenceManager
.getDefaultSharedPreferences(this);
if (sp.getString("PROJECT_NAME", "").equals("")) {
Utils.showToast(this, "To get started, you must choose a project.");
Int... | void function(View view) { SharedPreferences sp = PreferenceManager .getDefaultSharedPreferences(this); if (sp.getString(STR, STRSTRTo get started, you must choose a project."); Intent i = new Intent(this, ShowProjectsActivity.class); startActivity(i); } else { Intent intent = new Intent(); switch (view.getId()) { case... | /**
* Handles clicks on PositMain's buttons.
*/ | Handles clicks on PositMain's buttons | onClick | {
"repo_name": "sanyaade-g2g-repos/posit-mobile.haiti",
"path": "src/org/hfoss/posit/android/PositMain.java",
"license": "lgpl-2.1",
"size": 11117
} | [
"android.content.Intent",
"android.content.SharedPreferences",
"android.preference.PreferenceManager",
"android.view.View"
] | import android.content.Intent; import android.content.SharedPreferences; import android.preference.PreferenceManager; import android.view.View; | import android.content.*; import android.preference.*; import android.view.*; | [
"android.content",
"android.preference",
"android.view"
] | android.content; android.preference; android.view; | 2,505,724 |
public interface AuthorListener extends EventListener
{
public void authorAdded(AuthorEvent e);
| interface AuthorListener extends EventListener { public void function(AuthorEvent e); | /**
* Invoked when an author is added to a weblog
* @param e The event
*/ | Invoked when an author is added to a weblog | authorAdded | {
"repo_name": "tixus/Thngm",
"path": "src/net/sf/thingamablog/blog/AuthorListener.java",
"license": "gpl-2.0",
"size": 1483
} | [
"java.util.EventListener"
] | import java.util.EventListener; | import java.util.*; | [
"java.util"
] | java.util; | 1,106,587 |
public static void main(String args[]) throws Exception
{
HTMLParser hpr = new HTMLParser("D:/Test1.html");
hpr.parse();
System.out.println("Tags: ");
Collection<ArrayList<TagParser>> lim = (Collection<ArrayList<TagParser>>) (hpr.getAllParsedContent().values());
for(ArrayList<TagParser> tagList : lim)
{... | static void function(String args[]) throws Exception { HTMLParser hpr = new HTMLParser(STR); hpr.parse(); System.out.println(STR); Collection<ArrayList<TagParser>> lim = (Collection<ArrayList<TagParser>>) (hpr.getAllParsedContent().values()); for(ArrayList<TagParser> tagList : lim) { for(TagParser tag : tagList) { Syst... | /**
* test main
* @throws Exception
* */ | test main | main | {
"repo_name": "animesks/projects",
"path": "Academic_UG/SearchEngineAlgo_Algo_Project/src/ac/in/iiitdmj/btech2008/cs305/parser/HTMLParser.java",
"license": "gpl-2.0",
"size": 2595
} | [
"java.util.ArrayList",
"java.util.Collection"
] | import java.util.ArrayList; import java.util.Collection; | import java.util.*; | [
"java.util"
] | java.util; | 1,693,657 |
@Override
public boolean hasNature(FMLRTVirtualModelInstance virtualModelInstance) {
// The corresponding VirtualModel should have FMLControlledDiagramVirtualModelNature
if (!virtualModelInstance.getVirtualModel().hasNature(FMLControlledFIBVirtualModelNature.INSTANCE)) {
return false;
}
FIBComponentMod... | boolean function(FMLRTVirtualModelInstance virtualModelInstance) { if (!virtualModelInstance.getVirtualModel().hasNature(FMLControlledFIBVirtualModelNature.INSTANCE)) { return false; } FIBComponentModelSlot fibMS = virtualModelInstance.getVirtualModel().getModelSlots(FIBComponentModelSlot.class).get(0); FreeModelSlotIn... | /**
* Return boolean indicating if supplied {@link FMLRTVirtualModelInstance} might be interpreted as a FML-controlled FIBComponent
*/ | Return boolean indicating if supplied <code>FMLRTVirtualModelInstance</code> might be interpreted as a FML-controlled FIBComponent | hasNature | {
"repo_name": "openflexo-team/openflexo-technology-adapters",
"path": "ginaconnector/src/main/java/org/openflexo/technologyadapter/gina/fml/FMLControlledFIBVirtualModelInstanceNature.java",
"license": "gpl-3.0",
"size": 6716
} | [
"org.openflexo.foundation.fml.rt.FMLRTVirtualModelInstance",
"org.openflexo.foundation.fml.rt.FreeModelSlotInstance",
"org.openflexo.technologyadapter.gina.FIBComponentModelSlot",
"org.openflexo.technologyadapter.gina.model.GINAFIBComponent"
] | import org.openflexo.foundation.fml.rt.FMLRTVirtualModelInstance; import org.openflexo.foundation.fml.rt.FreeModelSlotInstance; import org.openflexo.technologyadapter.gina.FIBComponentModelSlot; import org.openflexo.technologyadapter.gina.model.GINAFIBComponent; | import org.openflexo.foundation.fml.rt.*; import org.openflexo.technologyadapter.gina.*; import org.openflexo.technologyadapter.gina.model.*; | [
"org.openflexo.foundation",
"org.openflexo.technologyadapter"
] | org.openflexo.foundation; org.openflexo.technologyadapter; | 679,883 |
if (!KEY_MAP.equals(keymapElement.getName())) {
throw new IllegalArgumentException(UNKNOWN_ELEMENT + keymapElement);
}
String version = keymapElement.getAttributeValue(VERSION);
if (version != null) {
throw new InvalidDataException(UNKNOWN_VERSION + version);
}
// Add version
keyma... | if (!KEY_MAP.equals(keymapElement.getName())) { throw new IllegalArgumentException(UNKNOWN_ELEMENT + keymapElement); } String version = keymapElement.getAttributeValue(VERSION); if (version != null) { throw new InvalidDataException(UNKNOWN_VERSION + version); } keymapElement.setAttribute(VERSION, Integer.toString(1)); ... | /**
* Converts keymap from version "0" (no version specified)
* to version "1".
*
* @param keymapElement XML element that corresponds to "keymap" tag.
*/ | Converts keymap from version "0" (no version specified) to version "1" | convert | {
"repo_name": "leafclick/intellij-community",
"path": "platform/platform-impl/src/com/intellij/openapi/keymap/impl/Converter01.java",
"license": "apache-2.0",
"size": 5318
} | [
"com.intellij.openapi.util.InvalidDataException",
"java.util.ArrayList",
"java.util.HashMap",
"java.util.Iterator",
"org.jdom.Element"
] | import com.intellij.openapi.util.InvalidDataException; import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; import org.jdom.Element; | import com.intellij.openapi.util.*; import java.util.*; import org.jdom.*; | [
"com.intellij.openapi",
"java.util",
"org.jdom"
] | com.intellij.openapi; java.util; org.jdom; | 2,035,561 |
private Measurement makePositionFlagMeasurement(Flag positionFlag,
Flag sensorFlag) throws SensorTypeNotFoundException {
Measurement result = new Measurement(1L, 1L, LocalDateTime.now(),
"RunType");
if (null != positionFlag) {
List<String> posMessage = new ArrayList<String>(1);
posMess... | Measurement function(Flag positionFlag, Flag sensorFlag) throws SensorTypeNotFoundException { Measurement result = new Measurement(1L, 1L, LocalDateTime.now(), STR); if (null != positionFlag) { List<String> posMessage = new ArrayList<String>(1); posMessage.add(POSITION_MESSAGE); MeasurementValue longitude = new Measure... | /**
* Create a measurement containing {@link MeasurementValue}s for position and
* another sensor, each with the specified QC flags.
*
* @param positionFlag
* The flag for the position value
* @param sensorFlag
* The flag for the other sensor value
* @return The measurement
... | Create a measurement containing <code>MeasurementValue</code>s for position and another sensor, each with the specified QC flags | makePositionFlagMeasurement | {
"repo_name": "BjerknesClimateDataCentre/QuinCe",
"path": "WebApp/junit/junit/uk/ac/exeter/QuinCe/data/Dataset/MeasurementTest.java",
"license": "gpl-3.0",
"size": 5591
} | [
"java.time.LocalDateTime",
"java.util.ArrayList",
"java.util.Arrays",
"java.util.List",
"uk.ac.exeter.QuinCe"
] | import java.time.LocalDateTime; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import uk.ac.exeter.QuinCe; | import java.time.*; import java.util.*; import uk.ac.exeter.*; | [
"java.time",
"java.util",
"uk.ac.exeter"
] | java.time; java.util; uk.ac.exeter; | 1,486,676 |
public void setRegisterNameValue(String registerNameValue)
throws JNCException {
setRegisterNameValue(new YangString(registerNameValue));
} | void function(String registerNameValue) throws JNCException { setRegisterNameValue(new YangString(registerNameValue)); } | /**
* Sets the value for child leaf "register-name",
* using a String value.
* @param registerNameValue used during instantiation.
*/ | Sets the value for child leaf "register-name", using a String value | setRegisterNameValue | {
"repo_name": "jnpr-shinma/yangfile",
"path": "hitel/src/hctaEpc/mmeSgsn/statistics/gprsMm/General.java",
"license": "apache-2.0",
"size": 11341
} | [
"com.tailf.jnc.YangString"
] | import com.tailf.jnc.YangString; | import com.tailf.jnc.*; | [
"com.tailf.jnc"
] | com.tailf.jnc; | 583,334 |
public SPDXPackage createSpdxPackage(String uri) throws InvalidSPDXAnalysisException {
Node spdxDocNode = getSpdxDocNode();
if (spdxDocNode == null) {
throw(new InvalidSPDXAnalysisException("Must create the SPDX document before creating an SPDX Package"));
}
// delete the previous SPDX package
Property ... | SPDXPackage function(String uri) throws InvalidSPDXAnalysisException { Node spdxDocNode = getSpdxDocNode(); if (spdxDocNode == null) { throw(new InvalidSPDXAnalysisException(STR)); } Property p = model.getProperty(SPDX_NAMESPACE, PROP_SPDX_PACKAGE); Resource s = getResource(getSpdxDocNode()); model.removeAll(s, p, null... | /**
* Creates an empty SPDX package
* @param uri Unique URI representing the SPDX package
* @return
* @throws InvalidSPDXAnalysisException
*/ | Creates an empty SPDX package | createSpdxPackage | {
"repo_name": "rtgdk/tools",
"path": "src/org/spdx/rdfparser/SPDXDocument.java",
"license": "apache-2.0",
"size": 71164
} | [
"org.apache.jena.graph.Node",
"org.apache.jena.rdf.model.Property",
"org.apache.jena.rdf.model.Resource"
] | import org.apache.jena.graph.Node; import org.apache.jena.rdf.model.Property; import org.apache.jena.rdf.model.Resource; | import org.apache.jena.graph.*; import org.apache.jena.rdf.model.*; | [
"org.apache.jena"
] | org.apache.jena; | 68,339 |
@JsMethod
public Feature readFeature(String source, String dataProjection, String featureProjection) {
FormatReadOptions options = new FormatReadOptions();
options.dataProjection = Projection.create(dataProjection);
options.featureProjection = Projection.create(featureProjection);
... | Feature function(String source, String dataProjection, String featureProjection) { FormatReadOptions options = new FormatReadOptions(); options.dataProjection = Projection.create(dataProjection); options.featureProjection = Projection.create(featureProjection); return readFeature(source, options); } | /**
* Read the feature from the IGC source.
* @param source Source.
* @param dataProjection Projection of the data we are reading. If not provided, the projection will be derived from
* the data (where possible) or the defaultDataProjection of the format is assigned (where set)... | Read the feature from the IGC source | readFeature | {
"repo_name": "iSergio/gwt-ol",
"path": "ol4gwt-main/src/main/java/org/openlayers/ol/format/IGCFormat.java",
"license": "apache-2.0",
"size": 6924
} | [
"org.openlayers.ol.Feature",
"org.openlayers.ol.format.options.FormatReadOptions",
"org.openlayers.ol.proj.Projection"
] | import org.openlayers.ol.Feature; import org.openlayers.ol.format.options.FormatReadOptions; import org.openlayers.ol.proj.Projection; | import org.openlayers.ol.*; import org.openlayers.ol.format.options.*; import org.openlayers.ol.proj.*; | [
"org.openlayers.ol"
] | org.openlayers.ol; | 410,329 |
static Viterbi getViterbi() {
if (viterbi == null) {
viterbi = SenFactory.getViterbi(IPADIC_DIR, false);
}
return viterbi;
} | static Viterbi getViterbi() { if (viterbi == null) { viterbi = SenFactory.getViterbi(IPADIC_DIR, false); } return viterbi; } | /**
* Returns a Viterbi for testing
*
* @return The Viterbi
*/ | Returns a Viterbi for testing | getViterbi | {
"repo_name": "hkazuakey/lucene-gosen",
"path": "src/test/java/net/java/sen/SenTestUtil.java",
"license": "lgpl-2.1",
"size": 7335
} | [
"net.java.sen.dictionary.Viterbi"
] | import net.java.sen.dictionary.Viterbi; | import net.java.sen.dictionary.*; | [
"net.java.sen"
] | net.java.sen; | 1,622,979 |
public static final Color getDefaultBracketMatchBGColor() {
return DEFAULT_BRACKET_MATCH_BG_COLOR;
}
| static final Color function() { return DEFAULT_BRACKET_MATCH_BG_COLOR; } | /**
* Returns the default bracket-match background color.
*
* @return The color.
* @see #getDefaultBracketMatchBorderColor
*/ | Returns the default bracket-match background color | getDefaultBracketMatchBGColor | {
"repo_name": "thomasgalvin/ThirdParty",
"path": "RText/RText-Editor/src/main/java/org/fife/ui/rsyntaxtextarea/RSyntaxTextArea.java",
"license": "apache-2.0",
"size": 82868
} | [
"java.awt.Color"
] | import java.awt.Color; | import java.awt.*; | [
"java.awt"
] | java.awt; | 619,878 |
String content = null;
String contentType = null;
int statusCode = 0;
Date timestamp = null;
HttpURLConnection connection =
(HttpURLConnection) new URL(uri).openConnection();
connection.setRequestProperty("User-Agent", this.userAgent);
connection.setRequestProperty("Connection", "close");
con... | String content = null; String contentType = null; int statusCode = 0; Date timestamp = null; HttpURLConnection connection = (HttpURLConnection) new URL(uri).openConnection(); connection.setRequestProperty(STR, this.userAgent); connection.setRequestProperty(STR, "close"); connection.setInstanceFollowRedirects(true); Inp... | /**
* Retrieve an object
*
* @param uri The URI of the object
*
* @return The instance of the object retrieved
*
* @throws IOException if the object cannot be retrieved due to I/O problems
*/ | Retrieve an object | retrieveObject | {
"repo_name": "YixingCheng/gae-webmonitor",
"path": "src/io/github/lorenzosaino/webmonitor/services/ObjectRetrievalService.java",
"license": "mit",
"size": 1988
} | [
"io.github.lorenzosaino.webmonitor.entities.WebObjectInstance",
"java.io.BufferedReader",
"java.io.InputStream",
"java.io.InputStreamReader",
"java.net.HttpURLConnection",
"java.util.Date"
] | import io.github.lorenzosaino.webmonitor.entities.WebObjectInstance; import java.io.BufferedReader; import java.io.InputStream; import java.io.InputStreamReader; import java.net.HttpURLConnection; import java.util.Date; | import io.github.lorenzosaino.webmonitor.entities.*; import java.io.*; import java.net.*; import java.util.*; | [
"io.github.lorenzosaino",
"java.io",
"java.net",
"java.util"
] | io.github.lorenzosaino; java.io; java.net; java.util; | 1,149,105 |
@ReflectiveMethod(name = "b", types = {int.class, int.class})
public void b(int i, int i1){
NMSWrapper.getInstance().exec(nmsObject, i, i1);
} | @ReflectiveMethod(name = "b", types = {int.class, int.class}) void function(int i, int i1){ NMSWrapper.getInstance().exec(nmsObject, i, i1); } | /**
* TODO Find correct name
* @see net.minecraft.server.v1_9_R1.InventoryLargeChest#b(int, int)
*/ | TODO Find correct name | b | {
"repo_name": "Vilsol/NMSWrapper",
"path": "src/main/java/me/vilsol/nmswrapper/wraps/unparsed/NMSInventoryLargeChest.java",
"license": "apache-2.0",
"size": 8229
} | [
"me.vilsol.nmswrapper.NMSWrapper",
"me.vilsol.nmswrapper.reflections.ReflectiveMethod"
] | import me.vilsol.nmswrapper.NMSWrapper; import me.vilsol.nmswrapper.reflections.ReflectiveMethod; | import me.vilsol.nmswrapper.*; import me.vilsol.nmswrapper.reflections.*; | [
"me.vilsol.nmswrapper"
] | me.vilsol.nmswrapper; | 1,960,846 |
public List<SecurityRuleInner> securityRules() {
return this.securityRules;
} | List<SecurityRuleInner> function() { return this.securityRules; } | /**
* Get collection of custom security rules.
*
* @return the securityRules value
*/ | Get collection of custom security rules | securityRules | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2018_12_01/src/main/java/com/microsoft/azure/management/network/v2018_12_01/NetworkInterfaceAssociation.java",
"license": "mit",
"size": 1572
} | [
"com.microsoft.azure.management.network.v2018_12_01.implementation.SecurityRuleInner",
"java.util.List"
] | import com.microsoft.azure.management.network.v2018_12_01.implementation.SecurityRuleInner; import java.util.List; | import com.microsoft.azure.management.network.v2018_12_01.implementation.*; import java.util.*; | [
"com.microsoft.azure",
"java.util"
] | com.microsoft.azure; java.util; | 129,573 |
protected synchronized AdRequest getAdRequest() {
AdRequest.Builder adBldr = new AdRequest.Builder();
if(!TextUtils.isEmpty(getTestDeviceId()))
adBldr.addTestDevice(getTestDeviceId());
return adBldr.build();
//.addTestDevice(AdRequest.DEVICE_ID_EMULATOR);
// All e... | synchronized AdRequest function() { AdRequest.Builder adBldr = new AdRequest.Builder(); if(!TextUtils.isEmpty(getTestDeviceId())) adBldr.addTestDevice(getTestDeviceId()); return adBldr.build(); } | /**
* Setup and get an ads request
*/ | Setup and get an ads request | getAdRequest | {
"repo_name": "skystars1688/skystars-library",
"path": "Promote/src/main/java/com/skystars/library/admobadapter/AdmobFetcherBase.java",
"license": "apache-2.0",
"size": 4818
} | [
"android.text.TextUtils",
"com.google.android.gms.ads.AdRequest"
] | import android.text.TextUtils; import com.google.android.gms.ads.AdRequest; | import android.text.*; import com.google.android.gms.ads.*; | [
"android.text",
"com.google.android"
] | android.text; com.google.android; | 2,446,979 |
public void writeSequenceMesurement(final SequenceMeasurements sm)
throws IOException {
if (this.writer == null)
return;
if (first) {
this.indexStart =
sm.getIndexMeasurment(OligoStartMeasurement.MEASUREMENT_NAME);
this.indexChromosome =
sm.getIndexMeasurment(Chr... | void function(final SequenceMeasurements sm) throws IOException { if (this.writer == null) return; if (first) { this.indexStart = sm.getIndexMeasurment(OligoStartMeasurement.MEASUREMENT_NAME); this.indexChromosome = sm.getIndexMeasurment(ChromosomeMeasurement.MEASUREMENT_NAME); this.indexLength = sm.getIndexMeasurment(... | /**
* Write a sequence measurement to the file.
* @param sm Sequence measurement to write
* @throws IOException if an error occurs while writing data
*/ | Write a sequence measurement to the file | writeSequenceMesurement | {
"repo_name": "GenomicParisCentre/teolenn",
"path": "src/main/java/fr/ens/transcriptome/teolenn/output/GFFOutput.java",
"license": "gpl-2.0",
"size": 6268
} | [
"fr.ens.transcriptome.teolenn.measurement.ChromosomeMeasurement",
"fr.ens.transcriptome.teolenn.measurement.OligoLengthMeasurement",
"fr.ens.transcriptome.teolenn.measurement.OligoStartMeasurement",
"fr.ens.transcriptome.teolenn.selector.GlobalScoreMeasurement",
"fr.ens.transcriptome.teolenn.selector.ORFMea... | import fr.ens.transcriptome.teolenn.measurement.ChromosomeMeasurement; import fr.ens.transcriptome.teolenn.measurement.OligoLengthMeasurement; import fr.ens.transcriptome.teolenn.measurement.OligoStartMeasurement; import fr.ens.transcriptome.teolenn.selector.GlobalScoreMeasurement; import fr.ens.transcriptome.teolenn.s... | import fr.ens.transcriptome.teolenn.measurement.*; import fr.ens.transcriptome.teolenn.selector.*; import fr.ens.transcriptome.teolenn.sequence.*; import java.io.*; | [
"fr.ens.transcriptome",
"java.io"
] | fr.ens.transcriptome; java.io; | 1,814,808 |
@Test public void duplexWithAuthChallenge() throws Exception {
enableProtocol(Protocol.HTTP_2);
String credential = Credentials.basic("jesse", "secret");
client = client.newBuilder()
.authenticator(new RecordingOkAuthenticator(credential, null))
.build();
MockDuplexResponseBody mockR... | @Test void function() throws Exception { enableProtocol(Protocol.HTTP_2); String credential = Credentials.basic("jesse", STR); client = client.newBuilder() .authenticator(new RecordingOkAuthenticator(credential, null)) .build(); MockDuplexResponseBody mockResponseBody1 = enqueueResponseWithBody( new MockResponse() .cle... | /**
* Auth requires follow-ups. Unlike redirects, the auth follow-up also has a request body. This
* test makes a single call with two duplex requests!
*/ | Auth requires follow-ups. Unlike redirects, the auth follow-up also has a request body. This test makes a single call with two duplex requests | duplexWithAuthChallenge | {
"repo_name": "cmzy/okhttp",
"path": "okhttp/src/test/java/okhttp3/DuplexTest.java",
"license": "apache-2.0",
"size": 21555
} | [
"java.io.IOException",
"java.net.HttpURLConnection",
"org.assertj.core.api.Assertions",
"org.junit.jupiter.api.Assertions",
"org.junit.jupiter.api.Test"
] | import java.io.IOException; import java.net.HttpURLConnection; import org.assertj.core.api.Assertions; import org.junit.jupiter.api.Assertions; import org.junit.jupiter.api.Test; | import java.io.*; import java.net.*; import org.assertj.core.api.*; import org.junit.jupiter.api.*; | [
"java.io",
"java.net",
"org.assertj.core",
"org.junit.jupiter"
] | java.io; java.net; org.assertj.core; org.junit.jupiter; | 2,456,663 |
public boolean isAtEnd() throws IOException {
return bufferPos == bufferSize && !refillBuffer(false);
} | boolean function() throws IOException { return bufferPos == bufferSize && !refillBuffer(false); } | /**
* Returns true if the stream has reached the end of the input. This is the
* case if either the end of the underlying input source has been reached or
* if the stream has reached a limit created using {@link #pushLimit(int)}.
*/ | Returns true if the stream has reached the end of the input. This is the case if either the end of the underlying input source has been reached or if the stream has reached a limit created using <code>#pushLimit(int)</code> | isAtEnd | {
"repo_name": "TextusData/Mover",
"path": "thirdparty/protobuf-2.2.0/java/src/main/java/com/google/protobuf/CodedInputStream.java",
"license": "gpl-3.0",
"size": 27856
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 2,452,307 |
public static synchronized long initialGPUMemBudget() throws RuntimeException {
try {
if (!initialized)
initializeGPU();
return INITIAL_GPU_MEMORY_BUDGET;
} catch (DMLRuntimeException e){
throw new RuntimeException(e);
}
} | static synchronized long function() throws RuntimeException { try { if (!initialized) initializeGPU(); return INITIAL_GPU_MEMORY_BUDGET; } catch (DMLRuntimeException e){ throw new RuntimeException(e); } } | /**
* Gets the initial GPU memory budget. This is the minimum of the
* available memories across all the GPUs on the machine(s)
* @return minimum available memory
* @throws RuntimeException if error initializing the GPUs
*/ | Gets the initial GPU memory budget. This is the minimum of the available memories across all the GPUs on the machine(s) | initialGPUMemBudget | {
"repo_name": "deroneriksson/incubator-systemml",
"path": "src/main/java/org/apache/sysml/runtime/instructions/gpu/context/GPUContextPool.java",
"license": "apache-2.0",
"size": 8749
} | [
"org.apache.sysml.runtime.DMLRuntimeException"
] | import org.apache.sysml.runtime.DMLRuntimeException; | import org.apache.sysml.runtime.*; | [
"org.apache.sysml"
] | org.apache.sysml; | 826,212 |
@Test
public void testOneAttributeFromJson() throws Exception {
productRelease.fromSdcJson(productReleaseJsonOneAttribute);
assertEquals(productRelease.getDescription(), "mysql 1.2.4");
assertEquals(productRelease.getVersion(), "1.2.4");
assertEquals(productRelease.getProduct(), ... | void function() throws Exception { productRelease.fromSdcJson(productReleaseJsonOneAttribute); assertEquals(productRelease.getDescription(), STR); assertEquals(productRelease.getVersion(), "1.2.4"); assertEquals(productRelease.getProduct(), "mysql"); assertEquals(productRelease.getName(), STR); } | /**
* Test the creation of a product message from a json message with only 1 attribute.
* @throws Exception
*/ | Test the creation of a product message from a json message with only 1 attribute | testOneAttributeFromJson | {
"repo_name": "telefonicaid/fiware-paas",
"path": "model/src/test/java/com/telefonica/euro_iaas/paasmanager/model/ProductReleaseTest.java",
"license": "apache-2.0",
"size": 12666
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 609,696 |
public void startNewTrial(){
this.trials.add(new Trial());
}
}
protected class Trial{
public List<Double> cumulativeStepReward = new ArrayList<Double>();
public List<Double> cumulativeEpisodeReward = new ArrayList<Double>();
public List<Double> averageEpisodeReward = n... | void function(){ this.trials.add(new Trial()); } } protected class Trial{ public List<Double> cumulativeStepReward = new ArrayList<Double>(); public List<Double> cumulativeEpisodeReward = new ArrayList<Double>(); public List<Double> averageEpisodeReward = new ArrayList<Double>(); public List<Double> medianEpisodeReward... | /**
* Creates a new trial object and adds it to the end of the list of trials.
*/ | Creates a new trial object and adds it to the end of the list of trials | startNewTrial | {
"repo_name": "gauravpuri/MDP_Repp",
"path": "src/burlap/behavior/stochasticgames/auxiliary/performance/MultiAgentPerformancePlotter.java",
"license": "lgpl-3.0",
"size": 41844
} | [
"java.util.ArrayList",
"java.util.List"
] | import java.util.ArrayList; import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,007,149 |
public Set getUserGroups() {
return usergroups;
} | Set function() { return usergroups; } | /**
* Get UserGroups for this Org. This is used internally within this package
* to map Roles to UserGroups
* @return userGroup array
*/ | Get UserGroups for this Org. This is used internally within this package to map Roles to UserGroups | getUserGroups | {
"repo_name": "colloquium/spacewalk",
"path": "java/code/src/com/redhat/rhn/domain/org/Org.java",
"license": "gpl-2.0",
"size": 20150
} | [
"java.util.Set"
] | import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 530,002 |
protected Node mkdir(String path, boolean autoSave) throws RepositoryException {
return registry.mkdir(path, autoSave);
}
/**
* {@inheritDoc} | Node function(String path, boolean autoSave) throws RepositoryException { return registry.mkdir(path, autoSave); } /** * {@inheritDoc} | /**
* yet another Convenience method to create intermediate nodes.
* @param path path to create
* @param autoSave if {@code true} all changes are automatically persisted
* @return the node
* @throws RepositoryException if an error occurrs
*/ | yet another Convenience method to create intermediate nodes | mkdir | {
"repo_name": "tripodsan/jackrabbit-filevault",
"path": "vault-core/src/main/java/org/apache/jackrabbit/vault/packaging/impl/JcrPackageManagerImpl.java",
"license": "apache-2.0",
"size": 20489
} | [
"javax.jcr.Node",
"javax.jcr.RepositoryException"
] | import javax.jcr.Node; import javax.jcr.RepositoryException; | import javax.jcr.*; | [
"javax.jcr"
] | javax.jcr; | 1,620,650 |
@Test
public void testWordHTML() throws Exception {
XMLResult result = getXML("testWORD.docx");
String xml = result.xml;
Metadata metadata = result.metadata;
assertEquals(
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
m... | void function() throws Exception { XMLResult result = getXML(STR); String xml = result.xml; Metadata metadata = result.metadata; assertEquals( STR, metadata.get(Metadata.CONTENT_TYPE)); assertEquals(STR, metadata.get(TikaCoreProperties.TITLE)); assertEquals(STR, metadata.get(TikaCoreProperties.CREATOR)); assertEquals(S... | /**
* Test that the word converter is able to generate the
* correct HTML for the document
*/ | Test that the word converter is able to generate the correct HTML for the document | testWordHTML | {
"repo_name": "icirellik/tika",
"path": "tika-parsers/src/test/java/org/apache/tika/parser/microsoft/ooxml/OOXMLParserTest.java",
"license": "apache-2.0",
"size": 67582
} | [
"org.apache.tika.metadata.Metadata",
"org.apache.tika.metadata.TikaCoreProperties",
"org.junit.Assert"
] | import org.apache.tika.metadata.Metadata; import org.apache.tika.metadata.TikaCoreProperties; import org.junit.Assert; | import org.apache.tika.metadata.*; import org.junit.*; | [
"org.apache.tika",
"org.junit"
] | org.apache.tika; org.junit; | 1,173,426 |
OrganizationProfile get(); | OrganizationProfile get(); | /**
* Retrieves the partner's organization profile.
*
* @return The organization profile.
*/ | Retrieves the partner's organization profile | get | {
"repo_name": "iogav/Partner-Center-Java-SDK",
"path": "PartnerSdk/src/main/java/com/microsoft/store/partnercenter/profiles/IOrganizationProfile.java",
"license": "mit",
"size": 1283
} | [
"com.microsoft.store.partnercenter.models.partners.OrganizationProfile"
] | import com.microsoft.store.partnercenter.models.partners.OrganizationProfile; | import com.microsoft.store.partnercenter.models.partners.*; | [
"com.microsoft.store"
] | com.microsoft.store; | 809,478 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.