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
private static List<String> createKeysForSmpStatus(String phoneNumber){ List<String> keys = new ArrayList<String>(); keys.add(phoneNumber + MyPrefFiles.PUB_KEY_REQUEST_FORWARDED); keys.add(phoneNumber + MyPrefFiles.PUB_KEY_RECEIVED); keys.add(phoneNumber + MyPrefFiles.SECRET_QUESTION_FORWARDED); keys.add(p...
static List<String> function(String phoneNumber){ List<String> keys = new ArrayList<String>(); keys.add(phoneNumber + MyPrefFiles.PUB_KEY_REQUEST_FORWARDED); keys.add(phoneNumber + MyPrefFiles.PUB_KEY_RECEIVED); keys.add(phoneNumber + MyPrefFiles.SECRET_QUESTION_FORWARDED); keys.add(phoneNumber + MyPrefFiles.HASH_RECEI...
/** * Crea tutte le chiavi del file SMP_STATUS a partire dal numero di telefono dell'altro. * * @param phoneNumber : il numero di telefono dell'altro * @return la lista delle chiavi da usare nel file SMP_STATUS */
Crea tutte le chiavi del file SMP_STATUS a partire dal numero di telefono dell'altro
createKeysForSmpStatus
{ "repo_name": "ClaudioRizzo/WatchDog", "path": "src/it/polimi/dima/watchdog/utilities/MyPrefFiles.java", "license": "gpl-2.0", "size": 29422 }
[ "java.util.ArrayList", "java.util.List" ]
import java.util.ArrayList; import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,912,305
private void fillComboExp() { List<ClipboardItem> items; // Obtain all methods of all Experiments items = Core.getInstance().getClipboard() .getItemsByClass(IExperiment.class); if (!items.isEmpty()) { // Add all the methods to the ComboBox for (ClipboardItem item : items) { // We save the firs...
void function() { List<ClipboardItem> items; items = Core.getInstance().getClipboard() .getItemsByClass(IExperiment.class); if (!items.isEmpty()) { for (ClipboardItem item : items) { if (selectedExp == null) selectedExp = (IExperiment) item.getUserData(); this.comboExp.addItem(item); } } }
/** * Fills the combo with the cliboard Experiments. */
Fills the combo with the cliboard Experiments
fillComboExp
{ "repo_name": "sing-group/BEW", "path": "plugins_src/bew/es/uvigo/ei/sing/bew/view/dialogs/UploadExpDialog.java", "license": "gpl-3.0", "size": 5509 }
[ "es.uvigo.ei.aibench.core.Core", "es.uvigo.ei.aibench.core.clipboard.ClipboardItem", "es.uvigo.ei.sing.bew.model.IExperiment", "java.util.List" ]
import es.uvigo.ei.aibench.core.Core; import es.uvigo.ei.aibench.core.clipboard.ClipboardItem; import es.uvigo.ei.sing.bew.model.IExperiment; import java.util.List;
import es.uvigo.ei.aibench.core.*; import es.uvigo.ei.aibench.core.clipboard.*; import es.uvigo.ei.sing.bew.model.*; import java.util.*;
[ "es.uvigo.ei", "java.util" ]
es.uvigo.ei; java.util;
647,027
public static String unescapeHtml(final String s) { final StringBuilder result = new StringBuilder(s.length()); int ampInd = s.indexOf("&"); int lastEnd = 0; while (ampInd >= 0) { final int nextAmp = s.indexOf("&", ampInd + 1); final int nextSemi = s.indexOf(";", ampInd + 1); if (nextSemi != -1 &...
static String function(final String s) { final StringBuilder result = new StringBuilder(s.length()); int ampInd = s.indexOf("&"); int lastEnd = 0; while (ampInd >= 0) { final int nextAmp = s.indexOf("&", ampInd + 1); final int nextSemi = s.indexOf(";", ampInd + 1); if (nextSemi != -1 && (nextAmp == -1 nextSemi < nextAm...
/** * Turn any HTML escape entities in the string into characters and return the * resulting string. * * @param s * String to be unescaped * @return unescaped String * @since ostermillerutils 1.00.00 */
Turn any HTML escape entities in the string into characters and return the resulting string
unescapeHtml
{ "repo_name": "openfurther/further-open-core", "path": "core/core-api/src/main/java/edu/utah/further/core/api/text/StringUtil.java", "license": "apache-2.0", "size": 82912 }
[ "java.lang.Integer" ]
import java.lang.Integer;
import java.lang.*;
[ "java.lang" ]
java.lang;
2,827,284
protected void fireItemSetChange() { if (itemSetEventListeners != null && !itemSetEventListeners.isEmpty()) { final Container.ItemSetChangeEvent event = new ItemSetChangeEvent( this); final Object[] listeners = itemSetEventListeners.toArray(); for (int...
void function() { if (itemSetEventListeners != null && !itemSetEventListeners.isEmpty()) { final Container.ItemSetChangeEvent event = new ItemSetChangeEvent( this); final Object[] listeners = itemSetEventListeners.toArray(); for (int i = 0; i < listeners.length; i++) { ((Container.ItemSetChangeListener) listeners[i]) ....
/** * Fires the item set change event. */
Fires the item set change event
fireItemSetChange
{ "repo_name": "Peppe/vaadin", "path": "server/src/com/vaadin/ui/AbstractSelect.java", "license": "apache-2.0", "size": 76697 }
[ "com.vaadin.data.Container", "java.io.Serializable", "java.util.EventObject" ]
import com.vaadin.data.Container; import java.io.Serializable; import java.util.EventObject;
import com.vaadin.data.*; import java.io.*; import java.util.*;
[ "com.vaadin.data", "java.io", "java.util" ]
com.vaadin.data; java.io; java.util;
1,790,570
private List<String> cleanForeignKeys() throws SQLException { @SuppressWarnings({"unchecked"}) List<Map<String, String>> constraintNames = jdbcTemplate.queryForList( "SELECT table_name, constraint_name FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS" + ...
List<String> function() throws SQLException { @SuppressWarnings({STR}) List<Map<String, String>> constraintNames = jdbcTemplate.queryForList( STR + STR, name ); List<String> statements = new ArrayList<String>(); for (Map<String, String> row : constraintNames) { String tableName = row.get(STR); String constraintName = r...
/** * Cleans the foreign keys in this schema. * * @return The drop statements. * @throws SQLException when the clean statements could not be generated. */
Cleans the foreign keys in this schema
cleanForeignKeys
{ "repo_name": "nathanvick/flyway", "path": "flyway-core/src/main/java/org/flywaydb/core/internal/dbsupport/sqlserver/SQLServerSchema.java", "license": "apache-2.0", "size": 10668 }
[ "java.sql.SQLException", "java.util.ArrayList", "java.util.List", "java.util.Map" ]
import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import java.util.Map;
import java.sql.*; import java.util.*;
[ "java.sql", "java.util" ]
java.sql; java.util;
119,927
@DELETE @Path("delete/{type}/{entity}") @Produces({MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON}) @Monitored(event = "delete") @Override public APIResult delete( @Context HttpServletRequest request, @Dimension("entityType") @PathParam("type") final String type...
@Path(STR) @Produces({MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON}) @Monitored(event = STR) APIResult function( @Context HttpServletRequest request, @Dimension(STR) @PathParam("type") final String type, @Dimension(STR) @PathParam(STR) final String entityName, @Dimension("colo") @QueryParam("col...
/** * Delete the specified entity. * @param request Servlet Request * @param type Valid options are cluster, feed or process. * @param entityName Name of the entity. * @param ignore colo is ignored * @return Results of the delete operation. */
Delete the specified entity
delete
{ "repo_name": "InMobi/falcon", "path": "prism/src/main/java/org/apache/falcon/resource/proxy/SchedulableEntityManagerProxy.java", "license": "apache-2.0", "size": 33718 }
[ "java.util.HashMap", "java.util.Map", "javax.servlet.http.HttpServletRequest", "javax.ws.rs.Path", "javax.ws.rs.PathParam", "javax.ws.rs.Produces", "javax.ws.rs.QueryParam", "javax.ws.rs.core.Context", "javax.ws.rs.core.MediaType", "org.apache.falcon.FalconException", "org.apache.falcon.FalconWe...
import java.util.HashMap; import java.util.Map; import javax.servlet.http.HttpServletRequest; import javax.ws.rs.Path; import javax.ws.rs.PathParam; import javax.ws.rs.Produces; import javax.ws.rs.QueryParam; import javax.ws.rs.core.Context; import javax.ws.rs.core.MediaType; import org.apache.falcon.FalconException; i...
import java.util.*; import javax.servlet.http.*; import javax.ws.rs.*; import javax.ws.rs.core.*; import org.apache.falcon.*; import org.apache.falcon.entity.*; import org.apache.falcon.monitors.*; import org.apache.falcon.resource.*;
[ "java.util", "javax.servlet", "javax.ws", "org.apache.falcon" ]
java.util; javax.servlet; javax.ws; org.apache.falcon;
2,691,866
@Test public void getResultShouldReturnTheSameNumberIfNotDivisibleByEither3or5() { Assert.assertEquals("1", FizzBuzz.getResult(1)); Assert.assertEquals("2", FizzBuzz.getResult(2)); Assert.assertEquals("4", FizzBuzz.getResult(4)); }
void function() { Assert.assertEquals("1", FizzBuzz.getResult(1)); Assert.assertEquals("2", FizzBuzz.getResult(2)); Assert.assertEquals("4", FizzBuzz.getResult(4)); }
/** * Tests that original number is returned if not divisible by either 3 or 5 */
Tests that original number is returned if not divisible by either 3 or 5
getResultShouldReturnTheSameNumberIfNotDivisibleByEither3or5
{ "repo_name": "marcus-j/katas", "path": "fizzbuzz/src/test/java/de/marcusjanke/katas/fizzbuzz/FizzBuzzTest.java", "license": "apache-2.0", "size": 1405 }
[ "org.junit.Assert" ]
import org.junit.Assert;
import org.junit.*;
[ "org.junit" ]
org.junit;
1,983,671
public T lt(Object val) { return _withComparisonOperator(ComparisonOperator.LT)._withValues(val); }
T function(Object val) { return _withComparisonOperator(ComparisonOperator.LT)._withValues(val); }
/** * Creates and returns a condition of the range key being less than the * given value. */
Creates and returns a condition of the range key being less than the given value
lt
{ "repo_name": "jentfoo/aws-sdk-java", "path": "aws-java-sdk-dynamodb/src/main/java/com/amazonaws/services/dynamodbv2/document/internal/Filter.java", "license": "apache-2.0", "size": 4494 }
[ "com.amazonaws.services.dynamodbv2.model.ComparisonOperator" ]
import com.amazonaws.services.dynamodbv2.model.ComparisonOperator;
import com.amazonaws.services.dynamodbv2.model.*;
[ "com.amazonaws.services" ]
com.amazonaws.services;
428,936
public static String toString(String str, String name0, @Nullable Object val0, boolean sens0, String name1, @Nullable Object val1, boolean sens1, String name2, @Nullable Object val2, boolean sens2, String name3, @Nullable Object val3, boolean sens3, String name4, @Nullable Ob...
static String function(String str, String name0, @Nullable Object val0, boolean sens0, String name1, @Nullable Object val1, boolean sens1, String name2, @Nullable Object val2, boolean sens2, String name3, @Nullable Object val3, boolean sens3, String name4, @Nullable Object val4, boolean sens4) { assert name0 != null; a...
/** * Produces uniformed output of string with context properties * * @param str Output prefix or {@code null} if empty. * @param name0 Property name. * @param val0 Property value. * @param sens0 Property sensitive flag. * @param name1 Property name. * @param val1 Property value....
Produces uniformed output of string with context properties
toString
{ "repo_name": "andrey-kuznetsov/ignite", "path": "modules/core/src/main/java/org/apache/ignite/internal/util/tostring/GridToStringBuilder.java", "license": "apache-2.0", "size": 65062 }
[ "org.jetbrains.annotations.Nullable" ]
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.*;
[ "org.jetbrains.annotations" ]
org.jetbrains.annotations;
2,257,351
public void beginHandshake() { Preconditions.checkState(state instanceof InitState, "must be in InitState"); if (this.featuresReply.getNTables() > 1) { log.debug("Have {} table(s) for switch {}", this.featuresReply.getNTables(), getSwitchInfoString()); } if (this.featuresReply.getVersion().compareT...
void function() { Preconditions.checkState(state instanceof InitState, STR); if (this.featuresReply.getNTables() > 1) { log.debug(STR, this.featuresReply.getNTables(), getSwitchInfoString()); } if (this.featuresReply.getVersion().compareTo(OFVersion.OF_13) < 0) { setState(new WaitConfigReplyState()); } else { setState(...
/** * This begins the switch handshake. We start where the OFChannelHandler * left off, right after receiving the OFFeaturesReply. */
This begins the switch handshake. We start where the OFChannelHandler left off, right after receiving the OFFeaturesReply
beginHandshake
{ "repo_name": "netgroup/floodlight", "path": "src/main/java/net/floodlightcontroller/core/internal/OFSwitchHandshakeHandler.java", "license": "apache-2.0", "size": 62338 }
[ "com.google.common.base.Preconditions", "org.projectfloodlight.openflow.protocol.OFVersion" ]
import com.google.common.base.Preconditions; import org.projectfloodlight.openflow.protocol.OFVersion;
import com.google.common.base.*; import org.projectfloodlight.openflow.protocol.*;
[ "com.google.common", "org.projectfloodlight.openflow" ]
com.google.common; org.projectfloodlight.openflow;
384,586
@Override public void readFromTask(Task task) { this.model = task; if (initialized) { readFromTaskOnInitialize(); } }
void function(Task task) { this.model = task; if (initialized) { readFromTaskOnInitialize(); } }
/** * Read data from model to update the control set */
Read data from model to update the control set
readFromTask
{ "repo_name": "xVir/tasks", "path": "src/main/java/com/todoroo/astrid/helper/TaskEditControlSetBase.java", "license": "gpl-3.0", "size": 3756 }
[ "com.todoroo.astrid.data.Task" ]
import com.todoroo.astrid.data.Task;
import com.todoroo.astrid.data.*;
[ "com.todoroo.astrid" ]
com.todoroo.astrid;
2,441,665
public byte[] getGamma(byte[] nonce) throws PoloException { byte[] alphaBytes = getAlpha(nonce); assert(alphaBytes.length >= nonce.length); byte[] result = new byte[nonce.length * 2]; System.arraycopy(alphaBytes, 0, result, 0, nonce.length); System.arraycopy(nonce, 0, resul...
byte[] function(byte[] nonce) throws PoloException { byte[] alphaBytes = getAlpha(nonce); assert(alphaBytes.length >= nonce.length); byte[] result = new byte[nonce.length * 2]; System.arraycopy(alphaBytes, 0, result, 0, nonce.length); System.arraycopy(nonce, 0, result, nonce.length, nonce.length); return result; }
/** * Returns the gamma value to be used in pairing, i.e. the concatenation * of the alpha value with the nonce. * <p> * The returned value with be twice the byte length of the nonce. * * @throws PoloException if the secret could not be computed */
Returns the gamma value to be used in pairing, i.e. the concatenation of the alpha value with the nonce. The returned value with be twice the byte length of the nonce
getGamma
{ "repo_name": "s20121035/rk3288_android5.1_repo", "path": "external/google-tv-pairing-protocol/java/src/com/google/polo/pairing/PoloChallengeResponse.java", "license": "gpl-3.0", "size": 7957 }
[ "com.google.polo.exception.PoloException" ]
import com.google.polo.exception.PoloException;
import com.google.polo.exception.*;
[ "com.google.polo" ]
com.google.polo;
2,314,424
// TODO(bazel-team): This is inconsistent with the documentation on CppModel. public CcLibraryHelper addSources(Iterable<Pair<Artifact, Label>> sources) { Iterables.addAll(this.sources, sources); return this; }
CcLibraryHelper function(Iterable<Pair<Artifact, Label>> sources) { Iterables.addAll(this.sources, sources); return this; }
/** * Add the corresponding files as source files. These may also be header files, in which case * they will not be compiled, but also not made visible as includes to dependent rules. */
Add the corresponding files as source files. These may also be header files, in which case they will not be compiled, but also not made visible as includes to dependent rules
addSources
{ "repo_name": "dinowernli/bazel", "path": "src/main/java/com/google/devtools/build/lib/rules/cpp/CcLibraryHelper.java", "license": "apache-2.0", "size": 41137 }
[ "com.google.common.collect.Iterables", "com.google.devtools.build.lib.actions.Artifact", "com.google.devtools.build.lib.cmdline.Label", "com.google.devtools.build.lib.util.Pair" ]
import com.google.common.collect.Iterables; import com.google.devtools.build.lib.actions.Artifact; import com.google.devtools.build.lib.cmdline.Label; import com.google.devtools.build.lib.util.Pair;
import com.google.common.collect.*; import com.google.devtools.build.lib.actions.*; import com.google.devtools.build.lib.cmdline.*; import com.google.devtools.build.lib.util.*;
[ "com.google.common", "com.google.devtools" ]
com.google.common; com.google.devtools;
1,678,023
public Optional<ApplePackageConfig> getPackageConfigForPlatform(ApplePlatform platform) { String command = delegate.getValue(APPLE_SECTION, platform.getName() + "_package_command").orElse(""); String extension = delegate.getValue(APPLE_SECTION, platform.getName() + "_package_extension").orElse...
Optional<ApplePackageConfig> function(ApplePlatform platform) { String command = delegate.getValue(APPLE_SECTION, platform.getName() + STR).orElse(STR_package_extensionSTRSTRConfig option %s and %s should be both specified, or be both omitted.STRapple." + platform.getName() + STR, "apple.STR_package_extension"); } else...
/** * Returns the custom packager command specified in the config, if defined. * * <p>This is translated into the config value of {@code apple.PLATFORMNAME_packager_command}. * * @param platform the platform to query. * @return the custom packager command specified in the config, if defined. */
Returns the custom packager command specified in the config, if defined. This is translated into the config value of apple.PLATFORMNAME_packager_command
getPackageConfigForPlatform
{ "repo_name": "facebook/buck", "path": "src/com/facebook/buck/apple/AppleConfig.java", "license": "apache-2.0", "size": 20177 }
[ "com.facebook.buck.apple.toolchain.ApplePlatform", "java.util.Optional" ]
import com.facebook.buck.apple.toolchain.ApplePlatform; import java.util.Optional;
import com.facebook.buck.apple.toolchain.*; import java.util.*;
[ "com.facebook.buck", "java.util" ]
com.facebook.buck; java.util;
2,403,690
public long[] getItemTableIDsByQuery(Long baseId, String queryString, Date start, Date end) { try { String searchString = ""; if (start == null || end == null) { if (queryString.trim().length() > 0) { searchString = "(BaseUid=="+baseId...
long[] function(Long baseId, String queryString, Date start, Date end) { try { String searchString = STR(BaseUid==STR)STR(BaseUid==STR)STR(DateTime>=STR) & (DateTime<=STR)STRError retrieving import list from %s to %s.", start.toString(), end.toString()); log.error(s, e); } return null; }
/** * Return an array of ids based on query and date * @param uid * @param queryString * @param from * @param to * @return */
Return an array of ids based on query and date
getItemTableIDsByQuery
{ "repo_name": "rleigh-dundee/openmicroscopy", "path": "components/tools/OmeroImporter/src/ome/formats/importer/gui/HistoryTableStore.java", "license": "gpl-2.0", "size": 33092 }
[ "java.util.Date" ]
import java.util.Date;
import java.util.*;
[ "java.util" ]
java.util;
2,915,730
private UsedSetting getSampleUsedSetting() { return new UsedSetting("", // prefix Token.DIGIT, // tokentype "d", // charmap 1, // rootlength true, //sans vowels 5); // amount }
UsedSetting function() { return new UsedSetting(STRd", 1, true, 5); }
/** * Return a sample UsedSetting * * @return */
Return a sample UsedSetting
getSampleUsedSetting
{ "repo_name": "Khyzad/PID-webservice", "path": "Minter/src/test/java/com/hida/service/MinterServiceTest.java", "license": "apache-2.0", "size": 18393 }
[ "com.hida.model.UsedSetting" ]
import com.hida.model.UsedSetting;
import com.hida.model.*;
[ "com.hida.model" ]
com.hida.model;
286,472
InputStream getSnapshotInputStream() throws TransactionCouldNotTakeSnapshotException;
InputStream getSnapshotInputStream() throws TransactionCouldNotTakeSnapshotException;
/** * Retrieves the state of the transaction manager and send it as a stream. The snapshot will not be persisted. * @return an input stream containing an encoded snapshot of the transaction manager */
Retrieves the state of the transaction manager and send it as a stream. The snapshot will not be persisted
getSnapshotInputStream
{ "repo_name": "cdapio/tephra", "path": "tephra-core/src/main/java/co/cask/tephra/TransactionSystemClient.java", "license": "apache-2.0", "size": 5792 }
[ "java.io.InputStream" ]
import java.io.InputStream;
import java.io.*;
[ "java.io" ]
java.io;
1,154,439
private BaseCalendar findBaseCalendar(String name) { List<BaseCalendar> baseCalendars = baseCalendarDAO.findByName(name); BaseCalendar calendar = null; for (BaseCalendar baseCalendar : baseCalendars) { if ( baseCalendar.getName().equals(name) ) { calendar = ba...
BaseCalendar function(String name) { List<BaseCalendar> baseCalendars = baseCalendarDAO.findByName(name); BaseCalendar calendar = null; for (BaseCalendar baseCalendar : baseCalendars) { if ( baseCalendar.getName().equals(name) ) { calendar = baseCalendar; return calendar; } } throw new ValidationException(_(STR)); }
/** * Private method. * * Return the {@link BaseCalendar} with the same name as the string given. * * @param name * String with the name that we want to find. * @return BaseCalendar Calendar. */
Private method. Return the <code>BaseCalendar</code> with the same name as the string given
findBaseCalendar
{ "repo_name": "skylow95/libreplan", "path": "libreplan-webapp/src/main/java/org/libreplan/importers/OrderImporterMPXJ.java", "license": "agpl-3.0", "size": 19339 }
[ "java.util.List", "org.libreplan.business.calendars.entities.BaseCalendar", "org.libreplan.business.common.exceptions.ValidationException" ]
import java.util.List; import org.libreplan.business.calendars.entities.BaseCalendar; import org.libreplan.business.common.exceptions.ValidationException;
import java.util.*; import org.libreplan.business.calendars.entities.*; import org.libreplan.business.common.exceptions.*;
[ "java.util", "org.libreplan.business" ]
java.util; org.libreplan.business;
2,492,783
public static byte[][] getMaksedKeyForSorting(List<QueryDimension> orderDimensions, KeyGenerator generator, int[][] maskedByteRangeForSorting, int[] maskedRanges) throws QueryExecutionException { byte[][] maskedKey = new byte[orderDimensions.size()][]; byte[] mdKey = null; long[] key = null; ...
static byte[][] function(List<QueryDimension> orderDimensions, KeyGenerator generator, int[][] maskedByteRangeForSorting, int[] maskedRanges) throws QueryExecutionException { byte[][] maskedKey = new byte[orderDimensions.size()][]; byte[] mdKey = null; long[] key = null; byte[] maskedMdKey = null; try { if (null != mas...
/** * Below method will be used to get the masked key for sorting * * @param orderDimensions query dimension * @param generator key generator * @param maskedByteRangeForSorting masked byte range for sorting * @param maskedRanges masked range * @return masked b...
Below method will be used to get the masked key for sorting
getMaksedKeyForSorting
{ "repo_name": "foryou2030/incubator-carbondata", "path": "core/src/main/java/org/apache/carbondata/scan/executor/util/QueryUtil.java", "license": "apache-2.0", "size": 41271 }
[ "java.util.List", "org.apache.carbondata.core.keygenerator.KeyGenException", "org.apache.carbondata.core.keygenerator.KeyGenerator", "org.apache.carbondata.scan.executor.exception.QueryExecutionException", "org.apache.carbondata.scan.model.QueryDimension" ]
import java.util.List; import org.apache.carbondata.core.keygenerator.KeyGenException; import org.apache.carbondata.core.keygenerator.KeyGenerator; import org.apache.carbondata.scan.executor.exception.QueryExecutionException; import org.apache.carbondata.scan.model.QueryDimension;
import java.util.*; import org.apache.carbondata.core.keygenerator.*; import org.apache.carbondata.scan.executor.exception.*; import org.apache.carbondata.scan.model.*;
[ "java.util", "org.apache.carbondata" ]
java.util; org.apache.carbondata;
1,104,364
public void surfaceDestroyed(SurfaceHolder arg0) { Elog.v(TAG, "enter surfaceDestroyed "); if (mProgresDlgExist) { mProgressDlgHdl.sendEmptyMessage(FULL_SCAN_COMPLET); // mProgressDlgExists = false; // return; } stopPreview(); closeCamera()...
void function(SurfaceHolder arg0) { Elog.v(TAG, STR); if (mProgresDlgExist) { mProgressDlgHdl.sendEmptyMessage(FULL_SCAN_COMPLET); } stopPreview(); closeCamera(); Elog.v(TAG, STR); }
/** * used to handle when the surface destoryed * * @param arg0 * : surface holder, used to handle surface */
used to handle when the surface destoryed
surfaceDestroyed
{ "repo_name": "rex-xxx/mt6572_x201", "path": "mediatek/packages/apps/EngineerMode/src/com/mediatek/engineermode/camera/CameraPreview.java", "license": "gpl-2.0", "size": 60957 }
[ "android.view.SurfaceHolder", "com.mediatek.engineermode.Elog" ]
import android.view.SurfaceHolder; import com.mediatek.engineermode.Elog;
import android.view.*; import com.mediatek.engineermode.*;
[ "android.view", "com.mediatek.engineermode" ]
android.view; com.mediatek.engineermode;
2,822,186
synchronized public ByteBuffer sendVendorRequestIN(final byte request, final short value, final short index, final int dataLength) throws HardwareInterfaceException { if (dataLength == 0) { throw new HardwareInterfaceException("Unable to send vendor IN request with dataLength of zero!"); } if (!isOpen())...
synchronized ByteBuffer function(final byte request, final short value, final short index, final int dataLength) throws HardwareInterfaceException { if (dataLength == 0) { throw new HardwareInterfaceException(STR); } if (!isOpen()) { open(); } final ByteBuffer dataBuffer = BufferUtils.allocateByteBuffer(dataLength); fi...
/** * Sends a vendor request to receive (IN direction) data. This is a blocking * method. * * @param request * the vendor request byte, identifies the request on the device * @param value * the value of the request (bValue USB field) * @param index * the "index" of the...
Sends a vendor request to receive (IN direction) data. This is a blocking method
sendVendorRequestIN
{ "repo_name": "viktorbahr/jaer", "path": "src/net/sf/jaer/hardwareinterface/usb/cypressfx2libusb/CypressFX2.java", "license": "lgpl-2.1", "size": 65752 }
[ "java.nio.ByteBuffer", "net.sf.jaer.hardwareinterface.HardwareInterfaceException", "org.usb4java.BufferUtils", "org.usb4java.LibUsb" ]
import java.nio.ByteBuffer; import net.sf.jaer.hardwareinterface.HardwareInterfaceException; import org.usb4java.BufferUtils; import org.usb4java.LibUsb;
import java.nio.*; import net.sf.jaer.hardwareinterface.*; import org.usb4java.*;
[ "java.nio", "net.sf.jaer", "org.usb4java" ]
java.nio; net.sf.jaer; org.usb4java;
268,513
protected void buildAnswerMaps() { answersMap = new HashMap<String, List<EvalAnswer>>(); responseAnswersMap = new HashMap<Long, Map<String,EvalAnswer>>(); for (EvalAnswer answer : answers) { // decode the stored answers into the int array answer.multipleAnswers = Eval...
void function() { answersMap = new HashMap<String, List<EvalAnswer>>(); responseAnswersMap = new HashMap<Long, Map<String,EvalAnswer>>(); for (EvalAnswer answer : answers) { answer.multipleAnswers = EvalUtils.decodeMultipleAnswers(answer.getMultiAnswerCode()); EvalUtils.decodeAnswerNA(answer); String key = TemplateItem...
/** * Builds both answer maps using the answers data (if there is any), * the order of the answers inside the lists is effectively random */
Builds both answer maps using the answers data (if there is any), the order of the answers inside the lists is effectively random
buildAnswerMaps
{ "repo_name": "buckett/evaluation", "path": "api/src/java/org/sakaiproject/evaluation/utils/TemplateItemDataList.java", "license": "apache-2.0", "size": 54050 }
[ "java.util.ArrayList", "java.util.HashMap", "java.util.List", "java.util.Map", "org.sakaiproject.evaluation.model.EvalAnswer", "org.sakaiproject.evaluation.model.EvalResponse" ]
import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import org.sakaiproject.evaluation.model.EvalAnswer; import org.sakaiproject.evaluation.model.EvalResponse;
import java.util.*; import org.sakaiproject.evaluation.model.*;
[ "java.util", "org.sakaiproject.evaluation" ]
java.util; org.sakaiproject.evaluation;
1,197,196
public void testQuery() throws Exception { PersistenceManager pm = pmf.getPersistenceManager(); Transaction tx = pm.currentTransaction(); try { tx.begin(); pm.makePersistent(getOneObject()); pm.makePersistent(getOneObject()); p...
void function() throws Exception { PersistenceManager pm = pmf.getPersistenceManager(); Transaction tx = pm.currentTransaction(); try { tx.begin(); pm.makePersistent(getOneObject()); pm.makePersistent(getOneObject()); pm.makePersistent(getOneObject()); SqlTimeHolder holder = new SqlTimeHolder(); holder.setKey(generateT...
/** * Test for querying of time fields. */
Test for querying of time fields
testQuery
{ "repo_name": "hopecee/texsts", "path": "jdo/general/src/test/org/datanucleus/tests/types/SqlTimeTest.java", "license": "apache-2.0", "size": 8479 }
[ "java.util.Collection", "javax.jdo.PersistenceManager", "javax.jdo.Query", "javax.jdo.Transaction", "org.jpox.samples.types.sqltime.SqlTimeHolder" ]
import java.util.Collection; import javax.jdo.PersistenceManager; import javax.jdo.Query; import javax.jdo.Transaction; import org.jpox.samples.types.sqltime.SqlTimeHolder;
import java.util.*; import javax.jdo.*; import org.jpox.samples.types.sqltime.*;
[ "java.util", "javax.jdo", "org.jpox.samples" ]
java.util; javax.jdo; org.jpox.samples;
530,434
public FilenameFilter getFilenameFilter();
FilenameFilter function();
/** * Returns the <code>FilenameFilter</code> that matches filenames to be associated with this archive format. * * @return the <code>FilenameFilter</code> that matches filenames to be associated with this archive format */
Returns the <code>FilenameFilter</code> that matches filenames to be associated with this archive format
getFilenameFilter
{ "repo_name": "jorgevasquezp/mucommander", "path": "src/main/com/mucommander/commons/file/ArchiveFormatProvider.java", "license": "gpl-3.0", "size": 2162 }
[ "com.mucommander.commons.file.filter.FilenameFilter" ]
import com.mucommander.commons.file.filter.FilenameFilter;
import com.mucommander.commons.file.filter.*;
[ "com.mucommander.commons" ]
com.mucommander.commons;
1,797,567
private ResultSet getExportedKeysODBC( String catalog, String schema, String table) throws SQLException { CallableStatement cs = prepareCall("CALL SYSIBM.SQLFOREIGNKEYS(" + "?, ?, ?, null, null, null, 'EXPORTEDKEY=1;DATATYPE=''ODBC''')"); cs.setString(1, catalog); ...
ResultSet function( String catalog, String schema, String table) throws SQLException { CallableStatement cs = prepareCall(STR + STR); cs.setString(1, catalog); cs.setString(2, schema); cs.setString(3, table); cs.execute(); return cs.getResultSet(); }
/** * Helper method for testing getExportedKeys - calls the ODBC procedure * @throws SQLException */
Helper method for testing getExportedKeys - calls the ODBC procedure
getExportedKeysODBC
{ "repo_name": "gemxd/gemfirexd-oss", "path": "gemfirexd/tools/src/testing/java/org/apache/derbyTesting/functionTests/tests/jdbcapi/DatabaseMetaDataTest.java", "license": "apache-2.0", "size": 184366 }
[ "java.sql.CallableStatement", "java.sql.ResultSet", "java.sql.SQLException" ]
import java.sql.CallableStatement; import java.sql.ResultSet; import java.sql.SQLException;
import java.sql.*;
[ "java.sql" ]
java.sql;
2,594,505
private void initScoreEasyForm(final UserRequest ureq) { removeAsListenerAndDispose(scoreEasyForm); scoreEasyForm = new EditScoreCalculationEasyForm(ureq, getWindowControl(), stNode.getScoreCalculator(), assessableChildren); listenTo(scoreEasyForm); score.put("scoreForm", scoreEasyForm.getInitialComponent())...
void function(final UserRequest ureq) { removeAsListenerAndDispose(scoreEasyForm); scoreEasyForm = new EditScoreCalculationEasyForm(ureq, getWindowControl(), stNode.getScoreCalculator(), assessableChildren); listenTo(scoreEasyForm); score.put(STR, scoreEasyForm.getInitialComponent()); score.contextPut(STR, Boolean.FALS...
/** * Initialize an easy mode score calculator form and push it to the score velocity container */
Initialize an easy mode score calculator form and push it to the score velocity container
initScoreEasyForm
{ "repo_name": "RLDevOps/Scholastic", "path": "src/main/java/org/olat/course/nodes/st/STCourseNodeEditController.java", "license": "apache-2.0", "size": 16189 }
[ "org.olat.core.gui.UserRequest" ]
import org.olat.core.gui.UserRequest;
import org.olat.core.gui.*;
[ "org.olat.core" ]
org.olat.core;
1,826,437
@Override public TipsOfTheDayUsers fetchByC_G_U(long companyId, long groupId, long userId, boolean retrieveFromCache) { Object[] finderArgs = new Object[] { companyId, groupId, userId }; Object result = null; if (retrieveFromCache) { result = finderCache.getResult(FINDER_PATH_FETCH_BY_C_G_U, finde...
TipsOfTheDayUsers function(long companyId, long groupId, long userId, boolean retrieveFromCache) { Object[] finderArgs = new Object[] { companyId, groupId, userId }; Object result = null; if (retrieveFromCache) { result = finderCache.getResult(FINDER_PATH_FETCH_BY_C_G_U, finderArgs, this); } if (result instanceof TipsO...
/** * Returns the Tips of the Day Users where companyId = &#63; and groupId = &#63; and userId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache. * * @param companyId the company ID * @param groupId the group ID * @param userId the user ID * @param retrieveFrom...
Returns the Tips of the Day Users where companyId = &#63; and groupId = &#63; and userId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache
fetchByC_G_U
{ "repo_name": "rivetlogic/liferay-tip-of-the-day", "path": "modules/tip-day-services/tip-day-services-service/src/main/java/com/rivetlogic/services/service/persistence/impl/TipsOfTheDayUsersPersistenceImpl.java", "license": "gpl-3.0", "size": 36323 }
[ "com.liferay.portal.kernel.dao.orm.Query", "com.liferay.portal.kernel.dao.orm.QueryPos", "com.liferay.portal.kernel.dao.orm.Session", "com.liferay.portal.kernel.util.StringBundler", "com.liferay.portal.kernel.util.StringUtil", "com.rivetlogic.services.model.TipsOfTheDayUsers", "java.util.Collections", ...
import com.liferay.portal.kernel.dao.orm.Query; import com.liferay.portal.kernel.dao.orm.QueryPos; import com.liferay.portal.kernel.dao.orm.Session; import com.liferay.portal.kernel.util.StringBundler; import com.liferay.portal.kernel.util.StringUtil; import com.rivetlogic.services.model.TipsOfTheDayUsers; import java....
import com.liferay.portal.kernel.dao.orm.*; import com.liferay.portal.kernel.util.*; import com.rivetlogic.services.model.*; import java.util.*;
[ "com.liferay.portal", "com.rivetlogic.services", "java.util" ]
com.liferay.portal; com.rivetlogic.services; java.util;
1,084,532
ServiceCall<Void> patch302Async(final ServiceCallback<Void> serviceCallback) throws IllegalArgumentException; ServiceResponseWithHeaders<Void, HttpRedirectsPatch302Headers> patch302(Boolean booleanValue) throws ErrorException, IOException;
ServiceCall<Void> patch302Async(final ServiceCallback<Void> serviceCallback) throws IllegalArgumentException; ServiceResponseWithHeaders<Void, HttpRedirectsPatch302Headers> patch302(Boolean booleanValue) throws ErrorException, IOException;
/** * Patch true Boolean value in request returns 302. This request should not be automatically redirected, but should return the received 302 to the caller for evaluation. * * @param booleanValue Simple boolean value true * @throws ErrorException exception thrown from REST call * @throws IOEx...
Patch true Boolean value in request returns 302. This request should not be automatically redirected, but should return the received 302 to the caller for evaluation
patch302
{ "repo_name": "yaqiyang/autorest", "path": "src/generator/AutoRest.Java.Tests/src/main/java/fixtures/http/HttpRedirects.java", "license": "mit", "size": 22215 }
[ "com.microsoft.rest.ServiceCall", "com.microsoft.rest.ServiceCallback", "com.microsoft.rest.ServiceResponseWithHeaders", "java.io.IOException" ]
import com.microsoft.rest.ServiceCall; import com.microsoft.rest.ServiceCallback; import com.microsoft.rest.ServiceResponseWithHeaders; import java.io.IOException;
import com.microsoft.rest.*; import java.io.*;
[ "com.microsoft.rest", "java.io" ]
com.microsoft.rest; java.io;
110,799
public void testMin4011() { List<AbstractPlanNode> pn = compileToFragments("SELECT MIN(C1) FROM R WHERE C1 > ?"); checkIndexLimit(pn, true, new String[] {"R_IDX1_TREE", "R_IDX2_TREE", "R_IDX4_TREE"}); }
void function() { List<AbstractPlanNode> pn = compileToFragments(STR); checkIndexLimit(pn, true, new String[] {STR, STR, STR}); }
/** * Test edge cases. */
Test edge cases
testMin4011
{ "repo_name": "migue/voltdb", "path": "tests/frontend/org/voltdb/planner/TestReplaceWithIndexLimit.java", "license": "agpl-3.0", "size": 20690 }
[ "java.util.List", "org.voltdb.plannodes.AbstractPlanNode" ]
import java.util.List; import org.voltdb.plannodes.AbstractPlanNode;
import java.util.*; import org.voltdb.plannodes.*;
[ "java.util", "org.voltdb.plannodes" ]
java.util; org.voltdb.plannodes;
1,918,456
public static DataCell nodeToStringCell(final JsonNode node) { if (isNull(node)) { return new MissingCell(null); } else { return new StringCell(node.asText()); } }
static DataCell function(final JsonNode node) { if (isNull(node)) { return new MissingCell(null); } else { return new StringCell(node.asText()); } }
/** * Creates a StringCell from the given JsonNode. Will return a MissingCell * if node.isNull() is true. * * @param node * The JsonNode * @return The corresponding cell */
Creates a StringCell from the given JsonNode. Will return a MissingCell if node.isNull() is true
nodeToStringCell
{ "repo_name": "patrick-winter-knime/misc", "path": "de.unikonstanz.winter.crossref/src/de/unikonstanz/winter/crossref/CrossrefUtil.java", "license": "gpl-3.0", "size": 4434 }
[ "com.fasterxml.jackson.databind.JsonNode", "org.knime.core.data.DataCell", "org.knime.core.data.MissingCell", "org.knime.core.data.def.StringCell" ]
import com.fasterxml.jackson.databind.JsonNode; import org.knime.core.data.DataCell; import org.knime.core.data.MissingCell; import org.knime.core.data.def.StringCell;
import com.fasterxml.jackson.databind.*; import org.knime.core.data.*; import org.knime.core.data.def.*;
[ "com.fasterxml.jackson", "org.knime.core" ]
com.fasterxml.jackson; org.knime.core;
2,268,337
public final Property<DebtSeniority> debtSeniority() { return metaBean().debtSeniority().createProperty(this); }
final Property<DebtSeniority> function() { return metaBean().debtSeniority().createProperty(this); }
/** * Gets the the {@code debtSeniority} property. * @return the property, not null */
Gets the the debtSeniority property
debtSeniority
{ "repo_name": "jeorme/OG-Platform", "path": "projects/OG-FinancialTypes/src/main/java/com/opengamma/financial/security/cds/CreditDefaultSwapSecurity.java", "license": "apache-2.0", "size": 12667 }
[ "com.opengamma.analytics.financial.credit.DebtSeniority", "org.joda.beans.Property" ]
import com.opengamma.analytics.financial.credit.DebtSeniority; import org.joda.beans.Property;
import com.opengamma.analytics.financial.credit.*; import org.joda.beans.*;
[ "com.opengamma.analytics", "org.joda.beans" ]
com.opengamma.analytics; org.joda.beans;
2,372,822
public PartitionedResourceRequests partitionAskList( List<ResourceRequest> askList) { PartitionedResourceRequests partitionedRequests = new PartitionedResourceRequests(); for (ResourceRequest rr : askList) { if (rr.getExecutionTypeRequest().getExecutionType() == ExecutionType.OPP...
PartitionedResourceRequests function( List<ResourceRequest> askList) { PartitionedResourceRequests partitionedRequests = new PartitionedResourceRequests(); for (ResourceRequest rr : askList) { if (rr.getExecutionTypeRequest().getExecutionType() == ExecutionType.OPPORTUNISTIC) { partitionedRequests.getOpportunistic().ad...
/** * Partitions a list of ResourceRequest to two separate lists, one for * GUARANTEED and one for OPPORTUNISTIC ResourceRequests. * @param askList the list of ResourceRequests to be partitioned * @return the partitioned ResourceRequests */
Partitions a list of ResourceRequest to two separate lists, one for GUARANTEED and one for OPPORTUNISTIC ResourceRequests
partitionAskList
{ "repo_name": "wenxinhe/hadoop", "path": "hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-common/src/main/java/org/apache/hadoop/yarn/server/scheduler/OpportunisticContainerAllocator.java", "license": "apache-2.0", "size": 22106 }
[ "java.util.List", "org.apache.hadoop.yarn.api.records.ExecutionType", "org.apache.hadoop.yarn.api.records.ResourceRequest" ]
import java.util.List; import org.apache.hadoop.yarn.api.records.ExecutionType; import org.apache.hadoop.yarn.api.records.ResourceRequest;
import java.util.*; import org.apache.hadoop.yarn.api.records.*;
[ "java.util", "org.apache.hadoop" ]
java.util; org.apache.hadoop;
1,918,857
public void delete() throws IOException;
void function() throws IOException;
/** * Deletes the sorted oplog file */
Deletes the sorted oplog file
delete
{ "repo_name": "SnappyDataInc/snappy-store", "path": "gemfire-core/src/main/java/com/gemstone/gemfire/internal/cache/persistence/soplog/SortedOplog.java", "license": "apache-2.0", "size": 4483 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
1,539,659
public void addPayload(String bearerToken, Map<String, String> addPayload) { Map<String, String> payload = tokenMap.get(bearerToken); if (payload != null) { payload.putAll(addPayload); } else { throw new IllegalStateException("Token " + bearerToken + " is not found "); } }
void function(String bearerToken, Map<String, String> addPayload) { Map<String, String> payload = tokenMap.get(bearerToken); if (payload != null) { payload.putAll(addPayload); } else { throw new IllegalStateException(STR + bearerToken + STR); } }
/** * Add some payload to existed token * * @param bearerToken - bearer token that associated with payload. * @return - map with payload */
Add some payload to existed token
addPayload
{ "repo_name": "codenvy/codenvy", "path": "wsmaster/codenvy-hosted-sso-auth-bearer/src/main/java/com/codenvy/auth/sso/server/handler/BearerTokenAuthenticationHandler.java", "license": "epl-1.0", "size": 6110 }
[ "java.util.Map" ]
import java.util.Map;
import java.util.*;
[ "java.util" ]
java.util;
2,523,099
@Test public void setBlockSize() { Assert.assertEquals(TEST_BLOCK_SIZE, mTempBlockMeta.getBlockSize()); mTempBlockMeta.setBlockSize(1); Assert.assertEquals(1, mTempBlockMeta.getBlockSize()); mTempBlockMeta.setBlockSize(100); Assert.assertEquals(100, mTempBlockMeta.getBlockSize()); }
void function() { Assert.assertEquals(TEST_BLOCK_SIZE, mTempBlockMeta.getBlockSize()); mTempBlockMeta.setBlockSize(1); Assert.assertEquals(1, mTempBlockMeta.getBlockSize()); mTempBlockMeta.setBlockSize(100); Assert.assertEquals(100, mTempBlockMeta.getBlockSize()); }
/** * Tests the {@link TempBlockMeta#setBlockSize(long)} method. */
Tests the <code>TempBlockMeta#setBlockSize(long)</code> method
setBlockSize
{ "repo_name": "ShailShah/alluxio", "path": "core/server/worker/src/test/java/alluxio/worker/block/meta/TempBlockMetaTest.java", "license": "apache-2.0", "size": 3120 }
[ "org.junit.Assert" ]
import org.junit.Assert;
import org.junit.*;
[ "org.junit" ]
org.junit;
397,444
private static final int find(MapElement[] map, CharChunk name, int start, int end) { int a = 0; int b = map.length - 1; // Special cases: -1 and 0 if (b == -1) { return -1; } if (compare(name, start, end, map[0].name) ...
static final int function(MapElement[] map, CharChunk name, int start, int end) { int a = 0; int b = map.length - 1; if (b == -1) { return -1; } if (compare(name, start, end, map[0].name) < 0 ) { return -1; } if (b == 0) { return 0; } int i = 0; while (true) { i = (b + a) / 2; int result = compare(name, start, end, map...
/** * Find a map element given its name in a sorted array of map elements. * This will return the index for the closest inferior or equal item in the * given array. */
Find a map element given its name in a sorted array of map elements. This will return the index for the closest inferior or equal item in the given array
find
{ "repo_name": "mayonghui2112/helloWorld", "path": "sourceCode/apache-tomcat-7.0.82-src/java/org/apache/tomcat/util/http/mapper/Mapper.java", "license": "apache-2.0", "size": 61011 }
[ "org.apache.tomcat.util.buf.CharChunk" ]
import org.apache.tomcat.util.buf.CharChunk;
import org.apache.tomcat.util.buf.*;
[ "org.apache.tomcat" ]
org.apache.tomcat;
2,251,065
static <E> Iterator<E> iteratorImpl(Multiset<E> multiset) { return new MultisetIteratorImpl<E>(multiset, multiset.entrySet().iterator()); } static final class MultisetIteratorImpl<E> implements Iterator<E> { private final Multiset<E> multiset; private final Iterator<Entry<E>> entryIterator; priva...
static <E> Iterator<E> iteratorImpl(Multiset<E> multiset) { return new MultisetIteratorImpl<E>(multiset, multiset.entrySet().iterator()); } static final class MultisetIteratorImpl<E> implements Iterator<E> { private final Multiset<E> multiset; private final Iterator<Entry<E>> entryIterator; private Entry<E> currentEntr...
/** * An implementation of {@link Multiset#iterator}. */
An implementation of <code>Multiset#iterator</code>
iteratorImpl
{ "repo_name": "DavesMan/guava", "path": "guava/src/com/google/common/collect/Multisets.java", "license": "apache-2.0", "size": 39042 }
[ "com.google.common.collect.Multiset", "java.util.Iterator" ]
import com.google.common.collect.Multiset; import java.util.Iterator;
import com.google.common.collect.*; import java.util.*;
[ "com.google.common", "java.util" ]
com.google.common; java.util;
1,417,861
public final InstanceIdentifier<Node> getNodeIdentifier() { return getNodeIdentifierBuilder().build(); }
final InstanceIdentifier<Node> function() { return getNodeIdentifierBuilder().build(); }
/** * Return an instance identifier that specifies MD-SAL node instance. * * @return An instance identifier for a MD-SAL node. */
Return an instance identifier that specifies MD-SAL node instance
getNodeIdentifier
{ "repo_name": "opendaylight/vtn", "path": "manager/implementation/src/main/java/org/opendaylight/vtn/manager/internal/util/inventory/SalNode.java", "license": "epl-1.0", "size": 13071 }
[ "org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.nodes.Node", "org.opendaylight.yangtools.yang.binding.InstanceIdentifier" ]
import org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.nodes.Node; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
import org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.nodes.*; import org.opendaylight.yangtools.yang.binding.*;
[ "org.opendaylight.yang", "org.opendaylight.yangtools" ]
org.opendaylight.yang; org.opendaylight.yangtools;
1,710,847
public void clearAnyGeneralLedgerPendingEntries() { generalLedgerPendingEntries = new ArrayList<GeneralLedgerPendingEntry>(); }
void function() { generalLedgerPendingEntries = new ArrayList<GeneralLedgerPendingEntry>(); }
/** * This resets this document's list of general ledger pending etnries, though it does not delete those entries (however, the GeneralLedgerPendingEntryService will in most cases when this method is called). */
This resets this document's list of general ledger pending etnries, though it does not delete those entries (however, the GeneralLedgerPendingEntryService will in most cases when this method is called)
clearAnyGeneralLedgerPendingEntries
{ "repo_name": "ua-eas/ua-kfs-5.3", "path": "work/src/org/kuali/kfs/sys/document/GeneralLedgerPostingDocumentBase.java", "license": "agpl-3.0", "size": 9160 }
[ "java.util.ArrayList", "org.kuali.kfs.sys.businessobject.GeneralLedgerPendingEntry" ]
import java.util.ArrayList; import org.kuali.kfs.sys.businessobject.GeneralLedgerPendingEntry;
import java.util.*; import org.kuali.kfs.sys.businessobject.*;
[ "java.util", "org.kuali.kfs" ]
java.util; org.kuali.kfs;
340,734
public static String translateFormatted(String key, Object... pars) { // translates twice to allow rerouting/alias return I18n.translateToLocal(I18n.translateToLocalFormatted(key, (Object[]) pars).trim()).trim(); }
static String function(String key, Object... pars) { return I18n.translateToLocal(I18n.translateToLocalFormatted(key, (Object[]) pars).trim()).trim(); }
/** * Translate the string, insert parameters into the result of the translation */
Translate the string, insert parameters into the result of the translation
translateFormatted
{ "repo_name": "VosDerrick/Volsteria", "path": "src/main/java/slimeknights/tconstruct/library/Util.java", "license": "gpl-3.0", "size": 4695 }
[ "net.minecraft.util.text.translation.I18n" ]
import net.minecraft.util.text.translation.I18n;
import net.minecraft.util.text.translation.*;
[ "net.minecraft.util" ]
net.minecraft.util;
210,778
public static ConcurrentMap<String, String> getDispatchMap() throws JHOVE2Exception { if (dispatchMap == null) { dispatchMap = new ConcurrentHashMap<String, String>(); Map<String, Object> map = SpringConfigInfo .getObjectsForType(BaseFormatModule.class); ...
static ConcurrentMap<String, String> function() throws JHOVE2Exception { if (dispatchMap == null) { dispatchMap = new ConcurrentHashMap<String, String>(); Map<String, Object> map = SpringConfigInfo .getObjectsForType(BaseFormatModule.class); for (Entry<String, Object> entry : map.entrySet()) { String moduleBeanName = e...
/** * Gets the mapping from format to format module. Initializes the static map * on first invocation. * * @return map from JHOVE2 format identifier to module bean name * * @throws JHOVE2Exception */
Gets the mapping from format to format module. Initializes the static map on first invocation
getDispatchMap
{ "repo_name": "opf-labs/jhove2", "path": "src/main/java/org/jhove2/config/spring/SpringFormatModuleFactory.java", "license": "bsd-2-clause", "size": 5450 }
[ "java.util.Map", "java.util.concurrent.ConcurrentHashMap", "java.util.concurrent.ConcurrentMap", "org.jhove2.core.JHOVE2Exception", "org.jhove2.core.format.Format", "org.jhove2.module.format.BaseFormatModule", "org.jhove2.module.format.FormatProfile" ]
import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; import org.jhove2.core.JHOVE2Exception; import org.jhove2.core.format.Format; import org.jhove2.module.format.BaseFormatModule; import org.jhove2.module.format.FormatProfile;
import java.util.*; import java.util.concurrent.*; import org.jhove2.core.*; import org.jhove2.core.format.*; import org.jhove2.module.format.*;
[ "java.util", "org.jhove2.core", "org.jhove2.module" ]
java.util; org.jhove2.core; org.jhove2.module;
517,161
public List getDebugLvlVals() { return this.debugLvlVals; }
List function() { return this.debugLvlVals; }
/** * Return the debugVals. */
Return the debugVals
getDebugLvlVals
{ "repo_name": "devjin24/howtomcatworks", "path": "bookrefer/jakarta-tomcat-4.1.12-src/webapps/admin/WEB-INF/classes/org/apache/webapp/admin/connector/ConnectorForm.java", "license": "apache-2.0", "size": 20038 }
[ "java.util.List" ]
import java.util.List;
import java.util.*;
[ "java.util" ]
java.util;
1,347,698
public Set<ReconfigurationCommand> process(){ Set<ReconfigurationCommand> aux = new HashSet<ReconfigurationCommand>(); for(Iterator<ComponentAction> iter = action_list.values().iterator(); iter.hasNext();){ ReconfigurationCommand command = (ReconfigurationCommand) iter.next().execute(); if (command != null...
Set<ReconfigurationCommand> function(){ Set<ReconfigurationCommand> aux = new HashSet<ReconfigurationCommand>(); for(Iterator<ComponentAction> iter = action_list.values().iterator(); iter.hasNext();){ ReconfigurationCommand command = (ReconfigurationCommand) iter.next().execute(); if (command != null) aux.add(command);...
/** * processes the actions in the list that had not been processed but now can be * @return the commands of the action_list that had not been processed, null if none */
processes the actions in the list that had not been processed but now can be
process
{ "repo_name": "aslab/rct", "path": "higgs/branches/ros-fuerte/OM/versions/NamePerception_OM/OMJava/src/org/aslab/om/metacontrol/action/Reconfiguration.java", "license": "gpl-3.0", "size": 2041 }
[ "java.util.HashSet", "java.util.Iterator", "java.util.Set" ]
import java.util.HashSet; import java.util.Iterator; import java.util.Set;
import java.util.*;
[ "java.util" ]
java.util;
293,037
@Test public void testUpdateObjectOnUniqueIndexDifferentValue() { DBCollection collection = fongoRule.newCollection(); collection.createIndex(new BasicDBObject("n", 1), "n_1", true); collection.insert(new BasicDBObject("n", 1)); collection.insert(new BasicDBObject("n", 2)); // Update same. ...
void function() { DBCollection collection = fongoRule.newCollection(); collection.createIndex(new BasicDBObject("n", 1), "n_1", true); collection.insert(new BasicDBObject("n", 1)); collection.insert(new BasicDBObject("n", 2)); collection.update(new BasicDBObject("n", 2), new BasicDBObject("n", 3)); assertEquals(0, coll...
/** * Try to update an object and doesn't violate the unique index. */
Try to update an object and doesn't violate the unique index
testUpdateObjectOnUniqueIndexDifferentValue
{ "repo_name": "fakemongo/fongo", "path": "src/test/java/com/github/fakemongo/FongoIndexTest.java", "license": "apache-2.0", "size": 35106 }
[ "com.mongodb.BasicDBObject", "com.mongodb.DBCollection", "org.junit.Assert" ]
import com.mongodb.BasicDBObject; import com.mongodb.DBCollection; import org.junit.Assert;
import com.mongodb.*; import org.junit.*;
[ "com.mongodb", "org.junit" ]
com.mongodb; org.junit;
545,649
public RecommendationActionInner withExpirationTime(OffsetDateTime expirationTime) { if (this.innerProperties() == null) { this.innerProperties = new RecommendationActionProperties(); } this.innerProperties().withExpirationTime(expirationTime); return this; }
RecommendationActionInner function(OffsetDateTime expirationTime) { if (this.innerProperties() == null) { this.innerProperties = new RecommendationActionProperties(); } this.innerProperties().withExpirationTime(expirationTime); return this; }
/** * Set the expirationTime property: Recommendation action expiration time. * * @param expirationTime the expirationTime value to set. * @return the RecommendationActionInner object itself. */
Set the expirationTime property: Recommendation action expiration time
withExpirationTime
{ "repo_name": "Azure/azure-sdk-for-java", "path": "sdk/mysql/azure-resourcemanager-mysql/src/main/java/com/azure/resourcemanager/mysql/fluent/models/RecommendationActionInner.java", "license": "mit", "size": 7554 }
[ "java.time.OffsetDateTime" ]
import java.time.OffsetDateTime;
import java.time.*;
[ "java.time" ]
java.time;
1,149,932
protected String getOpSingleAssignToken(EObject semanticObject, RuleCall ruleCall, INode node) { if (node != null) return getTokenText(node); return "="; }
String function(EObject semanticObject, RuleCall ruleCall, INode node) { if (node != null) return getTokenText(node); return "="; }
/** * OpSingleAssign: * '=' * ; */
OpSingleAssign: '='
getOpSingleAssignToken
{ "repo_name": "adrian-herscu/experiments", "path": "language-workbenches/xtext/org.example.domainmodel/src-gen/org/example/domainmodel/serializer/DomainmodelSyntacticSequencer.java", "license": "apache-2.0", "size": 7461 }
[ "org.eclipse.emf.ecore.EObject", "org.eclipse.xtext.RuleCall", "org.eclipse.xtext.nodemodel.INode" ]
import org.eclipse.emf.ecore.EObject; import org.eclipse.xtext.RuleCall; import org.eclipse.xtext.nodemodel.INode;
import org.eclipse.emf.ecore.*; import org.eclipse.xtext.*; import org.eclipse.xtext.nodemodel.*;
[ "org.eclipse.emf", "org.eclipse.xtext" ]
org.eclipse.emf; org.eclipse.xtext;
1,414,762
@RequestMapping(method = RequestMethod.GET, value = "/{projectId}/suitabilityScenarios/{id}/pdf") @ResponseBody public byte[] getPDF(final HttpServletResponse response, @PathVariable("id") final String id) throws WifInvalidInputException, WifInvalidConfigException, ParsingException, IOException { ...
@RequestMapping(method = RequestMethod.GET, value = STR) byte[] function(final HttpServletResponse response, @PathVariable("id") final String id) throws WifInvalidInputException, WifInvalidConfigException, ParsingException, IOException { byte[] bytem = null; LOGGER.info( STR, id); final SuitabilityScenario suitabilityS...
/** * Generates suitability scenario pdf report * * @param response * @param id * @return * @throws WifInvalidInputException * @throws WifInvalidConfigException * @throws ParsingException * @throws IOException */
Generates suitability scenario pdf report
getPDF
{ "repo_name": "tosseto/online-whatif", "path": "src/main/java/au/org/aurin/wif/controller/BirtController.java", "license": "mit", "size": 56273 }
[ "au.org.aurin.wif.exception.config.ParsingException", "au.org.aurin.wif.exception.config.WifInvalidConfigException", "au.org.aurin.wif.exception.validate.WifInvalidInputException", "au.org.aurin.wif.model.reports.BirtReport", "au.org.aurin.wif.model.reports.suitability.SuitabilityAnalysisItem", "au.org.au...
import au.org.aurin.wif.exception.config.ParsingException; import au.org.aurin.wif.exception.config.WifInvalidConfigException; import au.org.aurin.wif.exception.validate.WifInvalidInputException; import au.org.aurin.wif.model.reports.BirtReport; import au.org.aurin.wif.model.reports.suitability.SuitabilityAnalysisItem;...
import au.org.aurin.wif.exception.config.*; import au.org.aurin.wif.exception.validate.*; import au.org.aurin.wif.model.reports.*; import au.org.aurin.wif.model.reports.suitability.*; import au.org.aurin.wif.model.suitability.*; import java.io.*; import java.util.*; import javax.servlet.http.*; import org.springframewo...
[ "au.org.aurin", "java.io", "java.util", "javax.servlet", "org.springframework.web" ]
au.org.aurin; java.io; java.util; javax.servlet; org.springframework.web;
2,390,196
public boolean getClosedLoopControl() { return CompressorJNI.getClosedLoopControl(m_pcm); }
boolean function() { return CompressorJNI.getClosedLoopControl(m_pcm); }
/** * Gets the current operating mode of the PCM *$ * @return true if compressor is operating on closed-loop mode, otherwise * return false. */
Gets the current operating mode of the PCM $
getClosedLoopControl
{ "repo_name": "JLLeitschuh/allwpilib", "path": "wpilibj/src/athena/java/edu/wpi/first/wpilibj/Compressor.java", "license": "bsd-3-clause", "size": 6904 }
[ "edu.wpi.first.wpilibj.hal.CompressorJNI" ]
import edu.wpi.first.wpilibj.hal.CompressorJNI;
import edu.wpi.first.wpilibj.hal.*;
[ "edu.wpi.first" ]
edu.wpi.first;
2,094,285
private static void initializeFlipper(Context context) { if (BuildConfig.DEBUG) { try { Class<?> aClass = Class.forName("com.facebook.flipper.ReactNativeFlipper"); aClass.getMethod("initializeFlipper", Context.class).invoke(null, context); } catch (ClassNotFoundException e) { ...
static void function(Context context) { if (BuildConfig.DEBUG) { try { Class<?> aClass = Class.forName(STR); aClass.getMethod(STR, Context.class).invoke(null, context); } catch (ClassNotFoundException e) { e.printStackTrace(); } catch (NoSuchMethodException e) { e.printStackTrace(); } catch (IllegalAccessException e) {...
/** * Loads Flipper in React Native templates. * * @param context */
Loads Flipper in React Native templates
initializeFlipper
{ "repo_name": "paramaggarwal/react-native-youtube", "path": "example/android/app/src/main/java/com/reactnativeyoutubeexample/MainApplication.java", "license": "mit", "size": 2292 }
[ "android.content.Context", "java.lang.reflect.InvocationTargetException" ]
import android.content.Context; import java.lang.reflect.InvocationTargetException;
import android.content.*; import java.lang.reflect.*;
[ "android.content", "java.lang" ]
android.content; java.lang;
2,288,107
int updateByExampleSelective(@Param("record") Ptresource record, @Param("example") PtresourceExample example);
int updateByExampleSelective(@Param(STR) Ptresource record, @Param(STR) PtresourceExample example);
/** * This method was generated by MyBatis Generator. * This method corresponds to the database table PTRESOURCE * * @mbggenerated Tue Jan 12 13:20:41 CST 2016 */
This method was generated by MyBatis Generator. This method corresponds to the database table PTRESOURCE
updateByExampleSelective
{ "repo_name": "rongshang/fbi-cbs2", "path": "common/main/java/skyline/repository/dao/PtresourceMapper.java", "license": "unlicense", "size": 2051 }
[ "org.apache.ibatis.annotations.Param" ]
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.*;
[ "org.apache.ibatis" ]
org.apache.ibatis;
840,978
public void finishRefreshing(Date updateDate) { header.startAnimation(new ResizeHeaderAnimation(0)); progress.setVisibility(View.INVISIBLE); arrow.setVisibility(View.VISIBLE); if (updateDate == null) lastUpdateDate = new Date(); else lastUpdateDate = updateDate; date.setText(getFormattedDate(lastUp...
void function(Date updateDate) { header.startAnimation(new ResizeHeaderAnimation(0)); progress.setVisibility(View.INVISIBLE); arrow.setVisibility(View.VISIBLE); if (updateDate == null) lastUpdateDate = new Date(); else lastUpdateDate = updateDate; date.setText(getFormattedDate(lastUpdateDate)); comment.setText(getResou...
/** * Call when refreshing task is done. Must be called by the developer. * * @param updateDate * allow developer to set the last updateDate */
Call when refreshing task is done. Must be called by the developer
finishRefreshing
{ "repo_name": "sathishsr/Pull-To-Refresh", "path": "src/com/handmark/pulltorefresh/library/RefreshListView.java", "license": "apache-2.0", "size": 12832 }
[ "android.view.View", "java.util.Date" ]
import android.view.View; import java.util.Date;
import android.view.*; import java.util.*;
[ "android.view", "java.util" ]
android.view; java.util;
2,818,242
private String getContext() { return ToolManager.getCurrentPlacement().getContext(); }
String function() { return ToolManager.getCurrentPlacement().getContext(); }
/** * Returns current context * * @return * String The site id (context) where tool currently located */
Returns current context
getContext
{ "repo_name": "marktriggs/nyu-sakai-10.4", "path": "msgcntr/messageforums-app/src/java/org/sakaiproject/tool/messageforums/ui/MessageForumSynopticBean.java", "license": "apache-2.0", "size": 54127 }
[ "org.sakaiproject.tool.cover.ToolManager" ]
import org.sakaiproject.tool.cover.ToolManager;
import org.sakaiproject.tool.cover.*;
[ "org.sakaiproject.tool" ]
org.sakaiproject.tool;
1,857,023
public void actionPerformed(ActionEvent e) { try { Object target = e.getSource(); if (target == choice1But) { dispose(); button1Chosen(); // <--- Callback for button 1 --- } else if (target =...
void function(ActionEvent e) { try { Object target = e.getSource(); if (target == choice1But) { dispose(); button1Chosen(); } else if (target == choice2But) { dispose(); button2Chosen(); } else if (target == choice3But) { dispose(); button3Chosen(); } } catch (Throwable thr) { if (pi != null) { pi.chatPrintStackTrace(t...
/** * A button has been chosen by the user. * Call button1Chosen, button2Chosen or button3chosen, and dispose of this dialog. */
A button has been chosen by the user. Call button1Chosen, button2Chosen or button3chosen, and dispose of this dialog
actionPerformed
{ "repo_name": "nsp/OpenSettlers", "path": "src/java/soc/client/AskDialog.java", "license": "gpl-3.0", "size": 22330 }
[ "java.awt.event.ActionEvent" ]
import java.awt.event.ActionEvent;
import java.awt.event.*;
[ "java.awt" ]
java.awt;
742,459
private void assertSameAcls(AclStatus a, AclStatus b) throws Exception { assertTrue(a.getOwner().equals(b.getOwner())); assertTrue(a.getGroup().equals(b.getGroup())); assertTrue(a.isStickyBit() == b.isStickyBit()); assertTrue(a.getEntries().size() == b.getEntries().size()); for (AclEntry e : a.get...
void function(AclStatus a, AclStatus b) throws Exception { assertTrue(a.getOwner().equals(b.getOwner())); assertTrue(a.getGroup().equals(b.getGroup())); assertTrue(a.isStickyBit() == b.isStickyBit()); assertTrue(a.getEntries().size() == b.getEntries().size()); for (AclEntry e : a.getEntries()) { assertTrue(b.getEntries...
/** * Runs assertions testing that two AclStatus objects contain the same info * @param a First AclStatus * @param b Second AclStatus * @throws Exception */
Runs assertions testing that two AclStatus objects contain the same info
assertSameAcls
{ "repo_name": "xiao-chen/hadoop", "path": "hadoop-hdfs-project/hadoop-hdfs-httpfs/src/test/java/org/apache/hadoop/fs/http/client/BaseTestHttpFSWith.java", "license": "apache-2.0", "size": 59927 }
[ "org.apache.hadoop.fs.permission.AclEntry", "org.apache.hadoop.fs.permission.AclStatus", "org.junit.Assert" ]
import org.apache.hadoop.fs.permission.AclEntry; import org.apache.hadoop.fs.permission.AclStatus; import org.junit.Assert;
import org.apache.hadoop.fs.permission.*; import org.junit.*;
[ "org.apache.hadoop", "org.junit" ]
org.apache.hadoop; org.junit;
1,913,597
@Override public void setTypeflag(ILabelBean labelBean, Integer typeflag) { TPriorityBean priorityBean = (TPriorityBean)labelBean; priorityBean.setWlevel(typeflag); }
void function(ILabelBean labelBean, Integer typeflag) { TPriorityBean priorityBean = (TPriorityBean)labelBean; priorityBean.setWlevel(typeflag); }
/** * Sets the typeflag * @param labelBean * @param typeflag * @return */
Sets the typeflag
setTypeflag
{ "repo_name": "trackplus/Genji", "path": "src/main/java/com/aurel/track/admin/customize/lists/systemOption/PriorityConfigBL.java", "license": "gpl-3.0", "size": 8885 }
[ "com.aurel.track.beans.ILabelBean", "com.aurel.track.beans.TPriorityBean" ]
import com.aurel.track.beans.ILabelBean; import com.aurel.track.beans.TPriorityBean;
import com.aurel.track.beans.*;
[ "com.aurel.track" ]
com.aurel.track;
724,519
public void setDefaultMenuBar(final JMenuBar menuBar) { menuBarHandler.setDefaultMenuBar(menuBar); }
void function(final JMenuBar menuBar) { menuBarHandler.setDefaultMenuBar(menuBar); }
/** * Sets the default menu bar to use when there are no active frames. * Only used when the system property "apple.laf.useScreenMenuBar" is "true", and * the Aqua Look and Feel is active. * * @param menuBar to use when no other frames are active * * @since Java for Mac OS X 10.6 Upda...
Sets the default menu bar to use when there are no active frames. Only used when the system property "apple.laf.useScreenMenuBar" is "true", and the Aqua Look and Feel is active
setDefaultMenuBar
{ "repo_name": "universsky/openjdk", "path": "jdk/src/java.desktop/macosx/classes/com/apple/eawt/Application.java", "license": "gpl-2.0", "size": 22259 }
[ "javax.swing.JMenuBar" ]
import javax.swing.JMenuBar;
import javax.swing.*;
[ "javax.swing" ]
javax.swing;
2,845,882
@Override public byte[] getBases(final SimpleInterval window) { if ( dataSource == null || window == null ) { return new byte[0]; } // Trim to the contig start/end: final SimpleInterval trimmedWindow = new SimpleInterval( window.getContig(), ...
byte[] function(final SimpleInterval window) { if ( dataSource == null window == null ) { return new byte[0]; } final SimpleInterval trimmedWindow = new SimpleInterval( window.getContig(), trimToContigStart(window.getStart()), trimToContigLength(window.getContig(), window.getEnd()) ); return dataSource.queryAndPrefetch...
/** * Get all reference bases in this context with the given window. * Does not cache results or modify this {@link ReferenceContext} at all. * Will always return an empty array if there is no backing data source and/or interval to query. * * @return reference bases in this context, as a byte a...
Get all reference bases in this context with the given window. Does not cache results or modify this <code>ReferenceContext</code> at all. Will always return an empty array if there is no backing data source and/or interval to query
getBases
{ "repo_name": "broadinstitute/hellbender", "path": "src/main/java/org/broadinstitute/hellbender/engine/ReferenceContext.java", "license": "bsd-3-clause", "size": 18683 }
[ "org.broadinstitute.hellbender.utils.SimpleInterval" ]
import org.broadinstitute.hellbender.utils.SimpleInterval;
import org.broadinstitute.hellbender.utils.*;
[ "org.broadinstitute.hellbender" ]
org.broadinstitute.hellbender;
1,541,884
public static void main(String[] args) throws Exception { // String texFile = "test.tex"; String texFile = "article.tex"; countCitations(texFile); } ///////////////////////////////////////////////////////////////// // LOGGER ///////////////////////////////////////////////// ///////////////...
static void function(String[] args) throws Exception { String texFile = STR; countCitations(texFile); } private static HierarchicalLogger logger = HierarchicalLoggerManager.getHierarchicalLogger(); private final static Pattern BIBTEX_PATTERN = Pattern.compile(STR);
/** * Method used to launch this processing. Just change * the latex file when calling {@link #countCitations(String)}. * * @param args * None used. * * @throws Exception * Whatever exception. */
Method used to launch this processing. Just change the latex file when calling <code>#countCitations(String)</code>
main
{ "repo_name": "CompNet/BiblioProcess", "path": "src/fr/univavignon/biblioproc/tex/CountCitations.java", "license": "gpl-2.0", "size": 5215 }
[ "fr.univavignon.tools.log.HierarchicalLogger", "fr.univavignon.tools.log.HierarchicalLoggerManager", "java.util.regex.Pattern" ]
import fr.univavignon.tools.log.HierarchicalLogger; import fr.univavignon.tools.log.HierarchicalLoggerManager; import java.util.regex.Pattern;
import fr.univavignon.tools.log.*; import java.util.regex.*;
[ "fr.univavignon.tools", "java.util" ]
fr.univavignon.tools; java.util;
2,325,139
@Nullable default <T> T getCastedValue (@Nullable final KEYTYPE aKey, @Nullable final T aDefault) { final Object aValue = getValue (aKey); return aValue == null ? aDefault : GenericReflection.uncheckedCast (aValue); }
default <T> T getCastedValue (@Nullable final KEYTYPE aKey, @Nullable final T aDefault) { final Object aValue = getValue (aKey); return aValue == null ? aDefault : GenericReflection.uncheckedCast (aValue); }
/** * Get the contained value casted to the return type. * * @param aKey * The key to be accessed. May be <code>null</code>. * @param aDefault * The value to be returned if the retrieved value is <code>null</code> * . * @return The object value casted to the passed class. Ma...
Get the contained value casted to the return type
getCastedValue
{ "repo_name": "phax/ph-commons", "path": "ph-commons/src/main/java/com/helger/commons/traits/IGetterByKeyTrait.java", "license": "apache-2.0", "size": 30218 }
[ "com.helger.commons.lang.GenericReflection", "javax.annotation.Nullable" ]
import com.helger.commons.lang.GenericReflection; import javax.annotation.Nullable;
import com.helger.commons.lang.*; import javax.annotation.*;
[ "com.helger.commons", "javax.annotation" ]
com.helger.commons; javax.annotation;
396,056
@Test public void shouldCreateOneSharedNode() throws RepositoryException { String originalPath = "/Cars/Utility"; String sharedPath = "/NewArea/SharedUtility"; // Make the original a shareable node ... Node original = makeShareable(originalPath); session.save(); /...
void function() throws RepositoryException { String originalPath = STR; String sharedPath = STR; Node original = makeShareable(originalPath); session.save(); Node sharedNode = makeShare(originalPath, sharedPath); assertSharedSetIs(original, originalPath, sharedPath); assertSharedSetIs(sharedNode, originalPath, sharedPa...
/** * Verify that it is possible to create a new shareable node and then clone it to create a shared node and a shared set of * exactly one node. * * @throws RepositoryException */
Verify that it is possible to create a new shareable node and then clone it to create a shared node and a shared set of exactly one node
shouldCreateOneSharedNode
{ "repo_name": "weebl2000/modeshape", "path": "modeshape-jcr/src/test/java/org/modeshape/jcr/ShareableNodesTest.java", "license": "apache-2.0", "size": 30754 }
[ "javax.jcr.Node", "javax.jcr.RepositoryException" ]
import javax.jcr.Node; import javax.jcr.RepositoryException;
import javax.jcr.*;
[ "javax.jcr" ]
javax.jcr;
1,378,208
public static void printStackTrace(@CheckForNull Throwable t, @Nonnull PrintStream ps) { ps.println(printThrowable(t).trim()); }
static void function(@CheckForNull Throwable t, @Nonnull PrintStream ps) { ps.println(printThrowable(t).trim()); }
/** * Like {@link Throwable#printStackTrace(PrintStream)} but using {@link #printThrowable} format. * @param t an exception to print * @param ps the log * @since 2.43 */
Like <code>Throwable#printStackTrace(PrintStream)</code> but using <code>#printThrowable</code> format
printStackTrace
{ "repo_name": "lilyJi/jenkins", "path": "core/src/main/java/hudson/Functions.java", "license": "mit", "size": 74776 }
[ "java.io.PrintStream", "javax.annotation.CheckForNull", "javax.annotation.Nonnull" ]
import java.io.PrintStream; import javax.annotation.CheckForNull; import javax.annotation.Nonnull;
import java.io.*; import javax.annotation.*;
[ "java.io", "javax.annotation" ]
java.io; javax.annotation;
2,678,370
@SuppressLint("JavascriptInterface") public void addJavascriptInterface(Object object, String name) { if (TextUtils.equals(name, JAVASCRIPT_INTERFACE_NAME)) { throw new IllegalArgumentException(JAVASCRIPT_INTERFACE_NAME + " is a reserved Javascript Interface name."); } if (j...
@SuppressLint(STR) void function(Object object, String name) { if (TextUtils.equals(name, JAVASCRIPT_INTERFACE_NAME)) { throw new IllegalArgumentException(JAVASCRIPT_INTERFACE_NAME + STR); } if (javascriptInterfaces.get(name) == null) { javascriptInterfaces.put(name, object); webView.addJavascriptInterface(object, name...
/** * <p>Provides the ability to add an arbitrary number of custom Javascript Interfaces to the built-in * Turbolinks webView.</p> * * @param object The object with annotated JavascriptInterface methods * @param name The unique name for the interface (must not use the reserved name "Turbolink...
Provides the ability to add an arbitrary number of custom Javascript Interfaces to the built-in Turbolinks webView
addJavascriptInterface
{ "repo_name": "hgani/androlib", "path": "turbolinks/src/main/java/com/basecamp/turbolinks/TurbolinksSession.java", "license": "apache-2.0", "size": 33301 }
[ "android.annotation.SuppressLint", "android.text.TextUtils" ]
import android.annotation.SuppressLint; import android.text.TextUtils;
import android.annotation.*; import android.text.*;
[ "android.annotation", "android.text" ]
android.annotation; android.text;
1,400,683
@Generated @Selector("setTitle:") public native void setTitle(String value);
@Selector(STR) native void function(String value);
/** * An optional, user-visible title for this activity, such as a document name or web page title. */
An optional, user-visible title for this activity, such as a document name or web page title
setTitle
{ "repo_name": "multi-os-engine/moe-core", "path": "moe.apple/moe.platform.ios/src/main/java/apple/foundation/NSUserActivity.java", "license": "apache-2.0", "size": 25953 }
[ "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,113,107
void writeTriple(Resource s, URI p, Value o, URI g);
void writeTriple(Resource s, URI p, Value o, URI g);
/** * Writes a triple. * Parameters can be null, then the triple will be silently ignored. * * @param s subject * @param p predicate * @param o object * @param g graph */
Writes a triple. Parameters can be null, then the triple will be silently ignored
writeTriple
{ "repo_name": "venukb/any23", "path": "any23-core/src/main/java/org/deri/any23/extractor/ExtractionResult.java", "license": "apache-2.0", "size": 2243 }
[ "org.openrdf.model.Resource", "org.openrdf.model.Value" ]
import org.openrdf.model.Resource; import org.openrdf.model.Value;
import org.openrdf.model.*;
[ "org.openrdf.model" ]
org.openrdf.model;
1,435,327
protected int fieldHorizontalSpan() { return 1 + (hasLabel() ? 0 : 1) + (hasStyle(BasicsUI.NO_INFO) ? 1 : 0) + (hasActionsStyled(Action.STYLE_BUTTON) ? 0 : 1); }
int function() { return 1 + (hasLabel() ? 0 : 1) + (hasStyle(BasicsUI.NO_INFO) ? 1 : 0) + (hasActionsStyled(Action.STYLE_BUTTON) ? 0 : 1); }
/** * Calculates the horizontal span for the field value part. * SWT specific */
Calculates the horizontal span for the field value part. SWT specific
fieldHorizontalSpan
{ "repo_name": "jeancharles-roger/fr.minibilles.basics", "path": "basics-ui/src/main/java/fr/minibilles/basics/ui/field/AbstractField.java", "license": "mit", "size": 8724 }
[ "fr.minibilles.basics.ui.BasicsUI", "fr.minibilles.basics.ui.action.Action" ]
import fr.minibilles.basics.ui.BasicsUI; import fr.minibilles.basics.ui.action.Action;
import fr.minibilles.basics.ui.*; import fr.minibilles.basics.ui.action.*;
[ "fr.minibilles.basics" ]
fr.minibilles.basics;
608,031
InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(0, InputMethodManager.HIDE_NOT_ALWAYS); // imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0); }
InputMethodManager imm = (InputMethodManager) context.getSystemService(Context.INPUT_METHOD_SERVICE); imm.toggleSoftInput(0, InputMethodManager.HIDE_NOT_ALWAYS); }
/** * Toggle Soft Input * * @param context */
Toggle Soft Input
toggleSoftInput
{ "repo_name": "ifwx/AndroidCommon", "path": "common/src/main/java/com/wx/android/common/util/InputMethodUtils.java", "license": "apache-2.0", "size": 3132 }
[ "android.content.Context", "android.view.inputmethod.InputMethodManager" ]
import android.content.Context; import android.view.inputmethod.InputMethodManager;
import android.content.*; import android.view.inputmethod.*;
[ "android.content", "android.view" ]
android.content; android.view;
2,820,988
private void addPlacemarksToMap(HashMap<KmlPlacemark, Object> placemarks) { for (KmlPlacemark kmlPlacemark : placemarks.keySet()) { boolean isPlacemarkVisible = getPlacemarkVisibility(kmlPlacemark); Object mapObject = addPlacemarkToMap(kmlPlacemark, isPlacemarkVisible); /...
void function(HashMap<KmlPlacemark, Object> placemarks) { for (KmlPlacemark kmlPlacemark : placemarks.keySet()) { boolean isPlacemarkVisible = getPlacemarkVisibility(kmlPlacemark); Object mapObject = addPlacemarkToMap(kmlPlacemark, isPlacemarkVisible); placemarks.put(kmlPlacemark, mapObject); } }
/** * Iterates over the placemarks, gets its style or assigns a default one and adds it to the map */
Iterates over the placemarks, gets its style or assigns a default one and adds it to the map
addPlacemarksToMap
{ "repo_name": "DEVPAR/wigle-wifi-wardriving", "path": "android-maps-utils/src/com/google/maps/android/kml/KmlRenderer.java", "license": "bsd-3-clause", "size": 35734 }
[ "java.util.HashMap" ]
import java.util.HashMap;
import java.util.*;
[ "java.util" ]
java.util;
1,630,007
private void addHandler() { Varbind v = new Varbind(); v.setVbnumber(1); // A non null value is required here. container.addBean(v); }
void function() { Varbind v = new Varbind(); v.setVbnumber(1); container.addBean(v); }
/** * Adds the handler. */
Adds the handler
addHandler
{ "repo_name": "peternixon/opennms-mirror", "path": "features/vaadin-snmp-events-and-metrics/src/main/java/org/opennms/features/vaadin/events/MaskVarbindField.java", "license": "gpl-2.0", "size": 7370 }
[ "org.opennms.netmgt.xml.eventconf.Varbind" ]
import org.opennms.netmgt.xml.eventconf.Varbind;
import org.opennms.netmgt.xml.eventconf.*;
[ "org.opennms.netmgt" ]
org.opennms.netmgt;
1,005,648
public void error(Object message) { differentiatedLog(null, CATEGORY_FQCN, LocationAwareLogger.ERROR_INT, message, null); }
void function(Object message) { differentiatedLog(null, CATEGORY_FQCN, LocationAwareLogger.ERROR_INT, message, null); }
/** * Delegates to {@link org.slf4j.Logger#error(String)} method in SLF4J. * * @param message a message to log * */
Delegates to <code>org.slf4j.Logger#error(String)</code> method in SLF4J
error
{ "repo_name": "qos-ch/slf4j", "path": "log4j-over-slf4j/src/main/java/org/apache/log4j/Category.java", "license": "mit", "size": 11932 }
[ "org.slf4j.spi.LocationAwareLogger" ]
import org.slf4j.spi.LocationAwareLogger;
import org.slf4j.spi.*;
[ "org.slf4j.spi" ]
org.slf4j.spi;
2,277,562
@Override public Enumeration<String> getParameterNames() { return Collections.enumeration(getParameterMap().keySet()); }
Enumeration<String> function() { return Collections.enumeration(getParameterMap().keySet()); }
/** * Fetches just the names of regular parameters and does not include file upload parameters. If * the request is multipart then the information is sourced from the parsed multipart object * otherwise it is just pulled out of the request in the usual manner. */
Fetches just the names of regular parameters and does not include file upload parameters. If the request is multipart then the information is sourced from the parsed multipart object otherwise it is just pulled out of the request in the usual manner
getParameterNames
{ "repo_name": "scarcher2/stripes", "path": "stripes/src/net/sourceforge/stripes/controller/StripesRequestWrapper.java", "license": "apache-2.0", "size": 21887 }
[ "java.util.Collections", "java.util.Enumeration" ]
import java.util.Collections; import java.util.Enumeration;
import java.util.*;
[ "java.util" ]
java.util;
1,067,075
public static String getStringFromFile(String filename, int numChars) { StringBuffer s = new StringBuffer(); try { FileInputStream inputFile= new FileInputStream(filename); InputStreamReader inputStream = new InputStreamReader(inputFile); BufferedReader bis = new BufferedReader(inputStream); int v...
static String function(String filename, int numChars) { StringBuffer s = new StringBuffer(); try { FileInputStream inputFile= new FileInputStream(filename); InputStreamReader inputStream = new InputStreamReader(inputFile); BufferedReader bis = new BufferedReader(inputStream); int val; int count = 0; while ((val = bis.r...
/** Get a specified number of characters from a text file * * @param filename The file to read from * @param numChars The number of characters to read * @return The text string from the file with the appropriate number of characters */
Get a specified number of characters from a text file
getStringFromFile
{ "repo_name": "PBGraff/Coursera_Java_Performance", "path": "src/document/DocumentBenchmarking.java", "license": "gpl-2.0", "size": 3640 }
[ "java.io.BufferedReader", "java.io.FileInputStream", "java.io.InputStreamReader" ]
import java.io.BufferedReader; import java.io.FileInputStream; import java.io.InputStreamReader;
import java.io.*;
[ "java.io" ]
java.io;
1,211,430
protected void add2QueryBldr(final Parameter _parameter, final QueryBuilder _queryBldr) throws EFapsException { }
void function(final Parameter _parameter, final QueryBuilder _queryBldr) throws EFapsException { }
/** * Add2 query bldr. * * @param _parameter Parameter as passes by the eFaps API * @param _queryBldr QueryBuilder to add to * @throws EFapsException on error */
Add2 query bldr
add2QueryBldr
{ "repo_name": "eFaps/eFaps-Kernel-Install", "path": "src/main/efaps/ESJP/org/efaps/esjp/admin/datamodel/RangesValue_Base.java", "license": "apache-2.0", "size": 10536 }
[ "org.efaps.admin.event.Parameter", "org.efaps.db.QueryBuilder", "org.efaps.util.EFapsException" ]
import org.efaps.admin.event.Parameter; import org.efaps.db.QueryBuilder; import org.efaps.util.EFapsException;
import org.efaps.admin.event.*; import org.efaps.db.*; import org.efaps.util.*;
[ "org.efaps.admin", "org.efaps.db", "org.efaps.util" ]
org.efaps.admin; org.efaps.db; org.efaps.util;
476,401
@ApiModelProperty(value = "") public CurrencyCode getCurrencyCode() { return currencyCode; }
@ApiModelProperty(value = "") CurrencyCode function() { return currencyCode; }
/** * Get currencyCode * * @return currencyCode */
Get currencyCode
getCurrencyCode
{ "repo_name": "SidneyAllen/Xero-Java", "path": "src/main/java/com/xero/models/accounting/PurchaseOrder.java", "license": "mit", "size": 25049 }
[ "io.swagger.annotations.ApiModelProperty" ]
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.*;
[ "io.swagger.annotations" ]
io.swagger.annotations;
791,206
public static void moveMouseOutElement(EmergyaWebDriver driver, By selector) { log.info("[log-Utils] EmergyaWebDriverUtil - Start moveMouseOutElement method"); Robot r; int x = 0, y = 0; try { r = new Robot(); if (existsElement(driver, selector)) { ...
static void function(EmergyaWebDriver driver, By selector) { log.info(STR); Robot r; int x = 0, y = 0; try { r = new Robot(); if (existsElement(driver, selector)) { WebElement element = driver.findElement(selector); Point position = element.getLocation(); x = position.getX() - 10; y = position.getY() - 10; } Point toMo...
/** * Moves the mouse out of an element * * @param driver * WebDriver element * @param selector * By element */
Moves the mouse out of an element
moveMouseOutElement
{ "repo_name": "IvanGomezDeLeon/qa-selenium-handler", "path": "src/main/java/com/emergya/selenium/drivers/EmergyaWebDriverUtil.java", "license": "mit", "size": 21168 }
[ "java.awt.AWTException", "java.awt.MouseInfo", "java.awt.Robot", "org.openqa.selenium.By", "org.openqa.selenium.Point", "org.openqa.selenium.WebElement" ]
import java.awt.AWTException; import java.awt.MouseInfo; import java.awt.Robot; import org.openqa.selenium.By; import org.openqa.selenium.Point; import org.openqa.selenium.WebElement;
import java.awt.*; import org.openqa.selenium.*;
[ "java.awt", "org.openqa.selenium" ]
java.awt; org.openqa.selenium;
2,478,935
public void testMultithreadedCreate() throws Exception { Path dir = new Path(new Path(primaryFsUri), "/dir"); fs.mkdir(dir, FsPermission.getDefault(), true); final Path file = new Path(dir, "file"); fs.create(file, EnumSet.noneOf(CreateFlag.class), Options.CreateOpts.p...
void function() throws Exception { Path dir = new Path(new Path(primaryFsUri), "/dir"); fs.mkdir(dir, FsPermission.getDefault(), true); final Path file = new Path(dir, "file"); fs.create(file, EnumSet.noneOf(CreateFlag.class), Options.CreateOpts.perms(FsPermission.getDefault())).close(); final AtomicInteger cnt = new A...
/** * Ensure that when running in multithreaded mode only one create() operation succeed. * * @throws Exception If failed. */
Ensure that when running in multithreaded mode only one create() operation succeed
testMultithreadedCreate
{ "repo_name": "agura/incubator-ignite", "path": "modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java", "license": "apache-2.0", "size": 68253 }
[ "java.util.Collection", "java.util.EnumSet", "java.util.concurrent.atomic.AtomicInteger", "org.apache.hadoop.fs.CreateFlag", "org.apache.hadoop.fs.Options", "org.apache.hadoop.fs.Path", "org.apache.hadoop.fs.permission.FsPermission", "org.apache.ignite.internal.util.GridConcurrentHashSet" ]
import java.util.Collection; import java.util.EnumSet; import java.util.concurrent.atomic.AtomicInteger; import org.apache.hadoop.fs.CreateFlag; import org.apache.hadoop.fs.Options; import org.apache.hadoop.fs.Path; import org.apache.hadoop.fs.permission.FsPermission; import org.apache.ignite.internal.util.GridConcurre...
import java.util.*; import java.util.concurrent.atomic.*; import org.apache.hadoop.fs.*; import org.apache.hadoop.fs.permission.*; import org.apache.ignite.internal.util.*;
[ "java.util", "org.apache.hadoop", "org.apache.ignite" ]
java.util; org.apache.hadoop; org.apache.ignite;
254,118
@Override public INDArray computeScoreForExamples(double fullNetworkL1, double fullNetworkL2) { if (input == null || labels == null) throw new IllegalStateException("Cannot calculate score without input and labels " + layerId()); INDArray preOut = preOutput2d(false); ILossFu...
INDArray function(double fullNetworkL1, double fullNetworkL2) { if (input == null labels == null) throw new IllegalStateException(STR + layerId()); INDArray preOut = preOutput2d(false); ILossFunction lossFunction = layerConf().getLossFn(); INDArray scoreArray = lossFunction.computeScoreArray(getLabels2d(), preOut, laye...
/**Compute the score for each example individually, after labels and input have been set. * * @param fullNetworkL1 L1 regularization term for the entire network (or, 0.0 to not include regularization) * @param fullNetworkL2 L2 regularization term for the entire network (or, 0.0 to not include regularizat...
Compute the score for each example individually, after labels and input have been set
computeScoreForExamples
{ "repo_name": "kinbod/deeplearning4j", "path": "deeplearning4j-nn/src/main/java/org/deeplearning4j/nn/layers/BaseOutputLayer.java", "license": "apache-2.0", "size": 14934 }
[ "org.nd4j.linalg.api.ndarray.INDArray", "org.nd4j.linalg.lossfunctions.ILossFunction" ]
import org.nd4j.linalg.api.ndarray.INDArray; import org.nd4j.linalg.lossfunctions.ILossFunction;
import org.nd4j.linalg.api.ndarray.*; import org.nd4j.linalg.lossfunctions.*;
[ "org.nd4j.linalg" ]
org.nd4j.linalg;
1,321,423
@Override public String[] getOptions() { Vector<String> options = new Vector<String>(); options.add("-D"); options.add("" + getOnDemandDirectory()); Collections.addAll(options, super.getOptions()); return options.toArray(new String[0]); }
String[] function() { Vector<String> options = new Vector<String>(); options.add("-D"); options.add("" + getOnDemandDirectory()); Collections.addAll(options, super.getOptions()); return options.toArray(new String[0]); }
/** * Gets the current settings of the Classifier. * * @return an array of strings suitable for passing to setOptions */
Gets the current settings of the Classifier
getOptions
{ "repo_name": "umple/umple", "path": "Umplificator/UmplifiedProjects/weka-umplified-0/src/main/java/weka/experiment/CostSensitiveClassifierSplitEvaluator.java", "license": "mit", "size": 18719 }
[ "java.util.Collections", "java.util.Vector" ]
import java.util.Collections; import java.util.Vector;
import java.util.*;
[ "java.util" ]
java.util;
2,585,610
public void flush() throws IOException { getStream().flush(); }
void function() throws IOException { getStream().flush(); }
/** * Flushes this output stream and forces any buffered output bytes to be * written out. * * @exception IOException if an error occurs. */
Flushes this output stream and forces any buffered output bytes to be written out
flush
{ "repo_name": "plumer/codana", "path": "tomcat_files/6.0.0/ThresholdingOutputStream.java", "license": "mit", "size": 6797 }
[ "java.io.IOException" ]
import java.io.IOException;
import java.io.*;
[ "java.io" ]
java.io;
2,425,340
public Version with(Qualifier qualifier, int qualifierNumber) { this.qualifier = returnFirstNonNullValue(qualifier, Qualifier.UNDEFINED); this.qualifierNumber = Math.max(qualifierNumber, 0); return this; } public enum Qualifier { ALPHA("ALPHA", "Alpha"), BETA("BETA", "Beta"), BUILD_SN...
Version function(Qualifier qualifier, int qualifierNumber) { this.qualifier = returnFirstNonNullValue(qualifier, Qualifier.UNDEFINED); this.qualifierNumber = Math.max(qualifierNumber, 0); return this; } public enum Qualifier { ALPHA("ALPHA", "Alpha"), BETA("BETA", "Beta"), BUILD_SNAPSHOT(STR, STR), ITERATION("IT", STR)...
/** * Sets the {@link Version.Qualifier} for this {@link Version}. * * @param qualifier {@link Version.Qualifier}. * @param qualifierNumber {@link Version.Qualifier} number. * @return this {@link Version} reference. */
Sets the <code>Version.Qualifier</code> for this <code>Version</code>
with
{ "repo_name": "jxblum/cp-elements", "path": "src/main/java/org/cp/elements/lang/Version.java", "license": "apache-2.0", "size": 28195 }
[ "org.cp.elements.lang.ObjectUtils" ]
import org.cp.elements.lang.ObjectUtils;
import org.cp.elements.lang.*;
[ "org.cp.elements" ]
org.cp.elements;
1,869,666
public boolean deleteEndpoint(String endpointName) throws AxisFault { try { // This check was added due to endpoint was saved in endpoint directory instead of saving inline with api // synapse file. if (MultitenantConstants.SUPER_TENANT_DOMAIN_NAME.equals(tenantDomain)) ...
boolean function(String endpointName) throws AxisFault { try { if (MultitenantConstants.SUPER_TENANT_DOMAIN_NAME.equals(tenantDomain)) { return endpointAdmin.deleteEndpoint(endpointName); } else { return endpointAdmin.deleteEndpointForTenant(endpointName, tenantDomain); } } catch (Exception e) { log.error(STR, e); thro...
/** * Delete endpoint from the gateway * * @param endpointName Name of the endpoint to be deleted * @return True if the endpoint file is deleted * @throws AxisFault Thrown if an error occurred */
Delete endpoint from the gateway
deleteEndpoint
{ "repo_name": "jaadds/carbon-apimgt", "path": "components/apimgt/org.wso2.carbon.apimgt.gateway/src/main/java/org/wso2/carbon/apimgt/gateway/utils/EndpointAdminServiceProxy.java", "license": "apache-2.0", "size": 6572 }
[ "org.apache.axis2.AxisFault", "org.wso2.carbon.utils.multitenancy.MultitenantConstants" ]
import org.apache.axis2.AxisFault; import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
import org.apache.axis2.*; import org.wso2.carbon.utils.multitenancy.*;
[ "org.apache.axis2", "org.wso2.carbon" ]
org.apache.axis2; org.wso2.carbon;
923,905
@SuppressWarnings("nls") public static String degreeDecimal2ExifFormat( double decimalDegree ) { StringBuilder sb = new StringBuilder(); sb.append((int) decimalDegree); sb.append("/1,"); decimalDegree = (decimalDegree - (int) decimalDegree) * 60; sb.append((int) decimalDe...
@SuppressWarnings("nls") static String function( double decimalDegree ) { StringBuilder sb = new StringBuilder(); sb.append((int) decimalDegree); sb.append("/1,"); decimalDegree = (decimalDegree - (int) decimalDegree) * 60; sb.append((int) decimalDegree); sb.append("/1,"); decimalDegree = (decimalDegree - (int) decimal...
/** * Convert decimal degrees to exif format. * * @param decimalDegree the angle in decimal format. * @return the exif format string. */
Convert decimal degrees to exif format
degreeDecimal2ExifFormat
{ "repo_name": "gabrielmancilla/mtisig", "path": "geopaparazzilibrary/src/eu/geopaparazzi/library/util/Utilities.java", "license": "gpl-3.0", "size": 34203 }
[ "eu.geopaparazzi.library.database.GPLog" ]
import eu.geopaparazzi.library.database.GPLog;
import eu.geopaparazzi.library.database.*;
[ "eu.geopaparazzi.library" ]
eu.geopaparazzi.library;
404,447
Collection<TagAnnotationData> getTags() { StructuredDataResults data = parent.getStructuredData(); if (data == null) return new ArrayList<TagAnnotationData>(); Collection<TagAnnotationData> tags = data.getTags(); if (tags == null || tags.size() == 0) return new ArrayList<TagAnnotationData>(); return ...
Collection<TagAnnotationData> getTags() { StructuredDataResults data = parent.getStructuredData(); if (data == null) return new ArrayList<TagAnnotationData>(); Collection<TagAnnotationData> tags = data.getTags(); if (tags == null tags.size() == 0) return new ArrayList<TagAnnotationData>(); return (Collection<TagAnnotat...
/** * Returns the collection of the tags linked to the <code>DataObject</code>. * * @return See above. */
Returns the collection of the tags linked to the <code>DataObject</code>
getTags
{ "repo_name": "tp81/openmicroscopy", "path": "components/insight/SRC/org/openmicroscopy/shoola/agents/metadata/editor/EditorModel.java", "license": "gpl-2.0", "size": 128116 }
[ "java.util.ArrayList", "java.util.Collection", "org.openmicroscopy.shoola.env.data.util.StructuredDataResults" ]
import java.util.ArrayList; import java.util.Collection; import org.openmicroscopy.shoola.env.data.util.StructuredDataResults;
import java.util.*; import org.openmicroscopy.shoola.env.data.util.*;
[ "java.util", "org.openmicroscopy.shoola" ]
java.util; org.openmicroscopy.shoola;
2,084,741
Arrays.sort(constructors, new Comparator() {
Arrays.sort(constructors, new Comparator() {
/** * Sort the given constructors, preferring public constructors and "greedy" ones * with a maximum of arguments. The result will contain public constructors first, * with decreasing number of arguments, then non-public constructors, again with * decreasing number of arguments. * @param constructors the cons...
Sort the given constructors, preferring public constructors and "greedy" ones with a maximum of arguments. The result will contain public constructors first, with decreasing number of arguments, then non-public constructors, again with decreasing number of arguments
sortConstructors
{ "repo_name": "cbeams-archive/spring-framework-2.5.x", "path": "src/org/springframework/beans/factory/support/AutowireUtils.java", "license": "apache-2.0", "size": 4752 }
[ "java.util.Arrays", "java.util.Comparator" ]
import java.util.Arrays; import java.util.Comparator;
import java.util.*;
[ "java.util" ]
java.util;
1,236,899
public boolean isVendor(DisbursementVoucherPayeeDetail dvPayeeDetail);
boolean function(DisbursementVoucherPayeeDetail dvPayeeDetail);
/** * determine whether the given payee is a vendor * * @param dvPayeeDetail the given payee * @return true if the given payee is a vendor; otherwise, false */
determine whether the given payee is a vendor
isVendor
{ "repo_name": "Ariah-Group/Finance", "path": "af_webapp/src/main/java/org/kuali/kfs/fp/document/service/DisbursementVoucherPayeeService.java", "license": "apache-2.0", "size": 4472 }
[ "org.kuali.kfs.fp.businessobject.DisbursementVoucherPayeeDetail" ]
import org.kuali.kfs.fp.businessobject.DisbursementVoucherPayeeDetail;
import org.kuali.kfs.fp.businessobject.*;
[ "org.kuali.kfs" ]
org.kuali.kfs;
2,539,371
public synchronized void setNumElements(int i) { // If index is negative thrown an error if (i < 0) { throw MathRuntimeException.createIllegalArgumentException( "index ({0}) is not positive", i); } // Test the new num elements, ch...
synchronized void function(int i) { if (i < 0) { throw MathRuntimeException.createIllegalArgumentException( STR, i); } if ((startIndex + i) > internalArray.length) { expandTo(startIndex + i); } numElements = i; }
/** * This function allows you to control the number of elements contained * in this array, and can be used to "throw out" the last n values in an * array. This function will also expand the internal array as needed. * * @param i a new number of elements * @throws IllegalArgumentException ...
This function allows you to control the number of elements contained in this array, and can be used to "throw out" the last n values in an array. This function will also expand the internal array as needed
setNumElements
{ "repo_name": "justinwm/astor", "path": "examples/math_76/src/main/java/org/apache/commons/math/util/ResizableDoubleArray.java", "license": "gpl-2.0", "size": 35119 }
[ "org.apache.commons.math.MathRuntimeException" ]
import org.apache.commons.math.MathRuntimeException;
import org.apache.commons.math.*;
[ "org.apache.commons" ]
org.apache.commons;
205,899
private String validateTokenType(HttpServletRequest request, HttpServletResponse response) throws IOException, OidcServerException { String queryString = request.getQueryString(); if (queryString == null) { BrowserAndServerLogMessage updateMsg = new BrowserAndServerLogMessage...
String function(HttpServletRequest request, HttpServletResponse response) throws IOException, OidcServerException { String queryString = request.getQueryString(); if (queryString == null) { BrowserAndServerLogMessage updateMsg = new BrowserAndServerLogMessage(tc, STR, new Object[] { OAuth20Constants.TOKEN_TYPE }); Tr.e...
/** * Validates and returns the token_type specified with the referenced request. Returns <code>null</code> if token_type parameter was incorrectly specified * on the request, with the response object updated with the appropriate error message. * * @param request * The request to par...
Validates and returns the token_type specified with the referenced request. Returns <code>null</code> if token_type parameter was incorrectly specified on the request, with the response object updated with the appropriate error message
validateTokenType
{ "repo_name": "OpenLiberty/open-liberty", "path": "dev/com.ibm.ws.security.oauth/src/com/ibm/ws/security/oauth20/web/CoverageMapEndpointServices.java", "license": "epl-1.0", "size": 10010 }
[ "com.ibm.oauth.core.api.error.OidcServerException", "com.ibm.oauth.core.internal.oauth20.OAuth20Constants", "com.ibm.websphere.ras.Tr", "com.ibm.ws.security.oauth20.error.impl.BrowserAndServerLogMessage", "com.ibm.ws.security.oauth20.util.OIDCConstants", "java.io.IOException", "java.util.Map", "javax....
import com.ibm.oauth.core.api.error.OidcServerException; import com.ibm.oauth.core.internal.oauth20.OAuth20Constants; import com.ibm.websphere.ras.Tr; import com.ibm.ws.security.oauth20.error.impl.BrowserAndServerLogMessage; import com.ibm.ws.security.oauth20.util.OIDCConstants; import java.io.IOException; import java....
import com.ibm.oauth.core.api.error.*; import com.ibm.oauth.core.internal.oauth20.*; import com.ibm.websphere.ras.*; import com.ibm.ws.security.oauth20.error.impl.*; import com.ibm.ws.security.oauth20.util.*; import java.io.*; import java.util.*; import javax.servlet.http.*;
[ "com.ibm.oauth", "com.ibm.websphere", "com.ibm.ws", "java.io", "java.util", "javax.servlet" ]
com.ibm.oauth; com.ibm.websphere; com.ibm.ws; java.io; java.util; javax.servlet;
296,073
public void endEntity(String name, Augmentations augs) throws IOException, XNIException { // keep track of the entity depth if (fEntityDepth > 0) { fEntityDepth--; } } // endEntity(String)
void function(String name, Augmentations augs) throws IOException, XNIException { if (fEntityDepth > 0) { fEntityDepth--; } }
/** * This method notifies the end of an entity. The document entity has * the pseudo-name of "[xml]" the DTD has the pseudo-name of "[dtd]" * parameter entity names start with '%'; and general entities are just * specified by their name. * * @param name The name of the entity. * ...
This method notifies the end of an entity. The document entity has the pseudo-name of "[xml]" the DTD has the pseudo-name of "[dtd]" parameter entity names start with '%'; and general entities are just specified by their name
endEntity
{ "repo_name": "openjdk/jdk7u", "path": "jaxp/src/com/sun/org/apache/xerces/internal/impl/XMLScanner.java", "license": "gpl-2.0", "size": 61515 }
[ "com.sun.org.apache.xerces.internal.xni.Augmentations", "com.sun.org.apache.xerces.internal.xni.XNIException", "java.io.IOException" ]
import com.sun.org.apache.xerces.internal.xni.Augmentations; import com.sun.org.apache.xerces.internal.xni.XNIException; import java.io.IOException;
import com.sun.org.apache.xerces.internal.xni.*; import java.io.*;
[ "com.sun.org", "java.io" ]
com.sun.org; java.io;
1,084,408
@Test public void testMissingUrl() { String missingContentUrl = FileContentStore.createNewFileStoreUrl(); ContentReader reader = routingStore.getReader(missingContentUrl); assertNotNull("Missing URL should not return null", reader); assertFalse("Empty reader s...
void function() { String missingContentUrl = FileContentStore.createNewFileStoreUrl(); ContentReader reader = routingStore.getReader(missingContentUrl); assertNotNull(STR, reader); assertFalse(STR, reader.exists()); try { reader.getContentString(); fail(STR); } catch (Throwable e) { } }
/** * Checks that requests for missing content URLs are served. */
Checks that requests for missing content URLs are served
testMissingUrl
{ "repo_name": "Alfresco/community-edition", "path": "projects/repository/source/test-java/org/alfresco/repo/content/RoutingContentStoreTest.java", "license": "lgpl-3.0", "size": 8929 }
[ "org.alfresco.repo.content.filestore.FileContentStore", "org.alfresco.service.cmr.repository.ContentReader", "org.junit.Assert" ]
import org.alfresco.repo.content.filestore.FileContentStore; import org.alfresco.service.cmr.repository.ContentReader; import org.junit.Assert;
import org.alfresco.repo.content.filestore.*; import org.alfresco.service.cmr.repository.*; import org.junit.*;
[ "org.alfresco.repo", "org.alfresco.service", "org.junit" ]
org.alfresco.repo; org.alfresco.service; org.junit;
2,574,109
public static EventImpacts determineEventImpact() { IViewPart activePart = getActiveViewPart(); if(activePart instanceof ChainView) { int index = ((ChainView)activePart).eventsTabFolder. getSelectionIndex(); switch(index) { case 1: return EventImpacts.REDO; case 2: return EventImpacts.BREAK; ...
static EventImpacts function() { IViewPart activePart = getActiveViewPart(); if(activePart instanceof ChainView) { int index = ((ChainView)activePart).eventsTabFolder. getSelectionIndex(); switch(index) { case 1: return EventImpacts.REDO; case 2: return EventImpacts.BREAK; case 3: return EventImpacts.STOP; } } else if(...
/** * Returns the event impact (as in * {@link de.ptb.epics.eve.data.EventImpacts}) if the active part is a * {@link org.eclipse.ui.IViewPart} or <code>null</code>. * * @return the event impact if active part is a * {@link org.eclipse.ui.IViewPart}, <code>null</code> otherwise */
Returns the event impact (as in <code>de.ptb.epics.eve.data.EventImpacts</code>) if the active part is a <code>org.eclipse.ui.IViewPart</code> or <code>null</code>
determineEventImpact
{ "repo_name": "eveCSS/eveCSS", "path": "bundles/de.ptb.epics.eve.editor/src/de/ptb/epics/eve/editor/views/eventcomposite/EventMenuContributionHelper.java", "license": "epl-1.0", "size": 2134 }
[ "de.ptb.epics.eve.data.EventImpacts", "de.ptb.epics.eve.editor.views.chainview.ChainView", "de.ptb.epics.eve.editor.views.detectorchannelview.ui.DetectorChannelView", "de.ptb.epics.eve.editor.views.scanmoduleview.ScanModuleView", "org.eclipse.ui.IViewPart" ]
import de.ptb.epics.eve.data.EventImpacts; import de.ptb.epics.eve.editor.views.chainview.ChainView; import de.ptb.epics.eve.editor.views.detectorchannelview.ui.DetectorChannelView; import de.ptb.epics.eve.editor.views.scanmoduleview.ScanModuleView; import org.eclipse.ui.IViewPart;
import de.ptb.epics.eve.data.*; import de.ptb.epics.eve.editor.views.chainview.*; import de.ptb.epics.eve.editor.views.detectorchannelview.ui.*; import de.ptb.epics.eve.editor.views.scanmoduleview.*; import org.eclipse.ui.*;
[ "de.ptb.epics", "org.eclipse.ui" ]
de.ptb.epics; org.eclipse.ui;
2,849,241
public List<String> getGroups(final String user) throws IOException { // No need to lookup for groups of static users Map<String, List<String>> staticUserToGroupsMap = staticMapRef.get(); if (staticUserToGroupsMap != null) { List<String> staticMapping = staticUserToGroupsMap.get(user); if (sta...
List<String> function(final String user) throws IOException { Map<String, List<String>> staticUserToGroupsMap = staticMapRef.get(); if (staticUserToGroupsMap != null) { List<String> staticMapping = staticUserToGroupsMap.get(user); if (staticMapping != null) { return staticMapping; } } if (isNegativeCacheEnabled()) { if...
/** * Get the group memberships of a given user. * If the user's group is not cached, this method may block. * @param user User's name * @return the group memberships of the user * @throws IOException if user does not exist */
Get the group memberships of a given user. If the user's group is not cached, this method may block
getGroups
{ "repo_name": "plusplusjiajia/hadoop", "path": "hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/Groups.java", "license": "apache-2.0", "size": 16342 }
[ "java.io.IOException", "java.util.List", "java.util.Map", "java.util.concurrent.ExecutionException" ]
import java.io.IOException; import java.util.List; import java.util.Map; import java.util.concurrent.ExecutionException;
import java.io.*; import java.util.*; import java.util.concurrent.*;
[ "java.io", "java.util" ]
java.io; java.util;
1,959,474
public final boolean sameSenders(Digest other) { Address a1, a2; if (other == null) { return false; } if (this.senders == null || other.senders == null) { return false; } if (this.senders.length != other.senders.length) ...
final boolean function(Digest other) { Address a1, a2; if (other == null) { return false; } if (this.senders == null other.senders == null) { return false; } if (this.senders.length != other.senders.length) { return false; } for (int i = 0; i < this.senders.length; i++) { a1 = this.senders[i]; a2 = other.senders[i]; if...
/** * Compares two digests and returns true if the senders are the same, otherwise false * * @param other * * @return * */
Compares two digests and returns true if the senders are the same, otherwise false
sameSenders
{ "repo_name": "joseananio/TayzGrid", "path": "src/tgcluster/src/com/alachisoft/tayzgrid/cluster/protocols/pbcast/Digest.java", "license": "apache-2.0", "size": 15007 }
[ "com.alachisoft.tayzgrid.common.net.Address" ]
import com.alachisoft.tayzgrid.common.net.Address;
import com.alachisoft.tayzgrid.common.net.*;
[ "com.alachisoft.tayzgrid" ]
com.alachisoft.tayzgrid;
2,016,129
@Override public boolean hasNature(FlexoConceptInstance flexoConceptInstance) { // The corresponding VirtualModel should have FMLControlledDiagramVirtualModelNature if (!flexoConceptInstance.getFlexoConcept().hasNature(FMLControlledFIBFlexoConceptNature.INSTANCE)) { return false; } FIBComponentModelSlo...
boolean function(FlexoConceptInstance flexoConceptInstance) { if (!flexoConceptInstance.getFlexoConcept().hasNature(FMLControlledFIBFlexoConceptNature.INSTANCE)) { return false; } FIBComponentModelSlot fibMS = flexoConceptInstance.getFlexoConcept().getDeclaredProperties(FIBComponentModelSlot.class).get(0); GINAFIBCompo...
/** * Return boolean indicating if supplied {@link FMLRTVirtualModelInstance} might be interpreted as a FML-controlled FIBComponent */
Return boolean indicating if supplied <code>FMLRTVirtualModelInstance</code> might be interpreted as a FML-controlled FIBComponent
hasNature
{ "repo_name": "openflexo-team/openflexo-technology-adapters", "path": "ginaconnector/src/main/java/org/openflexo/technologyadapter/gina/fml/FMLControlledFIBFlexoConceptInstanceNature.java", "license": "gpl-3.0", "size": 4300 }
[ "org.openflexo.foundation.fml.rt.FlexoConceptInstance", "org.openflexo.technologyadapter.gina.FIBComponentModelSlot", "org.openflexo.technologyadapter.gina.model.GINAFIBComponent" ]
import org.openflexo.foundation.fml.rt.FlexoConceptInstance; import org.openflexo.technologyadapter.gina.FIBComponentModelSlot; import org.openflexo.technologyadapter.gina.model.GINAFIBComponent;
import org.openflexo.foundation.fml.rt.*; import org.openflexo.technologyadapter.gina.*; import org.openflexo.technologyadapter.gina.model.*;
[ "org.openflexo.foundation", "org.openflexo.technologyadapter" ]
org.openflexo.foundation; org.openflexo.technologyadapter;
1,277,729
public JSType getJSTypeBeforeCast() { return (JSType) getProp(TYPE_BEFORE_CAST); }
JSType function() { return (JSType) getProp(TYPE_BEFORE_CAST); }
/** * Returns the type of this node before casting. This annotation will only exist on the first * child of a CAST node after type checking. */
Returns the type of this node before casting. This annotation will only exist on the first child of a CAST node after type checking
getJSTypeBeforeCast
{ "repo_name": "redforks/closure-compiler", "path": "src/com/google/javascript/rhino/Node.java", "license": "apache-2.0", "size": 85845 }
[ "com.google.javascript.rhino.jstype.JSType" ]
import com.google.javascript.rhino.jstype.JSType;
import com.google.javascript.rhino.jstype.*;
[ "com.google.javascript" ]
com.google.javascript;
2,684,166
public static ImmutableList<PathFragment> asSortedPathFragments(Iterable<Artifact> input) { return Streams.stream(input).map(Artifact::getExecPath).sorted().collect(toImmutableList()); }
static ImmutableList<PathFragment> function(Iterable<Artifact> input) { return Streams.stream(input).map(Artifact::getExecPath).sorted().collect(toImmutableList()); }
/** * Returns the exec paths of the input artifacts in alphabetical order. */
Returns the exec paths of the input artifacts in alphabetical order
asSortedPathFragments
{ "repo_name": "ulfjack/bazel", "path": "src/main/java/com/google/devtools/build/lib/actions/Artifact.java", "license": "apache-2.0", "size": 49613 }
[ "com.google.common.collect.ImmutableList", "com.google.common.collect.Streams", "com.google.devtools.build.lib.vfs.PathFragment" ]
import com.google.common.collect.ImmutableList; import com.google.common.collect.Streams; import com.google.devtools.build.lib.vfs.PathFragment;
import com.google.common.collect.*; import com.google.devtools.build.lib.vfs.*;
[ "com.google.common", "com.google.devtools" ]
com.google.common; com.google.devtools;
1,337,635
default ServerEndpointConsumerBuilder timeZone(TimeZone timeZone) { doSetProperty("timeZone", timeZone); return this; }
default ServerEndpointConsumerBuilder timeZone(TimeZone timeZone) { doSetProperty(STR, timeZone); return this; }
/** * The timezone to use. May be any Java time zone string. * * The option is a: <code>java.util.TimeZone</code> type. * * Group: data */
The timezone to use. May be any Java time zone string. The option is a: <code>java.util.TimeZone</code> type. Group: data
timeZone
{ "repo_name": "objectiser/camel", "path": "core/camel-endpointdsl/src/main/java/org/apache/camel/builder/endpoint/dsl/ServerEndpointBuilderFactory.java", "license": "apache-2.0", "size": 55707 }
[ "java.util.TimeZone" ]
import java.util.TimeZone;
import java.util.*;
[ "java.util" ]
java.util;
2,715,424
public ArrayList<Binding> getBindings() { return bindings; }
ArrayList<Binding> function() { return bindings; }
/** * Gets the bindings for the site * * @return The current bindings for this site */
Gets the bindings for the site
getBindings
{ "repo_name": "EdHurtig/jServe", "path": "src/jServe/Sites/Site.java", "license": "gpl-3.0", "size": 10889 }
[ "java.util.ArrayList" ]
import java.util.ArrayList;
import java.util.*;
[ "java.util" ]
java.util;
1,181,054
public void createAuthorizationForSelectedGroups(PublishedAssessmentData publishedAssessment) { AuthzQueriesFacadeAPI authz = PersistenceService.getInstance().getAuthzQueriesFacade(); String qualifierIdString = publishedAssessment.getPublishedAssessmentId().toString(); authz.createAuthorization(AgentFacade....
void function(PublishedAssessmentData publishedAssessment) { AuthzQueriesFacadeAPI authz = PersistenceService.getInstance().getAuthzQueriesFacade(); String qualifierIdString = publishedAssessment.getPublishedAssessmentId().toString(); authz.createAuthorization(AgentFacade.getCurrentSiteId(), STR, qualifierIdString); au...
/** * Creates Authorizations for Selected Groups * @param p */
Creates Authorizations for Selected Groups
createAuthorizationForSelectedGroups
{ "repo_name": "whumph/sakai", "path": "samigo/samigo-services/src/java/org/sakaiproject/tool/assessment/facade/PublishedAssessmentFacadeQueries.java", "license": "apache-2.0", "size": 130942 }
[ "java.util.Iterator", "java.util.List", "org.sakaiproject.tool.assessment.data.dao.assessment.PublishedAssessmentData", "org.sakaiproject.tool.assessment.data.dao.authz.AuthorizationData", "org.sakaiproject.tool.assessment.services.PersistenceService" ]
import java.util.Iterator; import java.util.List; import org.sakaiproject.tool.assessment.data.dao.assessment.PublishedAssessmentData; import org.sakaiproject.tool.assessment.data.dao.authz.AuthorizationData; import org.sakaiproject.tool.assessment.services.PersistenceService;
import java.util.*; import org.sakaiproject.tool.assessment.data.dao.assessment.*; import org.sakaiproject.tool.assessment.data.dao.authz.*; import org.sakaiproject.tool.assessment.services.*;
[ "java.util", "org.sakaiproject.tool" ]
java.util; org.sakaiproject.tool;
2,287,362
private View configureHeader(WrapperView wv, final int position) { View header = wv.mHeader == null ? popHeader() : wv.mHeader; header = mDelegate.getHeaderView(position, header, wv); if (header == null) { throw new NullPointerException("Header view must not be null."); } //if the header isn't clickable...
View function(WrapperView wv, final int position) { View header = wv.mHeader == null ? popHeader() : wv.mHeader; header = mDelegate.getHeaderView(position, header, wv); if (header == null) { throw new NullPointerException(STR); } header.setClickable(true); header.setOnClickListener(new OnClickListener() {
/** * Get a header view. This optionally pulls a header from the supplied * {@link WrapperView} and will also recycle the divider if it exists. */
Get a header view. This optionally pulls a header from the supplied <code>WrapperView</code> and will also recycle the divider if it exists
configureHeader
{ "repo_name": "cowthan/AyoWeibo", "path": "ayoview/src/main/java/org/ayo/view/listview/sticky/AdapterWrapper.java", "license": "apache-2.0", "size": 6001 }
[ "android.view.View" ]
import android.view.View;
import android.view.*;
[ "android.view" ]
android.view;
2,381,541
public Adapter createCopydataAdapter() { return null; }
Adapter function() { return null; }
/** * Creates a new adapter for an object of class '{@link org.etl.sparrow.Copydata <em>Copydata</em>}'. * <!-- begin-user-doc --> * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * <!-- end-use...
Creates a new adapter for an object of class '<code>org.etl.sparrow.Copydata Copydata</code>'. This default implementation returns null so that we can easily ignore cases; it's useful to ignore a case when inheritance will catch all the cases anyway.
createCopydataAdapter
{ "repo_name": "jpvelsamy/sparrow", "path": "org.etl.dsl.etl.Sparrow/src-gen/org/etl/sparrow/util/SparrowAdapterFactory.java", "license": "apache-2.0", "size": 17363 }
[ "org.eclipse.emf.common.notify.Adapter" ]
import org.eclipse.emf.common.notify.Adapter;
import org.eclipse.emf.common.notify.*;
[ "org.eclipse.emf" ]
org.eclipse.emf;
624,515
@Test public void testNumIntArrayInt() { // example from NIST SP 800-38G int[] X1 = { 0, 0, 0, 1, 1, 0, 1, 0 }; assertTrue(Common.num(X1, 5).compareTo(BigInteger.valueOf(755)) == 0); // null input try { Common.num(null, 10); fail(); } catch (Exception e) { assertTrue(e instanceof NullPointerEx...
void function() { int[] X1 = { 0, 0, 0, 1, 1, 0, 1, 0 }; assertTrue(Common.num(X1, 5).compareTo(BigInteger.valueOf(755)) == 0); try { Common.num(null, 10); fail(); } catch (Exception e) { assertTrue(e instanceof NullPointerException); } try { int[] X = {}; Common.num(X, 10); fail(); } catch (Exception e) { assertTrue(e...
/** * Test method for {@link org.fpe4j.Common#num(int[], int)}. */
Test method for <code>org.fpe4j.Common#num(int[], int)</code>
testNumIntArrayInt
{ "repo_name": "Minolan/JavaFPE", "path": "tests/CommonTest.java", "license": "apache-2.0", "size": 26065 }
[ "java.math.BigInteger", "org.junit.Assert" ]
import java.math.BigInteger; import org.junit.Assert;
import java.math.*; import org.junit.*;
[ "java.math", "org.junit" ]
java.math; org.junit;
680,727