__key__
stringlengths
16
21
__url__
stringclasses
1 value
txt
stringlengths
183
1.2k
funcom_train/19537737
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private BigDecimal JSONLength(Object obj) throws ParserException { if (obj instanceof JSONObject) { JSONObject jobj = (JSONObject) obj; return BigDecimal.valueOf(jobj.keySet().size()); } else if (obj instanceof JSONArray) { JSONArray jarr = (JSONArray) obj; return BigDecimal.valueOf(jarr.size()); } else { throw new ParserException(I18N.getText("macro.function.json.unknownType", obj == null ? "NULL" : obj.toString(), "json.length")); } } COM: <s> gets the length of a json object </s>
funcom_train/40614892
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public long length() throws SQLException { try { debugCodeCall("length"); checkClosed(); if (value.getType() == Value.BLOB) { long precision = value.getPrecision(); if (precision > 0) { return precision; } } return IOUtils.copyAndCloseInput(value.getInputStream(), null); } catch (Exception e) { throw logAndConvert(e); } } COM: <s> returns the length </s>
funcom_train/19052009
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void insertUpdate(DefaultDocumentEvent chng, AttributeSet attr) { if (attr == null) { attr = contentAttributeSet; } // If this is the composed text element, merge the content attribute to it else if (attr.isDefined(StyleConstants.ComposedTextAttribute)) { ((MutableAttributeSet) attr).addAttributes(contentAttributeSet); } super.insertUpdate(chng, attr); } COM: <s> updates document structure as a result of text insertion </s>
funcom_train/2862016
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void done() { long currentTime = System.currentTimeMillis(); // This needs to interrupt all threads on the busy list. // A close request is an implicit interrupt for all current work!! if ( log.traceOn(Log.TRACE_MSGS) ) log.println("finalize: for session " + sessionId); log.close(); log = null; } COM: <s> clean up this user session </s>
funcom_train/37035823
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void deleteDir(File dir) { String files[] = dir.list(); if (files == null) { files = new String[0]; } for (int i = 0; i < files.length; i++) { File file = new File(dir, files[i]); if (file.isDirectory()) { deleteDir(file); } else { file.delete(); } } dir.delete(); } COM: <s> delete the specified directory including all of its contents and </s>
funcom_train/3152251
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Map getParameterValuesMap() { if (parameterValuesMap==null) { parameterValuesMap=new EnumerationMap(request.getParameterNames(), new KeyResolver() { public Object resolve(Object key) { return request.getParameterValues((String)key); } }); } return parameterValuesMap; } COM: <s> get a map of parameter names to multiple values </s>
funcom_train/39864834
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void writeHex(int i) throws IOException { int cursor = 8; do { hex[--cursor] = HEX_DIGITS[i & 0xf]; } while ((i >>>= 4) != 0); socketOut.write(hex, cursor, hex.length - cursor); } COM: <s> equivalent to but cheaper than writing integer </s>
funcom_train/4521126
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void delete(ConstanciaVotacion entity) { LogUtil.log("deleting ConstanciaVotacion instance", Level.INFO, null); try { entity = entityManager.getReference(ConstanciaVotacion.class, entity.getNumerodocumento()); entityManager.remove(entity); LogUtil.log("delete successful", Level.INFO, null); } catch (RuntimeException re) { LogUtil.log("delete failed", Level.SEVERE, re); throw re; } } COM: <s> delete a persistent constancia votacion entity </s>
funcom_train/35848232
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetNamespace() { Object ns = Model.getModelManagementFactory().createPackage(); Model.getCoreHelper().setNamespace(elem, ns); Model.getPump().flushModelEvents(); assertEquals(1, model.getSize()); assertEquals(ns, model.getElementAt(0)); } COM: <s> test for set name space </s>
funcom_train/50872883
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testRemoveElementAt() { OMApplication application = new OMApplication(); OMInteger integer = new OMInteger("1"); OMSymbol symbol = new OMSymbol("a","b"); application.addElement(integer); application.addElement(symbol); application.removeElementAt(0); assertTrue(application.getElementAt(0)==symbol); } COM: <s> test of remove element at method of class omapplication </s>
funcom_train/45329878
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void postBreak() { String cmdKill = config.getBreakCmd(); if (cmdKill != null) { System.out.println("Sending SIGINT to process. " + cmdKill); ExecutionCommand exec = new ExecutionCommand(cmdKill, config .getEnv(), new File(config.getWorkingDir())); exec.start(); } else { System.err.println("Unable to obtain break cmd."); } } COM: <s> send the sigint signal to the process to tell it to stop </s>
funcom_train/3859948
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void notestStaticMemberAccessRef() { // Type typeD = testModel.lookupType(TestClassD.class.getName()); // Type typeB = testModel.lookupType(TestClassB.class.getName()); // // assertNotNull(typeD); // assertNotNull(typeB); // // assertTrue(typeD.dependsOn(typeB)); } COM: <s> if a class references another just by accessing a static member </s>
funcom_train/43673210
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void effectOn(FiducialSCEffect fiducial) { try { // effectSynths.add(fiducial.addEffect(out, instGroup, // Constants.kAddToTail, this)); // placeholders[i].free(); fiducial.addEffect(out, instGroup, Constants.kAddToTail, this); } catch (IOException e) { e.printStackTrace(); } return; } COM: <s> by default all sc instruments are affected by effects </s>
funcom_train/3750786
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setUsiteList(List usites) { ListIterator elements = usites.listIterator(); StringBuffer buf = new StringBuffer(); while (elements.hasNext()) { Usite theUsite = (Usite)elements.next(); if (buf.length() > 0) { buf.append(" "); } buf.append(theUsite.getAddress()); } put(USITELIST, buf.toString()); } COM: <s> sets the list of usites in the broker defaults object </s>
funcom_train/34627270
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Color getColor(String rgb) { Color color = (Color) fColorTable.get(rgb); if (color == null) { color = new Color(Display.getCurrent(), PreferenceConverter.getColor(TexlipsePlugin.getDefault().getPreferenceStore(), rgb)); fColorTable.put(rgb, color); } return color; } COM: <s> return the color that is stored in the color table as rgb </s>
funcom_train/32011813
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setName(String name) { if ((name == null) || (name.length() == 0)) { throw new IllegalArgumentException("Invalid name [" + name + "]"); } getOperation().removeFault(getName()); this.name = name; getOperation().addFault(this); } COM: <s> sets the name of the fault </s>
funcom_train/12179216
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Element doBlinkTest(boolean supportsBlink, boolean supportsCSS) { MutablePropertyValues properties = createPropertyValues(); properties.setComputedAndSpecifiedValue( StylePropertyDetails.MCS_TEXT_BLINK, MCSTextBlinkKeywords.BLINK); return doTest(false, supportsBlink, false, false, supportsCSS, "p", properties); } COM: <s> utility method to test blink emulation </s>
funcom_train/21656153
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JButton getBtModificarCoordenadas() { if (btModificarCoordenadas == null) { btModificarCoordenadas = new JButton(); btModificarCoordenadas.setBounds(new Rectangle(150, 555, 100, 30)); btModificarCoordenadas.setMnemonic('m'); btModificarCoordenadas.setText("Modificar"); btModificarCoordenadas.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { guardarCoordenadas(); ControladorPrincipal.mostrarMenuEditarProyecto(); } }); } return btModificarCoordenadas; } COM: <s> this method initializes bt modificar coordenadas </s>
funcom_train/50151027
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setFlowIn(String c) { flowIn="None"; if (c!=null) { if (c.compareToIgnoreCase("RTS/CTS In")==0) flowIn="RTS/CTS In"; if (c.compareToIgnoreCase("Xon/Xoff In")==0) flowIn="Xon/Xoff In"; } } COM: <s> set control flow in </s>
funcom_train/35847712
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean loadURL(URL url) { try { propertyBundle.load(url.openStream()); LOG.info("Configuration loaded from " + url + "\n"); return true; } catch (Exception e) { if (canComplain) { LOG.warn("Unable to load configuration " + url + "\n"); } canComplain = false; return false; } } COM: <s> load the configuration from a specified location </s>
funcom_train/2890000
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private NotificationSubscription getSubscription(MessageContext messageContext) { MessageDocument request = messageContext.getRequest(); AlpineEPR to = getTo(request); String id = NotificationSubscription.extractSubscriptionIDFromAddress(to); NotificationSubscription sub = getServerInstance().getSubscriptionStore().lookup(id); if (sub == null) { FaultRaiser.raiseBadArgumentFault("No subscription at "+to); } return sub; } COM: <s> get the subscription </s>
funcom_train/32365859
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void injectSearchResultHandler(final SearchResultHandler handler) { // check if annotation found if (searchResultHandler == null) { return; } try { this.searchResultHandler.setAccessible(true); this.searchResultHandler.set(plugin, handler); } catch (IllegalArgumentException ex) { ClubmixerLogger.debugUnexpectedException(this, ex); } catch (IllegalAccessException ex) { ClubmixerLogger.debugUnexpectedException(this, ex); } } COM: <s> this method injects a search result handler into the annotated plugin </s>
funcom_train/28473632
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getTypeUnknownScorePanel() { if (typeUnknownScorePanel == null) { typeUnknownLabel = new JLabel(); typeUnknownLabel.setText("Unknown Score (0-1):"); typeUnknownLabel.setPreferredSize(new Dimension(180, 16)); typeUnknownScorePanel = new JPanel(); typeUnknownScorePanel.setLayout(new FlowLayout(FlowLayout.LEFT)); typeUnknownScorePanel.add(typeUnknownLabel, null); typeUnknownScorePanel.add(getTypeUnknownTextField(), null); } return typeUnknownScorePanel; } COM: <s> this method initializes type unknown score panel </s>
funcom_train/13849016
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setGroups(String[] groups) { try { ((DiscoveryGroupManagement) dm).setGroups(groups); } catch (IOException e) { throw new RuntimeException( "Could not change groups: " + e.getMessage(), e); } try { takeSnapshot(); } catch (IOException e) { throw new RuntimeException( "Could not log change: " + e.getMessage(), e); } } COM: <s> replace the list of groups to join with a new list </s>
funcom_train/7601552
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Panel getListPanel() { if (listPanel == null) { listPanel = new Panel(); listPanel.setLayout(new BoxLayout(getListPanel(), BoxLayout.X_AXIS)); listPanel.setMinimumSize(new Dimension(200, 80)); listPanel.setPreferredSize(new Dimension(200, 80)); listPanel.add(getFileList(), null); } return listPanel; } COM: <s> this method initializes list panel </s>
funcom_train/20827248
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getLevelControlGroupCount() { int groupCount = 0; if (getLevelControlCount() > 0) { if (getGroupSize() > 0) { groupCount = 1 + (getLevelControlCount() - 1) / getGroupSize(); } else { groupCount = 1; } } return groupCount; } COM: <s> gets the number of control element groups for level controls </s>
funcom_train/8995009
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public RuleBaseObject setRowNumRecordCount(RuleBaseObject ruleBaseObj, int rowNum, int totalNumOfRule){ //set the row number if ( rowNum > -1 ) { ruleBaseObj.setRowNum(rowNum); } //set the total number of the record if ( totalNumOfRule > -1 ) { ruleBaseObj.setRecordCount(totalNumOfRule); } return ruleBaseObj; } COM: <s> set the rule base object with the row number and the total number </s>
funcom_train/26536360
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setConfigElement(Element xml, String attrName) { checkElementTagName(xml); loadFilterID(xml); loadResourceBundle(xml); loadCommentSyntaxInformation(xml); loadStringSyntaxInformation(xml); loadFilenameEndings(xml); loadOptions(xml); loadFirstLinePatterns(xml); loadIgnoredLinePatterns(xml); } COM: <s> configure this filter based on information in the given xml element </s>
funcom_train/9236487
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String duration(final long secondsInput) { final StringBuilder result = new StringBuilder(); final long hours = secondsInput / 3600; final long minutes = secondsInput / 60 % 60; //final long seconds = secondsInput % 60; if (hours > 0) { result.append(hours).append("h "); } result.append(minutes).append("m"); return result.toString(); } COM: <s> get the duration in seconds as a string </s>
funcom_train/43039664
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean find2dIntersection(UTriangle t) { if (a2d == null || b2d == null || c2d == null || t.getA2d() == null || t.getB2d() == null || t.getC2d() == null) return false; if (intS.intersection2d(this, t) == true) return true; return false; } COM: <s> find 2d triangle triangle intersection </s>
funcom_train/25277026
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void changeProcessStatus(BusinessProcess process, ProcessStatus status) { synchronized (process) { ProcessStatus currentStatus = process.getStatus(); if (!currentStatus.equals(status)) { Log4jUtil.debug(logger, "Change status of process [name=" + process.getName() + "] from " + currentStatus + " to " + status); process.setStatus(status); } } } COM: <s> changes status of process </s>
funcom_train/12899399
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isSet(IPropertySource source) { // If the descriptor is also an ISourcedPropertyDescriptor, then // route over to it, but use the wrappered source instead. Else // Use the standard mechanism for testing the value from the wrappered source. if (fDescriptor instanceof ISourcedPropertyDescriptor) return ((ISourcedPropertyDescriptor) fDescriptor).isSet(fSource); else return fSource.isPropertySet(fDescriptor.getId()); } COM: <s> answer whether the value is set or not </s>
funcom_train/2291762
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private I_CmsReport getEventReport(CmsEvent event) { I_CmsReport report = null; if (event.getData() != null) { report = (I_CmsReport)event.getData().get(I_CmsEventListener.KEY_REPORT); } if (report == null) { report = new CmsLogReport(Locale.ENGLISH, getClass()); } return report; } COM: <s> returns the report in the given event data if code null code </s>
funcom_train/37508213
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public JMenuItem getMenuAlbumExportFilesystem() { if (m_menuAlbumExportFilesystem == null) { m_menuAlbumExportFilesystem = new JMenuItem("Filesystem", 'F'); m_menuAlbumExportFilesystem.setActionCommand( ACTION_ALBUM_EXPORT_FILESYSTEM); } return m_menuAlbumExportFilesystem; } COM: <s> returns the album export filesystem item </s>
funcom_train/7508276
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getRequestedSessionId() { String id = getHttpServletRequest().getRequestedSessionId(); String clean = ""; try { clean = ESAPI.validator().getValidInput("Requested cookie: " + id, id, "HTTPJSESSIONID", 50, false); } catch (ValidationException e) { // already logged } return clean; } COM: <s> returns the uri from the http servlet request after canonicalizing and </s>
funcom_train/18256488
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setMaximumColor(Color valueColor) { redMaximum = (float) valueColor.getRed() / 255.0F; greenMaximum = (float) valueColor.getGreen() / 255.0F; blueMaximum = (float) valueColor.getBlue() / 255.0F; calculateColorValues(); } COM: <s> sets the color at maximum intensity that is the color that </s>
funcom_train/24473803
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void indexToPointer() throws GraphException { for (NodeImpl node : this.nodes) { node.indexToPointer(); } for (PortImpl port : this.ports) { port.indexToPointer(); } for (EdgeImpl edge : this.edges) { edge.indexToPointer(); } } COM: <s> converts indexes to references </s>
funcom_train/366417
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Edge getEdge(Node n) { nodeItemCheck(n); for ( int i=0; i < m_edges.size(); i++ ) { Edge e = (Edge)m_edges.get(i); if ( n == e.getAdjacentNode(this) ) return e; } throw new NoSuchElementException(); } // COM: <s> returns the edge connected to the given neighbor node </s>
funcom_train/36715243
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public CommonSolvent enterText(String inputField, String text) { String inputLocator = "//input/following::td[normalize-space(text())='" + inputField + "']/following::input[1]"; if(!selenium.isElementPresent(inputLocator, 2000)) throw new SeleniumException("Unable to find input field name with '" + inputField + "' to type in '"+ text + "'"); selenium.type(inputLocator, text); return this; } COM: <s> enters specified text in edit box with the given field label name </s>
funcom_train/19741225
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void loadTestingFile(File f) throws FileNotFoundException, IOException, BadLocationException{ /* * loads and isplays a test-file... * ASSUME f is plain text file */ this.getHighlighter().removeAllHighlights(); this.setCaretColor(Color.black); TestFile TestFile = new TestFile(); TestFile.openFile(f); this.setDocument(TestFile); } COM: <s> loads and displays test file ending </s>
funcom_train/37566071
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Page getPage(String url) throws IOException { Page result = null, target = new Page(); UTF8 searchURL = new UTF8(url); // Don't do linear search. Instead, jump to the // chunk that will have it. return pagesByURL[DBKeyDivision.findURLSection(url, numMachines)].getPage(searchURL, target); } COM: <s> get page from the pagedb with the given url </s>
funcom_train/35178245
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void removeAccount(Long accountId) throws ObjectNotFoundException { try { AccountLocal account = EntityHomeCache.getInstance().getAccountHome() .findByPrimaryKey(accountId); account.remove(); } catch (FinderException e) { if (e.getClass() == ObjectNotFoundException.class) throw (ObjectNotFoundException) e; throw new EJBException(e); } catch (RemoveException e) { throw new EJBException(e); } } COM: <s> removes a code account lite code object from the database </s>
funcom_train/20364084
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Element getXML() { Element xml = new Element(XML_KEY); //name xml.setAttribute("name",traitName); xml.setAttribute("level" , ( traitLevel==MINOR_TRAIT ? "minor" : "major" ) ) ; if ( focus!=null ) { xml.setAttribute("focus" , focus); } if ( skill!=null ) { xml.setAttribute("skill" , skill); } return xml; } COM: <s> save this trait data as an xml element </s>
funcom_train/27843912
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public SwingViewOptions displayInInternalFrame(Container parent) { _options.put( DisplayModeOption.DISPLAY_MODE_OPTION, new Integer(DisplayModeOption.DISPLAY_IN_NON_MODAL_DIALOG)); _options.put(DisplayModeOption.PARENT_CONTAINER_OPTION, parent); setDefaultScreenPosition(GridBagConstraints.NORTHWEST); return this; } COM: <s> displays the view in an internal frame </s>
funcom_train/44502250
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String createScope(final Element scopeElement) { String scope = getTextValue(scopeElement); if (FacesWebApplicationContext.SCOPE_APPLICATION.equals(scope)) { scope = SCOPE_SINGLETON; } else if (FacesWebApplicationContext.SCOPE_NONE.equals(scope)) { scope = SCOPE_PROTOTYPE; } return scope; } COM: <s> evaluates the scope of the given managed bean definition </s>
funcom_train/7614149
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public StringBuffer getKeyChars() { if (keyInfo == null) { return null; } if (keyInfo.vKey == KeyEvent.VK_ENTER) { keyInfo.keyChars.setLength(0); keyInfo.setKeyChars('\n'); } return keyInfo.keyChars; } COM: <s> return the string of characters associated with the event </s>
funcom_train/31660966
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setAlpha(float Alpha_Arg) { debug(1, "setAlpha DSPopupMenu: " + Alpha_Arg); // MUST BE between 0 and 2*Pi // NO MORE NECESSARY but it doesn't cost something to keep it Alpha = (float) (Alpha_Arg % (Math.PI * 2)); if (Alpha < 0) Alpha += Math.PI * 2; AlphaOrigin = Alpha; } // setAlpha() COM: <s> sets the alpha attribute of the dspopup menu object </s>
funcom_train/24588476
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JScrollPane getJWorkingDateScrollPane() { if (jWorkingDateScrollPane == null) { jWorkingDateScrollPane = new JScrollPane(); jWorkingDateScrollPane.setBounds(new Rectangle(15, 380, 630, 250)); jWorkingDateScrollPane.setViewportView(getJWorkingDateTable()); } return jWorkingDateScrollPane; } COM: <s> this method initializes j working date scroll pane </s>
funcom_train/5081297
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void paintFigure(Graphics g) { RectD2D r = getBounds(); r.shrink(1, 1); try { g.setBackgroundColor(getFillColor()); g.fillRectangle(r.x, r.y, r.width, r.height); g.setForegroundColor(getBorderColor()); g.drawRectangle(r.x, r.y, r.width, r.height); } finally { //We don't really own rect 'r', so fix it. r.expand(1, 1); } } COM: <s> draws the handle with fill color and outline color dependent </s>
funcom_train/11102568
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void attributeReplaced(ServletRequestAttributeEvent event) { Object value = event.getValue(); if (value != null) { fireRequestDestroy(value); } value = event.getServletRequest().getAttribute(event.getName()); if (value != null) { fireRequestInit(value); } } COM: <s> p respond to a request scope attribute being replaced </s>
funcom_train/46092869
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public JFrame getJFrame() { if (jFrame == null) { jFrame = new JFrame(); jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); jFrame.setJMenuBar(getJJMenuBar()); jFrame.setSize(521, 289); jFrame.setContentPane(getJContentPane()); jFrame.setTitle("Imaging Trial Submitter - NOT GxP COMPLIANT"); } return jFrame; } COM: <s> this method initializes j frame </s>
funcom_train/36061961
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public DefinitionPolicySet getPolicySetForRule( int ruleID, int recordCount, int page, String searchText ) throws NoDatabaseConnectionException, SQLException{ Connection connection = null; connection = application.getDatabaseConnection( Application.DatabaseAccessType.SCANNER ); try{ return DefinitionPolicySet.getPolicySetForRule(connection, ruleID, recordCount, page, searchText); } finally { if (connection != null ) connection.close(); } } COM: <s> get the scan policy set for the given rule id </s>
funcom_train/36672140
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void readPage() { Page page = (Page) m_neighbour.read(); if (page != null) { // detect the last page if (page.getContent().contains("\1")) { if (m_exit == false) { write(page); System.out.println("\nTHIS IS THE LAST PAGE"); } m_EOF = true; } else { if (m_exit == false) { write(page); } } } else { System.out.println("not ready"); } } COM: <s> reads the next page from the pipeline and writes it to the specified </s>
funcom_train/35715829
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void removeListeners() { StyledText text= fTextViewer.getTextWidget(); if (text != null) { if (fKeyAndMouseListener != null) { text.removeMouseListener(fKeyAndMouseListener); text.removeKeyListener(fKeyAndMouseListener); fKeyAndMouseListener= null; } if (fTextInputListener != null) { fTextViewer.removeTextInputListener(fTextInputListener); fTextInputListener= null; } } } COM: <s> unregister all previously installed listeners from the text viewer </s>
funcom_train/23159950
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Edge addEdge(Node start, Node end, String edgeType) { synchronized (gc) { try { EdgeView view = ViewManager.getInstance().createEdgeView(edgeType); return addEdge(start, end, view); } catch (ViewManager.UnknownViewTypeException ex) { ViewerMain.showErrorDialog("No view type specified", ex); return null; } } } COM: <s> add a new edge </s>
funcom_train/50926819
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addCalculatedCoordinatesForHydrogens(CoordinateType type, double bondLength) { if (CoordinateType.TWOD.equals(type)) { calculateAndAddHydrogenCoordinates(bondLength); } else if (CoordinateType.CARTESIAN.equals(type)) { throw new RuntimeException("CARTESIAN H coords nyi"); } else { throw new RuntimeException("THREED H coords nyi"); } } COM: <s> add calculated coordinates for hydrogens </s>
funcom_train/9769484
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: @Test(expected=IllegalArgumentException.class) public void testConstructorSameType() { Combo[] combos = new Combo[] {this.bamboo_123, this.circle_555, this.wind_pair, this.character_222, this.circle_234}; new Scoreentry_ALL_SUITS_AND_HONORS(combos); } COM: <s> check if it fails if one type is doubled </s>
funcom_train/26454519
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void forward(String page) throws ServletException { String url = baseUrl + page; if (url.startsWith("//")) { url = url.substring(1); } try { context.getRequestDispatcher(url).forward(request, response); } catch (IOException e) { throw new ServletException("Cannot forward to page '" + url + "' : " + e.toString()); } } COM: <s> forward request to specified page under code base url code directory </s>
funcom_train/25587898
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void parseUnCheckout(WebDAVResponseEvent responseEvent) { try { int code = responseEvent.getResponse().getStatusCode(); if (code >= 200 && code < 300) fireUnCheckoutEvent(responseEvent.getResource(), code); else fireUnCheckoutEvent( responseEvent.getResponse().getReasonLine(), code); } catch (Exception e) { } } COM: <s> process the response to an uncheckout request </s>
funcom_train/13811715
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private ImportNormalizer getImportNormalizer(String ns, boolean ignoreCase) { ImportNormalizer n = inCache.get(ns); if (n == null) { String orig = ns; boolean hasWildcard = false; if (ns.endsWith(".*")) { hasWildcard = true; ns = ns.substring(0, ns.length() - 2); } n = new ImportNormalizer( QualifiedName.create(ns.split("\\.")), hasWildcard, ignoreCase); inCache.put(orig, n); } return n; } COM: <s> returns an import normalizer for the given namespace string </s>
funcom_train/35863781
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String createETag(net.sf.ehcache.Element ehcacheElement) { //For a given key and server this is unique, unless two updates for that key happened in the same millisecond. long eTagNumber = ehcacheElement.getCreationTime(); return new StringBuffer().append(eTagNumber).toString(); } COM: <s> a very performant etag implementation </s>
funcom_train/26476199
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void init( Class[] fSet, Class[] tSet, int[] argTypes ) throws ParametersNotProperlySetException { if (fSet.length==0) throw new ParametersNotProperlySetException("Void function set."); init( new ClassArray(fSet), new ClassArray(tSet), argTypes); } COM: <s> common initialization for the constructors </s>
funcom_train/48911034
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public ValueVector cloneInto(ValueVector vv) { if (m_ptr > vv.m_v.length) { vv.m_v = new Value[m_ptr]; } vv.m_ptr = m_ptr; System.arraycopy(m_v, 0, vv.m_v, 0, m_ptr); return vv; } COM: <s> make the parameter into a copy of this value vector </s>
funcom_train/39069673
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void loadPersistentHistory(){ int tasksAdded = 0; for(int i = MylarPlugin.getContextManager().getActivityHistory().getInteractionHistory().size() - 1; i >=0; i--){ ITask prevTask = getHistoryTaskAt(i); if (prevTask != null && !isDuplicate(prevTask, i + 1)) { history.add(0, prevTask); currentIndex++; tasksAdded++; if (tasksAdded == PERSISTENT_HISTORY_SIZE){ break; } } } } COM: <s> load in a number of saved history tasks from previous session </s>
funcom_train/3835033
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getJPanelSub() { if (jPanelSub == null) { jPanelSub = new JPanel(); jPanelSub.setLayout(null); jPanelSub.setBounds(new java.awt.Rectangle(15, 14, 322, 185)); jPanelSub.add(getJButtonLoad(), null); jPanelSub.add(getJButtonCreateStructFromQList(), null); jPanelSub.add(getJButtonCreateAndLoad(), null); } return jPanelSub; } COM: <s> this method initializes j panel sub </s>
funcom_train/44160799
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addValue(String legendEntryName, String value) { ArrayList alTmp = (ArrayList) legendMap.get(legendEntryName); if (null != alTmp) { alTmp.add(value); } else { alTmp = new ArrayList(); alTmp.add(value); legendMap.put(legendEntryName, alTmp); } } COM: <s> add value to the legend map </s>
funcom_train/21022302
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void increaseKeywordRate(String keyword, boolean add) { if (keywordTableMap.containsKey(keyword)) { int row = Integer.valueOf(keywordTableMap.get(keyword)); int value = Integer.valueOf(table.getHTML(row, 1)) + 1; table.setHTML(row, 1, ""+value); } else if (add) { GWTKeyword key = new GWTKeyword(); key.setFrequency(1); key.setKeyword(keyword); key.setTop10(false); add(key); } } COM: <s> increase the keyword rate with one </s>
funcom_train/25881269
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected Node createTestTeapot() { Node teapotAffectedNode = new Node("Affected Teapot Node"); Teapot tp = new Teapot("ShinyTeapot"); tp.setLocalScale(10f); // rotate our teapot so its base sits on the marker Quaternion q = new Quaternion(); q = q.fromAngleAxis(-FastMath.PI / 2, new Vector3f(1f, 0f, 0f)); tp.setLocalRotation(q); teapotAffectedNode.attachChild(tp); return teapotAffectedNode; } COM: <s> utility method allowing fast creation of a default teapot attached to </s>
funcom_train/49757209
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void removeLinkListener(UPBLinkListenerI theListener, UPBLinkI forLink) { synchronized(linkListenerList) { for (QualifiedLinkListener linkListener: linkListenerList) { if (linkListener.theListener != theListener) continue; if (linkListener.theLink != forLink) continue; // Remove Listener linkListenerList.remove(linkListener); linkListener.releaseResources(); return; } } } COM: <s> remove a previously added link listener for a passed link </s>
funcom_train/45540124
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public List readProfilesFromFile(File file) throws CoreException { try { final FileInputStream reader= new FileInputStream(file); try { return readProfilesFromStream(new InputSource(reader)); } finally { try { reader.close(); } catch (IOException e) { /* ignore */ } } } catch (IOException e) { throw createException(e, FormatterMessages.CodingStyleConfigurationBlock_error_reading_xml_message); } } COM: <s> read the available profiles from the internal xml file and return them </s>
funcom_train/8367144
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetQuantity() { System.out.println("setQuantity"); int idx = 3; StoreItem item = new StoreItem(null,5); Store instance = new Store() {}; instance.setStoreSize(5); instance.addItem(idx, item); assertEquals(instance.getStoreItem(idx),item); assertEquals(instance.getStoreItem(idx).getQuantity(),5); } COM: <s> test of set quantity method of class store </s>
funcom_train/22395294
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public IdentityConfig getIdentityConfigByUniqueId(long uniqueId) { int size = getNumIdentities(); for(int i=0; i<size; i++) { IdentityConfig tmpConfig = getIdentityConfig(i); if(tmpConfig.getUniqueId() == uniqueId) { return tmpConfig; } } return null; } COM: <s> gets the identity configuration by unique id </s>
funcom_train/268347
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isCaseSensitive(int column) throws java.sql.SQLException { int sqlType = getField(column).getSQLType(); switch (sqlType) { case Types.BIT: case Types.TINYINT: case Types.SMALLINT: case Types.INTEGER: case Types.BIGINT: case Types.FLOAT: case Types.REAL: case Types.DOUBLE: case Types.DATE: case Types.TIME: case Types.TIMESTAMP: return false; default: return true; } } COM: <s> does a columns case matter assumption any field that is </s>
funcom_train/6332947
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void handleValueStartElement(Attributes atts) { String ref = atts.getValue(ATTR_REF); if (ref != null) { Object refObj = objCache.get(ref); stack.push(new RefElement(refObj)); return; } ValueElement ve = new ValueElement(atts); stack.push(ve); } COM: <s> the method handle value start element creates a value element </s>
funcom_train/8461968
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setSelectedItem(MusicElement elmnt) { JScoreElement r = null; if (elmnt!=null) //r = (JScoreElementAbstract)m_jTune.getRenditionObjectsMapping().get(elmnt); r = m_jTune.getRenditionObjectFor(elmnt); //if (r!=null) // System.out.println("Selecting item " + elmnt + "->" + r + "@" + r.getBase()); setSelectedItem(r); } COM: <s> highlights the given score element in the score </s>
funcom_train/42284476
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public DiagramEditPart openDiagram(Diagram diagram) throws PartInitException { IEditorInput editorInput = new DiagramEditor.Input(diagram); DiagramEditor editor = (DiagramEditor)getSite().getPage().openEditor(editorInput, DiagramEditor.ID); return editor.getDiagramPart(); } COM: <s> open an already stored diagram in an editor </s>
funcom_train/29806647
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public DBSubset getAddresses(JDCConnection oConn) throws SQLException { Object aUser[] = { get(DB.gu_user) }; oAddresses = new DBSubset(DB.k_x_addr_user,DB.gu_address + "," + DB.ix_address + "," + DB.tp_location, DB.gu_user + "=?",10); oAddresses.load (oConn, aUser); return oAddresses; } COM: <s> p get addresses associated with user at k x addr user table </s>
funcom_train/22202247
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean supportsAbstraction(TopicMapObject tmo, AbstractionContext ac) { if (tmo == null) { return false; // cf. added nullpointer-check 30-09-2002 } //Ask CompactAssocAbstractor if (caa.supportsAbstraction(tmo, ac)) { return true; } if (tmo instanceof Topic) { return true; } else if (tmo instanceof Occurrence) { return ((Occurrence) tmo).getParent() != null; } else { return false; } } COM: <s> currently the compact abstractor supports model generation for topics </s>
funcom_train/35612609
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Widget setupCell(Direction direction) { final FocusPanel widget = new FocusPanel(); widget.setPixelSize(BORDER_THICKNESS, BORDER_THICKNESS); grid.setWidget(direction.getY(), direction.getX(), widget); grid.getCellFormatter().addStyleName(direction.getY(), direction.getX(), direction.getStyle()); return widget; } COM: <s> sets up a boundary cell </s>
funcom_train/25639750
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void summaryTableHeader(String[] header, String scope) { tr(); for ( int i=0; i < header.length; i++ ) { thScopeNoWrap("TableHeader", scope); print(header[i]); thEnd(); } trEnd(); } COM: <s> print summary table header </s>
funcom_train/5391992
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setPool(KeyedObjectPool pool) throws IllegalStateException, NullPointerException { if(null != this.pool) { throw new IllegalStateException("Pool already set"); } else if(null == pool) { throw new NullPointerException("Pool must not be null."); } else { this.pool = pool; } } COM: <s> set the keyed object pool used in this datasource </s>
funcom_train/27776568
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void info(Object msg, Throwable t) { synchronized (msgQuene) { msgQuene.add( new MsgNode("[Info-" + name + "] " + msg.toString(), t)); //msgThread.notify(); msgQuene.notifyAll(); } } COM: <s> log general info </s>
funcom_train/13969582
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void fireAttachmentRemovedRCEvent (Incident incident, Attachment attachment) { AttachmentEvent event = new AttachmentEvent(incident, attachment); for (Iterator listeners = Arrays.asList(getIncidentChangeListeners()).iterator(); listeners.hasNext();) { ((IncidentChangeListener)listeners.next()).performAttachmentRemovedEvent(event); } } COM: <s> fires an event that informs all listeners about an removed attachment </s>
funcom_train/291338
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String getRenderedViewId() { if (Init.instance().isJbpmInstalled() && Pageflow.instance().isInProcess()) { return Pageflow.instance().getPageViewId(); } else { // TODO: not working right now, 'cos no mock navigation handler! return getFacesContext().getViewRoot().getViewId(); } } COM: <s> get the view id to be rendered </s>
funcom_train/51591396
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Object getValueAt(int rowIndex, int columnIndex) { Object result = null; Row r = null; if ( rowIndex >= 0 && rowIndex < this.getRowCount() ) { r = this.getRowAt(rowIndex); } if ( r != null ) { result = r.getValueAt(columnIndex); } return result; } COM: <s> returns the value for the cell at code column index code and </s>
funcom_train/3472822
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void stateChanged(ChangeEvent event) { if (listenToChangeEvents) { listenToSessionList = false; cleverPHL.getSessionList().setCurrent(getSelectedIndex()); listenToSessionList = true; RecordPanel currentPanel = getCurrentRecordPanel(); if (currentPanel != null) { currentPanel.updateMenuItems(); } } } COM: <s> invoked when the state of the tabbed pane has changed </s>
funcom_train/3082457
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void throwTPE(int lineNo, String token, String message) throws CssStyleSheetException { if (input != null) { try { input.close(); } catch (IOException ieo) {} } input = null; String msg = "CSS stylesheet parse failure : " + message; if (token != null || token.length() > 0) msg += " instead found '" + token + "' line : " + lineNo; throw new CssStyleSheetException(msg, null, lineNo); } COM: <s> internal function to throw a formatted style sheet exception </s>
funcom_train/45485815
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JButton getJButton11Add() { if (jButton11Add == null) { jButton11Add = new JButton(); jButton11Add.setBounds(new Rectangle(5, 279, 64, 26)); Font font = new Font("Serif", Font.BOLD, 16); jButton11Add.setFont(font); jButton11Add.setForeground(Color.green); jButton11Add.setText("11"); } return jButton11Add; } COM: <s> this method initializes j button11 add </s>
funcom_train/3730746
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public StmtRegistry (JXClassLoader jxcl) { super(jxcl); //INSTANCE = this; // XXX the horror ClassAction classAct = new ClassAction(this); cxf = new ClassXformer[] { classAct }; mxf = new MethodXformer[] { new MethodAction(this) }; gxf = new GraphXformer[] { new GraphAction(this, classAct) }; setTransformers(); } COM: <s> constructor specifying ucovered class loader the registry is </s>
funcom_train/9927517
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String isNullChecker(String whatsit, String value) throws Exception { if (value == null) { throw new Exception("PropertyLoader.isNullChecker() - '" + whatsit + "' is null! Check that "+this.propFile+" contains '"+whatsit+"'!"); } else { } return value; } COM: <s> checks if value is not null </s>
funcom_train/7294269
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void TestScriptSet() { expectContainment("[:Latin:]", "aA", CharsToUnicodeString("\\u0391\\u03B1")); expectContainment("[:Greek:]", CharsToUnicodeString("\\u0391\\u03B1"), "aA"); /* Jitterbug 1423 */ expectContainment("[[:Common:][:Inherited:]]", CharsToUnicodeString("\\U00003099\\U0001D169\\u0000"), "aA"); } COM: <s> test the latin syntax </s>
funcom_train/34333357
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void storeOwner(Owner owner) throws DataAccessException { // Note: TopLink's merge operation does not reassociate the object with the // current TopLink Session. Instead, it will always copy the state over to // a registered representation of the entity. In case of a new entity, it will // register a copy as well, but will also update the id of the passed-in object. getTopLinkTemplate().deepMerge(owner); } COM: <s> merge the given owner object into the current unit of work </s>
funcom_train/5402749
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Collection getBundleEntries(String key) { Collection entries = new ArrayList(); for (Iterator iter = bundles.keySet().iterator(); iter.hasNext();) { Locale locale = (Locale) iter.next(); BundleEntry entry = getBundleEntry(locale, key); if (entry != null) { entries.add(entry); } } return entries; } COM: <s> gets bundle entries matching given key from all bundles </s>
funcom_train/25701708
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setLocation(String url) { super.setLocation(url); // Get the X3D Scene mainScene = super.getX3DScene(); // Load the prototypes into the scene loadPrototypes (mainScene, prototypeWorld); String [] protosNames = mainScene.getProtosNames(); for (int i =0; i < protosNames.length; i++) System.out.println(protosNames[i]); } COM: <s> set the location </s>
funcom_train/7675171
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int compareTo(Entry other) { if (address < other.address) { return -1; } else if (address > other.address) { return 1; } boolean thisIsStart = isStart(); boolean otherIsStart = other.isStart(); if (thisIsStart != otherIsStart) { return thisIsStart ? 1 : -1; } return spec.compareTo(other.spec); } COM: <s> compares by in priority order address end then start </s>
funcom_train/47490910
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Command getExitApplicationCommand() { if (exitApplicationCommand == null) {//GEN-END:|30-getter|0|30-preInit // write pre-init user code here exitApplicationCommand = new Command("Salir", Command.ITEM, 0);//GEN-LINE:|30-getter|1|30-postInit // write post-init user code here }//GEN-BEGIN:|30-getter|2| return exitApplicationCommand; } COM: <s> returns an initiliazed instance of exit application command component </s>
funcom_train/49890088
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Builder setProxy(final String hostName, final int port) { if (hostName == null || hostName.length() == 0) { throw(new IllegalArgumentException( "Proxy host name cannot be null or empty")); } if (port <= 0) { throw(new IllegalArgumentException( "Proxy port must be > 0")); } bProxyHost = hostName; bProxyPort = port; return this; } COM: <s> specify the hostname and port of an http proxy to connect through </s>
funcom_train/32061797
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetSize() { System.out.println("getSize"); IntPoint2D containersize = newIP(10, 100); ContainerView instance = ContainerView.createNewWithFlow("cv", Right, Down, 0, containersize); IntPoint2D result = instance.getSize(); assertEquals(containersize, result); } COM: <s> test of get size method of class container view </s>
funcom_train/12562546
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public MIDletProxy findAmsProxy() { if (null == amsProxy) { for (int i = midletProxies.size() - 1; i >= 0; i--) { MIDletProxy current = (MIDletProxy)midletProxies.elementAt(i); if (current.getIsolateId() == MIDletSuiteUtils.getAmsIsolateId()) { amsProxy = current; break; } } } return amsProxy; } COM: <s> retireves proxy whose peer application runs in the ams isolate </s>
funcom_train/22105483
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getTitle() { if (isLocalizedTitle) { Locale userLocale = RequestUtils.getUserLocale( (HttpServletRequest) pageContext.getRequest(), null); try { return TagUtils.getInstance().message(pageContext, null, userLocale.toString(), super.getTitle()); } catch (JspException e) { // Do not localize then } } return super.getTitle(); } COM: <s> internationalize the title </s>