__key__
stringlengths
16
21
__url__
stringclasses
1 value
txt
stringlengths
183
1.2k
funcom_train/3294984
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String calculateFormName(Node preHtmlFormField) { try { String fid = Utils.getAttribute(preHtmlFormField, "fid"); String did = Utils.getAttribute(preHtmlFormField, "did"); return "field/"+fid+"/"+did; } catch (RuntimeException e) { return "field/fid_or_did_missed_a_tag"; } } COM: <s> returns the proper form name for input name xx </s>
funcom_train/2557628
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean number() { int mark = off; int size = 0; while(mark < count) { char ch = text[mark]; if(isDigit(ch)) { size++; } else { break; } mark++; } if(size > 0) { commit(text, off, mark - off); } off = mark; return size > 0; } COM: <s> this is used to extract a number from the source string </s>
funcom_train/36190377
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void updateFaultReComposeCount(SessionID sessId) { Dbc.require(null != sessId && sessId.getId() > 0); SessionStore store = SessionStore.getInstance(); SessionPlan plan = getSessionPlan(sessId); plan.incrementReComposedFault(); store.addPlan(plan); } COM: <s> update the session plan recomposed due to a fault counter </s>
funcom_train/45330149
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void selectFilter (String sDescription) { javax.swing.filechooser.FileFilter [] filters = this.getChoosableFileFilters(); for (int i=0; i < filters.length; i++ ) { if( filters[i].getDescription().equals(sDescription) ) { this.setFileFilter(filters[i]); return; } } } COM: <s> tries to select a file filter based on the description </s>
funcom_train/20978876
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Dimension getArrowPreferredSize(int direction) { Dimension dimension = null; if (skina.getScrollbar() != null) { dimension = skina.getScrollbar().getArrowPreferredSize(direction); } if ((dimension == null) && (skinb.getScrollbar() != null)) { dimension = skinb.getScrollbar().getArrowPreferredSize(direction); } return dimension; } COM: <s> gets the arrow preferred size attribute of the compound scrollbar object </s>
funcom_train/46188095
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public StaticPage loadStaticPage(Blog blog, String pageId) throws PersistenceException { File path = new File(getPath(blog, pageId)); File file = new File(path, pageId + STATIC_PAGE_FILE_EXTENSION); return loadStaticPage(blog, file); } COM: <s> loads a specific static page </s>
funcom_train/32947585
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public IIndividualSet createIndividualSet() { try { ObjIn xmlInput = new ObjIn( new FileReader( file ) ); IIndividualSet set = (IIndividualSet) xmlInput.readObject(); return set; } catch ( Exception ex ) { EVLog.error( "initialization from file failed : file " + file + " did not contain an individual collection", ex ); return null; } } COM: <s> reads the individual set from the given file </s>
funcom_train/25121113
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public DoubleMatrix x(){ CohoDouble[][] x = new CohoDouble[nrows()][ncols()]; for(int i=0;i<nrows();i++){ for(int j=0;j<ncols();j++){ x[i][j]=V(i,j).x(); } } return DoubleMatrix.create(x); } COM: <s> get the middle value x of all elements of this matrix </s>
funcom_train/23216884
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addContractTemplateReferencePropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_ContractTemplate_contractTemplateReference_feature"), getString("_UI_PropertyDescriptor_description", "_UI_ContractTemplate_contractTemplateReference_feature", "_UI_ContractTemplate_type"), ContractPackage.Literals.CONTRACT_TEMPLATE__CONTRACT_TEMPLATE_REFERENCE, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the contract template reference feature </s>
funcom_train/45896603
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void die() { // remove equipment of the owner Iterator<InventoryItem> pit = inventory.iterator(); while (pit.hasNext()) { InventoryItem pii = pit.next(); if (pii.owner == owner) { pit.remove(); } } if (owner != null) { owner.planets.put(this, PlanetKnowledge.NAME); } owner = null; race = null; quarantine = false; allocation = ResourceAllocationStrategy.DEFAULT; tax = TaxLevel.MODERATE; morale = 50; lastMorale = 50; population = 0; lastPopulation = 0; autoBuild = AutoBuild.OFF; taxIncome = 0; tradeIncome = 0; surface.buildings.clear(); surface.buildingmap.clear(); } COM: <s> remove everything from the planet and reset to its default stance </s>
funcom_train/22093729
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected FormHandler getFormHandler(String url) { if (url == null) { return null; } if (formHandlers == null) { return null; } for (int i=0; i<formHandlers.size(); i++) { FormHandler fh = (FormHandler)formHandlers.elementAt(i); if (fh.getUrl().toString().equals(url)) { return fh; } } return null; } COM: <s> gets a form handler for a given url </s>
funcom_train/31303732
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void print( boolean immediately ) { setBusy(); try { print( immediately, rpo ); setReady(); } catch (Throwable t) { setReady(); showExceptionDialog(getDesc("error"),getDesc("order_access_error"), t, false); } } COM: <s> print order or offer </s>
funcom_train/45623438
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addFixedNamesPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_AspNetCompilerType_fixedNames_feature"), getString("_UI_PropertyDescriptor_description", "_UI_AspNetCompilerType_fixedNames_feature", "_UI_AspNetCompilerType_type"), MSBPackage.eINSTANCE.getAspNetCompilerType_FixedNames(), true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the fixed names feature </s>
funcom_train/8392715
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private int parseClassNum(String line) { int num = -1; String token; if ( !(line.startsWith("<classNumber>")) ) { num = -1; } else { StringTokenizer st = new StringTokenizer(line,"#"); st.nextToken(); token = st.nextToken(); token = token.trim(); num = Integer.parseInt(token); } return num; } COM: <s> example of a string that this method parses </s>
funcom_train/31079711
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getMethodName() { if (_index == 0) return null; ComplexEntry entry = (ComplexEntry) getPool().getEntry(_index); String name = entry.getNameAndTypeEntry().getNameEntry().getValue(); if (name.length() == 0) return null; return name; } COM: <s> return the name of the method this instruction operates on or null </s>
funcom_train/39399513
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public TroothResult report(SQLUtils sqlUtils, String fingerprint, String userID) { TroothResult reportResult = doReportRevokePairWork(sqlUtils,fingerprint,userID,config.getReportUserIDName(),REPORT_SELECT_QUERY,REPORT_INSERT_QUERY,REVOKE_SELECT_QUERY,REVOKE_DELETE_ONE_REVOKE_QUERY,REVOKE_SELECT_ANYREVOKER_QUERY); // the single report revoke pair is only interesting for the revoke if (reportResult.getStatusCode() == TroothResult.STATUS_SINGLE_REPORT_REVOKE_PAIR) { reportResult = TroothResultFactory.createRepRevPair(reportResult); } return reportResult; } COM: <s> reports a fingerprint in the name of the provided user id </s>
funcom_train/50217433
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void createClassField(Composite parent) { // Create Label+Text+Browse button Class field classField = createJavaField(parent, JavaFieldType.CLASS); // Add completion to search classes FreemarkerJavaHelperUI.addTypeFieldAssistToText(classField, projectSettings.getProject(), IJavaSearchConstants.CLASS); // Validate class fields. classField.addModifyListener(new ModifyListener() { public void modifyText(ModifyEvent e) { validate(); } }); } COM: <s> create class field </s>
funcom_train/16545510
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void artifactSelectedInGraph(Artifact artifact) { System.out.println(artifact + " selected"); if(artifact != null) { /* an artifact is selected */ enableSingleArtifactButtons(true); enableMutlipleArtifactButtons(true); } else { /* no artifact is selected */ enableSingleArtifactButtons(false); enableMutlipleArtifactButtons(false); } } COM: <s> method called when a node is selected in the visualisation graph </s>
funcom_train/33750063
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isGeneAnnotated(Gene gene, String annotation) { if ((gene == null) || (annotation == null)) return false; String currAnnot; Iterator<String> annotIter = gene.annotationsIterator(); while(annotIter.hasNext()) { currAnnot = annotIter.next(); if (currAnnot.equals(annotation)) { return true; } if (_transitiveClosure.containsEdge(currAnnot, annotation)) { return true; } } return false; } COM: <s> checks if a gene is annotated with some annotation </s>
funcom_train/10666412
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Result testBindWithoutSM() { try { final InitialContext ctx = createCtx(false); ctx.bind(objName, remObj); } catch (final Exception e) { e.printStackTrace(); return failed(e.getMessage()); } finally { try { reg.unbind(objName); } catch (final Exception e) { } } return passed(); } COM: <s> try to bind remote object without installing security manager </s>
funcom_train/10017940
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private int internNode(Object node) { int nd = EXISchema.NIL_NODE; if (node != null) { if ((nd = getDoneNodeId(node)) == EXISchema.NIL_NODE) { nd = m_n_nodes; putDoneNodeId(node, nd); } } return nd; } COM: <s> intern a node </s>
funcom_train/7881519
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void outci(String bin) { // set effective address regEFFADDR = effAdrIO(bin); // parse out immediate value StringBuilder string = new StringBuilder(); int firstChar = Integer.valueOf(bin.substring(16, 24), 2); int secondChar = Integer.valueOf(bin.substring(24, 31), 2); string.append((char) firstChar); string.append((char) secondChar); // print string System.out.println(string); } COM: <s> description immediate string or character is displayed to the output </s>
funcom_train/34838321
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Repository createRepository(String language_type) throws GlueException { if ((language_type==null)||(language_type=="")) { throw new GlueException("You must specify a language type to create a new repository"); } return new GlueRepository(config_dir, language_type); } COM: <s> create a new repository service component </s>
funcom_train/19381352
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void updateAdminInfo() throws Exception { if (_dsAdmin.getRowStatus() == DataStore.STATUS_NEW || _dsAdmin.getRowStatus() == DataStore.STATUS_NEW_MODIFIED) { _dsAdmin.createAdmin(); } else { _dsAdmin.update(); } } COM: <s> updates the administrator detailed information </s>
funcom_train/8686037
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isSelected(File basedir, String filename, File file) { validate(); Enumeration e = selectorElements(); boolean result; while (e.hasMoreElements()) { result = ((FileSelector) e.nextElement()).isSelected(basedir, filename, file); if (!result) { return false; } } return true; } COM: <s> returns true the file is selected only if all other selectors </s>
funcom_train/15636660
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public BitString pack1d(int dimension, double value) { if (dimension >= dim) throw new IllegalArgumentException("Dimension doesn't exist."); BitString temp = new BitString(); // stretch input to whole hashing range temp=new BitString( pc[dimension].multiply(BigDecimal.valueOf(value),mc) .add(pd[dimension],mc) .toBigInteger()); return temp; } COM: <s> hashes the input using code dimension code hashing limits </s>
funcom_train/45451049
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testCreateFromMillis() throws Exception { java.util.Date javaDate = new java.util.Date(); Date testDate = new Date(javaDate.getTime()); assertNotNull("Test Date could not be created.", testDate); assertEquals("Test millis inconsistent", javaDate.getTime(), testDate.getTime()); } COM: <s> test creating a date from a millisecond value </s>
funcom_train/35595159
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private BufferedImage flipHorizontally(BufferedImage img) { int w = img.getWidth(); int h = img.getHeight(); BufferedImage bi = new BufferedImage(w, h, img.getType()); Graphics2D g = bi.createGraphics(); g.drawImage(img, 0, 0, w, h, w, 0, 0, h, null); g.dispose(); return bi; } COM: <s> flips an image horizontally </s>
funcom_train/25248924
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void convertToRGBImage() { imageIcon = new ImageIcon(currentbufferedimage); loadedImage = imageIcon.getImage(); image = new BufferedImage(loadedImage.getWidth(null), loadedImage.getHeight(null), BufferedImage.TYPE_INT_RGB); Graphics2D g2 = image.createGraphics(); g2.drawImage(loadedImage, 0, 0, null); imageIcon = null; loadedImage = null; } COM: <s> this routine used to convert the rgb image </s>
funcom_train/41666663
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void copyPropertiesFrom(ViewModel anotherViewModel) { setModel(anotherViewModel.getModel()); setContextViewModel(anotherViewModel.getContextViewModel()); setEntities(anotherViewModel.getEntities()); setAction(anotherViewModel.getAction()); setEntity(anotherViewModel.getEntity()); setUpdateEntity(anotherViewModel.getUpdateEntity()); setPropertyConfig(anotherViewModel.getPropertyConfig()); setLookupEntities(anotherViewModel.getLookupEntities()); setUserProperties(anotherViewModel.getUserProperties()); } COM: <s> copies properties from another view model to this view model </s>
funcom_train/4884569
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Command getBackCommand5 () { if (backCommand5 == null) {//GEN-END:|399-getter|0|399-preInit // write pre-init user code here backCommand5 = new Command ("Voltar", Command.BACK, 0);//GEN-LINE:|399-getter|1|399-postInit // write post-init user code here }//GEN-BEGIN:|399-getter|2| return backCommand5; } COM: <s> returns an initiliazed instance of back command5 component </s>
funcom_train/45347289
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: static private String hexEncode(byte[] bytes) { StringBuffer result = new StringBuffer(); for (int i = 0; i < bytes.length; i++) { byte b = bytes[i]; result.append(DIGITS[(b & 0xf0) >> 4]); result.append(DIGITS[b & 0x0f]); } return result.toString(); } COM: <s> encode unique byte set to a string </s>
funcom_train/3168469
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public OrderSpec getDescending() { OrderSpec result = fetchDescending(); if (result == null) { throw new AboraRuntimeException(AboraRuntimeException.NO_FULL_ORDER); } return result; /* udanax-top.st:14365:CoordinateSpace methodsFor: 'accessing'! {OrderSpec} getDescending "The mirror image of the partial order returned by 'CoordinateSpace::getAscending'." | result {OrderSpec | NULL} | result := self fetchDescending. result == NULL ifTrue: [Heaper BLAST: #NoFullOrder]. ^result! */ } COM: <s> the mirror image of the partial order returned by coordinate space get ascending </s>
funcom_train/47678922
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String genJSArray(String[] values) { String js = "new Array("; if (values == null) { values = new String[1]; values[0] = ""; } setJSConv(); for (int i = 0; i < values.length; i++) { js += "\"" + convStr(values[i]) + "\","; } js = js.substring(0, js.length() - 1); js += ")"; return js; } COM: <s> generates a java script array based on a java array of string values </s>
funcom_train/877788
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void warning(SAXParseException exception) throws SAXException { if (errorHandler != null) { log.warn("Parse Warning Error at line " + exception.getLineNumber() + " column " + exception.getColumnNumber() + ": " + exception.getMessage(), exception); errorHandler.warning(exception); } } COM: <s> forward notification of a parse warning to the application supplied </s>
funcom_train/44770259
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int hashCode() { // QName is immutable, we can store the computed hash code value int h = hash; if (h == 0) { h = 17; h = 37 * h + namespaceURI.hashCode(); h = 37 * h + localName.hashCode(); hash = h; } return h; } COM: <s> returns the hash code of this qualified name </s>
funcom_train/16706762
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private double topicCoherence(int[] terms) { double tc = 0; for (int i = 1; i < terms.length; i++) { for (int j = 0; j < i - 1; j++) { int codf = coocDf(terms[i], terms[j]); tc += Math.log((codf + 1.) / df[terms[j]]); } } return tc; } COM: <s> perform tc analysis </s>
funcom_train/27823469
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void parseTokenStore(TokenTraverseStore store, String id) { Vector pointer = new Vector(); Vector pointerTemp = new Vector(); while(store.next()) { parse(store, pointer, pointerTemp, id); Vector shortTerm = pointer; pointer = pointerTemp; pointerTemp = shortTerm; pointerTemp.removeAllElements(); } } COM: <s> parses the entire token travers store </s>
funcom_train/40421562
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getUpDown() throws IOException { String state = getState(); int up = getStateFor("up:" + state, xCoord, yCoord - 1, state); int down = getStateFor("down:" + state, xCoord, yCoord + 1, state); return (up << 16) | down; } COM: <s> get the value for the up down parameter of visual rchandler </s>
funcom_train/43191770
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JRadioButton getWriteRadioButton() { if (writeRadioButton == null) { writeRadioButton = new JRadioButton(); writeRadioButton.setBounds(new Rectangle(480, 190, 61, 21)); writeRadioButton.addActionListener(operationListener); getOperationGroup().add(writeRadioButton); writeRadioButton.setText("Write"); } return writeRadioButton; } COM: <s> this method initializes write radio button </s>
funcom_train/25657147
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: static public void getIntegratedProperties(String filename) throws IOException { if (IntegratedProperties.last != null) { return; } if (filename == null) throw new IllegalArgumentException("The filenamepased to " + "PropertiesFactory.getIntegratedProperties() can not be null."); new IntegratedProperties(filename); } COM: <s> this factory will create the integrated properties given only a file name </s>
funcom_train/17902564
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void startHideTimer() { final Runnable runner = new Runnable() { public void run() { hidePanel(); } }; TimerTask hidePanel = new TimerTask() { public void run() { EventQueue.invokeLater(runner); } }; timer = new Timer(); timerStarted = true; timer.schedule(hidePanel, timeout); } COM: <s> creates and starts the hide panel timer task </s>
funcom_train/19797819
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setFilterConfig(FilterConfig filterConfig) { this.filterConfig = filterConfig; if (filterConfig==null){ view_url = null; } else { view_url = filterConfig.getInitParameter(ATTR_VIEW_URL); if (view_url==null||view_url.equals("")) view_url = null; if (debug) { log("Antispam:Initializing filter"); } } } COM: <s> set the filter configuration object for this filter </s>
funcom_train/8988115
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void deleteStylesheet() { // find start of the section final int start = strBuf.indexOf(SEC_START); if (start == -1) { // section not contained, so just return ... return; } // find end of section final int end = strBuf.indexOf(SEC_END, start); // delete section strBuf.delete(start, end + 2); } COM: <s> deletion of the prblematic section </s>
funcom_train/16476120
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void fireProjectCloseEvent(BenchmarkProject e) { // System.out.println("Fire ProjectCloseEvent: " + e.toString()); // DEBUG final BenchmarkProjectEvent event = new BenchmarkProjectEvent(e); fireEvent( new EventHandler<BenchmarkProjectEvent>(event) { @Override protected void dispatch(ProjectEventListener listener, BenchmarkProjectEvent event) { listener.projectClosed(event); } }); } COM: <s> fire an event to note that the given project was closed </s>
funcom_train/39127727
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public MidiLane createMidiLane() { sequence.createTrack(); FrinikaTrackWrapper ftw = sequence.getFrinikaTrackWrappers().lastElement(); ftw.setMidiChannel(0); MidiLane lane = new MidiLane(ftw, this); // Set channel 1 (0) as default MIDI channel // MidiLane lane = new MidiLane(ftw,this); add(lane); return lane; } COM: <s> creates a midi lane and adds it to the lane collection </s>
funcom_train/48476487
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public HandlerRegistration addFilterEditorSubmitHandler(com.smartgwt.client.widgets.grid.events.FilterEditorSubmitHandler handler) { if(getHandlerCount(com.smartgwt.client.widgets.grid.events.FilterEditorSubmitEvent.getType()) == 0) setupFilterEditorSubmitEvent(); return doAddHandler(handler, com.smartgwt.client.widgets.grid.events.FilterEditorSubmitEvent.getType()); } COM: <s> add a filter editor submit handler </s>
funcom_train/4900622
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setZoomSliderVisible(boolean zoomSliderVisible) { boolean old = this.isZoomSliderVisible(); this.zoomSliderVisible = zoomSliderVisible; zoomSlider.setVisible(zoomSliderVisible); firePropertyChange("zoomSliderVisible",old,this.isZoomSliderVisible()); } COM: <s> sets if the zoom slider should be visible </s>
funcom_train/15911905
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setActive(boolean active) { if (this.active && !active) { // Turn off event handlers this.active = false; node.removeMouseListener(this); node.removeMouseMotionListener(this); } else if (!this.active && active) { // Turn on event handlers this.active = true; node.addMouseListener(this); node.addMouseMotionListener(this); } } COM: <s> specifies whether this event handler is active or not </s>
funcom_train/20044839
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void _flush() { requiredMethod("writeBytes()"); boolean res; try { oObj.flush(); res = true; } catch (com.sun.star.io.IOException e) { e.printStackTrace(log) ; res = false; } tRes.tested("flush()", res); } COM: <s> test flushes out data from stream </s>
funcom_train/15896955
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getDfResidual(String modelName) throws RSrvException, RWebServiceException { loadModel(modelName, "lm", connection); REXP ret = connection.eval(modelName + "$df.residual"); if (!maintainState) connection.close(); return ret.asInt(); } COM: <s> gets the code df </s>
funcom_train/12759287
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JTabbedPane buildTabbedPanel() { /** * Editor Panel */ JTabbedPane tabbedPane = new JTabbedPane(); tabbedPane.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5)); tabbedPane.setFont(headerFont); tabbedPane.addTab("Main", buildMainPanel()); tabbedPane.addTab("Report", buildReportPanel()); tabbedPane.addTab("Configuration", buildConfigurationPanel()); // For testing purposes // addTestConfigurationInfo(); return tabbedPane; } COM: <s> method build tabbed panel </s>
funcom_train/35534289
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setTipos_cursos(List<TipoCurso> tipos_cursos) { List<TipoCurso> oldTipos_cursos = this.tipos_cursos; this.tipos_cursos = tipos_cursos; propertyChangeSupport.firePropertyChange(PROP_TIPOS_CURSOS, oldTipos_cursos, tipos_cursos); } COM: <s> set the value of tipos cursos </s>
funcom_train/18950508
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addSection( Section pSection ) { if( ErrorUtil.not_null( pSection, "pSection" ) ) { String name = pSection.getName(); if( ErrorUtil.not_null( name, "name" ) ) { iSectionsByName.put( name, pSection ); } } } COM: <s> add a section </s>
funcom_train/25707327
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JRadioButton getBoards_RBdisplayed() { if( boards_RBdisplayed == null ) { boards_RBdisplayed = new JRadioButton(); boards_RBdisplayed.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(final java.awt.event.ItemEvent e) { boards_RBitemStateChanged(); } }); } return boards_RBdisplayed; } COM: <s> this method initializes j radio button9 </s>
funcom_train/17603548
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void createModuleTables() throws IOException { for (ModuleJar moduleJar : moduleJars) { logger.info("Creating database schema for module [" + moduleJar.getModuleName() + "]"); ModuleContext cCtx = new ModuleContext(moduleJar, databaseVersions.get(moduleJar.getModuleName())); generateTable(new ModuleArtifactService(cCtx, cjs)); } } COM: <s> creates modules tables </s>
funcom_train/38551960
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setSourceJarName(String sourceJarName) { Cube42NullParameterException.checkNull(sourceJarName, "sourceJarName", "setSourceJarName", this); synchronized(this.systemTestID) { this.systemTestID.setSourceJarName(sourceJarName); } } COM: <s> sets the source jar name </s>
funcom_train/12843335
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private IPropertyDescriptor createFixedPropertyDescriptor(CMAttributeDeclaration attrDecl, CMDataType helper) { // the displayName MUST be set String attrName = DOMNamespaceHelper.computeName(attrDecl, fNode, null); EnumeratedStringPropertyDescriptor descriptor = new EnumeratedStringPropertyDescriptor(attrName, attrName, _getValidFixedStrings(attrDecl, helper)); descriptor.setCategory(getCategory(attrDecl)); descriptor.setDescription(DOMNamespaceHelper.computeName(attrDecl, fNode, null)); return descriptor; } COM: <s> creates a property descriptor for an attribute with a fixed value if </s>
funcom_train/35645074
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void disconnectAllCharacters() { Collection<L1PcInstance> players = L1World.getInstance().getAllPlayers(); for (L1PcInstance pc : players) { pc.getNetConnection().setActiveChar(null); pc.getNetConnection().kick(); } // Kick save after all, make for (L1PcInstance pc : players) { ClientThread.quitGame(pc); L1World.getInstance().removeObject(pc); } } COM: <s> all players online to kick character and preservation of information </s>
funcom_train/12189581
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetUrlString() throws Exception { // Create a testable instance HTTPRequestOperationProcess process = (HTTPRequestOperationProcess) createTestableProcess(); // Now test a variety of protocols String protocol = "http"; checkProtocolMatch(process, protocol); protocol = "https"; checkProtocolMatch(process, protocol); protocol = "ftp"; checkProtocolMatch(process, protocol); } COM: <s> test the set url string method </s>
funcom_train/25275093
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getSelectedEditorCode() { IEditorPart editorPart = SnipplePluginActivator.getDefault().getWorkbench().getActiveWorkbenchWindow() .getActivePage().getActiveEditor(); IEditorSite iEditorSite = editorPart.getEditorSite(); ISelectionProvider selectionProvider = iEditorSite.getSelectionProvider(); ISelection iSelection = selectionProvider.getSelection(); return ((ITextSelection) iSelection).getText(); } COM: <s> getting selected source code fragment in the editor </s>
funcom_train/25774340
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JButton getJStopGameButton() { if (jStopGameButton == null) { jStopGameButton = new JButton(); jStopGameButton.setText("Stop"); jStopGameButton.setEnabled(false); jStopGameButton.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { jStopGameButton.setEnabled(false); stopGame(); jStartGameButton.setEnabled(true); } }); } return jStopGameButton; } COM: <s> this method initializes j stop game button </s>
funcom_train/22064021
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void process(char ch) { if ((ch >= ' ') && (ch <= '~')) { int max = text.getText().length(); line.insert( lineInsert, ch ); lineInsert++; text.replaceRange( line.toString(), textLength,max); text.setCaretPosition(textLength+lineInsert); } } COM: <s> insert the character ch if it is a valid character into the </s>
funcom_train/50083357
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean readXMLInformation(Element element) { if (element == null) { return false; } else { this.dbURL = element.getChild(DBCONNECTION_POSTGRES).getChildText(DBURL); this.userName = element.getChild(DBCONNECTION_POSTGRES).getChildText(DBUSER_NAME); this.userPassword = element.getChild(DBCONNECTION_POSTGRES).getChildText(DBUSER_PASSWORD); this.sqlStatement = element.getChild(DBCONNECTION_POSTGRES).getChildText(SQLQUERY); return true; } } COM: <s> read the xml content from this element to create this object </s>
funcom_train/37087563
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private boolean pointInEdgeRegion(Edge e,int x, int y) { Rectangle r = new Rectangle(nodePt(e.getNode1())); r.add(nodePt(e.getNode2())); r.grow(POINT_RADIUS,POINT_RADIUS); // as mouse doesnt have to be exactly on edge return pointInRectangle(x,y,r); } COM: <s> this works in screen space not angstroms jmol </s>
funcom_train/15519325
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void setSimilarity (int level, int index, byte sim_value) { int level_offset = 0; for (int levelI = 0; levelI < level; levelI++) { level_offset += level_sizes[levelI]; } if (index > level_sizes[level]) throw new ArrayIndexOutOfBoundsException (); sim_index[level_offset + index] = sim_value; } COM: <s> set an individual similarity value </s>
funcom_train/4521083
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void save(ParametroCedula entity) { LogUtil.log("saving ParametroCedula instance", Level.INFO, null); try { entityManager.persist(entity); LogUtil.log("save successful", Level.INFO, null); } catch (RuntimeException re) { LogUtil.log("save failed", Level.SEVERE, re); throw re; } } COM: <s> perform an initial save of a previously unsaved parametro cedula entity </s>
funcom_train/50534466
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void Stop() { Entry entry; // i. If retransmitter is owned, stop it else cancel all tasks // ii. Clear all pending msgs synchronized(msgs) { if (retransmitter_owned) { try { retransmitter.stop(); } catch(InterruptedException ex) { Trace.error("NakReceiverWindow.Stop()", _toString(ex)); } } else { for (int i = 0; i < msgs.size(); ++i) { entry = (Entry)msgs.get(i); entry.cancel(); } } msgs.clear(); } } COM: <s> stop the rentransmition and clear all pending msgs </s>
funcom_train/28506124
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setNextPos() { if ((xpos>baseX && movaction==2)||(xpos<contx && movaction==1)) xpos += speed; else moveStop(); if (container!=null) container.updatePosition(speed,0.0f,0.0f); } COM: <s> set the next position for the crane </s>
funcom_train/14358364
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: final public Concept StructConcept() throws ParseException { String name; Concept structc; jj_consume_token(LBRACE); name = String(); structc = ConceptArg(name); jj_consume_token(RBRACE); {if (true) return structc;} throw new Error("Missing return statement in function"); } COM: <s> whenever brackets are found </s>
funcom_train/33059305
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addMethod(String methodName, Class[] argTypes) throws Exception { Method[] meths = cls.getMethods(); int i; Method meth; meth = cls.getMethod(methodName,argTypes); //Class[] clss = meth.getParameterTypes(); //clss = argTypes; methods.put(methodName,meth); } COM: <s> loads given method for use </s>
funcom_train/22543016
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Contact readContact() throws IOException { Vendor vendor = readVendor(); Version version = readVersion(); KUID nodeId = readKUID(); SocketAddress addr = readSocketAddress(); if (addr == null) { throw new UnknownHostException("SocketAddress is null"); } return ContactFactory.createUnknownContact(vendor, version, nodeId, addr); } COM: <s> reads a contact from the input stream </s>
funcom_train/35108959
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public IVMRunner getVMRunner(String mode) { if (ILaunchManager.DEBUG_MODE.equals(mode)) { return new JiveVMDebugger(this); } else { // TODO Add log message after internationalizing the above string literal //JiveLaunchingPlugin.log("JIVE can only be used when launching in debug mode."); throw new IllegalStateException("JIVE can only be used when launching in debug mode."); } } COM: <s> returns a vm runner that runs this installed vm with jive debugging enabled </s>
funcom_train/38806548
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getActiveTaskId(GanttPoint position) { Iterator it = shapeMap.keySet().iterator(); for (; it.hasNext();) { Integer taskId = (Integer) it.next(); ShapeAdapter s = (ShapeAdapter) shapeMap.get(taskId); if (s.contains(position)) { System.out.println(taskId); return taskId.intValue(); } } return 0; } COM: <s> get id of active task </s>
funcom_train/41524628
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void endsLogCommand(Command cmd){ TransactionStatus status = null; boolean commit = true; try{ //Log completion of the command status = getTxStatus(cmd.getActionName(), false, Command.ISOLATION_DEFAULT, Command.PROPAGATION_REQUIRED); cmd.endsCommandLog(); }catch(Exception e){ logMessage(cmd, "It is not possible to log end command execution", e); txManager.rollback(status); commit = false; } if(commit) txManager.commit(status); } COM: <s> this method completes the audit log into database but if it </s>
funcom_train/130298
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void close () { try { /* close all sockets */ os.close (); buffer.close (); is.close (); socket.close (); } catch (Exception e) { System.err.println ("[PlayerClient] : Error in PlayerClient stop: " + e.toString ()); System.exit (1); } } COM: <s> the player client destructor </s>
funcom_train/6401752
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void processImage(imageType image) throws Exception { if (image.hasdata()) { if (!squelch) { logger.warning("Raw data images not supported."); } } if (image.hasinit_from()) { put(image.getid().toString(), image.getinit_from().toString()); } } COM: <s> process image takes an image type and places the necessary information in </s>
funcom_train/9871698
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void ensureCapacity(int minCapacity) { int oldCapacity = elementData.length; if (minCapacity > oldCapacity) { float[] oldData = elementData; int newCapacity = (oldCapacity * 3)/2 + 1; if (newCapacity < minCapacity) newCapacity = minCapacity; elementData = new float[newCapacity]; System.arraycopy(oldData, 0, elementData, 0, size); } } COM: <s> increases the capacity of this tt float array tt instance if </s>
funcom_train/42445767
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void releaseConnection() throws QcException { try { if (connectionReleased.compareAndSet(false, true)) { if (log.isDebugEnabled()) { log.debug("Releasing connection"); } // if (isConnected()) { connection.invoke("releaseConnection"); // } log.info("connection released"); internalSleep(); ComThread.Release(); } else { log.warn("CONNECTION NOT RELEASD!!"); } } catch (final ComFailException e) { throw new QcException("Error releasing the connection", e); } } COM: <s> release the connection </s>
funcom_train/4774412
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public List getNames(int maxLength) { AddressDb db = new AddressDb(); List<Person> people = db.getAll(); List names = new LinkedList<String>(); for (Person person : people) { String name = person.getName(); if (name.length() > maxLength) { name = name.substring(0, maxLength); } names.add(name); } String oldName = ""; oldName = oldName + names; return names; } COM: <s> returns all names in the book </s>
funcom_train/34314271
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean hasMissingLabels(Instance instance) { int numLabels = getNumLabels(); int[] labelIndices = getLabelIndices(); boolean missing = false; for (int j = 0; j < numLabels; j++) { if (instance.isMissing(labelIndices[j])) { missing = true; break; } } return missing; } COM: <s> method that checks whether an instance has missing labels </s>
funcom_train/31056290
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { GZIPInputStream gis = new GZIPInputStream(in); ObjectInputStream is = new ObjectInputStream(gis); dim = (Dimension)is.readObject(); data = (int[])is.readObject(); } COM: <s> reads the compressed image from the input stream </s>
funcom_train/5017883
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String getExplorer() { if (System.getProperty("explorer") != null) { String explorerId = System.getProperty("explorer"); if (explorerId.equals("ie")) { return IE; } if (explorerId.equals("firefox")) { return FIREFOX; } if (explorerId.equals("opera")) { return OPERA; } } return IE; } COM: <s> this method will try to retrieve the system property explorer </s>
funcom_train/31873009
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void trimRewards(int value) { this.top.trimReward(value, MINIMUM_REWARD); /* obsolete, no use of rewardList anymore * TODO clean up for rewardList final ListIterator<QNode> i = this.rewardList.listIterator(); while (i.hasNext()) { final QNode n = i.next(); if (n.reward < MINIMUM_REWARD) n.remove(); } */ } COM: <s> substracts a given rewards value </s>
funcom_train/15954655
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetMonth() { DataDate lDataDate = new DataDate(fYear,fMonth,fDay,fTimeZone); int lMonth = 10; lDataDate.setMonth(lMonth); assertEquals(lMonth,lDataDate.getMonth()); } COM: <s> test of set month method </s>
funcom_train/46162008
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setPlaybackSpeed(float speed) { synchronized (speedChangeLock) { long currTime = System.currentTimeMillis(); this.elapsed += this.playbackSpeed * (currTime - this.timeOfLastSpeedChange); this.timeOfLastSpeedChange = currTime; this.playbackSpeed = speed; this.handleSpeedChange((double) speed); } } COM: <s> set a particular playback speed and update the total elapsed time </s>
funcom_train/38573969
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String toString(){ String defaultFileTypes = ""; if(extensions == null){ return null; } for(int i=0; i<extensions.length; i++){ defaultFileTypes += extensions[i]; if(i != extensions.length - 1){ defaultFileTypes += "; "; } } return defaultFileTypes; } COM: <s> returns a formatted string of extensions for display </s>
funcom_train/4912360
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void annotate(TrieDictionary<String> terms, String type) { // in each annotation step find and replace any new annotations this.text = convertChunkingToRawResult(new LongestMatchChunker( new ApproxDictionaryChunker(terms, IndoEuropeanTokenizerFactory.FACTORY, ANNOT_DISTANCE, MAX_DISTANCE)).chunk(this.text), type, this.annotations); } COM: <s> annotates all terms that are given by the provided dictionary with the </s>
funcom_train/27719828
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testColSpan() { System.out.println("testColSpan"); assertEquals(2, tl.colSpan(5, 10)); assertEquals(2, tl.colSpan(5, 12)); assertEquals(3, tl.colSpan(5, 13)); assertEquals(3, tl.colSpan(5, 15)); } COM: <s> test of col span method of class puce </s>
funcom_train/12179316
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testIncrementalDuplicates() throws Exception { initializeTest(); rewrite("logo.jpg", PageURLType.IMAGE); assertEquals(1, prerendererPackageContext.getIncrementalRewrittenURIMap().size()); rewrite("logo.jpg", PageURLType.IMAGE); assertEquals(0, prerendererPackageContext.getIncrementalRewrittenURIMap().size()); } COM: <s> tests that get incremental rewritten urimap does not return duplicates </s>
funcom_train/14599894
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected HtmlParseTree createHeadParseTree() { final HtmlParseTree headTree = super.createHeadParseTree(); headTree.setAttributeValueListener("frame", "src", new AttributeValueListener() { public void setValue(String frameUrl) { addLink(frameUrl); setEncounteredFrameset(true); frameInHead = true; } }); return headTree; } COM: <s> returns the head parse tree </s>
funcom_train/48183579
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void showApplyInstance(Category[] inputs) { StringBuffer sb = new StringBuffer(); sb.append(_name).append(": "); for (int i=0; i < inputs.length; i++) { sb.append(inputs[i]).append(' '); } System.out.println(sb); } COM: <s> prints an apply instance for the given categories to system </s>
funcom_train/32752108
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setFont(Font fnt) { table.setFont(fnt); borderGraph.setTitleFont(fnt); titleLabel.setFont(fnt); cntrlPanelTitle_Label.setFont(fnt); autoUpdate_Button.setFont(fnt); lastTimeLabel_Label.setFont(fnt); lastTimeText_Label.setFont(fnt); freq_cntrlPanel_Spinner.setFont(fnt); ((JSpinner.DefaultEditor) freq_cntrlPanel_Spinner.getEditor()).getTextField().setFont(fnt); cntrlPanelTime_Label.setFont(fnt); setRefButton.setFont(fnt); wrapButton.setFont(fnt); } COM: <s> sets the font </s>
funcom_train/33058905
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setAttribute(String name, Object value) { // Null value is the same as removeAttribute() if (value == null) { removeAttribute(name); return; } // Validate our current state // Replace or add this attribute Object unbound = null; synchronized (attributes) { unbound = attributes.get(name); attributes.put(name, value); } } COM: <s> bind an object to this session using the specified name </s>
funcom_train/39320195
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void removeSequentialArcs(CompTransition t, Set<CompTransition> conflicts) { Set<CompPlace> my_preset = preSet(t); Set<CompPlace> my_postset = postSet(t); for (Iterator<CompTransition> it = conflicts.iterator(); it.hasNext(); ) { CompTransition u = it.next(); if (! Collections.disjoint(my_preset, postSet(u)) || ! Collections.disjoint(my_postset, preSet(u))) it.remove(); } } COM: <s> remove sequential arcs from conflict set </s>
funcom_train/20633187
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setConnMgr (ApelConnectionMgr connMgr) { fConnectionMgr = connMgr; setConnectionItems (fConnectionMgr.getConnectionItems()); getAlwaysConnectChkbx().setSelected (fConnectionMgr.getAlwaysConnect()); getDefaultValueChkbx().setSelected (fConnectionMgr.getUseAsDefaults()); } COM: <s> sets the conn mgr property com </s>
funcom_train/42282849
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected IDataType registerDataType(IDataType type, String standardName, int priority) { primaryTypeNames = null; // invalidate cache registeredTypes.put(type.getPrimaryName().toUpperCase(), type); if (standardName != null) { standardMappings.put( type.getPrimaryName().toUpperCase(), new StandardTypeConverter(standardName, priority)); } return type; } COM: <s> register a datatype with a given standard sql name </s>
funcom_train/45801172
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void validateAll() throws OptionValidationException { boolean unattended = getBooleanValue(UNATTENDED, false); Iterator keys = getOptionNames(); while (keys.hasNext()) { String optionId = (String) keys.next(); OptionDefinition opt = OptionDefinition.get(optionId, this); opt.validateValue(getValue(optionId), unattended); } } COM: <s> validate the options assuming defaults have already been applied </s>
funcom_train/11042385
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void processElement(XmlSchemaElement xsElt, Map<QName,String> innerElementMap, List<QName> localNillableList, XmlSchema parentSchema) throws SchemaCompilationException { processElement(xsElt, false, innerElementMap, localNillableList, parentSchema); } COM: <s> for inner elements </s>
funcom_train/40799310
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof AdminPermission)) { return false; } AdminPermission ap = (AdminPermission) obj; if(bundle == null){ return ((actionMask == ap.actionMask) && getName().equals(ap.getName())); } else{ return (actionMask == ap.actionMask && bundle == ap.bundle); } } COM: <s> determines the equality of two code admin permission code objects </s>