__key__
stringlengths 16
21
| __url__
stringclasses 1
value | txt
stringlengths 183
1.2k
|
---|---|---|
funcom_train/43902680 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testMissingInfoException() throws FactoryException {
// The exception should be thrown when the number of points is less than
// necessary
List pts = generateCoords(5, 2434765, false);
try {
AffineTransformBuilder builder = new AffineTransformBuilder(pts);
builder.includeWeights(true);
fail("Expected FactoryException");
} catch (MissingInfoException e) {
}
}
COM: <s> test for missing info exception </s>
|
funcom_train/39315888 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: /** public void testLgt_grayActionPerformed() {
System.out.println("testLgt_grayActionPerformed");
f.lgt_grayActionPerformed( actionEvent );
t.lgt_grayActionPerformed( actionEvent );
System.out.println("empty code");
System.out.println("done testLgt_grayActionPerformed");
}
COM: <s> public void test clear image action performed </s>
|
funcom_train/43467480 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object clone() {
AttributeCollection colCollection = new AttributeCollection();
Attribute objAttr;
Iterator iter = iterator();
while (iter.hasNext()) {
objAttr = (Attribute)iter.next();
colCollection.put(objAttr.getName(), objAttr);
}
return colCollection;
}
COM: <s> clone the attribute collection object </s>
|
funcom_train/15603025 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void createTempFileAndShow(String title) throws IOException {
File file=File.createTempFile("GB-",".htm");
createFile(file.getAbsolutePath(),title);
URLLauncher.launchURL(file.getAbsolutePath());
file.deleteOnExit();
}
COM: <s> will create an html file by prompting for the filename </s>
|
funcom_train/31192010 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setRelativePosition(int xType, int yType) {
if(relativePosition[Overlay.X_PLACEMENT] != xType
|| relativePosition[Overlay.Y_PLACEMENT] != yType) {
synchronized(relativePosition) {
relativePosition[Overlay.X_PLACEMENT] = xType;
relativePosition[Overlay.Y_PLACEMENT] = yType;
dirty(LINE_POSITION | BORDER_POSITION);
}
}
}
COM: <s> this will set the relative position of the scroller elements </s>
|
funcom_train/8969507 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void execute( Runnable task ) {
BlockingThreadPoolExecutor executor = getThreadPoolExecutor();
try {
executor.executeWithBlock( task );
} catch( RejectedExecutionException ex ) {
throw new TaskRejectedException( "Executor [" + executor + "] did not accept task: " + task, ex );
}
}
COM: <s> implementation of both the jdk 1 </s>
|
funcom_train/27787520 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean loadQuoteRange(EODQuoteRange quoteRange) {
String queryString = buildSQLString(quoteRange);
boolean success;
// This query might take a while...
ProgressDialog progress = ProgressDialogManager.getProgressDialog();
progress.setNote(Locale.getString("LOADING_QUOTES"));
progress.setIndeterminate(true);
success = executeSQLString(progress, queryString);
ProgressDialogManager.closeProgressDialog(progress);
return success;
}
COM: <s> load the given quote range into the quote cache </s>
|
funcom_train/3291077 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected String getBuilderName(String fieldname) {
int pos=fieldname.indexOf(".");
if (pos==-1) {
return null;
} else {
String bulname=fieldname.substring(0,pos);
int pos2=bulname.lastIndexOf("(");
bulname=bulname.substring(pos2+1);
// XXX: we should check on commas and semicolons too... ?
return bulname;
}
}
COM: <s> determines the builder name of a specified fieldname i </s>
|
funcom_train/25798301 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void getTvShows(DataResponse<ArrayList<TvShow>> response, final Actor actor, final Context context) {
mHandler.post(new Command<ArrayList<TvShow>>(response, this) {
@Override
public void doRun() throws Exception {
mResponse.value = shows(context).getTvShows(TvShowManager.this, actor, getSortBy(SortType.TITLE), getSortOrder(), getHideWatched(context));
}
});
}
COM: <s> gets all tv shows of an actor from database </s>
|
funcom_train/28435726 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object parse(File file) throws IOException, SAXException {
configure();
InputSource input = new InputSource(new FileInputStream(file));
input.setSystemId(file.getAbsolutePath()); //input.setSystemId("file://" + file.getAbsolutePath());
getXMLReader().parse(input);
return (root);
}
COM: <s> parse the content of the specified file using this digester </s>
|
funcom_train/21023128 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void showPopup(boolean enableAddButton, boolean enableImport, boolean enableNotifyButton) {
this.enableNotifyButton = enableNotifyButton;
this.enableAddButton = enableAddButton;
this.enableImport = enableImport;
setWidth(""+popupWidth);
setHeight(""+popupHeight);
ffUpload.init(); // Inits to correct center position
center();
// Allways must initilize htmlForm for tree path initialization
langRefresh();
ffUpload.reset(enableImport, enableNotifyButton);
}
COM: <s> show file upload popup </s>
|
funcom_train/50849907 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testEntityAngle() {
/*
assertEquals(90, AbstractEntity.calcStanceAngle(1, 0));
assertEquals(225, AbstractEntity.calcStanceAngle(-1, 1));
assertEquals(0, AbstractEntity.calcStanceAngle(0, -1));
*/
}
COM: <s> test the angle stuff in abstract entity </s>
|
funcom_train/9235752 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void layoutGroupPanel() {
groupPanel.setLayout(new MigLayout("fill, wrap 1"));
groupPanel.add(new JScrollPane(groups), "growy, w 150!");
groupPanel.add(add, "sgx button, w 150!");
groupPanel.add(edit, "sgx button, w 150!");
groupPanel.add(delete, "sgx button, w 150!");
}
COM: <s> lays out the group panel </s>
|
funcom_train/44601454 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void test_final_field_01(){
compileAndExecGivenStatement(
"X.java",
"public class X {\n" +
" final int x;\n" +
" X() {\n" +
" x = 10;\n" +
" }\n" +
"}\n",
"new X()");
}
COM: <s> the wrapper approach interferes with final fields as assignments </s>
|
funcom_train/8484715 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean equals(Object other) {
try {
if (other instanceof ATObject) {
return this.base__opeql__opeql_((ATObject) other).asNativeBoolean().javaValue;
}
} catch (InterpreterException e) {
Logging.Actor_LOG.warn("Error during equality testing:", e);
}
return false;
}
COM: <s> java method invocations of equals are transformed into </s>
|
funcom_train/43470317 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void populateTextInputsIndexDeclaratons() throws Exception {
this.out.append("words[").append(this.textInputIndex).append("] = [];\n");
this.out.append("suggs[").append(this.textInputIndex).append("] = [];\n");
}
COM: <s> make declarations for the text input index </s>
|
funcom_train/24950663 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void generateDerivatives() throws FedoraAPIException {
//update workflow process "derivative-creation" to "In progress"
Workflow workflow = getWorkflow();
workflow.updateProcessStatus("derivative-creation","In progress");
setWorkflow(workflow);
try {
if (hasDatastream("tiff")) {
addFullResFromTiff();
}
addMediumResFromFull();
addThumbnailFromMedium();
} catch (FedoraAPIException e) {
workflow.updateProcessStatus("derivative-creation","Error");
setWorkflow(workflow);
throw e;
}
workflow.updateProcessStatus("derivative-creation","Complete");
setWorkflow(workflow);
}
COM: <s> performs any additional processing that must occur in terms of creating derivatives </s>
|
funcom_train/17884931 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected long readLong() throws HeapException {
long value = 0;
for (int byteIndex = 7; byteIndex >= 0; byteIndex--) {
final byte byteValue = ioBuffer[numberOfByteReadWrote + byteIndex];
value = (value << 8) | (((long) byteValue) & 0xff);
}
// updateCrc32(ioBuffer, numberOfByteReadWrote, 8);
numberOfByteReadWrote += 8;
return value;
}
COM: <s> unmarshal from byte array current </s>
|
funcom_train/33380702 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testCapacity() throws Exception {
int iterations = 15;
Queue q = new Queue(3);
EnqueueThread et = new EnqueueThread(q, iterations, (long) 20);
DequeueThread dt = new DequeueThread(q);
et.start();
dt.start();
et.join();
dt.join();
assertTrue("expected [" + iterations + "], got [" + dt.getCount() + "]", dt.getCount() == iterations);
}
COM: <s> start two threads a reader and a writer </s>
|
funcom_train/19830148 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testSetNullDouble() throws SQLException {
assertEquals((double) 0.0, rs2.getNullDouble(), 0.0);
// Set what gets returned to something other than the default
double d = (double) 10.0;
rs2.setNullDouble(d);
assertEquals(d, rs.getDouble(1), 0.0);
assertEquals(d, rs.getDouble("column"), 0.0);
}
COM: <s> tests the set null double implementation </s>
|
funcom_train/10800225 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private DataCachePCData newPCData(OpenJPAStateManager sm) {
ClassMetaData meta = sm.getMetaData();
if (_gen != null)
return (DataCachePCData) _gen.generatePCData(sm.getObjectId(), meta);
return new DataCachePCDataImpl(sm.fetchObjectId(), meta, _mgr.selectCache(sm).getName());
}
COM: <s> create a new cacheable instance for the given state manager </s>
|
funcom_train/45485938 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getJButtonClose() {
if (jButtonClose == null) {
jButtonClose = new JButton();
jButtonClose.setBounds(new Rectangle(892, 691, 116, 23));
jButtonClose.setText("Close");
jButtonClose.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
exitHomePosition();
System.exit(0);
}
});
}
return jButtonClose;
}
COM: <s> this method initializes j button close </s>
|
funcom_train/25394676 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void updateBoundaryBox() {
double a = (outerRadius + innerRadius);
boundaryBoxMin.set(-outerRadius, -outerRadius, -(outerRadius
- innerRadius));
boundaryBoxMax.set(outerRadius, outerRadius,
(outerRadius - innerRadius));
boundaryBoxMin.set(-a, -a, -innerRadius);
boundaryBoxMax.set(a, a, innerRadius);
}
COM: <s> update bounding box of current object </s>
|
funcom_train/45542289 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void selectionChanged() {
if (getSelectionProvider() == null)
return;
ISourceReference element= computeHighlightRangeSourceReference();
if (getPreferenceStore().getBoolean(PreferenceConstants.EDITOR_SYNC_OUTLINE_ON_CURSOR_MOVE))
synchronizeOutlinePage(element);
if (fIsBreadcrumbVisible && fBreadcrumb != null && !fBreadcrumb.isActive())
setBreadcrumbInput(element);
setSelection(element, false);
if (!fSelectionChangedViaGotoAnnotation)
updateStatusLine();
fSelectionChangedViaGotoAnnotation= false;
}
COM: <s> react to changed selection </s>
|
funcom_train/20308423 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private Node convertNameToNode( String name ) {
if (name.startsWith( DIGAdapter.ANON_MARKER )) {
String anonID = name.substring( DIGAdapter.ANON_MARKER.length() );
return Node.createAnon( new AnonId( anonID ) );
}
else {
return Node.createURI( name );
}
}
COM: <s> answer the node with the given name </s>
|
funcom_train/31911105 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Rectangle2D getBounds2D() {
// System.out.println("GetBounds2D called");
Rectangle2D r2d = getBoundsRecursive(node, null);
// System.out.println("BoundsRec: " + r2d);
if (r2d == CompositeGraphicsNode.VIEWPORT) {
r2d = getViewportBounds(node, null);
// System.out.println("BoundsViewport: " + r2d);
}
return r2d;
}
COM: <s> returns the bounds of this rable in the user coordinate system </s>
|
funcom_train/30218086 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void onFault(WSRMMessage msg, Throwable fault) {
try {
System.out.println
("The following message:" + util.NL +
msg.getAsString() + util.NL + util.NL +
"generated this fault:" + util.NL +
util.stackTrace(fault));
} catch (WSRMException we) {
System.out.println(Messages.get("rmMsgAsStrErr"));
}
}
COM: <s> prints soap server faults that occur within a provider </s>
|
funcom_train/26221416 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private AgentStarterInternalFrame getAgentStarterInternalFrame() {
if (agentStarterInternalFrame == null) {
agentStarterInternalFrame = new AgentStarterInternalFrame();
agentStarterInternalFrame.setBounds(new Rectangle(1 * LOW_WID, LOG_HEI, LOW_WID, 200));
}
return agentStarterInternalFrame;
}
COM: <s> this method initializes agent starter internal frame </s>
|
funcom_train/46435073 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public List subActivities(XComponent activity) {
java.util.Set actTypes = new HashSet();
actTypes.add(new Byte(STANDARD));
actTypes.add(new Byte(MILESTONE));
actTypes.add(new Byte(COLLECTION));
return getSubElements(activity, actTypes, true);
}
COM: <s> returns the subactivities with outline level greater with 1 of a collection activity </s>
|
funcom_train/3133047 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void expand(int capacity) throws IOException {
if(capacity > limit) {
throw new BufferException("Capacity limit %s exceeded", limit);
}
int resize = buffer.length * 2;
int size = Math.max(capacity, resize);
byte[] temp = new byte[size];
System.arraycopy(buffer, 0, temp, 0, count);
buffer = temp;
}
COM: <s> this is used to ensure that there is enough space in the buffer </s>
|
funcom_train/23853168 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private int calculateDelta(IRingSet ringAssembly) {
int nr = ringAssembly.getAtomContainerCount(); // number of rings
int nrrb = 0; //number of bonds being a member of more than one ring
for (IBond bond : mol.bonds()) {
//bond is member of more than one ring
if (ringAssembly.getRings(bond).getAtomContainerCount() > 1) {
nrrb++;
}
}
return((nrrb - (nr - 1)));
}
COM: <s> calculates delta to prioritize bridged rings </s>
|
funcom_train/16630135 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JTextField getText_db_pw() {
if (text_db_pw == null) {
text_db_pw = new JPasswordField();
text_db_pw.setText("hase123");
text_db_pw.setLocation(new Point(152, 89));
text_db_pw.setSize(new Dimension(148, 23));
}
return text_db_pw;
}
COM: <s> this method initializes text db pw </s>
|
funcom_train/32783708 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void paintBox(final UnitView box, final Graphics2D graphics, final OrganigramLayout orgLay) {
boxRender.paint(graphics, box, orgLay);
if (box.hasChildren()) {
lineRender.paint(graphics, box, orgLay);
// Draw the children boxes.
for (final UnitView child : box) {
paintBox(child, graphics, orgLay);
}
}
}
COM: <s> paint the organigram box </s>
|
funcom_train/9887601 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void checkReadInProgressState() throws Exception {
if (( m_numbersRead + 1 ) > m_dims.getDimX() * m_dims.getDimY())
throw new Exception("Error reading matrix data. Has read more data than dims allow: " +
"read: " + m_numbersRead );
}
COM: <s> checkes if the matrix is overflow </s>
|
funcom_train/173324 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void run() {
IStructuredSelection selection = getStructuredSelection();
if (selection == null || selection.isEmpty() || clipboard == null)
return;
List list = selection.toList();
IMarker[] markers = new IMarker[list.size()];
list.toArray(markers);
setClipboard(markers, createMarkerReport(markers));
}
COM: <s> copies the selected imarker objects to the clipboard </s>
|
funcom_train/19739516 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getBtnReabrir() {
if (btnReabrir == null) {
btnReabrir = new JButton();
btnReabrir.setBounds(new Rectangle(21, 211, 90, 27));
btnReabrir.setText("Reabrir");
btnReabrir.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e)
{
String mensaje = txtDescripcion.getText();
IUsuario usuario = principal.darLogin();
principal.ReabrirTicket(ticket, mensaje,usuario );
dispose();
}
});
}
return btnReabrir;
}
COM: <s> this method initializes btn reabrir </s>
|
funcom_train/51093465 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected boolean parseEDICT(){
ParserResultsWrapper EDICTresults = parseEDICTStyleDictionary( isr_dictionary );
L1StringMap = EDICTresults.L1StringMap;
L2StringMap = EDICTresults.L2StringMap;
if (EDICTresults.L1StringMap == null ||
EDICTresults.L2StringMap == null ) {
return false;
} // end of if (L1StringMap == null)
else {
this.j3.addDictionary( this, sEDICT, sEDICT );
return true;
}
}
COM: <s> code parse edict code parses the current good dictionary file </s>
|
funcom_train/19320385 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int getTextIndent(final FObj fobj, final FoContext context) {
final PdTextIndent property = (PdTextIndent) getProperty(
FoProperty.TEXT_INDENT);
if (property != null) {
return property.getValue(context, fobj);
}
return PdTextIndent.getValueNoInstance(context, fobj);
}
COM: <s> returns the text indent property </s>
|
funcom_train/49704431 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected ASort generateSort(final Vector sortVec) {
if (null == sortVec || 0 == sortVec.size()) {
return null;
} else {
ASort lastSort = null;
for (int i = sortVec.size() - 1 ; i >= 0; i--) {
lastSort = generateSingleSort((Vector) sortVec.elementAt(i), lastSort);
}
return lastSort;
}
}
COM: <s> returns a hounder sort from the vector representation of filters </s>
|
funcom_train/31931079 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private String label(String string) {
StringBuffer label = new StringBuffer(string.trim());
for (int i = label.length() - 1; i < LABEL_LENGTH; i++) {
label.append(SPACE);
}
label.append(COLON);
label.append(SPACE);
return label.toString();
}
COM: <s> create a formatted label for the code string code </s>
|
funcom_train/34758323 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean isConnectionOK() {
boolean ok = true;
if (testQuery != null) {
try {
con.createStatement().executeQuery("select dummy from dual"); //"select count(*) from tab");
} catch (SQLException e) {
ok = false;
CoreFactory.getLogger().exception(this,e);
//e.printStackTrace();
}
}
return ok;
}
COM: <s> checks if the i sac db connection is ok </s>
|
funcom_train/3866878 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int getIndexOfChild(Object parent, Object child) {
TestSuite suite= isTestSuite(parent);
if (suite != null) {
int i= 0;
for (Enumeration e= suite.tests(); e.hasMoreElements(); i++) {
if (child.equals((Test)e.nextElement()))
return i;
}
}
return -1;
}
COM: <s> gets the index of a test in a test suite </s>
|
funcom_train/7518181 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void save(Servico entity) {
EntityManagerHelper.log("saving Servico instance", Level.INFO, null);
try {
getEntityManager().persist(entity);
EntityManagerHelper.log("save successful", Level.INFO, null);
} catch (RuntimeException re) {
EntityManagerHelper.log("save failed", Level.SEVERE, re);
throw re;
}
}
COM: <s> perform an initial save of a previously unsaved servico entity </s>
|
funcom_train/20440070 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addStaggerLocPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_ESMFField_staggerLoc_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_ESMFField_staggerLoc_feature", "_UI_ESMFField_type"),
ESMFPackage.Literals.ESMF_FIELD__STAGGER_LOC,
true,
false,
false,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
null,
null));
}
COM: <s> this adds a property descriptor for the stagger loc feature </s>
|
funcom_train/35228796 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Class getColumnClass(int columnIndex) {
if (rows == null || rows.isEmpty()) {
return super.getColumnClass(columnIndex);
}
if (colClassesCache[columnIndex] != null) {
return colClassesCache[columnIndex];
}
return getPropertyType(columnIndex);
}
COM: <s> returns column class </s>
|
funcom_train/1812500 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void grow(int units) {
int newSize = units + buffer.length + FOLGA;
if (logger.isLoggable(Level.FINER)) {
logger.finer("Increasing buffer. The new size is: " + newSize);
}
byte[] newHeader = new byte[newSize];
int newPos = newSize - (buffer.length - cursor);
System.arraycopy(buffer, cursor, newHeader, newPos, buffer.length - cursor);
this.buffer = newHeader;
this.cursor = newPos;
}
COM: <s> increases buffer length in the units specified to fit more headers </s>
|
funcom_train/25607083 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private BrowseItem convertJSON(JSONObject jsonObject) throws CrossPatherException {
BrowseItem browseItem = null;
try {
browseItem = new BrowseItem(jsonObject.getBoolean(BrowseItem.JSON_FILE_KEY),
jsonObject.getString(BrowseItem.JSON_NAME_KEY), jsonObject.getString(BrowseItem.JSON_ABSOLUTEPATH_KEY),
jsonObject.getLong(BrowseItem.JSON_LENGTH_KEY));
} catch (JSONException e) {
throw ExceptionFactory.createException(Constants.ERROR_CODES.INVALID_JSON_CONTENT, e);
}
return browseItem;
}
COM: <s> converts the passed jsonobject into browse item </s>
|
funcom_train/43391699 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void initDatabasePropertyes(HttpServletRequest request){
List<GuseServiceBean> services=DH.getI().getAllGuseService();
for(GuseServiceBean t: services){
for(String p:propertyKeys){
manageDataBaseProperty(t, p, request.getParameter(p));
}
}
}
COM: <s> modifying or creating service properties based on the received database parameters </s>
|
funcom_train/8249203 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void afterPropertiesSet() throws Exception {
if(calendarDao == null) {
throw new ExceptionInInitializerError(CALENDAR_MANAGER_IMPL_NEEDS_CALENDAR_DAO);
} else if(log.isDebugEnabled()) {
log.debug("Class of CalendarDao set by Spring: " + calendarDao.getClass());
}
if(daoFactory == null) {
throw new ExceptionInInitializerError("CalendarManagerImpl needs a DaoFactory");
}
}
COM: <s> checks if all properties are corectly set up </s>
|
funcom_train/10705146 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void writeStatement(Statement oldStat) {
if (oldStat == null) {
throw new NullPointerException();
}
Statement newStat = createNewStatement(oldStat);
try {
// execute newStat
newStat.execute();
} catch (Exception e) {
listener.exceptionThrown(new Exception(
"failed to write statement: " + oldStat, e)); //$NON-NLS-1$
}
}
COM: <s> write a statement of old objects </s>
|
funcom_train/39537047 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int getAuthorizationLevelForView(String viewPath){
int authorizationLevel=0;
//getting the element corresponding to the provided view path
Element viewElement=getElement(viewPath);
//getting the authorization level for the view
try{
authorizationLevel=Integer.parseInt(
viewElement.getAttribute(viewAuthorizationLevelAtt));
}catch (Exception ex){}
return authorizationLevel;
}
COM: <s> returns the authorization level for the view denoted by the provided view path </s>
|
funcom_train/2254410 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testCase3() throws Exception {
for(int i = 1; i <= 6; i++) {
WebConversation wc = new WebConversation();
WebResponse wr = wc.getResponse("http://localhost:8080/controller/rest/polling/96e79218965eb72c92a549dd5a330112/3");
logger.info("The " + i + " result was : \n" + wr.getText());
}
}
COM: <s> b situation3 b br br </s>
|
funcom_train/28212013 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JPanel getJPanel31() {
if (jPanel31 == null) {
jPanel31 = new JPanel();
jPanel31.setLayout(new GridBagLayout());
jPanel31.setBorder(BorderFactory
.createBevelBorder(BevelBorder.RAISED));
jPanel31.setLocation(new Point(221, 5));
jPanel31.setSize(new Dimension(4, 25));
jPanel31.setBackground(Color.gray);
}
return jPanel31;
}
COM: <s> this method initializes j panel31 </s>
|
funcom_train/18645763 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void initializeFullId() {
StringBuffer ret=new StringBuffer(ID_PREFIX);
if (m_tokens != null && m_values != null &&
m_tokens.length == m_values.length) {
for (int i=0; i < m_tokens.length; i++) {
if (i > 0) {
ret.append(TOKEN_SEPARATOR);
}
ret.append(m_tokens[i]);
ret.append(VALUE_SEPARATOR);
ret.append(m_values[i].toString());
}
}
ret.append(ID_SUFFIX);
m_fullId = ret.toString();
}
COM: <s> this method initializes the full id field </s>
|
funcom_train/23307011 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Attributes getAttributes() {
Attributes grp = new BasicAttributes(true);
grp.put( PREFIX_NAME, givenGroupName );
//posixGrp.put( GIDNUMBER, givenGroupId );
//posixGrp.put( PASSWORD, givenPassword );
grp.put( OBJECTCLASS, OBJECT_CLASS_TOP);
Attribute attr = grp.get( OBJECTCLASS );
attr.add( OBJECT_CLASS_GROUPOFURLS );
grp.put(attr);
return grp;
}
COM: <s> get the attributes of the posix group </s>
|
funcom_train/34109860 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setUserHome() {
if (nodePath!=null && !nodePath.equals("")) {
// ServiceDefTarget endPoint = (ServiceDefTarget) bookmarkService;
// endPoint.setServiceEntryPoint(Config.OKMBookmarkService);
// bookmarkService.setUserHome(nodePath, callbackSetUserHome);
}
}
COM: <s> sets the user home </s>
|
funcom_train/28153858 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void visitTryFinallyStatement(/* @non_null */JTryFinallyStatement self) {
self.tryClause().accept(this);
JBlock newTryClause = (JBlock) this.getStack().pop();
self.finallyClause().accept(this);
JBlock newFinallyClause = (JBlock) this.getStack().pop();
JTryFinallyStatement newSelf = new JTryFinallyStatement(self.getTokenReference(), newTryClause, newFinallyClause, self.getComments());
this.getStack().push(newSelf);
}
COM: <s> visits the given try finally statement </s>
|
funcom_train/10942367 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void addAlias(String entityAlias, String name, String field, String colAlias, Boolean primKey, Boolean groupBy, String function) {
addAlias(entityAlias, name, field, colAlias, primKey, groupBy, function, null, null);
}
COM: <s> add an alias full detail </s>
|
funcom_train/37200949 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void randomize(Random rand) {
// random bias
b = LAVector.gaussianNoise(size(), rand);
// random incoming sigma weights
for (Enumeration i = in.elements() ; i.hasMoreElements() ;) {
BPConnection c = (BPConnection)i.nextElement();
c.randomize(rand);
}
// existing squared errors are invalid
sqrerrs = null;
}
COM: <s> randomizes biases and weights on this layer to values normally </s>
|
funcom_train/46498469 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JScrollPane getJScrollPaneConsole() {
if (jScrollPaneConsole == null) {
jScrollPaneConsole = new JScrollPane();
jScrollPaneConsole.setAutoscrolls(true);
jScrollPaneConsole.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
jScrollPaneConsole.setViewportView(getJTextAreaConsole());
jScrollPaneConsole.setMaximumSize(new Dimension(2000,2000));
}
return jScrollPaneConsole;
}
COM: <s> this method initializes j scroll pane console </s>
|
funcom_train/38301642 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object getValueAt(int row, int column) {
Vector v = (Vector)getDataVector().elementAt(row);
String result = "<?>";
if (column == 0) {
result = (String)v.get(0);
}
if (column == 1) {
result = (String)v.get(1);
}
return result;
}
COM: <s> gets the value at attribute of the statistics table model object </s>
|
funcom_train/31359586 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean getSensitivity(int buttonNo, int selectedRow){
ComponentModel child = null;
if (selectedRow >= 0)
child = dataModel.get(selectedRow);
if (buttonNo < 0 || buttonNo >= reorder.length)
return false;
switch (reorder[buttonNo]){
case UPLOAD:
return true;
case REMOVE:
return selectedRow >= 0 && !child.isStarted() &&
!child.table.get("TYPE").equals("BASE");
default:
return selectedRow >= 0;
}
}
COM: <s> is this button pressable </s>
|
funcom_train/50613746 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setModified( boolean modified ) {
if ( this.modified == modified )
return;
if ( modified ) {
getTab().setTitleAt( getIndexOfEditor( editor ), name + "*" );
toolbar_commit.setEnabled( true );
} else {
getTab().setTitleAt( getIndexOfEditor( editor ), name );
}
this.modified = modified;
}
COM: <s> sets the modified property of the document being </s>
|
funcom_train/33480344 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Command getOkCommand() {
if (okCommand == null) {//GEN-END:|84-getter|0|84-preInit
// write pre-init user code here
okCommand = new Command("Ok", Command.OK, 0);//GEN-LINE:|84-getter|1|84-postInit
// write post-init user code here
}//GEN-BEGIN:|84-getter|2|
return okCommand;
}
COM: <s> returns an initiliazed instance of ok command component </s>
|
funcom_train/22950069 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean checkLayerTypeConsistency(LayerType layerType){
NeuronType neuronType = HelpingFunctions.determineNeuronType(layerType);
Iterator<Neuron> iterator = this.neuronsList.iterator();
while (iterator.hasNext()){
if (iterator.next().type() != neuronType) return false;
}
return true;
}
COM: <s> checks if all neurons are the same type as the layer </s>
|
funcom_train/3655041 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void addCommand(String mimeType, String cmdName, String className) {
List cmdInfoList = (List)cmdMap.get(mimeType);
if (cmdInfoList == null) {
cmdInfoList = new ArrayList();
cmdMap.put(mimeType, cmdInfoList);
}
cmdInfoList.add(0, new CommandInfo(cmdName, className));
setModified(true);
}
COM: <s> prepends a new command definition so the given class is </s>
|
funcom_train/37829258 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private double calculateChildWeight(final TreeNode child) {
double childweight = child.g + child.getHeuristic(goalNode);
// Prefer nodes that do not result in direction change
if (parent != null) {
final int incx = parent.x - x;
final int incy = parent.y - y;
final int incx2 = x - child.x;
final int incy2 = y - child.y;
if ((incx == incx2) && (incy == incy2)) {
childweight -= STRAIGHT_PATH_PREFERENCE_FACTOR;
}
}
return childweight;
}
COM: <s> calculate node weight for a child node </s>
|
funcom_train/3416531 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public PrintWriter format(String format, Object ... args) {
try {
synchronized (lock) {
ensureOpen();
if ((formatter == null)
|| (formatter.locale() != Locale.getDefault()))
formatter = new Formatter(this);
formatter.format(Locale.getDefault(), format, args);
if (autoFlush)
out.flush();
}
} catch (InterruptedIOException x) {
Thread.currentThread().interrupt();
} catch (IOException x) {
trouble = true;
}
return this;
}
COM: <s> writes a formatted string to this writer using the specified format </s>
|
funcom_train/41979455 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void buildPopup (JDialog popup, JProgressBar bar) {
bar.setValue (0);
bar.setStringPainted (true);
popup.setTitle ("Generating...");
popup.setLocation (400, 350);
popup.add (bar);
popup.pack ();
popup.setVisible (true);
popup.setAlwaysOnTop (true);
}
COM: <s> builds a popup window that shows the progress of the puzzle generation </s>
|
funcom_train/35357053 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void push(Image image) throws jjil.core.Error {
if (!(image instanceof Gray8Image)) {
throw new Error(
Error.PACKAGE.ALGORITHM,
ErrorCodes.IMAGE_NOT_GRAY8IMAGE,
image.toString(),
null,
null);
}
super.setOutput(
new Gray8OffsetImage(doWarp((Gray8Image) image),
this.nXOffset,
this.nYOffset));
}
COM: <s> affine warp of an image </s>
|
funcom_train/11735187 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void addVirtualItemStateProvider(VirtualItemStateProvider prov) {
VirtualItemStateProvider[] provs =
new VirtualItemStateProvider[virtualProviders.length + 1];
System.arraycopy(virtualProviders, 0, provs, 0, virtualProviders.length);
provs[virtualProviders.length] = prov;
virtualProviders = provs;
prov.addListener(this);
}
COM: <s> adds a new virtual item state provider </s>
|
funcom_train/1719945 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean matchName(String regexp) throws IllegalArgumentException {
if (StringUtil.isEmpty(regexp)) {
throw new IllegalArgumentException("Can't perform regular expression since the given input is empty. Check the Method body velocity code: regexp='" + regexp + "'");
}
return methodName.matches(regexp);
}
COM: <s> performs a regular expression matching the methodname </s>
|
funcom_train/20774690 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setTailTrimmingPercents(int tailTrimmingPercents) {
int old = this.tailTrimmingPercents;
this.tailTrimmingPercents = tailTrimmingPercents;
getPrefs().putInt("GestureBF2D.tailTrimmingPercents",tailTrimmingPercents);
support.firePropertyChange("tailTrimmingPercents",old,this.tailTrimmingPercents);
}
COM: <s> sets tail trimming percents </s>
|
funcom_train/9978525 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void removeDefaultInterceptorRef(Element ref) {
pContext.getProject().fireChangeEvent(ProjectChangeListener.EventType.PluginSettingsWillChange, Struts2Tools.pluginID);
ref.getParentNode().removeChild(ref);
pContext.getProject().fireChangeEvent(ProjectChangeListener.EventType.PluginSettingsChanged, Struts2Tools.pluginID);
}
COM: <s> removes a default interceptor ref </s>
|
funcom_train/17783321 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void init(IWorkbench workbench, IStructuredSelection selection) {
m_workbench = workbench;
m_selection = selection;
setWindowTitle("New Scribble Wizard");
java.util.List<Object> notations=
RegistryFactory.getRegistry().getExtensions(
org.scribble.model.Notation.class, null);
for (int i=0; i < notations.size(); i++) {
org.scribble.model.Notation n=
(org.scribble.model.Notation)notations.get(i);
if (n.useScribbleEditor()) {
m_notations.add(n);
}
}
}
COM: <s> this method initializes the wizard </s>
|
funcom_train/2801632 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void removeEventHandler(String pHandlerName) throws RaccoonException {
IEventHandler handler = mMsgCallback.removeEventHandler(pHandlerName);
if (handler == null) {
throw new RaccoonException("Handler not found:" + pHandlerName);
}
if (handler.isRunning()) {
handler.stop();
}
}
COM: <s> removes an event handler from this subscriber </s>
|
funcom_train/37017876 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected String getValuesString(String[] values){
String valuesString= "";
for(int i= 0; i < values.length; i++){
valuesString+= "," + values[i];
}
if(valuesString.length() > 0){
valuesString= valuesString.substring(1);
}
return valuesString;
}
COM: <s> get the string of values parameters </s>
|
funcom_train/31842829 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testLogin() {
assertFalse(tm1.isLoggedOnInPastHour());
tm1 = tm1.login(password);
assertNotNull("Login failed when it should have sicceeded", tm1);
assertTrue("After successful login team member should be logged in", tm1.isLoggedOnInPastHour());
tm1 = tm1.logout();
assertFalse("After logout team member should be logged out", tm1.isLoggedOnInPastHour());
}
COM: <s> test member test test login </s>
|
funcom_train/50858460 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean checkPermition(Context context, int permition) {
boolean result = false;
if((permition > 0) && (permition < 64)) {
com.zahariev.jframe.permitions.User userProfile = (com.zahariev.jframe.permitions.User)context.getSessionObject(JFrameHTTPServlet.USER_PROFILE);
result = userProfile.hasPermition(permition);
}
return result;
}
COM: <s> checks permition for current command </s>
|
funcom_train/41163102 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void delete(ToDictionaryType entity) {
EntityManagerHelper.log("deleting ToDictionaryType instance", Level.INFO, null);
try {
entity = getEntityManager().getReference(ToDictionaryType.class, entity.getDictionaryTypeId());
getEntityManager().remove(entity);
EntityManagerHelper.log("delete successful", Level.INFO, null);
} catch (RuntimeException re) {
EntityManagerHelper.log("delete failed", Level.SEVERE, re);
throw re;
}
}
COM: <s> delete a persistent to dictionary type entity </s>
|
funcom_train/44496294 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setColumns(String[] columns) {
this.columnsCount = columns.length;
this.columns = new String[columnsCount];
for (int i = 0; i < columnsCount; i++) {
this.columns[i] = columns[i];
}
this.rows = new ArrayList();
}
COM: <s> set the code columns code that were queried </s>
|
funcom_train/37206503 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Element parseXml(String xml) throws Exception{
Element root = null;
// Create a builder factory
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
factory.setValidating(false);
// Create the builder and parse the file
Document doc = factory.newDocumentBuilder().parse(new InputSource(new StringReader(xml)));
root = doc.getDocumentElement();
return root;
}
COM: <s> this method is used to parse the xml </s>
|
funcom_train/9810167 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public long compareTo(Date current) {
long startTime = getStartTime().getTime();
long endTime = getEndTime().getTime() - 1000;
long curTime = current.getTime();
long dxTime = startTime - curTime;
if (dxTime > 0) {
return dxTime;
}
dxTime = endTime - curTime;
if (dxTime < 0) {
return dxTime;
}
return 0;
}
COM: <s> compares this program event to the provided date </s>
|
funcom_train/42886682 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public TupleSet range(Tuple from, Tuple to) {
if (from.arity()!=to.arity())
throw new IllegalArgumentException("from.arity!=to.arity");
if (!(from.universe().equals(universe)&&to.universe().equals(universe)))
throw new IllegalArgumentException("from.universe != this.universe || to.universe != this.universe");
return new TupleSet(universe, from.arity(), from.index(), to.index());
}
COM: <s> returns a tuple set that contains all tuples between code from code </s>
|
funcom_train/48775529 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String resolveRelativeUri(String uri) {
// sometimes we get uri's massaged from File(String), so check for
// a root directory deperator char
if (uri.startsWith("/") || uri.startsWith(File.separator)) {
return uri;
} else {
return uriBase + uri;
}
}
COM: <s> get the full value of a uri relative to this compilations context </s>
|
funcom_train/44873067 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setValues(Value[] v) {
for (int i = 0; i < values.length; i++) {
if (values[i] instanceof QueueableValue) {
QueueableValue qv = (QueueableValue) values[i];
qv.removeQueueableValueUpdateListener(this);
}
}
values = v;
for (int i = 0; i < v.length; i++) {
if (v[i] instanceof QueueableValue) {
QueueableValue qv = (QueueableValue) v[i];
qv.addQueueableValueUpdateListener(this);
}
}
changed = true;
needsRedraw();
}
COM: <s> set the values that are substituted for single s in the string </s>
|
funcom_train/27755065 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setCross(boolean horz, boolean vert) {
horzCross = horz;
vertCross = vert;
vertCrossColor = null;
horzCrossColor = null;
if (horzCross)
horzCrossColor = baseEditor.getHorzCross();
if (vertCross)
vertCrossColor = baseEditor.getVertCross();
}
COM: <s> specifies visibility of cross at the cursor position </s>
|
funcom_train/32137962 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object run(Object args) throws Exception {
Display display = PlatformUI.createDisplay();
if(!SystemTapGUISettings.settingsFolder.exists())
SystemTapGUISettings.settingsFolder.mkdir();
try {
int returnCode = PlatformUI.createAndRunWorkbench(display, new ApplicationWorkbenchAdvisor());
if (returnCode == PlatformUI.RETURN_RESTART) {
return IPlatformRunnable.EXIT_RESTART;
}
return IPlatformRunnable.EXIT_OK;
} finally {
display.dispose();
}
}
COM: <s> instantiates the workbench and creats a settings folder if it does not exist </s>
|
funcom_train/13916026 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: final protected void initFile() throws IOException {
if (this.pipeSupported) {
// instantiate process
this.mActiveLoaderThread = new LoaderProcess(this.getLoadStatement(), Thread.currentThread());
this.mActiveLoaderThread.start();
}
this.mTarget = new FileOutputStream(this.msDataFile);
this.mBuffer = new BufferedOutputStream(this.mTarget);
this.mWriter = new DataOutputStream(this.mBuffer);
this.mFileOpen = true;
}
COM: <s> inits the file </s>
|
funcom_train/25196460 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Entry makeEntry(String type, String key, Locator locator) {
Entry entry = new Entry(locator);
entry.setKey(key);
entry.setType(type);
entries.add(entry);
entryHash.put(key.toLowerCase(Locale.ENGLISH), entry);
makeEntryHook.update(this, entry);
return entry;
}
COM: <s> creates a new entry for this database </s>
|
funcom_train/3764042 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testloadPlugins_InterrestedInFeedback() {
try {
assertNotNull("InterrestedInFeedback plugins list must to be initialized",
PluginManager.getInterestedInFeedback());
assertTrue(PluginManager.getInterestedInFeedback().length != 0);
} catch (RpException e) {
e.printStackTrace();
fail();
}
}
COM: <s> test the get interrested in feedback method of the plugin manager </s>
|
funcom_train/45553583 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void sensingLoop() {
int currentTemp;
try {
currentTemp =
(int) Math.floor(temperatureSensor.getCelsius() + 0.5d);
// System.out.println("Updating temperature: Current="
// + currentTemp + "Cº (rounded value).");
updateTemperatureLEDs(currentTemp);
} catch (IOException theException) {
theException.printStackTrace();
notifyDestroyed();
}
}
COM: <s> loop to periodically read the local temperature and display it on </s>
|
funcom_train/22495462 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void setupViewport(final Context context) {
// Avoid division by zero
int h = internalHeight;
if (h == 0) {
h = 1;
}
logger.info("Setting up viewport (0,0) (" + internalWidth + "," + h + ")");
// Reset the current viewport
renderer.glViewport(0, 0, internalWidth, h);
viewPortDirty = false;
}
COM: <s> sets up viewport </s>
|
funcom_train/6508228 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void showActionMessage(String s){
ausgabe.getView().logFloatPane.addMessage( s );
// statusLog.addMessage(s);
synchronized(this){
try {
wait(SHOW_MESSAGE_DELAY);
}
catch (InterruptedException ie){
CAT.debug("interrupted!");
}
}
}
COM: <s> show the sinlge line action message that came from the server </s>
|
funcom_train/31188453 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testHtmlOnly() {
DoxygenTask.Property thisProp = new DoxygenTask.Property();
try {
doxygenTask.execute();
assertEquals(true, htmlDir.exists());
deleteDir(htmlDir);
} catch (BuildException ex) {
System.out.println("Error executing doxygen task " + ex);
}
}
COM: <s> test case for generating html and not </s>
|
funcom_train/29399556 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void initialize(Problem p, Graph<T> graph, List<T> order) {
super.initialize(p, graph);
graphNavigator = graph.getNavigator();
boundaries = graph.getRoots();
traversalOrder = order;
Streams.trace.trace("Traversal order: " + traversalOrder);
}
COM: <s> initializes this solver with the given dataflow problem graph and traversal order </s>
|
funcom_train/37006247 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void close() throws SQLException {
Iterator it = m_preparedStatements.values().iterator();
while (it.hasNext()) {
List psl = (List) it.next();
Iterator itl = psl.iterator();
while (itl.hasNext()) {
PreparedStatement ps = (PreparedStatement)itl.next();
ps.close();
}
it.remove();
}
}
COM: <s> close all prepared statements </s>
|
funcom_train/33880933 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean rotateImageBy(int degrees) {
int newDegrees = getDegreesRotated() + degrees;
setDegreesRotated(newDegrees);
// setting this to zero will force the call to checkCursor to generate fresh thumbs
mMiniThumbMagic = 0;
try {
mContainer.checkThumbnail(this, mContainer.getCursor(), this.getRow());
} catch (IOException e) {
// Ignore inability to store mini thumbnail.
}
return true;
}
COM: <s> save the rotated image by updating the exif orientation tag </s>
|
funcom_train/12587312 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Catalog loadRemoteCatalog(URL catalogHref) throws CatalogRemoteException {
Catalog catalog = m_cache.get(catalogHref.toExternalForm());
if (catalog == null) {
catalog = m_catalogRepositoryStore
.getCatalogFromLocation(catalogHref);
if (catalog == null) {
catalog = loadCatalog(catalogHref);
m_catalogRepositoryStore.save(catalog, catalogHref);
}
m_cache.put(catalogHref.toExternalForm(), catalog);
}
return catalog;
}
COM: <s> load remote catalog from cache </s>
|
funcom_train/12188742 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testPushVariableStackFrame() throws Exception {
assertTrue("Stack frame count should be 0",
variables.getStackFrameCount() == 0);
variables.pushStackFrame();
assertTrue("Stack frame should count should increment by 1",
variables.getStackFrameCount() == 1);
}
COM: <s> test the push variable stack frame method </s>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.