query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
Returns a new object of class 'Int Change Action'. | IntChangeAction createIntChangeAction(); | [
"@Override\n public IncrementAction copy() {\n return copy(new IncrementAction());\n }",
"Action createAction();",
"CaseAction createCaseAction();",
"ActionState createActionState();",
"TurnAction createTurnAction();",
"public static PlayerAction convertIntToAction(int value) {\n\t\tswitch (value) {\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the amount of the excess space to feed back to lines thickness. | final float getLinesExcessSpaceFeedbackRatio() {
return linesExcessSpaceFeedbackRatio;
} | [
"double getRequiredSpaceAboveLine();",
"double getRequiredSpaceBelowLine();",
"public float getLineThickness() {\n // check for border style\n if (borderStyle != null) {\n return borderStyle.getStrokeWidth();\n }\n // check the border entry, will be solid or dashed\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the value of productVersionModified | public void setProductVersionModified(boolean productVersionModified)
{
this.productVersionModified = productVersionModified;
} | [
"public boolean isProductVersionModified()\n\t{\n\t\treturn productVersionModified;\n\t}",
"public void setProductKeyModified(boolean productKeyModified)\n\t{\n\t\tthis.productKeyModified = productKeyModified;\n\t}",
"void setProductVersion(java.lang.String productVersion);",
"void xsetProductVersion(amdocs.i... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new relationship between the two given cows. Only called if no previous relationships have occured between the two given cows. | public static void newRelation(@NotNull Cow firstCow, @NotNull Cow secondCow) {
firstCow.socialRelations.relations.add(secondCow.getId());
secondCow.socialRelations.relations.add(firstCow.getId());
firstCow.socialRelations.relationsValues.add(100);
secondCow.socialRelations.relationsValu... | [
"Relationship createRelationship();",
"void relationshipCreate( long id, int typeId, long startNodeId,\n long endNodeId );",
"public void CreateRelationship(Node node1, Node node2, myRelationships relation) {\r\n\t\tTransaction tx = _db.beginTx(); \r\n\t\ttry {\r\n\t\t\tnode1.createRelationshipTo(node2, ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Reads latest order item from the database | public List<Item> readLatestOrderItem() {
String query = "SELECT oi.id, i.name, i.value "
+ "FROM order_items oi "
+ "JOIN items i on oi.item_id = i.id "
+ "ORDER BY id DESC LIMIT 1;";
try (Connection connection = DBUtils.getInstance().getConnection();
Statement statement = connection.createStatemen... | [
"public Item readLatest() {\n\t\tItem item = new Item();\n\t\ttry (Statement statement = connection.createStatement();\n\t\t\t\tResultSet resultSet = statement.executeQuery(\"SELECT * FROM items ORDER BY id DESC LIMIT 1\");) {\n\t\t\tif (resultSet.next()) {\n\t\t\t\titem.setName(resultSet.getString(\"name\"));\n\t\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
public Map findHolidayEntity(String date); | public Map<String, Object> deleteHolidayById(Integer id); | [
"public Map<String, Object> getSeasonDataListByDates(String startDate, String endDate);",
"public String getHoliday() {\n return holiday;\n }",
"public interface IWeekendHolidayService {\r\n\r\n\t/**\r\n\t * Manages standard weekend holiday for specific currency\r\n\t * and returns the Next working if... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the type, which is 'person'. | public String getType() {
return "person";
} | [
"public PersonType GetPersonType()\n\t{\n\t\treturn this.pType;\n\t}",
"public String getPersonType() {\r\n return (String) getAttributeInternal(PERSONTYPE);\r\n }",
"public Integer getPersonType() {\r\n return personType;\r\n }",
"@Override\n public java.lang.String getPersonType() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__XBasicForLoopExpression__Group__8" $ANTLR start "rule__XBasicForLoopExpression__Group__8__Impl" InternalDroneScript.g:11717:1: rule__XBasicForLoopExpression__Group__8__Impl : ( ')' ) ; | public final void rule__XBasicForLoopExpression__Group__8__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalDroneScript.g:11721:1: ( ( ')' ) )
// InternalDroneScript.g:11722:1: ( ')' )
{
// Interna... | [
"public final void rule__XForLoopExpression__Group__6__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.guicemodules.ui/src-gen/org/xtext/guicemodules/ui/contentassist/antlr/internal/InternalGuiceModules.g:11639:1: ( ( ')'... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Retrieve the set of values that occur in matches for by. | public Set<Integer> getAllValuesOfby() {
return rawStreamAllValuesOfby(emptyArray()).collect(Collectors.toSet());
} | [
"public Set<Integer> getAllValuesOfby(final VehicleSlowsDownMeasurements.Match partialMatch) {\n return rawStreamAllValuesOfby(partialMatch.toArray()).collect(Collectors.toSet());\n }",
"public Set<V> values();",
"public static Set<Value> findAllValue(Set<Observation> data) {\n\t\t \n\t\t Set<Value> dat... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/////////////////////////////////////////////////////////////////// Function: adjustAngleOfShooter() /////////////////////////////////////////////////////////////////// Purpose: Used for adjusting the angle at which the ball shooter is firing. Uses sensor readings and some fancy physics to adjust it to the right angle ... | public void adjustAngleOfShooter() {
// Initial x and y values.
double x0 = 0.0;
double y0 = 0.0;
// Get the distance from the robot to the tower (the x value).
double xProxSensorDistance = sensors.proximitySensorDistance;
// Get the initial angle of the ball shooter.
... | [
"public void adjustShooterAngleManual() {\n\n // If the driver pushes the Square Button on the PS4 Controller,\n // set the worm drive motors to go backwards (lower it).\n if (PS4.getRawButton(PS4_X_BUTTON) == true) {\n\n wormDriveMotors.set(-0.2);\n\n // If the driver pus... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Remove (make 0) the element at the specified row and column. Throws an error if row/column combination is out of bounds. | public void removeElement(int row, int col){
//Check if matrix is out of bounds
if((col<0) || (col>=numCols) || (row<0) || (row>=numRows)){
throw new IndexOutOfBoundsException("Index of row or column is out of bounds!");
}
//Remove Element in linked list
else{
list.get(... | [
"public void removeNumber(int row, int col) {\n\t\tsudoku[row][col] = 0;\n\t}",
"void remove(int row, int column) {\n SparseArrayCompat<TObj> array = mData.get(row);\n if (array != null) {\n array.remove(column);\n }\n }",
"@Override\n\tpublic void unset(final int row, final i... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The method below returns the binary instructions of most of the Pep/8 mnemonics and elements. | public String getBinaryMnemonic(){
switch(this) {
case STOP -> {return "00000000";}
case RETTR -> {return "00000001";}
case MOVSPA -> {return "00000010";}
case MOVFLGA -> {return "00000011";}
case BR -> {return "0000010";}
case BRLE -> {return "0000011";}
case BRLT -> {return "0000100";... | [
"public Instruction[] getInstructions();",
"List<Instruction> allInstructions();",
"String getInstructions();",
"public String getInstructions();",
"public Instruction[] getInstructions(){\r\n\t\treturn instruction;\r\n\t}",
"public static String getMnemonic(int opCode){\n\n Map<String, Integer> op... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Auto Generated method for G2 Method GDLTASK::GDLDEANIMATE | public void gdlDeanimate(com.gensym.classes.UiClientItem arg1) throws G2AccessException
{
if (isByHandle()) {
java.lang.Object result;
java.lang.Object[] args = new java.lang.Object[] {this,arg1};
result = (java.lang.Object)callRPC(MethodName_GDL_DEANIMATE_, args);
}
else {
// No Me... | [
"AnimationData dijkstraANIMATION(String from);",
"public void animacionEntradaCeldasTaskList(final View viewGeneral, final View viewPanatalla,\n final TypewriterText textoTitulo, final String titulo, final TypewriterText textoFecha, final String fecha,\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
return null when there is not operator in the stack. | public Operator pop() {
if (operatorStack.isEmpty()) {
return null;
}
return operatorStack.pop();
} | [
"private void pushOperator(Operator operator)\n {\n LOGGER.debug(\"pushing operator '{}' onto operator stack\", operator);\n\n while (!operators_.isEmpty() && operators_.peek().precedes(operator))\n {\n LOGGER.debug(\"removing higher precedence operator from st... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Getter method to retrieve the sell side of this product book | private ProductBookSide getSellSide() {
return sellSide;
} | [
"private ProductBookSide getBuySide() {\n\t\treturn buySide;\n\t}",
"com.cantor.drop.aggregator.model.CFTrade.Side getSide();",
"public String getSellPoint() {\n return sellPoint;\n }",
"public java.lang.String getCrossSell() {\n return crossSell;\n }",
"public QuoteSide getQuoteSide(Boo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleFQN" $ANTLR start "entryRuleFQNWithWildcard" ../org.eclipse.eclipsecon.conference.ui/srcgen/org/eclipse/eclipsecon/ui/contentassist/antlr/internal/InternalConference.g:172:1: entryRuleFQNWithWildcard : ruleFQNWithWildcard EOF ; | public final void entryRuleFQNWithWildcard() throws RecognitionException {
try {
// ../org.eclipse.eclipsecon.conference.ui/src-gen/org/eclipse/eclipsecon/ui/contentassist/antlr/internal/InternalConference.g:173:1: ( ruleFQNWithWildcard EOF )
// ../org.eclipse.eclipsecon.conference.ui/sr... | [
"public final void entryRuleQualifiedNameWithWildcard() throws RecognitionException {\n try {\n // ../org.xtext.guicemodules.ui/src-gen/org/xtext/guicemodules/ui/contentassist/antlr/internal/InternalGuiceModules.g:2206:1: ( ruleQualifiedNameWithWildcard EOF )\n // ../org.xtext.guicemodu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns an unmodifiable view of the weight list. This list will not contain any duplicate weight records. | ObservableList<Weight> getWeightList(); | [
"public List<PD141137WeightListBean> getWeightList() {\n return weightList;\n }",
"private List<Weight> loadWeights() {\n return mWeightDb.getWeights();\n }",
"public int[] getWeight() {\r\n\t\treturn weight;\r\n\t}",
"public ButlerWeights getWeights() {\n\treturn currentWeights;\n }",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "Integer" $ANTLR start "Digits" | public final void mDigits() throws RecognitionException {
try {
// /Users/sidharth/Documents/code/phpparser/grammar/Php.g:528:2: ( ( '0' .. '9' )+ )
// /Users/sidharth/Documents/code/phpparser/grammar/Php.g:528:4: ( '0' .. '9' )+
{
// /Users/sidharth/Documents/cod... | [
"public final void mINTLITERAL() throws RecognitionException {\n try {\n int _type = INTLITERAL;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // /Users/ckbest83/Documents/workspace/Test/src/test/Test.g:248:12: ( ( DIGIT )+ )\n // /Users/ckbest83/Documents/workspace/Te... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Updates a schema with the indexes and fields on the server and creates the indexes and fields in the schema on the server side. This function does not delete indexes and the fields on the server side nor in the schema. | public void syncSchema(Schema schema) {
Span span = this.tracer.buildSpan("Client.SyncSchema").start();
try {
Schema serverSchema = readSchema();
// find out local - remote schema
Schema diffSchema = schema.diff(serverSchema);
// create the indexes and fi... | [
"public void updateTapSchema(SchemaConfig newSchema, boolean createOnly) throws ConfigurationException;",
"protected abstract int updateDatabaseSchema(int oldDbSchemaVersion);",
"private void createStatusUpdateSchema(JanusGraphManagement mgt) {\n log.info(\"Create {} schema\", STATUS_UPDATE);\n Ve... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
If no other interrupt is pending, or the new interrupt is of a higher priority, set the new interrupt as the pending interrupt. Any lowerpriority interrupt is dropped or ignored. | private void raiseInterrupt(
final MachineInterrupt interrupt
) {
if ((_pendingInterrupt == null)
|| (interrupt.getInterruptClass().getCode() < _pendingInterrupt.getInterruptClass().getCode())) {
_pendingInterrupt = interrupt;
}
} | [
"private void handleInterrupt(\n ) throws MachineInterrupt {\n // Get pending interrupt, save it to lastInterrupt, and clear pending.\n //???? are interrupts prevented? If so, do not handle a deferable interrupt\n MachineInterrupt interrupt = _pendingInterrupt;\n _pendingInterrupt = ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
string bank_name = 3; | java.lang.String getBankName(); | [
"java.lang.String getBankNo();",
"public String getBankname() {\n return bankname;\n }",
"public String getBankno() {\n return bankno;\n }",
"public java.lang.String getBank_name() {\n return bank_name;\n }",
"public String getBank() {\r\n return bank;\r\n }",
"publ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Determines if a two sets of namespace mappings differ. | private static boolean namespaceMappingsDiffer(IMXMLNamespaceMapping[] oldMappings, List<? extends IMXMLNamespaceMapping> newMappings)
{
if (oldMappings.length != newMappings.size())
return true;
int nMappings = oldMappings.length;
for (int i = 0; i < nMappings; ++i)
{
... | [
"public static boolean areMappingsDifferent(final List<Workspace.Mapping> mappings1, final List<Workspace.Mapping> mappings2) {\n if (mappings1 == mappings2) {\n // They are the same list (or both null)\n return false;\n }\n\n // Check for simple differences: one is null, ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Zip together two arrays to create a list of pairs. A mismatch in size will trucate. | public static <T1, T2> ArrayList<Pair<T1, T2>> zip(T1[] array1, T2[] array2){
ArrayList<Pair<T1, T2>> pairs = new ArrayList<>();
// Iterate over the first list
for(int i = 0; i < array1.length && i < array2.length; i++) {
// Bind it to the second array
pairs.add(new Pair... | [
"public static <T1,T2> ArrayList<Pair<T1,T2>> zipArrays(ArrayList<T1> first, ArrayList<T2> second) {\n if (first.size() == second.size()) {\n ArrayList<Pair<T1,T2>> output = new ArrayList<>(first.size());\n\n for (int i = 0; i < first.size(); i++) {\n Pair<T1,T2> pair = n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Annotates genes with GeneSymbol identifier. | public static void addGeneSymbol(GenomicSet<Gene> genes, HashMap<String, String> idToSymbol){
for (Gene g: genes.values()){
// check if GeneSymbol is available for this gene
if (idToSymbol.containsKey(g.getName())){
// set gene symbol
... | [
"int getGeneId();",
"protected String getGeneSymbol(Match m, String label)\n\t{\n\t\tProteinReference pr = (ProteinReference) m.get(label, getPattern());\n\t\treturn getGeneSymbol(pr);\n\t}",
"public String getGeneName() {\n return geneName;\n }",
"private void _parseGene() {\n\t\ttry {\n\t\t\t// a... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the value of the 'Body Condition' reference. If the meaning of the 'Body Condition' reference isn't clear, there really should be more of a description here... | Constraint getBodyCondition(); | [
"public String getCondition() {\n return condition;\n }",
"public java.lang.String getOnBody () {\n\t\treturn onBody;\n\t}",
"public String getRuleCondition() {\n return ruleCondition;\n }",
"cn.infinivision.dataforce.busybee.pb.meta.Expr getCondition();",
"public WeatherCondition getCon... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a random neighborhood fixing variables randomly | public static INeighbor random(IntVar... vars) {
return new RandomNeighborhood(vars, 3, 0);
} | [
"public ArrayList<PuzzleState> getRandomNeighbors() {\n\t\tArrayList<PuzzleState> ns = getNeighbors();\n\t\tCollections.shuffle(ns);\n\t\treturn ns;\t\n\t}",
"private void randomlySeed(Patch[][] grid, LinkedList<int[]> remainingSpace,\n int numberOfDaisies, Daisy.DaisyType type, doubl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method is called when the 'Point' button is clicked for TeamB. | public void addPointForTeamB(View view) {
pointScoreTeamB = pointScoreTeamB + 1;
displayPointForTeamB(pointScoreTeamB);
increaseTotalForTeamB(1);
} | [
"public void addPointTeamB(View view) {\n\n //Only add points for team B if they are the serving team\n if (servingTeam.equals(\"B\")) {\n scoreTeamB += POINT_VALUE;\n }\n\n //Update the score displayed\n displayForTeamB(scoreTeamB);\n }",
"public void twoPointB(Vi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calculate MIDI pitch based on frequency in Hertz. Middle C is 60.0. | public static double frequencyToPitch(double frequency) {
return CONCERT_A_PITCH + 12 * Math.log(frequency / mConcertAFrequency) / Math.log(2.0);
} | [
"float getPitch();",
"private void calPitch() {\n int index = midiValue % 12;\n this.pitchClass = PitchClass.readPitchClass(index);\n }",
"protected float getSoundPitch()\n {\n return 4.0F-3.0F * (float)this.getDinoAge()/(float)this.SelfType.MaxAge+this.rand.nextFloat()*0.2F;\n }",... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Método de acceso al campo tipoPertenencia. | public ValorDTO getTipoPertenencia() {
return tipoPertenencia;
} | [
"public void setTipoPertenencia(ValorDTO tipoPertenencia) {\n this.tipoPertenencia = tipoPertenencia;\n }",
"public void setTipo_articulo(String tipo_articulo) {\r\n this.tipo_articulo = tipo_articulo;\r\n }",
"public void setTipoContingencia(String tipoContingencia) {\n this.tipoCont... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
an interface to determine inventory holders. | public interface SmartHolder extends InventoryHolder {
/**
* obtains the contents.
*
* @return contents.
*/
@NotNull
InventoryContents getContents();
@Override
@NotNull
default Inventory getInventory() {
return this.getContents().getTopInventory();
}
/**
* obtains the page.
*
... | [
"Inventory getInventory();",
"Collection<Item> getInventory();",
"public interface ISustainedInventory {\n\n /**\n * Sets the inventory tag list to a new value.\n *\n * @param nbtTags - NBTTagList value to set\n * @param data - ItemStack parameter if using on item\n */\n void setInvent... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns public transport by profile id | @RequestMapping(method = RequestMethod.GET, value = "/profile/{id}")
public ResponseEntity<?> getPublicTransportWithProfileId(@PathVariable("id") String id) {
try {
return ResponseEntity.accepted()
.body(this.publicTransportRepository.findAll(getListaIdPublicTransportIterator(id)));
// ... | [
"@RequestMapping(method = RequestMethod.GET, value = \"/{id}\")\r\n public PublicTransport getById(@PathVariable(\"id\") String id) {\r\n return publicTransportRepository.findOne(id);\r\n }",
"@RequestMapping(method = RequestMethod.GET, value = \"/profile/{id}/page/{page}\")\r\n public ResponseEntity<?> get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Recover a take operation. If the original take was done under a transaction, and the transaction was prepared, txnId will be nonnull. | public void recoverTake(Uuid cookie, Long txnId) throws Exception; | [
"public void recoverTransaction(Long txnId, StoredObject transaction)\n\tthrows Exception;",
"public void recoverWrite(StoredResource entry, Long txnId)\n\tthrows Exception;",
"public void rollbackResume() throws TransactionException;",
"@Test\n public void testTaskRecovery1() {\n TezTaskID lastTaskId = g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
log the msg into independent log, when the parameter is invalid. | private void logInvalidMessage(String msg){
if (null != utilLog){
utilLog.error(msg);
}
else{
System.out.println(msg);
}
} | [
"static public void errorMessage(String msg) {\n final java.text.SimpleDateFormat fileTstamp =\n new java.text.SimpleDateFormat(\"yyyyMMdd'T'HHmmss_SSS'Z'Z\");\n String fileDest = \"/tmp/unravel_hive_hook_\"\n + fileTstamp.format(new Date()) + \".log\";\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calculate the frequent renter point for regular movie. | @Test
public void regularMovieGetFrequentRenterPointsTest() {
final int daysRented = 2;
final double actualResult = regular.calculateFrequentRenterPoints(daysRented);
final double expectedResult = 1;
assertEquals(expectedResult, actualResult, 0);
} | [
"public int calculateFrequentRenterPoints() {\n return movie.calculateFrequentRenterPoints(daysRented);\n }",
"private double getGenreScore(Movie movie) {\n double genreScore = 0;\n\n for (String genre : this.generes) {\n if (movie.getGenre().contains(genre)) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Callback called when new DHCP results are available. | public void onNewDhcpResults(DhcpResults dhcpResults) {
log("onNewDhcpResults({" + dhcpResults + "})");
try {
mCallback.onNewDhcpResults(toStableParcelable(dhcpResults));
} catch (RemoteException e) {
log("Failed to call onNewDhcpResults", e);
... | [
"public void discovery() {\n\t\tLOG.info(\"NAT: DhcpPacketHandler: discovery(): handling DHCP Discovery\");\n\n\t\tDhcpOption[] options = {\n\t\t\t\tnew DhcpOption(DhcpOption.MessageType.DISCOVER),\n\t\t\t\tnew DhcpOption(DhcpOption.Code.PARAM_REQ,\n\t\t\t\t\t\tnew DhcpOption.Code[] { DhcpOption.Code.SUBNET_MASK,\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Responsible to check the service is in outage level | public boolean isInOutage() {
return (getOutageStartBoundary() <= System.currentTimeMillis() && System.currentTimeMillis() <= getOutageEndBoundary());
} | [
"public boolean hasTakeOff();",
"boolean hasAccuConnTimeWithVpnOff();",
"@Override\r\n\tpublic boolean canTakeOut(int amount) {\r\n\t\treturn ((balance - amount) >= -200000);\r\n\t}",
"public boolean isEffective() {\r\n \r\n Calendar now = Calendar.getInstance();\r\n \r\n if(!from.matches(OUT_AGE_... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
optional .client.ControlBoardProfil Profil = 3; | com.obctech.growbe.proto.serre.SerreData.ControlBoardProfil getProfil(); | [
"com.obctech.growbe.proto.serre.SerreData.ControlBoardProfilOrBuilder getProfilOrBuilder();",
"com.obctech.growbe.proto.serre.SerreData.HubProfilOrBuilder getProfilOrBuilder();",
"com.obctech.growbe.proto.serre.SerreData.HubProfil getProfil();",
"public com.obctech.growbe.proto.serre.SerreData.ControlBoardPro... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the src port. | public int getSrcPort() {
return srcPort;
} | [
"public int getSrcPort() {\n\t\tlog.trace(\"Get srcPort, returns [{}]\", srcPort);\n\t\treturn srcPort;\n\t}",
"public java.lang.Integer getSrcPort() {\n return srcPort;\n }",
"public java.lang.Integer getSrcPort() {\n return srcPort;\n }",
"public int getSourcePort(){\r\n\t\treturn this.srcPort;\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method sets the value of the database column t_ctr_carte.carte_type_id | public void setCarteTypeId(String carteTypeId) {
this.carteTypeId = carteTypeId == null ? null : carteTypeId.trim();
} | [
"public String getCarteTypeId() {\n return carteTypeId;\n }",
"public void setIdType(Integer idType) {\n this.idType = idType;\n }",
"public void setIdType(String idType) {\r\n this.idType = idType;\r\n }",
"public void setIdType(String idType) {\n this.idType = idType;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Function_call_args__Group__2" $ANTLR start "rule__Function_call_args__Group__2__Impl" ../org.openmodelica.modelicaml.editor.xtext.modeleditor.ui/srcgen/org/openmodelica/modelicaml/editor/xtext/model/ui/contentassist/antlr/internal/InternalModeleditor.g:3710:1: rule__Function_call_args__Group__2__Impl ... | public final void rule__Function_call_args__Group__2__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../org.openmodelica.modelicaml.editor.xtext.modeleditor.ui/src-gen/org/openmodelica/modelicaml/editor/xtext/model/ui/contentassist/antlr/i... | [
"public final void rule__Function_call_args__Group__2() throws RecognitionException {\r\n\r\n \t\tint stackSize = keepStackSize();\r\n \r\n try {\r\n // ../org.openmodelica.modelicaml.editor.xtext.modeleditor.ui/src-gen/org/openmodelica/modelicaml/editor/xtext/model/ui/contentass... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "entryRuleVisualSectionOption" $ANTLR start "ruleVisualSectionOption" ../org.xtext.hipie/srcgen/org/xtext/hipie/parser/antlr/internal/InternalHIPIE.g:4267:1: ruleVisualSectionOption returns [EObject current=null] : ( ( (lv_name_0_0= 'LABEL' ) ) otherlv_1= '(' ( (lv_vals_2_0= ruleValue ) ) otherlv_3= ')' ) ; | public final EObject ruleVisualSectionOption() throws RecognitionException {
EObject current = null;
Token lv_name_0_0=null;
Token otherlv_1=null;
Token otherlv_3=null;
EObject lv_vals_2_0 = null;
enterRule();
try {
// ../org.xtext.hi... | [
"public final EObject ruleVisualSectionOptions() throws RecognitionException {\n EObject current = null;\n\n Token otherlv_0=null;\n Token otherlv_2=null;\n EObject lv_vis_ops_1_0 = null;\n\n EObject lv_vis_ops_3_0 = null;\n\n\n enterRule(); \n \n try {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
viewMP3 method, asks the view to display the View MP3 banner and gets the title from the user. Then it asks the DAO for the MP3s associated with the title. finally it asks the view to display the MP3 info | private void createMP3() throws MP3DaoException{
view.displayAddMP3Banner();
MP3 newMP3 = view.getNewMP3Info();
dao.addMP3(newMP3.getTitle(), newMP3);
view.displayCreateSuccessBanner();
} | [
"private void displayMP3Tags() //throws IOException\r\n {\n \r\n ID3TagSet tagSet = selectedLesson.getID3Tags(); \r\n \r\n if (tagSet == null)\r\n {\r\n\t Debug.debug(\"LessonManagerControl.displayMP3Tags() - No id3 metadata found.\");\r\n statusPanel.printStatusLine(\"No ID3 tags... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Picking is only allowed when the game is in state PLAYING. So, in the test, try to pick cards when the game is in another state (e.g. OPEN), and expect some exception (create that exception class). | @Test(expected = NotPlayingException.class)
public void not_allow_picking_cards_if_not_playing(){
Deck deck = new Deck();
Game game = new Game(deck);
game.join("susan");
game.pickCard("susan");
} | [
"@Test(expected = DidNotPickCardException.class)\n public void allow_discard_only_if_picked_before(){\n\n Deck deck = new Deck();\n deck.add(new Card(3,2,5));\n Game game = new Game(deck);\n\n game.join(\"susan\");\n game.join(\"peter\");\n\n game.discard(\"susan\");\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Generate the list of News by extracting JSON response | private static List<News> extractFeaturesFromJsonResponse(String jsonResponse) {
List<News> newsList = new ArrayList<>();
try {
JSONObject baseJsonObject = new JSONObject(jsonResponse);
// If JSON object does not contain "response" return null object
if (!baseJsonObj... | [
"private static List<News> parseJsonResponse(String jsonResponse) {\n List<News> newsList = new ArrayList<>();\n\n if (jsonResponse != null && !jsonResponse.isEmpty()) {\n try {\n JSONObject rootJson = new JSONObject(jsonResponse);\n JSONObject responseJson = r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method returns the value of the database column t_agency.leaf | public String getLeaf() {
return leaf;
} | [
"public String getIs_leaf() {\r\n\t\treturn is_leaf;\r\n\t}",
"public Integer getLeaf() {\n return leaf;\n }",
"public String getLeaf() {\n if (isRootPath())\n return \"/\";\n return absolutePath.substring(absolutePath.lastIndexOf('/') + 1);\n }",
"public BigDecimal getLe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets measurement information in measurementInfo section | private void setMeasurementInfo(){
Measurement measurement = watch.getMeasurement();
Label label;
if(measurement == null || measurement.size() <= 0){
label = new Label("No measurement active.");
measurementLabels.getChildren().add(label);
return;
}
... | [
"void setMeasurement(Measurement m);",
"private void setInfo(){\n setStorageInfo();\n setBatteryInfo();\n setWatchInfo();\n setMeasurementInfo();\n }",
"public static void setMeasurements(int measurements) {\n systemMeasurements = measurements;\n }",
"public void setMe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the uses of the tactical equipment | public int getUses() {
return statUse.getDenominator();
} | [
"public EquipmentUsage getEquipmentUsage() { return equipmentUsage; }",
"public ArrayList<String> getUsedTreatements()\n {\n return usedTreatments;\n }",
"public BitSet getTechUsages() {\n BitSet bs = new BitSet(techs.length);\n for (int techIndex = 0; techIndex < techs.length; tech... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the current shading setting, true for Phong shading or false for flat shading. | public boolean getPhongShading() {
return phongShading;
} | [
"public boolean getSheared() {\n return (this.dataManager.get(DYE_COLOR) & 16) != 0;\n }",
"public boolean isGlowing() {\r\n return isGlowing;\r\n }",
"boolean getLightOn();",
"public boolean isGlow() {\n return glow;\n }",
"public boolean isShadesVisible() {\r\n return ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Back is pressed, go to page activity page | @Override
public void onBackPressed() {
cleanup();
finish();
goToPageActivity();
} | [
"private void backPage() {\n Intent intent = new Intent(this, HelpPage.class);\n startActivity(intent);\n }",
"public void goBack() {\n MainController.display(AppScreen.HOME);\n }",
"@Override\n\tpublic void onBackPressed() {\n\t\tfinish();\n\t\tgoToEditPage();\n\t}",
"void onBackBu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
required int32 nextLevelGold = 2; | public int getNextLevelGold() {
return nextLevelGold_;
} | [
"int getNextLevelGold();",
"public int getNextLevelGold() {\n return nextLevelGold_;\n }",
"int getMaxStartingGold();",
"public Builder setNextLevelGold(int value) {\n bitField0_ |= 0x00000002;\n nextLevelGold_ = value;\n \n return this;\n }",
"int ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__BodyRepetition__Group__3" $ANTLR start "rule__BodyRepetition__Group__3__Impl" ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/srcgen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:4412:1: rule__BodyRepetition__Group__3__Impl : ( ( rule__BodyRepetition__BodyAssignment_3 ) ) ; | public final void rule__BodyRepetition__Group__3__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/src-gen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:4416:1: ( ( ( rule__... | [
"public final void rule__BodyRepetition__Group__3() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../uk.ac.kcl.inf.robotics.rigid_bodies.ui/src-gen/uk/ac/kcl/inf/robotics/ui/contentassist/antlr/internal/InternalRigidBodies.g:4404:1: ( rule... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Run arm pivot no PID. | public void doArm() {
if (driverControl.getLeftButton2()){
arm.setArmPivotForward(0.5);
} else if (driverControl.getLeftButton3()){
arm.setArmPivotBackward(0.5);
} else {
arm.stopArmPivot();
}
} | [
"protected ExecutionResult runOnRealDevice(ConsoleView console) throws ExecutionException {\n VirtualFile copiedPrg = copyBuiltPrgToDevice();\n\n String message = String.format(\"Generated %s\\nYou can now start the app on your device.\", copiedPrg);\n console.print(message, ConsoleViewContentType.NORMAL_O... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new job file input vertex. | public JobFileOutputVertex(final JobGraph jobGraph) {
super(null, null, jobGraph);
} | [
"Vertex createVertex();",
"public JobFileOutputVertex(final String name, final JobGraph jobGraph) {\n\t\tsuper(name, null, jobGraph);\n\t}",
"public JobFileOutputVertex(final String name, final JobVertexID id, final JobGraph jobGraph) {\n\t\tsuper(name, id, jobGraph);\n\t}",
"private void createInputFile(Stri... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor: Used to instantiate the FriendsRecyclerViewAdapter | public FriendsRecyclerViewAdapter(ArrayList<AccountInfoDocument> dataItems) {
this.dataItems = dataItems;
} | [
"private void setupMemberRecycler() {\n\t\tRecyclerView memberRecycler = findViewById(R.id.memberRecycler);\n\n\t\t// Keep reference of the dataset (arraylist here) in the adapter\n\t\tmemberRecyclerAdapter = new MemberRecyclerAdapter(this, entity.getMembers());\n\t\tmemberRecyclerAdapter.registerAdapterDataObserve... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This test makes sure that cached policy evaluation results are properly invalidated for a resource and its descendants, when attributes are changed for the parent resource. | @Test
public void testPolicyEvalCacheInvalidationWhenResourceParentChanges() throws Exception {
BaseResource grandparentResource = new BaseResource("/secured-by-value/sites/east-bay");
BaseResource parentResource = new BaseResource("/secured-by-value/sites/sanramon");
BaseResource childResou... | [
"@Test\n public void testPolicyEvalCacheInvalidationWhenSubjectParentChanges() throws Exception {\n BaseSubject fbi = new BaseSubject(this.FBI);\n\n BaseSubject specialAgentsGroup = new BaseSubject(this.SPECIAL_AGENTS_GROUP);\n specialAgentsGroup\n .setParents(new HashSet<>(Ar... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the lineCoverages value for this AvailableCoveragesPADTO. | public com.guidewire.pc.webservices.entity.CoverageDTO[] getLineCoverages() {
return lineCoverages;
} | [
"@gw.internal.gosu.parser.ExtendedProperty\n public entity.GL7SublineTypeCov[] getCoverages();",
"public void setLineCoverages(com.guidewire.pc.webservices.entity.CoverageDTO[] lineCoverages) {\n this.lineCoverages = lineCoverages;\n }",
"@gw.internal.gosu.parser.ExtendedProperty\n public entity.GL7... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
ogWidth = original width | public double getOgWidth() {
return ogWidth;
} | [
"public int getWidth() { return width; }",
"int getWidth() { return width; }",
"Integer getCurrentWidth();",
"private void setWidth( int w )\n {\n this.width = w; //set the width\n }",
"public void setWidth(int w) { fWidth = w; }",
"public int GetWidth() {\n return DEFAULT_WIDTH;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Increment a counter corresponding to a particular reasons for attempting to connect via a push. | void increment(PushReason reason); | [
"private void incrConnectionCount() {\n connectionCount.inc();\n }",
"public void incrementRetryCount() {\n this.retryCount++;\n }",
"int addAndGetRetryCount();",
"public void incrementFailedCount() {\n ++failedCount;\n }",
"public void incrementErrorCounter(int increment) {\n error... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Utility method to help check and cast if a given storage is of the given type. It does not check generic types for the storage. | @SuppressWarnings("unchecked")
static <V extends Serializable, S extends StorageManager> S checkType(StorageManager<V> storage, Class<S> klazz) {
Objects.requireNonNull(klazz);
if (!klazz.isInstance(storage)) {
String name = storage == null ? "null" : storage.getClass().getName();
... | [
"protected abstract boolean isDatastoreType(Object o);",
"public abstract boolean convertStorageDescriptor(StorageDescriptor sd);",
"public void testgetType_0(){\r\n\t\tDatabase b = new Database();\r\n\t\tassertTrue(b.storage.getType().contains(\"freezer\"));\r\n\t}",
"boolean isActive(Storage<?> storage);",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the version of mobility if it exists, 1 otherwise | public static int getMobilityVersion(Context context) {
PackageInfo info = getMobilityPackageInfo(context);
if (info != null)
return info.versionCode;
return -1;
} | [
"public int getMobilityFlag()\n\t {\n\t return 1;\n\t }",
"@Override\n\tpublic int getMobilityFlag() {\n\t\treturn 2;\n\t}",
"public static boolean isMobilityInstalled(Context context) {\n return getMobilityPackageInfo(context) != null;\n }",
"private static PackageInfo getMobilityPacka... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
builder factory method for Attributes | public static AttributesBuilder builder() {
return AttributesBuilder.of();
} | [
"public Builder attributes(Attributes attributes);",
"Attribute createAttribute();",
"private CATTRIBUTE(Builder builder) {\n super(builder);\n }",
"AttributeDefinition createAttributeDefinition();",
"protected abstract void createAttributes();",
"private CSINGLEATTRIBUTE(Builder builder) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the 'Math Operator' literal with the specified literal value. | public static MathOperator get(String literal)
{
for (int i = 0; i < VALUES_ARRAY.length; ++i)
{
MathOperator result = VALUES_ARRAY[i];
if (result.toString().equals(literal))
{
return result;
}
}
return null;
} | [
"public String getArithmeticOperator() {\n return (String)getAttributeInternal(ARITHMETICOPERATOR);\n }",
"public void setArithmeticOperator(String value) {\n setAttributeInternal(ARITHMETICOPERATOR, value);\n }",
"abstract public MathValue createMathValue(String s, ArithmeticMode mode);",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create necessary action handlers | private void setActionHandlers() {
//Set OnPlaceSelectedActionHandler to fill all location details editText
setPlaceSelectedActionHandler();
//Set startDateBtn Action Handler
setDatePickerBtnAction(startDateBtn, startDateEditText);
setDateEditTextAutoFormat(startDateEditText);
... | [
"protected void createRemoteActions(RemoteHandler remoteHandler) {\n }",
"private void createActions()\r\n {\n actions.put(ActionFactory.DELETE.getId(), new DeleteAction());\r\n actions.put(ActionFactory.REDO.getId(), new RedoAction());\r\n actions.put(ActionFactory.UNDO.getId(), new ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Default constructor (protected; use intToEnumeratedValue to obtain enumerated values from integers.) | protected SchemaEnum( int __n ) { __Ezj_value = __n; } | [
"private LanguagesEnum(Integer languagesEnumValue)\r\n\t{\r\n\r\n\t\tlanguagesEnum = languagesEnumValue;\r\n\r\n\t}",
"private ListEnum(int listEnum) \n {\n // The constructor sets the values for each enumeration.\n this.listEnum = listEnum;\n }",
"public Int() {\n this(0)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
VERIFY SESSION 1 HEADING | public void verifySessionOneHeading(){
String actualSessionHeading = driver.findElement(By.xpath(sessionHeadingXpathLocator)).getText();
Assert.assertTrue(actualSessionHeading.contains(expectedSessionHeading),"Session Heading is present.");
} | [
"void SessionChecks(SessionState api_session, String uri, String content);",
"public boolean verify_errorPageOn_CreateAccount() {\n\t\tboolean value = false;\n\n\t\tString title = element(\"ProgressTitle\").getText();\n\t\tSystem.out.println(title);\n\t\tif (title.contains(\"Absher Verification\")) {\n\t\t\tSyste... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Obtains the sinks for a given host for a given Multicast route. | Set<ConnectPoint> sinksFor(McastRoute route, HostId hostId); | [
"Set<ConnectPoint> sinksFor(McastRoute route);",
"void addSink(McastRoute route, HostId hostId, Set<ConnectPoint> sinks);",
"void addSinks(McastRoute route, Set<ConnectPoint> sinks);",
"public List<String> getProcessSinks(String param1) throws CallError, InterruptedException {\n return (List<String>) s... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Interpret duplicates for putNoOverwrite operation. The main purpose of this method is to guarantee that when two threads call putNoOverwrite concurrently, only one of them will succeed. In other words, if putNoOverwrite is called for all dup insertions, there will always be at most one dup per key. Next key locking mus... | private OperationStatus dupsPutNoOverwrite(final DatabaseEntry key,
final DatabaseEntry data) {
final DatabaseEntry key2 = new DatabaseEntry();
final DatabaseEntry data2 = new DatabaseEntry();
final Cursor c = dup(false /*samePosition*/);
t... | [
"private OperationStatus dupsPutOverwrite(final DatabaseEntry key,\n final DatabaseEntry data) {\n final DatabaseEntry twoPartKey = DupKeyData.combine(key, data);\n return putNoDups(twoPartKey, EMPTY_DUP_DATA, PutMode.OVERWRITE);\n }",
"private Operatio... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Recupera el usuario del Crawler para insertar datos | private void setUser() {
try {
user = usersDao.leerUsuario("crawler", "crawler");
} catch (SQLException e) {
e.printStackTrace();
}
} | [
"public void buscarUsuario() {\n\n //se pide el identificador del correo o cedula\n String id = vistaU.pedirIdentificador();\n\n //recibir un usuario mandando el id\n usuario2 = usuarioDaoImpl.read(id);\n if (usuario2 != null) {\n\n //imprime el usuario\n vis... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Records Cancel of an Order in the Book | public void recordCancel(OrderInternal order_, String cancellationCommentLanguageKey_, OrderManagementContext orderManagementContext_); | [
"public void cancelOrder() {\r\n\r\n\t}",
"void cancelOrder(String orderKey);",
"CancelOrderResponse cancelOrder(CancelOrderRequest cancelOrderRequest);",
"ContractOrderResult cancelContractOrder(CancelContractOrderRequest cancelOrderRequest);",
"BatchCancelOrderResult batchCancelContractOrder(BatchCancelOr... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get a list of Codes belonging to a Code System via a supplied OID. | public List<CdsCodeDTO> getCodeDTOsByOid(String oid) {
final String METHODNAME = "getCodeDTOsByOid ";
List<CdsCodeDTO> result = new ArrayList<CdsCodeDTO>();
CdsCodeSystemDTO cdsCodeSystemDTO = getCdsCodeSystemDTOByOid(oid);
if (cdsCodeSystemDTO != null) {
result = cdsCodeSyst... | [
"public CdsCodeSystemDTO getCdsCodeSystemDTOByOid(String oid) {\n final String METHODNAME = \"getCdsCodeSystemDTOByOid \";\n CdsCodeSystemDTO result = null;\n if (oid != null && !oid.trim().isEmpty()) {\n for (CdsCodeSystemDTO item : getAll()) {\n if (oid.trim().equals... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Exit ShopActivity when the shopExitButton is clicked. | private void shopExitButtonClicked() {
finish();
} | [
"public void onExit() {\n Intent homeIntent = new Intent(Intent.ACTION_MAIN);\n homeIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n homeIntent.addCategory(Intent.CATEGORY_HOME);\n startActivity(homeIntent);\n finish();\n }",
"public void finishShop(ShopWindow shop) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new instance of DummyWizardPage. | protected DummyWizardPage()
{
super( "" ); //$NON-NLS-1$
setTitle( Messages.getString( "NewEntryWizard.NoConnectonSelected" ) ); //$NON-NLS-1$
setDescription( Messages.getString( "NewEntryWizard.NoConnectonSelectedDescription" ) ); //$NON-NLS-1$
setImageDescriptor... | [
"public NewTestWizardPage() {\n\t\tsuper(true, \"New Groovy Test Settings\");\n\n\t\tsetTitle(\"Groovy Test Class\");\n\t\tsetDescription(\"Create a new Groovy unit test class\");\n\t}",
"public void testGenericWizards() {\n // open new project wizard\n NewProjectWizardOperator npwo = NewProjectWiza... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns all rows from the emergencia_credito_factura_realizada table that match the criteria 'ID_EMERGENCIA = :idEmergencia'. | public EmergenciaCreditoFacturaRealizada[] findWhereIdEmergenciaEquals(int idEmergencia) throws EmergenciaCreditoFacturaRealizadaDaoException; | [
"public EmergenciaCreditoFacturaRealizada[] findWhereIdEmergenciaCreditoEquals(int idEmergenciaCredito) throws EmergenciaCreditoFacturaRealizadaDaoException;",
"public EmergenciaCreditoFacturaRealizada findByPrimaryKey(int idEmergenciaCredito) throws EmergenciaCreditoFacturaRealizadaDaoException;",
"public Emer... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Print the student solution | private void printStudentSolution(ArrayList<Student> studs) {
System.out.println("Solution Format: 3");
System.out.println("Objective Function: " + Objective.getDescription());
System.out.println("Class Info: " + fileIO.getClassDesc());
System.out.println("Student Info: " + fileIO.getStudentDesc());
System.o... | [
"public void printSolution(){\n\t\tSystem.out.print(toString());\n\t}",
"public void printSolution(){}",
"public void printSolution() {\r\n System.out.println(\"Best value: \" + bestSoFar);\r\n System.out.println(\"Best weight: \" + bestWeight);\r\n System.out.println(\"Vector:\");\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check the presence of SetupName field in Define Setup page | public boolean visible_SetupNameField() {
return IsElementVisibleStatus(DefineSetup_SetupName_txtBx);
} | [
"public String get_defineSetupPage_setupName() {\r\n\t\treturn FetchText(DefineSetup_SetupName_txtBx);\r\n\t}",
"public boolean isSetSetupID()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().find_attribute_user(SETUPI... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Delete an image Delete a firmware image. | @DELETE("v3/firmware-images/{image_id}/")
Call<Void> firmwareImageDestroy(@retrofit2.http.Path(value = "image_id", encoded = true) String imageId); | [
"public void deleteImage(Image image) {\n library.delete(image);\n }",
"public void deleteImage(){\n\n this.masterCoderImage.delete();\n\n }",
"public void deleteImage(Integer imageId) {\n imageRepository.deleteImage(imageId);\n }",
"private void deleteImage(Image image){\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructs a card number. | CardNumber(int number) {
this.number = number;
} | [
"public CardNumber(Integer cardNumber) {\n this.cardNumber = cardNumber;\n }",
"private NumericCard (Color color, int number)\n {\n super(color);\n this.number = number;\n }",
"private String generateCardNumber() {\n //generate random 4-digit sequence four times\n String cN... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a free port number on localhost, or throw runtime exception if unable to find a free port. | public static int findFreePort() {
try (ServerSocket socket = new ServerSocket(0)) {
return socket.getLocalPort();
} catch (IOException e) {
}
throw new RuntimeException("no available ports.");
} | [
"private int findFreePort() {\n\t int port = 0;\n\n\t try {\n\t\tServerSocket socket = new ServerSocket(0);\n\t\tport = socket.getLocalPort();\n\t\tsocket.close();\n\t } catch(IOException e) {\n\t\te.printStackTrace();\n\t }\n\n\t return port;\n\t}",
"protected int findFreePort() {\n\t\tjava.net.Se... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Validates link settings on account | AccountSettings validateLinkSettings(AccountSettings accountSettings); | [
"@Test (priority =28)\n\tpublic void verifyAccountURL() {\n\t\tCreateAccountPage home = new CreateAccountPage(driver);\n\t\tAssert.assertEquals(home.getAccountURL(), \"http://automationpractice.com/index.php?controller=my-account\", \"User is not on correct page\");;\n\t}",
"public void verify_Billing_hyperlink_S... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
if the table is empty, end the tree with the default answer... | @Override
public <Q, A, T> @NotNull Node<Q, A> branch(
@NotNull DataTable table,
@NotNull String resultsKey,
@NotNull Set<T> successVals,
@NotNull Function<String, Q> toQuestionFunc,
@NotNull Map<String, Func... | [
"public void postOrder() {\n if(this.root==null){\n System.out.println(\"tree is empty\");\n }else {\n this.postOrder(this.root);\n }\n }",
"public boolean fillEmptyTable() {\n if(isEmpty()) {\n System.err.println(\"The queue is empty! All of the walk-ins... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return a list of the authentication types that the RPC authenticator implementation supports. The authentication types are specified in the AuthType class. | public int[] getRpcAuthenticationTypes(); | [
"public int[] getRpcAuthenticationTypes() {\n return _authTypes;\n }",
"String[] getSupportedCredentialTypes();",
"@Override\n public List<AuthorizationType> getAuthorizationTypes() {\n ArrayList<AuthorizationType> fakeTypes = new ArrayList<>();\n fakeTypes.add(\n new Authori... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the current position in the InputStream, as an offset from the beginning of the InputStream. | public long getPosition() {
if (in == null)
throw new RuntimeException("Stream closed");
return bufpos + pos - start;
} | [
"@Override\n public long getPosition() throws IOException {\n if (lzopIn_ != null) {\n return start_ + lzopIn_.getCompressedBytesRead();\n } else {\n return super.getPosition();\n }\n }",
"@Override\n\tpublic long getPosition()\n\t{\n\t\treturn inputStream.Position;\n\t}",
"public long getP... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create a scoped classloader domain | public ClassLoaderDomain createScopedClassLoaderDomain(String name, ParentPolicy parentPolicy, Loader parent)
{
ClassLoaderSystem system = getSystem();
return system.createAndRegisterDomain(name, parentPolicy, parent);
} | [
"public ClassLoaderDomain createScopedClassLoaderDomain(String name, ParentPolicy parentPolicy)\n {\n return createScopedClassLoaderDomain(name, parentPolicy, getDomain());\n }",
"private WebappClassLoader createClassLoader()\n throws Exception {\n \t\n \tClass clazz = Class.forName(loaderCl... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the number of l m s leave informations where LeaveRequestId = &63;. | @Override
public int countByLeaveRequestId(String LeaveRequestId)
throws SystemException {
FinderPath finderPath = FINDER_PATH_COUNT_BY_LEAVEREQUESTID;
Object[] finderArgs = new Object[] { LeaveRequestId };
Long count = (Long)FinderCacheUtil.getResult(finderPath, finderArgs,
this);
if (count == null) ... | [
"@Override\n\tpublic LMSLeaveInformation fetchByLeaveRequestId(String LeaveRequestId)\n\t\tthrows SystemException {\n\t\treturn fetchByLeaveRequestId(LeaveRequestId, true);\n\t}",
"public final int getLeaveId() {\n\n return leaveId;\n }",
"@Override\n\tpublic LMSLeaveInformation fetchByLeaveRequestId(Strin... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
====================== saveData Stuff ====================================== Add a scan to the list of tags | private void addScan(String tag) {
SaveData.add(new Scan(tag, currentLocation));
} | [
"private void writeScanData() throws IOException {\n ReadWrite.writeOut(saveData, getApplicationContext());\n }",
"private void saveTags() {\n SavedFolders.editFolder(this.folder);\n }",
"List<Tag> saveTags(String tags);",
"public void saveBookings(ArrayList<String> saveBookingData)\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Wraps the given array in an array wrapper | public static <T> Vector<T> wrap(T[] array) {
return new Vector<>(array);
} | [
"public static Int32Array1D wrap(Int32Array array)\n {\n if (array instanceof Int32Array1D)\n { \n return (Int32Array1D) array; \n }\n return new Wrapper(array);\n }",
"public static Object unwrapArray ( Object arr ) {\n\t\tObject result;\n\t\t\n\t\tif ( arr.getClass()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method takes the user's credentials and uses them to make a request to log into a given Jira instance. It returns the response generated from that request. | public static String loginToJira(String baseURL, String loginURL, String loginUserName, String loginPassWord){
String loginResponse = "";
URL url = null;
HttpURLConnection conn = null;
String input = "";
OutputStream os = null;
BufferedReader br = null;
String out... | [
"public String login(String username, String password) throws JiraManagerException {\r\n Util.logEnter(log, \"login\", username, password);\r\n Util.checkString(log, \"username\", username);\r\n Util.checkString(log, \"password\", password);\r\n\r\n try {\r\n String result = g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the value of the 'field388' field. doc for field388 | public java.lang.CharSequence getField388() {
return field388;
} | [
"public java.lang.CharSequence getField388() {\n return field388;\n }",
"java.lang.String getField1038();",
"java.lang.String getField1063();",
"java.lang.String getField1538();",
"java.lang.String getField1093();",
"java.lang.String getField1164();",
"java.lang.String getField1139();",
"java.... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Accessor for the initiator. | public Object getInitiator() {
return mInitiator;
} | [
"public ObjectType getInitiator() { return initiator; }",
"public boolean initiator() {\n return initiator;\n }",
"public String getInitiatorAddress() {\n return this.initiatorAddress;\n }",
"public void setInitiator(ObjectType init) { initiator = init; }",
"public Long[] getInitiatorIDs... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
compare and insert the new image in prothese | public void addNewImages(List<String>newList,List<String>oldList,ProtheseFixe currentProtheseFixe){
boolean found= false;
for (int i = 0; i < newList.size(); i++) {
for (int j = 0; j < oldList.size(); j++) {
if (newList.get(i)==oldList.get(j)) {
//do nothing
found=true;
}
}
if (!foun... | [
"private void createTransformation(Transformation t, String keyImage1, String keyImage2, RavensProblem problem){\n \t//loading the raven's figures\n \tRavensFigure a = problem.getFigures().get(keyImage1);\n \tRavensFigure b = problem.getFigures().get(keyImage2);\n \t\n \ttry{\n \t\tt.image1 = Imag... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ The input integer is the key defined in ContentPoolItem.java | public ContentPoolItem getContentPoolItem(Integer i) {
return cPool.getItem(i);
} | [
"protected abstract Long requestKey();",
"private synchronized int getPlcReadTagsSHM_keyID() {\n if (plcReadTagsSHM_keyID > 10000) {\n plcReadTagsSHM_keyID = 1;\n }\n else {\n plcReadTagsSHM_keyID += 1;\n }\n return plcReadTagsSH... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Another example of a event handler. This one will give you the name of the entity you interact with, if it is a Creature it will give you the creature Id. | @EventHandler
public void onPlayerInteract(PlayerInteractEntityEvent event) {
final EntityType entityType = event.getRightClicked().getType();
event.getPlayer().sendMessage(MessageFormat.format(
"You interacted with a {0} it has an id of {1}",
entityType.getName(),
... | [
"String getEntityName();",
"String getInputEvent();",
"String getEventName();",
"String getSnapshotEventEntryEntityName();",
"java.lang.String getEntityName();",
"String getDomainEventEntryEntityName();",
"public void onFirstClickNpc(Player player, Entity npc) {\n\n }",
"java.lang.String getEventId... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Diese Funktion erzeugt eine Instanz der Klasse Berechnungen und weist ihr im Konstruktor die eingelesenen Daten fuer die eingabezahl und iterationen zu. Anschliessend wird die iteriere() Funktion ausgefuehrt. | public void berechne() {
berechnungen = new Berechnungen(eingabezahl, iterationen);
berechnungen.iteriere();
} | [
"@Override\r\n public Iterator<T> iterator(){\r\n return new lenkeListeIterator();\r\n }",
"@Override\n public Iterator<BObject> iterator() {\n return toArrayList().iterator();\n }",
"@Override\n public Iterator<T> iterator() {\n return new LenkelisteIterator();\n }",
"public Bu... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__AssignOperator__Alternatives" $ANTLR start "rule__UnaryOp__Alternatives" InternalReflex.g:2123:1: rule__UnaryOp__Alternatives : ( ( ( '+' ) ) | ( ( '' ) ) | ( ( '~' ) ) | ( ( '!' ) ) ); | public final void rule__UnaryOp__Alternatives() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalReflex.g:2127:1: ( ( ( '+' ) ) | ( ( '-' ) ) | ( ( '~' ) ) | ( ( '!' ) ) )
int alt20=4;
switch ( input.LA(1) ) {
ca... | [
"public final void rule__OpUnary__Alternatives() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.guicemodules.ui/src-gen/org/xtext/guicemodules/ui/contentassist/antlr/internal/InternalGuiceModules.g:2830:1: ( ( '!' ) | ( '-' ) |... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Disables a table (takes it offline) If it is being served, the master will tell the servers to stop serving it. Synchronous operation. | public void disableTable(final byte [] tableName) throws IOException {
if (this.master == null)
throw new MasterNotRunningException("master has been shut down");
// Wait until all regions are disabled
boolean disabled = false;
for (int tries = 0; tries < this.numRetries; tries++) {
try {
... | [
"public void disableTable(final String tableName) throws IOException {\n disableTable(Bytes.toBytes(tableName));\n }",
"private void disableTable() {\n for (Button button : seatsArray) {\n button.setDisable(true);\n }\n confirmChange.setDisable(true);\n deleteBooking.set... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Identify if sector is a home region, inside sphere of influence, or outside. | private int getSphere(final Sector sector) {
if (sector == null || String.valueOf(sector.getPoliticalSphere()).length() == 0) {
return 3;
}
final char thisNationCodeLower = String.valueOf(sector.getNation().getCode()).toLowerCase().charAt(0);
final char thisSectorCodeLower =... | [
"boolean hasSector();",
"public boolean isLand() {\n if ((getType() == OCEAN) || (getType() == HIGH_SEAS)) {\n return false;\n } else {\n return true;\n }\n }",
"boolean isSphere();",
"public boolean isPointInRegion();",
"boolean isSetIntersectionLocation(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sanitize the intent in place. | private static void sanitizeIntent(Intent intent) {
// Apps should not be allowed to target a specific package/ component in the target user.
intent.setPackage(null);
intent.setComponent(null);
} | [
"private static void normalizeIntents(IntentAttachPoint intentAttachPoint) {\n PolicyComputationUtils.expandProfileIntents(intentAttachPoint.getRequiredIntents());\r\n\r\n //remove duplicates and ...\r\n //where qualified form of intent exists retain it and remove the qualifiable intent\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Used to export API Product artifact | public File exportAPIProduct(String apiId, String revisionUUID, boolean preserveStatus, ExportFormat format,
boolean preserveDocs, boolean preserveCredentials, String organization)
throws APIManagementException, APIImportExportException; | [
"public File exportAPIProduct(String apiId, String name, String version, String providerName, String revisionNum,\n ExportFormat format,boolean preserveStatus, boolean preserveDocs,\n boolean preserveCredentials, boolean exportLatestRevision, String or... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the number of response in the collection. | public int getCount() {
return this.responses.size();
} | [
"public int responseCount() {\n synchronized (_responseIds) {\n return _responseIds.size();\n }\n }",
"public int getTotalResponse() {\n return totalResponse;\n }",
"public Integer size(){\n\t\treturn this.collection.size();\n\t}",
"public int size() {\n return collectio... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR start "program" D:\\workspace\\s\\JLLVM_b\\src\\cn\\edu\\sjtu\\jllvm\\VMCore\\Parser\\LLVM.g:28:1: program returns [Module program] : ( target ) ( named_type ) ( global_variable ) ( aliases_variable ) ( function_declaration | function_definition )+ EOF ; | public final Module program() throws RecognitionException {
Module program = null;
GlobalVariable global_variable1 =null;
GlobalAlias aliases_variable2 =null;
FunctionDeclare function_declaration3 =null;
Function function_definition4 =null;
List<Glob... | [
"Program program() throws SyntaxException {\r\n\t\tToken first=t;\r\n\t\tToken progName=match(IDENTIFIER);\r\n\t\tBlock e1=block();\r\n\t\treturn new Program(first,progName,e1);\r\n\t}",
"Program program() throws SyntaxException {\r\n\t\tToken first = t;\r\n\t\tToken progName = match(IDENTIFIER);\r\n\t\tBlock blo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |