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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
@Nullable
public Vec3d getTargetLocation()
{
return this.targetLocation;
} | Vec3d function() { return this.targetLocation; } | /**
* Returns the location the dragon is flying toward
*/ | Returns the location the dragon is flying toward | getTargetLocation | {
"repo_name": "danielyc/test-1.9.4",
"path": "build/tmp/recompileMc/sources/net/minecraft/entity/boss/dragon/phase/PhaseLandingApproach.java",
"license": "gpl-3.0",
"size": 3584
} | [
"net.minecraft.util.math.Vec3d"
] | import net.minecraft.util.math.Vec3d; | import net.minecraft.util.math.*; | [
"net.minecraft.util"
] | net.minecraft.util; | 2,337,452 |
@NonNull
public StaticLayoutBuilderCompat setMaxLines(@IntRange(from = 0) int maxLines) {
this.maxLines = maxLines;
return this;
}
/**
* Set the line spacing addition and multiplier frequency. Only available on API level 23+.
*
* @param spacingAdd Line spacing addition for the resulting {@link... | StaticLayoutBuilderCompat function(@IntRange(from = 0) int maxLines) { this.maxLines = maxLines; return this; } /** * Set the line spacing addition and multiplier frequency. Only available on API level 23+. * * @param spacingAdd Line spacing addition for the resulting {@link StaticLayout} * @param lineSpacingMultiplier... | /**
* Set maximum number of lines. This is particularly useful in the case of ellipsizing, where it
* changes the layout of the last line. The default is unlimited.
*
* @param maxLines maximum number of lines in the layout
* @return this builder, useful for chaining
* @see android.widget.TextView#setM... | Set maximum number of lines. This is particularly useful in the case of ellipsizing, where it changes the layout of the last line. The default is unlimited | setMaxLines | {
"repo_name": "material-components/material-components-android",
"path": "lib/java/com/google/android/material/internal/StaticLayoutBuilderCompat.java",
"license": "apache-2.0",
"size": 11949
} | [
"android.text.StaticLayout",
"androidx.annotation.IntRange"
] | import android.text.StaticLayout; import androidx.annotation.IntRange; | import android.text.*; import androidx.annotation.*; | [
"android.text",
"androidx.annotation"
] | android.text; androidx.annotation; | 638,988 |
protected void openFileChooser(ActionEvent e) {
OurGridFileChooser fileChooser = new OurGridFileChooser("Properties file", "properties");
File propertiesFile = fileChooser.getFile();
if (propertiesFile != null) {
Properties prop = CommonUtils.loadProperties(propertiesFile);
peerAddr... | void function(ActionEvent e) { OurGridFileChooser fileChooser = new OurGridFileChooser(STR, STR); File propertiesFile = fileChooser.getFile(); if (propertiesFile != null) { Properties prop = CommonUtils.loadProperties(propertiesFile); peerAddressTextArea.setText(prop.getProperty(SignatureProperties.PROP_PUBLIC_KEY)); }... | /**
* Opens a FileChooser that permites define the peer public key.
* @param e The event that represents the clicking of the loadButton.
*/ | Opens a FileChooser that permites define the peer public key | openFileChooser | {
"repo_name": "OurGrid/OurGrid",
"path": "src/main/java/org/ourgrid/worker/ui/async/gui/WorkerBasicSettingsPanel.java",
"license": "lgpl-3.0",
"size": 15688
} | [
"br.edu.ufcg.lsd.commune.network.signature.SignatureProperties",
"java.awt.event.ActionEvent",
"java.io.File",
"java.util.Properties",
"org.ourgrid.common.util.CommonUtils",
"org.ourgrid.peer.ui.async.gui.OurGridFileChooser"
] | import br.edu.ufcg.lsd.commune.network.signature.SignatureProperties; import java.awt.event.ActionEvent; import java.io.File; import java.util.Properties; import org.ourgrid.common.util.CommonUtils; import org.ourgrid.peer.ui.async.gui.OurGridFileChooser; | import br.edu.ufcg.lsd.commune.network.signature.*; import java.awt.event.*; import java.io.*; import java.util.*; import org.ourgrid.common.util.*; import org.ourgrid.peer.ui.async.gui.*; | [
"br.edu.ufcg",
"java.awt",
"java.io",
"java.util",
"org.ourgrid.common",
"org.ourgrid.peer"
] | br.edu.ufcg; java.awt; java.io; java.util; org.ourgrid.common; org.ourgrid.peer; | 1,912,669 |
public static <T> T[] shuffle(T[] array) {
return shuffle(array, new Random());
} | static <T> T[] function(T[] array) { return shuffle(array, new Random()); } | /**
* Shuffles the given array.
*
* @return mutated parameter array that was shuffled beforehand.
*/ | Shuffles the given array | shuffle | {
"repo_name": "sourcewarehouse/thomasjungblut",
"path": "src/de/jungblut/datastructure/ArrayUtils.java",
"license": "apache-2.0",
"size": 40697
} | [
"java.util.Random"
] | import java.util.Random; | import java.util.*; | [
"java.util"
] | java.util; | 1,490,797 |
public Type getOwnerType() {
return ownerType;
} | Type function() { return ownerType; } | /**
* Returns a <tt>Type</tt> object representing the type that this type
* is a member of. For example, if this type is <tt>O<T>.I<S></tt>,
* return a representation of <tt>O<T></tt>.
*
* <p>If this type is a top-level type, <tt>null</tt> is returned.
*
* @return a <tt>Type</tt> obj... | Returns a Type object representing the type that this type is a member of. For example, if this type is O.I, return a representation of O. If this type is a top-level type, null is returned | getOwnerType | {
"repo_name": "TheTypoMaster/Scaper",
"path": "openjdk/jdk/src/share/classes/sun/reflect/generics/reflectiveObjects/ParameterizedTypeImpl.java",
"license": "gpl-2.0",
"size": 9904
} | [
"java.lang.reflect.Type"
] | import java.lang.reflect.Type; | import java.lang.reflect.*; | [
"java.lang"
] | java.lang; | 1,801,832 |
public AttributeInfo getAttribute(String name) {
ArrayList list = attributes;
int n = list.size();
for (int i = 0; i < n; ++i) {
AttributeInfo ai = (AttributeInfo)list.get(i);
if (ai.getName().equals(name))
return ai;
}
return null;
... | AttributeInfo function(String name) { ArrayList list = attributes; int n = list.size(); for (int i = 0; i < n; ++i) { AttributeInfo ai = (AttributeInfo)list.get(i); if (ai.getName().equals(name)) return ai; } return null; } | /**
* Returns the attribute with the specified name. If there are multiple
* attributes with that name, this method returns either of them. It
* returns null if the specified attributed is not found.
*
* @param name attribute name
* @see #getAttributes()
*/ | Returns the attribute with the specified name. If there are multiple attributes with that name, this method returns either of them. It returns null if the specified attributed is not found | getAttribute | {
"repo_name": "ilagunap/process-profiler",
"path": "java_methods_profiler/javaassist/javassist-3.16.1-GA/src/main/javassist/bytecode/ClassFile.java",
"license": "gpl-3.0",
"size": 26642
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 1,303,822 |
public MessageBuilder addRecipient(String address, String name) throws AddressException
{
recipients.add(createAddress(address, name));
return this;
} | MessageBuilder function(String address, String name) throws AddressException { recipients.add(createAddress(address, name)); return this; } | /**
* Adds a recipient to the list. If the name parameter is specified as
* "John Doe" then the recipient will be in the form of
* "John Doe <name@example.com>"
*
* @param address
* The internet email address in the form of "name@example.com" or
* "name <nam... | Adds a recipient to the list. If the name parameter is specified as "John Doe" then the recipient will be in the form of "John Doe <name@example.com>" | addRecipient | {
"repo_name": "jaapgeurts/snap",
"path": "src/main/java/snap/mail/Mailer.java",
"license": "gpl-2.0",
"size": 11691
} | [
"javax.mail.internet.AddressException"
] | import javax.mail.internet.AddressException; | import javax.mail.internet.*; | [
"javax.mail"
] | javax.mail; | 2,154,148 |
public static String quoteIfNeeded(String s, String delim)
{
if (s==null)
return null;
if (s.length()==0)
return "\"\"";
for (int i=0;i<s.length();i++)
{
char c = s.charAt(i);
if (c=='\\' || c=='"' || c=='\'' || Character.isW... | static String function(String s, String delim) { if (s==null) return null; if (s.length()==0) return "\"\STR' c=='\'' Character.isWhitespace(c) delim.indexOf(c)>=0) { StringBuffer b=new StringBuffer(s.length()+8); quote(b,s); return b.toString(); } } return s; } private static final char[] escapes = new char[32]; stati... | /** Quote a string.
* The string is quoted only if quoting is required due to
* embedded delimiters, quote characters or the
* empty string.
* @param s The string to quote.
* @param delim the delimiter to use to quote the string
* @return quoted string
*/ | Quote a string. The string is quoted only if quoting is required due to embedded delimiters, quote characters or the empty string | quoteIfNeeded | {
"repo_name": "knowledgecode/jetty-websocket-android",
"path": "src/org/eclipse/jetty/util/QuotedStringTokenizer.java",
"license": "apache-2.0",
"size": 10524
} | [
"java.util.Arrays"
] | import java.util.Arrays; | import java.util.*; | [
"java.util"
] | java.util; | 2,553,422 |
public void setCreateDate(Date createDate) {
this.createDate = createDate;
} | void function(Date createDate) { this.createDate = createDate; } | /**
* Setter of createDate.
*
* @param createDate createDate
*/ | Setter of createDate | setCreateDate | {
"repo_name": "sismics/books",
"path": "books-core/src/main/java/com/sismics/books/core/model/jpa/User.java",
"license": "gpl-2.0",
"size": 4946
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 96,745 |
@SubscribeEvent(priority = EventPriority.HIGHEST)
public void magPickBonus(PlayerEvent.BreakSpeed event)
{
EntityPlayer player = event.entityPlayer;
ItemStack itemstack = player.getCurrentEquippedItem();
List<Item> SpeedItems = new ArrayList();
SpeedItems.add(MagItems.MagAxe);
SpeedItems.add(MagItems.Mag... | @SubscribeEvent(priority = EventPriority.HIGHEST) void function(PlayerEvent.BreakSpeed event) { EntityPlayer player = event.entityPlayer; ItemStack itemstack = player.getCurrentEquippedItem(); List<Item> SpeedItems = new ArrayList(); SpeedItems.add(MagItems.MagAxe); SpeedItems.add(MagItems.MagEarthMover); SpeedItems.ad... | /**
* Speeds up the player's ability to harvest Blocks based on their
* experience while using the magPick
*
* @param event
*/ | Speeds up the player's ability to harvest Blocks based on their experience while using the magPick | magPickBonus | {
"repo_name": "VapourDrive/MagTools",
"path": "src/main/java/com/vapourdrive/magtools/events/MagSpeedBonus.java",
"license": "mit",
"size": 1803
} | [
"com.vapourdrive.magtools.config.ConfigInfo",
"com.vapourdrive.magtools.items.MagItems",
"java.util.ArrayList",
"java.util.List",
"net.minecraft.block.Block",
"net.minecraft.block.material.Material",
"net.minecraft.entity.player.EntityPlayer",
"net.minecraft.item.Item",
"net.minecraft.item.ItemStack... | import com.vapourdrive.magtools.config.ConfigInfo; import com.vapourdrive.magtools.items.MagItems; import java.util.ArrayList; import java.util.List; import net.minecraft.block.Block; import net.minecraft.block.material.Material; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import ne... | import com.vapourdrive.magtools.config.*; import com.vapourdrive.magtools.items.*; import java.util.*; import net.minecraft.block.*; import net.minecraft.block.material.*; import net.minecraft.entity.player.*; import net.minecraft.item.*; import net.minecraftforge.event.entity.player.*; | [
"com.vapourdrive.magtools",
"java.util",
"net.minecraft.block",
"net.minecraft.entity",
"net.minecraft.item",
"net.minecraftforge.event"
] | com.vapourdrive.magtools; java.util; net.minecraft.block; net.minecraft.entity; net.minecraft.item; net.minecraftforge.event; | 2,533,701 |
public BigDecimal getPastDue61_Plus ()
{
BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_PastDue61_Plus);
if (bd == null)
return Env.ZERO;
return bd;
} | BigDecimal function () { BigDecimal bd = (BigDecimal)get_Value(COLUMNNAME_PastDue61_Plus); if (bd == null) return Env.ZERO; return bd; } | /** Get Past Due > 61.
@return Past Due > 61 */ | Get Past Due > 61 | getPastDue61_Plus | {
"repo_name": "klst-com/metasfresh",
"path": "de.metas.adempiere.adempiere/base/src/main/java-gen/org/compiere/model/X_T_Aging.java",
"license": "gpl-2.0",
"size": 20737
} | [
"java.math.BigDecimal",
"org.compiere.util.Env"
] | import java.math.BigDecimal; import org.compiere.util.Env; | import java.math.*; import org.compiere.util.*; | [
"java.math",
"org.compiere.util"
] | java.math; org.compiere.util; | 1,560,236 |
public void setHostname(Socket socket, String hostName) {
castToOpenSSLSocket(socket).setHostname(hostName);
} | void function(Socket socket, String hostName) { castToOpenSSLSocket(socket).setHostname(hostName); } | /**
* Turns on <a href="http://tools.ietf.org/html/rfc6066#section-3">Server
* Name Indication (SNI)</a> on a given socket.
*
* @param socket a socket created by this factory.
* @param hostName the desired SNI hostname, null to disable.
* @throws IllegalArgumentException if the socket was ... | Turns on Server Name Indication (SNI) on a given socket | setHostname | {
"repo_name": "haikuowuya/android_system_code",
"path": "src/android/net/SSLCertificateSocketFactory.java",
"license": "apache-2.0",
"size": 19572
} | [
"java.net.Socket"
] | import java.net.Socket; | import java.net.*; | [
"java.net"
] | java.net; | 787,849 |
public Set<ID> getPeerIDs() {
return Collections.unmodifiableSet(peerids);
} | Set<ID> function() { return Collections.unmodifiableSet(peerids); } | /**
* Returns a {@link java.util.Set} (possibly empty) containing the peer ids
* which should respond to this query.
*
* @return set containing the peer ids to which this peer is directed.
*/ | Returns a <code>java.util.Set</code> (possibly empty) containing the peer ids which should respond to this query | getPeerIDs | {
"repo_name": "johnjianfang/jxse",
"path": "src/main/java/net/jxta/protocol/PipeResolverMessage.java",
"license": "apache-2.0",
"size": 8258
} | [
"java.util.Collections",
"java.util.Set"
] | import java.util.Collections; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 2,086,804 |
@Override
void createRowIndexEntry() throws IOException {
getFileStatistics().merge(indexStatistics);
OrcProto.RowIndexEntry.Builder rowIndexEntry = getRowIndexEntry();
rowIndexEntry.setStatistics(indexStatistics.serialize());
indexStatistics.reset();
if (useCarriedOverDirectEncodi... | void createRowIndexEntry() throws IOException { getFileStatistics().merge(indexStatistics); OrcProto.RowIndexEntry.Builder rowIndexEntry = getRowIndexEntry(); rowIndexEntry.setStatistics(indexStatistics.serialize()); indexStatistics.reset(); if (useCarriedOverDirectEncoding()) { getRowIndex().addEntry(rowIndexEntry); }... | /**
* This method doesn't call the super method, because unlike most of the
* other TreeWriters, this one can't record the position in the streams
* until the stripe is being flushed. Therefore it saves all of the entries
* and augments them with the final information as the stripe is written.
... | This method doesn't call the super method, because unlike most of the other TreeWriters, this one can't record the position in the streams until the stripe is being flushed. Therefore it saves all of the entries and augments them with the final information as the stripe is written | createRowIndexEntry | {
"repo_name": "libin/hive-dwrf",
"path": "hive-dwrf/src/main/java/com/facebook/hive/orc/WriterImpl.java",
"license": "apache-2.0",
"size": 91194
} | [
"java.io.IOException"
] | import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 1,838,416 |
public TaskContainer getExportTaskContainer() {
return getTaskContainer(TaskReference.Phase.EXPORT);
} | TaskContainer function() { return getTaskContainer(TaskReference.Phase.EXPORT); } | /**
* Returns a {@link TaskContainer} for {@code export} phase.
* @return task reference container
*/ | Returns a <code>TaskContainer</code> for export phase | getExportTaskContainer | {
"repo_name": "ashigeru/asakusafw-compiler",
"path": "compiler-project/api/src/main/java/com/asakusafw/lang/compiler/api/basic/TaskContainerMap.java",
"license": "apache-2.0",
"size": 3620
} | [
"com.asakusafw.lang.compiler.api.reference.TaskReference"
] | import com.asakusafw.lang.compiler.api.reference.TaskReference; | import com.asakusafw.lang.compiler.api.reference.*; | [
"com.asakusafw.lang"
] | com.asakusafw.lang; | 53,654 |
@Test
@Ignore
public void assertNotContainsWorksCorrect() {
assertTrue(fixture.assertNotContains("Auto", "Bahn"));
assertTrue(fixture.assertNotContains("Auto", null));
assertTrue(fixture.assertNotContains(null, "Bahn"));
assertFalse(fixture.assertNotContains("Hallo Welt", "Welt"));
assertFalse(fixture.a... | void function() { assertTrue(fixture.assertNotContains("Auto", "Bahn")); assertTrue(fixture.assertNotContains("Auto", null)); assertTrue(fixture.assertNotContains(null, "Bahn")); assertFalse(fixture.assertNotContains(STR, "Welt")); assertFalse(fixture.assertNotContains(STR, STR)); assertFalse(fixture.assertNotContains(... | /**
* Test for assertNotContains.
*/ | Test for assertNotContains | assertNotContainsWorksCorrect | {
"repo_name": "yatol/yatol",
"path": "acceptanceTest/webfixture/src/test/java/org/testeditor/fixture/web/WebFixtureTest.java",
"license": "epl-1.0",
"size": 24750
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 983,152 |
public static String getCertificateDistinguishedName(InputStream keystore,
String password, String alias, boolean useBCAPI) {
PKCS12Content content = loadFromKeyStore(keystore, password, alias, useBCAPI);
if (content == null || content.certificates == null || content.certificates[0] == null)
return null;
... | static String function(InputStream keystore, String password, String alias, boolean useBCAPI) { PKCS12Content content = loadFromKeyStore(keystore, password, alias, useBCAPI); if (content == null content.certificates == null content.certificates[0] == null) return null; return content.certificates[0].getSubjectDN().toSt... | /** This is a helper function for fetching the distinguished name from a certificate.
*
* @param keystore The keystore/PKCS12 file to load from.
* @param password The password used to encrypt the keystore/PKCS12 file.
* @param alias The alias used to store the certificate in the keystore/PKCS12 file.
* @para... | This is a helper function for fetching the distinguished name from a certificate | getCertificateDistinguishedName | {
"repo_name": "mobilesec/openuat",
"path": "src/org/openuat/channel/X509CertificateGenerator.java",
"license": "lgpl-3.0",
"size": 38112
} | [
"java.io.InputStream"
] | import java.io.InputStream; | import java.io.*; | [
"java.io"
] | java.io; | 1,595,229 |
public interface ReaderImportRowHandler
{
void handleRow(Iterator columnIterator) throws ImportException;
}
| interface ReaderImportRowHandler { void function(Iterator columnIterator) throws ImportException; } | /**
* This is the callback that is called for each row.
* @param columnIterator Iterator for a collection of CSVReaderImportCell for this row.
*/ | This is the callback that is called for each row | handleRow | {
"repo_name": "marktriggs/nyu-sakai-10.4",
"path": "calendar/calendar-impl/impl/src/java/org/sakaiproject/calendar/impl/readers/Reader.java",
"license": "apache-2.0",
"size": 8035
} | [
"java.util.Iterator",
"org.sakaiproject.exception.ImportException"
] | import java.util.Iterator; import org.sakaiproject.exception.ImportException; | import java.util.*; import org.sakaiproject.exception.*; | [
"java.util",
"org.sakaiproject.exception"
] | java.util; org.sakaiproject.exception; | 1,380,658 |
@GET
@Produces("application/json")
public Response handleGet(@Context HttpServletRequest request,
@QueryParam("page") @DefaultValue("0") int page,
@QueryParam("pageSize") @DefaultValue("-1") int pgSize,
@QueryParam("count") @DefaultValue("false") boolean cnt,
@QueryParam("sort") @DefaultValue("name") S... | @Produces(STR) Response function(@Context HttpServletRequest request, @QueryParam("page") @DefaultValue("0") int page, @QueryParam(STR) @DefaultValue("-1") int pgSize, @QueryParam("count") @DefaultValue("false") boolean cnt, @QueryParam("sort") @DefaultValue("name") String sort, @QueryParam("tagId") int tagId, @QueryPa... | /**
* List videos.
*/ | List videos | handleGet | {
"repo_name": "harkwell/khallware",
"path": "src/main/java/com/khallware/api/ctrl/Videos.java",
"license": "gpl-3.0",
"size": 5965
} | [
"com.khallware.api.domain.Video",
"com.khallware.api.dstore.Pagination",
"javax.servlet.http.HttpServletRequest",
"javax.ws.rs.DefaultValue",
"javax.ws.rs.Produces",
"javax.ws.rs.QueryParam",
"javax.ws.rs.core.Context",
"javax.ws.rs.core.Response"
] | import com.khallware.api.domain.Video; import com.khallware.api.dstore.Pagination; import javax.servlet.http.HttpServletRequest; import javax.ws.rs.DefaultValue; import javax.ws.rs.Produces; import javax.ws.rs.QueryParam; import javax.ws.rs.core.Context; import javax.ws.rs.core.Response; | import com.khallware.api.domain.*; import com.khallware.api.dstore.*; import javax.servlet.http.*; import javax.ws.rs.*; import javax.ws.rs.core.*; | [
"com.khallware.api",
"javax.servlet",
"javax.ws"
] | com.khallware.api; javax.servlet; javax.ws; | 2,466,263 |
public final Pagerator<Refund>
getRefunds(final Refund refund, final Filter filter)
throws IOException, OptimalException {
final HashMap<String, String> queryStr = new HashMap<String, String>();
if (null != refund) {
if (null != refund.getMerchantRefNum() && !refund.getMerchantRefNu... | final Pagerator<Refund> function(final Refund refund, final Filter filter) throws IOException, OptimalException { final HashMap<String, String> queryStr = new HashMap<String, String>(); if (null != refund) { if (null != refund.getMerchantRefNum() && !refund.getMerchantRefNum().isEmpty()) { queryStr.put(MERCHANT_REF_NUM... | /**
* Get matching refunds.
*
* @param refund the refund
* @param filter the filter
* @return Pagerator< Refund >
* @throws IOException Signals that an I/O exception has occurred.
* @throws OptimalException the optimal exception
*/ | Get matching refunds | getRefunds | {
"repo_name": "OptimalPayments/Java_SDK",
"path": "NetBanxSDK/src/main/java/com/optimalpayments/cardpayments/CardPaymentsService.java",
"license": "mit",
"size": 24566
} | [
"com.optimalpayments.cardpayments.impl.RefundPagerator",
"com.optimalpayments.common.OptimalException",
"com.optimalpayments.common.Pagerator",
"com.optimalpayments.common.impl.Request",
"java.io.IOException",
"java.util.HashMap"
] | import com.optimalpayments.cardpayments.impl.RefundPagerator; import com.optimalpayments.common.OptimalException; import com.optimalpayments.common.Pagerator; import com.optimalpayments.common.impl.Request; import java.io.IOException; import java.util.HashMap; | import com.optimalpayments.cardpayments.impl.*; import com.optimalpayments.common.*; import com.optimalpayments.common.impl.*; import java.io.*; import java.util.*; | [
"com.optimalpayments.cardpayments",
"com.optimalpayments.common",
"java.io",
"java.util"
] | com.optimalpayments.cardpayments; com.optimalpayments.common; java.io; java.util; | 2,496,020 |
public Set getProhibitedACAttributes()
{
return Collections.unmodifiableSet(prohibitedACAttributes);
} | Set function() { return Collections.unmodifiableSet(prohibitedACAttributes); } | /**
* Returns the attribute certificates which are not allowed.
* <p>
* The returned <code>Set</code> is immutable and contains
* <code>String</code>s with the OIDs.
*
* @return Returns the prohibited AC attributes. Is never <code>null</code>.
*/ | Returns the attribute certificates which are not allowed. The returned <code>Set</code> is immutable and contains <code>String</code>s with the OIDs | getProhibitedACAttributes | {
"repo_name": "bullda/DroidText",
"path": "src/bouncycastle/repack/org/bouncycastle/x509/ExtendedPKIXParameters.java",
"license": "lgpl-3.0",
"size": 21507
} | [
"java.util.Collections",
"java.util.Set"
] | import java.util.Collections; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 437,455 |
public void createEmpty() throws IOException {
Version luceneVersion = indexSettings.getIndexVersionCreated().luceneVersion;
metadataLock.writeLock().lock();
try (IndexWriter writer = newTemporaryEmptyIndexWriter(directory, luceneVersion)) {
final Map<String, String> map = new Ha... | void function() throws IOException { Version luceneVersion = indexSettings.getIndexVersionCreated().luceneVersion; metadataLock.writeLock().lock(); try (IndexWriter writer = newTemporaryEmptyIndexWriter(directory, luceneVersion)) { final Map<String, String> map = new HashMap<>(); map.put(Engine.HISTORY_UUID_KEY, UUIDs.... | /**
* creates an empty lucene index and a corresponding empty translog. Any existing data will be deleted.
*/ | creates an empty lucene index and a corresponding empty translog. Any existing data will be deleted | createEmpty | {
"repo_name": "robin13/elasticsearch",
"path": "server/src/main/java/org/elasticsearch/index/store/Store.java",
"license": "apache-2.0",
"size": 74189
} | [
"java.io.IOException",
"java.util.HashMap",
"java.util.Map",
"org.apache.lucene.index.IndexWriter",
"org.apache.lucene.util.Version",
"org.elasticsearch.common.UUIDs",
"org.elasticsearch.index.engine.Engine",
"org.elasticsearch.index.seqno.SequenceNumbers"
] | import java.io.IOException; import java.util.HashMap; import java.util.Map; import org.apache.lucene.index.IndexWriter; import org.apache.lucene.util.Version; import org.elasticsearch.common.UUIDs; import org.elasticsearch.index.engine.Engine; import org.elasticsearch.index.seqno.SequenceNumbers; | import java.io.*; import java.util.*; import org.apache.lucene.index.*; import org.apache.lucene.util.*; import org.elasticsearch.common.*; import org.elasticsearch.index.engine.*; import org.elasticsearch.index.seqno.*; | [
"java.io",
"java.util",
"org.apache.lucene",
"org.elasticsearch.common",
"org.elasticsearch.index"
] | java.io; java.util; org.apache.lucene; org.elasticsearch.common; org.elasticsearch.index; | 1,281,953 |
@SuppressWarnings("unchecked")
public void testQueryRowCount() throws ApplicationException
{
IvlIntDataType searchObject = new IvlIntDataType();
Collection results = search("gov.nih.nci.cacoresdk.domain.other.datatype.IvlIntDataType",searchObject );
assertNotNull(results);
assertEquals(21,results.siz... | @SuppressWarnings(STR) void function() throws ApplicationException { IvlIntDataType searchObject = new IvlIntDataType(); Collection results = search(STR,searchObject ); assertNotNull(results); assertEquals(21,results.size()); } | /**
* Uses Nested Search Criteria for search
* Verifies that the results are returned
* Verifies size of the result set
*
* @throws ApplicationException
*/ | Uses Nested Search Criteria for search Verifies that the results are returned Verifies size of the result set | testQueryRowCount | {
"repo_name": "NCIP/cacore-sdk",
"path": "sdk-toolkit/iso-example-project/junit/src/test/gov/nih/nci/cacoresdk/domain/other/datatype/IvlIntDataTypeTest.java",
"license": "bsd-3-clause",
"size": 18696
} | [
"gov.nih.nci.cacoresdk.domain.other.datatype.IvlIntDataType",
"gov.nih.nci.system.applicationservice.ApplicationException",
"java.util.Collection"
] | import gov.nih.nci.cacoresdk.domain.other.datatype.IvlIntDataType; import gov.nih.nci.system.applicationservice.ApplicationException; import java.util.Collection; | import gov.nih.nci.cacoresdk.domain.other.datatype.*; import gov.nih.nci.system.applicationservice.*; import java.util.*; | [
"gov.nih.nci",
"java.util"
] | gov.nih.nci; java.util; | 2,553,631 |
protected static Instances getDataDictionaryAsInstances(Document doc)
throws Exception {
// TO-DO: definition of missing values (see below)
ArrayList<Attribute> attInfo = new ArrayList<Attribute>();
NodeList dataDictionary = doc.getElementsByTagName("DataField");
for (int i = 0; i < dataDictiona... | static Instances function(Document doc) throws Exception { ArrayList<Attribute> attInfo = new ArrayList<Attribute>(); NodeList dataDictionary = doc.getElementsByTagName(STR); for (int i = 0; i < dataDictionary.getLength(); i++) { Node dataField = dataDictionary.item(i); if (dataField.getNodeType() == Node.ELEMENT_NODE)... | /**
* Get the data dictionary as an Instances object
*
* @param doc the Document encapsulating the pmml
* @return the data dictionary as an Instances object
* @throws Exception if there are fields that are not continuous, ordinal or
* categorical in the data dictionary
*/ | Get the data dictionary as an Instances object | getDataDictionaryAsInstances | {
"repo_name": "mydzigear/weka.kmeanspp.silhouette_score",
"path": "src/weka/core/pmml/PMMLFactory.java",
"license": "gpl-3.0",
"size": 20765
} | [
"java.util.ArrayList",
"org.w3c.dom.Document",
"org.w3c.dom.Element",
"org.w3c.dom.Node",
"org.w3c.dom.NodeList"
] | import java.util.ArrayList; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; | import java.util.*; import org.w3c.dom.*; | [
"java.util",
"org.w3c.dom"
] | java.util; org.w3c.dom; | 1,932,617 |
public void setRuntimeProperties(Map<String, String> runtimePropertyMap) {
this.runtimePropertyMap = runtimePropertyMap;
} | void function(Map<String, String> runtimePropertyMap) { this.runtimePropertyMap = runtimePropertyMap; } | /**
*
* Set runtime properties.
*
* @param runtimePropertyMap
*/ | Set runtime properties | setRuntimeProperties | {
"repo_name": "capitalone/Hydrograph",
"path": "hydrograph.ui/hydrograph.ui.propertywindow/src/main/java/hydrograph/ui/propertywindow/widgets/customwidgets/runtimeproperty/RuntimePropertyDialog.java",
"license": "apache-2.0",
"size": 21285
} | [
"java.util.Map"
] | import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 1,333,018 |
public void calculateBatchIdAndDateRange() throws KettleTransException {
TransLogTable transLogTable = transMeta.getTransLogTable();
currentDate = new Date();
logDate = new Date();
startDate = Const.MIN_DATE;
endDate = currentDate;
DatabaseMeta logConnection = transLogTable.getDatabaseMeta(... | void function() throws KettleTransException { TransLogTable transLogTable = transMeta.getTransLogTable(); currentDate = new Date(); logDate = new Date(); startDate = Const.MIN_DATE; endDate = currentDate; DatabaseMeta logConnection = transLogTable.getDatabaseMeta(); String logTable = environmentSubstitute( transLogTabl... | /**
* Calculate the batch id and date range for the transformation.
*
* @throws KettleTransException
* if there are any errors during calculation
*/ | Calculate the batch id and date range for the transformation | calculateBatchIdAndDateRange | {
"repo_name": "mdamour1976/pentaho-kettle",
"path": "engine/src/main/java/org/pentaho/di/trans/Trans.java",
"license": "apache-2.0",
"size": 199226
} | [
"java.util.Date",
"org.pentaho.di.core.Const",
"org.pentaho.di.core.database.Database",
"org.pentaho.di.core.database.DatabaseMeta",
"org.pentaho.di.core.exception.KettleException",
"org.pentaho.di.core.exception.KettleTransException",
"org.pentaho.di.core.logging.TransLogTable",
"org.pentaho.di.core.... | import java.util.Date; import org.pentaho.di.core.Const; import org.pentaho.di.core.database.Database; import org.pentaho.di.core.database.DatabaseMeta; import org.pentaho.di.core.exception.KettleException; import org.pentaho.di.core.exception.KettleTransException; import org.pentaho.di.core.logging.TransLogTable; impo... | import java.util.*; import org.pentaho.di.core.*; import org.pentaho.di.core.database.*; import org.pentaho.di.core.exception.*; import org.pentaho.di.core.logging.*; import org.pentaho.di.core.util.*; import org.pentaho.di.i18n.*; | [
"java.util",
"org.pentaho.di"
] | java.util; org.pentaho.di; | 384,252 |
public static List<alluxio.grpc.table.FieldSchema> toProto(List<Column> glueCloumns) {
if (glueCloumns == null) {
return Collections.emptyList();
}
List<alluxio.grpc.table.FieldSchema> list = new ArrayList<>();
for (Column column:glueCloumns) {
alluxio.grpc.table.FieldSchema.Builder builde... | static List<alluxio.grpc.table.FieldSchema> function(List<Column> glueCloumns) { if (glueCloumns == null) { return Collections.emptyList(); } List<alluxio.grpc.table.FieldSchema> list = new ArrayList<>(); for (Column column:glueCloumns) { alluxio.grpc.table.FieldSchema.Builder builder = alluxio.grpc.table.FieldSchema.n... | /**
* Convert the Glue FieldSchema to Alluxio FieldSchema.
*
* @param glueCloumns Glue FiledSchema
* @return list of Alluxio FieldSchema
*/ | Convert the Glue FieldSchema to Alluxio FieldSchema | toProto | {
"repo_name": "EvilMcJerkface/alluxio",
"path": "table/server/underdb/glue/src/main/java/alluxio/table/under/glue/GlueUtils.java",
"license": "apache-2.0",
"size": 15207
} | [
"com.amazonaws.services.glue.model.Column",
"java.util.ArrayList",
"java.util.Collections",
"java.util.List"
] | import com.amazonaws.services.glue.model.Column; import java.util.ArrayList; import java.util.Collections; import java.util.List; | import com.amazonaws.services.glue.model.*; import java.util.*; | [
"com.amazonaws.services",
"java.util"
] | com.amazonaws.services; java.util; | 1,958,723 |
public void setSeriesOutlineStroke(int series, Stroke stroke,
boolean notify) {
this.outlineStrokeList.setStroke(series, stroke);
if (notify) {
fireChangeEvent();
}
}
| void function(int series, Stroke stroke, boolean notify) { this.outlineStrokeList.setStroke(series, stroke); if (notify) { fireChangeEvent(); } } | /**
* Sets the outline stroke for a series and, if requested, sends a
* {@link RendererChangeEvent} to all registered listeners.
*
* @param series the series index.
* @param stroke the stroke (<code>null</code> permitted).
* @param notify notify listeners?
*
* @see #ge... | Sets the outline stroke for a series and, if requested, sends a <code>RendererChangeEvent</code> to all registered listeners | setSeriesOutlineStroke | {
"repo_name": "sebkur/JFreeChart",
"path": "src/main/java/org/jfree/chart/renderer/AbstractRenderer.java",
"license": "lgpl-3.0",
"size": 142687
} | [
"java.awt.Stroke"
] | import java.awt.Stroke; | import java.awt.*; | [
"java.awt"
] | java.awt; | 1,469,473 |
private static ParameterIssuerProviderInterface getBumpedProvider(final ParameterIssuerProviderInterface data) {
if (data instanceof IssuerProviderDiscount) {
final IssuerProviderDiscount discount = ((IssuerProviderDiscount) data);
final MulticurveProviderDiscount multicurveProvider = discount.getMult... | static ParameterIssuerProviderInterface function(final ParameterIssuerProviderInterface data) { if (data instanceof IssuerProviderDiscount) { final IssuerProviderDiscount discount = ((IssuerProviderDiscount) data); final MulticurveProviderDiscount multicurveProvider = discount.getMulticurveProvider(); final IssuerProvi... | /**
* Bumps every curve in a provider. This method will be replaced when the curve providers
* have been refactored.
* @param data The curves
* @return A provider with each curve bumped by +1 bp
*/ | Bumps every curve in a provider. This method will be replaced when the curve providers have been refactored | getBumpedProvider | {
"repo_name": "DevStreet/FinanceAnalytics",
"path": "projects/OG-Analytics/src/main/java/com/opengamma/analytics/financial/interestrate/bond/calculator/BondBillTrsGammaPV01Calculator.java",
"license": "apache-2.0",
"size": 9316
} | [
"com.opengamma.analytics.ShiftType",
"com.opengamma.analytics.financial.instrument.index.IborIndex",
"com.opengamma.analytics.financial.instrument.index.IndexON",
"com.opengamma.analytics.financial.legalentity.LegalEntity",
"com.opengamma.analytics.financial.legalentity.LegalEntityFilter",
"com.opengamma.... | import com.opengamma.analytics.ShiftType; import com.opengamma.analytics.financial.instrument.index.IborIndex; import com.opengamma.analytics.financial.instrument.index.IndexON; import com.opengamma.analytics.financial.legalentity.LegalEntity; import com.opengamma.analytics.financial.legalentity.LegalEntityFilter; impo... | import com.opengamma.analytics.*; import com.opengamma.analytics.financial.instrument.index.*; import com.opengamma.analytics.financial.legalentity.*; import com.opengamma.analytics.financial.model.interestrate.curve.*; import com.opengamma.analytics.financial.provider.description.interestrate.*; import com.opengamma.u... | [
"com.opengamma.analytics",
"com.opengamma.util",
"java.util"
] | com.opengamma.analytics; com.opengamma.util; java.util; | 1,828,903 |
@Override
public CategoryURLGenerator getBaseItemURLGenerator() {
return this.baseItemURLGenerator;
}
| CategoryURLGenerator function() { return this.baseItemURLGenerator; } | /**
* Returns the base item URL generator.
*
* @return The item URL generator.
*
* @see #setBaseItemURLGenerator(CategoryURLGenerator)
*/ | Returns the base item URL generator | getBaseItemURLGenerator | {
"repo_name": "ciaracdb/LOG6302",
"path": "examples/jfreechart/source/org/jfree/chart/renderer/category/AbstractCategoryItemRenderer.java",
"license": "apache-2.0",
"size": 71021
} | [
"org.jfree.chart.urls.CategoryURLGenerator"
] | import org.jfree.chart.urls.CategoryURLGenerator; | import org.jfree.chart.urls.*; | [
"org.jfree.chart"
] | org.jfree.chart; | 2,478,279 |
private File writeShortCut(String target, String shortCutDef)
{
File targetPath = new File(target.substring(0, target.lastIndexOf(File.separatorChar)));
if (!targetPath.exists())
{
targetPath.mkdirs();
this.createdDirectory = targetPath.toString();
}
... | File function(String target, String shortCutDef) { File targetPath = new File(target.substring(0, target.lastIndexOf(File.separatorChar))); if (!targetPath.exists()) { targetPath.mkdirs(); this.createdDirectory = targetPath.toString(); } File targetFileName = new File(target); File backupFile = new File(targetPath + Fi... | /**
* Writes the given Shortcutdefinition to the given Target. Returns the written File.
*
* @param target
* @param shortCutDef
*
* @return the File of the written shortcut.
*/ | Writes the given Shortcutdefinition to the given Target. Returns the written File | writeShortCut | {
"repo_name": "RomRaider/original.mirror",
"path": "installer/IzPack/src/lib/com/izforge/izpack/util/os/Unix_Shortcut.java",
"license": "gpl-2.0",
"size": 33355
} | [
"java.io.File",
"java.io.FileWriter",
"java.io.IOException"
] | import java.io.File; import java.io.FileWriter; import java.io.IOException; | import java.io.*; | [
"java.io"
] | java.io; | 814,058 |
public void assertStartsWith(AssertionInfo info, char[] actual, char[] sequence) {
arrays.assertStartsWith(info, failures, actual, sequence);
} | void function(AssertionInfo info, char[] actual, char[] sequence) { arrays.assertStartsWith(info, failures, actual, sequence); } | /**
* Verifies that the given array starts with the given sequence of values, without any other values between them.
* Similar to <code>{@link #assertContainsSequence(AssertionInfo, char[], char[])}</code>, but it also verifies that
* the first element in the sequence is also the first element of the given arr... | Verifies that the given array starts with the given sequence of values, without any other values between them. Similar to <code><code>#assertContainsSequence(AssertionInfo, char[], char[])</code></code>, but it also verifies that the first element in the sequence is also the first element of the given array | assertStartsWith | {
"repo_name": "yurloc/assertj-core",
"path": "src/main/java/org/assertj/core/internal/CharArrays.java",
"license": "apache-2.0",
"size": 14166
} | [
"org.assertj.core.api.AssertionInfo"
] | import org.assertj.core.api.AssertionInfo; | import org.assertj.core.api.*; | [
"org.assertj.core"
] | org.assertj.core; | 1,680,314 |
protected void sequence_ModelLoad(EObject context, ModelLoad semanticObject) {
if(errorAcceptor != null) {
if(transientValues.isValueTransient(semanticObject, MMDSLPackage.eINSTANCE.getModelLoad_Modelname()) == ValueTransient.YES)
errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObj... | void function(EObject context, ModelLoad semanticObject) { if(errorAcceptor != null) { if(transientValues.isValueTransient(semanticObject, MMDSLPackage.eINSTANCE.getModelLoad_Modelname()) == ValueTransient.YES) errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, MMDSLPackage.eINSTANCE.getM... | /**
* Constraint:
* modelname=[ModelCreate|QualifiedName]
*/ | Constraint: modelname=[ModelCreate|QualifiedName] | sequence_ModelLoad | {
"repo_name": "niksavis/mm-dsl",
"path": "org.xtext.nv.dsl/src-gen/org/xtext/nv/dsl/serializer/MMDSLSemanticSequencer.java",
"license": "epl-1.0",
"size": 190481
} | [
"org.eclipse.emf.ecore.EObject",
"org.eclipse.xtext.serializer.acceptor.SequenceFeeder",
"org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider",
"org.eclipse.xtext.serializer.sequencer.ITransientValueService",
"org.xtext.nv.dsl.mMDSL.MMDSLPackage",
"org.xtext.nv.dsl.mMDSL.ModelLoad"
] | import org.eclipse.emf.ecore.EObject; import org.eclipse.xtext.serializer.acceptor.SequenceFeeder; import org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider; import org.eclipse.xtext.serializer.sequencer.ITransientValueService; import org.xtext.nv.dsl.mMDSL.MMDSLPackage; import org.xtext.nv.dsl.mMDSL.ModelLoa... | import org.eclipse.emf.ecore.*; import org.eclipse.xtext.serializer.acceptor.*; import org.eclipse.xtext.serializer.sequencer.*; import org.xtext.nv.dsl.*; | [
"org.eclipse.emf",
"org.eclipse.xtext",
"org.xtext.nv"
] | org.eclipse.emf; org.eclipse.xtext; org.xtext.nv; | 1,125,880 |
@Override
public List<InsurancesHasPlacesrisks> getInsurancesHasPlacesrisksByInsurancesId(
int id) {
List list = getSessionFactory()
.getCurrentSession()
.createQuery(
"from InsurancesHasPlacesrisks where insurances_idinsurances=?")
.setParameter(0, id).list();
return list;
} | List<InsurancesHasPlacesrisks> function( int id) { List list = getSessionFactory() .getCurrentSession() .createQuery( STR) .setParameter(0, id).list(); return list; } | /**
* Get InsurancesHasPlacesrisks
*
* @param int Id
* @return List - InsurancesHasPlacesrisks list
*/ | Get InsurancesHasPlacesrisks | getInsurancesHasPlacesrisksByInsurancesId | {
"repo_name": "machadolucas/watchout",
"path": "src/main/java/com/riskvis/db/dao/impl/InsurancesHasPlacesrisksDAO.java",
"license": "apache-2.0",
"size": 3391
} | [
"com.riskvis.entity.InsurancesHasPlacesrisks",
"java.util.List"
] | import com.riskvis.entity.InsurancesHasPlacesrisks; import java.util.List; | import com.riskvis.entity.*; import java.util.*; | [
"com.riskvis.entity",
"java.util"
] | com.riskvis.entity; java.util; | 1,680,031 |
public Map<String, List<String>> getChatMetadata(String sessionID) throws XMPPException, NotConnectedException {
ChatMetadata request = new ChatMetadata();
request.setType(IQ.Type.get);
request.setTo(workgroupJID);
request.setSessionID(sessionID);
ChatMetadata response = con... | Map<String, List<String>> function(String sessionID) throws XMPPException, NotConnectedException { ChatMetadata request = new ChatMetadata(); request.setType(IQ.Type.get); request.setTo(workgroupJID); request.setSessionID(sessionID); ChatMetadata response = connection.createPacketCollectorAndSend(request).nextResult();... | /**
* Query for metadata associated with a session id.
*
* @param sessionID the sessionID to query for.
* @return Map a map of all metadata associated with the sessionID.
* @throws XMPPException if an error occurs while getting information from the server.
* @throws NotConnectedException
... | Query for metadata associated with a session id | getChatMetadata | {
"repo_name": "Soo000/SooChat",
"path": "src/org/jivesoftware/smackx/workgroup/agent/AgentSession.java",
"license": "apache-2.0",
"size": 45270
} | [
"java.util.List",
"java.util.Map",
"org.jivesoftware.smack.SmackException",
"org.jivesoftware.smack.XMPPException",
"org.jivesoftware.smackx.workgroup.ext.history.ChatMetadata"
] | import java.util.List; import java.util.Map; import org.jivesoftware.smack.SmackException; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smackx.workgroup.ext.history.ChatMetadata; | import java.util.*; import org.jivesoftware.smack.*; import org.jivesoftware.smackx.workgroup.ext.history.*; | [
"java.util",
"org.jivesoftware.smack",
"org.jivesoftware.smackx"
] | java.util; org.jivesoftware.smack; org.jivesoftware.smackx; | 2,886,335 |
public Student getStudent(String id) {
String[] columns = {DBHelper.ID_FIELD_NAME, DBHelper.NAME_FIELD_NAME,
DBHelper.LASTNAME_FIELD_NAME, DBHelper.PHOTO_FIELD_NAME};
Cursor cursor = db.query(DBHelper.STUDENT_TBL_NAME, columns,
DBHelper.ID_FIELD_NAME + "=" + id, null, null, null, null)... | Student function(String id) { String[] columns = {DBHelper.ID_FIELD_NAME, DBHelper.NAME_FIELD_NAME, DBHelper.LASTNAME_FIELD_NAME, DBHelper.PHOTO_FIELD_NAME}; Cursor cursor = db.query(DBHelper.STUDENT_TBL_NAME, columns, DBHelper.ID_FIELD_NAME + "=" + id, null, null, null, null); Student student = null; if(cursor.moveToF... | /**
* Get student specified by id or null if not exist.
*
* @return The Student if exist.
*/ | Get student specified by id or null if not exist | getStudent | {
"repo_name": "rgmf/LTN",
"path": "src/es/rgmf/ltn/db/DBAdapter.java",
"license": "gpl-3.0",
"size": 69648
} | [
"android.database.Cursor",
"es.rgmf.ltn.model.orm.CheckFieldException",
"es.rgmf.ltn.model.orm.Student"
] | import android.database.Cursor; import es.rgmf.ltn.model.orm.CheckFieldException; import es.rgmf.ltn.model.orm.Student; | import android.database.*; import es.rgmf.ltn.model.orm.*; | [
"android.database",
"es.rgmf.ltn"
] | android.database; es.rgmf.ltn; | 252,624 |
public static boolean equal(final Object a, final Object b, final boolean ignoreCase) {
if (a == b) {
return true;
}
if (a == null || b == null) {
return false;
}
if (ignoreCase) {
if (a instanceof String && b instanceof String) {
... | static boolean function(final Object a, final Object b, final boolean ignoreCase) { if (a == b) { return true; } if (a == null b == null) { return false; } if (ignoreCase) { if (a instanceof String && b instanceof String) { return ((String) a).equalsIgnoreCase((String) b); } } return Objects.deepEquals(a, b); } | /**
* A helper method for comparing objects for equality while handling nulls
*/ | A helper method for comparing objects for equality while handling nulls | equal | {
"repo_name": "trohovsky/camel",
"path": "camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java",
"license": "apache-2.0",
"size": 70972
} | [
"java.util.Objects"
] | import java.util.Objects; | import java.util.*; | [
"java.util"
] | java.util; | 1,326,700 |
private static Object parseScalar(String value, String type) {
if ("String".equals(type)) {
return value;
}
if ("Integer".equals(type)) {
return Integer.parseInt(value);
}
if ("Long".equals(type)) {
return Long.parseLong(value);
}
if ("Double".equals(type)) {
return Double.parseD... | static Object function(String value, String type) { if (STR.equals(type)) { return value; } if (STR.equals(type)) { return Integer.parseInt(value); } if ("Long".equals(type)) { return Long.parseLong(value); } if (STR.equals(type)) { return Double.parseDouble(value); } if ("Byte".equals(type)) { return Byte.parseByte(va... | /**
* Construct the scalar value represented by the string
*
* @param value
* @param type
* @return the scalar value represented by the string
*/ | Construct the scalar value represented by the string | parseScalar | {
"repo_name": "glyn/Gemini-Management",
"path": "org.eclipse.gemini.mgmt/src/org/eclipse/gemini/mgmt/internal/OSGiProperties.java",
"license": "apache-2.0",
"size": 18160
} | [
"java.math.BigDecimal",
"java.math.BigInteger"
] | import java.math.BigDecimal; import java.math.BigInteger; | import java.math.*; | [
"java.math"
] | java.math; | 1,997,213 |
public static OAuthProvider getOAuthProvider(ServletContext context) throws ServletException {
OAuthProvider provider = (OAuthProvider) context.getAttribute(ATTR_OAUTH_PROVIDER);
if(provider != null)
return provider;
String providerClassName = context.getInitParameter(OAuthServlet.PARAM_PROVIDER_CLASS);
... | static OAuthProvider function(ServletContext context) throws ServletException { OAuthProvider provider = (OAuthProvider) context.getAttribute(ATTR_OAUTH_PROVIDER); if(provider != null) return provider; String providerClassName = context.getInitParameter(OAuthServlet.PARAM_PROVIDER_CLASS); if(providerClassName == null) ... | /**
* Loads the OAuthProvider as specified in the Servlet Context parameters, and caches it in the Servlet Context attributes for reuse.
*/ | Loads the OAuthProvider as specified in the Servlet Context parameters, and caches it in the Servlet Context attributes for reuse | getOAuthProvider | {
"repo_name": "soul2zimate/resteasy2",
"path": "security/resteasy-oauth/src/main/java/org/jboss/resteasy/auth/oauth/OAuthUtils.java",
"license": "apache-2.0",
"size": 9154
} | [
"javax.servlet.ServletContext",
"javax.servlet.ServletException",
"org.jboss.resteasy.auth.oauth.i18n.LogMessages",
"org.jboss.resteasy.auth.oauth.i18n.Messages"
] | import javax.servlet.ServletContext; import javax.servlet.ServletException; import org.jboss.resteasy.auth.oauth.i18n.LogMessages; import org.jboss.resteasy.auth.oauth.i18n.Messages; | import javax.servlet.*; import org.jboss.resteasy.auth.oauth.i18n.*; | [
"javax.servlet",
"org.jboss.resteasy"
] | javax.servlet; org.jboss.resteasy; | 1,065,947 |
@Nonnull
T build(@Nonnull Message... messages); | T build(@Nonnull Message... messages); | /**
* Partially builds a new message, setting the specified {@link Message}s to their relative extensions.
*
* @param messages The messages to be added as extensions.
* @return The partially built message.
*/ | Partially builds a new message, setting the specified <code>Message</code>s to their relative extensions | build | {
"repo_name": "rmsy/Protobuf-Packet",
"path": "src/main/java/tc/oc/protobuf/packet/PacketManager.java",
"license": "mit",
"size": 1186
} | [
"com.google.protobuf.Message",
"javax.annotation.Nonnull"
] | import com.google.protobuf.Message; import javax.annotation.Nonnull; | import com.google.protobuf.*; import javax.annotation.*; | [
"com.google.protobuf",
"javax.annotation"
] | com.google.protobuf; javax.annotation; | 2,733,390 |
public static ServiceInfoListDTO getServicesResponsePayloadBuilder(List<ServiceInfoDTO> servicesList) {
ServiceInfoListDTO serviceInfoListDTO = new ServiceInfoListDTO();
serviceInfoListDTO.setCount(servicesList.size());
serviceInfoListDTO.setList(servicesList);
return serviceInfoLi... | static ServiceInfoListDTO function(List<ServiceInfoDTO> servicesList) { ServiceInfoListDTO serviceInfoListDTO = new ServiceInfoListDTO(); serviceInfoListDTO.setCount(servicesList.size()); serviceInfoListDTO.setList(servicesList); return serviceInfoListDTO; } | /**
* Convert list of ServiceInfoDTO objects to ServiceInfoListDTO object
*
* @param servicesList metadata list of services provided in zip
* @return build the ServiceInfoListDTO object
*/ | Convert list of ServiceInfoDTO objects to ServiceInfoListDTO object | getServicesResponsePayloadBuilder | {
"repo_name": "Rajith90/carbon-apimgt",
"path": "components/apimgt/org.wso2.carbon.apimgt.rest.api.service.catalog/src/main/java/org/wso2/carbon/apimgt/rest/api/service/catalog/utils/ServiceEntryMappingUtil.java",
"license": "apache-2.0",
"size": 15016
} | [
"java.util.List",
"org.wso2.carbon.apimgt.rest.api.service.catalog.dto.ServiceInfoDTO",
"org.wso2.carbon.apimgt.rest.api.service.catalog.dto.ServiceInfoListDTO"
] | import java.util.List; import org.wso2.carbon.apimgt.rest.api.service.catalog.dto.ServiceInfoDTO; import org.wso2.carbon.apimgt.rest.api.service.catalog.dto.ServiceInfoListDTO; | import java.util.*; import org.wso2.carbon.apimgt.rest.api.service.catalog.dto.*; | [
"java.util",
"org.wso2.carbon"
] | java.util; org.wso2.carbon; | 1,131,465 |
public static ims.core.resource.place.domain.objects.Clinic extractClinic(ims.domain.ILightweightDomainFactory domainFactory, ims.core.vo.ClinicMinVo valueObject)
{
return extractClinic(domainFactory, valueObject, new HashMap());
}
| static ims.core.resource.place.domain.objects.Clinic function(ims.domain.ILightweightDomainFactory domainFactory, ims.core.vo.ClinicMinVo valueObject) { return extractClinic(domainFactory, valueObject, new HashMap()); } | /**
* Create the domain object from the value object.
* @param domainFactory - used to create existing (persistent) domain objects.
* @param valueObject - extract the domain object fields from this.
*/ | Create the domain object from the value object | extractClinic | {
"repo_name": "FreudianNM/openMAXIMS",
"path": "Source Library/openmaxims_workspace/ValueObjects/src/ims/core/vo/domain/ClinicMinVoAssembler.java",
"license": "agpl-3.0",
"size": 16012
} | [
"java.util.HashMap"
] | import java.util.HashMap; | import java.util.*; | [
"java.util"
] | java.util; | 2,418,047 |
List<ResourceRoot> getResourceRoots(); | List<ResourceRoot> getResourceRoots(); | /**
* Returns all the collected property roots.
*
* @return an <b>unmodifiable</b> list of {@link TagSoupExtractionResult.ResourceRoot}s.
*/ | Returns all the collected property roots | getResourceRoots | {
"repo_name": "lewismc/any23",
"path": "core/src/main/java/org/apache/any23/extractor/TagSoupExtractionResult.java",
"license": "apache-2.0",
"size": 6221
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,658,048 |
@Override
public void onAttach(Activity activity) {
super.onAttach(activity);
try {
mCallbacks = (NavigationDrawerCallbacks) activity;
} catch (ClassCastException e) {
throw new ClassCastException("Activity must implement NavigationDrawerCallbacks.");
}
... | void function(Activity activity) { super.onAttach(activity); try { mCallbacks = (NavigationDrawerCallbacks) activity; } catch (ClassCastException e) { throw new ClassCastException(STR); } } | /**
* Lifecycle Callback where the fragment could Ensure that the host activity implements the communication interface declared by the fragment
* @param activity the host activity within which the fragment is managed
*/ | Lifecycle Callback where the fragment could Ensure that the host activity implements the communication interface declared by the fragment | onAttach | {
"repo_name": "Leyonce/iceteck",
"path": "app/src/main/java/org/apache/taverna/mobile/fragments/NavigationDrawerFragment.java",
"license": "apache-2.0",
"size": 12019
} | [
"android.app.Activity"
] | import android.app.Activity; | import android.app.*; | [
"android.app"
] | android.app; | 1,457,581 |
private Result pObsoleteArrayDesignation(final int yyStart)
throws IOException {
Result yyResult;
int yyBase;
Node yyValue;
ParseError yyError = ParseError.DUMMY;
// Alternative 1.
yyResult = pSymbol(yyStart);
if (yyResult.hasValue("[")) {
final String v$g$1 ... | Result function(final int yyStart) throws IOException { Result yyResult; int yyBase; Node yyValue; ParseError yyError = ParseError.DUMMY; yyResult = pSymbol(yyStart); if (yyResult.hasValue("[")) { final String v$g$1 = "["; yyResult = pJeannieC$ConditionalExpression(yyResult.index); yyError = yyResult.select(yyError); i... | /**
* Parse nonterminal xtc.lang.jeannie.JeannieC.ObsoleteArrayDesignation.
*
* @param yyStart The index.
* @return The result.
* @throws IOException Signals an I/O error.
*/ | Parse nonterminal xtc.lang.jeannie.JeannieC.ObsoleteArrayDesignation | pObsoleteArrayDesignation | {
"repo_name": "wandoulabs/xtc-rats",
"path": "xtc-core/src/main/java/xtc/lang/jeannie/JeannieParser.java",
"license": "lgpl-2.1",
"size": 647687
} | [
"java.io.IOException",
"xtc.parser.ParseError",
"xtc.parser.Result",
"xtc.tree.GNode",
"xtc.tree.Node"
] | import java.io.IOException; import xtc.parser.ParseError; import xtc.parser.Result; import xtc.tree.GNode; import xtc.tree.Node; | import java.io.*; import xtc.parser.*; import xtc.tree.*; | [
"java.io",
"xtc.parser",
"xtc.tree"
] | java.io; xtc.parser; xtc.tree; | 2,001,456 |
public ArrayList<String> getMetricNames() {
return this.metricNames;
} | ArrayList<String> function() { return this.metricNames; } | /**
* Optional. Specifies a comma-separated list of the names of the metrics to
* return. If the names parameter is not specified, then all available
* metrics are returned.
* @return The MetricNames value.
*/ | Optional. Specifies a comma-separated list of the names of the metrics to return. If the names parameter is not specified, then all available metrics are returned | getMetricNames | {
"repo_name": "southworkscom/azure-sdk-for-java",
"path": "service-management/azure-svc-mgmt-websites/src/main/java/com/microsoft/windowsazure/management/websites/models/WebSiteGetHistoricalUsageMetricsParameters.java",
"license": "apache-2.0",
"size": 6246
} | [
"java.util.ArrayList"
] | import java.util.ArrayList; | import java.util.*; | [
"java.util"
] | java.util; | 1,963,548 |
public InputStream openInputStream() {
if (zipFile != null) {
try {
inputStream = zipFile.getInputStream(zipEntry);
return inputStream;
} catch (IOException ioex) {
throw new FindFileException("Unable to get input stream: '" + zipFile.getName()
+ "', entry: '" + zipEntry.getName() ... | InputStream function() { if (zipFile != null) { try { inputStream = zipFile.getInputStream(zipEntry); return inputStream; } catch (IOException ioex) { throw new FindFileException(STR + zipFile.getName() + STR + zipEntry.getName() + "'." , ioex); } } try { inputStream = new FileInputStream(file); return inputStream; } c... | /**
* Opens zip entry or plain file and returns its input stream.
*/ | Opens zip entry or plain file and returns its input stream | openInputStream | {
"repo_name": "Artemish/jodd",
"path": "jodd-core/src/main/java/jodd/io/findfile/ClassFinder.java",
"license": "bsd-3-clause",
"size": 13757
} | [
"java.io.FileInputStream",
"java.io.FileNotFoundException",
"java.io.IOException",
"java.io.InputStream"
] | import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.IOException; import java.io.InputStream; | import java.io.*; | [
"java.io"
] | java.io; | 2,161,392 |
public Observable<ServiceResponse<Page<NetworkInterfaceInner>>> listByResourceGroupSinglePageAsync(final String resourceGroupName) {
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
}
if (this.clie... | Observable<ServiceResponse<Page<NetworkInterfaceInner>>> function(final String resourceGroupName) { if (resourceGroupName == null) { throw new IllegalArgumentException(STR); } if (this.client.subscriptionId() == null) { throw new IllegalArgumentException(STR); } | /**
* Gets all network interfaces in a resource group.
*
ServiceResponse<PageImpl<NetworkInterfaceInner>> * @param resourceGroupName The name of the resource group.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the PagedList<NetworkInterfaceInner> ob... | Gets all network interfaces in a resource group | listByResourceGroupSinglePageAsync | {
"repo_name": "martinsawicki/azure-sdk-for-java",
"path": "azure-mgmt-network/src/main/java/com/microsoft/azure/management/network/implementation/NetworkInterfacesInner.java",
"license": "mit",
"size": 169944
} | [
"com.microsoft.azure.Page",
"com.microsoft.rest.ServiceResponse"
] | import com.microsoft.azure.Page; import com.microsoft.rest.ServiceResponse; | import com.microsoft.azure.*; import com.microsoft.rest.*; | [
"com.microsoft.azure",
"com.microsoft.rest"
] | com.microsoft.azure; com.microsoft.rest; | 1,359,282 |
RRFedNonFedSubawardBudget1010Document rrSubawardBudgetDocument = RRFedNonFedSubawardBudget1010Document.Factory.newInstance();
RRFedNonFedSubawardBudget1010 rrSubawardBudget = RRFedNonFedSubawardBudget1010.Factory.newInstance();
BudgetAttachments budgetAttachments = BudgetAttachments.Factory.newI... | RRFedNonFedSubawardBudget1010Document rrSubawardBudgetDocument = RRFedNonFedSubawardBudget1010Document.Factory.newInstance(); RRFedNonFedSubawardBudget1010 rrSubawardBudget = RRFedNonFedSubawardBudget1010.Factory.newInstance(); BudgetAttachments budgetAttachments = BudgetAttachments.Factory.newInstance(); List<BudgetSu... | /**
*
* This method is to get SubAward Budget details
*
* @return rrSubawardBudgetDocument {@link XmlObject} of type RRFedNonFedSubawardBudgetDocument.
*/ | This method is to get SubAward Budget details | getRRFedNonFedSubawardBudgetDocument | {
"repo_name": "vivantech/kc_fixes",
"path": "src/main/java/org/kuali/kra/s2s/generator/impl/RRFedNonFedSubAwardBudget10_10V1_2Generator.java",
"license": "apache-2.0",
"size": 8935
} | [
"gov.grants.apply.forms.rrFedNonFedBudget10V11.RRFedNonFedBudget10Document",
"gov.grants.apply.forms.rrFedNonFedSubawardBudget1010V12.RRFedNonFedSubawardBudget1010Document",
"java.util.List",
"org.kuali.kra.proposaldevelopment.budget.bo.BudgetSubAwards",
"org.kuali.kra.s2s.util.S2SConstants"
] | import gov.grants.apply.forms.rrFedNonFedBudget10V11.RRFedNonFedBudget10Document; import gov.grants.apply.forms.rrFedNonFedSubawardBudget1010V12.RRFedNonFedSubawardBudget1010Document; import java.util.List; import org.kuali.kra.proposaldevelopment.budget.bo.BudgetSubAwards; import org.kuali.kra.s2s.util.S2SConstants; | import gov.grants.apply.forms.*; import java.util.*; import org.kuali.kra.proposaldevelopment.budget.bo.*; import org.kuali.kra.s2s.util.*; | [
"gov.grants.apply",
"java.util",
"org.kuali.kra"
] | gov.grants.apply; java.util; org.kuali.kra; | 1,498,783 |
private boolean insertImageFromEnclosure(NewsViewHolder holder) {
if (mCursor.getString(FeedFragment.INDEX_ENCLOSURE) != null) {
Picasso.with(mContext).load(mCursor.getString(FeedFragment.INDEX_ENCLOSURE)).fit()
.into(holder.imageView);
return true;
}
... | boolean function(NewsViewHolder holder) { if (mCursor.getString(FeedFragment.INDEX_ENCLOSURE) != null) { Picasso.with(mContext).load(mCursor.getString(FeedFragment.INDEX_ENCLOSURE)).fit() .into(holder.imageView); return true; } return false; } | /**
* Insert the image from the enclosure field in the Cursor. If there is a problem in the XML
* and it returns null, we simply use the default thumbnail.
*
* @param holder the relevant ViewHolder
* @return whether or not the image was successfully found and applied
*/ | Insert the image from the enclosure field in the Cursor. If there is a problem in the XML and it returns null, we simply use the default thumbnail | insertImageFromEnclosure | {
"repo_name": "benway0/Mundo",
"path": "app/src/main/java/com/github/benway0/mundo/adapters/NewsAdapter.java",
"license": "gpl-3.0",
"size": 22194
} | [
"com.github.benway0.mundo.fragments.FeedFragment",
"com.squareup.picasso.Picasso"
] | import com.github.benway0.mundo.fragments.FeedFragment; import com.squareup.picasso.Picasso; | import com.github.benway0.mundo.fragments.*; import com.squareup.picasso.*; | [
"com.github.benway0",
"com.squareup.picasso"
] | com.github.benway0; com.squareup.picasso; | 2,368,760 |
@Generated
@Selector("maxSysExSize")
public native NSNumber maxSysExSize(); | @Selector(STR) native NSNumber function(); | /**
* unsigned long
*/ | unsigned long | maxSysExSize | {
"repo_name": "multi-os-engine/moe-core",
"path": "moe.apple/moe.platform.ios/src/main/java/apple/coremidi/MIDICISession.java",
"license": "apache-2.0",
"size": 11059
} | [
"org.moe.natj.objc.ann.Selector"
] | import org.moe.natj.objc.ann.Selector; | import org.moe.natj.objc.ann.*; | [
"org.moe.natj"
] | org.moe.natj; | 2,704,058 |
public static XMLGregorianCalendar createDateTime(
BigInteger year,
int month,
int day,
int hours,
int minutes,
int seconds,
BigDecimal fractionalSecond,
int timezone) {
return new XMLGregorianCalendarImpl(
year,
... | static XMLGregorianCalendar function( BigInteger year, int month, int day, int hours, int minutes, int seconds, BigDecimal fractionalSecond, int timezone) { return new XMLGregorianCalendarImpl( year, month, day, hours, minutes, seconds, fractionalSecond, timezone); } | /**
* <p>Create a Java representation of XML Schema builtin datatype <code>dateTime</code>.
* All possible fields are specified for this factory method.</p>
*
* @param year represents both high-order eons and low-order year.
* @param month of <code>dateTime</code>
* @param day of <c... | Create a Java representation of XML Schema builtin datatype <code>dateTime</code>. All possible fields are specified for this factory method | createDateTime | {
"repo_name": "machine16/xerces-for-android",
"path": "src/mf/org/apache/xerces/jaxp/datatype/XMLGregorianCalendarImpl.java",
"license": "apache-2.0",
"size": 122701
} | [
"java.math.BigDecimal",
"java.math.BigInteger"
] | import java.math.BigDecimal; import java.math.BigInteger; | import java.math.*; | [
"java.math"
] | java.math; | 506,362 |
public void verify(XmlVTenant xvtn, boolean jaxb) {
verify((XmlVNode)xvtn);
assertEquals(idleTimeout, getIdleTimeout(xvtn));
assertEquals(hardTimeout, getHardTimeout(xvtn));
VBridgeConfigList.verify(vBridges, xvtn.getBridges(), jaxb);
VTerminalConfigList.verify(vTerminals, x... | void function(XmlVTenant xvtn, boolean jaxb) { verify((XmlVNode)xvtn); assertEquals(idleTimeout, getIdleTimeout(xvtn)); assertEquals(hardTimeout, getHardTimeout(xvtn)); VBridgeConfigList.verify(vBridges, xvtn.getBridges(), jaxb); VTerminalConfigList.verify(vTerminals, xvtn.getTerminals(), jaxb); PathMapConfigList.verif... | /**
* Ensure that the given {@link XmlVTenant} instance is identical to
* this instance.
*
* @param xvtn A {@link XmlVTenant} instance.
* @param jaxb {@code true} indicates {@code xvbr} was deserialized from
* XML.
*/ | Ensure that the given <code>XmlVTenant</code> instance is identical to this instance | verify | {
"repo_name": "opendaylight/vtn",
"path": "manager/implementation/src/test/java/org/opendaylight/vtn/manager/internal/vnode/xml/VTenantConfig.java",
"license": "epl-1.0",
"size": 10961
} | [
"org.junit.Assert"
] | import org.junit.Assert; | import org.junit.*; | [
"org.junit"
] | org.junit; | 1,653,994 |
public RemoteDAVClient getClient(); | RemoteDAVClient function(); | /**
* Provides access to the underlying RemoteDAVClient.
* @return The client associated with the current repository connection.
*/ | Provides access to the underlying RemoteDAVClient | getClient | {
"repo_name": "bbrodt/droolsjbpm-tools",
"path": "drools-eclipse/org.guvnor.tools/src/org/guvnor/tools/utils/webdav/IWebDavClient.java",
"license": "apache-2.0",
"size": 5708
} | [
"org.eclipse.webdav.client.RemoteDAVClient"
] | import org.eclipse.webdav.client.RemoteDAVClient; | import org.eclipse.webdav.client.*; | [
"org.eclipse.webdav"
] | org.eclipse.webdav; | 409,169 |
@SuppressWarnings("unchecked")
public static <V> SupplierCache<V> expiring(String name, Supplier<V> supplier,
long duration, TimeUnit timeUnit) {
return new SupplierCache(name,supplier,duration,timeUnit);
}
private SupplierCache(final String name, Supplier<V> supplier,
... | @SuppressWarnings(STR) static <V> SupplierCache<V> function(String name, Supplier<V> supplier, long duration, TimeUnit timeUnit) { return new SupplierCache(name,supplier,duration,timeUnit); } private SupplierCache(final String name, Supplier<V> supplier, long duration, TimeUnit timeUnit) { this.name = name; this.suppli... | /**
* Creates an expiring,caching Supplier,
* if duration = 0 caching will effectively be disabled
* if duration < 0 the cache will never expire
*
* @param <V>
* @param name
* @param supplier
* @param duration
* @param timeUnit
* @return
*/ | Creates an expiring,caching Supplier, if duration = 0 caching will effectively be disabled if duration < 0 the cache will never expire | expiring | {
"repo_name": "rhlabs/louie",
"path": "engine/src/main/java/com/rhythm/louie/cache/SupplierCache.java",
"license": "apache-2.0",
"size": 4568
} | [
"com.google.common.base.Supplier",
"java.util.concurrent.TimeUnit"
] | import com.google.common.base.Supplier; import java.util.concurrent.TimeUnit; | import com.google.common.base.*; import java.util.concurrent.*; | [
"com.google.common",
"java.util"
] | com.google.common; java.util; | 2,084,125 |
public Stroke getDefaultOutlineStroke() {
return this.defaultOutlineStroke;
}
| Stroke function() { return this.defaultOutlineStroke; } | /**
* Returns the default outline stroke.
*
* @return The stroke (never <code>null</code>).
*
* @see #setDefaultOutlineStroke(Stroke)
*/ | Returns the default outline stroke | getDefaultOutlineStroke | {
"repo_name": "greearb/jfreechart-fse-ct",
"path": "src/main/java/org/jfree/chart/renderer/AbstractRenderer.java",
"license": "lgpl-2.1",
"size": 108424
} | [
"java.awt.Stroke"
] | import java.awt.Stroke; | import java.awt.*; | [
"java.awt"
] | java.awt; | 1,973,754 |
protected String build_student_view_submission_confirmation_context(VelocityPortlet portlet, Context context, RunData data,
SessionState state)
{
String contextString = (String) state.getAttribute(STATE_CONTEXT_STRING);
context.put("context", contextString);
String invokedByStatus = (String) state.getAt... | String function(VelocityPortlet portlet, Context context, RunData data, SessionState state) { String contextString = (String) state.getAttribute(STATE_CONTEXT_STRING); context.put(STR, contextString); String invokedByStatus = (String) state.getAttribute(INVOKE); if(invokedByStatus!=null){ if(invokedByStatus.equalsIgnor... | /**
* build the student view of showing an assignment submission confirmation
*/ | build the student view of showing an assignment submission confirmation | build_student_view_submission_confirmation_context | {
"repo_name": "lorenamgUMU/sakai",
"path": "assignment/assignment-tool/tool/src/java/org/sakaiproject/assignment/tool/AssignmentAction.java",
"license": "apache-2.0",
"size": 677150
} | [
"java.util.List",
"org.apache.commons.lang.StringUtils",
"org.sakaiproject.assignment.api.Assignment",
"org.sakaiproject.assignment.api.AssignmentSubmission",
"org.sakaiproject.cheftool.Context",
"org.sakaiproject.cheftool.RunData",
"org.sakaiproject.cheftool.VelocityPortlet",
"org.sakaiproject.compon... | import java.util.List; import org.apache.commons.lang.StringUtils; import org.sakaiproject.assignment.api.Assignment; import org.sakaiproject.assignment.api.AssignmentSubmission; import org.sakaiproject.cheftool.Context; import org.sakaiproject.cheftool.RunData; import org.sakaiproject.cheftool.VelocityPortlet; import ... | import java.util.*; import org.apache.commons.lang.*; import org.sakaiproject.assignment.api.*; import org.sakaiproject.cheftool.*; import org.sakaiproject.component.cover.*; import org.sakaiproject.event.api.*; import org.sakaiproject.site.api.*; import org.sakaiproject.site.cover.*; import org.sakaiproject.user.api.*... | [
"java.util",
"org.apache.commons",
"org.sakaiproject.assignment",
"org.sakaiproject.cheftool",
"org.sakaiproject.component",
"org.sakaiproject.event",
"org.sakaiproject.site",
"org.sakaiproject.user"
] | java.util; org.apache.commons; org.sakaiproject.assignment; org.sakaiproject.cheftool; org.sakaiproject.component; org.sakaiproject.event; org.sakaiproject.site; org.sakaiproject.user; | 868,513 |
void createQueue(SimpleString address, RoutingType routingType, SimpleString queueName) throws ActiveMQException; | void createQueue(SimpleString address, RoutingType routingType, SimpleString queueName) throws ActiveMQException; | /**
* Creates a <em>non-temporary</em> queue <em>non-durable</em> queue.
*
* @param address the queue will be bound to this address
* @param routingType the routing type for this queue, MULTICAST or ANYCAST
* @param queueName the name of the queue
* @throws ActiveMQException in an exception oc... | Creates a non-temporary queue non-durable queue | createQueue | {
"repo_name": "iweiss/activemq-artemis",
"path": "artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/client/ClientSession.java",
"license": "apache-2.0",
"size": 50872
} | [
"org.apache.activemq.artemis.api.core.ActiveMQException",
"org.apache.activemq.artemis.api.core.RoutingType",
"org.apache.activemq.artemis.api.core.SimpleString"
] | import org.apache.activemq.artemis.api.core.ActiveMQException; import org.apache.activemq.artemis.api.core.RoutingType; import org.apache.activemq.artemis.api.core.SimpleString; | import org.apache.activemq.artemis.api.core.*; | [
"org.apache.activemq"
] | org.apache.activemq; | 585,924 |
private void writeTransportHeader(DataOutputStream out)
throws RemoteException
{
try {
// write out transport header
DataOutputStream dataOut =
new DataOutputStream(out);
dataOut.writeInt(TransportConstants.Magic);
dataOut.writeShor... | void function(DataOutputStream out) throws RemoteException { try { DataOutputStream dataOut = new DataOutputStream(out); dataOut.writeInt(TransportConstants.Magic); dataOut.writeShort(TransportConstants.Version); } catch (IOException e) { throw new ConnectIOException( STR, e); } } | /**
* Send transport header over stream.
*/ | Send transport header over stream | writeTransportHeader | {
"repo_name": "JetBrains/jdk8u_jdk",
"path": "src/share/classes/sun/rmi/transport/tcp/TCPChannel.java",
"license": "gpl-2.0",
"size": 19703
} | [
"java.io.DataOutputStream",
"java.io.IOException",
"java.rmi.ConnectIOException",
"java.rmi.RemoteException"
] | import java.io.DataOutputStream; import java.io.IOException; import java.rmi.ConnectIOException; import java.rmi.RemoteException; | import java.io.*; import java.rmi.*; | [
"java.io",
"java.rmi"
] | java.io; java.rmi; | 130,211 |
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/ss7/Sccp.java",
"license": "apache-2.0",
"size": 11300
} | [
"com.tailf.jnc.YangString"
] | import com.tailf.jnc.YangString; | import com.tailf.jnc.*; | [
"com.tailf.jnc"
] | com.tailf.jnc; | 77,361 |
public Value getStaticFieldInternal(Env env, StringValue name)
{
StringValue staticName = _staticFieldNameMap.get(name);
if (staticName != null)
return env.getStaticValue(staticName);
else
return null;
}
//
// Constructors
//
/*
public Value callNew(Env env, Expr []args)
... | Value function(Env env, StringValue name) { StringValue staticName = _staticFieldNameMap.get(name); if (staticName != null) return env.getStaticValue(staticName); else return null; } /* public Value callNew(Env env, Expr []args) { Value object = _classDef.callNew(env, args); if (object != null) return object; object = ... | /**
* For Reflection.
*/ | For Reflection | getStaticFieldInternal | {
"repo_name": "TheApacheCats/quercus",
"path": "com/caucho/quercus/env/QuercusClass.java",
"license": "gpl-2.0",
"size": 68876
} | [
"com.caucho.quercus.expr.Expr",
"com.caucho.quercus.function.AbstractFunction"
] | import com.caucho.quercus.expr.Expr; import com.caucho.quercus.function.AbstractFunction; | import com.caucho.quercus.expr.*; import com.caucho.quercus.function.*; | [
"com.caucho.quercus"
] | com.caucho.quercus; | 2,259,012 |
@Override
public long parse(JHOVE2 jhove2, Source source, Input input)
throws EOFException, IOException, JHOVE2Exception
{
long consumed = super.parse(jhove2, source, input);
long start = ((MeasurableSource) source).getStartingOffset();
this.unshif... | long function(JHOVE2 jhove2, Source source, Input input) throws EOFException, IOException, JHOVE2Exception { long consumed = super.parse(jhove2, source, input); long start = ((MeasurableSource) source).getStartingOffset(); this.unshiftedNote = input.readUnsignedByte(); if (this.unshiftedNote < 0 this.unshiftedNote > 12... | /**
* Parse a WAVE chunk.
*
* @param jhove2
* JHOVE2 framework
* @param source
* WAVE source unit
* @param input WAVE source input
* @return Number of bytes consumed
* @throws EOFException
* If End-of-File is reached readin... | Parse a WAVE chunk | parse | {
"repo_name": "opf-labs/jhove2",
"path": "src/main/java/org/jhove2/module/format/wave/InstrumentChunk.java",
"license": "bsd-2-clause",
"size": 11020
} | [
"java.io.EOFException",
"java.io.IOException",
"org.jhove2.core.JHOVE2Exception",
"org.jhove2.core.Message",
"org.jhove2.core.io.Input",
"org.jhove2.core.source.MeasurableSource",
"org.jhove2.core.source.Source",
"org.jhove2.module.format.Validator"
] | import java.io.EOFException; import java.io.IOException; import org.jhove2.core.JHOVE2Exception; import org.jhove2.core.Message; import org.jhove2.core.io.Input; import org.jhove2.core.source.MeasurableSource; import org.jhove2.core.source.Source; import org.jhove2.module.format.Validator; | import java.io.*; import org.jhove2.core.*; import org.jhove2.core.io.*; import org.jhove2.core.source.*; import org.jhove2.module.format.*; | [
"java.io",
"org.jhove2.core",
"org.jhove2.module"
] | java.io; org.jhove2.core; org.jhove2.module; | 818,549 |
default boolean containsAnyValue (@Nullable final Predicate <? super VALUETYPE> aFilter)
{
return CollectionHelper.containsAny (values (), aFilter);
} | default boolean containsAnyValue (@Nullable final Predicate <? super VALUETYPE> aFilter) { return CollectionHelper.containsAny (values (), aFilter); } | /**
* Check if at least one value matches the passed filter.
*
* @param aFilter
* The filter to be applied. May be <code>null</code>.
* @return <code>true</code> if the map is not empty and contains at least one
* value matching the filter, <code>false</code> otherwise. If no
* ... | Check if at least one value matches the passed filter | containsAnyValue | {
"repo_name": "phax/ph-commons",
"path": "ph-commons/src/main/java/com/helger/commons/collection/impl/ICommonsMap.java",
"license": "apache-2.0",
"size": 25410
} | [
"com.helger.commons.collection.CollectionHelper",
"java.util.function.Predicate",
"javax.annotation.Nullable"
] | import com.helger.commons.collection.CollectionHelper; import java.util.function.Predicate; import javax.annotation.Nullable; | import com.helger.commons.collection.*; import java.util.function.*; import javax.annotation.*; | [
"com.helger.commons",
"java.util",
"javax.annotation"
] | com.helger.commons; java.util; javax.annotation; | 2,832,071 |
long countByType(JpaDistributionSetType type); | long countByType(JpaDistributionSetType type); | /**
* Counts {@link DistributionSet} instances of given type in the repository.
*
* @param type
* to search for
* @return number of found {@link DistributionSet}s
*/ | Counts <code>DistributionSet</code> instances of given type in the repository | countByType | {
"repo_name": "StBurcher/hawkbit",
"path": "hawkbit-repository/hawkbit-repository-jpa/src/main/java/org/eclipse/hawkbit/repository/jpa/DistributionSetRepository.java",
"license": "epl-1.0",
"size": 5618
} | [
"org.eclipse.hawkbit.repository.jpa.model.JpaDistributionSetType"
] | import org.eclipse.hawkbit.repository.jpa.model.JpaDistributionSetType; | import org.eclipse.hawkbit.repository.jpa.model.*; | [
"org.eclipse.hawkbit"
] | org.eclipse.hawkbit; | 2,705,693 |
public Cursor getMessagesContainingCursor(String message, boolean getDeleted, boolean getReplies, int limit){
if(message == null) message = "";
message = Utils.makeTextSafeForSQL(message);
SQLiteDatabase db = getWritableDatabase();
if(db != null) {
String likeQuery ="";... | Cursor function(String message, boolean getDeleted, boolean getReplies, int limit){ if(message == null) message = STRSTR\\s","STR LIKE '%STR%'STR[\n\"]", " "); while(message.charAt(0) == ' '){ message = message.substring(1); } String[] words = message.split("\\s"); for(int i=0; i<words.length; i++){ if(words[i].length(... | /** Return a cursor pointing to messages sorted according to current sort order and deleted state
* @param getDeleted whether or not results should include deleted items
* @param getReplies whether or not results should include items which are replies on other message
* @param limit Maximum number of ite... | Return a cursor pointing to messages sorted according to current sort order and deleted state | getMessagesContainingCursor | {
"repo_name": "casific/murmur",
"path": "app/src/main/java/org/denovogroup/murmur/backend/MessageStore.java",
"license": "apache-2.0",
"size": 50068
} | [
"android.database.Cursor"
] | import android.database.Cursor; | import android.database.*; | [
"android.database"
] | android.database; | 1,176,712 |
public void triangulate() {
double minArea = 1000 * charLength * DOUBLE_PREC;
newFaces.clear();
for (Iterator it = faces.iterator(); it.hasNext();) {
Face face = (Face) it.next();
if (face.mark == Face.VISIBLE) {
face.triangulate(newFaces, minArea);
... | void function() { double minArea = 1000 * charLength * DOUBLE_PREC; newFaces.clear(); for (Iterator it = faces.iterator(); it.hasNext();) { Face face = (Face) it.next(); if (face.mark == Face.VISIBLE) { face.triangulate(newFaces, minArea); } } for (Face face = newFaces.first(); face != null; face = face.next) { faces.a... | /**
* Triangulates any non-triangular hull faces. In some cases, due to
* precision issues, the resulting triangles may be very thin or small, and
* hence appear to be non-convex (this same limitation is present in <a
* href=http://www.qhull.org>qhull</a>).
*/ | Triangulates any non-triangular hull faces. In some cases, due to precision issues, the resulting triangles may be very thin or small, and hence appear to be non-convex (this same limitation is present in qhull) | triangulate | {
"repo_name": "Quickhull3d/quickhull3d",
"path": "src/main/java/com/github/quickhull3d/QuickHull3D.java",
"license": "bsd-2-clause",
"size": 48505
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 1,660,045 |
public void setCounter(Date d, CounterValue value); | void function(Date d, CounterValue value); | /**
* Counter value setter
*/ | Counter value setter | setCounter | {
"repo_name": "xuraylei/floodlight_with_topoguard",
"path": "src/main/java/net/floodlightcontroller/counter/ICounter.java",
"license": "apache-2.0",
"size": 1584
} | [
"java.util.Date"
] | import java.util.Date; | import java.util.*; | [
"java.util"
] | java.util; | 2,719,480 |
public URI getBaseUri() {
return this.baseUri;
}
private SubscriptionCloudCredentials credentials; | URI function() { return this.baseUri; } private SubscriptionCloudCredentials credentials; | /**
* Gets the URI used as the base for all cloud service requests.
* @return The BaseUri value.
*/ | Gets the URI used as the base for all cloud service requests | getBaseUri | {
"repo_name": "manikandan-palaniappan/azure-sdk-for-java",
"path": "management-scheduler/src/main/java/com/microsoft/windowsazure/management/scheduler/CloudServiceManagementClientImpl.java",
"license": "apache-2.0",
"size": 27187
} | [
"com.microsoft.windowsazure.credentials.SubscriptionCloudCredentials"
] | import com.microsoft.windowsazure.credentials.SubscriptionCloudCredentials; | import com.microsoft.windowsazure.credentials.*; | [
"com.microsoft.windowsazure"
] | com.microsoft.windowsazure; | 1,877,307 |
protected void cleanup( TestParameters tParam, PrintWriter log ) {
log.println( " disposing xDrawDoc " );
util.DesktopTools.closeDoc(xDrawDoc);
} | void function( TestParameters tParam, PrintWriter log ) { log.println( STR ); util.DesktopTools.closeDoc(xDrawDoc); } | /**
* in general this method disposes the testenvironment and document
*
* @param tParam class which contains additional test parameters
* @param log class to log the test state and result
*
*
* @see TestParameters
* @see PrintWriter
*
*/ | in general this method disposes the testenvironment and document | cleanup | {
"repo_name": "qt-haiku/LibreOffice",
"path": "qadevOOo/tests/java/mod/_svx/SvxShapeDimensioning.java",
"license": "gpl-3.0",
"size": 5504
} | [
"java.io.PrintWriter"
] | import java.io.PrintWriter; | import java.io.*; | [
"java.io"
] | java.io; | 454,099 |
// Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JLabel PluginsToRunLabel;
private javax.swing.JButton browseButton;
private javax.swing.JButton deselectAllButton;
private javax.swing.JLabel errorLabel;
private javax.swing.ButtonGroup infileTypeButtonGroup;
priva... | javax.swing.JLabel PluginsToRunLabel; private javax.swing.JButton browseButton; private javax.swing.JButton deselectAllButton; private javax.swing.JLabel errorLabel; private javax.swing.ButtonGroup infileTypeButtonGroup; private javax.swing.JScrollPane listsScrollPane; private javax.swing.JLabel pathLabel; private java... | /**
* Get the path of the user selected image.
*
* @return the image path
*/ | Get the path of the user selected image | getImageFilePath | {
"repo_name": "sleuthkit/autopsy",
"path": "Experimental/src/org/sleuthkit/autopsy/experimental/volatilityDSP/MemoryDSInputPanel.java",
"license": "apache-2.0",
"size": 24920
} | [
"javax.swing.JTable"
] | import javax.swing.JTable; | import javax.swing.*; | [
"javax.swing"
] | javax.swing; | 1,671,701 |
public List<ProjectExpectedStudyLink> getAllStudyLinksByStudy(Long studyId);
| List<ProjectExpectedStudyLink> function(Long studyId); | /**
* This method gets a list of projectExpectedStudyLink by a given projectExpectedStudy identifier.
*
* @param studyId is the projectExpectedStudy identifier.
* @return a list of projectExpectedStudyLink objects.
*/ | This method gets a list of projectExpectedStudyLink by a given projectExpectedStudy identifier | getAllStudyLinksByStudy | {
"repo_name": "CCAFS/MARLO",
"path": "marlo-data/src/main/java/org/cgiar/ccafs/marlo/data/manager/ProjectExpectedStudyLinkManager.java",
"license": "gpl-3.0",
"size": 3759
} | [
"java.util.List",
"org.cgiar.ccafs.marlo.data.model.ProjectExpectedStudyLink"
] | import java.util.List; import org.cgiar.ccafs.marlo.data.model.ProjectExpectedStudyLink; | import java.util.*; import org.cgiar.ccafs.marlo.data.model.*; | [
"java.util",
"org.cgiar.ccafs"
] | java.util; org.cgiar.ccafs; | 2,388,329 |
private static void outputValue(PrintWriter out, Object value, int nestLevel) throws IOException
{
if (value == null)
{
out.println(JmxDumpUtil.NULL_VALUE);
}
else if (value.getClass().isArray())
{
int length = Array.getLength(value);
... | static void function(PrintWriter out, Object value, int nestLevel) throws IOException { if (value == null) { out.println(JmxDumpUtil.NULL_VALUE); } else if (value.getClass().isArray()) { int length = Array.getLength(value); if (length == 0) { out.println("[]"); } else { out.println(); indent(out, nestLevel + 1); out.pr... | /**
* Outputs a single value, dealing with nested arrays and CompositeData objects.
*
* @param out
* PrintWriter to write the output to
* @param value
* the value to output
* @param nestLevel
* the nesting level
* @throws IOExceptio... | Outputs a single value, dealing with nested arrays and CompositeData objects | outputValue | {
"repo_name": "daniel-he/community-edition",
"path": "projects/repository/source/java/org/alfresco/repo/management/JmxDumpUtil.java",
"license": "lgpl-3.0",
"size": 14081
} | [
"java.io.IOException",
"java.io.PrintWriter",
"java.lang.reflect.Array",
"javax.management.openmbean.CompositeData"
] | import java.io.IOException; import java.io.PrintWriter; import java.lang.reflect.Array; import javax.management.openmbean.CompositeData; | import java.io.*; import java.lang.reflect.*; import javax.management.openmbean.*; | [
"java.io",
"java.lang",
"javax.management"
] | java.io; java.lang; javax.management; | 1,747,366 |
private JasperPrint fillJasperTemplate( PrintMap printMap, int scaleDenominator )
throws JRException, MalformedURLException {
URL templatePath = null;
try {
String templateName = printMap.getTemplate();
templatePath = getTemplatePath( templa... | JasperPrint function( PrintMap printMap, int scaleDenominator ) throws JRException, MalformedURLException { URL templatePath = null; try { String templateName = printMap.getTemplate(); templatePath = getTemplatePath( templateName, true ); } catch ( IOException e ) { LOG.logError( e.getMessage(), e ); throw new Malforme... | /**
* Open the JasperAPI to process the PrintMap request.
*
* @param printMap
* @param scaleDenominator
* @return JasperPrint
* @throws InconsistentRequestException
* @throws JRException
* @throws MalformedURLException
*/ | Open the JasperAPI to process the PrintMap request | fillJasperTemplate | {
"repo_name": "lat-lon/deegree2-base",
"path": "deegree2-core/src/main/java/org/deegree/ogcwebservices/wmps/PrintMapHandler.java",
"license": "lgpl-2.1",
"size": 53232
} | [
"java.io.IOException",
"java.net.MalformedURLException",
"java.util.HashMap",
"java.util.Map",
"net.sf.jasperreports.engine.JREmptyDataSource",
"net.sf.jasperreports.engine.JRException",
"net.sf.jasperreports.engine.JasperFillManager",
"net.sf.jasperreports.engine.JasperPrint",
"org.deegree.i18n.Mes... | import java.io.IOException; import java.net.MalformedURLException; import java.util.HashMap; import java.util.Map; import net.sf.jasperreports.engine.JREmptyDataSource; import net.sf.jasperreports.engine.JRException; import net.sf.jasperreports.engine.JasperFillManager; import net.sf.jasperreports.engine.JasperPrint; i... | import java.io.*; import java.net.*; import java.util.*; import net.sf.jasperreports.engine.*; import org.deegree.i18n.*; import org.deegree.ogcwebservices.wmps.operation.*; | [
"java.io",
"java.net",
"java.util",
"net.sf.jasperreports",
"org.deegree.i18n",
"org.deegree.ogcwebservices"
] | java.io; java.net; java.util; net.sf.jasperreports; org.deegree.i18n; org.deegree.ogcwebservices; | 1,400,098 |
public AnalogValueCallbackThreshold getAnalogValueCallbackThreshold() throws TimeoutException, NotConnectedException {
ByteBuffer bb = ipcon.createRequestPacket((byte)8, FUNCTION_GET_ANALOG_VALUE_CALLBACK_THRESHOLD, this);
byte[] response = sendRequest(bb.array());
bb = ByteBuffer.wrap(response, 8, response.... | AnalogValueCallbackThreshold function() throws TimeoutException, NotConnectedException { ByteBuffer bb = ipcon.createRequestPacket((byte)8, FUNCTION_GET_ANALOG_VALUE_CALLBACK_THRESHOLD, this); byte[] response = sendRequest(bb.array()); bb = ByteBuffer.wrap(response, 8, response.length - 8); bb.order(ByteOrder.LITTLE_EN... | /**
* Returns the threshold as set by {@link BrickletAnalogIn#setAnalogValueCallbackThreshold(char, int, int)}.
*/ | Returns the threshold as set by <code>BrickletAnalogIn#setAnalogValueCallbackThreshold(char, int, int)</code> | getAnalogValueCallbackThreshold | {
"repo_name": "jaggr2/ch.bfh.fbi.mobiComp.17herz",
"path": "com.tinkerforge/src/com/tinkerforge/BrickletAnalogIn.java",
"license": "apache-2.0",
"size": 23150
} | [
"java.nio.ByteBuffer",
"java.nio.ByteOrder"
] | import java.nio.ByteBuffer; import java.nio.ByteOrder; | import java.nio.*; | [
"java.nio"
] | java.nio; | 2,224,692 |
public String makeDebugString() {
final StringBuilder sb = new StringBuilder();
for (int partitionIndex = 0; partitionIndex < partitions.length; partitionIndex++) {
final String partitionPrefix = "Partition " + partitionIndex + ": ";
final HashPartition hashPartition = partitions[partitionIndex];... | String function() { final StringBuilder sb = new StringBuilder(); for (int partitionIndex = 0; partitionIndex < partitions.length; partitionIndex++) { final String partitionPrefix = STR + partitionIndex + STR; final HashPartition hashPartition = partitions[partitionIndex]; sb.append(partitionPrefix).append(hashPartitio... | /**
* This creates a string that summarizes the memory usage of the operator.
* @return A memory dump string.
*/ | This creates a string that summarizes the memory usage of the operator | makeDebugString | {
"repo_name": "kkhatua/drill",
"path": "exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/join/HashJoinBatch.java",
"license": "apache-2.0",
"size": 61488
} | [
"org.apache.drill.exec.physical.impl.common.HashPartition"
] | import org.apache.drill.exec.physical.impl.common.HashPartition; | import org.apache.drill.exec.physical.impl.common.*; | [
"org.apache.drill"
] | org.apache.drill; | 379,985 |
public OFFlowMod removeEntry(IOFSwitch sw, String name) {
log.debug("removeEntry: switch {}, name {}", sw, name);
OFFlowMod ret = null;
HashMap<String, OFFlowMod> swentries = this.getEntries(sw);
if (swentries.containsKey(name)) {
ret = swentries.get(name)... | OFFlowMod function(IOFSwitch sw, String name) { log.debug(STR, sw, name); OFFlowMod ret = null; HashMap<String, OFFlowMod> swentries = this.getEntries(sw); if (swentries.containsKey(name)) { ret = swentries.get(name); swentries.remove(name); } return ret; } | /**
* Remove a flow-mod entry that has been added previously
* returns the flow-mod that has just been removed
*
* @param sw
* @param name
*/ | Remove a flow-mod entry that has been added previously returns the flow-mod that has just been removed | removeEntry | {
"repo_name": "bigswitch/BeaconMirror",
"path": "net.beaconcontroller.staticflowentry/src/main/java/net/beaconcontroller/staticflowentry/StaticFlowEntryPusher.java",
"license": "apache-2.0",
"size": 21863
} | [
"java.util.HashMap",
"net.beaconcontroller.core.IOFSwitch",
"org.openflow.protocol.OFFlowMod"
] | import java.util.HashMap; import net.beaconcontroller.core.IOFSwitch; import org.openflow.protocol.OFFlowMod; | import java.util.*; import net.beaconcontroller.core.*; import org.openflow.protocol.*; | [
"java.util",
"net.beaconcontroller.core",
"org.openflow.protocol"
] | java.util; net.beaconcontroller.core; org.openflow.protocol; | 2,536,927 |
List<Bundle> getBundlesByURL(String url); | List<Bundle> getBundlesByURL(String url); | /**
* Returns the bundles that match
*
* @param url
* @return
*/ | Returns the bundles that match | getBundlesByURL | {
"repo_name": "soluvas/karaf",
"path": "bundle/core/src/main/java/org/apache/karaf/bundle/core/BundleWatcher.java",
"license": "apache-2.0",
"size": 1316
} | [
"java.util.List",
"org.osgi.framework.Bundle"
] | import java.util.List; import org.osgi.framework.Bundle; | import java.util.*; import org.osgi.framework.*; | [
"java.util",
"org.osgi.framework"
] | java.util; org.osgi.framework; | 2,397,885 |
public long[] processBombings(StatisticRound stats, StatisticEvent event)
{ // init
List<String> playersIds = stats.getPlayersIds();
long result[] = stats.getScores(this);
// processing
if(event.getAction() == StatisticAction.BOMB_PLAYER)
{ int indexActor = playersIds.indexOf(event.getActorId());
... | long[] function(StatisticRound stats, StatisticEvent event) { List<String> playersIds = stats.getPlayersIds(); long result[] = stats.getScores(this); if(event.getAction() == StatisticAction.BOMB_PLAYER) { int indexActor = playersIds.indexOf(event.getActorId()); int indexTarget = playersIds.indexOf(event.getTargetId());... | /**
* Processes the bombed opponents scores for all players in the
* specified round, using the specified event.
*
* @param stats
* Stats object used to get players.
* @param event
* Data used to process the scores.
* @return
* An array containing the scores.
*/ | Processes the bombed opponents scores for all players in the specified round, using the specified event | processBombings | {
"repo_name": "vlabatut/totalboumboum",
"path": "src/org/totalboumboum/statistics/detailed/Score.java",
"license": "gpl-2.0",
"size": 10167
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,513,753 |
public String getName()
{
return this.getCOSDictionary().getNameAsString(COSName.N);
} | String function() { return this.getCOSDictionary().getNameAsString(COSName.N); } | /**
* Returns the property name.
*
* @return the property name
*/ | Returns the property name | getName | {
"repo_name": "myrridin/qz-print",
"path": "pdfbox_1.8.4_qz/src/org/apache/pdfbox/pdmodel/documentinterchange/logicalstructure/PDUserProperty.java",
"license": "lgpl-2.1",
"size": 5311
} | [
"org.apache.pdfbox.cos.COSName"
] | import org.apache.pdfbox.cos.COSName; | import org.apache.pdfbox.cos.*; | [
"org.apache.pdfbox"
] | org.apache.pdfbox; | 2,536,372 |
Properties p = new Properties();
ArrayList<Configurable> l = new ArrayList<Configurable>();
findPieceSlots(l, p);
return p;
} | Properties p = new Properties(); ArrayList<Configurable> l = new ArrayList<Configurable>(); findPieceSlots(l, p); return p; } | /**
* Returns a mapping of GamePiece type to the id of a PieceSlot in the module
* This information is exported from an old module version, then imported into a new module version to update saved games
* @return
*/ | Returns a mapping of GamePiece type to the id of a PieceSlot in the module This information is exported from an old module version, then imported into a new module version to update saved games | getPieceSlotsMap | {
"repo_name": "fifa0329/vassal",
"path": "src/VASSAL/tools/SavedGameUpdater.java",
"license": "lgpl-2.1",
"size": 5279
} | [
"java.util.ArrayList",
"java.util.Properties"
] | import java.util.ArrayList; import java.util.Properties; | import java.util.*; | [
"java.util"
] | java.util; | 2,669,721 |
public void diff_cleanupEfficiency(LinkedList<Diff> diffs) {
if (diffs.isEmpty()) {
return;
}
boolean changes = false;
Stack<Diff> equalities = new Stack<Diff>(); // Stack of equalities.
String lastequality = null; // Always equal to equalities.lastElement().text
ListIterator<Diff> poin... | void function(LinkedList<Diff> diffs) { if (diffs.isEmpty()) { return; } boolean changes = false; Stack<Diff> equalities = new Stack<Diff>(); String lastequality = null; ListIterator<Diff> pointer = diffs.listIterator(); boolean pre_ins = false; boolean pre_del = false; boolean post_ins = false; boolean post_del = fals... | /**
* Reduce the number of edits by eliminating operationally trivial equalities.
* @param diffs LinkedList of Diff objects.
*/ | Reduce the number of edits by eliminating operationally trivial equalities | diff_cleanupEfficiency | {
"repo_name": "HTML5MSc/HTML5ParserComparator",
"path": "Utils/src/com/html5tools/Utils/diff_match_patch.java",
"license": "mit",
"size": 89015
} | [
"java.util.LinkedList",
"java.util.ListIterator",
"java.util.Stack"
] | import java.util.LinkedList; import java.util.ListIterator; import java.util.Stack; | import java.util.*; | [
"java.util"
] | java.util; | 540,578 |
private final static void markCompleted(String inpath, int crawlSize) throws Exception {
synchronized (BulkEmbeddedJsonDownloader.class) {
inpath = inpath.toUpperCase();
FileOutputStream out = new FileOutputStream(LOCK_FILE);
try {
FileLock lock = null;
try {
lock = ou... | final static void function(String inpath, int crawlSize) throws Exception { synchronized (BulkEmbeddedJsonDownloader.class) { inpath = inpath.toUpperCase(); FileOutputStream out = new FileOutputStream(LOCK_FILE); try { FileLock lock = null; try { lock = out.getChannel().lock(); List<String> lines = Files.readLines(COMP... | /**
* Locks the lock-file, then records that this task has been completed
*
* @param inpath
* path of the input file, which should serve as a unique ID for the
* job
* @return true if the job should be undertaken, false if the job should be
* abandoned (on the premise tha... | Locks the lock-file, then records that this task has been completed | markCompleted | {
"repo_name": "budgefeeney/twitter-tools",
"path": "src/main/java/cc/twittertools/scripts/BulkEmbeddedJsonDownloader.java",
"license": "apache-2.0",
"size": 8641
} | [
"com.google.common.base.Charsets",
"com.google.common.base.Joiner",
"com.google.common.io.Files",
"java.io.FileOutputStream",
"java.nio.channels.FileLock",
"java.util.List",
"java.util.concurrent.Callable"
] | import com.google.common.base.Charsets; import com.google.common.base.Joiner; import com.google.common.io.Files; import java.io.FileOutputStream; import java.nio.channels.FileLock; import java.util.List; import java.util.concurrent.Callable; | import com.google.common.base.*; import com.google.common.io.*; import java.io.*; import java.nio.channels.*; import java.util.*; import java.util.concurrent.*; | [
"com.google.common",
"java.io",
"java.nio",
"java.util"
] | com.google.common; java.io; java.nio; java.util; | 449,742 |
public boolean isSetSuccess() {
return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID);
} | boolean function() { return EncodingUtils.testBit(__isset_bitfield, __SUCCESS_ISSET_ID); } | /**
* Returns true if field success is set (has been assigned a value) and
* false otherwise
*/ | Returns true if field success is set (has been assigned a value) and false otherwise | isSetSuccess | {
"repo_name": "f1194361820/helper",
"path": "frameworkex/frameworkex-apache-thrift/src/test/java/com/fjn/helper/frameworkex/apache/thrift/tutorial/Calculator.java",
"license": "gpl-2.0",
"size": 130625
} | [
"org.apache.thrift.EncodingUtils"
] | import org.apache.thrift.EncodingUtils; | import org.apache.thrift.*; | [
"org.apache.thrift"
] | org.apache.thrift; | 2,679,551 |
public List<Patch> patch_fromText(String textline)
throws IllegalArgumentException {
List<Patch> patches = new LinkedList<Patch>();
if (textline.length() == 0) {
return patches;
}
List<String> textList = Arrays.asList(textline.split("\n"));
LinkedList<String> text = new LinkedLi... | List<Patch> function(String textline) throws IllegalArgumentException { List<Patch> patches = new LinkedList<Patch>(); if (textline.length() == 0) { return patches; } List<String> textList = Arrays.asList(textline.split("\n")); LinkedList<String> text = new LinkedList<String>(textList); Patch patch; Pattern patchHeader... | /**
* Parse a textual representation of patches and return a List of Patch
* objects.
* @param textline Text representation of patches.
* @return List of Patch objects.
* @throws IllegalArgumentException If invalid input.
*/ | Parse a textual representation of patches and return a List of Patch objects | patch_fromText | {
"repo_name": "ShengLiu/File-Dependency-Client",
"path": "src/com/projectchanged/client/userInterface/diff_match_patch.java",
"license": "bsd-3-clause",
"size": 89449
} | [
"java.io.UnsupportedEncodingException",
"java.net.URLDecoder",
"java.util.Arrays",
"java.util.LinkedList",
"java.util.List",
"java.util.regex.Matcher",
"java.util.regex.Pattern"
] | import java.io.UnsupportedEncodingException; import java.net.URLDecoder; import java.util.Arrays; import java.util.LinkedList; import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern; | import java.io.*; import java.net.*; import java.util.*; import java.util.regex.*; | [
"java.io",
"java.net",
"java.util"
] | java.io; java.net; java.util; | 2,084,580 |
public static RepositoryFolderAndXml parseRepoFile(File directory,
Collection<String> subDirs,
ModuleFileUnmarshaller unmarshaller) {
File repositoryFile = null;
String repoDir = null;
RepositoryXml repoFile ... | static RepositoryFolderAndXml function(File directory, Collection<String> subDirs, ModuleFileUnmarshaller unmarshaller) { File repositoryFile = null; String repoDir = null; RepositoryXml repoFile = null; if (subDirs.contains(REPOSITORY_FOLDER_NAME)) { repoDir = directory.getAbsolutePath() + File.separator + REPOSITORY_... | /**
* Parses the repository file for a stack/service if exists.
*
* @param directory stack/service base directory
* @param subDirs stack/service directory sub directories
* @param unmarshaller {@link ModuleFileUnmarshaller}, needed to parse repo XML
* @throws AmbariException if unable to parse the rep... | Parses the repository file for a stack/service if exists | parseRepoFile | {
"repo_name": "alexryndin/ambari",
"path": "ambari-server/src/main/java/org/apache/ambari/server/stack/RepoUtil.java",
"license": "apache-2.0",
"size": 8732
} | [
"com.google.common.base.Optional",
"java.io.File",
"java.util.Collection",
"org.apache.ambari.server.state.stack.RepositoryXml"
] | import com.google.common.base.Optional; import java.io.File; import java.util.Collection; import org.apache.ambari.server.state.stack.RepositoryXml; | import com.google.common.base.*; import java.io.*; import java.util.*; import org.apache.ambari.server.state.stack.*; | [
"com.google.common",
"java.io",
"java.util",
"org.apache.ambari"
] | com.google.common; java.io; java.util; org.apache.ambari; | 341,431 |
public void updateUserPermissions(String userName,
Map<String, List<String>> perms);
/**
* List the available permission types.
*
* @deprecated in favour of {@link listAvailablePermissionRoleTypes()} | void function(String userName, Map<String, List<String>> perms); /** * List the available permission types. * * @deprecated in favour of {@link listAvailablePermissionRoleTypes()} | /**
* Update the user permissions - takes the userName, and a map from
* permission type to the list of targets it applies to.
*/ | Update the user permissions - takes the userName, and a map from permission type to the list of targets it applies to | updateUserPermissions | {
"repo_name": "cyberdrcarr/guvnor",
"path": "guvnor-webapp-core/src/main/java/org/drools/guvnor/client/rpc/RepositoryService.java",
"license": "apache-2.0",
"size": 11271
} | [
"java.util.List",
"java.util.Map"
] | import java.util.List; import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 2,666,933 |
@Test
public void whenDelete() {
Tracker tracker = new Tracker();
Item item = new Item("test1", "testDescription", "testdesc", 123L, "Hello World!");
Item item2 = new Item("test2", "testDescription", "testdesc", 123L, "Hello World!");
tracker.add(item);
tracker.add(item2);
tracker.delete(... | void function() { Tracker tracker = new Tracker(); Item item = new Item("test1", STR, STR, 123L, STR); Item item2 = new Item("test2", STR, STR, 123L, STR); tracker.add(item); tracker.add(item2); tracker.delete(item2); assertThat(tracker.findByName(STR).length, is(1)); } | /**
* Test delete(), findByName().
*/ | Test delete(), findByName() | whenDelete | {
"repo_name": "jkulabuha/akulabuhov",
"path": "chapter_002/src/test/java/ru/job4j/tracker/TrackerTest.java",
"license": "apache-2.0",
"size": 1855
} | [
"org.hamcrest.core.Is",
"org.junit.Assert"
] | import org.hamcrest.core.Is; import org.junit.Assert; | import org.hamcrest.core.*; import org.junit.*; | [
"org.hamcrest.core",
"org.junit"
] | org.hamcrest.core; org.junit; | 1,412,555 |
public String getValueFromRequestElements(String sName) {
String sValue = null;
if (getQueryParams() != null) {
final List<String> v = getQueryParams().get(sName);
if (v != null && !v.isEmpty()) sValue = v.iterator().next();
}
if (sValue != null) return sValue... | String function(String sName) { String sValue = null; if (getQueryParams() != null) { final List<String> v = getQueryParams().get(sName); if (v != null && !v.isEmpty()) sValue = v.iterator().next(); } if (sValue != null) return sValue; sValue = getHeaderValue(sName); if (sValue != null) return sValue; sValue = getFormV... | /**
* Checks headers, query string, and form body for a given parameter
*
* @param sName
* @return
*/ | Checks headers, query string, and form body for a given parameter | getValueFromRequestElements | {
"repo_name": "yeungbo/zuul",
"path": "zuul-core/src/main/java/com/netflix/zuul/util/HTTPRequestUtils.java",
"license": "apache-2.0",
"size": 10218
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 300,244 |
public URL getAuthLoginURL() {
try {
return authServerURL.resolve(LOGIN_LOC).toURL();
} catch (MalformedURLException e) {
throw new RuntimeException("This should never happen");
}
}
| URL function() { try { return authServerURL.resolve(LOGIN_LOC).toURL(); } catch (MalformedURLException e) { throw new RuntimeException(STR); } } | /** Returns the full URL used for logging in a user with the KBase
* authorization service.
* @return the auth service login URL.
*/ | Returns the full URL used for logging in a user with the KBase authorization service | getAuthLoginURL | {
"repo_name": "kbase/auth",
"path": "java-libs/src/us/kbase/auth/AuthConfig.java",
"license": "mit",
"size": 9591
} | [
"java.net.MalformedURLException"
] | import java.net.MalformedURLException; | import java.net.*; | [
"java.net"
] | java.net; | 2,817,445 |
byte[] generateDelegatingMethodHandleHolderClassBytes(String className,
MethodType[] methodTypes); | byte[] generateDelegatingMethodHandleHolderClassBytes(String className, MethodType[] methodTypes); | /**
* Returns a {@code byte[]} containing the bytecode for a class implementing
* DelegatingMethodHandles of each {@code MethodType} kind in the
* {@code methodTypes} argument. Used by GenerateJLIClassesPlugin to
* generate such a class during the jlink phase.
*/ | Returns a byte[] containing the bytecode for a class implementing DelegatingMethodHandles of each MethodType kind in the methodTypes argument. Used by GenerateJLIClassesPlugin to generate such a class during the jlink phase | generateDelegatingMethodHandleHolderClassBytes | {
"repo_name": "FauxFaux/jdk9-jdk",
"path": "src/java.base/share/classes/jdk/internal/misc/JavaLangInvokeAccess.java",
"license": "gpl-2.0",
"size": 3287
} | [
"java.lang.invoke.MethodType"
] | import java.lang.invoke.MethodType; | import java.lang.invoke.*; | [
"java.lang"
] | java.lang; | 2,075,856 |
public Integer getAvailableAccountBalanceCount(Map fieldValues, boolean isConsolidated) {
Integer recordCount = null;
if (!isConsolidated) {
recordCount = OJBUtility.getResultSizeFromMap(fieldValues, new AccountBalance()).intValue();
} else {
Iterator recordCountItera... | Integer function(Map fieldValues, boolean isConsolidated) { Integer recordCount = null; if (!isConsolidated) { recordCount = OJBUtility.getResultSizeFromMap(fieldValues, new AccountBalance()).intValue(); } else { Iterator recordCountIterator = accountBalanceDao.findConsolidatedAvailableAccountBalance(fieldValues); List... | /**
* This method gets the number of the available account balances according to input fields and values
*
* @param fieldValues the input fields and values
* @param isConsolidated determine whether the search results are consolidated
* @return the number of the available account balances
... | This method gets the number of the available account balances according to input fields and values | getAvailableAccountBalanceCount | {
"repo_name": "quikkian-ua-devops/will-financials",
"path": "kfs-core/src/main/java/org/kuali/kfs/gl/service/impl/AccountBalanceServiceImpl.java",
"license": "agpl-3.0",
"size": 23823
} | [
"java.util.Iterator",
"java.util.List",
"java.util.Map",
"org.apache.commons.collections.IteratorUtils",
"org.kuali.kfs.gl.OJBUtility",
"org.kuali.kfs.gl.businessobject.AccountBalance"
] | import java.util.Iterator; import java.util.List; import java.util.Map; import org.apache.commons.collections.IteratorUtils; import org.kuali.kfs.gl.OJBUtility; import org.kuali.kfs.gl.businessobject.AccountBalance; | import java.util.*; import org.apache.commons.collections.*; import org.kuali.kfs.gl.*; import org.kuali.kfs.gl.businessobject.*; | [
"java.util",
"org.apache.commons",
"org.kuali.kfs"
] | java.util; org.apache.commons; org.kuali.kfs; | 1,098,206 |
public void setProperties(Map<String, Object> properties)
{
m_properties = properties;
} | void function(Map<String, Object> properties) { m_properties = properties; } | /**
* Set the properties.
* @param strProperties The properties to set.
*/ | Set the properties | setProperties | {
"repo_name": "jbundle/jbundle",
"path": "base/screen/control/servlet/src/main/java/org/jbundle/base/screen/control/servlet/BaseHttpTask.java",
"license": "gpl-3.0",
"size": 41977
} | [
"java.util.Map"
] | import java.util.Map; | import java.util.*; | [
"java.util"
] | java.util; | 1,691,484 |
public static void addMonths(Calendar calendar, int months) {
calendar.add(Calendar.MONTH, months);
} | static void function(Calendar calendar, int months) { calendar.add(Calendar.MONTH, months); } | /**
* Add the given amount of months to the given calendar. The changes are
* reflected in the given calendar.
*
* @param calendar
* The calendar to add the given amount of months to.
* @param months
* The amount of months to be added to the given calendar.
* Negative v... | Add the given amount of months to the given calendar. The changes are reflected in the given calendar | addMonths | {
"repo_name": "masterucm1617/botzzaroni",
"path": "BotzzaroniDev/src/icaro/aplicaciones/informacion/gestionPizzeria/CalendarUtil.java",
"license": "gpl-3.0",
"size": 21074
} | [
"java.util.Calendar"
] | import java.util.Calendar; | import java.util.*; | [
"java.util"
] | java.util; | 2,557,269 |
public void format(String journalId,
NamespaceInfo nsInfo) throws IOException; | void function(String journalId, NamespaceInfo nsInfo) throws IOException; | /**
* Format the underlying storage for the given namespace.
*/ | Format the underlying storage for the given namespace | format | {
"repo_name": "ict-carch/hadoop-plus",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/qjournal/protocol/QJournalProtocol.java",
"license": "apache-2.0",
"size": 5538
} | [
"java.io.IOException",
"org.apache.hadoop.hdfs.server.protocol.NamespaceInfo"
] | import java.io.IOException; import org.apache.hadoop.hdfs.server.protocol.NamespaceInfo; | import java.io.*; import org.apache.hadoop.hdfs.server.protocol.*; | [
"java.io",
"org.apache.hadoop"
] | java.io; org.apache.hadoop; | 233,104 |
public TabBuilder setPreInitializeAction(Callback<Tab> action) {
mPreInitializeAction = action;
return this;
} | TabBuilder function(Callback<Tab> action) { mPreInitializeAction = action; return this; } | /**
* Sets a pre-initialization action to run.
* @param action {@link Callback} object to invoke before {@link #initialize()}.
* @return {@link TabBuilder} creating the Tab.
*/ | Sets a pre-initialization action to run | setPreInitializeAction | {
"repo_name": "ric2b/Vivaldi-browser",
"path": "chromium/chrome/android/java/src/org/chromium/chrome/browser/tab/TabBuilder.java",
"license": "bsd-3-clause",
"size": 8993
} | [
"org.chromium.base.Callback"
] | import org.chromium.base.Callback; | import org.chromium.base.*; | [
"org.chromium.base"
] | org.chromium.base; | 1,779,889 |
public JPanel getContPaneItemFreqDist1() {
if (contPaneItemFreqDist1 == null) {
lblSkew = new JLabel();
lblSkew.setBounds(new Rectangle(15, 75, 95, 20));
lblSkew.setToolTipText("Must be >0");
lblSkew.setText("Skew ( >0 )");
lblMaxFreq1 = new JLabel();
lblMaxFreq1.setBounds(new Rectangle(15... | JPanel function() { if (contPaneItemFreqDist1 == null) { lblSkew = new JLabel(); lblSkew.setBounds(new Rectangle(15, 75, 95, 20)); lblSkew.setToolTipText(STR); lblSkew.setText(STR); lblMaxFreq1 = new JLabel(); lblMaxFreq1.setBounds(new Rectangle(15, 45, 95, 20)); lblMaxFreq1.setToolTipText(STR); lblMaxFreq1.setText(STR... | /**
* This method initializes contPaneItemFreqDist1
*
* @return javax.swing.JPanel
*/ | This method initializes contPaneItemFreqDist1 | getContPaneItemFreqDist1 | {
"repo_name": "emrahcem/profid",
"path": "src/example/popularItems/gui/content/NetworkParamsPanel.java",
"license": "apache-2.0",
"size": 43194
} | [
"java.awt.Dimension",
"java.awt.Rectangle",
"javax.swing.JLabel",
"javax.swing.JPanel"
] | import java.awt.Dimension; import java.awt.Rectangle; import javax.swing.JLabel; import javax.swing.JPanel; | import java.awt.*; import javax.swing.*; | [
"java.awt",
"javax.swing"
] | java.awt; javax.swing; | 779,651 |
public Node getNamedItem( String name ) {
if ( name == null ) {
return null;
}
return get( null, name );
} | Node function( String name ) { if ( name == null ) { return null; } return get( null, name ); } | /**
* <b>DOM</b>: Implements {@link org.w3c.dom.NamedNodeMap#getNamedItem(String)}.
*/ | DOM: Implements <code>org.w3c.dom.NamedNodeMap#getNamedItem(String)</code> | getNamedItem | {
"repo_name": "sflyphotobooks/crp-batik",
"path": "sources/org/apache/batik/dom/AbstractElement.java",
"license": "apache-2.0",
"size": 35349
} | [
"org.w3c.dom.Node"
] | import org.w3c.dom.Node; | import org.w3c.dom.*; | [
"org.w3c.dom"
] | org.w3c.dom; | 1,854,464 |
ItemMeta getItemMeta(Material material);
/**
* Gets material. to use for the icon. {@link org.bukkit.Material} | ItemMeta getItemMeta(Material material); /** * Gets material. to use for the icon. {@link org.bukkit.Material} | /**
* Gets item meta.
*
* @param material the material
* @return the ItemMeta related to the material
*/ | Gets item meta | getItemMeta | {
"repo_name": "SurvivalGamesDevTeam/TheSurvivalGames",
"path": "src/main/java/com/communitysurvivalgames/thesurvivalgames/util/items/interfaces/IMetable.java",
"license": "unlicense",
"size": 732
} | [
"org.bukkit.Material",
"org.bukkit.inventory.meta.ItemMeta"
] | import org.bukkit.Material; import org.bukkit.inventory.meta.ItemMeta; | import org.bukkit.*; import org.bukkit.inventory.meta.*; | [
"org.bukkit",
"org.bukkit.inventory"
] | org.bukkit; org.bukkit.inventory; | 1,273,838 |
@Test
public void service2getPage() {
List<KeyValue> array = new ArrayList<>();
KeyValue key1 = new KeyValue(1, "Foo");
KeyValue key2 = new KeyValue(2, "Bar");
KeyValue key3 = new KeyValue(10, "Baz");
array.add(key1);
array.add(key2);
array.add(key3);
... | void function() { List<KeyValue> array = new ArrayList<>(); KeyValue key1 = new KeyValue(1, "Foo"); KeyValue key2 = new KeyValue(2, "Bar"); KeyValue key3 = new KeyValue(10, "Baz"); array.add(key1); array.add(key2); array.add(key3); KeyValuePage page = new KeyValuePage(array, STR); PagedResponse<KeyValue> response = cre... | /**
* Verifies that we can get a PagedResponse<T> when the user has implemented their own class from {@link
* Page}.
*/ | Verifies that we can get a PagedResponse<T> when the user has implemented their own class from <code>Page</code> | service2getPage | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/core/azure-core-test/src/test/java/com/azure/core/test/implementation/RestProxyWithMockTests.java",
"license": "mit",
"size": 22800
} | [
"com.azure.core.http.rest.PagedResponse",
"java.util.ArrayList",
"java.util.List",
"org.junit.jupiter.api.Assertions"
] | import com.azure.core.http.rest.PagedResponse; import java.util.ArrayList; import java.util.List; import org.junit.jupiter.api.Assertions; | import com.azure.core.http.rest.*; import java.util.*; import org.junit.jupiter.api.*; | [
"com.azure.core",
"java.util",
"org.junit.jupiter"
] | com.azure.core; java.util; org.junit.jupiter; | 844,875 |
List<Invoice> retrieveInvoices(Company company); | List<Invoice> retrieveInvoices(Company company); | /**
* Retrieve ventilated invoices from factorized customers.
*
* @param company
* @return
*/ | Retrieve ventilated invoices from factorized customers | retrieveInvoices | {
"repo_name": "ama-axelor/axelor-business-suite",
"path": "axelor-account/src/main/java/com/axelor/apps/account/service/SubrogationReleaseService.java",
"license": "agpl-3.0",
"size": 2509
} | [
"com.axelor.apps.account.db.Invoice",
"com.axelor.apps.base.db.Company",
"java.util.List"
] | import com.axelor.apps.account.db.Invoice; import com.axelor.apps.base.db.Company; import java.util.List; | import com.axelor.apps.account.db.*; import com.axelor.apps.base.db.*; import java.util.*; | [
"com.axelor.apps",
"java.util"
] | com.axelor.apps; java.util; | 2,582,483 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.