__key__
stringlengths
16
21
__url__
stringclasses
1 value
txt
stringlengths
183
1.2k
funcom_train/24373578
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Connection getConnection() throws PatientCorrelationCacheException { try { Connection connection = new SQLConnectionWrapper().getConnection(SQLConnectionWrapper.adtJNDIResourceName); return connection; } catch (XdsInternalException ex) { logger.error("Could not open connection to support Patient Correlation", ex); throw new PatientCorrelationCacheException(ex.getMessage()); } } COM: <s> get adt for now jdbc connection instance from connection pool </s>
funcom_train/26485396
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String getDataType(Column schemaDataType) { if (SqlKitConsts.COL_DEFAULT_AUTOINCREMENT.equals(schemaDataType .getDefault()) && DarrtDbmsAutoincrementPositionType.DATATYPE_TYPE == dbms .getAutoincrementPosition().getType()) { return dbms.getAutoincrement().toString(); } return getDataType(schemaDataType.getColType()); } COM: <s> returns this rdbms implementation for the jdbc type </s>
funcom_train/29724652
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: static public String replace(String text, String toFind, String replaceBy) { int pos = text.indexOf(toFind); if (pos == -1) return text; StringBuffer result = new StringBuffer(text.length()); while (pos >= 0) { result.append(text.substring(0, pos)); result.append(replaceBy); text = text.substring(pos + toFind.length()); // arff pos = text.indexOf(toFind); } result.append(text); return(result.toString()); } COM: <s> replace a all aucurence of a string into an other </s>
funcom_train/28928813
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void reset() { // Remove items not in the original item set // int nStableItems = itemSet != null ? itemSet.size() : 0; // for (int i = units.size() - 1; i >= nStableItems; i--) // units.removeElementAt(i); // Reset act and phase for (Unit u : units) u.reset(); // Filter for (Filter f : filters) f.reset(); // Reset monitors for (LayerSignalEntry ent : layerSignals) ent.reset(); } COM: <s> reset the layer for a new trial </s>
funcom_train/32074848
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isEmpty() { if(surface.length() == 0) return true; // Belt-and-braces programming. This should also catch back-to-front // entities. This line should never return true but if the conditions // happened and weren't caught then major problems might happen later on. if(endOffset - startOffset < 1) return true; // OK return false; } COM: <s> is the named entity empty or back to front </s>
funcom_train/46154905
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void valueChanged(ListSelectionEvent e) { TrackSegment selectedSegment = (TrackSegment) segmentList.getSelectedValue(); logger.info("Selected Segment: " + selectedSegment); if (selectedSegment == null) { editButton.setEnabled(false); } else { editButton.setEnabled(true); } } COM: <s> handles when a selection has been made of the list of segments </s>
funcom_train/2808297
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public ModelReader getModelReader() { if (keepLocalReaders) { return this.modelReader; } else { try { return ModelReader.getModelReader(delegatorName); } catch (GenericEntityException e) { Debug.logError(e, "Error loading entity model", module); return null; } } } COM: <s> gets the instance of model reader that corresponds to this delegator </s>
funcom_train/44350607
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setVariable(String varName, double value) { if (functionBlocks.size() > 1) throw new RuntimeException("ERROR: No 'default' FunctionBlock. There are more than one FunctionBlocks, so you should set the variables by using FIS.setVariable(fbName, varName, value) method instead."); setVariable(null, varName, value); } COM: <s> set a variable from first available function block </s>
funcom_train/24645365
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String generateQuery(SQLQueryTypes type, SQLConditions cond) { switch (type) { case SELECT: return new SQLStatementSelect(TABLE_NAME).generateQuery(cond); case INSERT: return new SQLStatementInsert(TABLE_NAME).generateQuery(cond); case UPDATE: return new SQLStatementUpdate(TABLE_NAME).generateQuery(cond); case DELETE: return ""; } return ""; } COM: <s> generating query on standart templates </s>
funcom_train/38311504
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected JFrame findTopLevelContainer(Object obj) { JFrame result = null; if (obj == null || !(obj instanceof Component)) return null; Component comp = (Component)obj; while (comp.getParent() != null) comp = comp.getParent(); if (comp instanceof JFrame) return (JFrame)comp; return null; } COM: <s> finds the top level container subclasses of window that is a parent of </s>
funcom_train/16935032
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getType(String group, String key) { String value = ((RegistryGroup) m_groups.get(group)).getProperty(key); if (value == null) { return Registry.TYPE_NONE; } else { return markerToType(value.substring(0, 3)); } } COM: <s> get the type of the specified property </s>
funcom_train/22203361
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getIdFromLocator(Locator loc) { if (loc == null) { return null; } String adr = loc.getAddress(); if (adr == null) { return null; } int ix = adr.indexOf("#"); if ((ix == -1) || (ix >= (adr.length() - 1))) { return null; } return adr.substring(ix + 1); } COM: <s> returns the fragment identifier from the given locator </s>
funcom_train/16304982
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void draw(Point start, Point end) { Graphics2D g2 = image.createGraphics(); g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g2.setPaint(Color.BLACK); g2.setStroke(new BasicStroke(10, BasicStroke.CAP_ROUND, BasicStroke.JOIN_MITER)); g2.draw(new Line2D.Double(start, end)); g2.dispose(); repaint(); } COM: <s> this method is used to draw on the panel </s>
funcom_train/40424420
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetCommandOutput() { String output = CommandRunner.getCommandOutput(new File("."), new File( System.getProperty("java.home"), "bin/java").getAbsolutePath(), "-help"); assertNotNull(output); } COM: <s> test that java help runs successfully </s>
funcom_train/3481144
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setConnectionRetryCount(int connectionRetryCount) throws IllegalArgumentException { if (connectionRetryCount<=0) { throw new IllegalArgumentException(this.language.getText("LessThanZeroError", "ConnectionRetryCount", Integer.toString(connectionRetryCount))); } this.connectionRetryCount = connectionRetryCount; } COM: <s> set the number of times to attempt to establish a connection </s>
funcom_train/28751937
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setRoleid(Long newVal) { if ((newVal != null && this.roleid != null && (newVal.compareTo(this.roleid) == 0)) || (newVal == null && this.roleid == null && roleid_is_initialized)) { return; } this.roleid = newVal; roleid_is_modified = true; roleid_is_initialized = true; } COM: <s> setter method for roleid </s>
funcom_train/40627830
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testListen_ExtremeThreading() throws Exception { checkListen_ExtremeThreading(false); assertEquals(1500, getEventCount(TEST_DOMAIN)); assertEquals(1500, getEventCount(TEST_DOMAIN_2)); assertEquals(1500, getEventCount(TEST_DOMAIN_3)); } COM: <s> adding 4500 events with multithreading and a single listen at the end </s>
funcom_train/28752183
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setExtnid(Long newVal) { if ((newVal != null && this.extnid != null && (newVal.compareTo(this.extnid) == 0)) || (newVal == null && this.extnid == null && extnid_is_initialized)) { return; } this.extnid = newVal; extnid_is_modified = true; extnid_is_initialized = true; } COM: <s> setter method for extnid </s>
funcom_train/36995039
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getSize() { int size = 0; // iterate over TextRecords only for( int i = 1; i<records.size(); i += 2 ) { TextRecord tr = (TextRecord) records.elementAt(i); size += tr.getSize(); } if( lastRecord != null ) size += lastRecord.getSize(); return size; } COM: <s> return number of characters in this line </s>
funcom_train/20045038
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void _getViewData() { if (tEnv.getObjRelation("HasViewData") != null) { log.println("This Object has no View Data"); tRes.tested("getViewData()", true); return; } ViewData = oObj.getViewData(); tRes.tested( "getViewData()", ViewData != null ); } COM: <s> at first gotten object relation has view data is checked </s>
funcom_train/3033414
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean compareRecord(GdbiRecord rec2) throws GdbiIOException { options.progress.appendStatus("comparing: " + rec2); final GdbiXref xref1 = mapping.get(rec2.getXref()); assert (xref1 != null); final GdbiRecord rec1 = options.primary.getRecord(xref1); assert (rec1 != null); return compareRecursively(rec1, rec2); } COM: <s> compares the given record from the secondary to the primary </s>
funcom_train/25827981
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addListener(FileListener fileListener) { // Don't add if its already there for (WeakReference<FileListener> listener : this.listeners) { FileListener l = listener.get(); if (listener == l) return; } // Use WeakReference to avoid memory leak if this becomes the // sole reference to the object. this.listeners.add(new WeakReference<FileListener>(fileListener)); } COM: <s> add listener to this file monitor </s>
funcom_train/48406849
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addSubCategoryPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_Category_subCategory_feature"), getString("_UI_PropertyDescriptor_description", "_UI_Category_subCategory_feature", "_UI_Category_type"), SpemxtcompletePackage.eINSTANCE.getCategory_SubCategory(), true, false, true, null, null, null)); } COM: <s> this adds a property descriptor for the sub category feature </s>
funcom_train/39911032
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetClient() { System.out.println("getClient"); employee_client instance = new employee_client(); String expResult = ""; String result = instance.getClient(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } COM: <s> test of get client method of class buissness </s>
funcom_train/43902982
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean allSameOrder(String[] requestedNames, FeatureType ft) { if (requestedNames.length != ft.getAttributeCount()) return false; // incorrect # of attribute for (int t = 0; t < requestedNames.length; t++) { if (!(requestedNames[t].equals(ft.getAttributeType(t).getName()))) return false; // name doesnt match } return true; } COM: <s> returns true if the requested names list all the attributes in the </s>
funcom_train/19358515
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isRootClass(OWLClass cls) { for (OWLOntology ont : ontologies) { for (OWLAxiom ax : ont.getReferencingAxioms(cls)) { checker.setOWLClass(cls); ax.accept(checker); if (!checker.isRoot()) { return false; } } } return true; } COM: <s> determines if the specified class is a direct syntactic subclass of owl thing </s>
funcom_train/16994796
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getPathTranslated(NavigationRule mappedNav, String fromURL) throws NotMatchedException { URLRewriter rewriter = this.getURLRewriter(mappedNav); return rewriter.translate(mappedNav.getFromViewId().toString(), mappedNav.getFromViewId().getMappingTo(), fromURL); } COM: <s> translate incoming url of client to internal one </s>
funcom_train/50502234
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void resolve(String command) { if(command.equals("edit")) { if(source != null) { FormDialog dlog = new FormDialog(ch.orcasys.editor.EditorManager.getInstance().getEditor(source.getClass(), source), (JFrame) null, "Edit findings item"); dlog.setModal(true); dlog.setVisible(true); } } } COM: <s> this method is called with a supproted command id for starting execution </s>
funcom_train/14354896
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetApplication() { loginAsSysAdmin(); assertTrue(initSecurityServices()); assertEquals("none", checkGetApplication(testApplication1)); logout(); loginAsApplDev(); assertTrue(initSecurityServices()); assertEquals("none", checkGetApplication(testApplication1)); logout(); loginAsApplDev(); assertTrue(initSecurityServices()); assertEquals("SecurityException", checkGetApplication(testApplication2)); logout(); loginAsUser(); assertTrue(initSecurityServices()); assertEquals("SecurityException", checkGetApplication(testApplication2)); logout(); } COM: <s> method name test get application class name </s>
funcom_train/49608822
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Country getCountry(String username,EntityManager em,String code) throws Throwable { try { Country vo = JPAMethods.find(username, em, Country.class, code); if (vo==null) throw new Exception("No Country found having code: "+code); return vo; } catch (Throwable ex) { Logger.error(null, ex.getMessage(), ex); throw ex; } } COM: <s> retrieve a specific country </s>
funcom_train/25637726
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected Content getClassName(String classStr) { Content table = HtmlTree.TABLE(0, 3, 0, constantsTableSummary, getTableCaption(classStr)); table.addContent(getSummaryTableHeader(constantsTableHeader, "col")); return table; } COM: <s> get the class name in the table caption and the table header </s>
funcom_train/49952561
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Object deserialize(String fileName) { Object deserializedObject = null; try { ObjectInputStream in = new ObjectInputStream(new FileInputStream( fileName)); deserializedObject = in.readObject(); in.close(); System.out.println("Object : " + deserializedObject.getClass() + " de-serialized successfully"); } catch (Exception ex) { System.out.println("Error Reading Object to File :" + ex.getMessage()); ex.printStackTrace(); } return deserializedObject; } COM: <s> de serialize the object from the file </s>
funcom_train/10620407
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean checkWindow(Window wnd) { if (wnd == null) { return false; } if (wnd instanceof EmbeddedWindow) { // TODO: query state of EmbeddedWindow's owner return true; } // FIXME: explicitly deny focus requests for components // inside iconified/shaded windows: if ((getOwningFrame(wnd).getExtendedState() & Frame.ICONIFIED) != 0) { return false; } return true; } COM: <s> perform additional checks to determine if a window can </s>
funcom_train/31690645
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Date getDate(DateRange range, String sDate) throws ParseException { Date date = null; SimpleDateFormat format = null; if(range.includeTime() == true) { format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss G"); } else { format = new SimpleDateFormat("yyyy-MM-dd G"); } date = format.parse(sDate); return date; } COM: <s> returns a date object given a string representation </s>
funcom_train/20045850
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void requiredMethod(String method) { log.println("starting required method: " + method); executeMethod( method ); Status mtStatus = tRes.getStatusFor( method ); if ( mtStatus != null && (!mtStatus.isPassed() || mtStatus.isFailed()) ) { log.println( "! Required method " + method + " failed" ); throw new StatusException( mtStatus ); } } COM: <s> calling of the method indicates that the code method code test should </s>
funcom_train/41163570
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void save(CoParagraphCheckList3 entity) { EntityManagerHelper.log("saving CoParagraphCheckList3 instance", Level.INFO, null); try { getEntityManager().persist(entity); EntityManagerHelper.log("save successful", Level.INFO, null); } catch (RuntimeException re) { EntityManagerHelper.log("save failed", Level.SEVERE, re); throw re; } } COM: <s> perform an initial save of a previously unsaved co paragraph check list3 </s>
funcom_train/9205221
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean contains(Body body, Vector2 point) { Transform transform = body.getTransform(); int fSize = body.getFixtureCount(); // loop over the body fixtures for (int j = fSize - 1; j >= 0; j--) { BodyFixture bodyFixture = body.getFixture(j); Convex convex = bodyFixture.getShape(); if (convex.contains(point, transform)) { // return the first body who contains a fixture // that contains the given point return true; } } return false; } COM: <s> returns true if the given body contains the given point </s>
funcom_train/328737
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void parseAndSetSpList(String spListSingleString) { String tempSpecies = spListSingleString.trim(); String tempSpeciesSub = tempSpecies.substring(1,tempSpecies.length()-2); String[] speciesArray = tempSpeciesSub.split("[-]"); this.setSpecies(speciesArray); } COM: <s> reads the species from the passed string and sets the species list </s>
funcom_train/14433347
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void updateGraphics() { // Draw Graphics of each Drawing Layer to the BufferedImage which serves as the // off-screen buffer. for(DrawingLayer drawingLayer : this.drawingLayers) { if(drawingLayer.isVisible()) { drawingLayer.getDrawing().drawGraphics(this.bufferedImageGraphics); } } } COM: <s> p draw graphics of each drawing layer </s>
funcom_train/2883573
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void run() { if (SFSystem.sfLog().isDebugEnabled()) SFSystem.sfLog().debug(Thread.currentThread().getStackTrace()[1]); try { eclipse.rpc("sfsolve"); } catch (Exception e) { generalError = e; yieldLockFromECRThread(); } } COM: <s> eclipse main goal to run in secondary thread </s>
funcom_train/1233680
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void reloadResourceBundle(Locale locale) { if(locale == null) { //Get resource bundle for the text elements in the application. ["text"] text = ResourceBundle.getBundle("text"); //Read out global application name out of resource bundle "text" appname = text.getString("APP_NAME"); } else { Locale.setDefault(locale); //Get resource bundle for the text elements in the application. ["text"] text = ResourceBundle.getBundle("text"); //Read out global application name out of resource bundle "text" appname = text.getString("APP_NAME"); } } COM: <s> reloads the localized text for this application </s>
funcom_train/12179731
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testDetectStartEndMismatch() { BaseURLTracker tracker = new BaseURLTracker(null); tracker.startElement("file:/a/b.xml"); try { tracker.endElement("file:/q/r/s.xml"); fail("Did not detect mismatch between start and end system ids"); } catch (IllegalStateException expected) { } } COM: <s> ensure that the tracker detects a mismatch between the system ids </s>
funcom_train/39186256
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void adjustParameters(ImagePlus imp) { if(zscale < 0.0) zscale = 1.0; // Maximum reasonable width is equal to diagonal dimension of // image. int w = imp.getWidth(), h = imp.getHeight(); int maxwidth = (int)Math.sqrt(w*w + h*h); if(swidth < 1 || swidth > maxwidth) swidth = 1; } COM: <s> adjust z spacing and slice width to ensure they have </s>
funcom_train/4628769
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void setBackgroundColor() { ISourceViewer sourceViewer = getSourceViewer(); if(sourceViewer == null || sourceViewer.getTextWidget() == null) return; Control widget = sourceViewer.getTextWidget(); IPreferenceStore store = TUnitPlugin.getDefault().getPreferenceStore(); Color background = new Color(Display.getCurrent(), PreferenceConverter.getColor(store, TclPreferencesConstants.P_BACKGROUNDCOLOR)); widget.setBackground(background); sourceViewer.invalidateTextPresentation(); widget.redraw(); } COM: <s> change background color of the editor </s>
funcom_train/25738675
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String toString() { StringBuffer buffer = new StringBuffer(); buffer.append("Theo MS" + msLevel); buffer.append("-Peak m["); buffer.append(massType); buffer.append("] = "); buffer.append(mass); buffer.append(" Da"); buffer.append(", z = "); if (getChargeState() != 0) { buffer.append(getChargeState()); } else { buffer.append("NA"); } buffer.append(", mz = "); buffer.append(mz); return buffer.toString(); } COM: <s> string representation of theoretical ms peak </s>
funcom_train/323407
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean prepareUpdateStatement(Connection connection) { if (preparedUpdateStatement != null && connection == currentConnection) { return true; } if (preparedUpdateStatement != null) { try { preparedUpdateStatement.close(); } catch (SQLException e) { } } String updateString = getUpdateString(); try { preparedUpdateStatement = connection.prepareStatement(updateString); } catch (SQLException e) { System.out.println("Unable to prepare update statement " + updateString); e.printStackTrace(); return false; } return true; } COM: <s> prepare a prepared update statement for the cursor which can </s>
funcom_train/3470602
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void registerChild(JacaretoClassLoader child) { String identifier = child.getIdentifier(); if (StringToolkit.isDefined(identifier)) { Vector<JacaretoClassLoader> childVector = null; if (childVectors.containsKey(identifier)) { childVector = childVectors.get(identifier); } else { childVector = new Vector<JacaretoClassLoader>(); childVectors.put(identifier, childVector); } childVector.add(child); } } COM: <s> registers a child class loader </s>
funcom_train/31118708
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean addChildOf(Object o, Object n) { if (root.equals(o)) { addChild(n); return true; } else { for (int a = 0; a < children.size(); a++) { Tree t = (Tree) children.elementAt(a); if (t.addChildOf(o, n)) { return true; } } return false; } } COM: <s> adds a feature to the child of attribute of the tree object </s>
funcom_train/24942219
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getNumberOfCycles() { final int streamLength = getStreamFormat().length; final int fifoWidth = getBlockDescriptor().getByteWidth(); // Simple sanity check. assert ((streamLength % fifoWidth) == 0) : "Illegal block element format. Number of bytes is not integral multiple of fifo width. Bytes: " + streamLength + " fifo width " + fifoWidth; return streamLength / fifoWidth; } COM: <s> returns the number of cycles necessary to transfer this element over the </s>
funcom_train/10182753
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void shutDown() { collector.removePool(this); factory.poolClosing(this); // close all objects synchronized (objects) { for (Iterator it = objects.values().iterator(); it.hasNext();) { ObjectRecord rec = (ObjectRecord) it.next(); if (null != rec) { if (rec.isInUse()) factory.returnObject(rec.getClientObject()); factory.deleteObject(rec.getObject()); rec.close(); } } objects.clear(); deadObjects.clear(); }// end of synch factory = null; poolName = null; initialized = false; } COM: <s> shuts down the pool </s>
funcom_train/6279894
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addContact(Contact contact) { if (getIndexContact(contact.getAddress()) != -1) { int retval = JOptionPane.showConfirmDialog( null, "This email address already exists in your address book.\n Do you want to add it once again ?\n\n", "Add again ?", JOptionPane.YES_NO_OPTION); if (retval == JOptionPane.NO_OPTION) { return; } } contacts.add(contact); } COM: <s> method add contact </s>
funcom_train/49822143
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public SolveInfo solve(Term query) { try { query.resolveTerm(); libraryManager.onSolveBegin(query); primitiveManager.identifyPredicate(query); // theoryManager.transBegin(); freeze(); if (env != null) env.cleanup(); env = new Engine(this, query); StateEnd result = env.run(false); defreeze(); sinfo = new SolveInfo( env.query, result.getResultGoal(), result.getResultDemo(), result.getResultVars() ); if (!sinfo.hasOpenAlternatives()) solveEnd(); return sinfo; } catch (Exception ex) { ex.printStackTrace(); return new SolveInfo(query); } } COM: <s> solves a query </s>
funcom_train/4923319
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testImediatelyFailInvalidate() throws Throwable { final Exception failure = new Exception("Failed to invalidate"); // Record this.record_instantiate(); this.record_invalidate_failedToInvalidateSession(failure); // Invalidate this.replayMockObjects(); HttpSessionAdministration admin = this .createHttpSessionAdministration(); try { admin.invalidate(true); } catch (Exception ex) { assertSame("Incorrect cause of failure", failure, ex); } this.verifyFailure(admin, failure); } COM: <s> ensure can handle immediately failing to invalidate </s>
funcom_train/45933380
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String process(String formattedString) { if (formattedString != null && formattedString.length() > 2) { Pattern pattern = Pattern.compile("<.[^>]*>"); Matcher matcher = pattern.matcher(formattedString); return matcher.replaceAll(""); } else { return formattedString; } } COM: <s> this should no longer be used </s>
funcom_train/24067536
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public MimeMessage getMimeMessage(final Session session) throws MessagingException { // Define message final MimeMessage message = new MimeMessage(session); message.setFrom(new InternetAddress(SYSTEM_EMAIL)); message.addHeader(CHARSET, UTF8); // set Header message.addHeader(XPRIO, PRIORITY); message.setSentDate(new Date()); // set date return message; } COM: <s> gets the mime message </s>
funcom_train/48630791
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetLongueurTotale() { System.out.println("getLongueurTotale"); Itineraire instance = new Itineraire(); int expResult = 0; int result = instance.getLongueurTotale(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } COM: <s> test of get longueur totale method of class itineraire </s>
funcom_train/31820330
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void refreshVisuals(){ BacklogFigure figure = (BacklogFigure)getFigure(); figure.setNameText(getCastedModel().getName()); Rectangle bounds = new Rectangle (getCastedModel().getLocation(),getCastedModel().getSize()); ((GraphicalEditPart)getParent()).setLayoutConstraint(this,getFigure(),bounds); figure.repaint(); } COM: <s> required method to refresh the figure when changes to the model occure </s>
funcom_train/42403954
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected NewConcreteType subClassLoggingFactory(final String newTypeName) { final GeneratorContext context = this.getGeneratorContext(); context.branch(); context.info("Creating type that sub classes LoggingFactoryImpl"); final NewConcreteType newType = context.newConcreteType(newTypeName); newType.setAbstract(false); newType.setFinal(true); newType.setSuperType(this.getLoggerFactoryImpl()); newType.setVisibility(Visibility.PUBLIC); context.unbranch(); return newType; } COM: <s> creates a new type that will form the basis of the implemented </s>
funcom_train/22093873
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public HttpHeader getHeader(String name) { for (int i=0; i<httpHeader.size(); i++) { HttpHeader h = (HttpHeader)httpHeader.elementAt(i); if (name.equalsIgnoreCase(h.getName())) { return h; } } return null; } COM: <s> the the content of an http header line </s>
funcom_train/8528481
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Document readXML(File file) throws TTSBuilderException { Document doc = null; try { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); DocumentBuilder db = dbf.newDocumentBuilder(); doc = db.parse(file); } catch (Exception e) { System.err.println(e.getMessage()); e.printStackTrace(); throw new TTSBuilderException(e.getMessage(), e); } return doc; } COM: <s> reads the configuration file into a dom object </s>
funcom_train/19672021
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getJContentPane() { if (jContentPane == null) { jContentPane = new JPanel(); jContentPane.setLayout(null); jContentPane.add(getStartgameButton(), null); jContentPane.add(getAboutButton(), null); jContentPane.add(getPatchboardTextPane(), null); jContentPane.add(getPatchcheckProgressBar(), null); } return jContentPane; } COM: <s> this method initializes j content pane </s>
funcom_train/44018146
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void ConfigureSelectedSource() { // Get selected source final String selection = (String) EnabledSourcesList.getSelectedValue(); if (selection == null) return; final SourcePlugin src = PluginSources.findType(selection); if (src == null) return; final JDialog frame = src.getOptionsDialog(); if (frame == null) return; frame.setLocationRelativeTo(this); frame.setVisible(true); } COM: <s> configure the currently selected source plugin by simply calling the </s>
funcom_train/20079513
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void forwardToChild(AppEvent event) { if (children != null) { for (int i = 0; i < children.size(); i++) { Controller c = (Controller) children.get(i); if (!c.initialized) { c.initialize(); c.initialized = true; } if (c.canHandle(event)) { c.handleEvent(event); } } } } COM: <s> forwards an event to any child controllers who can handle the event </s>
funcom_train/48206619
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void unregisterForm(IGameFormObject form){ CollisionGameState collisionState = (CollisionGameState)form.getState( CollisionGameState.class.getCanonicalName() ); if(collisionState != null){ List<IGameFormObject> formTypeList = forms.get(collisionState.getColliderType()); if(formTypeList != null){ formTypeList.remove(form); } } } COM: <s> removes a form from collision checking </s>
funcom_train/18788330
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void saveAll() throws IOException { IsModifiedFlagFunctor functor = new IsModifiedFlagFunctor(); VisitorFunctor visitor = new VisitorFunctor(functor); for (MetaClass clazz : types.keySet()) { functor.reset(); CodeType type = types.get(clazz); type.accept(visitor); if (functor.isModified()) { save(clazz); } } } COM: <s> saves all modified code types and thier code values </s>
funcom_train/29710330
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public final void createPartControl(Composite parent) { this._sashForm = createContainer(parent); try { createPages(); } catch (PartInitException ex) { ex.printStackTrace(); } // set the active page (page 0 by default), unless it has already been // done if (getActiveEditor() == null) { if (!_nestedEditors.isEmpty()) { setActiveEditor((IEditorPart) _nestedEditors.get(0)); } } } COM: <s> the code multi page editor code implementation of this </s>
funcom_train/44852695
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void storeMissingResources(ArrayList resourcez) { try { baseRdfRepository.startTransaction(); URI resType = new URIImpl(RDF_TYPE); URI resResource = new URIImpl(RESOURCE); for (int i = 0; i < resourcez.size(); i++) { Resource res = (Resource) resourcez.get(i); if (idByRes.get(res) == null) { baseRdfRepository.addStatement(res, resType, resResource); } } baseRdfRepository.commitTransaction(); } catch (SailUpdateException e) { throw new SailInternalException(e); } } COM: <s> stores the missing resources from the security setup </s>
funcom_train/29023494
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addImageAsFrame(BufferedImage image, int sleepCount) throws IOException { Buffer b = ImageToBuffer.createBuffer(image, frameRate); if (!init) { boolean result = init((RGBFormat) b.getFormat()); if (!result) { System.err.println("Failed to setup movie capture"); } init = true; } source.addBuffer(b); try { Thread.sleep(sleepCount); } catch (InterruptedException ex) { } System.gc(); } COM: <s> adds an image to a movie as a frame </s>
funcom_train/10670972
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Result testGetBeanDescriptor() { try { if (!beanInfo.getBeanDescriptor().getBeanClass() .equals(Bean3.class)) { throw new LocationException("mistake BeanDescriptor"); } Bean1BeanInfo.verifyException(); return passed(); } catch (Exception e) { e.printStackTrace(); return failed(e.getMessage()); } } COM: <s> verify that get bean descriptor method returns bean class </s>
funcom_train/21508429
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public GameEventListener addListener(String eventQueue, int maxSize) { // TODO: Add the option for listeners of unlimited size. Probably by supplying zero or negative size. GameEventListener listener = null; if(!eventListeners.containsKey(eventQueue)) { listener = new GameEventListener(maxSize); eventListeners.put(eventQueue, listener); } return listener; } COM: <s> adds a new listener which will receive events of type event type </s>
funcom_train/1959172
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String matchChain(String interf, String direction){ // go through each IfMap and if one correpsonds to the given interf // and direction return the chain reference Iterator iter = this.getMappings().iterator(); String chain=null; while (iter.hasNext()){ IfMap temp = (IfMap) iter.next(); if ((temp.getDirection().equalsIgnoreCase(direction)) && temp.getInterf().equalsIgnoreCase(interf)){ chain = temp.getChain(); } } return chain; } COM: <s> matches interface and direction to the corresponding chain </s>
funcom_train/28316805
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public SourceJson getFiles(String node) throws Exception { if (node != null && node.length() > 0) { rootFile = node; } SourceJson sourcesJson = new SourceJson(); try { // file the fold/files now File aStartingDir = new File(rootFile); getFileListing(aStartingDir); sourcesJson.setFileNames(dirFiles); sourcesJson.setFoldNames(folds); aStartingDir = null; } catch (Exception e) { e.printStackTrace(); log.error(e.getMessage()); } return sourcesJson; } COM: <s> get a list of files now </s>
funcom_train/26137633
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void hideProgress() { runOnUiThread(new Runnable() { public void run() { // All activities defined these standard components findViewById(R.id.Content).setVisibility(View.VISIBLE); findViewById(R.id.ProgressIndicatorContainer).setVisibility(View.GONE); } }); } COM: <s> remove the progress indicator </s>
funcom_train/19536428
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setShowInit(boolean aShowInit) { if (showInit == aShowInit) return; boolean old = showInit; showInit = aShowInit; pcs.firePropertyChange(SHOW_INIT_PROP_NAME, old, showInit); ps.getPreferences().putBoolean(SHOW_INIT_PROP_NAME, showInit); } COM: <s> set the value of show init for this init tool preferences </s>
funcom_train/28660891
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void createCStandard() { GridData gridData9 = new GridData(); gridData9.horizontalAlignment = org.eclipse.swt.layout.GridData.FILL; gridData9.grabExcessHorizontalSpace = true; cStandard = new Combo(groupSelectAttributes, SWT.NONE); cStandard.setLayoutData(gridData9); cStandard.addSelectionListener(new SelectionListener() { public void widgetDefaultSelected(SelectionEvent e) { } public void widgetSelected(SelectionEvent e) { fillCCurve(); } }); } COM: <s> this method initializes c standard </s>
funcom_train/46261318
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void echo() { String input; try { while ((input = socketReader.readLine()) != null) { System.out.println(" Client Says : " + input); socketWriter.println(input); socketWriter.flush(); } } catch (SocketException ex) { System.out.println("Client exited...waiting for new connection"); } catch (IOException ex) { System.out.println("IO Error..."); ex.printStackTrace(); } } COM: <s> temp method to try echo server </s>
funcom_train/18524787
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void compRBtn_ItemStateChanged(ItemEvent itemEvent) { if (getcompRBtn().isSelected()) { getthreadOneComboBox().setEnabled(true); getthreadTwoComboBox().setEnabled(true); } else { getthreadOneComboBox().setEnabled(false); getthreadTwoComboBox().setEnabled(false); } return; } COM: <s> comp rbtn item state changed event </s>
funcom_train/51792403
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setItem(int elementNum, String stringPart, Image imagePart) { if((elementNum >= 0) && (elementNum < items.size())) { if(stringPart != null) { MenuItem item = (MenuItem)items.elementAt(elementNum); setText(stringPart, item); onResize(); } } } COM: <s> sets the element referenced by element num to the specified element </s>
funcom_train/34534920
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Node locateNode(String stateName) { Node result=null; for (Iterator i=m_diagram.getNode().iterator(); result==null && i.hasNext(); ) { Node node=(Node)i.next(); if (node.getName().equals(stateName)) result=node; } return result; } COM: <s> locate the existing node state name </s>
funcom_train/4425160
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void configureActionOutputs(FormattingConfig c) { AstActionElements access = f.getAstActionAccess(); c.setNoSpace().before(access.getCommaKeyword_5_1_0()); c.setNoSpace().before(f.getOutputPatternAccess().getColonKeyword_1()); c.setNoSpace().before(f.getOutputPatternAccess().getCommaKeyword_4_0()); c.setNoSpace().before( f.getOutputPatternAccess().getLeftSquareBracketKeyword_2()); } COM: <s> configure action output pattern </s>
funcom_train/31156106
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void Deallocate() { try { //http://pixel.recoil.org/java/jspeechlib/ResourceManagement.html // Wait till speaking is done speechSynthesizer.waitEngineState(Synthesizer.QUEUE_EMPTY); speechSynthesizer.deallocate(); } catch (Exception e) { e.printStackTrace(); } } COM: <s> deallocates speech synthesizer object </s>
funcom_train/37764776
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void changeDone(String path, Object source, Object target, UOW uow) throws ApplicationExceptions, FrameworkException { if (log.isDebugEnabled()) log.debug("Handle Event : changeDone for " + path + " (Target=" + shortClassName(target) + ")"); } COM: <s> called after all processing has been completed on the root graph </s>
funcom_train/7687082
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void onQueryComplete(int token, Object cookie, CallerInfo ci){ if (DBG) log("callerinfo query complete, updating ui."); ((RemoteViews) cookie).setTextViewText(R.id.text2, PhoneUtils.getCompactNameFromCallerInfo(ci, mContext)); } COM: <s> implemented for caller info async query </s>
funcom_train/40853622
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Command getItemInfo() { if (itemInfo == null) {//GEN-END:|58-getter|0|58-preInit // write pre-init user code here itemInfo = new Command("Datos de Usuario", Command.ITEM, 0);//GEN-LINE:|58-getter|1|58-postInit // write post-init user code here }//GEN-BEGIN:|58-getter|2| return itemInfo; } COM: <s> returns an initiliazed instance of item info component </s>
funcom_train/44702160
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void drawTitle(Graphics2D graphics, Font fontTitle, String title) { int beginY; int beginX; graphics.setColor(titleColor); graphics.setFont(fontTitle); beginX = Math.abs(WIDTH - graphics.getFontMetrics().stringWidth(title)) / 2; beginY = MARGIN + FONT_SIZE_TITLE; graphics.drawString(title, beginX, beginY); } //drawTitle() COM: <s> draws graphic title </s>
funcom_train/46937554
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getJPanelWindow() { if (jPanelWindow == null) { BorderLayout borderLayout = new BorderLayout(); borderLayout.setVgap(7); borderLayout.setHgap(0); jPanelWindow = new JPanel(); jPanelWindow.setLayout(borderLayout); jPanelWindow.add(getJPanelButtons(), BorderLayout.SOUTH); jPanelWindow.add(getJPanelMain(), BorderLayout.CENTER); jPanelWindow.add(getJPanelTitle(), BorderLayout.NORTH); } return jPanelWindow; } COM: <s> this method initializes j panel window </s>
funcom_train/43410463
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void deleteEntidade(int entidadeID) { try { Statement stmt = (Statement) con.createStatement(); String query = "delete from entidades where id=" + entidadeID; stmt.executeUpdate(query); stmt.close(); } catch (Exception e) { logger.log(Level.SEVERE, e.getStackTrace()[0].getMethodName() + "**" + lg + "** ", e); } } COM: <s> removes an entity in db </s>
funcom_train/11728567
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetAttributeNames() { String names[] = session.getAttributeNames(); for (int i = 0; i < names.length; i++) { assertNotNull("An attribute name returned by getAttributeNames() " + "does not exist.", session.getAttribute(names[i])); } } COM: <s> tests if attribute names returned by get attribute names do not return </s>
funcom_train/1242069
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String getLayerName(FeatureCollection coll) { String name = getCachedName(coll.hashCode() + ""); if (name == null) { name = layerNames[layerCounter]; if (name.equals("")) name = "LAYER" + layerCounter; layerCounter++; storeCachedName(coll.hashCode() + "", name); } return name; } COM: <s> gets a name for the layer represented by the given collection </s>
funcom_train/11688690
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public E poll() { final ReentrantLock lock = this.lock; lock.lock(); try { InternalQueue<E> internalQueue = nextQueueAlgorithm.getNextQueue(); if (internalQueue != null) { count--; E e = internalQueue.poll(); internalQueue.getNotFullCond().signal(); return e; } else { return null; } } finally { lock.unlock(); } } COM: <s> block indefinitely until a object is available for retrieval </s>
funcom_train/7242995
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Properties getConfiguration(String configFileName) throws IOException { log.info("Using configuration file: " + configFileName); localPropertyFile = new File(configFileName); Properties properties = new Properties(); if (localPropertyFile.exists()) { properties.load(new FileInputStream(configFileName)); } else { // properties = ReqtrackConfiguration.configureFromScratch(); } return properties; } COM: <s> retrieves the configuration properties no matter whether the given </s>
funcom_train/4984617
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setStyleClass(String styleClass) { this.styleClass = styleClass; if (styleClass != null && styleClass.trim().length() > 0) { this.openingTag = "<span class=\"" + styleClass + "\">"; this.closingTag = "</span>"; } else { this.openingTag = ""; this.closingTag = ""; } } COM: <s> sets a style class </s>
funcom_train/41593278
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addNullFlavorPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_POCDMT000040Custodian_nullFlavor_feature"), getString("_UI_PropertyDescriptor_description", "_UI_POCDMT000040Custodian_nullFlavor_feature", "_UI_POCDMT000040Custodian_type"), V3Package.eINSTANCE.getPOCDMT000040Custodian_NullFlavor(), true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the null flavor feature </s>
funcom_train/2414722
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testBuildMazeFromData() { Maze builtMaze = ParseMazeData.buildMazeFromData(FILE1); assertEquals(CellType.START, builtMaze.getCellAt(1, 2).getType()); assertEquals(CellType.END, builtMaze.getCellAt(5, 2).getType()); assertEquals(CellType.WALL, builtMaze.getCellAt(0, 0).getType()); } COM: <s> test built maze from data functionality </s>
funcom_train/1602419
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setScroll(MouseWheelEvent e){ int notches = e.getWheelRotation(); if (notches < 0) { if (scrollValue > scrollbar.getMinimum()){ setScrollValue(getScrollValue() - e.getScrollAmount()-20); } else { setScrollValue(scrollbar.getMinimum()); } } else { if (scrollValue < scrollbar.getMaximum()){ setScrollValue(getScrollValue() + e.getScrollAmount()+20); } else { setScrollValue(scrollbar.getMaximum()); } } getScrollbar().setValue(scrollValue); } COM: <s> the scrollbar is usable with the mousewheel with this method </s>
funcom_train/39314842
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: /** public void testCustomActionPerformed() { System.out.println("testCustomActionPerformed"); f.CustomActionPerformed(actionEvent); t.CustomActionPerformed(actionEvent); System.out.println("empty code"); System.out.println("done testCustomActionPerformed"); //needs work } COM: <s> public void test slide show action performed </s>
funcom_train/7751353
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getJPanel4() { if (jPanel4 == null) { jPanel4 = new JPanel(); jPanel4.setLayout(new GridBagLayout()); jPanel4.add(getJButton4(), new GridBagConstraints()); jPanel4.add(getJButton1(), new GridBagConstraints()); jPanel4.add(getJButton2(), new GridBagConstraints()); jPanel4.add(getJButton3(), new GridBagConstraints()); } return jPanel4; } COM: <s> this method initializes j panel4 </s>
funcom_train/34427988
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void setDefaultApp(Element e) throws InvalidXMLElementException, WebConfigException { String appName = this.getAttribute(e, ATT_DEFAULT_APP, true); if (this.applications.containsKey(appName)) { this.defaultApp = this.applications.get(appName); } else { throw new WebConfigException("Default application " + appName + " cannot be found", null); } } COM: <s> set the default application </s>
funcom_train/26492279
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void updateConversions(Node site, int sid) { System.out.println("Updating conversions"); NodeList nlist = ((Element)site).getElementsByTagName("conversion"); for (int i = 0; i < nlist.getLength(); i++) { updateThisConversion(nlist.item(i), sid); } } COM: <s> update conversions in the db </s>
funcom_train/2505064
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void removeEdge(String from, String to) { synchronized (lock) { Node actual = (Node) nodeMap.get(from); if (actual != null) for (int i = actual.neighbours.size() - 1; i >= 0; i--) { if (((Node) actual.neighbours.get(i)).name.equals(to)) { actual.neighbours.remove(i); actual.edges.remove(i); } } } } COM: <s> removes a edge from a node </s>