__key__
stringlengths 16
21
| __url__
stringclasses 1
value | txt
stringlengths 183
1.2k
|
---|---|---|
funcom_train/41252310 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private ListListener<L> leftListener = new ListAdapter<L>() {
public void elementRemoved(ListEvent<L> e) {
processElementRemoved(e,
leftToRightMap,
rightToLeftMap,
new AssociatorNotifier<L, R>() {
public void processLink(L left, R right) {
removeAssociation(left, right);
}
});
}
};
COM: <s> the listener to the left collection </s>
|
funcom_train/3409982 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean match(MimeType type) {
if (type == null)
return false;
return primaryType.equals(type.getPrimaryType())
&& (subType.equals("*")
|| type.getSubType().equals("*")
|| (subType.equals(type.getSubType())));
}
COM: <s> returns code true code if the primary type and the </s>
|
funcom_train/20767690 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void set(Enum newState) {
if (currentState == getInitial()) {
currentState = newState;
timeChanged = System.currentTimeMillis();
wasChanged = true;
}else if (newState != currentState) {
previousState = currentState;
currentState = newState;
timeChanged = System.currentTimeMillis();
wasChanged = true;
}else {
wasChanged = false;
}
}
COM: <s> set a possibly new current state </s>
|
funcom_train/22639423 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public ClassDeps getDepsForClass(String className) {
className = checkType(className);
if (className == null) {
return null;
}
if (data.containsKey(className)) {
return data.get(className);
} else {
ClassDeps deps = new ClassDeps(className);
data.put(className, deps);
return deps;
}
}
COM: <s> use this to add dependencies to a class </s>
|
funcom_train/17676327 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void dump() {
for (int i = 0; i < size; i++) {
ClassMetaData c = oids[i].getAvailableClassMetaData();
System.out.println("[" + i + "] = " + oids[i] +
" rgi " + c.referenceGraphIndex + " index " + c.index);
}
}
COM: <s> dump to sysout </s>
|
funcom_train/45450510 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean equals(final Object o) {
if (o == this)
return true;
if (!(o instanceof Name))
return false;
Name nm = (Name) o;
return this.givenName.equals(nm.getGivenName()) && this.middleName.equals(nm.getMiddleName())
&& this.surname.equals(nm.getSurname());
}
COM: <s> overrides equals while obeying the general contract </s>
|
funcom_train/22550878 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void handleConnect(Socket socket) {
// if we get the callback before the Sockets.connect call returned,
// then _socket will be null, but the rest of the code needs it.
// so we set it here just incase -- it's no big deal if it gets overwritten
// later.
_socket = socket;
ThreadExecutor.startThread(this, "Handshaking");
}
COM: <s> we got a connection </s>
|
funcom_train/40658394 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String getVersionString() {
String rawVersionString = getRawVersionString();
return rawVersionString == null ? null
: rawVersionString.replaceAll("\\D*(\\d+)", "$1,").replaceFirst(",$", "");
}
COM: <s> returns a generic string of comma delimited version numbers e </s>
|
funcom_train/39383679 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void removeTarget(String target) throws InvalidTargetException {
if (target == null || target.equals("")) {
throw new InvalidTargetException(
"No Target selected, Please select a Target to remove.");
}
nameTargetMap.remove(target);
logger.info("Removed Target " + target);
}
COM: <s> removes the target from the application environment target set </s>
|
funcom_train/38543430 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Long getElapsedTime() {
Long result = null;
if (!(this.startDate == null)) {
if (!(this.endDate == null)) {
result = new Long(this.endDate.getTime()
- this.startDate.getTime());
} else {
result = new Long(new Date().getTime()
- this.startDate.getTime());
}
}
return result;
}
COM: <s> provides the elapsed time since the task started </s>
|
funcom_train/9642129 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private boolean isNonEmptyOntology(Ontology ontology) {
return !((ontology.getAttributes() == null)
|| (ontology.getAttributes().isEmpty())
|| (ontology.getDataView() == null)
|| (ontology.getDataView().dataset() == null) || (ontology
.getDataView().size() == 0));
}
COM: <s> checks if is non empty ontology </s>
|
funcom_train/49456162 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void preflight(List<?> input) {
for (Object o : input) {
if (o instanceof RaciRuleInference) {
((RaciRuleInference) o).setRaciFilter(raciRulesFilter);
} else if (! (o instanceof RaciRuleCheck)) {
_logger.warn("Unknown rule input type ("+o.getClass().getName()+")");
}
}
}
COM: <s> ensure that everything is set </s>
|
funcom_train/5437351 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setFilter(Filter filter) throws PcapException {
if(filter == null) {
throw new NullPointerException("Filter is null.");
}
checkWrapper();
Filter old = this.filter;
try {
this.filter = filter;
wrapper.setFilter(this);
} catch (PcapException e) {
filter = old;
throw e;
}
}
COM: <s> set the filter on this network interface </s>
|
funcom_train/17394752 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean readBoolean() throws IOException {
int token = tokenizer.nextToken();
if (token == StreamTokenizer.TT_NUMBER) {
return ((int) tokenizer.nval) == 1;
}
String msg = "Integer expected in line: " + tokenizer.lineno();
throw new IOException(msg);
}
COM: <s> reads a boolean from the input stream </s>
|
funcom_train/41379842 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void dispose() {
fCodeScanner= null;
fPartitionScanner= null;
if (fColorManager != null) {
fColorManager.dispose();
fColorManager= null;
}
if (fPreferenceStore != null) {
fPreferenceStore.removePropertyChangeListener(fPreferenceListener);
fPreferenceStore= null;
if (fCorePreferenceStore != null) {
fCorePreferenceStore.removePropertyChangeListener(fPreferenceListener);
fCorePreferenceStore= null;
}
fPreferenceListener= null;
}
}
COM: <s> disposes all members of this tools collection </s>
|
funcom_train/17398764 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private Sphere readSphere(final XMLElement element) {
if (element == null) {
return null;
}
float radius = Float.parseFloat(
element.getAttributes().get("radius"));
Vector location = readVectorBeneath(
element.getSubElement("location"));
IShader shader = this.readSurface(element.getSubElement("surface"));
Vector pole = this.readVectorBeneath(element.getSubElement("pole"));
Vector equator =
this.readVectorBeneath(element.getSubElement("equator"));
return new Sphere(shader, location, pole, equator, radius);
}
COM: <s> reads a sphere from the specified xmlelement and returns it </s>
|
funcom_train/777360 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private ArrayList iterToArrayList( Iterator iter ) {
ArrayList al = new ArrayList();
while ( iter.hasNext() ) {
try {
al.add( iter.next() );
}
catch ( NoSuchElementException nsee ) {
throw new RuntimeException( "exception AID set iterator:"+
nsee.getMessage(), nsee );
}
}
return al;
}
COM: <s> convert a set represented by a leap iterator to an array list </s>
|
funcom_train/3749032 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public List getDatabaseTypes() {
if (logger.isDebugEnabled()) {
logger.debug("getDatabaseTypes() - start");
}
if (logger.isDebugEnabled()) {
logger.debug("getDatabaseTypes() - end - return value = "
+ databaseTypes);
}
return databaseTypes;
}
COM: <s> this list should correspond to </s>
|
funcom_train/2388132 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean deleteBucket () throws IOException {
final String hash = account.getHashedName();
try {
if (myBucketExists()) {
s3.deleteBucket(hash);
return true;
} else {
return false;
}
} catch (IOException anIoEx) {
throw anIoEx;
} catch (Exception anEx) {
throw new IOException("Unable to delete bucket " + account.getHashedName()+": " + anEx.getMessage());
}
}
COM: <s> tries to delete the bucket but throws an exception </s>
|
funcom_train/3289931 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String replace(scanpage sp, StringTokenizer tok) {
if (tok.hasMoreTokens()) {
String cmd=tok.nextToken();
if (cmd.equals("number")) {
int i=getNumber(sp.getSessionName());
if (i!=-1) {
return(""+i);
} else {
return("");
}
}
}
return("");
}
COM: <s> replace call when called in format mmbase builder users xxxxx </s>
|
funcom_train/37074217 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public SeqFeatureI getSeqFeat(int strand, String type) {
FeatureSetI strandFS = getFeatSetForStrand(strand);
for (int i=0; i<strandFS.size(); i++) {
SeqFeatureI grandChild = strandFS.getFeatureAt(i);
if (grandChild.getFeatureType().equals(type))
return grandChild;
}
return null; // not found
}
COM: <s> returns seq feat grandchildren tier level of type strand </s>
|
funcom_train/37808755 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void process(String input, String arg, Client client) {
if (arg != null) {
client.getServerInterface().sayToRoom(arg, input);
} else {
(new Throwable()).printStackTrace();
System.err.println("FIXME: what should I do here?");
}
}
COM: <s> invokes say to room on the local view of the chat server </s>
|
funcom_train/50208509 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: static public FlowletLabelModelPart createFlowletLabelModelPart(FlowletWithLabelModelPart flowletWithLabel) {
if (flowletWithLabel instanceof JavaTaskFlowletModelPart)
return new TaskFlowletLabelModelPart();
if (flowletWithLabel instanceof DecisionFlowletModelPart)
return new DecisionFlowletLabelModelPart();
if (flowletWithLabel instanceof TemplateFlowletModelPart)
return new TemplateFlowletLabelModelPart();
return new FlowletLabelModelPart();
}
COM: <s> creates flowlet label </s>
|
funcom_train/10508221 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void messageLogged(BuildEvent event) {
if (event.getPriority() > msgOutputLevel
|| null == event.getMessage()
|| "".equals(event.getMessage().trim())) {
return;
}
synchronized (this) {
if (null != targetName) {
out.println(StringUtils.LINE_SEP + targetName + ":");
targetName = null;
}
}
super.messageLogged(event);
}
COM: <s> logs a message for a target if it is of an appropriate </s>
|
funcom_train/2585967 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testFindMinimumRangeValue() {
CategoryDataset d1 = createCategoryDataset1();
Number min1 = DatasetUtilities.findMinimumRangeValue(d1);
assertEquals(new Double(1.0), min1);
XYDataset d2 = createXYDataset1();
Number min2 = DatasetUtilities.findMinimumRangeValue(d2);
assertEquals(new Double(100.0), min2);
}
COM: <s> some tests for the find minimum range value method </s>
|
funcom_train/10345382 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean registerOID(int[] oid, String key) {
ASN1ObjectIdentifier objectID;
String keyUC;
objectID = new ASN1ObjectIdentifier(oid);
keyUC = key.toUpperCase();
if (a2oid_.get(keyUC) != null || oid2a_.get(objectID) != null) {
return false;
}
a2oid_.put(keyUC, objectID);
oid2a_.put(objectID, keyUC);
return true;
}
COM: <s> register user defined oid key pairs which are accepted as keys of the </s>
|
funcom_train/30041012 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void ILoveYou(Digibot digibot) {
// Hey, great ! I received a love message from
// a digibot ?? Let's go for [him/her/we don't mind] !!
focusedPartner = digibot;
// Send a little answer !
focusedPartner.ILoveYouToo(this);
}
COM: <s> send a love message to a digibot </s>
|
funcom_train/18325666 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addClientRolePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_Association_clientRole_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_Association_clientRole_feature", "_UI_Association_type"),
CoremodelPackage.Literals.ASSOCIATION__CLIENT_ROLE,
true,
false,
false,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
null,
null));
}
COM: <s> this adds a property descriptor for the client role feature </s>
|
funcom_train/27973373 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void removeExpression(int index) {
subExpressions.remove(index);
booleanComboBoxes.remove(index);
// if just one expression left (and our parent is a ComplexExpressionPanel; it may be an ExpressionEditor)
if (subExpressions.size() == 1 && getParent() instanceof ComplexExpressionPanel)
{
try {
((ComplexExpressionPanel) getParent()).collapseExpression(this, (ExpressionPanel) subExpressions.get(0));
} catch (BEEJException BE) {
BE.printStackTrace();
}
}
// since stuff has changed
showPanels();
}
COM: <s> removes an expression </s>
|
funcom_train/24624602 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String getServiceWSDL() throws LemansysRuntimeException {
if(serviceWSDL!=null) {return serviceWSDL;} // Return cached WSDL
try{
// Compute only first time...
Class2WSDLExporter exporter=new Class2WSDLExporter();
serviceWSDL=exporter.export2WSDL(referredClass, "http://pippo.com");
return serviceWSDL;
} catch(Throwable e) {
e.printStackTrace();
throw new LemansysRuntimeException(e.toString());
}
}
COM: <s> return xml stream of current wsdl </s>
|
funcom_train/880671 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addDnPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(new LDAPItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_LDAPEntry_dn_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_LDAPEntry_dn_feature", "_UI_LDAPEntry_type"),
LdapPackage.eINSTANCE.getLDAPEntry_Dn(),
true,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE));
}
COM: <s> this adds a property descriptor for the dn feature </s>
|
funcom_train/13261431 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public double getLowerLimit() {
//NEW
//@author Stefano Omini
if (analyzer.isZero()) {
return 0.0;
}
//end NEW
double lower = analyzer.getMean() - analyzer.getConfInt();
// NEW Bertoli
if (analyzer.getConfInt() == 0) {
return 0;
//end NEW
}
if (lower > 0) {
// OLD
// return lower;
//NEW
//@author Stefano Omini
return lower * scaleFactor;
//end NEW
} else {
return 0;
}
}
COM: <s> gets lower limit </s>
|
funcom_train/18432756 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Size2D calculateDimensions(Graphics2D g2) {
FontMetrics fm = g2.getFontMetrics(this.font);
Rectangle2D bounds = TextUtilities.getTextBounds(this.text, g2, fm);
Size2D result = new Size2D(bounds.getWidth(), bounds.getHeight());
return result;
}
COM: <s> calculates the dimensions of the text fragment </s>
|
funcom_train/14437990 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setSelectedKey(String aKey) {
boolean found = false;
for (int i = 0;(i < getItemCount()) && !found; i++) {
Object item = getItemAt(i);
if (item instanceof CheckBoxItem) {
if (((CheckBoxItem) item).getKey().equals(aKey)) {
setSelectedIndex(i);
found = true;
}
}
}
}
COM: <s> if no item contains that key the selection remains unchanged </s>
|
funcom_train/18566363 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JButton getConfigureButton() {
if (configureButton == null) {
configureButton = new JButton();
configureButton.setIcon(configureImageIcon);
configureButton.setText("Configure");
configureButton.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent e) {
ilPool.showPreference();
}
});
}
return configureButton;
}
COM: <s> this method initializes configure button </s>
|
funcom_train/34670179 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public boolean equals(Object object) {
if (object instanceof TransactionImpl096)
{
return tid == ((TransactionImpl096) object).tid;
}
if (object instanceof Transaction)
{
final byte[] thisTid = this.getId();
final byte[] otherTid = ((Transaction) object).getId();
return Arrays.equals(thisTid, otherTid);
}
return false;
}
COM: <s> returns code true code if the argument is an instance of the same </s>
|
funcom_train/3473966 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object convertElement (StructureElement element) {
Converter converter = getConverterForElement (element);
if (converter != null) {
return converter.convertElement (element);
}
// logger.warn (language.getString ("Convert.SelectionConverter.Msg.NoConverter") + " " +
// element.getElementName ());
return null;
}
COM: <s> converts the specified element to an other representation </s>
|
funcom_train/22908758 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private Calendar convertToDate(String datum) {
// 2007-03-01T17:12:03+01:00
int day = Integer.parseInt(datum.substring(8, 10));
int month = Integer.parseInt(datum.substring(5, 7));
int year = Integer.parseInt(datum.substring(0, 4));
int hour = Integer.parseInt(datum.substring(11, 13));
int min = Integer.parseInt(datum.substring(14, 16));
Calendar cal = Calendar.getInstance();
cal.set(year, month, day, hour, min);
return cal;
}
COM: <s> utility function can be invoked if datum field is known </s>
|
funcom_train/39371457 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void item_save_selected() {
if (machTree.getCurrent() == null)
return;
try {
FileOutputStream fos = new FileOutputStream(machTree.getCurrent()
.getPath());
machTree.getCurrent().save(fos);
fos.flush();
fos.close();
} catch (Exception e) {
e.printStackTrace();
return;
}
Config.used(Config.makeRelative(machTree.getCurrent().getPath()));
rebuildRecentMI();
}
COM: <s> the user wants to save the current machine </s>
|
funcom_train/46720482 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testConstraintSpineEmpty() throws Throwable {
OPFPackage pack = createTestPackage(true,true,true,true, true);
Spine spine = pack.getSpine();
runConstraintChecks(pack,0,false,OPFConstraintViolation.Type.SPINE_EMPTY, false);
spine.clear();
runConstraintChecks(pack,1,false,OPFConstraintViolation.Type.SPINE_EMPTY, false);
}
COM: <s> constraint check empty spine </s>
|
funcom_train/34110243 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void downloadDocumentPdf() {
Log.debug("downloadDocumentPdf()");
if (isDocumentSelected()) {
Log.debug("jump to download");
Main.get().redirect = true;
Window.open(Config.OKMDownloadServlet +"?toPdf&id=" + URL.encodeComponent(getDocument().getPath()), "_self", "");
Main.get().redirect = false;
}
Log.debug("downloadDocumentPdf: void");
}
COM: <s> download document as pdf </s>
|
funcom_train/48476420 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public HandlerRegistration addFieldStateChangedHandler(com.smartgwt.client.widgets.grid.events.FieldStateChangedHandler handler) {
if(getHandlerCount(com.smartgwt.client.widgets.grid.events.FieldStateChangedEvent.getType()) == 0) setupFieldStateChangedEvent();
return doAddHandler(handler, com.smartgwt.client.widgets.grid.events.FieldStateChangedEvent.getType());
}
COM: <s> add a field state changed handler </s>
|
funcom_train/10590518 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void contextualize(Context context) throws ContextException {
ParsedContextURLProtocolHandler.setContext(
(org.apache.cocoon.environment.Context)context.get(Constants.CONTEXT_ENVIRONMENT_CONTEXT));
ParsedURL.registerHandler(new ParsedContextURLProtocolHandler());
ParsedURL.registerHandler(new ParsedResourceURLProtocolHandler());
}
COM: <s> get the context </s>
|
funcom_train/21844278 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private Configuration getConfigurationPanel() {
if (configurationPanel == null) {
configurationPanel = new Configuration();
configurationPanel.setLocation(new java.awt.Point(7,67));
configurationPanel.setSize(new java.awt.Dimension(320,230));
configurationPanel
.addInternalFrameListener(new javax.swing.event.InternalFrameAdapter() {
public void internalFrameClosed(
javax.swing.event.InternalFrameEvent e) {
isControlPanelOpened = false;
configurationPanel = null;
}
});
}
return configurationPanel;
}
COM: <s> this method initializes configuration panel </s>
|
funcom_train/28757275 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setFooterlogo(String newVal) {
if ((newVal != null && this.footerlogo != null && (newVal.compareTo(this.footerlogo) == 0)) ||
(newVal == null && this.footerlogo == null && footerlogo_is_initialized)) {
return;
}
this.footerlogo = newVal;
footerlogo_is_modified = true;
footerlogo_is_initialized = true;
}
COM: <s> setter method for footerlogo </s>
|
funcom_train/29632270 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void putFingerprintDec(byte[] iFpr) throws OpenPGPCardException{
if(iFpr.length != 20)
throw new IllegalArgumentException("Fingerprint must be exactly 20 bytes long");
putGenericData(TLV_FPR_DEC[0],TLV_FPR_DEC[1],iFpr,20);
}
COM: <s> stores the decryption key fingerprint 20 bytes on the card </s>
|
funcom_train/26199393 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void dropFilterTree(FilterTree filterToDrop){
ListIterator it = filterTrees.listIterator();
while(it.hasNext()){
if((FilterTree)it.next() == filterToDrop){
it.previous();
it.remove();
refreshLeftPane();
return;
}
}
S.out("assert: Viewer:dropFilterTree:Couldn't find filter to drop!");
}
COM: <s> removes the specified filter tree </s>
|
funcom_train/43608177 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected ConstructorCall_c reconstruct(Expr qualifier, List arguments) {
if (qualifier != this.qualifier || ! CollectionUtil.equals(arguments, this.arguments)) {
ConstructorCall_c n = (ConstructorCall_c) copy();
n.qualifier = qualifier;
n.arguments = TypedList.copyAndCheck(arguments, Expr.class, true);
return n;
}
return this;
}
COM: <s> reconstruct the constructor call </s>
|
funcom_train/26091351 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JToolBar getJToolBar() {
if (jToolBar == null) {
jToolBar = new JToolBar();
jToolBar.setBounds(new Rectangle(0, 0, 1, 1));
jToolBar.setPreferredSize(new Dimension(1, 1));
jToolBar.setEnabled(false);
jToolBar.setVisible(false);
}
return jToolBar;
}
COM: <s> this method initializes j tool bar </s>
|
funcom_train/17905470 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private void southPaneCreated() {
splitPane.setRightComponent(southTabPane);
splitPane.restoreDividerLocation();
//splitPane.setDividerLocation(defaultDividerLocation);
// if (orientation == SwingConstants.CENTER && scrollingTabPane != null) {
splitPane.setDividerSize(ApplicationConstants.SPLIT_PANE_DIVIDER_SIZE);
// }
}
COM: <s> adds the south tab pane component and </s>
|
funcom_train/13907233 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void load() {
final Map props = _config.readProperties();
final Iterator it = props.entrySet().iterator();
while (it.hasNext()) {
final Map.Entry entry = (Map.Entry) it.next();
putAlias((String) entry.getKey(), (String) entry.getValue());
}
}
COM: <s> initial load of aliases </s>
|
funcom_train/3424265 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private String resolveSystemId(String systemId, String baseURI) {
try {
return XMLEntityManager.expandSystemId(systemId, baseURI, false);
}
// In the event that resolution failed against the
// base URI, just return the system id as is. There's not
// much else we can do.
catch (URI.MalformedURIException ex) {
return systemId;
}
}
COM: <s> resolves a system identifier against a base uri </s>
|
funcom_train/37449748 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public IntactUserIF getIntactUser() {
// Session to access various session objects. This will create
//a new session if one does not exist.
HttpSession session = super.getSession( myRequest );
// Handle to the Intact User.
IntactUserIF user = super.getIntactUser( session );
if ( user == null ) {
//just set up a new user for the session
user = super.setupUser( myRequest );
}
return user;
}
COM: <s> returns the intact user value </s>
|
funcom_train/18953239 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String getAfterText() {
if (logger.isDebugEnabled()) {
logger.debug("getAfterText() - start");
}
if (logger.isDebugEnabled()) {
logger.debug("getAfterText() - end - return value = " + afterText);
}
return afterText;
}
COM: <s> text to appear after the label </s>
|
funcom_train/44496368 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void initConnectionMetadata(String driver, String url, UserInformation userInformation) throws ClassNotFoundException, SQLException {
this.url = url;
String user = userInformation.getUser();
String password = userInformation.getPassword();
Class.forName(driver);
this.connectionMetadata = DriverManager.getConnection(url, user, password);
connectionMetadata.setAutoCommit(false);
}
COM: <s> initializes the code connection code that is responsible for creating the </s>
|
funcom_train/46875510 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void debug(Object aMessage, Throwable aThrowable) {
if(isDebugEnabled())
logger.callAppenders(new LoggingEvent(this.getClass().getName(), logger, Level.DEBUG, aMessage, aThrowable));
//logger.debug(aMessage, aThrowable);
}
COM: <s> throws a debug message </s>
|
funcom_train/51107819 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void createSchema() throws Exception {
Iterator it = domain.getDataNodes().iterator();
while (it.hasNext()) {
DataNode node = (DataNode) it.next();
createSchema(node, (DataMap) node.getDataMaps().iterator().next());
}
}
COM: <s> creates all test tables in the database </s>
|
funcom_train/28471789 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testGetSubject() {
Review testReview = new Review();
String testSubj1 = "Tulpen und Narzissen";
String testSubj2 = "Guns And Trucks";
testReview.setSubject(testSubj1);
assertTrue(testSubj1.equals(testReview.getSubject()));
testReview.setSubject(testSubj2);
assertTrue(testSubj2.equals(testReview.getSubject()));
}
COM: <s> this should test the methods get subject and set subject of review </s>
|
funcom_train/50880381 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private Envelope readEnvelope(LEDataInputStream in) throws IOException{
// read the Coordinates
in.setLittleEndianMode(true);
double tempXmin = in.readDouble();
double tempYmin = in.readDouble();
double tempXmax = in.readDouble();
double tempYmax = in.readDouble();
// return the new envelope
return new Envelope(tempXmin, tempYmin, tempXmax, tempYmax);
}
COM: <s> reads the envelope from the shape file </s>
|
funcom_train/22204166 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void setUp() throws Exception {
try {
props = new TestProperties();
InputStream in = new FileInputStream(System.getProperty("testdir") +
File.separatorChar + PROPFILE);
props.load(in);
} catch (IOException io) {
fail("property file load error: " + io.getMessage());
}
}
COM: <s> standard setup method </s>
|
funcom_train/1104205 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addIlkdegerPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_Alan_ilkdeger_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_Alan_ilkdeger_feature", "_UI_Alan_type"),
HarzemliPackage.eINSTANCE.getAlan_Ilkdeger(),
true,
false,
false,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
getString("_UI_validasyonPropertyCategory"),
null));
}
COM: <s> this adds a property descriptor for the ilkdeger feature </s>
|
funcom_train/42036164 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void initializeProviders() {
this.feed = new HashMap<String, Map<String, Set<ModuleParser>>>();
this.entry = new HashMap<String, Map<String, Set<ModuleParser>>>();
this.globals = new HashMap<String, Map<String, Set<ModuleParser>>>();
for (ModuleProvider provider : this.getModuleProviders()) {
provider.init(this);
}
}
COM: <s> this method initializes the maps for the tag parsers and calls init on </s>
|
funcom_train/37483137 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int indexOf(String vehicleName) throws Exception {
for (int i = 0; i < list.size(); i++) {
Vehicle findVehicle = (Vehicle) list.get(i);
if (findVehicle.getVehicleName().equals(vehicleName)) {
return i;
}
}
Exception e = new Exception("The specified vehicle "
+ "name could not be found.");
throw e;
}
COM: <s> returns the vehicle of the item with the specified name from the </s>
|
funcom_train/33416967 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Icon get(final String url) {
final StackTraceElement[] stacks = new Exception().getStackTrace();
try {
final Class callerClazz = Class.forName(stacks[1].getClassName());
return get(callerClazz.getResource(url));
} catch (final ClassNotFoundException e) {
throw new RuntimeException(e);
}
}
COM: <s> gets the icon denoted by url </s>
|
funcom_train/44705373 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addParties(PageState state, OptionGroup target) {
DataQuery dq = (DataQuery) m_query.get(state);
while ( dq.next() ) {
BigDecimal partyId = (BigDecimal) dq.get(DQ_PARTY_ID);
String name = (String) dq.get(DQ_NAME);
target.addOption(new Option(partyId.toString(), name));
}
}
COM: <s> adds parties to the option group </s>
|
funcom_train/22548442 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void handleNewData(final byte[] data, final ReplyHandler handler) {
if(data != null) {
QUEUE.execute(new Runnable() {
public void run() {
LOG.trace("Parsing new data...");
handleDataInternal(data, false, handler);
}
});
}
}
COM: <s> notification that a new message has arrived </s>
|
funcom_train/21482529 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void notifyRemoveAll(boolean remoteEvent) {
elementsRemoveAllCounter++;
if (hasCacheEventListeners()) {
Iterator iterator = createThreadSafeIterator();
while (iterator.hasNext()) {
CacheEventListener cacheEventListener = (CacheEventListener) iterator.next();
if (!isCircularNotification(remoteEvent, cacheEventListener)) {
cacheEventListener.notifyRemoveAll(cache);
}
}
}
}
COM: <s> notifies all registered listeners in no guaranteed order that remove all </s>
|
funcom_train/22354552 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setHerbs(List<HerbInfo> newHerbs) {
herbs = new ArrayList<HerbInfo>(newHerbs);
herbMap = new HashMap<ItemType, HerbInfo>();
for (HerbInfo info : newHerbs) {
herbMap.put(info.item, info);
}
fireTableStructureChanged();
}
COM: <s> change the set of herbs </s>
|
funcom_train/50938845 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void fireSelectionChanged() {
ChangeEvent event = new ChangeEvent(this);
Object[] listeners = listenerList.getListenerList();
for (int i = listeners.length - 2; i>= 0 ; i -= 2) {
if (listeners[i] == ChangeListener.class) {
((ChangeListener) listeners[i+1]).stateChanged(event);
}
}
}
COM: <s> fire the selection change to the listeners </s>
|
funcom_train/20750501 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void debug(String s) {
if (Log.ifp(6)) {
if (getLocalNode() != null)
System.out.println(getLocalNode().getNodeId() + " (" + nodeId + "): " + s);
else
System.out.println(getLocalNode() + " (" + nodeId + "): " + s);
}
}
COM: <s> prints out nicely formatted debug messages </s>
|
funcom_train/50179068 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Date internalToDate(String value) {
Date date = null;
if (value != null) {
try {
date = dateFmt.parse(value);
} catch (ParseException e) {
throw new IllegalArgumentException("Invalid date format: '" + value +
"': must be '" + FORMAT_STR + "'");
} catch (NullPointerException e) {
/*
* Just ignore this.
*/
}
}
return date;
}
COM: <s> convert an internal date value to a java </s>
|
funcom_train/46741054 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setShortDisplayInd(int shortDisplayInd) {
if (!(this.shortDisplayInd == shortDisplayInd)) {
int oldshortDisplayInd= 0;
oldshortDisplayInd = this.shortDisplayInd;
this.shortDisplayInd = shortDisplayInd;
setModified("shortDisplayInd");
firePropertyChange(String.valueOf(APPLICATIONCONTROLCOLUMNS_SHORTDISPLAYIND), oldshortDisplayInd, shortDisplayInd);
}
}
COM: <s> indicates to use a shorter display for the values </s>
|
funcom_train/33859812 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private JPanel getImplicReducerPanel() {
if (implicReducerPanel == null) {
GridBagConstraints gridBagConstraints1 = new GridBagConstraints();
gridBagConstraints1.fill = GridBagConstraints.BOTH;
gridBagConstraints1.weighty = 1.0;
gridBagConstraints1.weightx = 1.0;
implicReducerPanel = new JPanel();
implicReducerPanel.setLayout(new GridBagLayout());
implicReducerPanel.add(getImplicReducerSplitPane(), gridBagConstraints1);
}
return implicReducerPanel;
}
COM: <s> this method initializes implic reducer panel </s>
|
funcom_train/8222575 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public String getSimulator(String key) {
Listener l = (Listener) _listeners.get(key);
if (l != null) {
NetworkSimulator netsim = l.getSimulator();
if (netsim != null) {
return netsim.getName();
} else {
return "Unlimited";
}
} else {
return "Unlimited";
}
}
COM: <s> gets the simulator </s>
|
funcom_train/4635056 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void init(){
this.getVersion().init();
this.getConstants();
this.getAccess();
this.getType();
this.getSuper();
this.getInterfaces();
this.getFields();
this.getMethods();
this.getAttributesChild();
}
COM: <s> p construct basic empty document for dom programmers </s>
|
funcom_train/14276040 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void printtimes() throws RemoteException {
Logger.timelog("avg. FRUSTUM", frustumTime/frames);
Logger.timelog("avg. QUADTREE", quadtreeTime/frames);
Logger.timelog("- avg. DB", databaseTime/frames);
Logger.timelog("avg. COMPRESS", compressTime/frames);
}
COM: <s> prints benchmarks on server log </s>
|
funcom_train/2616722 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void onMyExpenseListAdd() {
Expense expense = new Expense();
if (owner != null) {
expense.setResource(owner);
}
expense.setAmount(new Float(0.0));
expense.setDate(CalendarHelper.getInstance().changeTimeToStartOfDay(new Date()));
ExpenseInstanceInListFullWithResource exp = new ExpenseInstanceInListFullWithResource(expense);
myExpenseList.add(exp);
Roma.fieldChanged(this, "myExpenseList");
}
COM: <s> method that adds an expense into the table showed </s>
|
funcom_train/39138058 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int hashCode() {
int result;
result = (oDate != null ? oDate.hashCode() : 0);
result = 29 * result + (oState != null ? oState.hashCode() : 0);
result = 29 * result
+ (oDescription != null ? oDescription.hashCode() : 0);
return result;
}
COM: <s> returns a hash code value for the object </s>
|
funcom_train/17850746 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void storeChannels() {
OutputStream writer = null;
try {
writer = new FileOutputStream((mService.mDataDir + "/channels.properties"));
channelList.store(writer, "Nxtvepg Channellist");
} catch (IOException e) {
mLog.info(e.toString());
} finally {
try {
writer.close();
} catch (IOException e) {
mLog.info(e.toString());
}
}
}
COM: <s> saves channel data to file for future use on file system </s>
|
funcom_train/32757591 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void xRunningAverageValueChanged( final BpmAgent source, final double value ) {
final int row = BPM_AGENTS.indexOf( source );
if ( row >= 0 ) {
fireTableCellUpdated( row, X_BEAM_POSITION_COLUMN );
fireTableCellUpdated( row, X_BEAM_POSITION_ERROR_COLUMN );
}
}
COM: <s> event indicating that the x running average value changed </s>
|
funcom_train/18239639 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void setUpInsertBaseRow(String projectName, int seqId, String sequenceData, String qualityData, String positionData){
MockResultSet resultInsertBasesRowQuery = preparedStatementHandler.createResultSet(insertBaseRowQuery);
preparedStatementHandler.prepareResultSet(insertBaseRowQuery, resultInsertBasesRowQuery,new Object[]{seqId, sequenceData,qualityData, positionData} );
}
COM: <s> adds a version2 of the sequence into the base table </s>
|
funcom_train/36107072 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void sendResponse(String responseType, boolean success, String reason, String moduleKey) {
MutableComparableData response = agentIO.createData(DataProtocol.EVENT_RESPONSE, responseType, moduleKey);
response.setBoolean(success, DataIO.RESPONSE_SUCCESS);
if(!success && reason!=null) response.set(reason, "failReason");
agentIO.send(response);
}
COM: <s> sending response to controller as a reaction on start command </s>
|
funcom_train/12309516 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public long getInputSize() throws IOException {
if (length>0)
return length;
if (file != null)
return file.length();
else if (url != null) {
if (response == null) {
URL resolvedURL = null;
try {
resolvedURL = URLEncoder.encode(url);
response = ConnectionFactory.get(resolvedURL);
} catch (IOException e) {
return ContentReference.UNKNOWN_SIZE;
}
UpdateManagerUtils.checkConnectionResult(response,resolvedURL);
}
long size = response.getContentLength();
return size == -1 ? ContentReference.UNKNOWN_SIZE : size;
} else
return ContentReference.UNKNOWN_SIZE;
}
COM: <s> returns the size of the referenced input if it can be determined </s>
|
funcom_train/28552005 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public Object getValidationInstance() throws Exception {
Object instance = null;
String className = COM_UNIBETA_VRULES_ENGINES_DCCIMPLS_RULES
+ CommonUtils.generateClassNameByFileFullName(fileName);
instance = instancesPool.get(className);
if (null == instance) {
instance = newValidationInstance(className);
synchronized (className) {
instancesPool.put(className, instance);
}
}
return instance;
}
COM: <s> gets current availabe validation instance directly </s>
|
funcom_train/48966319 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setPosition( float x, float y, float z ) {
if ( this.position.x != x ||
this.position.y != y ||
this.position.z != z ) {
this.position.x = x;
this.position.y = y;
this.position.z = z;
firePropertyChange( POSITION_PROPERTY, null, this.position );
}
}
COM: <s> change the position of this object to x y z </s>
|
funcom_train/45018429 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected void addFirstGoodPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_NXdataVariable_firstGood_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_NXdataVariable_firstGood_feature", "_UI_NXdataVariable_type"),
NexusPackageImpl.Literals.NXDATA_VARIABLE__FIRST_GOOD,
true,
ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
null,
null));
}
COM: <s> this adds a property descriptor for the first good feature </s>
|
funcom_train/29694046 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public StraightArrowPolygon (Point startPoint, Point endPoint, int width, int headWidth, boolean halved){
super();
this.startPoint = startPoint;
this.endPoint = endPoint;
this.headWidth = headWidth;
this.arrowWidthAtHead = width;
this.tailWidth = width;
this.halved = halved;
buildPointsArrays();
}
COM: <s> i know it is annoying but another constructor </s>
|
funcom_train/44821218 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public DocletInfo (RootDoc rootDoc, String[] tagPrefixes) {
ClassDoc[] classDocs = rootDoc.classes();
classes = new ClassTagInfo[classDocs.length];
for (int i = 0; i < classes.length; ++i) {
classes[i] = new ClassTagInfo (classDocs[i], tagPrefixes);
}
}
COM: <s> construct from a root doc </s>
|
funcom_train/50911102 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public double getLambda(Real2 p) {
Real2 near = this.getNearestPointOnLine(p);
Real2 delta = near.subtract(from);
double lambda = (Math.abs(vector.getX()) > Math.abs(vector.getY())) ?
delta.getX() / vector.getX() : delta.getY() / vector.getY();
return lambda;
}
COM: <s> gets multiplier of point from from </s>
|
funcom_train/10609133 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void connect(PipedReader stream) throws IOException {
synchronized (lock) {
if (this.dest != null) {
throw new IOException(Msg.getString("K0079")); //$NON-NLS-1$
}
if (closed) {
throw new IOException(Msg.getString("K0078")); //$NON-NLS-1$
}
stream.establishConnection();
this.dest = stream;
}
}
COM: <s> connects this piped writer to a piped reader </s>
|
funcom_train/4521186 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void delete(Parametro entity) {
LogUtil.log("deleting Parametro instance", Level.INFO, null);
try {
entity = entityManager.getReference(Parametro.class, entity
.getParametroId());
entityManager.remove(entity);
LogUtil.log("delete successful", Level.INFO, null);
} catch (RuntimeException re) {
LogUtil.log("delete failed", Level.SEVERE, re);
throw re;
}
}
COM: <s> delete a persistent parametro entity </s>
|
funcom_train/7381991 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private String getFormattedText(byte[] bytes) {
final StringBuilder buf = new StringBuilder(bytes.length * 2);
for (int j = 0; j < bytes.length; j++) {
buf.append(HEX_DIGITS[(bytes[j] >> 4) & 0x0f]);
buf.append(HEX_DIGITS[bytes[j] & 0x0f]);
}
return buf.toString();
}
COM: <s> takes the raw bytes from the digest and formats them correct </s>
|
funcom_train/44450448 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void second_pass(SrcML f_srcml) {
// Time to create an initial symbol table now:
m_symtable = new SymbolTable();
// enter an outermost dummy block
m_symtable.enter();
// and now perform the treewalk
SrcMLElement.ms_eventsEnabled = false;
_treewalk(f_srcml.getUnit());
SrcMLElement.ms_eventsEnabled = true;
}
COM: <s> this performs a second pass on the parser result and can make various </s>
|
funcom_train/15945080 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public int addIcon(VertexIcon icon, ActionListener actionListener) {
IconButton button = new IconButton(icon);
if (actionListener != null)
button.addActionListener(actionListener);
this.add(button, getIconCount());
repaint();
return getIconCount() - 1;
}
COM: <s> the function code add icon code does allow for an action listener </s>
|
funcom_train/51482495 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected CommandMenu createColorMenu(String attribute) {
CommandMenu menu = new CommandMenu("Colour");
ColorMap map = ColorMap.getColorMap();
System.err.println("MAP SIZE:"+map.size());
for (int i = 0; i < map.size(); i++)
menu.add(
new ChangeAttributeCommand(
map.name(i), attribute,
map.color(i), fView));
return menu;
}
COM: <s> creates the color choice for the given attribute </s>
|
funcom_train/34749229 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void destroyObject(Object key, Object obj) throws Exception {
if (obj instanceof PooledConnectionAndInfo) {
PooledConnection pc = ((PooledConnectionAndInfo)obj).getPooledConnection();
pc.removeConnectionEventListener(this);
pcMap.remove(pc);
pc.close();
}
}
COM: <s> closes the pooled connection and stops listening for events from it </s>
|
funcom_train/12179249 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void testRenderNumberCenterValue() throws Exception {
StyleLength styleValueXPosition = styleValueFactory.getLength(null, 3.1, LengthUnit.PT);
StyleKeyword styleValueYPosition = BackgroundYPositionKeywords.CENTER;
stylePairTest(styleValueXPosition, styleValueYPosition, "3.1pt 50%");
}
COM: <s> tests the values rendered for number and center value is correct </s>
|
funcom_train/45310990 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: protected String getPrefix(IDocument document, int offset) {
try {
int start = offset - 1; // start one char before the cursor
while (isNonTerminalChar(document.getChar(start)))
--start;
if (document.getChar(start) == '<')
--start;
start++; // parsed one too far
return document.get(start, offset - start);
} catch (Exception e) {
}
return null;
}
COM: <s> get the prefix for a rule </s>
|
funcom_train/21005478 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: private RequestBuilder createRequestBuilder(Version apiVersion) {
switch (apiVersion) {
case MW1_09:
case MW1_10:
return new RequestBuilder1x09();
case MW1_11:
case MW1_12:
case MW1_13:
case MW1_14:
case MW1_15:
case MW1_16:
return new RequestBuilder1x11();
default: // MW1_17 and up
return new RequestBuilder1x17();
}
}
COM: <s> creates a request builder for the given api version </s>
|
funcom_train/45803025 | /tmp/hf-datasets-cache/medium/datasets/31837353763449-config-parquet-and-info-apcl-funcom-java-long-1b0b1ae9/downloads/d42b7d3130dd02820b64692a8810efdf479c66e589141ea4cfe3cb3bba421716 | TDAT: public void setSizeEquals(String equalsSizeString) {
try {
this.equalsSize = Integer.parseInt( equalsSizeString );
} catch (NumberFormatException e) {
log.warn("Reset invalid equalsSize value to '-1' was '" +
equalsSizeString + "'.");
this.equalsSize = -1;
}
}
COM: <s> sets exact equals size test value against collection size </s>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.