__key__
stringlengths
16
21
__url__
stringclasses
1 value
txt
stringlengths
183
1.2k
funcom_train/14464197
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addCell(CellHandle cx) throws Exception{ CellRange[] rngs = getCellRanges(); if(rngs.length>1) { throw new WorkBookException("NamedRange.addCell failed -- more than one cell range defined in this NameHandle, cannot determine where to add cell.",WorkBookException.RUNTIME_ERROR); } rngs[0].addCellToRange(cx); setLocation(rngs[0].getRange()); } COM: <s> add a cell to this named range </s>
funcom_train/46761934
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public VisitModel getVisit(final long visitId, final ServiceCall call) throws Exception { IBeanMethod method = new IBeanMethod() { public Object execute() throws Exception { if (call.isStoreAudit()) { BaseData.getSecurity().storeAudit(call.getUserRefId(), visitId, "Viewed Visit", call); } return PatientData.getVisit(visitId, call); }}; return (VisitModel) call(method, call); } COM: <s> return the single visit model for the primary key </s>
funcom_train/42535405
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean equals(Object o){ if(!(o instanceof GrpRang))return false; if(o == this)return true; GrpRang oo = (GrpRang)o; return (((Object)s).equals(oo.s))&&(((Object)e).equals(oo.e)); } COM: <s> is the given object equal to this grp rang </s>
funcom_train/16177092
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Node getRandomNodeOut() { if (outEdges.size() > 0) { int index = Random.uniform.nextIntFromTo(0, outEdges.size() - 1); Edge e = (Edge)outEdges.get(index); return e.getTo(); } return null; } COM: <s> gets a node at random from the list of out edges </s>
funcom_train/4814160
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String getAboutText(Game game) { StringBuffer aboutText = new StringBuffer(game.getName()); aboutText.append("<br>Game design &copy; Rudi Hoffman"); aboutText.append("<br>Java implementation by Andrew Swan"); aboutText.append("<br>Some sound effects from http://www.grsites.com"); return aboutText.toString(); } COM: <s> returns the help about text </s>
funcom_train/45231194
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void read(DataInputStream in, int length) throws IOException { // /* Debug */ System.err.println("About to read a string of length " + length); byte[] bytes = new byte[length]; in.readFully(bytes); setValue(new String(bytes)); // /* Debug */ System.err.println("Read a string: " + value); } COM: <s> read in a vsmstring from a stream </s>
funcom_train/20514458
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void delete(FichaEndodontica entity) { LogUtil.log("deleting FichaEndodontica instance", Level.INFO, null); try { entity = entityManager.getReference(FichaEndodontica.class, entity .getNumeroProntuario()); entityManager.remove(entity); LogUtil.log("delete successful", Level.INFO, null); } catch (RuntimeException re) { LogUtil.log("delete failed", Level.SEVERE, re); throw re; } } COM: <s> delete a persistent ficha endodontica entity </s>
funcom_train/5070294
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void updatePairs() throws BadLocationException { if (fDocument instanceof IDocumentExtension4) { IDocumentExtension4 document = (IDocumentExtension4) fDocument; if (document.getModificationStamp() == cachedStamp) { return; } } else { String content = fDocument.get(0, fDocument.getLength()); if (content.hashCode() == cachedHash) { return; } } recalc(); } COM: <s> recalcs pairs for the document only if it is required </s>
funcom_train/2739877
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String mod(List<Term> argsTerm) { String left = env.tp.visit(argsTerm.get(0)); String right = env.tp.visit(argsTerm.get(1)); if(Util.simplify) { try { int leftNumber = Integer.parseInt(left); int rightNumber = Integer.parseInt(right); return String.valueOf(leftNumber % rightNumber); } catch(NumberFormatException e) {} } return Util.setPars(left + " mod " + right); } COM: <s> executes the mod function </s>
funcom_train/18656918
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JMenu findMenu(JMenuBar MenuBar,final String Name){ JMenu CurrentMenu=null; for(int ix=0;ix<MenuBar.getMenuCount();ix++){ CurrentMenu=MenuBar.getMenu(ix); String CurrentMenuText=CurrentMenu.getText(); if(CurrentMenuText.equals(Name)==true) return CurrentMenu; } return null; // not found } COM: <s> find a menu by its name </s>
funcom_train/35952430
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void writeToFile(JuxtaDocument document, File sourceFile) throws ReportedException { JuxtaDocumentWriter documentWriter = new JuxtaDocumentWriter(document); try { documentWriter.writeDocument(sourceFile); } catch (IOException e) { throw new ReportedException(e, "An error occurred writing the file " + sourceFile); } } COM: <s> writes the document to the target source file </s>
funcom_train/50329949
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void configure() { // connect to the traffic controller EcosTrafficController control = new EcosTrafficController(); control.connectPort(this); control.setAdapterMemo(adaptermemo); adaptermemo.setEcosTrafficController(control); adaptermemo.configureManagers(); jmri.jmrix.ecos.ActiveFlag.setActive(); } COM: <s> set up all of the other objects to operate with an ecos command </s>
funcom_train/18089912
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void updateProgressBar() { if (progressBar != null) { if (m.isDownloadOnGoing()) { progressBar.min = m.getStartAddr(); progressBar.max = m.getEndAddr(); progressBar.setValue(m.getNextReadAddr(), "", " b"); } progressBar.setVisible(m.isDownloadOnGoing()); progressLabel.setVisible(m.isDownloadOnGoing()); } } COM: <s> update the progress bar </s>
funcom_train/14009140
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void loadAuthenticationCredentials(BlogUser blogUser) throws BlojsomException { // Now load the list of acceptible LDAP user ID's from the // authorization properties file, if available. try { super.loadAuthenticationCredentials(blogUser); } catch (Exception be) { // Do nothing, as we don't have to use the auth file if not there, // or if bad, authorize will indicate error. } } COM: <s> loads configures the authentication credentials for a given blog </s>
funcom_train/21336486
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean execute(Player p, String pwd) { byte[] encodedPwdFile = getPasswordFileContent(p); if (encodedPwdFile == null) { throw new IllegalStateException("No encoded password for " + p); } byte[] decodePwdFile = CryptoUtil.decode(encodedPwdFile); return Arrays.equals(decodePwdFile, pwd.getBytes()); } COM: <s> do service job </s>
funcom_train/21913268
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addUmlPackagePropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_PackageFolder_umlPackage_feature"), getString("_UI_PropertyDescriptor_description", "_UI_PackageFolder_umlPackage_feature", "_UI_PackageFolder_type"), UIMPackage.Literals.PACKAGE_FOLDER__UML_PACKAGE, true, false, true, null, null, null)); } COM: <s> this adds a property descriptor for the uml package feature </s>
funcom_train/4923510
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Node getFirstDirectChild(Node parent, String tagName) { // Search for the first direct child with Tag Name NodeList children = parent.getChildNodes(); for (int i = 0; i < children.getLength(); i++) { Node child = children.item(i); if (tagName.equals(child.getNodeName())) { return child; // found direct child by Tag Name } } // As here, did not find child return null; } COM: <s> obtains the first direct child </s>
funcom_train/24661956
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean validationChecks(){ if(username.equalsIgnoreCase("crony")){ JOptionPane.showMessageDialog(AppLoginFrame.getInstance(), "You can not" + " have \"crony\" as your username", "Error", JOptionPane.ERROR_MESSAGE); return false; } return true; } COM: <s> performs primary validation checks on username and password to detect </s>
funcom_train/51066740
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private OSVersionPredicate vid_vp ( FHandle fhandle ) { OSVersionPredicate vp; long timestamp = fhandle_to_time( fhandle ); if( timestamp == 0 ) { // No specified time; use current version. vp = new OSVPOnNode(); } else { Date needed = new Date( timestamp ); // two-parameter constructor requires the exact timestamp. vp = new OSVPTimed( needed, needed ); } return vp; } COM: <s> returns a version predicate appropriate for requesting the </s>
funcom_train/43889670
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void ensureFileExists(final File file) throws FileNotFoundException { if (!file.isFile() || !file.canRead()) { throw new FileNotFoundException(getErrorResources() .getString(ErrorKeys.FILE_DOES_NOT_EXIST_$1, file)); } } COM: <s> ensures that the specified file can be read </s>
funcom_train/3010268
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public List getTypesForLovOID( Long p_lovOID ) { List types = null; LovEntityCacheItem item = (LovEntityCacheItem) _cache.get( p_lovOID ); if ( item != null ) { // We have a types (ie. SQL statement), we will return it types = item.getTypes(); } return types; } COM: <s> returns a collection of type corresponding to the the metadata or null if </s>
funcom_train/40769017
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String encodeChar(char c) { String cS = Character.toString(c); // Note: I don't encode & or =, b/c those are valid url querystring chars String s = ""; if (cS.matches("[a-zA-Z0-9_.\\-~&=]") == false) { s = "%" + Byte.toString((byte) c); } else { s = cS; } return s; } COM: <s> encode char to there asii table using as the delimiter </s>
funcom_train/19967261
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void loadVectors(){ SAXBuilder sxb = new SAXBuilder(); try { org.jdom.Document document = sxb.build(new File(file)); List<Element> vectorsElement = document.getRootElement().getChildren(EXPLAINED_VECTOR); for (Element vector : vectorsElement){ V3 vect = createExplainedSemanticVector(vector); vectors.put(vect.getVector().getId(),vect); } } catch (JDOMException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } } COM: <s> loads vectors from a xml file </s>
funcom_train/22489901
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void finishTag () { EBindingTableColumn[] columns= new EBindingTableColumn[_columns.size()]; _columns.copyInto(columns); _compDesc.setModel( new EBindingTableModel( _compDesc.getDelegate(""), _dataPath, columns ) ); // TODO cleanup model value binding _compDesc.setProperty( EComponentDescriptor.PROP_MODEL_DATAPATH, _dataPath ); } COM: <s> creates the binding table model </s>
funcom_train/31702080
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void drawLine(int x1, int y1, int x2, int y2) { final GL gl = getGL(); gl.glBegin(GL.GL_LINE_STRIP); gl.glVertex3f(x1, -y1, 0); gl.glVertex3f(x2, -y2, 0); gl.glEnd(); } COM: <s> draws a line </s>
funcom_train/20845465
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void handleDeviceStateUp(String xaddrs, String endpointAddress, int metadataVersion) { if (GlobalConstants.GLOBAL_LOGGING) LogServiceTracker.log.log(LogService.LOG_WARNING, "Device " + duuid + " is running!"); if (GlobalConstants.GLOBAL_LOGGING) LogServiceTracker.log.log(LogService.LOG_DEBUG, "Checking device for changes..."); ProxyManager.getInstance().getDevicesQueue().enqueue(new DeviceQueueElement(duuid, DeviceQueueElement.EVENT_HELLO)); } COM: <s> enqueue the dpws device to check it for updates </s>
funcom_train/5464701
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testAddKey() { //add the key Keystore ks = KeyStoreFactory.getDefaultKeystore(null); ks.addKey("profileXXX", key1, "passwordXXX", "username1"); //retrieve it to validate byte[] key = ks.findKey("profileXXX", "passwordXXX"); assertTrue( equals(key, key1) ); String user = ks.getUsername("profileXXX"); assertTrue("username1".equals(user)); } COM: <s> test the adding of a key </s>
funcom_train/11663755
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void dropDocumentMeta(Collection collection, String id) throws DBException { Collection mcol = getMetaCollection(collection, false); if (null != mcol) { try { mcol.remove(id); } catch (DBException e) { if (log.isWarnEnabled()) { log.warn("ignored exception", e); } } } } COM: <s> drop document meta removes the meta data for the specified </s>
funcom_train/3118931
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean tryExportAsVoiceXML(final Window parentWindow) { final File newFile = FileDialogUtils.showExportVoiceXMLDialog(parentWindow); if (newFile != null) { exportVoiceXML(newFile, parentWindow); logger.info(this + ": export as VoiceXML"); return true; } else { return false; } } COM: <s> tries to export this document as a voice xml file </s>
funcom_train/20978767
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JTextField getEdGameName() { if (edGameName == null) { edGameName = new JTextField(); edGameName.setName("TEXTFIELD_GAMENAME"); edGameName.setBounds(new Rectangle(254, 87, 256, 20)); } return edGameName; } COM: <s> this method initializes ed game name </s>
funcom_train/3559917
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void showData(Integer pEditorID) throws DbException { if (!isInitialized()) init(); editorID = pEditorID; MoreSwingUtilities.disableTabs(tbdEditorDetails); loadEditorDetails(); MoreSwingUtilities.enableTab(tbdEditorDetails, 0); panDataView.setIndex(editorID); panDataView.showItems(); MoreSwingUtilities.enableTab(tbdEditorDetails, 1); } COM: <s> shows the data </s>
funcom_train/39953036
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean removeOutgoingTransition(TransitionImpl transition) { if ( (transition!=null) && (outgoingTransitions!=null) ) { boolean isRemoved = outgoingTransitions.remove(transition); if (isRemoved) { transition.setSource(null); if (outgoingTransitions.isEmpty()) { outgoingTransitions = null; } outgoingTransitionsMap = null; } return isRemoved; } return false; } COM: <s> removes the given transition from the leaving transitions </s>
funcom_train/32154881
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void askMasterToTerminate(boolean broadcast) { if (!this.terminate) { Message msg = this.createMessage(Commands.MASTER); msg.addContents(Commands.BROADCAST_SYSTEM_MSG, new Boolean(broadcast)); msg.addContents(Commands.END_STATE, this.myAgent.endState); msg.setReceiverId(AbstractMaster.MasterId); this.myAgent.sendMessage(msg); this.terminate = true; } } COM: <s> use this method to ask master to broadcast system message termination </s>
funcom_train/12164529
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void checkValue(CacheValue value, CacheConfiguration cache) { assertEquals(value.name, cache.getName()); assertEquals(value.strategy, cache.getStrategy()); assertEquals(value.maxEntries, cache.getMaxEntries()); assertEquals(value.maxAge, cache.getMaxAge()); } COM: <s> check that the cache values read match those expected </s>
funcom_train/25792119
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String getEntityToolTip(VisualItem entity) { m_tooltipContents.delete(0, m_tooltipContents.length()); int entityId = (Integer) entity.get(Entity.ID_FIELDNAME); String entityName = (String) entity.get(Entity.NAME_FIELDNAME); Entity.Type entityType = (Entity.Type) entity.get(Entity.TYPE_FIELDNAME); m_tooltipContents.append("<html>"); m_tooltipContents.append("<b>"); m_tooltipContents.append(entityName); m_tooltipContents.append(" "); m_tooltipContents.append(entityId); m_tooltipContents.append("<br><br>Type:</b><br>"); m_tooltipContents.append(entityType); m_tooltipContents.append("</html>"); return m_tooltipContents.toString(); } COM: <s> get the contents of a tool tip for an entity by the given </s>
funcom_train/4833833
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean leaveAuction(EntertainmentAuction auction){ boolean changed = (auction.getMyBids().isEmpty()) ? false : true; Iterator<EntertainmentInfo> it1 = auction.getMyBids().iterator(); // iterate over all ticket I started to bid for while(it1.hasNext()){ EntertainmentInfo ei = it1.next(); ei.startBidding = false; if(ei.getAssignedClient()>=0){ busyDays[ei.getAssignedClient()].remove(new Integer(ei.getDay())); ei.setDay(-1); } it1.remove(); } return changed; } COM: <s> free the client needs from inactive auction return </s>
funcom_train/28983016
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void initialize(ILowPan lowPan) { this.outputQueue = new Queue(); this.keepRunning = true; this.lowPan = lowPan; this.gearManager = GEARManager.getInstance(); this.routingTopology = RoutingTopology.getInstance(); this.forwardingEngine = ForwardingEngine.getInstance(); } COM: <s> initializes the instance output </s>
funcom_train/39388578
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Object clone() { Pose copy; try { copy = (Pose)super.clone(); // Makes deep copy copy.coordinate = (Coordinate)coordinate.clone(); return copy; } catch (CloneNotSupportedException e) { // Should never see this e.printStackTrace(); return null; } } COM: <s> makes a copy of all fields including deep copy of the </s>
funcom_train/16786732
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public PageArrayList getResponsibleDepartments() throws RQLException { Project project = getProject(); String responsiblityPagesCacheId = getResponsiblityPagesCacheId(); PageArrayList rowPages = project.getPages(responsiblityPagesCacheId); if (rowPages == null) { // get row pages com.hlcl.rql.as.List departmentsList = getDepartmentsTableList(); rowPages = departmentsList.getChildPages(); // cache within project project.putPages(responsiblityPagesCacheId, rowPages); } return rowPages; } COM: <s> returns the responsibility departments pages cached within project </s>
funcom_train/49470115
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean addProductAlias(ProductId pid, String alias) throws Exception, RaciException{ Db db = dbRW(); try{ db.begin(); _logger.info("Asset : addProductAlias "+pid+", "+alias); checkUserCanModify(db); DbAliases.addProductAlias(db, pid, alias, getCurrentUser()); db.commit(); return true; } catch (Exception e) { store(e); throw e; } finally { db.safeClose(); } } COM: <s> add an alias for a product </s>
funcom_train/935885
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private SemijoinList findSemiJoinsAtSite(Relation assemblysite) { SemijoinList atassemblysite = new SemijoinList(); for (Iterator i2 = this.joinsinEF.getList().iterator(); i2.hasNext(); ) { Semijoin join = (Semijoin) i2.next(); if (join.getLeft().equals(assemblysite)) { atassemblysite.add(join); } } return atassemblysite; } COM: <s> finds all semijoins with the given relation as their left hand side </s>
funcom_train/36558790
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public VBOInfo copy() { VBOInfo copy = new VBOInfo(); copy.useVBOVertex = useVBOVertex; copy.useVBOTexture = useVBOTexture; copy.useVBOColor = useVBOColor; copy.useVBONormal = useVBONormal; copy.useVBOTangent = useVBOTangent; copy.useVBOBinormal = useVBOBinormal; copy.useVBOIndex = useVBOIndex; copy.useVBOFogCoords = useVBOFogCoords; return copy; } COM: <s> creates a copy of this vboinfo </s>
funcom_train/33289940
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int totalSize() { Iterator x_iter = o_hashtable.keySet().iterator(); Object x_key = null; Vector x_vector = null; int sum = 0; while (x_iter.hasNext()) { x_key = x_iter.next(); x_vector = (Vector) (o_hashtable.get(x_key)); sum += x_vector.size(); } return sum; } COM: <s> get the sum of the sizes of all the vectors </s>
funcom_train/42652445
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testUnaryConstructor() { PropertyRestriction restriction = new PropertyRestriction("unary", Operation.EQUALS, new Integer(1)); assertEquals("unary", restriction.getTargetName()); assertEquals(Operation.EQUALS, restriction.getOperation()); assertEquals(1, restriction.getOperands().size()); assertEquals(1, restriction.getOperands().get(0)); } COM: <s> tests the contructor corresponding to unary operations </s>
funcom_train/48960804
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: @Override public MimeMessage createMessage(Collection<IWebJTrackerUser> users) { MimeMessage message = createMessage(); if (CollectionUtils.isNotEmpty(users)) { for (IWebJTrackerUser user : users) { addAddress(message, getAddress(user)); } } return message; } COM: <s> delegates message creation and sets multiple destinations </s>
funcom_train/10299320
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setInvoker(Component invoker) { this.invoker = invoker; // If we have a JMenuItem circulate up to the JMenu if (invoker instanceof JMenuItem) { while (!(this.invoker instanceof JMenu)) { this.invoker = this.invoker.getParent(); if (this.invoker instanceof JPopupMenu) { this.invoker = ((JPopupMenu)this.invoker).getInvoker(); } } } if (this.invoker == null) { throw new IllegalArgumentException("invoker"); } } COM: <s> set the invoking component for this popup </s>
funcom_train/22236431
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void Sensor2D(Object[] sensor) { if (sensor.length != 1) throw new IllegalArgumentException ("Sensor2D requires a single name or Sensor instance") ; if (sensor[0] instanceof String) sensor2DName = (String)sensor[0] ; else if (sensor[0] instanceof Sensor) sensor2D = (Sensor)sensor[0] ; else throw new IllegalArgumentException ("Sensor2D must be a name or a Sensor instance") ; } COM: <s> property which sets a 2 d sensor for manipulating the view platform </s>
funcom_train/14247358
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: /*public void categoryRead(Boolean selected) throws SQLException, IOException { if(junkIds.size() == 0) return; int junkId = ((Integer)junkIds.get(junkIdPosition)).intValue(); dao.junkMail.setIsRead(junkId, selected.booleanValue()); next(); }*/ COM: <s> user clicks read </s>
funcom_train/22550150
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void enterBitrateAtom(int atom, int skip, DataInputStream in) throws IOException { int length = enterAtom(atom, in); length -= IOUtils.ensureSkip(in,skip); int avgBitrate = in.readInt(); length -= 4; setBitrate(avgBitrate/1000); // bits to kbits IOUtils.ensureSkip(in,length); // ignore the rest of this atom } COM: <s> retrieve the bitrate </s>
funcom_train/3083520
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void updateLeadIndex() { if (leadPath != null) { if (selection == null) { leadPath = null; leadIndex = leadRow = -1; } else { leadRow = leadIndex = -1; for (int counter = selection.length - 1; counter >= 0; counter--) { if (selection[counter].equals(leadPath)) { leadIndex = counter; break; } } } } } COM: <s> updates the lead index instance variable </s>
funcom_train/24533315
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: static public String tokensToString(char tokens[][]) { StringBuffer buf = new StringBuffer() ; for (int i=0; i<tokens.length; i++) { if (i>0 && buf.length()>0) buf.append(".") ; //$NON-NLS-1$ buf.append(tokens[i]) ; } return buf.toString() ; } COM: <s> convert an array of token elements to a </s>
funcom_train/22278551
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Rect interiorRect() { Rect tmpRect; if (border != null) tmpRect = border.interiorRect(0, 0, width(), height()); else tmpRect = new Rect(0, 0, width(), height()); if (titleField._superview != null) { tmpRect.y += titleField.bounds.height; tmpRect.height -= titleField.bounds.height; } return tmpRect; } COM: <s> returns the area not used by the container view to draw its bounds </s>
funcom_train/3345465
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public FileRecord getRootDirectory() throws IOException { if (rootDirectory == null) { // Read the root directory final MasterFileTable mft = getMFT(); rootDirectory = mft.getRecord(MasterFileTable.SystemFiles.ROOT); log.info("getRootDirectory: " + rootDirectory.getFileName()); } return rootDirectory; } COM: <s> gets the root directory on this volume </s>
funcom_train/14123331
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void createButtons() { newButton = new HTML("<a href='javascript:;" + mediator.getMessageValue(IGWTMessageKeys.LINK_NEW) + "</a>", true); newButton.setStyleName("form_note"); newButton.addClickListener(aClickListener); } COM: <s> create button new for adding new mail folders </s>
funcom_train/644439
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void switchToOptionCalculation(DialogOptions dialogOptions) { this.dialogOptions = dialogOptions; CardLayout cl = (CardLayout) (dialogOptions.getPanelOptions().getLayout()); cl.show(dialogOptions.getPanelOptions(), PersistenceManager.Values.CARD_CALCULATION.name()); dialogOptions.setSelectedOption(PersistenceManager.Values.CARD_CALCULATION.name()); } COM: <s> switches to the calculation category in the option dialog </s>
funcom_train/45740817
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Command getItemSimulateWriteCommand () { if (itemSimulateWriteCommand == null) {//GEN-END:|23-getter|0|23-preInit // write pre-init user code here itemSimulateWriteCommand = new Command ("Simulate write", Command.ITEM, 0);//GEN-LINE:|23-getter|1|23-postInit // write post-init user code here }//GEN-BEGIN:|23-getter|2| return itemSimulateWriteCommand; } COM: <s> returns an initiliazed instance of item simulate write command component </s>
funcom_train/43360624
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getDaysToDownload() { int ret = 0; int numGrabbers = setupInternalGrabbers(); if (numGrabbers > 0) { Grabber grabber = (Grabber)m_grabbers.get(ZAPSCRAPER); if (grabber instanceof ZapScraperGrabber) { ret = ((ZapScraperGrabber)grabber).getDaysToDownload(); } } return ret; } COM: <s> getter for property m days to download </s>
funcom_train/18862399
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected Translator createDataSourceTranslator() { GenericTranslator translator = new GenericTranslator(DATA_SOURCE, STRUTS_CONFIG_PACKAGE.getDataSourcesType_Sources()); translator .setChildren(new Translator[] { IDTranslator.INSTANCE, CLASS_NAME_TRANSLATOR, new Translator(ATTR_KEY, STRUTS_CONFIG_PACKAGE .getDataSourceType_Key(), DOM_ATTRIBUTE | CDATA_CONTENT), new Translator(ATTR_TYPE, STRUTS_CONFIG_PACKAGE .getDataSourceType_Type(), DOM_ATTRIBUTE | CDATA_CONTENT), createSetPropertyTranslator() }); return translator; } COM: <s> creates the translator that maps the data source xml element to the </s>
funcom_train/50846155
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetMoreResults() throws Exception { String sql = "select * from customer"; Statement stmt = newStatement(); boolean expResult = true; boolean result = stmt.execute(sql); assertEquals(expResult, result); expResult = false; result = stmt.getMoreResults(); sql = "delete from customer where 1=0"; stmt.execute(sql); expResult = false; result = stmt.getMoreResults(); assertEquals(expResult, result); } COM: <s> test of get more results method of interface java </s>
funcom_train/16522096
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: static public void createMap(String version){ //System.out.println(version); if(version.equals("EL2006/690/EC")){ exemptFile = "Exempt"; } else if(version.equals("1.0")){ exemptFile = "Exempt-old"; } // System.out.println(version); exempt = createListEditor(dir+exemptFile); } COM: <s> create the exemption list according to the ipc version </s>
funcom_train/44287279
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String pathOfFilesFromLib() { File inFile = null; String path = XMLWrapper.USERDIR + XMLWrapper.SLASH + "lib" + XMLWrapper.SLASH; inFile = new File(path); if (inFile.exists()) return path; path = XMLWrapper.USERDIR + XMLWrapper.SLASH + ".." + XMLWrapper.SLASH; inFile = new File(path); if (inFile.exists()) return path; return null; } COM: <s> returns the list of files from the library </s>
funcom_train/1571756
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String inputElementNameInContext(final WOContext _ctx) { if (this.name == null) { return _ctx.elementID(); } final String s = this.name.stringValueInComponent(_ctx.cursor()); if (s != null) return s; return _ctx.elementID(); } COM: <s> checks whether the name binding is set </s>
funcom_train/41842100
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String getSearchResultsFromSearchEngines(String queryUrl,String query, int pageNum){ String modifiedQuery = query.replace(" ", "+"); queryUrl = queryUrl.replace("ryque", modifiedQuery); String page = Integer.toString(pageNum); queryUrl = queryUrl.replace("agep", page); return searchEngines(queryUrl); } COM: <s> get the html document by substituting the search string and the page number </s>
funcom_train/1265166
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean validateBPELVariableNames_MinLength(List<?> bpelVariableNames, DiagnosticChain diagnostics, Map<Object, Object> context) { int length = bpelVariableNames.size(); boolean result = length >= 1; if (!result && diagnostics != null) reportMinLengthViolation(ExecutablePackage.eINSTANCE.getBPELVariableNames(), bpelVariableNames, length, 1, diagnostics, context); return result; } COM: <s> validates the min length constraint of em bpel variable names em </s>
funcom_train/44588922
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void bufferChanged(BufferChangedEvent event) { if (event.getBuffer().isClosed()) { JavaModelManager.getJavaModelManager().getElementsOutOfSynchWithBuffers().remove(this); getBufferManager().removeBuffer(event.getBuffer()); } else { JavaModelManager.getJavaModelManager().getElementsOutOfSynchWithBuffers().add(this); } } COM: <s> the buffer associated with this element has changed </s>
funcom_train/4786405
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean doMakeFocusedRowVisible() { if (numRowsVisible < 1) { return false; } int topRowDelta = computeTopRowDelta(currentRow); if (topRowDelta == 0) { return false; } currentRow += -1 * topRowDelta; setTopRow(topRow + topRowDelta); Control control = getControl(currentColumn, currentRow); if (control != null) { control.setFocus(); // ?? Can I get away with avoiding asyncExec here ?? } return true; } COM: <s> makes sure that the focused row is visible </s>
funcom_train/16768744
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void rawBufferReceived(RTMPTConnection conn, RTMP state, IoBuffer in) { log.debug("rawBufferRecieved: {}", in); if (state.getState() != RTMP.STATE_HANDSHAKE) { log.warn("Raw buffer after handshake, something odd going on"); } log.debug("Writing handshake reply, handskake size: {}", in.remaining()); RTMPHandshake shake = new InboundHandshake(); shake.setHandshakeType(RTMPConnection.RTMP_NON_ENCRYPTED); conn.rawWrite(shake.doHandshake(in)); } COM: <s> handle raw buffer received </s>
funcom_train/46457725
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected boolean isDisallowedName(Object obj, String name) { boolean disallowed = super.isDisallowedName(obj, name); if (functionEditors != null) { for (int i = 0; i < functionEditors.length; i++) { disallowed = disallowed || functionEditors[i].isDisallowedName(null, name); } } return disallowed; } COM: <s> returns true if a name is already in use </s>
funcom_train/23671164
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addItems(int index, List<E> items) { final int index0 = index; final int index1 = index+items.size() - 1; for( int i = 0 ; i < items.size(); i++ ) { itemList.add(index0+i, items.get(i)); } listeners.intervalAdded(new ListModelEvent<E>(index0, index1)); } COM: <s> add itme at position </s>
funcom_train/11125094
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void awaitShutdown(long timeout) throws InterruptedException { synchronized (this.statusMutex) { long deadline = System.currentTimeMillis() + timeout; long remaining = timeout; while (this.status != IOReactorStatus.SHUT_DOWN) { this.statusMutex.wait(remaining); if (timeout > 0) { remaining = deadline - System.currentTimeMillis(); if (remaining <= 0) { break; } } } } } COM: <s> blocks for the given period of time in milliseconds awaiting </s>
funcom_train/47159302
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void repaintHandles() { Rectangle bounds = null; for (Handle handle : selectionHandles) { if (bounds == null) { bounds = handle.getDrawingArea(); } else { bounds.add(handle.getDrawingArea()); } } if (bounds != null) { repaint(bounds); } } COM: <s> repaints the handles </s>
funcom_train/1684968
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void kickPlayer(){ if( JOptionPane.OK_OPTION == JOptionPane.showConfirmDialog(this, "Do you really want to kick the player: " + /*TODO getPlayer()*/tablePlayers.getSelectedRow(), "Kick player", JOptionPane.YES_NO_OPTION) ){ labelWaitingForAnswer.setVisible(true); //TODO sending the server a message to kick this player } } COM: <s> asks the host whether he wants to kick one player and </s>
funcom_train/20045398
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void _getCellNames(){ // getCellNames() log.println( "test for getCellNames()" ); cellNamesList = oObj.getCellNames(); boolean result = cellNamesList.length == ( nRow * nCol ) ; result &= cellNamesList[0].equals( "A1" ) ; tRes.tested( "getCellNames()", result ) ; } COM: <s> obtains cell names of the table </s>
funcom_train/3420660
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void saveBaseURI() { fBaseURIScope.push(fDepth); fBaseURI.push(fCurrentBaseURI.getBaseSystemId()); fLiteralSystemID.push(fCurrentBaseURI.getLiteralSystemId()); fExpandedSystemID.push(fCurrentBaseURI.getExpandedSystemId()); } COM: <s> saves the current base uri to the top of the stack </s>
funcom_train/18322992
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addTypePropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_BinaryOperation_type_feature"), getString("_UI_PropertyDescriptor_description", "_UI_BinaryOperation_type_feature", "_UI_BinaryOperation_type"), MetalangPackage.Literals.BINARY_OPERATION__TYPE, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the type feature </s>
funcom_train/8394876
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isIphoneOrIpod() { //We repeat the searches here because some iPods may report themselves as an iPhone, which would be okay. if (userAgent.indexOf(deviceIphone) != -1 || userAgent.indexOf(deviceIpod) != -1) { return true; } return false; } COM: <s> detects if the current device is an i phone or i pod touch </s>
funcom_train/34342871
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public TextField getMonto4() { if (Monto4 == null) {//GEN-END:|50-getter|0|50-preInit // write pre-init user code here Monto4 = new TextField("Monto", null, 8, TextField.ANY);//GEN-LINE:|50-getter|1|50-postInit // write post-init user code here }//GEN-BEGIN:|50-getter|2| return Monto4; } COM: <s> returns an initiliazed instance of monto4 component </s>
funcom_train/1719215
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Foo getObject() { log.debug("getObject called"); Foo fooOut = null; //if we have a foo already set then return it if (foo != null) { fooOut = foo; } else { //create a new foo fooOut = new Foo(); fooOut.setArray(new Object[]{"test1", "test2", "test3"}); fooOut.setId(42); fooOut.setName("testfoo"); fooOut.setReady(true); } return fooOut; } COM: <s> sends back a foo </s>
funcom_train/43244879
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetConnectionInfo() { System.out.println("setConnectionInfo"); String connectionInfo = ""; ServerStatusObject instance = new ServerStatusObject(); instance.setConnectionInfo(connectionInfo); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } COM: <s> test of set connection info method of class org </s>
funcom_train/10510077
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void fireTargetFinished(Target target, Throwable exception) { BuildEvent event = new BuildEvent(target); event.setException(exception); BuildListener[] currListeners = listeners; for (int i = 0; i < currListeners.length; i++) { currListeners[i].targetFinished(event); } } COM: <s> send a quot target finished quot event to the build listeners </s>
funcom_train/29919830
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void rollback() throws SQLException { rollbackDate = Factory.getTimeMilliseconds(); realConnection.rollback(); Register.append(this, rollbackDate, rollbackDate, Factory.getTimeMilliseconds(), getClass() .getName(), "rollback (ro)", sbRollback.toString()); } COM: <s> execute roolback command </s>
funcom_train/17744270
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void write(int c) { int newcount = count + 1; if (newcount > buf.length) { char newbuf[] = new char[Math.max(buf.length << 1, newcount)]; System.arraycopy(buf, 0, newbuf, 0, count); buf = newbuf; } buf[count] = (char)c; count = newcount; } COM: <s> writes a character to the buffer </s>
funcom_train/5347157
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testIsCrawler() throws Exception { Properties props = new Properties(); props.put(HeaderNames.CRAWLER, "0.1"); HandshakeResponse hr = new HandshakeResponse(200, "OK", props); assertTrue("should be crawler", hr.isCrawler()); hr = new HandshakeResponse(200, "OK", new Properties()); assertFalse("should not be crawler", hr.isCrawler()); //props.put() //HandshakeResponse hr = HandshakeResponse.createCrawlerResponse(); } COM: <s> tests the method for determining whether or not a given handshake is </s>
funcom_train/23788913
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getBLZ() { lt.info("called method getBLZ().", this); cs.selectFID((byte)0x04,(byte)0x0C,cs.DF_BOERSE_AID); ResponseAPDU rsp = cs.readRecord((byte)0x01,(byte)0x19); // 0x19 = SFI von EF_BÖRSE return JSmexTools.BCDByteArrayToString(rsp.data(),1,5); } COM: <s> returns a formated string which contains the blz of the allocation account </s>
funcom_train/42850054
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void removeInstructionAt(Integer index) throws ProgramException { try { this.code.removeElementAt(index); } catch (ArrayIndexOutOfBoundsException e) { throw new ProgramException("Error while removing instruction at the index [" + index + "], the index is out of range, program length: " + this.code.size()); } } COM: <s> remove the instruction at the index specified </s>
funcom_train/50222649
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void process(Object o) { if (!animationVisible || o == null) { return; } if (o instanceof Collection) { list.setListData(((Collection) o).toArray()); } else { Object[] ldata = new Object[1]; ldata[0] = o; list.setListData(ldata); } } COM: <s> override this method in the subclass </s>
funcom_train/33598607
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Command getPlayAudio() { if (playAudio == null) {//GEN-END:|33-getter|0|33-preInit // write pre-init user code here playAudio = new Command("player", Command.ITEM, 0);//GEN-LINE:|33-getter|1|33-postInit // write post-init user code here }//GEN-BEGIN:|33-getter|2| return playAudio; } COM: <s> returns an initiliazed instance of play audio component </s>
funcom_train/28982859
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean isPresent(SpotLocation spotLocation){ int i = 0; boolean found = false; SpotLocation spotLocation_i = null; while ((i < coordinateSpots.size()) && !found ){ spotLocation_i = (SpotLocation) coordinateSpots.elementAt(i); found = spotLocation_i.equals(spotLocation); i++; } return found; } COM: <s> determine if the spots coordinate is present in the coordinate spots vector </s>
funcom_train/20627884
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private ArrayList saveSubsetConcepts(Subset item, Dag dag, boolean persistToDb) throws SQLException, DTSValidationException { ExpressionBuilder eb = new ExpressionBuilder(this.conn, this.subsetDAO); ArrayList results = eb.buildExpression(item, dag, persistToDb); return results; } COM: <s> computes the expression the stores the concepts of the subset tables </s>
funcom_train/21423320
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JMenuItem getClearDisconnectedMenuItem() { if (clearDisconnectedMenuItem == null) { clearDisconnectedMenuItem = new JMenuItem(); clearDisconnectedMenuItem.setText("Clear Disconnected"); clearDisconnectedMenuItem.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { clearDisconnected(); } }); } return clearDisconnectedMenuItem; } COM: <s> this method initializes clear disconnected menu item </s>
funcom_train/24586004
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public PGFSoundImpl (PGFDataResource resource) { this(resource.getResourceURL(), resource.getName(), resource.getDataType()); this.directories = (ArrayList<PGFResourceDirectory>)resource.getDirectories(); this.properties = (HashMap<String, String>)resource.getProperties(); } COM: <s> creates a single non complex sound from a given data resource </s>
funcom_train/32649136
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void createStyleThemeComboBox() { GridData gridData8 = new GridData(); gridData8.horizontalSpan = 2; styleThemeComboBox = new ThemeComboBox(optFamilyComposite, SWT.NONE); styleThemeComboBox.setEmbeddedInBindableGroup(false); styleThemeComboBox.setEnumClass("net.sf.tapestry_jsmenu.themegui.xmlbinding.FontStyle"); styleThemeComboBox.setLayoutData(gridData8); styleThemeComboBox.setBindingSubPath("fontStyle"); } COM: <s> this method initializes style theme combo box </s>
funcom_train/7633035
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean expectPassed() { for (int i = 0; i < TEST_NUM_EXPECTS; i++) { if (expects[i] == true) { return false; } } for (int i = 0; i < TEST_NUM_EXPECTS; i++) { if (eventsReceived[i] && notExpecting[i]) { return false; } } return true; } COM: <s> test to see if current expectations match recieved information </s>
funcom_train/33400799
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void openServerSocket() { Log.d(TAG, "Open server socket"); try { serverSocket = btAdapter.listenUsingRfcommWithServiceRecord( BeddernetInfo.SDP_RECORD_NAME, BeddernetInfo.BT_NETWORK_UUID); } catch (IOException e) { Log.e(TAG, "Could not open serverSocket: " + e.getMessage()); e.printStackTrace(); } } COM: <s> opens a bluetooth serversocket listening for incoming beddernet </s>
funcom_train/4377702
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getInt(String key) throws RJSONException { Object object = get(key); try { return object instanceof Number ? ((Number)object).intValue() : Integer.parseInt((String)object); } catch (Exception e) { throw new RJSONException("JSONObject[" + quote(key) + "] is not an int."); } } COM: <s> get the int value associated with a key </s>
funcom_train/27720213
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void reserveNick(String nick) throws NickAlreadyInUseException { // If the user tries to use a nick that's taken, tell 'em to naff off if (null != users.getUserByNick(nick)) { throw new NickAlreadyInUseException("Nick in use"); } users.createUser(nick, nick, "IRC", null); } COM: <s> this method allows the view to inform the controller of users that are </s>
funcom_train/12160783
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Button createButton(Composite parent, String text) { Button button = new Button(parent, SWT.PUSH); button.setText(text); button.setEnabled(false); GridData buttonGridData = new GridData(GridData.HORIZONTAL_ALIGN_FILL); button.setLayoutData(buttonGridData); return button; } COM: <s> creates and returns a button </s>
funcom_train/32831165
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetDifference_notEqualsRight0() { Difference result = reflectionComparator.getDifference(primitivesA, primitives0Value); Difference difference = getInnerDifference("intValue2", result); assertEquals(2, difference.getLeftValue()); assertEquals(0, difference.getRightValue()); } COM: <s> test for two primitives with right value 0 </s>
funcom_train/37089348
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public NBNode findNodeByIdOrName(String idOrName) { NBNode n = findNodeById(idOrName); if (n!=null) return n; n = findNodeByName(idOrName); if (n!=null) return n; // above fast searches are case sensitive return findNodeByIdOrNameCaseInsen(idOrName); } COM: <s> returns null if not found via id or name this is case sensitive </s>
funcom_train/20273032
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void visitGetElem(NodeTraversal t, Node n) { Node left = n.getFirstChild(); Node right = n.getLastChild(); validator.expectIndexMatch(t, n, getJSType(left), getJSType(right)); ensureTyped(t, n); } COM: <s> visits a getelem node </s>