__key__
stringlengths
16
21
__url__
stringclasses
1 value
txt
stringlengths
183
1.2k
funcom_train/20295042
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getRefreshTag(String tmp, ServletRequest request) { String linkRefreshParameter = (String) request.getAttribute(REFRESH_PARAMETER); return ("<a href=\"" + link + (linkRefreshParameter != null ? linkRefreshParameter : "") + "\">" + tmp + "</a>"); } COM: <s> gets the refresh tag attribute of the paged list info object </s>
funcom_train/1068872
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void changeFigureToStereotypeFigure() { if ( ((figure instanceof IconFigure) && !getGraphNode().getSemanticModel().getPresentation().equals(ModelerHelper.IMAGE_STEREOTYPE_PRESENTATION)) || ((!(figure instanceof IconFigure)) && getGraphNode().getSemanticModel().getPresentation().equals(ModelerHelper.IMAGE_STEREOTYPE_PRESENTATION))) { changeEditPartFigure(); } } COM: <s> change figure to stereotype figure </s>
funcom_train/50937780
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public List getAllAfters(String breakName) { Copy parent = getParentCopy(); List result = new ArrayList(); AddAfter add = (AddAfter) getMatch(addAfter,breakName); if (add != null) result.add(add); if (parent != null) result.addAll(parent.getAllAfters(breakName)); return result; } COM: <s> get a list of all additions to be inserted after the given breakpoint </s>
funcom_train/44283410
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String getPatchName(Patch p) { char c[] = new char[patchNameSize]; for (int i = 0; i < patchNameSize; i++) { c[i] = (char)PatchBytes.getSysexByte(p.sysex, Constants.PDMP_HDR_SIZE, Constants.PDMP_HDR_SIZE + i + nameStart); } return new String(c); } COM: <s> gets the name of the program patch </s>
funcom_train/802632
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addFloatPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_SupDataType_float_feature"), getString("_UI_PropertyDescriptor_description", "_UI_SupDataType_float_feature", "_UI_SupDataType_type"), MzdataPackage.Literals.SUP_DATA_TYPE__FLOAT, true, false, false, ItemPropertyDescriptor.REAL_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the float feature </s>
funcom_train/10666503
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Result testInvalidKey() throws Exception { TabularData tabularData = getTabularData(); try { tabularData.get(new Object[] { CompositeDataSupportTest .getCompositeData().get(indexNames[0]) }); assertTrue(false); } catch (InvalidKeyException e) { } return result(); } COM: <s> verify that get values of elements which is not index names method of </s>
funcom_train/8477398
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int read() throws IOException { while (true){ synchronized (CircularByteBuffer.this){ if (inputStreamClosed) throw new IOException("InputStream has been closed; cannot read from a closed InputStream."); int available = CircularByteBuffer.this.available(); if (available > 0){ int result = buffer[readPosition] & 0xff; readPosition++; if (readPosition == buffer.length){ readPosition = 0; } ensureMark(); return result; } else if (outputStreamClosed){ return -1; } } try { Thread.sleep(100); } catch(Exception x){ throw new IOException("Blocking read operation interrupted."); } } } COM: <s> read a single byte </s>
funcom_train/25011096
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void drawCenterTop(final GL2 gl, final int startX) { if (listMap.get(GemfireBorderSprite.CENTER_TOP) != null) { gl.glPushMatrix(); gl.glColor4fv(super.getColor()); // move to bottom-left corner of sprite double y = super.getPosition().getY(); y += super.getHeight(); y -= imageInsets.top; gl.glTranslated( startX, y, 0d ); gl.glCallList(listMap.get(GemfireBorderSprite.CENTER_TOP)); gl.glPopMatrix(); } } COM: <s> renders the center top piece </s>
funcom_train/18734402
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean arg0HoldsThis() { if (getKind().isEnclosingKind()) { return !getSignature().isStatic(); } else if (enclosingShadow == null) { // XXX this is mostly right // this doesn't do the right thing for calls in the pre part of introduced constructors. return !enclosingMethod.isStatic(); } else { return ((BcelShadow) enclosingShadow).arg0HoldsThis(); } } COM: <s> is arg0 occupied with the value of this </s>
funcom_train/38290123
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void deleteContents(boolean deleteEmptyNode) { for (int i = intervals.size() - 1; i >= 0; i--) { final DOMInterval interval = intervals.get(i); interval.deleteContents(deleteEmptyNode); } for (int i = attrIntervals.size() - 1; i >= 0; i--) { final DOMInterval interval = attrIntervals.get(i); interval.deleteContents(deleteEmptyNode); } } COM: <s> the delete operation </s>
funcom_train/7613771
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setInput(Object input, boolean seekForwardOnly, boolean ignoreMetadata) { if (input != null) { if (!isSupported(input) && !(input instanceof ImageInputStream)) { throw new IllegalArgumentException("input " + input + " is not supported"); } } this.minIndex = 0; this.seekForwardOnly = seekForwardOnly; this.ignoreMetadata = ignoreMetadata; this.input = input; } COM: <s> sets the specified object as the input source of this image reader </s>
funcom_train/9984849
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void initToggleStatus() { try { IWorkspaceRoot wsRoot = ResourcesPlugin.getWorkspace().getRoot(); String statusStr = wsRoot.getPersistentProperty( new QualifiedName( PalamedesUI.PLUGIN_ID, id ) ); toggleStatus = Boolean.valueOf(statusStr); } catch (CoreException exp) { } } COM: <s> retrieving the status out of the persistent properties </s>
funcom_train/51620803
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void updateState() { super.updateState(); //All of the conditions in the super class passed //now check for the menu. if (isEnabled()) { PartPane pane = (((PartSite) getActivePart().getSite()).getPane()); setEnabled((pane instanceof ViewPane) && ((ViewPane) pane).hasViewMenu()); } } COM: <s> updates the enabled state </s>
funcom_train/2325412
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public FloatMatrix2D xpowSlow(FloatMatrix2D A, int k) { // cern.colt.Timer timer = new cern.colt.Timer().start(); FloatMatrix2D result = A.copy(); for (int i = 0; i < k - 1; i++) { result = mult(result, A); } // timer.stop().display(); return result; } COM: <s> linear algebraic matrix power </s>
funcom_train/7636607
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void drawWorldRound(GL10 gl) { gl.glDisable(GL10.GL_BLEND); gl.glEnable(GL10.GL_DITHER); gl.glShadeModel(mSmoothShading ? GL10.GL_SMOOTH : GL10.GL_FLAT); mWorld.draw(gl); mNumTriangles += mWorld.getNumTriangles(); } COM: <s> draws the world in a 2 d round view </s>
funcom_train/40359700
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetDocumentContentDocumentNotFound() throws Exception { instantiator.addConnector(connectorName, new MockConnector(null, null, null, new MockRetriever())); try { manager.getDocumentContent(connectorName, MockRetriever.DOCID_NOT_FOUND); fail("Expected RepositoryDocumentException"); } catch (RepositoryDocumentException expected) { // Expected. } } COM: <s> test get document content with document not found </s>
funcom_train/28224622
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void paintControl(final PaintEvent e) { Image baseImg = new Image(Display.getCurrent(), painter.getBounds()); GC gcAux = new GC(baseImg); painter.paintBackground(gcAux); painter.paintPeople(gcAux); synchronized (markers) { painter.paintMarkers(gcAux, markers); } control.setDrawingCondluded(); gcAux.dispose(); e.gc.drawImage(baseImg, 0, 0); baseImg.dispose(); } COM: <s> draws the canvas that represents the simulation </s>
funcom_train/42476880
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void recalculateWidth() { int nameWidth = GUIFactory.getStringWidth(lblName, member.getName()); nameWidth += PADDING * 2; int graphicWidth = ICON_WIDTH + Math.max(attackMeter.getPreferredSize().width, healthbar.getPreferredSize().width); graphicWidth += PADDING * 2; totalWidth = Math.max(nameWidth, graphicWidth); } COM: <s> recalculates the labels width </s>
funcom_train/11739771
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void prepareGenerator() { try { DbAdapter adapter = connectionInfo.makeAdapter(getApplication() .getClassLoadingService()); this.generator = new DbGenerator(adapter, dataMap, tables.getExcludedTables()); } catch (Exception ex) { reportError("Error loading adapter", ex); } } COM: <s> creates new internal db generator instance </s>
funcom_train/44588784
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void copyResources(IResource[] resources, IPath destinationPath) throws JavaModelException { IProgressMonitor subProgressMonitor = getSubProgressMonitor(resources.length); IWorkspace workspace = resources[0].getWorkspace(); try { workspace.copy(resources, destinationPath, false, subProgressMonitor); setAttribute(HAS_MODIFIED_RESOURCE_ATTR, TRUE); } catch (CoreException e) { throw new JavaModelException(e); } } COM: <s> convenience method to copy resources </s>
funcom_train/2584884
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSetNullRenderer() { boolean failed = false; try { XYPlot plot = new XYPlot(null, new NumberAxis("X"), new NumberAxis("Y"), null); plot.setRenderer(null); } catch (Exception e) { failed = true; } assertTrue(!failed); } COM: <s> setting a null renderer should be allowed but is generating a null </s>
funcom_train/21942335
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Field74 getField74() { if (getSwiftMessage() == null) { throw new IllegalStateException("SwiftMessage was not initialized"); } if (getSwiftMessage().getBlock4() == null) { log.info("block4 is null"); return null; } else { final Tag t = getSwiftMessage().getBlock4().getTagByName("74"); if (t == null) { log.fine("field 74 not found"); return null; } else { return new Field74(t.getValue()); } } } COM: <s> iterates through block4 fields and return the first one whose name matches 74 </s>
funcom_train/51591797
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void removeClient(ClientDTO client) { if (clients.containsKey(client.getSource())) { Client c = (Client) clients.get(client.getSource()); c.delete(); clients.remove(client.getSource()); XMLManager.getInstance().deleteClient(client); } } COM: <s> notification that client was removed </s>
funcom_train/15637065
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JPanel getJContentPane() { if (jContentPane == null) { jLabel = new JLabel(); jLabel.setText(""); jLabel.setIcon(new ImageIcon(getClass().getResource("/biblePackage/splashscreen.png"))); jContentPane = new JPanel(); jContentPane.setLayout(new BorderLayout()); jContentPane.add(jLabel, java.awt.BorderLayout.EAST); } return jContentPane; } COM: <s> this method initializes j content pane </s>
funcom_train/8009697
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void generateHtmlForBand(Vector components, PrintWriter p, String rowBgColor, String rowStyle, int maxSize, boolean clickSort, int startRow, int endRow, String cellType) throws Exception { generateHtmlForBand(components, p, rowBgColor, rowStyle, maxSize, clickSort, startRow, endRow, cellType, false); } COM: <s> author bruno y </s>
funcom_train/7615441
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean equals(FontRenderContext frc) { if (this == frc){ return true; } if (frc == null){ return false; } if (!frc.getTransform().equals(this.getTransform()) && !frc.isAntiAliased() == this.fAntiAliased && !frc.usesFractionalMetrics() == this.fFractionalMetrics){ return false; } return true; } COM: <s> compares the specified font render context object with current </s>
funcom_train/39912916
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetRh13() { System.out.println("getRh13"); Page1 instance = new Page1(); TextField expResult = null; TextField result = instance.getRh13(); assertEquals(expResult, result); // TODO review the generated test code and remove the default call to fail. fail("The test case is a prototype."); } COM: <s> test of get rh13 method of class timesheetmanagement </s>
funcom_train/3108402
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int getPageForRow(int row) throws IloaException { if (this.rowsPerPage <= 0) { return 0; } if (row < 0 || row >= this.getRowCount()) { throw new IloaException("The number of the row is out of range for the datastore '" + this.getType() + "'"); } return (new Double(Math.ceil(row / this.rowsPerPage))).intValue(); } COM: <s> return the number of page for the row of the datastore </s>
funcom_train/45740232
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean execute() throws SQLException { //execute query boolean results; try { results = (Boolean) executeVerboseQuery("execute", null); } catch (Exception e) { logger.error(e.getMessage(), e); throw new SQLException("Could not execute sql command - Original message: " + e.getMessage(),e); } return results; } COM: <s> executes query and calculates query execution time </s>
funcom_train/16558607
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testSymbolForSelection() { for (int i = 0; i < symbols.length; i++) { assertNotNull("Symbol no. "+i+" '"+getNameForSymbol(symbols[i])+" does not define any derived symbol for selection", symbols[i].getSymbolForSelection()); } } COM: <s> ensures that any symbol provides a version of itself to use when the </s>
funcom_train/14373444
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void updateBoundLeftEchelon(SplitLine line) { if (line.getLeftChild() == null ) return; if (line.getLeftChild().getRightChild() == null) return; SplitLine current = line.getLeftChild().getRightChild(); while (current != null) { current.setOpBound(line); current = current.getRightChild(); // Descend right down the echelon to the LEFT of line } } COM: <s> repair left subtree following a delete </s>
funcom_train/15919273
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public If createIf(Position pos, Expr cond, Stmt thenStmt, Stmt elseStmt) { if (null == elseStmt) return nf.If(pos, cond, thenStmt); return nf.If(pos, cond, thenStmt, elseStmt); } COM: <s> create a conditional statements </s>
funcom_train/29682490
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean equals(LLRPType other) { SignedShortArray ba = (SignedShortArray) other; if (ba.size() != (this.size())) { return false; } for (int i = 0; i < shorts.length; i++) { if (!ba.get(i).equals(this.get(i))) { return false; } } return true; } COM: <s> compare each element </s>
funcom_train/24137485
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean setActiveItem(final int activeItemIndex) { final T oldActiveItem = activeItem; if (validIndex(activeItemIndex)) { activeItem = items.get(activeItemIndex); } else { activeItem = null; } if (oldActiveItem == activeItem) { return false; } if (oldActiveItem != null && oldActiveItem.equals(activeItem)) { return false; } return true; } COM: <s> changes the active item </s>
funcom_train/15454089
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public ContactGroup getGeneralGroup() { ContactGroup result = null; Iterator iterator = myContactGroups.iterator(); while (iterator.hasNext()) { ContactGroup contactGroup = (ContactGroup) iterator.next(); if (contactGroup.isGeneralGroup()) { result = contactGroup; } } return result; } COM: <s> returns the user general group </s>
funcom_train/24118290
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void doViewInFullScreen(Event event) { final Borderlayout bl = ((Borderlayout) Path.getComponent("/outerIndexWindow/borderlayoutMain")); final West west = bl.getWest(); if (west != null) { try { if (west.isOpen()) { west.setOpen(false); } else west.setOpen(true); } catch (Exception e) { // TODO: handle exception e.printStackTrace(); } } } COM: <s> changes the view for full width screen mode by collapsing the west </s>
funcom_train/5230034
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public _08InPacket parseIn(int supportedFamily, ByteBuffer buf, QQUser user, boolean debug) throws PacketParseException { if (!findParser(supportedFamily, buf)) return null; return parseIn(buf, parser.getLength(buf), user, debug); } COM: <s> byte buffer in packet buf limit </s>
funcom_train/42392222
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void cleanStaticReferences(String className) { if (isSystemClass(className)) { return; } Class<?> type = null; try { type = loadRobotClassLocaly(className, false); } catch (Throwable t) { return; } if (type != null) { for (Field field : getAllFields(new ArrayList<Field>(), type)) { if (isStaticReference(field)) { cleanStaticReference(field); } } } } COM: <s> cleans all static field references on a class </s>
funcom_train/21112079
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Subject getCreds(Principal subject, String [] urls, issrg.pba.AuthTokenParser authParser) throws PbaException { issrg.pba.repository.AuthTokenRepository repository; repository = new issrg.simplePERMIS.SimplePERMISAuthTokenRepository(this.getRepositories(urls),authParser); return getCreds(new UserEntry(subject), null, repository, null ); } COM: <s> this method returns the credentials of the subject given the subject principal </s>
funcom_train/45109070
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void checkIsRepeatSet(boolean status) throws Exception { Vector<Object> v = new Vector<Object>(); v.addElement(status); boolean selected = (Boolean) handleXmlCommand("check repeat status", "jsystem.checkIsRepeatSet", v); if (selected != status) { report.report("repeate checkbox is not in the expected state", false); throw new Exception("repeate checkbox is not in the expected state"); } } COM: <s> check if staus of repeat check box equals to status </s>
funcom_train/20766669
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public StereoClusterTracker (AEChip chip){ super (chip); if ( chip != null && chip instanceof StereoChipInterface ){ this.stereoChip = (StereoChipInterface)chip; } else{ log.warning ("AEChip " + chip + " is not StereoChipInterface"); } setEnclosedFilter (new StereoTranslateRotate (chip)); geom = new StereoGeometry (chip); } COM: <s> creates a new instance of stereo cluster tracker </s>
funcom_train/26657834
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void sendJMXNotification(SendMailMessageStatus msg) { long eventID = super.getNextNotificationSequenceNumber(); Notification notif = new Notification(msg.getClass().getName(), this, eventID); notif.setUserData(msg); super.sendNotification(notif); } COM: <s> fire a send mail message status jmx notification </s>
funcom_train/31357416
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void write(String command) throws Exception { // Variables int len; char b[]; // Convert Command to byte stream len = command.length(); b = new char[len]; command.getChars(0, len, b, 0); // write command to the engine if (bufferedWrites == true) { toEngine.write(b, 0, b.length); } else { for (int i = 0; i < b.length; i++) { toEngine.write(b[i]); } } toEngine.flush(); } // write() COM: <s> writes a string to the engine </s>
funcom_train/8716273
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String toString() { StringBuffer buf = new StringBuffer(); String indent = " "; buf.append(indent + "Glyf Table: (" + glyphs.length + " glyphs)\n"); buf.append(indent + " Glyf 0: " + getGlyph(0)); return buf.toString(); } COM: <s> create a pretty string </s>
funcom_train/25273490
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private int searchMatrixRow(final int findWhat, final int row) { int result = SEARCH_FAILED; if (row < getHeight()) { final int width = getWidth(); for (int column = 0; column < width; column++) { if (getElement(row, column) == findWhat) { if (result == SEARCH_FAILED) { // findWhat was not found before in this row. result = column; } else { // findWhat was already found in this row. result = SEARCH_FAILED; break; } } } } return result; } COM: <s> looks for a specified value in the specified row of this matrix </s>
funcom_train/49262552
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void setForeground() { EditorsPreference fontPreference = EditorsPreference.getInstance(); int[] rgb = fontPreference.getEditorTextFont().getRgb(); RGB foreGroundRgb = new RGB(rgb[0], rgb[1], rgb[2]); Color foreGround = new Color(textControl.getDisplay(), foreGroundRgb); textControl.setForeground(foreGround); } COM: <s> defines foreground color stored in code font preference code object </s>
funcom_train/48526810
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected String unmark() { try { if (this.marked != null) { this.marked.append(buffer, 0, bufferPosition); return cache.get(marked.getBuffer(), 0, marked.getLength()); } else { return cache.get(buffer, mark, bufferPosition-mark); } } finally { this.mark = -1; this.marked = null; } } COM: <s> unsets the mark </s>
funcom_train/1719730
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isConstantField(PsiField field) { PsiModifierList list = field.getModifierList(); if (list == null) { return false; } // modifier must be static if (!list.hasModifierProperty(PsiModifier.STATIC)) { return false; } // name must NOT have any lowercase character return !StringUtil.hasLowerCaseChar(field.getName()); } COM: <s> returns true if a field is constant </s>
funcom_train/24505927
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Color get(int i, int j) { if (this.isOriginUpperLeft) { return new Color(this.image.getRGB(i, j)); } else { return new Color(this.image.getRGB(i, this.height - j - 1)); } } COM: <s> return the color of pixel i j </s>
funcom_train/50925757
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void addCalculatedCoordinatesForHydrogens(CoordinateType type, HydrogenControl control) { if (type.equals(CoordinateType.CARTESIAN)) { addCalculated3DCoordinatesForHydrogens(control); } else if (type.equals(CoordinateType.TWOD)) { addCalculated2DCoordinatesForHydrogens(control); } else { throw new RuntimeException( "Add calculated coordinates for hydrogens: control not recognised: " + type); //$NON-NLS-1$ } } COM: <s> add calculated coordinates for hydrogen atoms </s>
funcom_train/18807344
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public ChartEntity getEntity(double x, double y) { ChartEntity result = null; Iterator iterator = this.entities.iterator(); while (iterator.hasNext()) { ChartEntity entity = (ChartEntity) iterator.next(); if (entity.getArea().contains(x, y)) { result = entity; } } return result; } COM: <s> returns an entity for the specified coordinates </s>
funcom_train/12639292
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public DSAParams getParams() { try { if (algid instanceof DSAParams) { return (DSAParams)algid; } else { DSAParameterSpec paramSpec; AlgorithmParameters algParams = algid.getParameters(); if (algParams == null) { return null; } paramSpec = (DSAParameterSpec)algParams.getParameterSpec (DSAParameterSpec.class); return (DSAParams)paramSpec; } } catch (InvalidParameterSpecException e) { return null; } } COM: <s> returns the dsa parameters associated with this key or null if the </s>
funcom_train/20691417
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testRemovePageFromRoomCache() { ObjectManager.current().startWrite(); try { PlainTextPage page = new PlainTextPage( "testRemovePageFromRoomCache"); getRoom().addPage(page); page.unload(); assertFalse("Page still loaded after an explicit unload request", ObjectManager.current().cachesObject(page.getID())); } finally { ObjectManager.current().endWrite(); } } COM: <s> method test remove page from room cache </s>
funcom_train/50389973
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void close() throws IOException { if (outputs_ == null) { throw new IOException("No internal output streams."); } byte[] tbuf = new byte[4]; if (PConfig.usethreads == true) { int i; // wake up all writers done_ = true; for (i = 0; i < writers_.length; i++) writers_[i].set(tbuf, 0, 0); } try { for (int i = 0; i < outputs_.length; i++) outputs_[i].close(); } catch (IOException e) { throw e; } } COM: <s> closes this output stream and releases any system resources associated </s>
funcom_train/12300899
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected void addBitLengthPropertyDescriptor(Object object) { itemPropertyDescriptors.add (createItemPropertyDescriptor (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_PortMappingType_bitLength_feature"), getString("_UI_PropertyDescriptor_description", "_UI_PortMappingType_bitLength_feature", "_UI_PortMappingType_type"), SchemaPackage.Literals.PORT_MAPPING_TYPE__BIT_LENGTH, true, false, false, ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE, null, null)); } COM: <s> this adds a property descriptor for the bit length feature </s>
funcom_train/34812821
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void pickPeaks(){ System.out.println("PickingPeaks"); //fetch data fetchData(); if (controlPointDirs == null) scoreTreatments(); else { //window score each EnrichedRegion scoreTreatmentsControls(); //calculate binomial p-values for each subwindow calculateSubWindowBinomialPValues(); //find and assign best peak for each EnrichedRegion findPeaks(); //add stats to best peak for whole ER calculateStatsForEnrichedRegions(); } } COM: <s> main method of class </s>
funcom_train/13969924
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean accept(File dir, String name) { File ticketCandidate = new File (dir.getAbsolutePath() + File.separator + name); return ticketCandidate.isDirectory() // isses ein verzeichnis? && new File(ticketCandidate.getAbsolutePath() + File.separator + "core.properties").exists(); // gibtsn core-file? } COM: <s> returns code true code when a directoy has been given that contains a </s>
funcom_train/1038923
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean detachOpenIDsByUser(int idUser){ // delete from user_openids where user_id = user_id Statement statement = null; int count = 0; try { statement = db.getStatement(); count = statement.executeUpdate("DELETE FROM user_openids WHERE " + "idUser='"+idUser+"';"); statement.close(); } catch (SQLException e) { e.printStackTrace(); } //TODO check openID was Attached return count > 0; } COM: <s> remove all openids </s>
funcom_train/18071387
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private JMenuItem getCloseABoxMenuItem() { if (closeABoxMenuItem == null) { closeABoxMenuItem = new JMenuItem(); closeABoxMenuItem.setText("Close ABox"); closeABoxMenuItem .addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent e) { closeABox(); } }); } return closeABoxMenuItem; } COM: <s> this method initializes close abox menu item </s>
funcom_train/39366302
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private int getExtentIndex(long position) { if( position > _maxFilePosition) throw new IllegalArgumentException("Position is not valid, " + position + " maxFilePosition = " + _maxFilePosition) ; if( position < 0) throw new IllegalArgumentException("Position is not valid, " + position ) ; int index = (int) (position/_extentSize) ; return index; } COM: <s> the position in the global virtual file is converted to the </s>
funcom_train/3000459
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void raiseEvent(Event evt, boolean priority) { if (priority) { eventQueue.addFirst(evt); } else { eventQueue.addLast(evt); } if (log.isDebugEnabled()) { log.debug("\n"+ "================================================\n"+ "EVENT IN\n"+ "================================================\n"+ " Widget Name: "+evt.getWidget().getName()+"\n"+ " Event Code: "+evt.getEventCode().name()+"\n"+ " Event Args: "+evt.getEventArguments()+"\n"+ "================================================" ); } } COM: <s> adds the specified event to the event queue </s>
funcom_train/20742954
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected AttachmentDO getLatestVersion(String pageName, String filename) { List<AttachmentDO> attachments = findAttachments(pageName, filename); if (attachments.size() > 0) { // pre-loading data is required - we need it to load contents - attachments.get(0).getDataAsByteArray(); return attachments.get(0); } else { return null; } } COM: <s> find latest version of attachment </s>
funcom_train/13674763
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getContactIDList() { String list = StringUtil.join(listContactIDs(), ","); //log.debug("List of ids=" + list); return list; //return StringUtil.joinList(listContactIDs()); }//getContactIDList COM: <s> used by castor to get list for persistence </s>
funcom_train/34085066
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void reset(ActionMapping mapping, HttpServletRequest request) { this.productid = null; this.categoryid = null; this.productname = null; this.productprice = null; this.listprice = null; this.theFile = null; this.imagename = null; this.quantity = null; this.description = null; this.briefdisc = null; this.action="add"; this.actionUpdateData=""; } COM: <s> reset all properties to their default values </s>
funcom_train/7471563
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public ModelAndView handlePdf(HttpServletRequest request, HttpServletResponse response) throws ServletException { RefreshablePagedListHolder listHolder = (RefreshablePagedListHolder) request.getSession(true).getAttribute( COUNTRIES_ATTR); if (listHolder == null) { throw new ServletException("No countries list found in session"); } return new ModelAndView(this.pdfView, "countries", listHolder); } COM: <s> custom handler for countries pdf document </s>
funcom_train/21346953
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public List getNotificationLogs(String startIndex,String recordsReturned,String sort,String dir,String nodeAddress,String opWebservice,String startDate, String endDate, String[] domainPermission,String version){ return dao.getNotificationLogs( startIndex, recordsReturned, sort, dir, nodeAddress, opWebservice, startDate, endDate,domainPermission, version); } COM: <s> get notification logs </s>
funcom_train/21644010
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void init() { theMixer = findMixer(properties.getOptionsSoundMixer()); panSupported = false; volSupported = false; Line.Info lineInfo = theMixer.getSourceLineInfo(new Line.Info(Clip.class))[0]; try { Line line = theMixer.getLine(lineInfo); volSupported = line.isControlSupported(FloatControl.Type.MASTER_GAIN); panSupported = line.isControlSupported(FloatControl.Type.PAN); } catch (LineUnavailableException e) {} } COM: <s> loads all required samples and performs all necessary setup </s>
funcom_train/20784497
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setUseWeightedOnOff(boolean useWeightedOnOff) { getPrefs().putBoolean("FilterLaserline.useWeightedOnOff", useWeightedOnOff); getSupport().firePropertyChange("useWeightedOnOff", this.useWeightedOnOff, useWeightedOnOff); this.useWeightedOnOff = useWeightedOnOff; } COM: <s> sets use weighted on off </s>
funcom_train/8777034
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void setActions() { PackingCasesAction addcase = new PackingCasesAction(packingcases, PackingCasesAction.ADDCASE); addAction(addcase, "addCase", false); PackingCasesAction removecase = new PackingCasesAction(packingcases, PackingCasesAction.REMOVECASE); addAction(removecase, "removeCase", false); ExitAction exitAction = new ExitAction(); addAction(exitAction, "exit",false); } COM: <s> assigns action classes to triggers </s>
funcom_train/21405117
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void startStreamingTrack() throws Exception { streaming = true; long server_id = -1; StreamingManager sm = new StreamingManager(ctx); try { server_id = sm.startStreaming(); } catch (Exception e) { streaming = false; throw e; } try { service.setServerId(server_id); } catch (RemoteException ex) { Log.e(LOG_TAG, "Error on start"); } catch (Exception ex) { Log.e(LOG_TAG, "Error on start"); } startTrackProcess(); } COM: <s> start a streaming track </s>
funcom_train/51635776
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Set getVisibleProjects() { final TreeItem[] children= ((TreeViewer) getViewer()).getTree().getItems(); final Set result= new HashSet(); for (int index= 0; index < children.length; index++) { final Object data= children[index].getData(); if (data instanceof IJavaProject) result.add(data); } return result; } COM: <s> returns the visible projects </s>
funcom_train/5438521
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Server createServer() { Server srv = new Server(); addGoalWest(srv, -Server.WIDTH / 2, 0); addGoalEast(srv, Server.WIDTH / 2, 0); addFlags(srv); srv.addSimObject(new Ball(0, 0)); return srv; } COM: <s> creates a server with no players </s>
funcom_train/31626679
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: protected Wizard newWizard(final ExpressoRequest request) throws WizardException, ControllerException { //commented out by rich // if (request.getParameter(PARAM_TARGET_ID) != null && request.getParameter(PARAM_TARGET_ID).length() > 0) { // theNewWizard.setTargetNodeId(request.getParameter(PARAM_TARGET_ID)); // } return super.newWizard(request); } COM: <s> override of wizard controller to provide for the unique capabilities </s>
funcom_train/31302030
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getClassTitle(Object object) { Collection tags = getTaggedValues(object); String title = findTagValue(tags, MMBaseUMLProfile.TAGGED_VALUE_CLASS_TITLE); if (title != null) { title = javaDocToText(title); title = getDocumentationHelper().getXML(title); } return title; } COM: <s> returns the tagged value of title on a class in xml format </s>
funcom_train/28752357
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setReleasedata(Long newVal) { if ((newVal != null && this.releasedata != null && (newVal.compareTo(this.releasedata) == 0)) || (newVal == null && this.releasedata == null && releasedata_is_initialized)) { return; } this.releasedata = newVal; releasedata_is_modified = true; releasedata_is_initialized = true; } COM: <s> setter method for releasedata </s>
funcom_train/20584166
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String totalEntropy() { DecimalFormat df = new DecimalFormat("0.000"); // converts the values List to an array for easier manipulation String[] arrayVals = values.toArray(new String[0]); String entropyStr = ""; for (int i = 0; i < arrayVals.length; i++) { entropyStr = entropyStr + arrayVals[i]; } entropyStr = "" + df.format(entropy(entropyStr)); return entropyStr; } COM: <s> concatenates all strings and calculates the total entropy of all the </s>
funcom_train/8629898
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getParameterTypeName(int param) throws SQLException { try { debugCodeCall("getParameterTypeName", param); ParameterInterface p = getParameter(param); int type = p.getType(); if (type == Value.UNKNOWN) { type = Value.STRING; } return DataType.getDataType(type).name; } catch (Exception e) { throw logAndConvert(e); } } COM: <s> returns the parameter type name </s>
funcom_train/36185861
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private Location convertToLocation(String locationAttribute) { if (locationAttribute == null) return null; StringTokenizer st = new StringTokenizer(locationAttribute, ","); Location loc = null; try{ String temp = st.nextToken(); double x = Double.parseDouble(temp); temp = st.nextToken(); double y = Double.parseDouble(temp); temp = st.nextToken(); double floorNumber = Double.parseDouble(temp); loc = new Location(x, y, floorNumber); } catch (NumberFormatException e){ e.printStackTrace(); } return loc; } COM: <s> format of the input is a string consisting of double double double </s>
funcom_train/45599391
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void deleteExecutedScript(ExecutedScript executedScript) { checkExecutedScriptsTable(); getExecutedScripts().remove(executedScript); String deleteSql = "delete from " + getQualifiedExecutedScriptsTableName() + " where " + fileNameColumnName + " = '" + executedScript.getScript().getFileName() + "'"; sqlHandler.executeUpdateAndCommit(deleteSql, defaultDatabase.getDataSource()); } COM: <s> remove the given executed script from the executed scripts </s>
funcom_train/36125522
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void getNumberChars(CharArray output) throws IOException { Event event = this.valstate == null ? nextEvent() : null; if (this.valstate == Event.LONG || this.valstate == Event.NUMBER) { output.write(this.outputBuffer); } else if (this.valstate == Event.BIGNUMBER) { continueNumber(output); } else { throw runtimeException("Unexpected " + event); } this.valstate = null; } COM: <s> reads a json numeric value into the output </s>
funcom_train/9023590
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void listen(){ while (true) { try { Socket socket = dasSocket.accept(); BufferedReader in = new BufferedReader(new InputStreamReader(socket.getInputStream())); PrintWriter out = new PrintWriter(socket.getOutputStream(), true); String clientMessage = in.readLine(); System.out.println(clientMessage); parseClientRequest(clientMessage); out.println(returnMessage); out.close(); in.close(); socket.close(); } catch (IOException ioe) { ioe.printStackTrace(); } catch (SecurityException se) { se.printStackTrace(); } } } COM: <s> method that listens on the socket it then parses the message </s>
funcom_train/3464431
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private String insertPic(HashMap h, String file, String data) { if(h.get(file)==null) { h.put(file, data); return file; } else { if(!data.equals(h.get(file))) { return checkForExisting(h, file, data, 1); } else { h.put(file, data); return file; } } } COM: <s> adds an image to the hash map </s>
funcom_train/777338
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetCopyrightNotice() { String copyrightNotice = jadeRuntime.getCopyrightNotice(); assertEquals( "JadeRuntimeMBean.getCopyrightNotice() returned "+ copyrightNotice+ " instead of "+Runtime.getCopyrightNotice(), Runtime.getCopyrightNotice(), copyrightNotice ); } COM: <s> test runtime copyright notice </s>
funcom_train/1240542
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setHeader(SOAPHeader hdr) { if(this.header != null) { removeChild(this.header); } header = hdr; try { header.setParentElement(this); } catch (SOAPException ex) { // class cast should never fail when parent is a SOAPEnvelope log.fatal(Messages.getMessage("exception00"), ex); } } COM: <s> set the soap header </s>
funcom_train/6332065
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Class targetClass() { try { return target.getClass(); } catch (NullPointerException e) { if (target != null) { throw e; } else { throw new NullPointerException(this + ": getCluster()=" + getCluster() + ": target=" + target + "."); } } } COM: <s> returns the class for the target object </s>
funcom_train/46104872
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: private void insertNode(Network target2, int start, int end, int col) { if (inhibitNotify != 0) { return; } try { for (int i = start; i <= end; i++) { Node currentNode = findNode(i, source); target.addNode(currentNode); } } catch (Exception e) { new ObviousRuntimeException(e); } } COM: <s> node s have been inserted </s>
funcom_train/17915594
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getDimensions(String locator, String database, String mask) throws AxisFault { try { IComponent component = ConfigManager.getInstance().getComponent(Locator.parse(locator),null); if (component instanceof OLAPConnection) { return ((OLAPConnection)component).getDimensions(database, mask).toString(); } return null; } catch (Exception e) { throw new AxisFault("Failed to execute method getDimensions for locator "+getPrintable(locator)+": "+e.getMessage()); } } COM: <s> get the dimension meta data from an existing olap connection </s>
funcom_train/9294663
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void setBorderVisible(boolean show) { checkWidget(); if (showBorder == show) return; showBorder = show; if (showBorder) { if ((getStyle() & SWT.FLAT) != 0 || !draw3DBorder) { BORDER_LEFT = BORDER_TOP = BORDER_RIGHT = BORDER_BOTTOM = 1; } else { BORDER_LEFT = BORDER_TOP = 1; BORDER_RIGHT = BORDER_BOTTOM = 3; } } else { BORDER_BOTTOM = BORDER_TOP = BORDER_LEFT = BORDER_RIGHT = 0; } layout(); redraw(); } COM: <s> specify whether the border should be displayed or not </s>
funcom_train/4154332
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void damageWalls( final Map map, final GameCoreHandler gameCoreHandler ) { gameCoreHandler.damageWall( xPoints[ xPoints.length - 1 ] >> GeneralConsts.WALL_WIDTH_SHIFT, yPoints[ yPoints.length - 1 ] >> GeneralConsts.WALL_HEIGHT_SHIFT, DAMAGE ); } COM: <s> damages all walls hit by this polyline shot </s>
funcom_train/36685594
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public int commonCount(char[] aletters, char[] bletters) { int count = 0; for (int k = 0; k < aletters.length; k++) { for (int j = 0; j < bletters.length; j++) { if (bletters[j] == aletters[k]) { bletters[j] = '*'; // don't use this again count++; break; } } } return count; } COM: <s> returns number of letters in common to a and b ensuring each common </s>
funcom_train/3160810
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void selectNextFrame() { JInternalFrame[] frames = getAllFrames(); if (frames.length > 0) { try { frames[0].setSelected(true); } catch (java.beans.PropertyVetoException pve) { System.out.println("Bean veto: " + pve.getMessage()); /*I18N*/ } } } COM: <s> selects the next available frame upon the virtual desktop </s>
funcom_train/35847699
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean addChar(char c) { int i; pattern <<= 1; pattern |= 1; for (i = 0; i < length; i++) { if (theString.charAt(i) != c) { pattern &= ~(1 << i); } } return (pattern & (1 << (length - 1))) != 0; } COM: <s> called by my tokenizer when a new character is processed in the </s>
funcom_train/39973258
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public CAWolfram1D setRuleArray(boolean[] r) { if (r.length == numBits) { System.arraycopy(r, 0, rules, 0, r.length); } else { throw new IllegalArgumentException( "rule array length needs to be equal to " + numBits + " for the given kernel size"); } return this; } COM: <s> updates the rules using the given array </s>
funcom_train/7508210
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public String getQueryString() { String query = getHttpServletRequest().getQueryString(); String clean = ""; try { clean = ESAPI.validator().getValidInput("HTTP query string: " + query, query, "HTTPQueryString", 2000, true); } catch (ValidationException e) { // already logged } return clean; } COM: <s> returns the query string from the http servlet request after canonicalizing </s>
funcom_train/18195552
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void incrementReferences() { // increment happens in if statement, before the > check if (numberOfReferences > ++numberOfReferences) { numberOfReferences--; throw new ReferencesOverflowException("The user \"" + forename + " " + surname + "\" has too many references."); } } COM: <s> increases the number of documents referenced by this user by one </s>
funcom_train/8662934
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public Object trapFieldRead(String name) { Class jc = getClassMetaobject().getJavaClass(); try { return jc.getField(name).get(getObject()); } catch (NoSuchFieldException e) { throw new RuntimeException(e.toString()); } catch (IllegalAccessException e) { throw new RuntimeException(e.toString()); } } COM: <s> is invoked when public fields of the base level </s>
funcom_train/9484533
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void testGetMetafacadeBuilder_2() { String path = "resources/builderTestFiles/model_2"; System.setProperty(DirigentConfig.MODEL_PATH, path); MetafacadeBuilder mfb = MetafacadeBuilder.getMetafacadeBuilder(); assertNotNull(mfb); assertTrue(mfb instanceof CsvMetafacadeBuilder); assertNotNull(mfb.getMetafacade("S_MYSQL")); assertNotNull(mfb.getMetafacade("T_EMP")); assertNotNull(mfb.getMetafacade("M_EMPLOYEE")); FileComparator .assertEquals( "results/builderTests/TestMetafacadeBuilder.expected.query.2.sql", ((IMapping) mfb.getMetafacade("M_EMPLOYEE")) .getSQLQuery()); } COM: <s> testing basic filter clause </s>
funcom_train/34748561
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void run() { try { evict(); } catch(Exception e) { // ignored } catch(OutOfMemoryError oome) { // Log problem but give evictor thread a chance to continue in // case error is recoverable oome.printStackTrace(System.err); } try { ensureMinIdle(); } catch(Exception e) { // ignored } } COM: <s> run pool maintenance </s>
funcom_train/51539223
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public boolean isMidletInList(String id, String className) { synchronized (midletProxies) { for (int i = midletProxies.size() - 1; i >= 0; i--) { MIDletProxy current = (MIDletProxy) midletProxies.elementAt(i); if (current.getSuiteId().equals(id) && current.getClassName().equals(className)) { return true; } } } return false; } COM: <s> check to see if the midlet is already started </s>
funcom_train/47886895
/tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716
TDAT: public void radMouthCountStateChanged(ChangeEvent evt) { if (radMouth.getSelection().equals(radMouthCount.getModel())) spinMouth.setModel(spinMouthCountModel); else spinMouth.setModel(spinMouthDuringModel); tfEyes = ((javax.swing.JSpinner.DefaultEditor)spinMouth.getEditor()) .getTextField(); tfEyes.setEditable(false); } COM: <s> event mouth radio button </s>