query
stringlengths
8
1.54M
document
stringlengths
9
312k
negatives
listlengths
19
20
metadata
dict
$ANTLR end "rule__XWhileExpression__BodyAssignment_5" $ANTLR start "rule__XDoWhileExpression__BodyAssignment_2" ../org.xtext.lwc.instances.ui/srcgen/org/xtext/lwc/instances/ui/contentassist/antlr/internal/InternalInstances.g:12987:1: rule__XDoWhileExpression__BodyAssignment_2 : ( ruleXExpression ) ;
public final void rule__XDoWhileExpression__BodyAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { // ../org.xtext.lwc.instances.ui/src-gen/org/xtext/lwc/instances/ui/contentassist/antlr/internal/InternalInstances.g:12991:1: ( ( ruleXExpressio...
[ "public final void rule__XDoWhileExpression__BodyAssignment_2() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.xtext.example.helloxcore.ui/src-gen/org/xtext/example/helloxcore/ui/contentassist/antlr/internal/InternalHelloXcore.g:1622...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ ADJUST TABLE TO MAX WIDTH
private void adjustTable(JTable table) { for (int column = 0; column < table.getColumnCount(); column++) { TableColumn tableColumn = table.getColumnModel().getColumn(column); int preferredWidth = tableColumn.getMinWidth(); int maxWidth = tableColumn.getMaxWidth(); ...
[ "private void setMaxWidths(Table inputTable) {\n int colsz = inputTable.getColumnSize();\n setInitialWidths(inputTable, colsz);\n List<String> recordKeys = inputTable.getKeyList();\n for (String entry : recordKeys) {\n for (int i = 0; i < colsz; i++) {\n this.colWidth[i] = \n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
NodeValue constant (returns null if not a constant)
public NodeValue getConstant() ;
[ "public Node getConstant();", "Object getConstantValue();", "@Nullable public abstract Object getConstantValue() throws CompileException;", "ConstantValue createConstantValue();", "public static ConstantExpression constant(Object value) { throw Extensions.todo(); }", "java.lang.String getConstantValue();"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
read a byte from MBC0 only valid ranges are ROM 0x0 0x7fff and extRam 0xa000 0xbfff
public int readByte(int address) { if (address < 0x8000 && address >= 0) { return rom[address]; } else if (address < 0xc000 && address >= 0xa000) { return extRam[address]; } else { System.err.println("invalid read from MBC0"); return 0; } ...
[ "@Test\n public void readRomBanks00_1F_RAMMode() {\n //Select RAM Mode\n cartridge.write((char) 0x6000, (byte) 0x01);\n for (byte bank = 0x01; bank <= 0x1F; bank++) {\n //Select ROM Bank <bank>\n cartridge.write((char) 0x2000, bank);\n for (char a = 0x4000; a...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the created_date of this buy sell products.
@Override public void setCreated_date(Date created_date) { _buySellProducts.setCreated_date(created_date); }
[ "@Override\n\tpublic void setCreateDate(Date createDate) {\n\t\t_bookOrder.setCreateDate(createDate);\n\t}", "@Override\n\tpublic void setCreateDate(Date createDate) {\n\t\t_ibOrder.setCreateDate(createDate);\n\t}", "@Override\n\tpublic void setCreateDate(java.util.Date createDate) {\n\t\t_purchaseOption.setCre...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Starts new game, rerandomizes board, clears LinkedList, repaints
public void newGame() { currentBoard = new Board(rows, cols, mines); currentCBoard = currentBoard.getCBoard(); cBoardList.clear(); playing = true; status.setText("Running..."); // Make sure that this component has the keyboard focus requestFocusInWindow(); ...
[ "private void newGame() \r\n {\r\n \t\r\n //clear the board, clear the free spots\r\n //create a new deck of cards and shuffle it\r\n panel.removeAll();\r\n freeSpots.clear();\r\n int buttonCent = PANEL_SIZE.width/2 -160;\r\n int gridCent = PANEL_SIZE.width/2 -2*Tile....
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the value of the 'Jpa Config' containment reference. If the meaning of the 'Jpa Config' containment reference isn't clear, there really should be more of a description here...
JpaConfig getJpaConfig();
[ "public Config getConfig();", "IConfig getConfig();", "public DBCConfig getConfig();", "public DBConfig getConfig()\n {\n return _config;\n }", "public ConfigTree getConfig() {\n\t\t\treturn AbstractManagedLifecycle.this.getConfig();\n\t\t}", "public Properties getConfig()\n\t{\n\t\treturn co...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method used to prepare list of database queries to update specified array of rows in database
List<WriteModel<Document>> prepareUpdateStatement(String collectionName, ArrayList<HashMap<String,Object>> data) { return data.stream() .map(row -> prepareInsertDocumentStatement(collectionName,row)) .collect(Collectors.toList()); }
[ "public void executeUpdate(ArrayList<String> queryList);", "void updateInBatch(String query);", "public void updateDBSupplier(ArrayList <Supplier> sArray) {\r\n\t\ttry (Connection con = getConnection(DB_NAME);\r\n\t\t\t\tStatement stmt = con.createStatement()) {\r\n\t\t\tfor (Supplier supplier: sArray) {\r\n\t\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method that draws all the Polylines
private void drawAllPolylines() { Marker marker = null; for (Marker marker1 : mMarkerList) { if (marker != null) { drawPolyline(marker.getPosition(), marker1.getPosition()); } marker = marker1; } }
[ "private void drawPolygons(Renderer r) {\n for ( Polygon p : polygons ) {\n p.drawYourSelf(r);\n }\n }", "private void plotLines() {\n if (pressed != null) {\n\n Set<Line> pressedLines = pressed.getLines();\n\n for (Line line : pressedLines) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets maximum of staff seats, excluding pilot and navigator seats.
public void setStaffSeatsCount(int staffSeatsCount) { this.staffSeatsCount = staffSeatsCount; }
[ "public void setSeats(int s)\r\n {\r\n if (s >= DEFAULT_VAL && s > _passengers)\r\n _seats = s;\r\n }", "public void setSeats(Flight fl, int seats) {\n\t\tfl.setNumSeats(seats);\n\t}", "public void setSeats(int seats)\r\n {\r\n if(seats > 0)\r\n this.seats = seats;\r...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__Operation__Group_4__3" $ANTLR start "rule__Operation__Group_4__3__Impl" ../com.mguidi.soa.ui/srcgen/com/mguidi/soa/ui/contentassist/antlr/internal/InternalSOA.g:3481:1: rule__Operation__Group_4__3__Impl : ( ( ( rule__Operation__FeaturesOutputAssignment_4_3 ) ) ( ( rule__Operation__FeaturesOutputAssign...
public final void rule__Operation__Group_4__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // ../com.mguidi.soa.ui/src-gen/com/mguidi/soa/ui/contentassist/antlr/internal/InternalSOA.g:3485:1: ( ( ( ( rule__Operation__FeaturesOutputAssignment_4_...
[ "public final void rule__Operation__Group_3__4() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../com.mguidi.soa.ui/src-gen/com/mguidi/soa/ui/contentassist/antlr/internal/InternalSOA.g:3340:1: ( rule__Operation__Group_3__4__Impl )\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Clears the results in methodItems and the summaries in classItems and the summary of classItems.
public void clearAllResultsAndSummaries() { for (WjrMethodItem methodItem : methodItems.values()) { methodItem.clearResult(); } for (WjrClassItem classItem : classItems.values()) { classItem.clearSummary(); } root.clearSummary(); }
[ "public void clearItems() {\n }", "public void clear() {\n\t\tresults.clear();\n\t}", "public void clear() {\n results.clear();\n }", "public void clear() {\n items.clear();\n }", "public void clear()\n\t{\n\t\titemCount = 0;\n\t\ttotalPrice = 0;\n\t\tprevious = 0;\n\t}", "private voi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets a CachedPlayer for a UUID. If no entry is found in the cache this method will query Mojang if queryMojangIfUnknown is true. This query is blocking, so avoid calling it in the main thread if possible. The result may be null if this player is not found in the cache. This method can be called from any thread.
CachedPlayer getPlayer(UUID playerUUID, boolean queryMojangIfUnknown);
[ "CachedPlayer getPlayerFromNameOrUUID(String playerNameOrUUID, boolean queryMojangIfUnknown);", "CachedPlayer getPlayer(UUID playerUUID);", "CachedPlayer getPlayer(String playerName, boolean queryMojangIfUnknown);", "CachedPlayer getPlayerFromNameOrUUID(String playerNameOrUUID);", "CachedPlayer getPlayer(St...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Query Person by Person instance which the primary key is set
public Person queryByPk(Person pk, DalHints hints) throws SQLException { hints = DalHints.createIfAbsent(hints); return client.queryByPk(pk, hints); }
[ "public Persona findByPrimaryKey(PersonaPk pk) throws PersonaDaoException;", "PersonDetail selectByPrimaryKey(Integer pid);", "LawPerson selectByPrimaryKey(Long personId);", "public Persona findByPrimaryKey(int idPersona) throws PersonaDaoException;", "T findByPrimaryKey(Object id);", "PersonRegisterDo se...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
returns the title for the given ISBN number from the google API
public Title getFromGoogleApi(String isbn) { //https://www.googleapis.com/books/v1/volumes?q=isbn:9789144059679 Title result = null; try { HttpGet httpGet = new HttpGet("https://www.googleapis.com/books/v1/volumes?q=isbn:" + isbn); HttpResponse response = httpClient.exec...
[ "public String getISBN( )\n { return countryNumber + \" \" + publisherNumber + \" \" +titleNumber+ \" \"\n + checkDigit;\n }", "public String getBookISBN ( )\n { return isbnNumber.getISBN ( ) ;\n }", "Book getBookByTitle(String title);", "public String isbnRequest(final String query) {\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This Metho allows to check if the Event contains an element with the given name
public boolean containsElement(String elementName) { for (int i = 0; i < eventFields.size(); i++) { EventDataEntry currentEntry = eventFields.get(i); if (currentEntry.getColumnName().equalsIgnoreCase(elementName)) { return true; } } retu...
[ "public boolean hasElement(String name) {\n return elements.has(name);\n }", "private boolean checkStartElement(XMLEvent event, String elementName) {\n\t\tif (event.isStartElement()\n\t\t\t\t&& event.asStartElement().getName().getLocalPart()\n\t\t\t\t\t\t.toLowerCase().equals(elementName)) {\n\t\t\treturn tru...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the paquete usuario.
public void setPaqueteUsuario(final PaqueteUsuario paqueteUsuario) { this.paqueteUsuario = paqueteUsuario; }
[ "public void setPaqueteUsuario(final PaqueteUsuario paqueteUsuario) {\r\n\tthis.paqueteUsuario = paqueteUsuario;\r\n }", "public void setUsuario(java.lang.String usuario);", "public void setUsuario(java.lang.String usuario) {\n this.usuario = usuario;\n }", "public void setUsuario(java.lang.Strin...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__GAdditionExpression__Group_1__2" $ANTLR start "rule__GAdditionExpression__Group_1__2__Impl" ../org.gemoc.gel.xtext.ui/srcgen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:7199:1: rule__GAdditionExpression__Group_1__2__Impl : ( ( rule__GAdditionExpression__RightOperandAssignment_1_2 ) ) ;
public final void rule__GAdditionExpression__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:7203:1: ( ( ( rule__GAdditionExpression__Right...
[ "public final void rule__GAdditionExpression__Group_1__1__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../org.gemoc.gel.xtext.ui/src-gen/org/gemoc/gel/ui/contentassist/antlr/internal/InternalGEL.g:7175:1: ( ( ( rule__GAdditionExpre...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
end method attackDefender Calls attack method of both Pokemon when they both attack and neither defends. Determines whether or not the faster Pokemon strikes first. If the Pokemon that was attacked first survived the attack, then it attacks the first attacker.
public void attackAttacker(Pokemon fasterAttacker, Pokemon slowerAttacker) { // If a Pokemon is faster, it strikes first 80% of the time. int oddsOfFirstStrike = randomGenerator.nextInt(10); if (oddsOfFirstStrike <= 7) { fasterAttacker.attack(slowerAttacker); // If both players survived faster P...
[ "public void attack(Entity defender) {\n\t\tboolean canAttack = true;\n\n\t\tif ((abilities[3] == false && abilities[2] == false)\n\t\t\t\t&& (Math.abs(defender.getPosX() - xCoordinate) > 1 || Math.abs(defender.getPosY() - yCoordinate) > 1))\n\t\t\treturn; // if not in range, don't attack (also cant attack self)\n\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the numeroTramite value for this RetornoTramiteRetorno.
public java.lang.String getNumeroTramite() { return numeroTramite; }
[ "public int getNbTriforce() {\n\t\treturn nbTriforce;\n\t}", "public synchronized Integer getNumeroTramite() throws Exception{\n\t\tObject pObject = new Object();\n\t\tsynchronized (pObject) {\n\t\t\tInteger locRetorno = 0;\n\t\t\ttry{\n\t\t\t\tlocRetorno = (Integer) entityManager.createQuery(\"SELECT MAX(o.numer...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
void GossipTimestampFilter_set_first_timestamp(struct LDKGossipTimestampFilter NONNULL_PTR this_ptr, uint32_t val);
public static native void GossipTimestampFilter_set_first_timestamp(long this_ptr, int val);
[ "public static native int GossipTimestampFilter_get_first_timestamp(long this_ptr);", "public static native void GossipTimestampFilter_set_timestamp_range(long this_ptr, int val);", "public static native long GossipTimestampFilter_new(byte[] chain_hash_arg, int first_timestamp_arg, int timestamp_range_arg);", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Handling when user clicks link to edit a wishlist item
@RequestMapping(value = "/editWish", method = RequestMethod.GET) @Transactional public String editWish(Model model, @RequestParam("wishId") Long id, @RequestParam(value="userId", required=false) Long userId, HttpServletRequest request){ if (userId == null) { userId = getMyUserId(); } WishlistItem it...
[ "protected abstract void editItem();", "public ItemPage clickAddToWishlistLink() {\n addToWishlist.click();\n return this;\n }", "public void clickWishlistLink()\n\t{\n \telementUtils.performElementClick(wbWishlistLink);\n\t}", "public void Edit(View view){\r\n\r\n //Used to determ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
LifeCycle Opens the hash join. This method reads the buildside input and constructs the initial hash table, gradually spilling partitions that do not fit into memory.
public void open() throws IOException { // open builds the initial table by consuming the build-side input this.currentRecursionDepth = 0; buildInitialTable(this.buildSideInput); // the first prober is the probe-side input this.probeIterator = new ProbeIterator(this.probeSideInput); // the b...
[ "void storeInitialHashTable() throws IOException {\n if (spilled) {\n return; // we create the initialHashTable only once. Later calls are caused by deeper\n // recursion lvls\n }\n spilled = true;\n\n for (int partIdx = 0; partIdx < initialPartitions.size(); partId...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
enable emulation mode. Override to initialize emulation state
public void enableEmulator() { _isEmulated = true; }
[ "public void setEngineOn();", "private void initSimulateMode() {\n initSimulateModeView();\n initSimulateModeController();\n }", "@Override\n public void setEventAcquisitionEnabled(boolean enable) throws HardwareInterfaceException {\n if ( input != null ){\n input.setPaused...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Method to destroy the binary tree. Postcondition: root = null
public void destroyTree() { root = null; }
[ "public void delete() {\n this.root = null;\n }", "public static void clearTree() {\n\t\troot=null; //sets the root to null (nothing), hence clearing the tree\r\n\t}", "@Override\r\n public void clear(){\r\n root = null;\r\n }", "private void deleteTree(tnode root){\n if (root !=...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create an aliased public.trips table reference
public Trips(String alias) { this(alias, TRIPS); }
[ "private static TableRef createAliasedTableRef( final TableMeta table,\n final String alias ) {\n return new TableRef() {\n public String getColumnName( String rawName ) {\n return alias + \".\" + rawName;\n }\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Determines the bounding box of the character at the given index into the string. The bounds are returned in local coordinates. If the index is invalid a null rectangle is returned.
public Rectangle getCharacterBounds(int i) { return null; }
[ "Rectangle2D getStringBounds(Font font, String string);", "public final void testGetStringBoundsCharArrayIntIntGraphics() {\n String str = \"toremove-This is a very long string for getting bounds!-toremove\";\n char[] chars = str.toCharArray();\n int width = 237;\n Rectangle2D rect = f...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Setter method for the COM property "Smooth"
@DISPID(163) @PropPut void setSmooth( boolean rhs);
[ "@DISPID(163)\n @PropGet\n boolean getSmooth();", "public void setSmooth(boolean smooth) {\n _smooth = smooth;\n _smoothSet = true;\n }", "public void setSmooth_factor(double smooth_factor){ \n this.smooth_factor = smooth_factor; \n }", "public void setSmoothness(double smoothness) {\n _c...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
By default Espresso Intents does not stub any Intents. Stubbing needs to be setup before every test run. In this case all external Intents will be blocked.
@Before public void stubAllExternalIntents() { intending(not(isInternal())).respondWith(new Instrumentation.ActivityResult(Activity.RESULT_OK, null)); }
[ "@Before\n public void stubAllExternalIntents() {\n intending(not(isInternal()))\n .respondWith(new Instrumentation.ActivityResult(Activity.RESULT_OK, null));\n }", "@Before\n public void stubAllExternalIntents() {\n intending(not(isInternal()))\n .respondWith(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Handles serialization for OFSwitchImpl
@Override public void serialize(OFSwitchImpl switchImpl, JsonGenerator jGen, SerializerProvider arg2) throws IOException, JsonProcessingException { jGen.writeStartObject(); jGen.writeStringField("dpid", HexString.toHexString...
[ "@Override\n public Class<OFSwitchImpl> handledType() {\n return OFSwitchImpl.class;\n }", "@Override\n public void serializeInto(ByteBuffer buf) {\n super.serializeInto(buf);\n // OVS_VPORT_ATTR_OPTIONS is a nested netlink attribute. Here we\n // write its netlink header manu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
call back this method when person list has changed.
public void onPersonListChanged();
[ "public void updatePersonList(String deadPerson) {\n for (int i = 0; i < config.personList.size(); i++) {\n if (config.personList.get(i).getName().equals(deadPerson)) {\n config.personList.remove(i--);\n if (i < 0) {\n i = 0;\n }\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
void CResult_NonePaymentSendFailureZ_free(struct LDKCResult_NonePaymentSendFailureZ _res);
public static native void CResult_NonePaymentSendFailureZ_free(long _res);
[ "public static native void CResult_PaymentHashPaymentSendFailureZ_free(long _res);", "public static native void CResult_TransactionNoneZ_free(long _res);", "public static native void PaymentSendFailure_free(long this_ptr);", "public static native void CResult_InvoiceNoneZ_free(long _res);", "public static n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Parser pool used for the OpenSAML parsing.
@Bean(initMethod = "initialize") public StaticBasicParserPool parserPool() { return new StaticBasicParserPool(); }
[ "public ParserPool() {\n\t\t\t// Build a parser factory and the default schema set.\n\t\t\tdbf = DocumentBuilderFactory.newInstance();\n\t\t\tdbf.setNamespaceAware(true);\n\t\t\ttry {\n\t\t\t\tdbf.setFeature(\n\t\t\t\t\t\t\"http://apache.org/xml/features/validation/schema/normalized-value\",\n\t\t\t\t\t\tfalse);\n\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
bool has_subtitles = 9;
public boolean getHasSubtitles() { return hasSubtitles_; }
[ "public boolean getHasSubtitles() {\n return hasSubtitles_;\n }", "boolean hasHadithChapterIntro();", "public boolean canProcessSubtitles() {\n return player != null && (player.isPlaying() || player.isPaused());\n }", "public native static boolean showSubtitles(boolean oper1);", "boolean hasVo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Adds a message to the serverside message queue.
public void addToMessageQueue(String message) { messageQueue.appendText(message + "..." + "\n"); }
[ "public void enqueue(Message message) {\n\t\tqueue.add(message);\n\n\t}", "public void queueMessage(ProtocolMessage message) {\n outgoing.add(message);\n }", "public void enqueue(Message msg){\n\t\tqueue.add(msg);\n\t}", "public void addMessage(Message message);", "public void addMessage(Message message...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Set the elapsed time
public void setTime(final long elapsed) { this.elapsed = elapsed; }
[ "void setElapsedTime(long time) {\r\n\r\n elapsedTime = time;\r\n\r\n }", "public void setTimeElapsed(double timeElapsed) {\r\n this.timeElapsed = timeElapsed;\r\n }", "public void setElapsedTime(Long elapsedTime) {\n this.elapsedTime = elapsedTime;\n }", "void updateElapsedTime(lo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Test the Getter and Setter of the Farm type, and also checks that the correct bonuses are applied
@Test void typeTest() { Farm testFarm = new Farm(); testFarm.setType("Plain"); assertEquals("Plain", testFarm.getType()); assertEquals(8.0, testFarm.getBonuses().get("animalHealth")); assertEquals(7.0, testFarm.getBonuses().get("animalHappiness")); assertEquals(1.0, testFarm.getBonuses().get("harvestTime")...
[ "@Test\n\tvoid setFarmerTest() {\n\t\tFarm testFarm = new Farm();\n\t\tFarmer testFarmer = new Farmer();\n\t\tFarmer testFarmer2 = new Farmer();\n\t\ttestFarm.setFarmer(testFarmer);\n\t\tassertEquals(testFarm.getFarmer(), testFarmer);\n\t\ttestFarm.setFarmer(testFarmer2);\n\t\tassertEquals(testFarm.getFarmer(), tes...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the parent component.
UIComponent getParent();
[ "public Component getParentComponent() {\r\n\t\tif (parentComponent == null) {\r\n\t\t\tif (view != null)\r\n\t\t\t\tparentComponent = view.getComponent(parentComponentName);\r\n\t\t}\r\n\t\treturn parentComponent;\r\n\t}", "public Component getParent() {\n \t\treturn parent;\n \t}", "public Component getParent...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sviesoforas s1 = new Sviesoforas(44,55,new Color(255, 0,0 ) ); Sviesoforas s2 = new Sviesoforas(44,55,new Color(211, 15,15 ) );
public static void main(String[] args) { Sviesoforas s1 = new Sviesoforas(44,55,Color.RED); Sviesoforas s2 = new Sviesoforas(44,55,Color.GREEN); Sviesoforas s3 = new Sviesoforas(44,55,Color.YELLOW); System.out.println(Color.RED); // Color.red = Color.yellow; // System.o...
[ "public SimpleColor(){\n Random rand = new Random();\n r = rand.nextFloat();\n g = rand.nextFloat();\n b = rand.nextFloat();\n o = 1;\n }", "public ShadesOfBlue(){\n super( Settings.ObjectivesProperties.SHADES_OF_BLUE.getTitle(),\n Settings.ObjectivesPr...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Initialize this servlet with required configuration. Parameters needed on the Local Servlet scope: 'com.auth0.redirect_on_success': where to redirect after a successful authentication. 'com.auth0.redirect_on_error': where to redirect after a failed authentication. Parameters needed on the Local/Global Servlet scope: 'c...
@Override public void init(ServletConfig config) throws ServletException { super.init(config); final ServletContext context = config.getServletContext(); redirectOnSuccess =Auth0Constants.AUTH0_LOGIN_SUCCESS.getValue(); redirectOnFail =Auth0Constants.AUTH0_LOGIN_FAILURE.getValu...
[ "@Override\n\tpublic void contextInitialized(ServletContextEvent event) {\t\n\t\t// 1. Initialize log4j:\n\t\tLog4jConfigure.configure(event);\n\t\t\n\t\tLOG.info(\"webapp initialized\");\n\t\t\n\t\t// 2. Initiate secure login\n\t\tSecureLogin.login();\n\t}", "@Override\n protected void initialize() throws Ser...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Sets the insolvency_id value for this InsolvencyCase.
public void setInsolvency_id(java.lang.String insolvency_id) { this.insolvency_id = insolvency_id; }
[ "public java.lang.String getInsolvency_id() {\n return insolvency_id;\n }", "public void setIdVaccin(int idVaccin) {\n\t\tthis.idVaccin = idVaccin;\n\t}", "public void setInseamId(String value) {\n setAttributeInternal(INSEAMID, value);\n }", "public void setIdIndice(Integer idIndice) {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Build a valid instance of a Character array from the given object.
protected Character[] convertObjectToCharacterArray(Object sourceObject) throws ConversionException { String stringValue = convertObjectToString(sourceObject); Character[] chars = new Character[stringValue.length()]; for (int index = 0; index < stringValue.length(); index++) { ch...
[ "public Character[] toObject(char[] array) {\n if (array == null) {\n return null;\n } else if (array.length == 0) {\n return EMPTY_CHARACTER_OBJECT_ARRAY;\n }\n final Character[] result = new Character[array.length];\n for (int i = 0; i < array.length; i++) ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Return accept check result with message
public static RtCheckResult accept(String message) { return new RtCheckResult(Name.ACCEPT, message); }
[ "void messageAllianceRequestAccepted(String message);", "boolean getAccepted();", "public ChabuConnectionAcceptInfo isAccepted( ChabuSetupInfo local, ChabuSetupInfo remote );", "Accept createAccept();", "public void receiveResultcheckServerStatus(\n loadbalance.LoadBalanceStub.CheckServer...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Assign the value on top of the stack to the instance variable with the specified name on the current "self". The value is consumed.
public void assignInstanceVariable(String name, CompilerCallback value);
[ "public void assignInstanceVariable(String name);", "public void assign (String name, int value){\n Closure exist = find_var(name);\n exist.getValues().put(name, new IntegerValue(value));\n }", "public void retrieveInstanceVariable(String name);", "public IRubyObject instance_variable_set(IRu...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column lb01_pt.lbt82_kinken_sum.tesuryo06
public Long getTesuryo06() { return tesuryo06; }
[ "public Long getKinkenriyou06() {\r\n return kinkenriyou06;\r\n }", "public Long getKinkenriyou05() {\r\n return kinkenriyou05;\r\n }", "java.lang.String getSum();", "public String getSumShopJkn() {\n return sumShopJkn;\n }", "private String getSumFormulaSql() {\n final List<S...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Overrides analyzeCells in the Simulation superclass and analyzes the cells for the simulation based on the specified rules of the Game of Life.
@Override public void analyzeCells() { for(Cell cell: getGrid()){ int liveNeighborsCount = countLiveNeighbors(cell.getMyNeighbors()); if (cell.getState() == LIVE) { if (liveNeighborsCount < minPopulationThreshold || liveNeighborsCount > maxPopulationThresh...
[ "public void processCells() {\n\n //Create a new grid which will be next iteration\n Cell[][] nextGrid = new Cell[this.width][this.height];\n\n //Populate the new grid with dead cells\n populateGrid(nextGrid);\n\n //Iterate through the grid\n for (int x = 0; x < this.width;...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
1. Gets the current logged in username 2. Gets the list of timeline TweetIDs from the timeline index for the user 3. Writes the content of all the timeline tweets to the json Array. 4. Returns the array
@RequestMapping(value = "/feed/{fromIndex}/{toIndex}", method = RequestMethod.GET, produces = { "application/json" }) public String getFeed(@PathVariable int fromIndex, @PathVariable int toIndex) throws Exception { LdapUserDetailsImpl user = (LdapUserDetailsImpl)SecurityContextHolder.getContext().getAuthe...
[ "List<Tweet> getTimeline(String userId);", "private static void readTweetsByUser() {\n try {\n List<Status> status = twitter.getUserTimeline();\n\n checkLatestTweet(status.get(0),\"user\");\n\n Thread.currentThread().sleep(60*SECONDS);\n\n TwitchChat.sendMessage(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the log frame
Log getLogFrame() { return logFrame; }
[ "private static FrameInfo getLoggingFrame() {\n StackTraceElement[] stackTrace = Thread.currentThread().getStackTrace();\n StackTraceElement loggingFrame = null;\n /*\n * We need to dig through all the frames until we get to a frame that contains this class, then dig through all\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the loader for the plugin
PluginLoader getLoader();
[ "public Loader getLoader();", "IScriptLoader getLoader();", "public ContainerLoader getLoader();", "public static ClassLoader getPluginClassLoader() {\r\n if (JDInit.CL == null) {\r\n try {\r\n if (JDUtilities.getRunType() == JDUtilities.RUNTYPE_LOCAL_JARED) {\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets whether the Unit has a HealthBar.
public boolean getHasHealthBar() { return hasHealthBar; }
[ "public static boolean hasHealthBar(EntityLiving entity) {\n return entity.func_94056_bM() /* If the entity has a custom name */ && entity.func_94057_bL() /* Gets the entity's custom name */ .startsWith(S + \"H\");\n }", "public HealthBar getHealthBar();", "public boolean getHasCustomHealth() {\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Aggregate a message if possible.
public boolean aggregateMessage(Message message) { if (flushInterval == 0 || !message.canAggregate() || message.getDone()) { return false; } int hash = message.hashCode(); int bucket = Math.abs(hash % this.shardGranularity); Map<Message, Message> map = aggregateMetr...
[ "protected abstract UMOMessage aggregateEvents(EventGroup events) throws RoutingException;", "@Override\n\tpublic Exchange aggregate(Exchange original, Exchange resource) {\n\t\t\n\t\tif (original==null){\n\n\t\t\treturn resource;\n\t\t}\n\n\t\tString messageID=original.getIn().getHeader(\"MessageID\", String.cla...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
set value on such web element by javascript, an alternative approach for method input
IWebElementWrapper setValue(String value);
[ "public void setValue(WebElement element, String value);", "public static void setAttValue(WebElement element,String AtributeName, String value) throws InterruptedException {\r\n\t\t JavascriptExecutor jse=(JavascriptExecutor) driver;\r\n\t\t// js.executeScript(\"arguments[0].setAttribute(style.visibility='visibl...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
creates a new LineByLineDataParser which is used for parsing each line in the file proviuded.
public LineByLineDataParser(DataDescription dataDescription) { super(dataDescription); buf.clear(); }
[ "protected abstract Operation parseLine(File baseDir, String line, int lineNum) throws IOException;", "LineContent processLine(String line) throws ParserException;", "public void read(){\n assert(inputStream.hasNext());\n\n while(inputStream.hasNextLine()){\n String line = inputStream.n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Constructor used to generate a Donut object using the Parcelable data
private Donut(Parcel in) { super(in.readInt()); this.flavor = in.readString(); this.count = in.readInt(); super.setItemPrice(itemPrice()); super.setItemString(donutDataString()); }
[ "public Donut(int donutQuantity){\n super(donutQuantity);\n super.setItemPrice(itemPrice());\n super.setItemString(donutDataString());\n count = donutQuantity;\n }", "private Pet(Parcel in){\n mId = in.readLong() ;\n mName = in.readString() ;\n mDetails = in.rea...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates countries using info found in Constants.java
public void createCountries() { countryArray = new Country[Constants.NUM_COUNTRIES]; for(int i=0; i<Constants.NUM_COUNTRIES; i++) { countryArray[i] = (new Country(i)); } }
[ "private static ArrayList<Country> countryCreator() {\n\t\t\n\t\tArrayList<Country> countries = new ArrayList<Country>();\n\t\tCell workingCell;\n\t\t\n\t\tfor (int i = 0; i < countriesNum; i++) {\n\t\t\tworkingCell = mapDataSheet.getCell( 0 , 4+i);\n\t\t\tString countryName = workingCell.getContents();\n\t\t\tcoun...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
First init of the hashtable that hold each robot it's path to the targeted fruit.
public void initRobotPath() { for (int i = 0; i < my_game.getRobot_size(); i++) { Robot robot = my_game.getRobots().get(i); // Fruit fruit = my_game.getFruits().get(i); Fruit fruit = findClosestFruit(robot); List<node_data> tmp = algo_g.shortestPath(robot.getSrc(),...
[ "public void init()\n {\n this.tripDict = new HashMap<String, Set<Trip>>();\n this.routeDict = new HashMap<String, Double>();\n this.tripList = new LinkedList<Trip>();\n this.computeAllPaths();\n this.generateDictionaries();\n }", "private static void initFruitTrees() {\r\...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Called when a click is recorded for an ad.
@Override public void onAdClicked() { Log.d(TAG, "Ad was clicked."); if (hasListeners(AdmobModule.AD_CLICKED)) { fireEvent(AdmobModule.AD_CLICKED, new KrollDict()); } }
[ "@Override\n public void onAdImpression() {\n Log.d(TAG, \"Ad recorded an impression.\");\n }", "@Override\n public void onAdClicked() {\n }", "@Override\n public void adClicked(Ad arg0) {\n\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Result of executing a primary operation expects finalResponseIfSuccessful or finalFailure to be notnull
public PrimaryResult(ReplicaRequest replicaRequest, Response finalResponseIfSuccessful, Exception finalFailure) { assert finalFailure != null ^ finalResponseIfSuccessful != null : "either a response or a failure has to be not null, " + "found [" + finalFailure ...
[ "protected abstract void callSuccessful(API_RESPONSE response) throws Throwable;", "public IFuture success() {\n return success(null);\n }", "@NotNull\n\t@Contract(pure = true)\n\tstatic VoidMaybe success() {\n\t\treturn SUCCESS;\n\t}", "boolean isSuccessful();", "public void onSuccesfulExecution(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
required .client2server.PlayerActivity playerActivity = 1;
pb4client.PlayerActivity getPlayerActivity();
[ "public void beginActivity(Player player) {}", "pb4client.PlayerActivityOrBuilder getPlayerActivityOrBuilder();", "com.huya.ig.jump.protocol.Player getPlayer();", "public void setPlayer(PlayerType player){\n this.player = player;\n }", "void setoPlayer(Player oPlayer){ this.oPlayer =...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the value of the 'Body Condition' reference. An optional Constraint on the result values of an invocation of this Operation.
Constraint getBodyCondition();
[ "OclExpressionCS getBodyExpression();", "public String getCondition() {\n return condition;\n }", "cn.infinivision.dataforce.busybee.pb.meta.Expr getCondition();", "public Statement getBody() {\n\t\treturn this.body;\n\t}", "public String getRuleCondition() {\n return ruleCondition;\n }"...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a new instance of IconButtonTreeTableCellEditor
public ATAutoActivateTreeTableCellEditor() { addMouseListener(this); if ( activateOnIcon == null ) activateOnIcon = UIManager.getIcon("AbilityButton.autoActivateOnIcon"); if ( activateOffIcon == null ) activateOffIcon = UIManager.getIcon("AbilityButton.autoActivateOffIcon"); ...
[ "protected TreeCellEditor createTreeCellEditor() {\n\tBorder aBorder = UIManager.getBorder(\"Tree.editorBorder\");\n\tDefaultCellEditor editor = new DefaultCellEditor\n\t (new DefaultTextField(aBorder)) {\n\t public boolean shouldSelectCell(EventObject event) {\n\t\tboolean retValue = super.sho...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Lookup the projectService with admin role.
private static void lookupProjectServiceRemoteWithAdminRole() throws Exception { Properties env = new Properties(); env.setProperty(Context.SECURITY_PRINCIPAL, "admin"); env.setProperty(Context.SECURITY_CREDENTIALS, "password"); env.setProperty(Context.INITIAL_CONTEXT_FACTOR...
[ "IAdminService getAdminService();", "private static void lookupProjectServiceRemoteWithUserRole()\r\n throws Exception {\r\n Properties env = new Properties();\r\n env.setProperty(Context.SECURITY_PRINCIPAL, \"username\");\r\n env.setProperty(Context.SECURITY_CREDENTIALS, \"password\")...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Fill in this method to determine if the tag body should be evaluated again after evaluating the body. Use this method to create an iterating tag. Called from doAfterBody().
public boolean theBodyShouldBeEvaluatedAgain() { // // TODO: code that determines whether the tag body should be // evaluated again after processing the tag // should be placed here. // You can use this method to create iterating tags. // Cal...
[ "public boolean theBodyShouldBeEvaluatedAgain() {\n //\n // evaluated again after processing the tag\n // should be placed here.\n // You can use this method to create iterating tags.\n // Called from the doAfterBody() method.\n //\n return fa...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/ In DocumentSettingsPart, the namespaces are actually used somewhere in the body, so JAXB will declare them. But it might just set it locally on the element So our job here is twofold: set the value of ignorable suitably, and pass it to namespacePrefixMapper
@Override protected void setMceIgnorable(McIgnorableNamespaceDeclarator namespacePrefixMapper) { boolean needW14 = false; if (this.jaxbElement.getDocId14()!=null) { needW14 = true; } else if (this.jaxbElement.getConflictMode() !=null) { needW14 = true; } else if (this.jaxbElement.getDiscardIm...
[ "protected abstract String getDefaultNamespace();", "public void setNamespaceAware(final boolean isNamespaceAware) {\n checkSetterPreconditions();\n\n namespaceAware = isNamespaceAware;\n }", "private static void bindDefaultNamespace(FeedReaderPreferences settings, XPath xpath) {\n String de...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
de.tif.jacob.core.definition.impl.jad.castor.CastorKey[] getForeignKey() Method getForeignKeyCount
public int getForeignKeyCount() { return _foreignKeyList.size(); }
[ "public int sizeOfForeignkeyArray()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().count_elements(FOREIGNKEY$4);\r\n }\r\n }", "public java.util.Enumeration enumerateForeignKey()\n {\n ret...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Checks if point v is inside the entry's MBR
boolean is_inside(float v[]) { int i; for (i = 0; i < dimension; i++) { if (v[i] < bounces[2*i] || // upper limit v[i] > bounces[2*i + 1]) // lower limit return false; } return true; }
[ "public boolean contains(MBR mbr) {\n if (mbr.x1 < x1 || mbr.x2 > x2 || mbr.y1 < y1 || mbr.y2 > y2)\n return false;\n return true;\n }", "public boolean inBox(PVector point, PVector[] line) {\n\tif (point.y >= min(line[0].y, line[1].y)-0.00001f) {\n\t\t//println(\"y <=max\", point.y, m...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
get the formula info of the constraints
public Map<T, FormulaInfo> getFormulaInfoOfConstraints() { return formulaInfoOfConstraints; }
[ "public List<Constraint> getConstraints();", "Constraints getConstraints();", "public Object getConstraints()\n {\n return constraints;\n }", "public MethodConstraints getConstraints() {\n\treturn constraints;\n }", "public LogicCriterion constraints();", "public List<Constraint> getConstr...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Create the page content
protected abstract void createContent(Composite page);
[ "Content createContent();", "void createAllContentPage(List<Content> contentList){\n String htmlPageString= templateBuffer.toString();\n htmlPageString=htmlPageString\n .replace(TITLE,\"All\")\n .replace(PAGE_HEADING,\"All\")\n .replace(STYLE_SHEET,siteDi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets if this crate is still dropped by the automatic crate drop timer
public boolean isDropped();
[ "public boolean drops() {\r\n\t\tboolean res = drops;\r\n\t\tif(drops) {\r\n\t\t\tRandom r = new Random();\r\n\t\t\tint rand = r.nextInt(2);\r\n\t\t\tres = rand == 0;\r\n\t\t}\r\n\t\treturn res;\r\n\t}", "public boolean toDisappear() {\n\t\treturn (timer > TIME_LOOP);\n\t}", "public final boolean isReleased()\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A helper method to check the class invariant for a territory model in play (while a game is going on). If this is ever false while a game is in session something is borked.
private boolean inGameInvariant(){ if (owner != null && troops >= 1) return true; else throw new IllegalStateException("A Territory is left without a Master or Troops"); }
[ "private boolean invariant(){\n return this.square != null && this.player != null;\n }", "@Override\n public boolean isStillValid() {\n return getModel().getMainBoard().getData().getGameState().getClass() == FrameSelectionState.class;\n }", "protected boolean invariant() {\n return tru...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Select NCD Protected Claim
public void selectNCDPotectedClaim () { WebDriverWait wait = new WebDriverWait (driver, GlobalWaitTime.getIntWaitTime ()); wait.until (ExpectedConditions.elementToBeClickable (orPolicyVehicleHub.ddlNCDProtected)); Select oNCDProtectedClaims = new Select (orPolicyVehicleHub.ddlNCDProtected); int intNCDProt...
[ "public void setClaim(int claim) {\n indianClaim = claim;\n }", "java.lang.String getClaimId();", "public abstract void claim(ConquerClaim<?> claim);", "public void selectClaimsTab() {\r\n\t\tWebDriverWait wait = new WebDriverWait(driver, GlobalWaitTime.getIntWaitTime());\r\n\t\twait.until(Expecte...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get an instance of the remote repository from the coordinator
public static RemoteRepository getInstance() throws Exception { Map<String, String> propInfo = _coordinator.getPropertyInfo().getProperties(); return new RemoteRepository(propInfo.get(SYSTEM_UPDATE_REPO), propInfo.get(SYSTEM_UPDATE_PROXY), propInfo.get(SYSTEM_UPDATE_USERN...
[ "Repository getRepository();", "org.mojolang.mojo.core.Url getRepository();", "static Repo getInstance() {\n return RepoSingelton.getRepo(); //todo: refactor\n }", "URI remoteRepoUri();", "Repository find(String repositoryOwner, String repositoryName);", "RegistryMavenRepoConfig getReposito...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__Affectation__Group__2" $ANTLR start "rule__Affectation__Group__2__Impl" InternalBrowser.g:1414:1: rule__Affectation__Group__2__Impl : ( ( rule__Affectation__ExprAssignment_2 ) ) ;
public final void rule__Affectation__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalBrowser.g:1418:1: ( ( ( rule__Affectation__ExprAssignment_2 ) ) ) // InternalBrowser.g:1419:1: ( ( rule__Affectation__ExprAssignment_...
[ "public final void rule__Affect__Group__2__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalWhdsl.g:1598:1: ( ( ( rule__Affect__ExprsAssignment_2 ) ) )\n // InternalWhdsl.g:1599:1: ( ( rule__Affect__ExprsAssignment_2 )...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Getter method for the NRN number. This data is extracted from the Product object.
public String getNRN();
[ "public String getNRR() {\n return fieldNRR.getString();\n }", "public String getNtnNo() {\n return (String)getAttributeInternal(NTNNO);\n }", "public Long getNnid() {\n return nnid;\n }", "public int getN() {\n return this.n;\n }", "public java.lang.String getNwaNumb...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
This method was generated by MyBatis Generator. This method returns the value of the database column cart.invoice_id
Long getInvoiceId();
[ "public String invoiceId() {\n return this.innerProperties() == null ? null : this.innerProperties().invoiceId();\n }", "public String getInvoiceId() {\n return invoiceId;\n }", "java.lang.String getInvoiceNo();", "String getInvoiceItemSeqId();", "public int getC_InvoiceLine_ID();", "p...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets ReviewWorkflowLevelEO entity object.
public ReviewWorkflowLevelEOImpl getReviewWorkflowLevelEO() { return (ReviewWorkflowLevelEOImpl)getEntity(1); }
[ "public ReviewWorkflowEOImpl getReviewWorkflowEO() {\n return (ReviewWorkflowEOImpl)getEntity(0);\n }", "public int getWorkflowLevel() {\n\t\treturn getInternalWorkflowLevel();\n\t}", "public RowSet getLookupSharedAppModule_ApprovalLevelLOV() {\n return (RowSet) getAttributeInternal(LOOKUPSHARE...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the attribute definition associated with the specified identifier.
public AttributeDefinition isAttribute(Integer id){ return(attrByID.get(id)); }
[ "AttributeDefinition getDefinition();", "public AttributeIdentifier getAttributeIdentifier() {\n return attributeIdentifier;\n }", "public static AttributeDefName ruleAttributeDefName() {\r\n return AttributeDefNameFinder.findByName(ruleMarkerName(), true);\r\n }", "AttributeDefinition createAtt...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Gets the path to the TLS certificate file.
public String getTlsCertPath();
[ "public String getTlsCertificatePath();", "protected static String getCertificatePath() {\n return certificatePath;\n }", "public static String getTrustedCertificatePath() {\n return System.getProperty(Constants.TRUSTED_CERTIFICATE_SYSTEM_PROPERTY);\n }", "public String getUserCertificatesPath()...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns true if field viewExpandedText is set (has been assigned a value) and false otherwise
public boolean isSetViewExpandedText() { return this.viewExpandedText != null; }
[ "public boolean isExpanded() {\r\n return expanded;\r\n }", "public boolean isExpanded() {\n return expanded;\n }", "public final boolean isExpanded() {\n return expanded;\n }", "public boolean hasItemExpanded() {\n int childCount = getChildCount();\n for (int i =...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Instantiates a new ldap delegate.
public LdapDelegate() { // Initialize the config this.config = new LdapConfig(); LOGGER.debug("LdapDelegate created with {} ", this.config); }
[ "protected LdapConfig() {\n Properties properties = create(PROPERTY_NAME, LdapDelegate.class);\n this.setLdapHost(getProperty(\"ldap.host\", properties));\n this.setLdapPort(Integer.parseInt(getProperty(\"ldap.port\", properties, \"10389\")));\n this.setSecureConnection(B...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Removes a previously registered column visibility change listener
public void removeColumnVisibilityChangeListener( ColumnVisibilityChangeListener listener) { removeListener(ColumnVisibilityChangeEvent.class, listener, COLUMN_VISIBILITY_METHOD); }
[ "void columnVisibilityChanged(ColumnVisibilityChangeEvent event);", "public interface ColumnVisibilityChangeListener extends Serializable {\n /**\n * Called when a column has become hidden or unhidden.\n * \n * @param event\n */\n void columnVisibilityChanged(ColumnVi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__DefDtoSimpleVariable__NameAssignment_1" $ANTLR start "rule__DefDtoModelTypeVariable__TypeAssignment_0" InternalDtoDsl.g:1296:1: rule__DefDtoModelTypeVariable__TypeAssignment_0 : ( ( RULE_ID ) ) ;
public final void rule__DefDtoModelTypeVariable__TypeAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalDtoDsl.g:1300:1: ( ( ( RULE_ID ) ) ) // InternalDtoDsl.g:1301:2: ( ( RULE_ID ) ) { // I...
[ "public final void rule__DefDtoSimpleVariable__TypeAssignment_0() throws RecognitionException {\r\n\r\n \t\tint stackSize = keepStackSize();\r\n \t\r\n try {\r\n // InternalDtoDsl.g:1270:1: ( ( ruleType ) )\r\n // InternalDtoDsl.g:1271:2: ( ruleType )\r\n {\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Creates a new instance of SysPropertiesTest
public PropertiesTest() { }
[ "public TestProperties() {\n\t\tthis.testProperties = new Properties();\n\t}", "protected Properties newTestProperties() throws IOException\n {\n Properties props = new Properties();\n storeTestConf(props); \n return props;\n }", "SystemPropertiesType createSystemPropertiesType();", "public void t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end synpred1_PrePro Delegated rules
public final boolean synpred1_PrePro() { state.backtracking++; int start = input.mark(); try { synpred1_PrePro_fragment(); // can never throw exception } catch (RecognitionException re) { System.err.println("impossible: "+re); } boolean success = !state.failed; input.rewind(start); state.backtrack...
[ "public static void main(String[] args) {\n\t\t\n//\t\t//PA4 a\n//\t\tArrayList<ArrayList<String>> rhs1 = new ArrayList<>();\n//\t\tArrayList<String> rhs11 = new ArrayList<>();\n//\t\trhs11.add(\"S\");rhs11.add(\"a\");\n//\t\tArrayList<String> rhs12 = new ArrayList<>();\n//\t\trhs12.add(\"b\");\t\t\n//\t\trhs1.add(...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
create a guitar string whose size and initial values are given by the array
public GuitarString(double[] init){ this.init = init; //creates a RingBuffer of capacity equal to the size of the array rb = new RingBuffer(init.length); //initializes the contents of the buffer to the values in the array for(int i = 0; i < init.length; i++){ rb.enque...
[ "public GuitarString(double[] init) {\n int n = init.length;\n rb = new RingBuffer(n);\n // Enqueue input array values\n for (int i = 0; i < n; i++) {\n rb.enqueue(init[i]);\n }\n\n }", "GuitarString(double[] init)\n\t{\n\t\trb = new RingBuffer(init.length);\n\t\tt...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Returns the discovered Print Services
public PrintService[] getServices() { return services; }
[ "public PrintService[] getAvailablePrintServices() {\n services = PrintServiceLookup.lookupPrintServices(myFlavor, aset);\n return services;\n }", "public PrintService[] getPrinters()\n\t{\n\t\t PrintService[] service = PrintServiceLookup.lookupPrintServices(null, null);\n\t\t return service;\n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
double the array once current size = array size(i.e. when the list is full)
private void doDouble() { if(list_size == array_size - 1) { array_size *= 2; ListHouse[] temp = new ListHouse[array_size]; for(int i = 0; i < list_size; i++) { temp[i] = new ListHouse(); temp[i].copy(houseList[i]); } houseList = temp; } }
[ "private void doubleArray()\n\t{\n\t\tT[] oldList = list;\n\t\tint oldSize = oldList.length;\n\t\t\n\t\tlist = (T[]) new Object[2 * oldSize];\n\t\t\n\t\t// copy entries from old array to new, bigger array\n\t\tfor (int index = 0; index < oldSize; index++)\n\t\t\tlist[index] = oldList[index];\n\t}", "private void...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__EInterfaceDefinitionBody__Group_1__1" $ANTLR start "rule__EInterfaceDefinitionBody__Group_1__1__Impl" InternalAADMParser.g:14855:1: rule__EInterfaceDefinitionBody__Group_1__1__Impl : ( RULE_BEGIN ) ;
public final void rule__EInterfaceDefinitionBody__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalAADMParser.g:14859:1: ( ( RULE_BEGIN ) ) // InternalAADMParser.g:14860:1: ( RULE_BEGIN ) { // ...
[ "public final void rule__EInterfaceDefinitionBody__Group_0__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalAADMParser.g:14793:1: ( rule__EInterfaceDefinitionBody__Group_0__1__Impl )\n // InternalAADMParser.g:14794:2: ru...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Generates the options menu with all appropriate entries
private void buildOptionMenu() { // generate the options menu optionMenu = AnimalTranslator.getGUIBuilder().generateJMenu("optionsMenu", null); // generate the concrete controller for this menu OptionMenuController optionMenuController = new OptionMenuController( animalInstance);...
[ "public void generateMenu () \n {\n mCoffeeList = mbdb.getCoffeeMenu();\n for(int i =0;i<mCoffeeList.size();i++){\n coffeeTypeCombo.addItem(mCoffeeList.get(i).toString());\n }\n mWaffleList = mbdb.getWaffleMenu();\n for(int j =0;j<mWaffleList.size();j++){\n waffleTypeCo...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
populate with courses and categories
private void loadCourses(Context context) { AppDao dao = getRoomDB(context).dao(); Course dummyCourse = new Course("Dr. Click", "Software Engineering", "Learning how to code", 438, "A@lice5", 0); dao.addCourse(dummyCourse); Course addedCourse = dao.getCourseByUsername_and_Title("A@lice5...
[ "private void loadCourses() {\n this.courses = new ArrayList<>();\n DatabaseHelper db = DatabaseHelper.getInstance(this);\n\n //Get all courses\n List<Course> allCourses = db.getCourses();\n\n //Add courses relating to the term into the courses\n for(Course course : allCour...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Get the client's svap object
public Svap getSvap() { return svap; }
[ "public Stomp getClient() {\n return new IntraVMClient( this );\n }", "public java.lang.String getClientVSP() {\n java.lang.Object ref = clientVSP_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.proto...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Check that a null queue passed in does not upset the policy.
public void testNullQueueParameter() throws ConfigurationException { TopicDeletePolicy policy = new TopicDeletePolicy(); policy.configure(_config); try { policy.performPolicy(null); } catch (Exception e) { fail("Exception should not be...
[ "private static void checkQueue(String queue)\n throws FederationStateStoreInvalidInputException {\n if (queue == null || queue.isEmpty()) {\n String message = \"Missing Queue. Please try again by specifying a Queue.\";\n LOG.warn(message);\n throw new FederationStateStoreInvalidInputExceptio...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
The PosTagger class uses an internal instance of OpenNLP POSTaggerME. The model is only loaded once, when the first instance is created, and is shared among all instances.
public PosTagger() { try { //Load pos model only if it has not been loaded before if (posModel == null) { InputStream modelIn = PosTagger.class .getResourceAsStream(POSTAGGING_MODEL_PATH); posModel = new POSModel(modelIn); modelIn.close(); } //Load multiword model only if it has not been...
[ "public static PosTagger getInstance(){\n if (instance == null){\n instance = new PosTagger();\n }\n return instance;\n }", "public static PosTagger createPosTagger(ConfigurationParams params) throws InstrumentCombinationException {\r\n\t\tPosTagger posTagger = null;\r\n\t\t...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
$ANTLR end "rule__Directory__Group__0" $ANTLR start "rule__Directory__Group__0__Impl" InternalMyDsl.g:9892:1: rule__Directory__Group__0__Impl : ( 'directory' ) ;
public final void rule__Directory__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { // InternalMyDsl.g:9896:1: ( ( 'directory' ) ) // InternalMyDsl.g:9897:1: ( 'directory' ) { // InternalMyDsl.g:9897:1: ( '...
[ "public final void rule__Directory__Group__0__Impl() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalDsl.g:23238:1: ( ( 'directory' ) )\n // InternalDsl.g:23239:1: ( 'directory' )\n {\n // InternalDsl.g...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
/OkHttpClient.Builder client = new OkHttpClient.Builder(); client.cache(cache); return client.build();
@Provides @Singleton OkHttpClient provideOkhttpClient(Cache cache) { OkHttpClient.Builder httpClient = new OkHttpClient.Builder(); httpClient.addInterceptor(chain -> { Request original = chain.request(); Request.Builder requestBuilder = original.newBuilder() ...
[ "private static OkHttpClient createCachedClient(final Context context) {\n File httpCacheDirectory = new File(context.getCacheDir(), \"cache_file\");\n Cache cache = new Cache(httpCacheDirectory, 20 * 1024 * 1024);\n OkHttpClient okHttpClient = new OkHttpClient.Builder().addNetworkInterceptor(n...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Requires: nothing Modifies: .fmdb file Effects: reads serializable object from .fmdb file, and creates a new fmdb from it note: read is static because we need to use this method to construct from file (acts like constructor)
public static Fmdb read() throws IOException, ClassNotFoundException { FileInputStream fileInputStream = new FileInputStream(".fmdb"); ObjectInputStream objectInputStream = new ObjectInputStream(fileInputStream); Fmdb fmdb = (Fmdb) objectInputStream.readObject(); objectInputStream.close(...
[ "private MRFile F2MRFile (File f) throws Exception{\n\t\tMRFile mrf = null;\n\t\tif(f.isFile()) {\n\t\t\ttry {\n\t\t\t\tFileInputStream fis = new FileInputStream(f);\n\t\t\t\tObjectInputStream ois = new ObjectInputStream(fis);\n\t\t\t\tArrayList<Object> A = (ArrayList<Object>) ois.readObject();\n\t\t\t\tois.close()...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Helper method that removes objects from the objectstate map and the stateobject map. This does not cancel tasks.
protected void doRemoveFromState(Collection<?> objects) { State lastState = null; Set<Object> objsInLastState = New.set(); synchronized (myObjectToStateMap) { for (Object obj : objects) { State oldState = myObjectToStateMap.get(obj); ...
[ "public void removeAll()\r\n {\r\n synchronized (myObjectToStateMap)\r\n {\r\n myAllObjects = null;\r\n synchronized (myTaskMap)\r\n {\r\n for (Task task : myTaskMap.values())\r\n {\r\n task.cancelAll();\r\n ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
String that is printed out at the end of the GA.
public String printGAEnd( Environment environment ) { Individual best; // best individual in population best = environment.getPopulation().getBestIndividual(); return "Most fit individual:\n" + best.toString() + "\n"; }
[ "public String toString()\n\t{\n\t\tString scriptsOutput = \"{\";\n\t\tfor (int i=0 ; i<scripts.length ; i++)\n\t\t{\n\t\t\tscriptsOutput += scripts[i];\n\t\t\tif (i<scripts.length-1)\n\t\t\t\tscriptsOutput += \",\";\n\t\t}\n\t\tscriptsOutput += \"}\";\n\t\treturn this.agentName + \" v\" + version + \", Reporting m...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
A custom note associated with the customer profile.
@ApiModelProperty(value = "A custom note associated with the customer profile.") public String getNote() { return note; }
[ "public java.lang.String getCustomer_note() {\n return customer_note;\n }", "public String getCustomerNotes() {\n return this.customerNotes;\n }", "public String getCustomerRemark() {\n return customerRemark;\n }", "public String getUserNote() {\r\n return userNote;\r\n }", ...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
Initialisiert Register 8001 und setzt vordefinierte Werte.
private Speicher initializeRegister8001(Speicher speicher){ Bit[] bits = new Bit[8]; bits[0] = new Bit( 1, 0); bits[1] = new Bit( 1, 0); bits[2] = new Bit( 1, 0); bits[3] = new Bit( 1, 0); bits[4] = new Bit( 1, 0); bits[5] = new Bit( 1, 0); bits[6] = new B...
[ "private Speicher initializeRegister0801(Speicher speicher){\n Bit[] bits = new Bit[8];\n bits[0] = new Bit( 0, 0);\n bits[1] = new Bit( 0, 0);\n bits[2] = new Bit( 0, 0);\n bits[3] = new Bit( 0, 0);\n bits[4] = new Bit( 0, 0);\n bits[5] = new Bit( 0, 0);\n bi...
{ "objective": { "paired": [], "self": [], "triplet": [ [ "query", "document", "negatives" ] ] } }