__key__ stringlengths 16 21 | __url__ stringclasses 1 value | txt stringlengths 183 1.2k |
|---|---|---|
funcom_train/28353265 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setLowerLimit( final double limit ) {
final double caLimit = toCA( limit );
// check if the conversion flips the sign of the values
if ( toPhysical( _coreParameter.getLowerLimit() ) <= toPhysical( _coreParameter.getUpperLimit() ) ) {
_coreParameter.setLowerLimit( caLimit );
}
else {
_coreParameter.setUpperLimit( caLimit );
}
}
COM: <s> set this parameters lower variable limit </s>
|
funcom_train/12179026 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void expectGetDefaultPaneGridAttributes(FormatMock.Expects expects) {
// expects.getBackgroundComponent().returns(null).any();
// expects.getBackgroundComponentType().returns(null).any();
// expects.getBackgroundColour().returns(BACKGROUND_COLOR).any();
// expects.getBorderWidth().returns(BORDER_WIDTH_STRING).any();
// expects.getCellPadding().returns(CELL_PADDING).any();
// expects.getCellSpacing().returns(CELL_SPACING).any();
// expects.getHeight().returns(HEIGHT).any();
// expects.getWidth().returns(WIDTH).any();
// expects.getWidthUnits().returns(WIDTH_UNITS);
}
COM: <s> initialise the mock with default pane and grid attributes </s>
|
funcom_train/23825046 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setGraphGenerator(GraphGenerator generator) {
if(generator == null) {
throw new NullPointerException("GraphGenerator must not be null");
}
GraphGenerator oldGraphGenerator = this.graphGenerator;
this.graphGenerator = generator;
Iterator it = oldGraphGenerator.getGraphGeneratorListeners();
while(it.hasNext()) {
GraphGeneratorListener lsnr = (GraphGeneratorListener) it.next();
graphGenerator.addGraphGeneratorListener(lsnr);
it.remove();
}
firePropertyChangeEvent(Controller.GRAPH_GENERATOR_PROPERTY, oldGraphGenerator, graphGenerator);
}
COM: <s> sets the code graph generator code which is used to create </s>
|
funcom_train/40699460 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private TripItem getTripItemForKey(final String tripItemKey) {
final String tripItemSerial = LocalDbService.getPersistent(tripItemKey);
if (tripItemSerial == null) {
return null;
}
final JsoTripItem jsoTripItem =
(JsoTripItem) JSONParser.parse(tripItemSerial).isObject().getJavaScriptObject();
return jsoTripItem.getTripItem();
}
COM: <s> get trip item by key </s>
|
funcom_train/6206298 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected List getFormFieldGeneratorHelpers(List gaijinFormFields) {
List helpers = new ArrayList(gaijinFormFields.size());
Iterator it = gaijinFormFields.iterator();
while (it.hasNext()) {
IGaijinFormField formField = (IGaijinFormField) it.next();
String id = formField.getFormFieldData().getId();
helpers.add(getFormFieldGeneratorHelper(id));
}
Collections.sort(helpers);
return helpers;
}
COM: <s> get the helpers for a list of form fields </s>
|
funcom_train/43269033 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setLinkValue(String linkValue) {
// Error handiling to match database schema
if ((linkValue != null) && (linkValue.length() > 255)) {
linkValue = linkValue.substring(0, 255);
log.warn("WARNING: Truncating linkValue to 255 characters");
}
rebuildStringValue = true; // Need to rebuild the value used for hashing.
this.linkValue = linkValue;
}
COM: <s> sets the code link template code link value attribute </s>
|
funcom_train/3876008 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private String updateSelectedString() {
String text, selected, total;
total = Integer.toString(availableIssues.size());
selected = Integer.toString(nIssues);
text = strSelectedMask.replaceFirst("%1", selected).replaceFirst("%2",
total);
return text;
}
COM: <s> this method refresh the text that indicates how many issues are selected </s>
|
funcom_train/8241151 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testIntranet2Internet() throws Exception {
System.out.println("intranet2Internet");
SyncClientService instance = null;
boolean expResult = false;
boolean result = instance.intranet2Internet();
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 intranet2 internet method of class sync client service </s>
|
funcom_train/9787880 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void addExtension(String extension) {
if(filters == null) {
filters = new Hashtable(5);
}
// Added for Intergeo File Format (Yves Kreis) -->
if (extension.indexOf(".") > -1) {
extension = extension.substring(0, extension.lastIndexOf("."));
}
// <-- Added for Intergeo File Format (Yves Kreis)
filters.put(extension.toLowerCase(Locale.US), this);
fullDescription = null;
}
COM: <s> adds a filetype dot extension to filter against </s>
|
funcom_train/39314672 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testcreateNewActionPerformed() {
System.out.println("testcreateNewActionPerformed");
preferences myPrefs=new preferences(ff, true);
String s=new String("l");
ActionEvent myEvent=new ActionEvent(s, 1, "hello");
myPrefs.createNewActionPerformed(myEvent);
//empty code
}
COM: <s> test of create new action performed method of class preferences </s>
|
funcom_train/44999213 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void fireFunctionChangeEvent(FunctionChangeEvent event) {
java.util.ArrayList list;
synchronized (this) {
if (changeListenerList == null)
return;
list = (java.util.ArrayList) changeListenerList.clone();
}
if (getParent() != null)
list.add(getParent());
for (int i = 0; i < list.size(); i++) {
((FunctionListener) list.get(i)).functionChanged(event);
}
}
COM: <s> notifies all registered listeners about the event </s>
|
funcom_train/37230162 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setVisitNumber( String sVisitNo, String sVisitNoOID ) {
CXElement cx = getVisitNumber(); // Gets the visit number OBJECT even if it didn't previously exist.
// Now assign the values.
cx.setAssigningAuthority("",sVisitNoOID,"ISO");
cx.setIdentifier( sVisitNo );
}
COM: <s> set the visit accession number and visit number assigner oid </s>
|
funcom_train/50342356 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void start() {
if (log.isDebugEnabled()) log.debug("identify begins");
// must be idle, or something quite bad has happened
if (state !=0) log.error("start with state "+state+", should have been zero");
// The first test is invoked here; the rest are handled in the programmingOpReply callback
state = 1;
test1();
}
COM: <s> start the identification state machine </s>
|
funcom_train/49409145 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testAddComponent() {
System.out.println("addComponent");
Item instance = new Item();
Component c = new Component("1");
ComponentType result = instance.addComponent(c);
assertTrue(result.getId().equals("1"));
assertTrue(result == c);
}
COM: <s> test of add component method of class info </s>
|
funcom_train/50154537 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected StrutsApplicationTreeNode getStrutsTreeNode(StrutsApplicationModel model) {
StrutsApplicationTreeNode _node = null;
ProjectTreeNode _root = (ProjectTreeNode) getRoot();
Enumeration _enum = _root.children();
while (_enum.hasMoreElements()) {
StrutsApplicationTreeNode _next =
(StrutsApplicationTreeNode) _enum.nextElement();
if (_next.getModel() == model) {
_node = _next;
break;
}
}
return _node;
}
COM: <s> method get struts tree node </s>
|
funcom_train/29023235 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void createAndShowGUI() {
//Create and set up the window.
JFrame frame = new JFrame("Animated Plot Controller");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
this.setOpaque(true); //content panes must be opaque
frame.setContentPane(this);
//Display the window.
frame.pack();
frame.setVisible(true);
}
COM: <s> create the gui and show it </s>
|
funcom_train/10209313 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: /*
* @SuppressWarnings("unused") private void onFindSumoExe() { String result
* = QFileDialog.getOpenFileName(this,
* tr("Please choose the target directory."),"",new
* QFileDialog.Filter("Executables (*.exe);;All (*)")); if
* (!result.equals("")) { sumoexeEdit.setText(toOSSpecificPath(result,"/"));
* } }
COM: <s> checks whether the currently entered sumo path exists and warns the user </s>
|
funcom_train/26229547 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean lookaheadIsEmpty(Alternative alt, int maxDepth) {
int depth = alt.lookaheadDepth;
if ( depth == GrammarAnalyzer.NONDETERMINISTIC ) {
depth = grammar.maxk;
}
for (int i=1; i<=depth && i<=maxDepth; i++) {
BitSet p = alt.cache[i].fset;
if (p.degree() != 0) {
return false;
}
}
return true;
}
COM: <s> is the lookahead for this alt empty </s>
|
funcom_train/18548704 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void remove(TransferObject to, Connection c) throws DataAccessException {
PreparedStatement pstmt = null;
try {
CategoryTO cto = (CategoryTO)to;
pstmt = c.prepareStatement("delete from category where id=?");
pstmt.setString(1, cto.getId());
pstmt.executeUpdate();
} catch (SQLException e) {
throw new DataAccessException(e);
}finally{
super.closeStatement(null, pstmt);
}
}
COM: <s> remove a category from data base </s>
|
funcom_train/18514139 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean isAttributeLike() {
// it must have no attributes
if (attributes.size() == 0) {
// it must have no subelement
// it meens that the only contain of this element is string
// values that could be displayed as attributes
// so returns the hasValue value
if (subElements.size() == 0) { return hasValue; }
}
// else, it is not attributeLike
return false;
}
COM: <s> says whether this component could be seen as an attribute or not to </s>
|
funcom_train/50862774 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Malfunction getMostSeriousMalfunction() {
Malfunction result = null;
double highestSeverity = 0;
if (hasMalfunction()) {
Iterator<Malfunction> i = malfunctions.iterator();
while (i.hasNext()) {
Malfunction malfunction = i.next();
if ((malfunction.getSeverity() > highestSeverity) && !malfunction.isFixed()) {
highestSeverity = malfunction.getSeverity();
result = malfunction;
}
}
}
return result;
}
COM: <s> gets the most serious malfunction the entity has </s>
|
funcom_train/9908661 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public float elapsedTime() {
Calendar time1 = getStartTime();
Calendar time2 = getCurrentTime();
if ((time1 != null) && (time2 != null)) {
long millisecondsTime1 = time1.getTimeInMillis();
long millisecondsTime2 = time2.getTimeInMillis();
return (millisecondsTime2 - millisecondsTime1) / 1000f;
}
else {
return 0;
}
}
COM: <s> returns the elapsed time in seconds </s>
|
funcom_train/3678042 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void initComponents() {
getContentPane().setLayout( new BorderLayout() );
addMouseListener( new MouseAdapter() {
public void mouseClicked( MouseEvent evt ) {
if ( f != null ) {
fVisible = !fVisible;
f.setVisible( fVisible );
if ( fVisible )
f.toFront();
}
}
} );
}
COM: <s> sets the layout and adds a mouse listener that makes </s>
|
funcom_train/40105086 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected String getHeader() {
return Messages.getString("SourceDocument.TitleLabel") + ":\t" + title + "\n" + //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
Messages.getString("SourceDocument.AuthorLabel") + ":\t" + author + "\n" + //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
"\n"; //$NON-NLS-1$
}
COM: <s> returns the title the upper label of the source document </s>
|
funcom_train/21654933 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JPanel getPanelWithButtons() {
if (panelWithButtons == null) {
panelWithButtons = new JPanel();
panelWithButtons.setLayout(new GridLayout(2, 1));
JPanel panel1 = new JPanel();
JPanel panel2 = new JPanel();
panel1.add(getAddButton());
panel1.add(getJRButton());
panel1.add(getDelButton());
panel2.add(getPanelWithRadioButtons());
panelWithButtons.add(panel1);
panelWithButtons.add(panel2);
}
return panelWithButtons;
}
COM: <s> this method initializes panel with buttons </s>
|
funcom_train/18257102 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setLocation(Object o, Rectangle2D bounds, double x, double y) {
RectangularShape shape = getCachedShape(o);
if (shape != null) {
shape.setFrameFromCenter(x, y, x + shape.getWidth() / 2, y + shape.getHeight() / 2);
}
}
COM: <s> code set location code updates the cached location for an </s>
|
funcom_train/12157737 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void writeGetDependentAccessorsMethod () {
// Write the method declaration.
out.println ();
out.println (" // Javadoc inherited from super class.");
out.println (" public Collection getDependentAccessors () {");
out.println (" return dependentAccessors;");
out.println (" }");
}
COM: <s> write out the get dependent accessors method </s>
|
funcom_train/1570863 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean isEndOfLine(int c) throws IOException {
// check if we have \r\n...
if (c == '\r') {
if (this.in.lookAhead() == '\n') {
// note: does not change c outside of this method !!
c = this.in.read();
}
}
return (c == '\n');
}
COM: <s> greedy accepts n and r n </s>
|
funcom_train/14207681 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void assertPageTitle(String pageTitle, WebResponse response) throws Exception {
String title = response.getTitle();
assertEquals(
"Expected page title \"" + pageTitle + "\", got: \"" + title + "\"",
pageTitle,
title
);
}
COM: <s> assert that the response has the expected page title </s>
|
funcom_train/34478922 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean isModified() throws SdaiException {
// synchronized (syncObject) {
if (!opened) {
throw new SdaiException(SdaiException.SS_NOPN);
}
for (int k = 0; k < active_servers.myLength; k++) {
SdaiRepository rep = (SdaiRepository)active_servers.myData[k];
if (rep.isModified()) {
return true;
}
}
return false;
// } // syncObject
}
COM: <s> informs if at least one repository available in this session is modified </s>
|
funcom_train/45144005 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void createSQLPage(){
try {
sqlEditor = new SQLEditor();
int index = addPage(sqlEditor, getEditorInput());
setPageText(index, sqlEditor.getTitle());
} catch (PartInitException e) {
ErrorDialog.openError(getSite().getShell(), "Error creating SQL Editor",
null, e.getStatus());
}
}
COM: <s> creates the sql editor page </s>
|
funcom_train/2807827 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected double eval(ArithmeticTerm t) {
Object o = t.eval();
if (o == null) {
throw new EvaluationException(
t + " is undefined in " + this);
}
if (!(o instanceof Number)) {
throw new EvaluationException(
t + " is not a number in " + this);
}
Number n = (Number) o;
return n.doubleValue();
}
COM: <s> get the double value of this term </s>
|
funcom_train/37021118 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void enterOperation(String opcode) {
// create a class for the operation
Operation op = findOperation(opcode);
// depending on the current state, do operation, set new state
if (opcode.compareTo("MemoryRecall") == 0) {
// memory recall is an operation but behaves like a number
// so handle it as entering a value
setState(state.enterValue(op));
}
else
setState(state.enterOperation(op));
}
COM: <s> enter operations into the cpu </s>
|
funcom_train/44823539 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean equals (Object o) {
if (o != null && getClass().equals(o.getClass())) {
return org.jewelbox.service.core.util.StringUtils.equalStrings
(serviceName,
((BaseServiceConfiguration)o).getName());
} else {
return false;
}
}
COM: <s> override to equals to base equality on servic name </s>
|
funcom_train/48076642 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void handleChunk_SendKO(ChunkMessage chunkMessage) {
// by convention, should the sender be the source, we avoid sending the
// ack over the simulated transport otherwise we do
if (chunkMessage.isFromSigma()) {
StarStreamSource.chunkKo(chunkMessage.getChunk().getResourceId());
} else {
ChunkKo ko = chunkMessage.replyKo();
send(ko);
}
}
COM: <s> reply to the node that just sent the input </s>
|
funcom_train/7777720 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void report (HttpServletRequest request, HttpServletResponse response) throws IOException {
HttpSession session = request.getSession(true);
RegisteredPatronAccountBean patron = (RegisteredPatronAccountBean)session.getAttribute("patron");
PrintWriter out = response.getWriter();
try {
ReservationControl resCtrl = new ReservationControl();
List<ReservationBean> reportList = resCtrl.search(patron);
out.write(encapsulateBeanListXML(reportList, "reservations"));
}
catch (ErrorBean e) {
out.println(e.toXML());
}
}
COM: <s> passes all the information of the reservation to be searched to </s>
|
funcom_train/28362978 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void selectedChannelGroupChanged( final BrowserModel model, final ChannelGroup newGroup ) {
if ( newGroup != null ) {
ChannelWrapper[] wrappers = newGroup.getChannelWrappers();
setSelectedSignals( convertToPVs(wrappers) );
}
else {
setSelectedSignals( new String[0] );
}
_proxy.selectedChannelGroupChanged( this, newGroup );
}
COM: <s> update the channel wrappers for the newly selected channel group and </s>
|
funcom_train/3022511 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void insureMinimumLettersInTypeCode(StringBuffer buffer, String type) {
buffer.append(type.charAt(1));
int ndx = 2;
char ch = type.charAt(ndx);
while (isVowel(ch)) {
buffer.append(ch);
ndx++;
ch = type.charAt(ndx);
}
buffer.append(ch);
}
COM: <s> insures that we have the appropriate number of characters </s>
|
funcom_train/44448629 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String recognize(SunAu sound) {
if (sound == null) {
Log.println("Nothing recorded");
return "";
}
sound = filter(sound);
LPC lpcData = new LPC(sound.getChannelStream(1));
LPC result = dtwMatcher.bestMatch(lpcData);
if (result == null) {
Log.println("Could not recognize");
return null;
} else {
Log.println("Recognized: " + result.getWord() + "\tScore: "
+ result.getCost());
}
return result.getWord();
}
COM: <s> recognizes the sound using a dtw algorithm </s>
|
funcom_train/19314265 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void createBasicLink(final Area area) {
boolean externalLink = false;
if (area.linkType() == LinkType.EXTERNAL) {
externalLink = true;
}
final Rectangle rectangle = new Rectangle(area.brOriginX(),
area.brOriginY(), area.brIpd(), area.brBpd());
this.currentPage.makeLink(rectangle, area.linkDestination(),
externalLink);
}
COM: <s> marks a specified area as being a link </s>
|
funcom_train/4917315 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testOfficeListing() throws UnknownOfficeException {
// Ensure correct office listing
String[] officeNames = this.officeFloor.getOfficeNames();
this.assertNames(officeNames, this.officeName);
// Ensure able to obtain Office
Office office = this.officeFloor.getOffice(this.officeName);
assertNotNull("Must have Office", office);
}
COM: <s> ensure able to obtain </s>
|
funcom_train/41332831 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void paintWithCaching(Graphics2D g, JComponent c, int w, int h, Object[] extendedCacheKeys) {
VolatileImage img = getImage(g.getDeviceConfiguration(), c, w, h, extendedCacheKeys);
if (img != null) {
// render cached image
g.drawImage(img, 0, 0, null);
} else {
// render directly
paintDirectly(g, c, w, h, extendedCacheKeys);
}
}
COM: <s> paint the component using a cached image if possible </s>
|
funcom_train/20299615 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void navigationPathChange(ActionEvent event){
// get from the context content include path to show as well
// as the title associated with the link.
FacesContext context = FacesContext.getCurrentInstance();
Map map = context.getExternalContext().getRequestParameterMap();
selectedIncludePath = (String) map.get("includePath");
}
COM: <s> action listener for the changes the selected content path in the </s>
|
funcom_train/32829801 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void loadDefaultConfiguration(Properties properties) {
Properties defaultProperties = propertiesReader.loadPropertiesFileFromClasspath(DEFAULT_PROPERTIES_FILE_NAME);
if (defaultProperties == null) {
throw new UnitilsException("Configuration file: " + DEFAULT_PROPERTIES_FILE_NAME + " not found in classpath.");
}
properties.putAll(defaultProperties);
}
COM: <s> load the default properties file that is distributed with unitils unitils default </s>
|
funcom_train/29403746 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Command getCommand(Request request) {
if (request instanceof ReconnectRequest) {
Object view = ((ReconnectRequest) request).getConnectionEditPart()
.getModel();
if (view instanceof View) {
Integer id = new Integer(VcVisualIDRegistry
.getVisualID((View) view));
request.getExtendedData().put(VISUAL_ID_KEY, id);
}
}
return super.getCommand(request);
}
COM: <s> extended request data key to hold editpart visual id </s>
|
funcom_train/15588331 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getButtonTestPOP3() {
if (buttonTestPOP3 == null) {
buttonTestPOP3 = new JButton();
buttonTestPOP3.setText("Test POP3");
buttonTestPOP3.setLocation(new Point(9, 89));
buttonTestPOP3.setSize(new Dimension(110, 25));
buttonTestPOP3.setMnemonic(KeyEvent.VK_WINDOWS);
}
return buttonTestPOP3;
}
COM: <s> this method initializes button test pop3 </s>
|
funcom_train/26395866 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void filterIgnoredModifications(final List<Modification> modifications) {
if (ignoreFiles != null) {
for (Iterator<Modification> iterator = modifications.iterator(); iterator.hasNext();) {
final Modification modification = iterator.next();
if (isIgnoredModification(modification)) {
iterator.remove();
}
}
}
}
COM: <s> remove all modifications that match any of the ignore files patterns </s>
|
funcom_train/50098601 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public XMLNode select(String what) {
XMLNode select = new XMLNode("select");
if(what.startsWith("/")) {
selectInto(what.substring(1), select, false);
} else {
selectChildrenInto(what, select, false);
}
if(select.getNodeCount() == 0) return null;
return select;
}
COM: <s> selects nodes from the xml tree that starts at this node </s>
|
funcom_train/1010565 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int hashCode() {
int sum1 = left + bottom;
int sum2 = right + top;
int val1 = sum1 * (sum1 + 1)/2 + left;
int val2 = sum2 * (sum2 + 1)/2 + top;
int sum3 = val1 + val2;
return sum3 * (sum3 + 1)/2 + val2;
}
COM: <s> returns the hash code for this insets </s>
|
funcom_train/33365867 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean isValid() {
int n;
int off;
if ((n = getIno(0)) < 0 || n > PBLKSIZ / SHORTSIZ)
return false;
if (n > 0) {
off = PBLKSIZ;
for (int i=1; n > 0; i += 2) {
if (getIno(i) > off || getIno(i+1) > off ||
getIno(i+1) > getIno(i))
return false;
off = getIno(i+1);
n -= 2;
}
}
return true;
}
COM: <s> check page sanity </s>
|
funcom_train/2628492 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testIsRoot() {
System.out.println("isRoot");
GUITypeWrapper instance = null;
boolean expResult = false;
boolean result = instance.isRoot();
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 is root method of class guitype wrapper </s>
|
funcom_train/33265419 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Dimension getPreferredSize() {
if ( valid && ( pref_width >= 0 ) && ( pref_height >= 0 ) ) {
return new Dimension( pref_width, pref_height );
}
Dimension pref = super.getPreferredSize();
list.setFont(text.getFont());
Dimension listSize = list.getPreferredSize();
pref.width = Math.max(pref.width,listSize.width+2);
return pref;
}
COM: <s> returns the preferred width and height if both 0 </s>
|
funcom_train/20875449 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public long getPropertyLong(String key, long defaultValue) {
try {
if (containsPropery(key))
return Long.parseLong(getProperty(key));
if (iSaveDefaults)
setProperty(key, String.valueOf(defaultValue));
return defaultValue;
} catch (NumberFormatException nfe) {
if (iSaveDefaults)
setProperty(key, String.valueOf(defaultValue));
return defaultValue;
}
}
COM: <s> returns long property </s>
|
funcom_train/13914099 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testGetContentType() {
System.out.println("getContentType");
ProxymaFacade proxyma = new ProxymaFacade();
ProxymaContext context = proxyma.getContextByName("default");
ProxymaServletRequest instance = new ProxymaServletRequest(request, context);
String expResult = request.getContentType();
String result = instance.getContentType();
assertEquals(expResult, result);
}
COM: <s> test of get content type method of class proxyma servlet request </s>
|
funcom_train/13778129 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void beginTable(IGridRegion regionToWrite) throws CreateTableException {
if (region != null) {
throw new IllegalStateException("beginTable() has already been called");
}
region = regionToWrite;
if (region == null) {
throw new CreateTableException("could not find appropriate region for writing");
}
currentRow = 0;
style2style.clear();
}
COM: <s> begins writing a table within the specified region </s>
|
funcom_train/10635607 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int read() throws IOException {
if (buffer == null) {
throw new IOException("Stream was closed.");
}
while (pos == end) {
if (end_reached) {
return -1;
}
// If there is no data in the buffer
// - will block untill the data will be provided by
// record layer
owner.needAppData();
}
return buffer[pos++] & 0xFF;
}
COM: <s> reads one byte </s>
|
funcom_train/19910963 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void couldNotConnect() {
setStartStopText("Start");
File f = new File(cannotConnectImageFilename);
if(f.exists())
setImage(Toolkit.getDefaultToolkit().getImage(cannotConnectImageFilename));
else
System.out.println(cannotConnectImageFilename + " not found");
}
COM: <s> displays image in cannot connect image filename upon failed connection </s>
|
funcom_train/47703978 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void doScpNoUsePasswd(String testId) {
try {
String resultFile = TestUtil.getResultPreDir(testId);
String toPath = resultFile.replace("/" + testId, "/");
String scp = MessageFormat.format(SCP_CMD_NO_PASSWD, new Object[] {
resultFile, toPath });
CommandUtil.execute(scp, null);
} catch (Throwable e) {
e.printStackTrace();
}
}
COM: <s> if create authorized keys on client server </s>
|
funcom_train/9782666 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void initConic(GeoConic macroConic, GeoConic conic) {
ArrayList macroPoints = macroConic.getPointsOnConic();
if (macroPoints == null) return;
int size = macroPoints.size();
ArrayList points = new ArrayList(size);
for (int i=0; i < size; i++) {
points.add(getAlgoGeo((GeoElement) macroPoints.get(i)));
}
conic.setPointsOnConic(points);
}
COM: <s> makes sure that all points on conic are </s>
|
funcom_train/3902543 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addTimelimitactionPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_DocumentRoot_timelimitaction_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_DocumentRoot_timelimitaction_feature", "_UI_DocumentRoot_type"),
AdlcpRootv1p2Package.Literals.DOCUMENT_ROOT__TIMELIMITACTION,
true,
false,
false,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
null,
null));
}
COM: <s> this adds a property descriptor for the timelimitaction feature </s>
|
funcom_train/31146623 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public BatchDescrIF nextBatch(int timeout) throws InterruptedException {
final List buffer = (List) list.get();
int num;
// XXX JM: should it be 'if (timeout <= 0)' ?
if (timeout == 0) {
num = source.dequeueAll(buffer);
} else {
num = source.blockingDequeueAll(buffer, timeout);
}
if (num == 0)
return null;
else
return new BatchDescrIF() {
public List getBatch() {
return buffer;
}
public void batchDone() {
buffer.clear();
}
};
}
COM: <s> returns a single batch for processing by the stages event handler </s>
|
funcom_train/34110318 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void evaluateSecurityToAction(TreeItem item) {
// Enables or disables move buttom
if ( ( ((GWTFolder) item.getUserObject()).getPermissions() & GWTPermission.WRITE) == GWTPermission.WRITE) {
Main.get().activeFolderTree.folderSelectPopup.enable(true);
} else {
Main.get().activeFolderTree.folderSelectPopup.enable(false);
}
}
COM: <s> evalues secutiry to action to prevent not permission access to folder destination </s>
|
funcom_train/45810231 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void findNoNameTopics() {
nonametopics = new ArrayList();
Collection topics = tm.getTopics();
Iterator it = topics.iterator();
while (it.hasNext()) {
TopicIF t = (TopicIF)it.next();
if (t.getTopicNames().isEmpty()) {
nonametopics.add(t);
}
}
}
COM: <s> finds all the topics with no name in the topic map </s>
|
funcom_train/2288100 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String getDisplayName(CmsObject cms, Locale locale) throws CmsException {
return Messages.get().getBundle(locale).key(
Messages.GUI_PRINCIPAL_DISPLAY_NAME_2,
getName(locale),
OpenCms.getOrgUnitManager().readOrganizationalUnit(cms, getOuFqn()).getDisplayName(locale));
}
COM: <s> returns the display name of this role including the organizational unit </s>
|
funcom_train/48959777 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected HudsonConfiguration loadHudson(UUID project) {
if (project != null) {
List<HudsonConfiguration> conf = dao.findByNamedQuery(HudsonConfiguration.FIND_BY_PROJECT, 0, 1, getProjectParams(project));
if (CollectionUtils.isNotEmpty(conf)) {
return conf.get(0);
}
}
return null;
}
COM: <s> loads the hudson configuration for this project if it already exists </s>
|
funcom_train/12867122 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean isValidNode(AST node) {
switch (node.getType()) {
case JavaTokenTypes.METHOD_DEF:
case JavaTokenTypes.CTOR_DEF:
case JavaTokenTypes.CLASS_DEF:
case JavaTokenTypes.INTERFACE_DEF:
return true;
case JavaTokenTypes.VARIABLE_DEF:
return !JavaNodeHelper.isLocalVariable(node);
default:
return false;
} // end switch
} // end isValidNode()
COM: <s> determines whether the given node is a valid javadoc node </s>
|
funcom_train/10383516 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void addPattern(String pattern) {
if (pattern == null)
return;
String decodedPattern = RequestUtil.URLDecode(pattern);
String results[] = new String[patterns.length + 1];
for (int i = 0; i < patterns.length; i++) {
results[i] = patterns[i];
}
results[patterns.length] = decodedPattern;
patterns = results;
}
COM: <s> add a url pattern to be part of this web resource collection </s>
|
funcom_train/11674567 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Color getFirstAlternativeOfType(int colorSpaceType) {
if (hasAlternativeColors()) {
for (int i = 0, c = this.alternativeColors.length; i < c; i++) {
if (this.alternativeColors[i].getColorSpace().getType() == colorSpaceType) {
return this.alternativeColors[i];
}
}
}
return null;
}
COM: <s> returns the first alternative color found with the given color space type </s>
|
funcom_train/33704818 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Map toMap() {
Map<String,Long> map = new HashMap();
map.put( "duration", getDuration() );
map.put( "meanDuration", getMeanDuration() );
map.put( "completed", getCompleted() );
map.put( "started", getStarted() );
return map;
}
COM: <s> provide the benchmark metadata as a map for use with external systems </s>
|
funcom_train/19296464 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void defaultsButton_ActionEvents() {
int sel = JOptionPane.showConfirmDialog(this,
"Set back optimization settings to default values?",
"Default Settings?", JOptionPane.YES_NO_OPTION,
JOptionPane.QUESTION_MESSAGE);
if (sel != JOptionPane.YES_OPTION)
return;
setDefaults();
}
COM: <s> sets back all settings to its respective default values </s>
|
funcom_train/45231145 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void connect() throws UnknownHostException, IOException {
setSocket(SSLSocketFactory.getDefault().createSocket(hostname, port));
setOutputStream(new DataOutputStream(new BufferedOutputStream(socket.getOutputStream())));
setInputStream(new DataInputStream(new BufferedInputStream(socket.getInputStream())));
}
COM: <s> establish the connection to the host vsmapi using ssl </s>
|
funcom_train/22402246 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getJButtonAdd() {
if (jButtonAdd == null) {
jButtonAdd = new JButton();
jButtonAdd.setText("Add indexation");
jButtonAdd.addActionListener( new java.awt.event.ActionListener (){
public void actionPerformed(java.awt.event.ActionEvent e) {
openJDialogNewIndex();
}
});
}
return jButtonAdd;
}
COM: <s> this method initializes j button add </s>
|
funcom_train/20443240 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Command getItemHistorico1() {
if (itemHistorico1 == null) {//GEN-END:|35-getter|0|35-preInit
// write pre-init user code here
itemHistorico1 = new Command("Historico", Command.ITEM, 0);//GEN-LINE:|35-getter|1|35-postInit
// write post-init user code here
}//GEN-BEGIN:|35-getter|2|
return itemHistorico1;
}
COM: <s> returns an initiliazed instance of item historico1 component </s>
|
funcom_train/31028062 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void bind(int port) throws Cube42Exception {
try {
UnicastRemoteObject.exportObject(this);
} catch (RemoteException e) {
throw new Cube42Exception(
ViewerSystemCodes.BIND_EXPORT_REMOTE_EXCEPTION,
new Object[] {e.getMessage()});
}
RMIUtils.bindInterface(port, Echoportal.RMI_NAME, this);
this.port = port;
}
COM: <s> puts the echoportal out onto rmi </s>
|
funcom_train/5345859 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void writeResponse() throws IOException {
_ostream.setIsCounting(_stateNum == THEX_REQUEST);
try {
_method.writeHttpResponse(_state, _ostream);
} catch (IOException e) {
// Only propogate the exception if they did not read
// as much as they wanted to.
if ( amountUploaded() < getAmountRequested() )
throw e;
}
_firstReply = false;
}
COM: <s> starts uploading the requested file </s>
|
funcom_train/15608232 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Set getSubjectSequenceOids(OID oid) {
loadFeaturesIfNeeded();
Set returnSet = new HashSet();
FeatureBean model = mFeatureHandler.getOrLoadModelForOid(oid);
if (model != null) {
recursivelyFindSubject(model, returnSet);
} // Found feature.
return returnSet;
} // End method
COM: <s> retrieves the subject sequence oid collection for the </s>
|
funcom_train/18903141 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void dumpAnonNodes() {
System.out.println("Dunping Anonymous nodes");
Iterator it = anonMap.entrySet().iterator();
while (it.hasNext()) {
Map.Entry e = (Map.Entry)it.next();
System.out.println(e.getKey().toString() + " -> " + e.getValue().toString());
}
}
COM: <s> debug method to see the contents of the internal anonymous node mapping </s>
|
funcom_train/33639893 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Path getPath(Graphable g) {
Path p = new Path();
p.add(g);
Graphable parent = g;
while((parent = m_iterator.getParent(parent)) != null) p.add(parent);
if (!p.getLast().equals(m_iterator.getSource())) return(null);
return(p);
}
COM: <s> returns a path b from b g b to b the source </s>
|
funcom_train/3124391 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void cancel(CProgressMonitor monitor) {
// update bar-components
CStatusBar.getStatusBar().bar_TaskLabel.setText(
TEXT_TASK_CANCELLED
+(TEXT_TASK_CANCELLED.endsWith(":") ? " " : ": ")
+ monitor.mMessage
);
// cancel showUp-Timer
if (CProgressGUI.getInstance().showUpTimer != null)
CProgressGUI.getInstance().showUpTimer.cancel();
hideDialogPanel(0);
resetAll();
}
COM: <s> update all gui components if the cancelled status is reached </s>
|
funcom_train/50327262 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean hasMode(int mode) {
if ( mode == Programmer.PAGEMODE ||
mode == Programmer.ADDRESSMODE ||
mode == Programmer.DIRECTBYTEMODE ||
mode == Programmer.REGISTERMODE ) {
log.debug("hasMode request on mode "+mode+" returns true");
return true;
}
log.debug("hasMode returns false on mode "+mode);
return false;
}
COM: <s> determine is a mode is available for this programmer implementation </s>
|
funcom_train/18653205 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void addNodes(final TreeItem root, final LDItems.LDItem item) {
for (int i = 0; i < item.getChildCount(); i++) {
LDItems.LDItem child = item.getChildAt(i);
TreeItem node = addNode(root, child);
if (child.getChildCount() > 0) {
addNodes(node, child);
}
}
}
COM: <s> add the lditem to the table tree </s>
|
funcom_train/19972979 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void listen(int secs, ClientData l) {
synchronized (this) {
clients.add(l);
// Set the overall interval.
if (clients.size() == 1)
tickSecs = secs;
else
tickSecs = gcd(tickSecs, secs);
}
if (DBG) Log.i(TAG, "listen(" + secs + "): tick=" + tickSecs);
// Interrupt the ticker thread, so it can re-schedule.
if (tickerThread != null)
tickerThread.interrupt();
}
COM: <s> schedule the given listener to get callbacks at a regular interval </s>
|
funcom_train/50569855 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void showStatus(final String status, final boolean move) {
Runnable runner = new Runnable() {
public void run() {
if (move) {
WindowManager.getDefault().getMainWindow().toFront();
}
StatusDisplayer.getDefault().setStatusText(status);
outputWriter.printOutput(status);
}
};
EventQueue.invokeLater(runner);
}
COM: <s> indicate the current the status of the session with a message </s>
|
funcom_train/19846583 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Audio getOggStream(String ref) throws IOException {
if (!soundWorks) {
return new NullAudio();
}
setMOD(null);
setStream(null);
if (soundWorks) {
if (currentMusic != -1) {
AL10.alSourceStop(sources.get(0));
}
getMusicSource();
currentMusic = sources.get(0);
return new StreamSound(new OpenALStreamPlayer(currentMusic, ref));
}
return new StreamSound(new OpenALStreamPlayer(0, ref));
}
COM: <s> get the sound based on a specified ogg file </s>
|
funcom_train/980484 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Painter getPainter() {
int width = 100;
int height = 100;
Color color1 = Color.WHITE;
Color color2 = Color.GRAY;
LinearGradientPaint gradientPaint =
new LinearGradientPaint(0.0f, 0.0f, width, height,
new float[]{0.0f, 1.0f},
new Color[]{color1, color2});
MattePainter mattePainter = new MattePainter(gradientPaint);
return mattePainter;
}
COM: <s> this painter draws a gradient fill </s>
|
funcom_train/18807815 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public RegularTimePeriod previous() {
final Month result;
if (this.month != SerialDate.JANUARY) {
result = new Month(this.month - 1, this.year);
}
else {
final Year prevYear = (Year) this.year.previous();
if (prevYear != null) {
result = new Month(SerialDate.DECEMBER, prevYear);
}
else {
result = null;
}
}
return result;
}
COM: <s> returns the month preceding this one </s>
|
funcom_train/2429143 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public SchedulePolicy getSchedulePolicy() {
try {
int id = getIntProperty(SCHEDULE_POLICY, -1);
if (id >= 0) {
return SchedulePolicy.fromId(id);
}
} catch (IllegalArgumentException ex) {
// Can only happen if the operation data has been corrupted. Return the default.
}
return SchedulePolicy.getDefault();
}
COM: <s> returns the code schedule policy code for this code operation code </s>
|
funcom_train/48333192 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void processRefArguments (MethodInfo miCallee, ReferenceVisitor visitor){
int nArgSlots = miCallee.getArgumentsSize();
for (int i=top-1; i>=top-nArgSlots; i--){
if (isOperandRef[i]){
visitor.visit(operands[i]);
}
}
}
COM: <s> generic visitor for reference arguments </s>
|
funcom_train/22607217 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void createGUI() {
if (mainFrame != null) {
return;
}
synchronized (this) {
if (mainFrame == null) {
if (isSwingPresent()) {
mainFrame = new MasterFrame();
} else {
mainFrame = new NoSwingFrame();
}
}
runner = (Runnable) mainFrame;
}
}
COM: <s> creates the main graphical user interface </s>
|
funcom_train/8164661 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void removeStatements(ModuleElementType type) {
ModuleElementList elementList = this.moduleElementList(type);
for (int elementIndex = 0; elementIndex < elementList.size(); elementIndex++) {
String elementString = elementList.getStringValue(elementIndex);
elementText = elementText.replace(elementString, "");
}
}
COM: <s> removes a statement text from this function def </s>
|
funcom_train/36900040 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void createOverlayGrid() {
double size = bounds.height / (double)8;
int startX = 0;
int startY = 0;
for (int i = 0; i < 8; i++) {
for (int j = 0; j < 8; j++) {
fields[i * 8 + j] = new Rectangle2D.Double(size * j, size * i,
size, size);
}
}
}
COM: <s> create the fields ontop of the grid </s>
|
funcom_train/325515 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void createImage() {
if (innerPanel == null){
return;
}
imageHeight = innerPanel.getHeight();
imageWidth = innerPanel.getWidth();
if (imageHeight <= 0 || imageWidth <= 0) {
return;
}
displayImage = new BufferedImage(imageWidth,
imageHeight, BufferedImage.TYPE_INT_RGB);
plotBackground = PamColors.getInstance().getColor(PamColor.PlOTWINDOW);
floodImage(plotBackground);
}
COM: <s> creates a buffered image for the actual drawing </s>
|
funcom_train/33233478 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Command getLoadLessonCommand() {
if (loadLessonCommand == null) {//GEN-END:|67-getter|0|67-preInit
// write pre-init user code here
loadLessonCommand = new Command("Load Lesson", Command.ITEM, 0);//GEN-LINE:|67-getter|1|67-postInit
// write post-init user code here
}//GEN-BEGIN:|67-getter|2|
return loadLessonCommand;
}
COM: <s> returns an initiliazed instance of load lesson command component </s>
|
funcom_train/28473274 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getDataDirectoryBrowseButton() {
if (dataDirectoryBrowseButton == null) {
dataDirectoryBrowseButton = new JButton();
dataDirectoryBrowseButton.setPreferredSize(new Dimension(101, 20));
dataDirectoryBrowseButton.setText("Browse...");
dataDirectoryBrowseButton
.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
browseDataDirectory();
}
});
}
return dataDirectoryBrowseButton;
}
COM: <s> this method initializes data directory browse button </s>
|
funcom_train/36840881 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean isHexNumberPart(int ch) {
return Character.isDigit((char) ch) || ch == 'a' || ch == 'b'
|| ch == 'c' || ch == 'd' || ch == 'e' || ch == 'f'
|| ch == 'A' || ch == 'B' || ch == 'C' || ch == 'D'
|| ch == 'E' || ch == 'F';
}
COM: <s> checks if part of hex number </s>
|
funcom_train/39911066 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testGetFirstname() {
System.out.println("getFirstname");
Employee instance = new Employee();
String expResult = "";
String result = instance.getFirstname();
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 firstname method of class buissness </s>
|
funcom_train/25324382 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void delete() throws IOException {
log.info("Deleting folder");
loadChildren();
for (int i = 0; i < children.size(); i++) {
OpenKeyValObject.load(intr.getConfig(), children.get(i)).delete();
}
intr.delete(this, true);
log.debug("Folder deleted");
}
COM: <s> deletes the folder and all children of the folder </s>
|
funcom_train/10543133 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void test1InsertAfterTrigger() throws SQLException{
if (isDerby1482Fixed == false)
return;
basicSetup();
Statement s = createStatement();
s.execute("create trigger trigger1 AFTER INSERT on table1 referencing " +
"new as n_row for each row " +
"insert into table2(id, updates) values (n_row.id, -1)");
commit();
runtest1InsertTriggerTest();
}
COM: <s> this test creates an after insert trigger which inserts non lob </s>
|
funcom_train/3785470 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean restoreSpotList()
{ /* restoreSpotList */
if(spotListBkup==null)
return(false); /* already backed up */
spotList= spotListBkup; /* Restore the backup list */
nSpots= nSpotsBackup;
spotListBkup= null; /* G.C. the backup list */
nSpotsBackup= 0;
return(true);
} /* restoreSpotList */
COM: <s> restore spot list retore spot list 0 n spots 1 from </s>
|
funcom_train/28282427 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void printStackTraces(List<StackTrace> l) {
System.out.println("\n\n");
for (int i = 0; i < l.size(); i++) {
StackTrace trace = l.get(i);
System.out.println("*****************?????????????????*****************\n");
System.out.println("OFFSET: " + trace.getOffset() + " LENGTH: " + trace.getLength());
System.out.println(trace.getStackTrace());
System.out.println("*****************?????????????????*****************\n\n");
}
}
COM: <s> print out the stack traces </s>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.