method stringlengths 13 441k | clean_method stringlengths 7 313k | doc stringlengths 17 17.3k | comment stringlengths 3 1.42k | method_name stringlengths 1 273 | extra dict | imports list | imports_info stringlengths 19 34.8k | cluster_imports_info stringlengths 15 3.66k | libraries list | libraries_info stringlengths 6 661 | id int64 0 2.92M |
|---|---|---|---|---|---|---|---|---|---|---|---|
protected PackagedProgram buildProgram(ProgramOptions options)
throws FileNotFoundException, ProgramInvocationException {
String[] programArgs = options.getProgramArgs();
String jarFilePath = options.getJarFilePath();
List<URL> classpaths = options.getClasspaths();
if (jarFilePath == null) {
throw new IllegalArgumentException("The program JAR file was not specified.");
}
File jarFile = new File(jarFilePath);
// Check if JAR file exists
if (!jarFile.exists()) {
throw new FileNotFoundException("JAR file does not exist: " + jarFile);
}
else if (!jarFile.isFile()) {
throw new FileNotFoundException("JAR file is not a file: " + jarFile);
}
// Get assembler class
String entryPointClass = options.getEntryPointClassName();
PackagedProgram program = entryPointClass == null ?
new PackagedProgram(jarFile, classpaths, programArgs) :
new PackagedProgram(jarFile, classpaths, entryPointClass, programArgs);
program.setSavepointRestoreSettings(options.getSavepointRestoreSettings());
return program;
} | PackagedProgram function(ProgramOptions options) throws FileNotFoundException, ProgramInvocationException { String[] programArgs = options.getProgramArgs(); String jarFilePath = options.getJarFilePath(); List<URL> classpaths = options.getClasspaths(); if (jarFilePath == null) { throw new IllegalArgumentException(STR); } File jarFile = new File(jarFilePath); if (!jarFile.exists()) { throw new FileNotFoundException(STR + jarFile); } else if (!jarFile.isFile()) { throw new FileNotFoundException(STR + jarFile); } String entryPointClass = options.getEntryPointClassName(); PackagedProgram program = entryPointClass == null ? new PackagedProgram(jarFile, classpaths, programArgs) : new PackagedProgram(jarFile, classpaths, entryPointClass, programArgs); program.setSavepointRestoreSettings(options.getSavepointRestoreSettings()); return program; } | /**
* Creates a Packaged program from the given command line options.
*
* @return A PackagedProgram (upon success)
* @throws java.io.FileNotFoundException
* @throws org.apache.flink.client.program.ProgramInvocationException
*/ | Creates a Packaged program from the given command line options | buildProgram | {
"repo_name": "zohar-mizrahi/flink",
"path": "flink-clients/src/main/java/org/apache/flink/client/CliFrontend.java",
"license": "apache-2.0",
"size": 40951
} | [
"java.io.File",
"java.io.FileNotFoundException",
"java.util.List",
"org.apache.flink.client.cli.ProgramOptions",
"org.apache.flink.client.program.PackagedProgram",
"org.apache.flink.client.program.ProgramInvocationException"
] | import java.io.File; import java.io.FileNotFoundException; import java.util.List; import org.apache.flink.client.cli.ProgramOptions; import org.apache.flink.client.program.PackagedProgram; import org.apache.flink.client.program.ProgramInvocationException; | import java.io.*; import java.util.*; import org.apache.flink.client.cli.*; import org.apache.flink.client.program.*; | [
"java.io",
"java.util",
"org.apache.flink"
] | java.io; java.util; org.apache.flink; | 1,944,887 |
@Override
protected boolean beforeSave (boolean newRecord)
{
if (getAD_Org_ID() != 0)
setAD_Org_ID(0);
// Region Check
if (getC_Region_ID() != 0)
{
if (m_c == null || m_c.getC_Country_ID() != getC_Country_ID())
getCountry();
if (!m_c.isHasRegion())
setC_Region_ID(0);
}
if (getC_City_ID() <= 0 && getCity() != null && getCity().length() > 0) {
int city_id = DB.getSQLValue(
get_TrxName(),
"SELECT C_City_ID FROM C_City WHERE C_Country_ID=? AND COALESCE(C_Region_ID,0)=? AND Name=?",
new Object[] {getC_Country_ID(), getC_Region_ID(), getCity()});
if (city_id > 0)
setC_City_ID(city_id);
}
//check city
if (m_c != null && !m_c.isAllowCitiesOutOfList() && getC_City_ID()<=0)
{
throw new AdempiereException("@CityNotFound@");
}
return true;
} // beforeSave
| boolean function (boolean newRecord) { if (getAD_Org_ID() != 0) setAD_Org_ID(0); if (getC_Region_ID() != 0) { if (m_c == null m_c.getC_Country_ID() != getC_Country_ID()) getCountry(); if (!m_c.isHasRegion()) setC_Region_ID(0); } if (getC_City_ID() <= 0 && getCity() != null && getCity().length() > 0) { int city_id = DB.getSQLValue( get_TrxName(), STR, new Object[] {getC_Country_ID(), getC_Region_ID(), getCity()}); if (city_id > 0) setC_City_ID(city_id); } if (m_c != null && !m_c.isAllowCitiesOutOfList() && getC_City_ID()<=0) { throw new AdempiereException(STR); } return true; } | /**
* Before Save
* @param newRecord new
* @return true
*/ | Before Save | beforeSave | {
"repo_name": "klst-com/metasfresh",
"path": "de.metas.adempiere.adempiere/base/src/main/java-legacy/org/compiere/model/MLocation.java",
"license": "gpl-2.0",
"size": 18566
} | [
"org.adempiere.exceptions.AdempiereException",
"org.compiere.util.DB"
] | import org.adempiere.exceptions.AdempiereException; import org.compiere.util.DB; | import org.adempiere.exceptions.*; import org.compiere.util.*; | [
"org.adempiere.exceptions",
"org.compiere.util"
] | org.adempiere.exceptions; org.compiere.util; | 2,785,168 |
private static Properties readApplicationProperties() {
Properties localProperties = new Properties();
try (InputStream input = AbstractConfig.class.getClassLoader().getResourceAsStream("/" + APPLICATION_PROPERTIES)) {
localProperties.load(input);
} catch (IOException | NullPointerException e) {
LOGGER.warn("The file {} could not be read.", APPLICATION_PROPERTIES, e);
}
return localProperties;
} | static Properties function() { Properties localProperties = new Properties(); try (InputStream input = AbstractConfig.class.getClassLoader().getResourceAsStream("/" + APPLICATION_PROPERTIES)) { localProperties.load(input); } catch (IOException NullPointerException e) { LOGGER.warn(STR, APPLICATION_PROPERTIES, e); } return localProperties; } | /**
* Tries to read the application properties.
*
* @return - A collection of properties, which is empty if no application has been defined (i.e. at unit tests)
*/ | Tries to read the application properties | readApplicationProperties | {
"repo_name": "USEF-Foundation/ri.usef.energy",
"path": "usef-build/usef-core/usef-core-commons/src/main/java/energy/usef/core/config/AbstractConfig.java",
"license": "apache-2.0",
"size": 11507
} | [
"java.io.IOException",
"java.io.InputStream",
"java.util.Properties"
] | import java.io.IOException; import java.io.InputStream; import java.util.Properties; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 2,888,392 |
public void setComments(List<String> comments) {
this.comments = comments;
} | void function(List<String> comments) { this.comments = comments; } | /**
* Attach xml comments to the target model element.
*/ | Attach xml comments to the target model element | setComments | {
"repo_name": "StephaneSeyvoz/mindEd",
"path": "org.ow2.mindEd.adl.model/customsrc/org/ow2/mindEd/adl/custom/helpers/HelperAdapter.java",
"license": "lgpl-3.0",
"size": 6700
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,524,913 |
public void launchCourse() {
this.course.setEtatCourse(EtatCourse.RUN);
initVoituresGraphics();
buildAndSetGameLoop();
beginGameLoop();
}
| void function() { this.course.setEtatCourse(EtatCourse.RUN); initVoituresGraphics(); buildAndSetGameLoop(); beginGameLoop(); } | /**
* Lance la course.
*/ | Lance la course | launchCourse | {
"repo_name": "Spasfonx/NeedForCodeOld",
"path": "NeedForCode/src/fr/needforcode/ihm/controller/CourseRunningController.java",
"license": "gpl-2.0",
"size": 10482
} | [
"fr.needforcode.course.EtatCourse"
] | import fr.needforcode.course.EtatCourse; | import fr.needforcode.course.*; | [
"fr.needforcode.course"
] | fr.needforcode.course; | 1,242,579 |
public VolatileImage createCompatibleVolatileImage(int width, int height,
int transparency)
{
VolatileImage vi = null;
try {
vi = createCompatibleVolatileImage(width, height, null, transparency);
} catch (AWTException e) {
// shouldn't happen: we're passing in null caps
assert false;
}
return vi;
} | VolatileImage function(int width, int height, int transparency) { VolatileImage vi = null; try { vi = createCompatibleVolatileImage(width, height, null, transparency); } catch (AWTException e) { assert false; } return vi; } | /**
* Returns a {@link VolatileImage} with a data layout and color model
* compatible with this <code>GraphicsConfiguration</code>.
* The returned <code>VolatileImage</code>
* may have data that is stored optimally for the underlying graphics
* device and may therefore benefit from platform-specific rendering
* acceleration.
* @param width the width of the returned <code>VolatileImage</code>
* @param height the height of the returned <code>VolatileImage</code>
* @param transparency the specified transparency mode
* @return a <code>VolatileImage</code> whose data layout and color
* model is compatible with this <code>GraphicsConfiguration</code>.
* @throws IllegalArgumentException if the transparency is not a valid value
* @see Transparency#OPAQUE
* @see Transparency#BITMASK
* @see Transparency#TRANSLUCENT
* @see Component#createVolatileImage(int, int)
* @since 1.5
*/ | Returns a <code>VolatileImage</code> with a data layout and color model compatible with this <code>GraphicsConfiguration</code>. The returned <code>VolatileImage</code> may have data that is stored optimally for the underlying graphics device and may therefore benefit from platform-specific rendering acceleration | createCompatibleVolatileImage | {
"repo_name": "flyzsd/java-code-snippets",
"path": "ibm.jdk8/src/java/awt/GraphicsConfiguration.java",
"license": "mit",
"size": 18926
} | [
"java.awt.image.VolatileImage"
] | import java.awt.image.VolatileImage; | import java.awt.image.*; | [
"java.awt"
] | java.awt; | 1,225,423 |
private static List<Map<String, Object>> getServersWithoutCurrentSize(List<Map<String, Object>> servers)
{
return Lists.transform(
servers,
(server) -> {
Map<String, Object> newServer = new HashMap<>(server);
newServer.put("curr_size", 0);
return newServer;
}
);
} | static List<Map<String, Object>> function(List<Map<String, Object>> servers) { return Lists.transform( servers, (server) -> { Map<String, Object> newServer = new HashMap<>(server); newServer.put(STR, 0); return newServer; } ); } | /**
* curr_size on historicals changes because cluster state is not isolated across different
* integration tests, zero it out for consistent test results
*/ | curr_size on historicals changes because cluster state is not isolated across different integration tests, zero it out for consistent test results | getServersWithoutCurrentSize | {
"repo_name": "gianm/druid",
"path": "integration-tests/src/test/java/org/apache/druid/tests/security/ITBasicAuthConfigurationTest.java",
"license": "apache-2.0",
"size": 28501
} | [
"com.google.common.collect.Lists",
"java.util.HashMap",
"java.util.List",
"java.util.Map"
] | import com.google.common.collect.Lists; import java.util.HashMap; import java.util.List; import java.util.Map; | import com.google.common.collect.*; import java.util.*; | [
"com.google.common",
"java.util"
] | com.google.common; java.util; | 1,187,683 |
Set<Link> getDeviceEgressLinks(DeviceId deviceId) {
return seenLinks.keySet().stream()
.filter(link -> link.src().deviceId().equals(deviceId))
.filter(link -> seenLinks.get(link))
.filter(link -> isBidirectionalLinkUp(link))
.collect(Collectors.toSet());
} | Set<Link> getDeviceEgressLinks(DeviceId deviceId) { return seenLinks.keySet().stream() .filter(link -> link.src().deviceId().equals(deviceId)) .filter(link -> seenLinks.get(link)) .filter(link -> isBidirectionalLinkUp(link)) .collect(Collectors.toSet()); } | /**
* Returns all links that egress from given device that are UP in the
* seenLinks store. The returned links are also confirmed to be
* bidirectional.
*
* @param deviceId the device identifier
* @return set of egress links from the device
*/ | Returns all links that egress from given device that are UP in the seenLinks store. The returned links are also confirmed to be bidirectional | getDeviceEgressLinks | {
"repo_name": "kuujo/onos",
"path": "apps/segmentrouting/app/src/main/java/org/onosproject/segmentrouting/LinkHandler.java",
"license": "apache-2.0",
"size": 30018
} | [
"java.util.Set",
"java.util.stream.Collectors",
"org.onosproject.net.DeviceId",
"org.onosproject.net.Link"
] | import java.util.Set; import java.util.stream.Collectors; import org.onosproject.net.DeviceId; import org.onosproject.net.Link; | import java.util.*; import java.util.stream.*; import org.onosproject.net.*; | [
"java.util",
"org.onosproject.net"
] | java.util; org.onosproject.net; | 1,318,806 |
@Test
public void testToString() {
final String defaultPrefix = "default";
final String prefixNode1 = "prefix1";
final String prefixNode2 = "prefix2";
final String prefixText = "prefixtext";
getXMLObject().declarePrefix(defaultPrefix, DEFAULT_NAMESPACE);
((XMLNode) getXMLObject().getChildNodes().get(0)).declarePrefix(prefixNode1, NAMESPACE_NODE_1);
((XMLNode) ((XMLParentNode) getXMLObject().getChildNodes().get(0)).getChildNodes().get(0)).declarePrefix(
prefixNode2, NAMESPACE_NODE_2);
((XMLNode) getXMLObject().getChildNodes().get(1)).declarePrefix(prefixText, NAMESPACE_TEXT_NODE);
StringBuilder builder = new StringBuilder();
builder.append("<").append(defaultPrefix).append(":").append(getXMLObject().getName());
builder.append(" xmlns:").append(defaultPrefix).append("=\"").append(DEFAULT_NAMESPACE).append("\"");
builder.append(">");
builder.append("<").append(prefixNode1).append(":").append(NAME_NODE_1);
builder.append(" xmlns:").append(prefixNode1).append("=\"").append(NAMESPACE_NODE_1).append("\"");
builder.append(">");
builder.append("<").append(prefixNode2).append(":").append(NAME_NODE_2);
builder.append(" xmlns:").append(prefixNode2).append("=\"").append(NAMESPACE_NODE_2).append("\"");
builder.append(" />");
builder.append("</").append(prefixNode1).append(":").append(NAME_NODE_1).append(">");
builder.append("<").append(prefixText).append(":").append(NAME_TEXT_NODE);
builder.append(" xmlns:").append(prefixText).append("=\"").append(NAMESPACE_TEXT_NODE).append("\"");
builder.append(">");
builder.append(VALUE_TEXT_NODE);
builder.append("</").append(prefixText).append(":").append(NAME_TEXT_NODE).append(">");
builder.append("</").append(defaultPrefix).append(":").append(getXMLObject().getName()).append(">");
assertEquals(builder.toString(), getXMLObject().toString());
} | void function() { final String defaultPrefix = STR; final String prefixNode1 = STR; final String prefixNode2 = STR; final String prefixText = STR; getXMLObject().declarePrefix(defaultPrefix, DEFAULT_NAMESPACE); ((XMLNode) getXMLObject().getChildNodes().get(0)).declarePrefix(prefixNode1, NAMESPACE_NODE_1); ((XMLNode) ((XMLParentNode) getXMLObject().getChildNodes().get(0)).getChildNodes().get(0)).declarePrefix( prefixNode2, NAMESPACE_NODE_2); ((XMLNode) getXMLObject().getChildNodes().get(1)).declarePrefix(prefixText, NAMESPACE_TEXT_NODE); StringBuilder builder = new StringBuilder(); builder.append("<STR:").append(getXMLObject().getName()); builder.append(STR).append(defaultPrefix).append("=\"STR\STR>STR<STR:").append(NAME_NODE_1); builder.append(STR).append(prefixNode1).append("=\STR\STR>STR<STR:").append(NAME_NODE_2); builder.append(STR).append(prefixNode2).append("=\STR\STR />STR</STR:STR>STR<STR:").append(NAME_TEXT_NODE); builder.append(STR).append(prefixText).append("=\STR\STR>STR</STR:STR>STR</STR:STR>"); assertEquals(builder.toString(), getXMLObject().toString()); } | /**
* Build up a string corresponding to what the basic node should look like
* serialized, then compare it.
* <p>
* This is a nasty test but it's gotta be here for regression testing.
*/ | Build up a string corresponding to what the basic node should look like serialized, then compare it. This is a nasty test but it's gotta be here for regression testing | testToString | {
"repo_name": "AlexGilleran/IceSoap",
"path": "IceSoapTest/src/test/java/com/alexgilleran/icesoap/xml/test/XMLNodeTest.java",
"license": "apache-2.0",
"size": 5831
} | [
"com.alexgilleran.icesoap.xml.XMLNode",
"com.alexgilleran.icesoap.xml.XMLParentNode",
"org.junit.Assert"
] | import com.alexgilleran.icesoap.xml.XMLNode; import com.alexgilleran.icesoap.xml.XMLParentNode; import org.junit.Assert; | import com.alexgilleran.icesoap.xml.*; import org.junit.*; | [
"com.alexgilleran.icesoap",
"org.junit"
] | com.alexgilleran.icesoap; org.junit; | 1,045,043 |
public void testQRMBeforePut()
{
try {
HARegionQueue regionqueue = createHARegionQueue("testing");
EventID[] ids = new EventID[10];
for (int i = 0; i < 10; i++) {
ids[i] = new EventID(new byte[] { 1 }, 1, i);
}
//first get the qrm message for the seventh id
regionqueue.removeDispatchedEvents(ids[6]);
Conflatable[] cf = new Conflatable[10];
// put 10 conflatable objects
for (int i = 0; i < 10; i++) {
cf[i] = new ConflatableObject("key" + i, "value", ids[i], true,
"testing");
regionqueue.put(cf[i]);
}
// verify 1-7 not in region
Set values = (Set)regionqueue.getRegion().values();
for (int i = 0; i < 7; i++) {
System.out.println(i);
Assert.assertTrue(!values.contains(cf[i]));
}
// verify 8-10 still in region queue
for (int i = 7; i < 10; i++) {
System.out.println(i);
Assert.assertTrue(values.contains(cf[i]));
}
// verify 1-8 not in conflation map
for (long i = 0; i < 7; i++) {
Assert.assertTrue(!((Map)regionqueue.getConflationMapForTesting().get(
"testing")).containsKey("key" + i));
}
// verify 8-10 in conflation map
for (long i = 7; i < 10; i++) {
Assert.assertTrue(((Map)regionqueue.getConflationMapForTesting().get(
"testing")).containsKey("key" + i));
}
EventID eid = new EventID(new byte[] { 1 }, 1, 6);
// verify 1-7 not in eventMap
for (long i = 4; i < 11; i++) {
Assert.assertTrue(!regionqueue.getCurrentCounterSet(eid).contains(
new Long(i)));
}
// verify 8-10 in event Map
for (long i = 1; i < 4; i++) {
Assert.assertTrue(regionqueue.getCurrentCounterSet(eid).contains(
new Long(i)));
}
// verify 1-7 not in available Id's map
for (long i = 4; i < 11; i++) {
Assert.assertTrue(!regionqueue.getAvalaibleIds().contains(new Long(i)));
}
// verify 8-10 in available id's map
for (long i = 1; i < 4; i++) {
Assert.assertTrue(regionqueue.getAvalaibleIds().contains(new Long(i)));
}
}
catch (Exception e) {
e.printStackTrace();
fail("Exception occured in test due to " + e);
}
} | void function() { try { HARegionQueue regionqueue = createHARegionQueue(STR); EventID[] ids = new EventID[10]; for (int i = 0; i < 10; i++) { ids[i] = new EventID(new byte[] { 1 }, 1, i); } regionqueue.removeDispatchedEvents(ids[6]); Conflatable[] cf = new Conflatable[10]; for (int i = 0; i < 10; i++) { cf[i] = new ConflatableObject("key" + i, "value", ids[i], true, STR); regionqueue.put(cf[i]); } Set values = (Set)regionqueue.getRegion().values(); for (int i = 0; i < 7; i++) { System.out.println(i); Assert.assertTrue(!values.contains(cf[i])); } for (int i = 7; i < 10; i++) { System.out.println(i); Assert.assertTrue(values.contains(cf[i])); } for (long i = 0; i < 7; i++) { Assert.assertTrue(!((Map)regionqueue.getConflationMapForTesting().get( STR)).containsKey("key" + i)); } for (long i = 7; i < 10; i++) { Assert.assertTrue(((Map)regionqueue.getConflationMapForTesting().get( STR)).containsKey("key" + i)); } EventID eid = new EventID(new byte[] { 1 }, 1, 6); for (long i = 4; i < 11; i++) { Assert.assertTrue(!regionqueue.getCurrentCounterSet(eid).contains( new Long(i))); } for (long i = 1; i < 4; i++) { Assert.assertTrue(regionqueue.getCurrentCounterSet(eid).contains( new Long(i))); } for (long i = 4; i < 11; i++) { Assert.assertTrue(!regionqueue.getAvalaibleIds().contains(new Long(i))); } for (long i = 1; i < 4; i++) { Assert.assertTrue(regionqueue.getAvalaibleIds().contains(new Long(i))); } } catch (Exception e) { e.printStackTrace(); fail(STR + e); } } | /**
* - send Dispatch message for sequence id 7 - put from sequence id 1 - id 10 -
* verify data for 1-7 not there - verify data for 8-10 is there
*
*/ | - send Dispatch message for sequence id 7 - put from sequence id 1 - id 10 - verify data for 1-7 not there - verify data for 8-10 is there | testQRMBeforePut | {
"repo_name": "papicella/snappy-store",
"path": "gemfire-junit/src/main/java/com/gemstone/gemfire/internal/cache/ha/HARegionQueueJUnitTest.java",
"license": "apache-2.0",
"size": 72282
} | [
"com.gemstone.gemfire.internal.cache.Conflatable",
"com.gemstone.gemfire.internal.cache.EventID",
"java.util.Map",
"java.util.Set",
"junit.framework.Assert"
] | import com.gemstone.gemfire.internal.cache.Conflatable; import com.gemstone.gemfire.internal.cache.EventID; import java.util.Map; import java.util.Set; import junit.framework.Assert; | import com.gemstone.gemfire.internal.cache.*; import java.util.*; import junit.framework.*; | [
"com.gemstone.gemfire",
"java.util",
"junit.framework"
] | com.gemstone.gemfire; java.util; junit.framework; | 450,325 |
public JarConfiguration setCategoryPropertyOrder(String category, final List<String> propOrder)
{
if (!caseSensitiveCustomCategories)
category = category.toLowerCase(Locale.ENGLISH);
getCategory(category).setPropertyOrder(propOrder);
return this;
}
public static class UnicodeInputStreamReader extends Reader
{
private final InputStreamReader input;
public UnicodeInputStreamReader(final InputStream source, final String encoding) throws IOException
{
String enc = encoding;
final byte[] data = new byte[4];
final PushbackInputStream pbStream = new PushbackInputStream(source, data.length);
final int read = pbStream.read(data, 0, data.length);
int size = 0;
final int bom16 = (data[0] & 0xFF) << 8 | (data[1] & 0xFF);
final int bom24 = bom16 << 8 | (data[2] & 0xFF);
final int bom32 = bom24 << 8 | (data[3] & 0xFF);
if (bom24 == 0xEFBBBF)
{
enc = "UTF-8";
size = 3;
}
else if (bom16 == 0xFEFF)
{
enc = "UTF-16BE";
size = 2;
}
else if (bom16 == 0xFFFE)
{
enc = "UTF-16LE";
size = 2;
}
else if (bom32 == 0x0000FEFF)
{
enc = "UTF-32BE";
size = 4;
}
else if (bom32 == 0xFFFE0000) //This will never happen as it'll be caught by UTF-16LE,
{ //but if anyone ever runs across a 32LE file, i'd like to disect it.
enc = "UTF-32LE";
size = 4;
}
if (size < read)
{
pbStream.unread(data, size, read - size);
}
this.input = new InputStreamReader(pbStream, enc);
} | JarConfiguration function(String category, final List<String> propOrder) { if (!caseSensitiveCustomCategories) category = category.toLowerCase(Locale.ENGLISH); getCategory(category).setPropertyOrder(propOrder); return this; } public static class UnicodeInputStreamReader extends Reader { private final InputStreamReader input; public UnicodeInputStreamReader(final InputStream source, final String encoding) throws IOException { String enc = encoding; final byte[] data = new byte[4]; final PushbackInputStream pbStream = new PushbackInputStream(source, data.length); final int read = pbStream.read(data, 0, data.length); int size = 0; final int bom16 = (data[0] & 0xFF) << 8 (data[1] & 0xFF); final int bom24 = bom16 << 8 (data[2] & 0xFF); final int bom32 = bom24 << 8 (data[3] & 0xFF); if (bom24 == 0xEFBBBF) { enc = "UTF-8"; size = 3; } else if (bom16 == 0xFEFF) { enc = STR; size = 2; } else if (bom16 == 0xFFFE) { enc = STR; size = 2; } else if (bom32 == 0x0000FEFF) { enc = STR; size = 4; } else if (bom32 == 0xFFFE0000) { enc = STR; size = 4; } if (size < read) { pbStream.unread(data, size, read - size); } this.input = new InputStreamReader(pbStream, enc); } | /**
* Sets the order that direct child properties of this config category will be written to the config file and will be displayed in
* config GUIs.
*/ | Sets the order that direct child properties of this config category will be written to the config file and will be displayed in config GUIs | setCategoryPropertyOrder | {
"repo_name": "OreCruncher/Restructured",
"path": "src/main/java/org/blockartistry/mod/Restructured/util/JarConfiguration.java",
"license": "mit",
"size": 61536
} | [
"java.io.IOException",
"java.io.InputStream",
"java.io.InputStreamReader",
"java.io.PushbackInputStream",
"java.io.Reader",
"java.util.List",
"java.util.Locale"
] | import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.io.PushbackInputStream; import java.io.Reader; import java.util.List; import java.util.Locale; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 254,450 |
@Test
public void getDestinationStatusForFakeMergeAndNonEmptyRoots() throws Exception {
fetch = primaryBranch;
push = primaryBranch;
Files.createDirectories(workdir.resolve("dir"));
Files.write(workdir.resolve("dir/file"), "".getBytes(UTF_8));
GitRepository repo = repo().withWorkTree(workdir);
repo.add().files("dir/file").run();
repo.simpleCommand("commit", "-m", "first commit");
repo.simpleCommand("branch", "foo");
Files.write(workdir.resolve("dir/file"), "other".getBytes(UTF_8));
repo.add().files("dir/file").run();
repo.simpleCommand("commit", "-m", "first commit");
repo.forceCheckout("foo");
Files.write(workdir.resolve("dir/file"), "feature".getBytes(UTF_8));
repo.add().files("dir/file").run();
repo.simpleCommand("commit", "-m", "first commit");
repo.forceCheckout(primaryBranch);
// Fake merge
repo.simpleCommand("merge", "-Xours", "foo", "-m",
"A fake merge\n\n" + DummyOrigin.LABEL_NAME + ": foo");
destinationFiles = Glob.createGlob(ImmutableList.of("dir/**"));
WriterContext writerContext =
new WriterContext("piper_to_github", "TEST", false, new DummyRevision("feature"),
Glob.ALL_FILES.roots());
DestinationStatus status = destination().newWriter(writerContext)
.getDestinationStatus(destinationFiles, DummyOrigin.LABEL_NAME);
assertThat(status).isNotNull();
assertThat(status.getBaseline()).isEqualTo("foo");
} | void function() throws Exception { fetch = primaryBranch; push = primaryBranch; Files.createDirectories(workdir.resolve("dir")); Files.write(workdir.resolve(STR), "".getBytes(UTF_8)); GitRepository repo = repo().withWorkTree(workdir); repo.add().files(STR).run(); repo.simpleCommand("commitSTR-mSTRfirst commitSTRbranchSTRfoo"); Files.write(workdir.resolve(STR), "other".getBytes(UTF_8)); repo.add().files(STR).run(); repo.simpleCommand("commitSTR-mSTRfirst commitSTRfoo"); Files.write(workdir.resolve(STR), "feature".getBytes(UTF_8)); repo.add().files(STR).run(); repo.simpleCommand("commitSTR-mSTRfirst commitSTRmergeSTR-XoursSTRfooSTR-mSTRA fake merge\n\nSTR: fooSTRdir/**STRpiper_to_githubSTRTESTSTRfeatureSTRfoo"); } | /**
* regression to ensure we don't do:
*
* git log -- some_path
*
* This doesn't work for fake merges as the merge is not shown when a path is passed even
* with -m.
*/ | regression to ensure we don't do: git log -- some_path This doesn't work for fake merges as the merge is not shown when a path is passed even with -m | getDestinationStatusForFakeMergeAndNonEmptyRoots | {
"repo_name": "google/copybara",
"path": "javatests/com/google/copybara/git/GitDestinationTest.java",
"license": "apache-2.0",
"size": 84713
} | [
"java.nio.file.Files"
] | import java.nio.file.Files; | import java.nio.file.*; | [
"java.nio"
] | java.nio; | 1,247,895 |
public Phonenumber.PhoneNumber getPhoneNumber() {
return mCurrentPhoneNumber;
} | Phonenumber.PhoneNumber function() { return mCurrentPhoneNumber; } | /**
* Get the current phone number
*
* @return phone number object
*/ | Get the current phone number | getPhoneNumber | {
"repo_name": "noepitome/neon-android",
"path": "neon/src/main/java/im/neon/PhoneNumberHandler.java",
"license": "apache-2.0",
"size": 10099
} | [
"com.google.i18n.phonenumbers.Phonenumber"
] | import com.google.i18n.phonenumbers.Phonenumber; | import com.google.i18n.phonenumbers.*; | [
"com.google.i18n"
] | com.google.i18n; | 2,099,739 |
public static Response toConflictJsonResponse(ModelException mex) {
return Response.status(Response.Status.CONFLICT)
.entity(toJson(mex)).type(MediaType.APPLICATION_JSON).build();
} | static Response function(ModelException mex) { return Response.status(Response.Status.CONFLICT) .entity(toJson(mex)).type(MediaType.APPLICATION_JSON).build(); } | /**
* To be used inside BadRequestException, like this :
* throw new BadRequestException(toConflictJsonResponse(e)).
* Inspired by JaxrsExceptionHelper
* @param t
* @return
*/ | To be used inside BadRequestException, like this : throw new BadRequestException(toConflictJsonResponse(e)). Inspired by JaxrsExceptionHelper | toConflictJsonResponse | {
"repo_name": "ozwillo/ozwillo-datacore",
"path": "ozwillo-datacore-rest-server/src/main/java/org/oasis/datacore/rest/server/DatacoreApiImpl.java",
"license": "agpl-3.0",
"size": 31174
} | [
"javax.ws.rs.core.MediaType",
"javax.ws.rs.core.Response",
"org.oasis.datacore.core.meta.ModelException"
] | import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; import org.oasis.datacore.core.meta.ModelException; | import javax.ws.rs.core.*; import org.oasis.datacore.core.meta.*; | [
"javax.ws",
"org.oasis.datacore"
] | javax.ws; org.oasis.datacore; | 2,491,913 |
public boolean canReviseOwn() {
boolean canReviseOwn = false;
try {
Site site = SiteService.getSite(ToolManager.getCurrentPlacement().getContext());
canReviseOwn = SecurityService.unlock(
ContentHostingService.AUTH_RESOURCE_WRITE_OWN, site.getReference());
} catch (IdUnusedException e) {
logger.debug("ResourcesAction.canReviseOwn: cannot find current site");
}
return canReviseOwn;
} | boolean function() { boolean canReviseOwn = false; try { Site site = SiteService.getSite(ToolManager.getCurrentPlacement().getContext()); canReviseOwn = SecurityService.unlock( ContentHostingService.AUTH_RESOURCE_WRITE_OWN, site.getReference()); } catch (IdUnusedException e) { logger.debug(STR); } return canReviseOwn; } | /**
* Check if you have 'content.revise.own' in the site @return
* @return true if the user can revise
*/ | Check if you have 'content.revise.own' in the site @return | canReviseOwn | {
"repo_name": "noondaysun/sakai",
"path": "content/content-tool/tool/src/java/org/sakaiproject/content/tool/ResourcesAction.java",
"license": "apache-2.0",
"size": 337685
} | [
"org.sakaiproject.authz.cover.SecurityService",
"org.sakaiproject.content.cover.ContentHostingService",
"org.sakaiproject.exception.IdUnusedException",
"org.sakaiproject.site.api.Site",
"org.sakaiproject.site.cover.SiteService",
"org.sakaiproject.tool.cover.ToolManager"
] | import org.sakaiproject.authz.cover.SecurityService; import org.sakaiproject.content.cover.ContentHostingService; import org.sakaiproject.exception.IdUnusedException; import org.sakaiproject.site.api.Site; import org.sakaiproject.site.cover.SiteService; import org.sakaiproject.tool.cover.ToolManager; | import org.sakaiproject.authz.cover.*; import org.sakaiproject.content.cover.*; import org.sakaiproject.exception.*; import org.sakaiproject.site.api.*; import org.sakaiproject.site.cover.*; import org.sakaiproject.tool.cover.*; | [
"org.sakaiproject.authz",
"org.sakaiproject.content",
"org.sakaiproject.exception",
"org.sakaiproject.site",
"org.sakaiproject.tool"
] | org.sakaiproject.authz; org.sakaiproject.content; org.sakaiproject.exception; org.sakaiproject.site; org.sakaiproject.tool; | 2,312,236 |
ShardSpec getShardSpec(long timestamp, InputRow row); | ShardSpec getShardSpec(long timestamp, InputRow row); | /**
* Returns a {@link ShardSpec} for the given timestamp and the inputRow.
* The timestamp must be bucketed using {@code GranularitySpec#getQueryGranularity}.
*/ | Returns a <code>ShardSpec</code> for the given timestamp and the inputRow. The timestamp must be bucketed using GranularitySpec#getQueryGranularity | getShardSpec | {
"repo_name": "nishantmonu51/druid",
"path": "core/src/main/java/org/apache/druid/timeline/partition/ShardSpecLookup.java",
"license": "apache-2.0",
"size": 1168
} | [
"org.apache.druid.data.input.InputRow"
] | import org.apache.druid.data.input.InputRow; | import org.apache.druid.data.input.*; | [
"org.apache.druid"
] | org.apache.druid; | 2,317,720 |
@ResourceOperation(resource = Resource.CLUSTER, operation = Operation.MANAGE,
target = Target.DISK)
void setDiskUsageCriticalPercentage(float criticalPercent); | @ResourceOperation(resource = Resource.CLUSTER, operation = Operation.MANAGE, target = Target.DISK) void setDiskUsageCriticalPercentage(float criticalPercent); | /**
* Sets the value of the disk usage critical percentage.
*
* @param criticalPercent the critical percent
*/ | Sets the value of the disk usage critical percentage | setDiskUsageCriticalPercentage | {
"repo_name": "smanvi-pivotal/geode",
"path": "geode-core/src/main/java/org/apache/geode/management/DiskStoreMXBean.java",
"license": "apache-2.0",
"size": 7321
} | [
"org.apache.geode.management.internal.security.ResourceOperation",
"org.apache.geode.security.ResourcePermission"
] | import org.apache.geode.management.internal.security.ResourceOperation; import org.apache.geode.security.ResourcePermission; | import org.apache.geode.management.internal.security.*; import org.apache.geode.security.*; | [
"org.apache.geode"
] | org.apache.geode; | 2,408,154 |
@Override
public boolean isFieldExist(String fieldname) {
return DataInfo.isFieldExist(this.getType(), fieldname);
} | boolean function(String fieldname) { return DataInfo.isFieldExist(this.getType(), fieldname); } | /**
* Devuelve verdadero o falso si es que existe un campo o propiedad en el
* modelo de dato.
*
* @param fieldname nombre del campo
* @return verdadero si existe el campo en el modelo o falso si no.
*/ | Devuelve verdadero o falso si es que existe un campo o propiedad en el modelo de dato | isFieldExist | {
"repo_name": "jencisopy/JavaBeanStack",
"path": "business/src/main/java/org/javabeanstack/datactrl/AbstractDataObject.java",
"license": "lgpl-3.0",
"size": 65909
} | [
"org.javabeanstack.data.DataInfo"
] | import org.javabeanstack.data.DataInfo; | import org.javabeanstack.data.*; | [
"org.javabeanstack.data"
] | org.javabeanstack.data; | 1,339,315 |
public List<GpodnetTag> getTopTags(int count)
throws GpodnetServiceException {
URI uri;
try {
uri = new URI(BASE_SCHEME, BASE_HOST, String.format(
"/api/2/tags/%d.json", count), null);
} catch (URISyntaxException e1) {
e1.printStackTrace();
throw new IllegalStateException(e1);
}
HttpGet request = new HttpGet(uri);
String response = executeRequest(request);
try {
JSONArray jsonTagList = new JSONArray(response);
List<GpodnetTag> tagList = new ArrayList<GpodnetTag>(
jsonTagList.length());
for (int i = 0; i < jsonTagList.length(); i++) {
JSONObject jObj = jsonTagList.getJSONObject(i);
String name = jObj.getString("tag");
int usage = jObj.getInt("usage");
tagList.add(new GpodnetTag(name, usage));
}
return tagList;
} catch (JSONException e) {
e.printStackTrace();
throw new GpodnetServiceException(e);
}
} | List<GpodnetTag> function(int count) throws GpodnetServiceException { URI uri; try { uri = new URI(BASE_SCHEME, BASE_HOST, String.format( STR, count), null); } catch (URISyntaxException e1) { e1.printStackTrace(); throw new IllegalStateException(e1); } HttpGet request = new HttpGet(uri); String response = executeRequest(request); try { JSONArray jsonTagList = new JSONArray(response); List<GpodnetTag> tagList = new ArrayList<GpodnetTag>( jsonTagList.length()); for (int i = 0; i < jsonTagList.length(); i++) { JSONObject jObj = jsonTagList.getJSONObject(i); String name = jObj.getString("tag"); int usage = jObj.getInt("usage"); tagList.add(new GpodnetTag(name, usage)); } return tagList; } catch (JSONException e) { e.printStackTrace(); throw new GpodnetServiceException(e); } } | /**
* Returns the [count] most used tags.
*/ | Returns the [count] most used tags | getTopTags | {
"repo_name": "eric-stanley/AntennaPod",
"path": "src/de/danoeh/antennapod/gpoddernet/GpodnetService.java",
"license": "mit",
"size": 28085
} | [
"de.danoeh.antennapod.gpoddernet.model.GpodnetTag",
"java.net.URISyntaxException",
"java.util.ArrayList",
"java.util.List",
"org.apache.http.client.methods.HttpGet",
"org.json.JSONArray",
"org.json.JSONException",
"org.json.JSONObject"
] | import de.danoeh.antennapod.gpoddernet.model.GpodnetTag; import java.net.URISyntaxException; import java.util.ArrayList; import java.util.List; import org.apache.http.client.methods.HttpGet; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; | import de.danoeh.antennapod.gpoddernet.model.*; import java.net.*; import java.util.*; import org.apache.http.client.methods.*; import org.json.*; | [
"de.danoeh.antennapod",
"java.net",
"java.util",
"org.apache.http",
"org.json"
] | de.danoeh.antennapod; java.net; java.util; org.apache.http; org.json; | 2,816,436 |
ChannelBuf setDataView(int index, DataView data); | ChannelBuf setDataView(int index, DataView data); | /**
* Sets the {@link DataView} at the specified absolute index in this
* buffer. This method does not modify readerIndex or writerIndex
* of this buffer.
*
* @param index The index
* @param data The boolean data
* @return This stream for chaining
*/ | Sets the <code>DataView</code> at the specified absolute index in this buffer. This method does not modify readerIndex or writerIndex of this buffer | setDataView | {
"repo_name": "Kiskae/SpongeAPI",
"path": "src/main/java/org/spongepowered/api/network/ChannelBuf.java",
"license": "mit",
"size": 16582
} | [
"org.spongepowered.api.data.DataView"
] | import org.spongepowered.api.data.DataView; | import org.spongepowered.api.data.*; | [
"org.spongepowered.api"
] | org.spongepowered.api; | 848,989 |
public UsbCamera startAutomaticCapture(String name, String path) {
UsbCamera camera = new UsbCamera(name, path);
startAutomaticCapture(camera);
return camera;
} | UsbCamera function(String name, String path) { UsbCamera camera = new UsbCamera(name, path); startAutomaticCapture(camera); return camera; } | /**
* Start automatically capturing images to send to the dashboard.
*
* @param name The name to give the camera
* @param path The device path (e.g. "/dev/video0") of the camera
*/ | Start automatically capturing images to send to the dashboard | startAutomaticCapture | {
"repo_name": "pjreiniger/TempAllWpi",
"path": "wpilibj/src/main/java/edu/wpi/first/wpilibj/CameraServer.java",
"license": "bsd-3-clause",
"size": 24532
} | [
"edu.wpi.cscore.UsbCamera"
] | import edu.wpi.cscore.UsbCamera; | import edu.wpi.cscore.*; | [
"edu.wpi.cscore"
] | edu.wpi.cscore; | 1,530,436 |
protected void paintTextLines(Graphics g, JLabel label, FontMetrics fm) {
List<String> lines = getTextLines(label);
// Available component height to paint on.
int height = getAvailableHeight(label);
int textHeight = lines.size() * fm.getHeight();
while (textHeight > height) {
// Remove one line until no. of visible lines is found.
textHeight -= fm.getHeight();
}
paintTextR.height = Math.min(textHeight, height);
paintTextR.y = alignmentY(label, fm, paintTextR);
int textX = paintTextR.x;
int textY = paintTextR.y;
for (Iterator<String> it = lines.iterator(); it.hasNext()
&& paintTextR.contains(textX, textY + getAscent(fm)); textY += fm
.getHeight()) {
String text = it.next().trim();
if (it.hasNext()
&& !paintTextR.contains(textX, textY + fm.getHeight()
+ getAscent(fm))) {
// The last visible row, add a clip indication.
text = clip(text, fm, paintTextR);
}
int x = alignmentX(label, fm, text, paintTextR);
if (label.isEnabled()) {
paintEnabledText(label, g, text, x, textY);
} else {
paintDisabledText(label, g, text, x, textY);
}
}
} | void function(Graphics g, JLabel label, FontMetrics fm) { List<String> lines = getTextLines(label); int height = getAvailableHeight(label); int textHeight = lines.size() * fm.getHeight(); while (textHeight > height) { textHeight -= fm.getHeight(); } paintTextR.height = Math.min(textHeight, height); paintTextR.y = alignmentY(label, fm, paintTextR); int textX = paintTextR.x; int textY = paintTextR.y; for (Iterator<String> it = lines.iterator(); it.hasNext() && paintTextR.contains(textX, textY + getAscent(fm)); textY += fm .getHeight()) { String text = it.next().trim(); if (it.hasNext() && !paintTextR.contains(textX, textY + fm.getHeight() + getAscent(fm))) { text = clip(text, fm, paintTextR); } int x = alignmentX(label, fm, text, paintTextR); if (label.isEnabled()) { paintEnabledText(label, g, text, x, textY); } else { paintDisabledText(label, g, text, x, textY); } } } | /**
* Paint the wrapped text lines.
*
* @param g
* graphics component to paint on
* @param label
* the label being painted
* @param fm
* font metrics for current font
*/ | Paint the wrapped text lines | paintTextLines | {
"repo_name": "i2p/i2p.itoopie",
"path": "src/net/i2p/itoopie/gui/component/multilinelabel/MultiLineLabelUI.java",
"license": "apache-2.0",
"size": 20147
} | [
"java.awt.FontMetrics",
"java.awt.Graphics",
"java.util.Iterator",
"java.util.List",
"javax.swing.JLabel"
] | import java.awt.FontMetrics; import java.awt.Graphics; import java.util.Iterator; import java.util.List; import javax.swing.JLabel; | import java.awt.*; import java.util.*; import javax.swing.*; | [
"java.awt",
"java.util",
"javax.swing"
] | java.awt; java.util; javax.swing; | 595,446 |
@Deprecated
public void setTargetAddress(final IeeeAddress targetAddress) {
this.targetAddress = targetAddress;
} | void function(final IeeeAddress targetAddress) { this.targetAddress = targetAddress; } | /**
* Sets Target Address.
*
* @param targetAddress the Target Address
* @deprecated as of 1.3.0. Use the parameterised constructor instead to ensure that all mandatory fields are provided.
*/ | Sets Target Address | setTargetAddress | {
"repo_name": "zsmartsystems/com.zsmartsystems.zigbee",
"path": "com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/rssilocation/GetLocationDataCommand.java",
"license": "epl-1.0",
"size": 5390
} | [
"com.zsmartsystems.zigbee.IeeeAddress"
] | import com.zsmartsystems.zigbee.IeeeAddress; | import com.zsmartsystems.zigbee.*; | [
"com.zsmartsystems.zigbee"
] | com.zsmartsystems.zigbee; | 2,094,678 |
if ( ConfigFactory.isValidPath( configPath ) == false ) {
throw new IllegalArgumentException( "The give path is not valid." );
}
try {
final Enumeration keys = config.getConfigProperties();
final Preferences pref = base.node( configPath );
pref.clear();
while ( keys.hasMoreElements() ) {
final String key = (String) keys.nextElement();
final String value = config.getConfigProperty( key );
if ( value != null ) {
pref.put( key, value );
}
}
pref.sync();
} catch ( BackingStoreException be ) {
throw new ConfigStoreException( "Failed to store config" + configPath, be );
}
} | if ( ConfigFactory.isValidPath( configPath ) == false ) { throw new IllegalArgumentException( STR ); } try { final Enumeration keys = config.getConfigProperties(); final Preferences pref = base.node( configPath ); pref.clear(); while ( keys.hasMoreElements() ) { final String key = (String) keys.nextElement(); final String value = config.getConfigProperty( key ); if ( value != null ) { pref.put( key, value ); } } pref.sync(); } catch ( BackingStoreException be ) { throw new ConfigStoreException( STR + configPath, be ); } } | /**
* Stores the given properties on the defined path.
*
* @param configPath
* the path on where to store the properties.
* @param config
* the properties which should be stored.
* @throws ConfigStoreException
* if an error occurred.
*/ | Stores the given properties on the defined path | store | {
"repo_name": "EgorZhuk/pentaho-reporting",
"path": "engine/extensions/src/main/java/org/pentaho/reporting/engine/classic/extensions/modules/java14config/Java14ConfigStorage.java",
"license": "lgpl-2.1",
"size": 5379
} | [
"java.util.Enumeration",
"java.util.prefs.BackingStoreException",
"java.util.prefs.Preferences",
"org.pentaho.reporting.engine.classic.core.modules.misc.configstore.base.ConfigFactory",
"org.pentaho.reporting.engine.classic.core.modules.misc.configstore.base.ConfigStoreException"
] | import java.util.Enumeration; import java.util.prefs.BackingStoreException; import java.util.prefs.Preferences; import org.pentaho.reporting.engine.classic.core.modules.misc.configstore.base.ConfigFactory; import org.pentaho.reporting.engine.classic.core.modules.misc.configstore.base.ConfigStoreException; | import java.util.*; import java.util.prefs.*; import org.pentaho.reporting.engine.classic.core.modules.misc.configstore.base.*; | [
"java.util",
"org.pentaho.reporting"
] | java.util; org.pentaho.reporting; | 2,101,243 |
@Override
public String format(final LogRecord record) {
String msg;
String threadInfo = Thread.currentThread().getName();
Throwable thrown = record.getThrown();
String clazz = className(record.getSourceClassName());
String where =
String.format("[%s] (%s.java:%s)", threadInfo, clazz, record.getSourceMethodName());
where = String.format("%s", where);
if (thrown == null) {
msg = String.format("%-7s %s - %s %n", record.getLevel(), where, record.getMessage());
} else {
StackTraceElement stack = thrown.getStackTrace()[0];
String errorClazz = stack.getClassName();
int errorLine = stack.getLineNumber();
msg =
String.format(
"%-7s %s %s %s:%d %s%n",
record.getLevel(),
where,
record.getMessage(),
errorClazz,
errorLine,
thrown.getMessage());
}
return msg;
}
} | String function(final LogRecord record) { String msg; String threadInfo = Thread.currentThread().getName(); Throwable thrown = record.getThrown(); String clazz = className(record.getSourceClassName()); String where = String.format(STR, threadInfo, clazz, record.getSourceMethodName()); where = String.format("%s", where); if (thrown == null) { msg = String.format(STR, record.getLevel(), where, record.getMessage()); } else { StackTraceElement stack = thrown.getStackTrace()[0]; String errorClazz = stack.getClassName(); int errorLine = stack.getLineNumber(); msg = String.format( STR, record.getLevel(), where, record.getMessage(), errorClazz, errorLine, thrown.getMessage()); } return msg; } } | /**
* Provide formatted logging strings.
*
* @param record LogRecord to use.
* @return String the formatted output.
*/ | Provide formatted logging strings | format | {
"repo_name": "axkr/symja_android_library",
"path": "symja_android_library/matheclipse-external/src/main/java/de/lab4inf/math/L4MLogger.java",
"license": "gpl-3.0",
"size": 11043
} | [
"java.lang.String",
"java.util.logging.LogRecord"
] | import java.lang.String; import java.util.logging.LogRecord; | import java.lang.*; import java.util.logging.*; | [
"java.lang",
"java.util"
] | java.lang; java.util; | 53,346 |
private ActiveScan getActiveScan(JSONObject params) throws ApiException {
int id = getParam(params, PARAM_SCAN_ID, -1);
GenericScanner2 activeScan = null;
if (id == -1) {
activeScan = controller.getLastScan();
} else {
activeScan = controller.getScan(id);
}
if (activeScan == null) {
throw new ApiException(ApiException.Type.DOES_NOT_EXIST, PARAM_SCAN_ID);
}
return (ActiveScan)activeScan;
} | ActiveScan function(JSONObject params) throws ApiException { int id = getParam(params, PARAM_SCAN_ID, -1); GenericScanner2 activeScan = null; if (id == -1) { activeScan = controller.getLastScan(); } else { activeScan = controller.getScan(id); } if (activeScan == null) { throw new ApiException(ApiException.Type.DOES_NOT_EXIST, PARAM_SCAN_ID); } return (ActiveScan)activeScan; } | /**
* Returns a {@link ActiveScan} from the available active scans or the last active scan. If a scan ID (
* {@link #PARAM_SCAN_ID}) is present in the given {@code params} it will be used to the get the {@code ActiveScan} from the
* available active scans, otherwise it's returned the last active scan.
*
* @param params the parameters of the API call
* @return the {@code ActiveScan} with the given scan ID or, if not present, the last active scan
* @throws ApiException if there's no scan with the given scan ID
*/ | Returns a <code>ActiveScan</code> from the available active scans or the last active scan. If a scan ID ( <code>#PARAM_SCAN_ID</code>) is present in the given params it will be used to the get the ActiveScan from the available active scans, otherwise it's returned the last active scan | getActiveScan | {
"repo_name": "zapbot/zaproxy",
"path": "src/org/zaproxy/zap/extension/ascan/ActiveScanAPI.java",
"license": "apache-2.0",
"size": 49184
} | [
"net.sf.json.JSONObject",
"org.zaproxy.zap.extension.api.ApiException",
"org.zaproxy.zap.model.GenericScanner2"
] | import net.sf.json.JSONObject; import org.zaproxy.zap.extension.api.ApiException; import org.zaproxy.zap.model.GenericScanner2; | import net.sf.json.*; import org.zaproxy.zap.extension.api.*; import org.zaproxy.zap.model.*; | [
"net.sf.json",
"org.zaproxy.zap"
] | net.sf.json; org.zaproxy.zap; | 122,010 |
public void initializePackageContents()
{
if (isInitialized) return;
isInitialized = true;
// Initialize package
setName(eNAME);
setNsPrefix(eNS_PREFIX);
setNsURI(eNS_URI);
// Create type parameters
// Set bounds for type parameters
// Add supertypes to classes
// Initialize classes and features; add operations and parameters
initEClass(modelBmodesbmiEClass, ModelBmodesbmi.class, "ModelBmodesbmi", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getModelBmodesbmi_Head(), this.getHeader(), null, "Head", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_Sec(), this.getSection(), null, "sec", null, 0, -1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_Echo(), this.getbEcho(), null, "Echo", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_BeamType(), this.getiBeamType(), null, "BeamType", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_RotRpm(), this.getnRotRpm(), null, "RotRpm", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_RpmMult(), this.getnRpmMult(), null, "RpmMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_Radius(), this.getnRadius(), null, "Radius", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_HubRad(), this.getnHubRad(), null, "HubRad", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_PreCone(), this.getnPrecone(), null, "PreCone", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_BlThp(), this.getnBlThp(), null, "BlThp", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_HubConn(), this.getiHubConn(), null, "HubConn", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_ModePr(), this.getiModePr(), null, "ModePr", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TabDelim(), this.getbTabDelim(), null, "TabDelim", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_MidNodeTw(), this.getbMidNodeTw(), null, "MidNodeTw", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TipMass(), this.getnTipMass(), null, "TipMass", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_CmLoc(), this.getnCmLoc(), null, "CmLoc", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_CmAxial(), this.getnCmAxial(), null, "CmAxial", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IxxTip(), this.getnIxxTip(), null, "IxxTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IyyTip(), this.getnIyyTip(), null, "IyyTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IzzTip(), this.getnIzzTip(), null, "IzzTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IxyTip(), this.getnIxyTip(), null, "IxyTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IzxTip(), this.getnIzxTip(), null, "IzxTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IyzTip(), this.getnIyzTip(), null, "IyzTip", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_IdMat(), this.getiIdMat(), null, "IdMat", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_SecFile(), this.getiSecFile(), null, "SecFile", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_SecMasMult(), this.getnSecMasMult(), null, "SecMasMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_FlpInrMult(), this.getnFlpInrMult(), null, "FlpInrMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_LagInrMult(), this.getnLagInrMult(), null, "LagInrMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_FlpstfMult(), this.getnFlpstfMult(), null, "FlpstfMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_EdgStfMult(), this.getnEdgStfMult(), null, "EdgStfMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TorStfMult(), this.getnTorStfMult(), null, "TorStfMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_AxiStfMult(), this.getnAxiStfMult(), null, "AxiStfMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_CgOffsMult(), this.getnCgOffsMult(), null, "CgOffsMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_ScOffsMult(), this.getnScOffsMult(), null, "ScOffsMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TcOffsMult(), this.getnTcOffsMult(), null, "TcOffsMult", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_NSelt(), this.getiNSelt(), null, "NSelt", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_ElLoc(), this.getaElLoc(), null, "ElLoc", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TwrSupport(), this.getiTwrSupport(), null, "TwrSupport", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TwrAttach(), this.getiTwrAttach(), null, "TwrAttach", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_TwrWires(), this.getaTwrWires(), null, "TwrWires", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_NodeAttach(), this.getaNodeAttach(), null, "NodeAttach", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_WireStiff(), this.getaWireStiff(), null, "WireStiff", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getModelBmodesbmi_WireAngle(), this.getaWireAngle(), null, "WireAngle", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(headerEClass, Header.class, "Header", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getHeader_Name(), ecorePackage.getEString(), "name", null, 0, 1, Header.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getHeader_Desc(), ecorePackage.getEString(), "desc", null, 0, 1, Header.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(sectionEClass, Section.class, "Section", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getSection_Name(), ecorePackage.getEString(), "name", null, 0, 1, Section.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(bEchoEClass, bEcho.class, "bEcho", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getbEcho_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bEcho.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getbEcho_Name(), ecorePackage.getEString(), "name", null, 0, 1, bEcho.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iBeamTypeEClass, iBeamType.class, "iBeamType", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiBeamType_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iBeamType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiBeamType_Name(), ecorePackage.getEString(), "name", null, 0, 1, iBeamType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nRotRpmEClass, nRotRpm.class, "nRotRpm", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnRotRpm_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRotRpm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnRotRpm_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRotRpm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nRpmMultEClass, nRpmMult.class, "nRpmMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnRpmMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRpmMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnRpmMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRpmMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nRadiusEClass, nRadius.class, "nRadius", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnRadius_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRadius.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnRadius_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRadius.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nHubRadEClass, nHubRad.class, "nHubRad", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnHubRad_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nHubRad.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnHubRad_Name(), ecorePackage.getEString(), "name", null, 0, 1, nHubRad.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nPreconeEClass, nPrecone.class, "nPrecone", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnPrecone_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nPrecone.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnPrecone_Name(), ecorePackage.getEString(), "name", null, 0, 1, nPrecone.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nBlThpEClass, nBlThp.class, "nBlThp", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnBlThp_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nBlThp.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnBlThp_Name(), ecorePackage.getEString(), "name", null, 0, 1, nBlThp.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iHubConnEClass, iHubConn.class, "iHubConn", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiHubConn_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iHubConn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiHubConn_Name(), ecorePackage.getEString(), "name", null, 0, 1, iHubConn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iModePrEClass, iModePr.class, "iModePr", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiModePr_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iModePr.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiModePr_Name(), ecorePackage.getEString(), "name", null, 0, 1, iModePr.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(bTabDelimEClass, bTabDelim.class, "bTabDelim", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getbTabDelim_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bTabDelim.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getbTabDelim_Name(), ecorePackage.getEString(), "name", null, 0, 1, bTabDelim.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(bMidNodeTwEClass, bMidNodeTw.class, "bMidNodeTw", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getbMidNodeTw_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bMidNodeTw.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getbMidNodeTw_Name(), ecorePackage.getEString(), "name", null, 0, 1, bMidNodeTw.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nTipMassEClass, nTipMass.class, "nTipMass", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnTipMass_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTipMass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnTipMass_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTipMass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nCmLocEClass, nCmLoc.class, "nCmLoc", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnCmLoc_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCmLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnCmLoc_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCmLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nCmAxialEClass, nCmAxial.class, "nCmAxial", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnCmAxial_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCmAxial.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnCmAxial_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCmAxial.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIxxTipEClass, nIxxTip.class, "nIxxTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIxxTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIxxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIxxTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIxxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIyyTipEClass, nIyyTip.class, "nIyyTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIyyTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIyyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIyyTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIyyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIzzTipEClass, nIzzTip.class, "nIzzTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIzzTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIzzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIzzTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIzzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIxyTipEClass, nIxyTip.class, "nIxyTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIxyTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIxyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIxyTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIxyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIzxTipEClass, nIzxTip.class, "nIzxTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIzxTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIzxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIzxTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIzxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nIyzTipEClass, nIyzTip.class, "nIyzTip", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnIyzTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIyzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnIyzTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIyzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iIdMatEClass, iIdMat.class, "iIdMat", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiIdMat_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iIdMat.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiIdMat_Name(), ecorePackage.getEString(), "name", null, 0, 1, iIdMat.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iSecFileEClass, iSecFile.class, "iSecFile", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiSecFile_Value(), ecorePackage.getEString(), "value", null, 0, 1, iSecFile.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiSecFile_Name(), ecorePackage.getEString(), "name", null, 0, 1, iSecFile.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nSecMasMultEClass, nSecMasMult.class, "nSecMasMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnSecMasMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nSecMasMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnSecMasMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nSecMasMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nFlpInrMultEClass, nFlpInrMult.class, "nFlpInrMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnFlpInrMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nFlpInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnFlpInrMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nFlpInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nLagInrMultEClass, nLagInrMult.class, "nLagInrMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnLagInrMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nLagInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnLagInrMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nLagInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nFlpstfMultEClass, nFlpstfMult.class, "nFlpstfMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnFlpstfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nFlpstfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnFlpstfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nFlpstfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nEdgStfMultEClass, nEdgStfMult.class, "nEdgStfMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnEdgStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nEdgStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnEdgStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nEdgStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nTorStfMultEClass, nTorStfMult.class, "nTorStfMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnTorStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTorStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnTorStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTorStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nAxiStfMultEClass, nAxiStfMult.class, "nAxiStfMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnAxiStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nAxiStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnAxiStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nAxiStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nCgOffsMultEClass, nCgOffsMult.class, "nCgOffsMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnCgOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCgOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnCgOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCgOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nScOffsMultEClass, nScOffsMult.class, "nScOffsMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnScOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nScOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnScOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nScOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(nTcOffsMultEClass, nTcOffsMult.class, "nTcOffsMult", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getnTcOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTcOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getnTcOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTcOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iNSeltEClass, iNSelt.class, "iNSelt", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiNSelt_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iNSelt.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiNSelt_Name(), ecorePackage.getEString(), "name", null, 0, 1, iNSelt.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(aElLocEClass, aElLoc.class, "aElLoc", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getaElLoc_El_loc(), ecorePackage.getEFloat(), "el_loc", null, 0, -1, aElLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iTwrSupportEClass, iTwrSupport.class, "iTwrSupport", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiTwrSupport_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iTwrSupport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiTwrSupport_Name(), ecorePackage.getEString(), "name", null, 0, 1, iTwrSupport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(iTwrAttachEClass, iTwrAttach.class, "iTwrAttach", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getiTwrAttach_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iTwrAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getiTwrAttach_Name(), ecorePackage.getEString(), "name", null, 0, 1, iTwrAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(aTwrWiresEClass, aTwrWires.class, "aTwrWires", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getaTwrWires_El_loc(), ecorePackage.getEInt(), "el_loc", null, 0, -1, aTwrWires.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getaTwrWires_Name(), ecorePackage.getEString(), "name", null, 0, 1, aTwrWires.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(aNodeAttachEClass, aNodeAttach.class, "aNodeAttach", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getaNodeAttach_El_loc(), ecorePackage.getEInt(), "el_loc", null, 0, -1, aNodeAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getaNodeAttach_Name(), ecorePackage.getEString(), "name", null, 0, 1, aNodeAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(aWireStiffEClass, aWireStiff.class, "aWireStiff", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getaWireStiff_El_loc(), ecorePackage.getEFloat(), "el_loc", null, 0, -1, aWireStiff.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getaWireStiff_Name(), ecorePackage.getEString(), "name", null, 0, 1, aWireStiff.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(aWireAngleEClass, aWireAngle.class, "aWireAngle", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getaWireAngle_El_loc(), ecorePackage.getEFloat(), "el_loc", null, 0, -1, aWireAngle.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getaWireAngle_Name(), ecorePackage.getEString(), "name", null, 0, 1, aWireAngle.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
// Create resource
createResource(eNS_URI);
} | void function() { if (isInitialized) return; isInitialized = true; setName(eNAME); setNsPrefix(eNS_PREFIX); setNsURI(eNS_URI); initEClass(modelBmodesbmiEClass, ModelBmodesbmi.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getModelBmodesbmi_Head(), this.getHeader(), null, "Head", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_Sec(), this.getSection(), null, "sec", null, 0, -1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_Echo(), this.getbEcho(), null, "Echo", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_BeamType(), this.getiBeamType(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_RotRpm(), this.getnRotRpm(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_RpmMult(), this.getnRpmMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_Radius(), this.getnRadius(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_HubRad(), this.getnHubRad(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_PreCone(), this.getnPrecone(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_BlThp(), this.getnBlThp(), null, "BlThp", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_HubConn(), this.getiHubConn(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_ModePr(), this.getiModePr(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TabDelim(), this.getbTabDelim(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_MidNodeTw(), this.getbMidNodeTw(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TipMass(), this.getnTipMass(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_CmLoc(), this.getnCmLoc(), null, "CmLoc", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_CmAxial(), this.getnCmAxial(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IxxTip(), this.getnIxxTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IyyTip(), this.getnIyyTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IzzTip(), this.getnIzzTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IxyTip(), this.getnIxyTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IzxTip(), this.getnIzxTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IyzTip(), this.getnIyzTip(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_IdMat(), this.getiIdMat(), null, "IdMat", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_SecFile(), this.getiSecFile(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_SecMasMult(), this.getnSecMasMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_FlpInrMult(), this.getnFlpInrMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_LagInrMult(), this.getnLagInrMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_FlpstfMult(), this.getnFlpstfMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_EdgStfMult(), this.getnEdgStfMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TorStfMult(), this.getnTorStfMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_AxiStfMult(), this.getnAxiStfMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_CgOffsMult(), this.getnCgOffsMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_ScOffsMult(), this.getnScOffsMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TcOffsMult(), this.getnTcOffsMult(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_NSelt(), this.getiNSelt(), null, "NSelt", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_ElLoc(), this.getaElLoc(), null, "ElLoc", null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TwrSupport(), this.getiTwrSupport(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TwrAttach(), this.getiTwrAttach(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_TwrWires(), this.getaTwrWires(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_NodeAttach(), this.getaNodeAttach(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_WireStiff(), this.getaWireStiff(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getModelBmodesbmi_WireAngle(), this.getaWireAngle(), null, STR, null, 0, 1, ModelBmodesbmi.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(headerEClass, Header.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getHeader_Name(), ecorePackage.getEString(), "name", null, 0, 1, Header.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getHeader_Desc(), ecorePackage.getEString(), "desc", null, 0, 1, Header.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(sectionEClass, Section.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getSection_Name(), ecorePackage.getEString(), "name", null, 0, 1, Section.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(bEchoEClass, bEcho.class, "bEcho", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getbEcho_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bEcho.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getbEcho_Name(), ecorePackage.getEString(), "name", null, 0, 1, bEcho.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iBeamTypeEClass, iBeamType.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiBeamType_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iBeamType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiBeamType_Name(), ecorePackage.getEString(), "name", null, 0, 1, iBeamType.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nRotRpmEClass, nRotRpm.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnRotRpm_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRotRpm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnRotRpm_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRotRpm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nRpmMultEClass, nRpmMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnRpmMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRpmMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnRpmMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRpmMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nRadiusEClass, nRadius.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnRadius_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nRadius.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnRadius_Name(), ecorePackage.getEString(), "name", null, 0, 1, nRadius.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nHubRadEClass, nHubRad.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnHubRad_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nHubRad.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnHubRad_Name(), ecorePackage.getEString(), "name", null, 0, 1, nHubRad.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nPreconeEClass, nPrecone.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnPrecone_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nPrecone.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnPrecone_Name(), ecorePackage.getEString(), "name", null, 0, 1, nPrecone.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nBlThpEClass, nBlThp.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnBlThp_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nBlThp.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnBlThp_Name(), ecorePackage.getEString(), "name", null, 0, 1, nBlThp.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iHubConnEClass, iHubConn.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiHubConn_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iHubConn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiHubConn_Name(), ecorePackage.getEString(), "name", null, 0, 1, iHubConn.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iModePrEClass, iModePr.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiModePr_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iModePr.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiModePr_Name(), ecorePackage.getEString(), "name", null, 0, 1, iModePr.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(bTabDelimEClass, bTabDelim.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getbTabDelim_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bTabDelim.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getbTabDelim_Name(), ecorePackage.getEString(), "name", null, 0, 1, bTabDelim.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(bMidNodeTwEClass, bMidNodeTw.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getbMidNodeTw_Value(), ecorePackage.getEBoolean(), "value", null, 0, 1, bMidNodeTw.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getbMidNodeTw_Name(), ecorePackage.getEString(), "name", null, 0, 1, bMidNodeTw.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nTipMassEClass, nTipMass.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnTipMass_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTipMass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnTipMass_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTipMass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nCmLocEClass, nCmLoc.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnCmLoc_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCmLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnCmLoc_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCmLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nCmAxialEClass, nCmAxial.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnCmAxial_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCmAxial.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnCmAxial_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCmAxial.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIxxTipEClass, nIxxTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIxxTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIxxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIxxTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIxxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIyyTipEClass, nIyyTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIyyTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIyyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIyyTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIyyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIzzTipEClass, nIzzTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIzzTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIzzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIzzTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIzzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIxyTipEClass, nIxyTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIxyTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIxyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIxyTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIxyTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIzxTipEClass, nIzxTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIzxTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIzxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIzxTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIzxTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nIyzTipEClass, nIyzTip.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnIyzTip_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nIyzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnIyzTip_Name(), ecorePackage.getEString(), "name", null, 0, 1, nIyzTip.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iIdMatEClass, iIdMat.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiIdMat_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iIdMat.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiIdMat_Name(), ecorePackage.getEString(), "name", null, 0, 1, iIdMat.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iSecFileEClass, iSecFile.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiSecFile_Value(), ecorePackage.getEString(), "value", null, 0, 1, iSecFile.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiSecFile_Name(), ecorePackage.getEString(), "name", null, 0, 1, iSecFile.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nSecMasMultEClass, nSecMasMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnSecMasMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nSecMasMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnSecMasMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nSecMasMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nFlpInrMultEClass, nFlpInrMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnFlpInrMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nFlpInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnFlpInrMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nFlpInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nLagInrMultEClass, nLagInrMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnLagInrMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nLagInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnLagInrMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nLagInrMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nFlpstfMultEClass, nFlpstfMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnFlpstfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nFlpstfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnFlpstfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nFlpstfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nEdgStfMultEClass, nEdgStfMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnEdgStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nEdgStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnEdgStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nEdgStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nTorStfMultEClass, nTorStfMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnTorStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTorStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnTorStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTorStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nAxiStfMultEClass, nAxiStfMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnAxiStfMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nAxiStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnAxiStfMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nAxiStfMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nCgOffsMultEClass, nCgOffsMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnCgOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nCgOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnCgOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nCgOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nScOffsMultEClass, nScOffsMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnScOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nScOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnScOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nScOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(nTcOffsMultEClass, nTcOffsMult.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getnTcOffsMult_Value(), ecorePackage.getEFloat(), "value", null, 0, 1, nTcOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getnTcOffsMult_Name(), ecorePackage.getEString(), "name", null, 0, 1, nTcOffsMult.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iNSeltEClass, iNSelt.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiNSelt_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iNSelt.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiNSelt_Name(), ecorePackage.getEString(), "name", null, 0, 1, iNSelt.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(aElLocEClass, aElLoc.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getaElLoc_El_loc(), ecorePackage.getEFloat(), STR, null, 0, -1, aElLoc.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iTwrSupportEClass, iTwrSupport.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiTwrSupport_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iTwrSupport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiTwrSupport_Name(), ecorePackage.getEString(), "name", null, 0, 1, iTwrSupport.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(iTwrAttachEClass, iTwrAttach.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getiTwrAttach_Value(), ecorePackage.getEInt(), "value", null, 0, 1, iTwrAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getiTwrAttach_Name(), ecorePackage.getEString(), "name", null, 0, 1, iTwrAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(aTwrWiresEClass, aTwrWires.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getaTwrWires_El_loc(), ecorePackage.getEInt(), STR, null, 0, -1, aTwrWires.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getaTwrWires_Name(), ecorePackage.getEString(), "name", null, 0, 1, aTwrWires.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(aNodeAttachEClass, aNodeAttach.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getaNodeAttach_El_loc(), ecorePackage.getEInt(), STR, null, 0, -1, aNodeAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getaNodeAttach_Name(), ecorePackage.getEString(), "name", null, 0, 1, aNodeAttach.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(aWireStiffEClass, aWireStiff.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getaWireStiff_El_loc(), ecorePackage.getEFloat(), STR, null, 0, -1, aWireStiff.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getaWireStiff_Name(), ecorePackage.getEString(), "name", null, 0, 1, aWireStiff.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(aWireAngleEClass, aWireAngle.class, STR, !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getaWireAngle_El_loc(), ecorePackage.getEFloat(), STR, null, 0, -1, aWireAngle.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEAttribute(getaWireAngle_Name(), ecorePackage.getEString(), "name", null, 0, 1, aWireAngle.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); createResource(eNS_URI); } | /**
* Complete the initialization of the package and its meta-model. This
* method is guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/ | Complete the initialization of the package and its meta-model. This method is guarded to have no affect on any invocation but its first. | initializePackageContents | {
"repo_name": "cooked/NDT",
"path": "sc.ndt.editor.bmodes.bmi/src-gen/sc/ndt/editor/bmodes/bmodesbmi/impl/BmodesbmiPackageImpl.java",
"license": "gpl-3.0",
"size": 88911
} | [
"sc.ndt.editor.bmodes.bmodesbmi.Header",
"sc.ndt.editor.bmodes.bmodesbmi.ModelBmodesbmi",
"sc.ndt.editor.bmodes.bmodesbmi.Section"
] | import sc.ndt.editor.bmodes.bmodesbmi.Header; import sc.ndt.editor.bmodes.bmodesbmi.ModelBmodesbmi; import sc.ndt.editor.bmodes.bmodesbmi.Section; | import sc.ndt.editor.bmodes.bmodesbmi.*; | [
"sc.ndt.editor"
] | sc.ndt.editor; | 1,223,461 |
public final String getPrePlannedCollectionTechnique() throws NitfFormatException {
switch (getPrePlannedCollectionTechniqueEncoded()) {
case VERTICAL_COLLECTION_TECHNIQUE:
return "vertical";
case FORWARD_OBLIQUE_COLLECTION_TECHNIQUE:
return "forward oblique";
case RIGHT_OBLIQUE_COLLECTION_TECHNIQUE:
return "right oblique";
case LEFT_OBLIQUE_COLLECTION_TECHNIQUE:
return "left oblique";
case BEST_POSSIBLE_COLLECTION_TECHNIQUE:
return "best possible";
default:
return "unknown";
}
} | final String function() throws NitfFormatException { switch (getPrePlannedCollectionTechniqueEncoded()) { case VERTICAL_COLLECTION_TECHNIQUE: return STR; case FORWARD_OBLIQUE_COLLECTION_TECHNIQUE: return STR; case RIGHT_OBLIQUE_COLLECTION_TECHNIQUE: return STR; case LEFT_OBLIQUE_COLLECTION_TECHNIQUE: return STR; case BEST_POSSIBLE_COLLECTION_TECHNIQUE: return STR; default: return STR; } } | /**
* Get the Pre-Planned Collection Technique (TGT_COLL) decoded.
*
* <ul>
* <li>0 = vertical
* <li>1 = forward oblique
* <li>2 = right oblique
* <li>3 = left oblique
* <li>4 = best possible
* </ul>
*
* @return the collection technique as a decoded string, or "unknown"
* @throws NitfFormatException if there was a problem during parsing.
*/ | Get the Pre-Planned Collection Technique (TGT_COLL) decoded. 0 = vertical 1 = forward oblique 2 = right oblique 3 = left oblique 4 = best possible | getPrePlannedCollectionTechnique | {
"repo_name": "codice/imaging-nitf",
"path": "trewrap/src/main/java/org/codice/imaging/nitf/trewrap/MSTGTA.java",
"license": "lgpl-2.1",
"size": 17036
} | [
"org.codice.imaging.nitf.core.common.NitfFormatException"
] | import org.codice.imaging.nitf.core.common.NitfFormatException; | import org.codice.imaging.nitf.core.common.*; | [
"org.codice.imaging"
] | org.codice.imaging; | 2,538,934 |
@Override
public void setLogWriter(PrintWriter out) {
_logWriter = out;
}
private PrintWriter _logWriter = null;
private final ObjectPool<C> _pool; | void function(PrintWriter out) { _logWriter = out; } private PrintWriter _logWriter = null; private final ObjectPool<C> _pool; | /**
* Sets my log writer.
* @see DataSource#setLogWriter
*/ | Sets my log writer | setLogWriter | {
"repo_name": "plumer/codana",
"path": "tomcat_files/8.0.22/PoolingDataSource.java",
"license": "mit",
"size": 7767
} | [
"java.io.PrintWriter",
"org.apache.tomcat.dbcp.pool2.ObjectPool"
] | import java.io.PrintWriter; import org.apache.tomcat.dbcp.pool2.ObjectPool; | import java.io.*; import org.apache.tomcat.dbcp.pool2.*; | [
"java.io",
"org.apache.tomcat"
] | java.io; org.apache.tomcat; | 1,911,848 |
public String getID();
/**
* <p>Converts the given "layout" attribute to a <code>LayoutManager</code>
* instance. The attribute value always starts with the layout identifier
* (see {@link #getID()}) followed by optional parameters.</p>
*
* <p>If the layout converter does not use the "layout" attribute, this method
* should return <code>null</code>, but then {@link #convertLayoutElement} | String function(); /** * <p>Converts the given STR attribute to a <code>LayoutManager</code> * instance. The attribute value always starts with the layout identifier * (see {@link #getID()}) followed by optional parameters.</p> * * <p>If the layout converter does not use the STR attribute, this method * should return <code>null</code>, but then {@link #convertLayoutElement} | /**
* Returns the unique identifier of the layout converter. E.g. "flowlayout".
* This identifier is used in "layout" attributes and elements to specify the
* layout manager.
*/ | Returns the unique identifier of the layout converter. E.g. "flowlayout". This identifier is used in "layout" attributes and elements to specify the layout manager | getID | {
"repo_name": "boyjimeking/paintown",
"path": "editor/src/swixml_220/src/org/swixml/LayoutConverter.java",
"license": "bsd-3-clause",
"size": 5290
} | [
"java.awt.LayoutManager"
] | import java.awt.LayoutManager; | import java.awt.*; | [
"java.awt"
] | java.awt; | 269,742 |
@Test
public void testConvenienceFactoriesTypes() throws Exception {
assertType(INTEGER,
attr("x", INTEGER).build());
assertType(INTEGER, attr("x", INTEGER).value(StarlarkInt.of(42)).build());
assertType(STRING,
attr("x", STRING).build());
assertType(STRING,
attr("x", STRING).value("foo").build());
Label label = Label.parseAbsolute("//foo:bar", ImmutableMap.of());
assertType(LABEL,
attr("x", LABEL).legacyAllowAnyFileType().build());
assertType(LABEL,
attr("x", LABEL).legacyAllowAnyFileType().value(label).build());
List<String> slist = Arrays.asList("foo", "bar");
assertType(STRING_LIST,
attr("x", STRING_LIST).build());
assertType(STRING_LIST,
attr("x", STRING_LIST).value(slist).build());
List<Label> llist =
Arrays.asList(
Label.parseAbsolute("//foo:bar", ImmutableMap.of()),
Label.parseAbsolute("//foo:wiz", ImmutableMap.of()));
assertType(LABEL_LIST,
attr("x", LABEL_LIST).legacyAllowAnyFileType().build());
assertType(LABEL_LIST,
attr("x", LABEL_LIST).legacyAllowAnyFileType().value(llist).build());
} | void function() throws Exception { assertType(INTEGER, attr("x", INTEGER).build()); assertType(INTEGER, attr("x", INTEGER).value(StarlarkInt.of(42)).build()); assertType(STRING, attr("x", STRING).build()); assertType(STRING, attr("x", STRING).value("foo").build()); Label label = Label.parseAbsolute(STRxSTRxSTRfooSTRbarSTRxSTRxSTR Label.parseAbsolute(STRxSTRx", LABEL_LIST).legacyAllowAnyFileType().value(llist).build()); } | /**
* Tests the "convenience factories" (string, label, etc) for types.
*/ | Tests the "convenience factories" (string, label, etc) for types | testConvenienceFactoriesTypes | {
"repo_name": "davidzchen/bazel",
"path": "src/test/java/com/google/devtools/build/lib/packages/AttributeTest.java",
"license": "apache-2.0",
"size": 12907
} | [
"com.google.devtools.build.lib.cmdline.Label",
"com.google.devtools.build.lib.packages.Attribute",
"net.starlark.java.eval.StarlarkInt"
] | import com.google.devtools.build.lib.cmdline.Label; import com.google.devtools.build.lib.packages.Attribute; import net.starlark.java.eval.StarlarkInt; | import com.google.devtools.build.lib.cmdline.*; import com.google.devtools.build.lib.packages.*; import net.starlark.java.eval.*; | [
"com.google.devtools",
"net.starlark.java"
] | com.google.devtools; net.starlark.java; | 2,567,472 |
public void seekToUs(long positionUs) {
lastSeekPositionUs = positionUs;
if (isPendingReset()) {
// A reset is already pending. We only need to update its position.
pendingResetPositionUs = positionUs;
return;
}
// Detect whether the seek is to the start of a chunk that's at least partially buffered.
BaseMediaChunk seekToMediaChunk = null;
for (int i = 0; i < mediaChunks.size(); i++) {
BaseMediaChunk mediaChunk = mediaChunks.get(i);
long mediaChunkStartTimeUs = mediaChunk.startTimeUs;
if (mediaChunkStartTimeUs == positionUs && mediaChunk.clippedStartTimeUs == C.TIME_UNSET) {
seekToMediaChunk = mediaChunk;
break;
} else if (mediaChunkStartTimeUs > positionUs) {
// We're not going to find a chunk with a matching start time.
break;
}
}
// See if we can seek inside the primary sample queue.
boolean seekInsideBuffer;
primarySampleQueue.rewind();
if (seekToMediaChunk != null) {
// When seeking to the start of a chunk we use the index of the first sample in the chunk
// rather than the seek position. This ensures we seek to the keyframe at the start of the
// chunk even if the sample timestamps are slightly offset from the chunk start times.
seekInsideBuffer =
primarySampleQueue.setReadPosition(seekToMediaChunk.getFirstSampleIndex(0));
decodeOnlyUntilPositionUs = 0;
} else {
seekInsideBuffer =
primarySampleQueue.advanceTo(
positionUs,
true,
positionUs < getNextLoadPositionUs())
!= SampleQueue.ADVANCE_FAILED;
decodeOnlyUntilPositionUs = lastSeekPositionUs;
}
if (seekInsideBuffer) {
// We can seek inside the buffer.
nextNotifyPrimaryFormatMediaChunkIndex =
primarySampleIndexToMediaChunkIndex(
primarySampleQueue.getReadIndex(), 0);
// Advance the embedded sample queues to the seek position.
for (SampleQueue embeddedSampleQueue : embeddedSampleQueues) {
embeddedSampleQueue.rewind();
embeddedSampleQueue.advanceTo(positionUs, true, false);
}
} else {
// We can't seek inside the buffer, and so need to reset.
pendingResetPositionUs = positionUs;
loadingFinished = false;
mediaChunks.clear();
nextNotifyPrimaryFormatMediaChunkIndex = 0;
if (loader.isLoading()) {
loader.cancelLoading();
} else {
loader.clearFatalError();
primarySampleQueue.reset();
for (SampleQueue embeddedSampleQueue : embeddedSampleQueues) {
embeddedSampleQueue.reset();
}
}
}
} | void function(long positionUs) { lastSeekPositionUs = positionUs; if (isPendingReset()) { pendingResetPositionUs = positionUs; return; } BaseMediaChunk seekToMediaChunk = null; for (int i = 0; i < mediaChunks.size(); i++) { BaseMediaChunk mediaChunk = mediaChunks.get(i); long mediaChunkStartTimeUs = mediaChunk.startTimeUs; if (mediaChunkStartTimeUs == positionUs && mediaChunk.clippedStartTimeUs == C.TIME_UNSET) { seekToMediaChunk = mediaChunk; break; } else if (mediaChunkStartTimeUs > positionUs) { break; } } boolean seekInsideBuffer; primarySampleQueue.rewind(); if (seekToMediaChunk != null) { seekInsideBuffer = primarySampleQueue.setReadPosition(seekToMediaChunk.getFirstSampleIndex(0)); decodeOnlyUntilPositionUs = 0; } else { seekInsideBuffer = primarySampleQueue.advanceTo( positionUs, true, positionUs < getNextLoadPositionUs()) != SampleQueue.ADVANCE_FAILED; decodeOnlyUntilPositionUs = lastSeekPositionUs; } if (seekInsideBuffer) { nextNotifyPrimaryFormatMediaChunkIndex = primarySampleIndexToMediaChunkIndex( primarySampleQueue.getReadIndex(), 0); for (SampleQueue embeddedSampleQueue : embeddedSampleQueues) { embeddedSampleQueue.rewind(); embeddedSampleQueue.advanceTo(positionUs, true, false); } } else { pendingResetPositionUs = positionUs; loadingFinished = false; mediaChunks.clear(); nextNotifyPrimaryFormatMediaChunkIndex = 0; if (loader.isLoading()) { loader.cancelLoading(); } else { loader.clearFatalError(); primarySampleQueue.reset(); for (SampleQueue embeddedSampleQueue : embeddedSampleQueues) { embeddedSampleQueue.reset(); } } } } | /**
* Seeks to the specified position in microseconds.
*
* @param positionUs The seek position in microseconds.
*/ | Seeks to the specified position in microseconds | seekToUs | {
"repo_name": "CzBiX/Telegram",
"path": "TMessagesProj/src/main/java/com/google/android/exoplayer2/source/chunk/ChunkSampleStream.java",
"license": "gpl-2.0",
"size": 30321
} | [
"com.google.android.exoplayer2.source.SampleQueue"
] | import com.google.android.exoplayer2.source.SampleQueue; | import com.google.android.exoplayer2.source.*; | [
"com.google.android"
] | com.google.android; | 1,535,746 |
public void setDocumentAnalyzerClass(Class<? extends Analyzer> theClass) {
conf.setClass("sea.document.analyzer", theClass, Analyzer.class);
}
| void function(Class<? extends Analyzer> theClass) { conf.setClass(STR, theClass, Analyzer.class); } | /**
* Set the analyzer class.
*
* @param theClass
* the analyzer class
*/ | Set the analyzer class | setDocumentAnalyzerClass | {
"repo_name": "dongpf/hadoop-0.19.1",
"path": "src/contrib/index/src/java/org/apache/hadoop/contrib/index/mapred/IndexUpdateConfiguration.java",
"license": "apache-2.0",
"size": 8028
} | [
"org.apache.lucene.analysis.Analyzer"
] | import org.apache.lucene.analysis.Analyzer; | import org.apache.lucene.analysis.*; | [
"org.apache.lucene"
] | org.apache.lucene; | 2,863,235 |
public void okPushed( View view ) {
Intent intent = getIntent();
intent.putExtra(LibraryConstants.PREFS_KEY_TEXT, lastReadNfcMessage);
setResult(Activity.RESULT_OK, intent);
finish();
} | void function( View view ) { Intent intent = getIntent(); intent.putExtra(LibraryConstants.PREFS_KEY_TEXT, lastReadNfcMessage); setResult(Activity.RESULT_OK, intent); finish(); } | /**
* Ok action.
*
* @param view parent.
*/ | Ok action | okPushed | {
"repo_name": "gabrielmancilla/mtisig",
"path": "geopaparazzilibrary/src/eu/geopaparazzi/library/nfc/NfcIdReaderActivity.java",
"license": "gpl-3.0",
"size": 6405
} | [
"android.app.Activity",
"android.content.Intent",
"android.view.View",
"eu.geopaparazzi.library.util.LibraryConstants"
] | import android.app.Activity; import android.content.Intent; import android.view.View; import eu.geopaparazzi.library.util.LibraryConstants; | import android.app.*; import android.content.*; import android.view.*; import eu.geopaparazzi.library.util.*; | [
"android.app",
"android.content",
"android.view",
"eu.geopaparazzi.library"
] | android.app; android.content; android.view; eu.geopaparazzi.library; | 2,408,389 |
public void gatherConstructorSignatures(String typeName, Set<String> sigs) {
gatherConstructorSignatures(typeName, "", sigs);
boolean oneSkipped = false;
try {
for (int i = 1; true; i++) {
String version = String.format("%03d", i);
try {
gatherConstructorSignatures(typeName, version, sigs);
oneSkipped = false;
}
catch (UnableToLoadClassException e) {
if (oneSkipped)
throw e;
else
oneSkipped = true;
}
}
}
catch (UnableToLoadClassException e) {
//No more versions
}
} | void function(String typeName, Set<String> sigs) { gatherConstructorSignatures(typeName, STR%03d", i); try { gatherConstructorSignatures(typeName, version, sigs); oneSkipped = false; } catch (UnableToLoadClassException e) { if (oneSkipped) throw e; else oneSkipped = true; } } } catch (UnableToLoadClassException e) { } } | /**
* Like gather signatures, but gathers signatures of constructors instead of methods.
*/ | Like gather signatures, but gathers signatures of constructors instead of methods | gatherConstructorSignatures | {
"repo_name": "drunklite/spring-loaded",
"path": "springloaded/src/test/java/org/springsource/loaded/testgen/SignatureFinder.java",
"license": "apache-2.0",
"size": 4837
} | [
"java.util.Set",
"org.springsource.loaded.UnableToLoadClassException"
] | import java.util.Set; import org.springsource.loaded.UnableToLoadClassException; | import java.util.*; import org.springsource.loaded.*; | [
"java.util",
"org.springsource.loaded"
] | java.util; org.springsource.loaded; | 1,230,067 |
public static ContinuousDailyHDD extractSimpleHDD(final Reader r, final float baseTemperature)
throws IOException
{
if(null == r) { throw new IllegalArgumentException(); }
// Wrap in BufferedReader if required.
@SuppressWarnings("resource")
final BufferedReader br = (r instanceof BufferedReader) ? ((BufferedReader) r) : new BufferedReader(r);
// Discard header lines until encountering the first one starting with "Date" as its first field.
// Thereafter extract data and HDD float value.
final SortedMap<Integer, Float> map = new TreeMap<>();
String line;
while(null != (line = br.readLine()))
{ if(line.startsWith("Date,")) { break; } }
while(null != (line = br.readLine()))
{
final String fields[] = Util.splitCSVLine(line);
if(fields.length < 2) { continue; }
final float hdd;
final int year;
final int month;
final int day;
final Integer key;
final String d = fields[0];
if((10 != d.length()) || ('-' != d.charAt(4)) || ('-' != d.charAt(7)))
{ throw new IOException("bad date, expecting YYYY-MM-DD: " + d); }
try
{
year = Integer.parseInt(d.substring(0, 4), 10);
month = Integer.parseInt(d.substring(5, 7), 10);
day = Integer.parseInt(d.substring(8), 10);
final float v = Float.parseFloat(fields[1]);
if(!(v >= 0)) { throw new IOException("bad HDD value in row: " + line); }
hdd = v;
}
catch(final NumberFormatException e)
{ throw new IOException("unable to parse row: " + line, e); }
key = (year * 10000) + (month * 100) + day;
map.put(key, hdd);
}
return(new ContinuousDailyHDD(){
@Override public float getBaseTemperatureAsFloat() { return(baseTemperature); } | static ContinuousDailyHDD function(final Reader r, final float baseTemperature) throws IOException { if(null == r) { throw new IllegalArgumentException(); } @SuppressWarnings(STR) final BufferedReader br = (r instanceof BufferedReader) ? ((BufferedReader) r) : new BufferedReader(r); final SortedMap<Integer, Float> map = new TreeMap<>(); String line; while(null != (line = br.readLine())) { if(line.startsWith("Date,")) { break; } } while(null != (line = br.readLine())) { final String fields[] = Util.splitCSVLine(line); if(fields.length < 2) { continue; } final float hdd; final int year; final int month; final int day; final Integer key; final String d = fields[0]; if((10 != d.length()) ('-' != d.charAt(4)) ('-' != d.charAt(7))) { throw new IOException(STR + d); } try { year = Integer.parseInt(d.substring(0, 4), 10); month = Integer.parseInt(d.substring(5, 7), 10); day = Integer.parseInt(d.substring(8), 10); final float v = Float.parseFloat(fields[1]); if(!(v >= 0)) { throw new IOException(STR + line); } hdd = v; } catch(final NumberFormatException e) { throw new IOException(STR + line, e); } key = (year * 10000) + (month * 100) + day; map.put(key, hdd); } return(new ContinuousDailyHDD(){ @Override public float getBaseTemperatureAsFloat() { return(baseTemperature); } | /**Extract simple HDD with specified base temperature; never null.
* Does NOT close the Reader.
* @param r ASCII CSV file in simple degreedays.net-like format (Date line followed by HDD values); never null
* @throws IOException in case of parse error or missing data
*
* Format accepted (only first two columns used):
<pre>
Date,HDD,% Estimated
2016-03-01,6.6,0
2016-03-02,10.1,0
2016-03-03,9.2,0
2016-03-04,10.6,0
</pre>
*/ | Extract simple HDD with specified base temperature; never null. Does NOT close the Reader | extractSimpleHDD | {
"repo_name": "opentrv/opentrv",
"path": "javasrc/uk/org/opentrv/hdd/DDNExtractor.java",
"license": "apache-2.0",
"size": 13349
} | [
"java.io.BufferedReader",
"java.io.IOException",
"java.io.Reader",
"java.util.SortedMap",
"java.util.TreeMap"
] | import java.io.BufferedReader; import java.io.IOException; import java.io.Reader; import java.util.SortedMap; import java.util.TreeMap; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 2,455,435 |
public AzureFirewallNetworkRule withDestinationAddresses(List<String> destinationAddresses) {
this.destinationAddresses = destinationAddresses;
return this;
} | AzureFirewallNetworkRule function(List<String> destinationAddresses) { this.destinationAddresses = destinationAddresses; return this; } | /**
* Set list of destination IP addresses.
*
* @param destinationAddresses the destinationAddresses value to set
* @return the AzureFirewallNetworkRule object itself.
*/ | Set list of destination IP addresses | withDestinationAddresses | {
"repo_name": "selvasingh/azure-sdk-for-java",
"path": "sdk/network/mgmt-v2018_08_01/src/main/java/com/microsoft/azure/management/network/v2018_08_01/AzureFirewallNetworkRule.java",
"license": "mit",
"size": 4494
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 676,538 |
@OneToMany()
@JoinTable( name="resource",
joinColumns = { @JoinColumn( name="workactivity") },
inverseJoinColumns = @JoinColumn( name="employee" )
)
@WhereJoinTable(clause="endingdate is null and workactivity is not null")
public Set<Employee> getEmployees() {
return this.employees;
}
| @OneToMany() @JoinTable( name=STR, joinColumns = { @JoinColumn( name=STR) }, inverseJoinColumns = @JoinColumn( name=STR ) ) @WhereJoinTable(clause=STR) Set<Employee> function() { return this.employees; } | /**
* Get the employees.
*
* @return the employees
*/ | Get the employees | getEmployees | {
"repo_name": "Esleelkartea/aon-employee",
"path": "aonemployee_v2.3.0_src/paquetes descomprimidos/aon.company-2.1.8-sources/com/code/aon/company/WorkActivity.java",
"license": "gpl-2.0",
"size": 3735
} | [
"com.code.aon.company.resources.Employee",
"java.util.Set",
"javax.persistence.JoinColumn",
"javax.persistence.JoinTable",
"javax.persistence.OneToMany",
"org.hibernate.annotations.WhereJoinTable"
] | import com.code.aon.company.resources.Employee; import java.util.Set; import javax.persistence.JoinColumn; import javax.persistence.JoinTable; import javax.persistence.OneToMany; import org.hibernate.annotations.WhereJoinTable; | import com.code.aon.company.resources.*; import java.util.*; import javax.persistence.*; import org.hibernate.annotations.*; | [
"com.code.aon",
"java.util",
"javax.persistence",
"org.hibernate.annotations"
] | com.code.aon; java.util; javax.persistence; org.hibernate.annotations; | 1,868,441 |
protected ContentAssetInfoTO writeContentAsset(PipelineContent content, String site, String user, String path,
String assetName, InputStream in, int width, int height,
boolean createFolders, boolean isPreview, boolean unlock,
boolean isSystemAsset, ResultTO result)
throws ServiceLayerException {
logger.debug("Writing content asset: [site: " + site + ", path: " + path + ", assetName: "
+ assetName + ", createFolders: " + createFolders);
String ext = null;
int index = assetName.lastIndexOf(".");
if (index > 0 && (index + 1) < assetName.length()) {
ext = assetName.substring(index + 1).toUpperCase();
}
String contentPath = path + FILE_SEPARATOR + assetName;
try {
// look up the path content first
ContentItemTO parentContentItem = contentService.getContentItem(site, path, 0);
boolean parentExists = contentService.contentExists(site, path);
if (!parentExists && createFolders) {
parentContentItem = createMissingFoldersInPath(site, path, isPreview);
parentExists = contentService.contentExists(site, path);
}
if (parentExists && parentContentItem.isFolder()) {
boolean exists = contentService.contentExists(site, path + FILE_SEPARATOR + assetName);
ContentItemTO contentItem = null;
if (exists) {
contentItem = contentService.getContentItem(site, path + FILE_SEPARATOR + assetName, 0);
updateFile(site, contentItem, contentPath, in, user, isPreview, unlock, result);
content.addProperty(DmConstants.KEY_ACTIVITY_TYPE, OPERATION_UPDATE);
} else {
// TODO: define content type
contentItem = createNewFile(site, parentContentItem, assetName, null, in, user,
unlock, result);
content.addProperty(DmConstants.KEY_ACTIVITY_TYPE, OPERATION_CREATE);
objectStateService.insertNewEntry(site, contentItem);
}
ContentAssetInfoTO assetInfo = new ContentAssetInfoTO();
assetInfo.setFileName(assetName);
long sizeInBytes = contentService.getContentSize(site, path + FILE_SEPARATOR + assetName);
double convertedSize = 0;
if (sizeInBytes > 0) {
convertedSize = sizeInBytes / 1024d;
if (convertedSize >= 1024) {
assetInfo.setSizeUnit(FILE_SIZE_MB);
assetInfo.setSize(convertedSize / 1024d);
} else {
if (convertedSize > 0 && convertedSize < 1) {
assetInfo.setSize(1);
} else {
assetInfo.setSize(Math.round(convertedSize));
}
assetInfo.setSizeUnit(FILE_SIZE_KB);
}
}
assetInfo.setFileExtension(ext);
return assetInfo;
} else {
throw new ServiceLayerException(path + " does not exist or not a directory.");
}
} finally {
ContentUtils.release(in);
}
} | ContentAssetInfoTO function(PipelineContent content, String site, String user, String path, String assetName, InputStream in, int width, int height, boolean createFolders, boolean isPreview, boolean unlock, boolean isSystemAsset, ResultTO result) throws ServiceLayerException { logger.debug(STR + site + STR + path + STR + assetName + STR + createFolders); String ext = null; int index = assetName.lastIndexOf("."); if (index > 0 && (index + 1) < assetName.length()) { ext = assetName.substring(index + 1).toUpperCase(); } String contentPath = path + FILE_SEPARATOR + assetName; try { ContentItemTO parentContentItem = contentService.getContentItem(site, path, 0); boolean parentExists = contentService.contentExists(site, path); if (!parentExists && createFolders) { parentContentItem = createMissingFoldersInPath(site, path, isPreview); parentExists = contentService.contentExists(site, path); } if (parentExists && parentContentItem.isFolder()) { boolean exists = contentService.contentExists(site, path + FILE_SEPARATOR + assetName); ContentItemTO contentItem = null; if (exists) { contentItem = contentService.getContentItem(site, path + FILE_SEPARATOR + assetName, 0); updateFile(site, contentItem, contentPath, in, user, isPreview, unlock, result); content.addProperty(DmConstants.KEY_ACTIVITY_TYPE, OPERATION_UPDATE); } else { contentItem = createNewFile(site, parentContentItem, assetName, null, in, user, unlock, result); content.addProperty(DmConstants.KEY_ACTIVITY_TYPE, OPERATION_CREATE); objectStateService.insertNewEntry(site, contentItem); } ContentAssetInfoTO assetInfo = new ContentAssetInfoTO(); assetInfo.setFileName(assetName); long sizeInBytes = contentService.getContentSize(site, path + FILE_SEPARATOR + assetName); double convertedSize = 0; if (sizeInBytes > 0) { convertedSize = sizeInBytes / 1024d; if (convertedSize >= 1024) { assetInfo.setSizeUnit(FILE_SIZE_MB); assetInfo.setSize(convertedSize / 1024d); } else { if (convertedSize > 0 && convertedSize < 1) { assetInfo.setSize(1); } else { assetInfo.setSize(Math.round(convertedSize)); } assetInfo.setSizeUnit(FILE_SIZE_KB); } } assetInfo.setFileExtension(ext); return assetInfo; } else { throw new ServiceLayerException(path + STR); } } finally { ContentUtils.release(in); } } | /**
* upload content asset to the given path
*
* @param site
* @param path
* @param assetName
* @param in
* input stream to read the asset from
* @param width
* @param height
* @param createFolders
* create missing folders?
* @param isPreview
* @param unlock
* unlock the content upon update?
* @return asset information
* @throws ServiceLayerException
*/ | upload content asset to the given path | writeContentAsset | {
"repo_name": "avasquez614/studio",
"path": "src/main/java/org/craftercms/studio/impl/v1/content/pipeline/AssetDmContentProcessor.java",
"license": "gpl-3.0",
"size": 11787
} | [
"java.io.InputStream",
"org.craftercms.studio.api.v1.constant.DmConstants",
"org.craftercms.studio.api.v1.content.pipeline.PipelineContent",
"org.craftercms.studio.api.v1.exception.ServiceLayerException",
"org.craftercms.studio.api.v1.to.ContentAssetInfoTO",
"org.craftercms.studio.api.v1.to.ContentItemTO",
"org.craftercms.studio.api.v1.to.ResultTO",
"org.craftercms.studio.impl.v1.util.ContentUtils"
] | import java.io.InputStream; import org.craftercms.studio.api.v1.constant.DmConstants; import org.craftercms.studio.api.v1.content.pipeline.PipelineContent; import org.craftercms.studio.api.v1.exception.ServiceLayerException; import org.craftercms.studio.api.v1.to.ContentAssetInfoTO; import org.craftercms.studio.api.v1.to.ContentItemTO; import org.craftercms.studio.api.v1.to.ResultTO; import org.craftercms.studio.impl.v1.util.ContentUtils; | import java.io.*; import org.craftercms.studio.api.v1.constant.*; import org.craftercms.studio.api.v1.content.pipeline.*; import org.craftercms.studio.api.v1.exception.*; import org.craftercms.studio.api.v1.to.*; import org.craftercms.studio.impl.v1.util.*; | [
"java.io",
"org.craftercms.studio"
] | java.io; org.craftercms.studio; | 2,849,399 |
@Override
@NotNull(message = "JSON can't be NULL")
public final JsonObject json() throws IOException {
return new RtJson(this.request).fetch();
} | @NotNull(message = STR) final JsonObject function() throws IOException { return new RtJson(this.request).fetch(); } | /**
* JSON object for this request.
* @return Json object
* @throws IOException In case of I/O problems
*/ | JSON object for this request | json | {
"repo_name": "cvrebert/typed-github",
"path": "src/main/java/com/jcabi/github/RtStatuses.java",
"license": "bsd-3-clause",
"size": 4799
} | [
"java.io.IOException",
"javax.json.JsonObject",
"javax.validation.constraints.NotNull"
] | import java.io.IOException; import javax.json.JsonObject; import javax.validation.constraints.NotNull; | import java.io.*; import javax.json.*; import javax.validation.constraints.*; | [
"java.io",
"javax.json",
"javax.validation"
] | java.io; javax.json; javax.validation; | 1,006,274 |
private void addChangeHandlerEvent(ListBox aggFuncListBox, ListBox functionListBox) {
functionListBox.addChangeHandler(event -> onListBoxChange());
aggFuncListBox.addChangeHandler(event -> onListBoxChange());
}
| void function(ListBox aggFuncListBox, ListBox functionListBox) { functionListBox.addChangeHandler(event -> onListBoxChange()); aggFuncListBox.addChangeHandler(event -> onListBoxChange()); } | /**
* Add Change Event Handler to the List Boxes.
* @param aggFuncListBox
* @param functionListBox
*/ | Add Change Event Handler to the List Boxes | addChangeHandlerEvent | {
"repo_name": "MeasureAuthoringTool/MeasureAuthoringTool_Release",
"path": "mat/src/main/java/mat/client/populationworkspace/CQLMeasureObservationDetailView.java",
"license": "cc0-1.0",
"size": 13336
} | [
"org.gwtbootstrap3.client.ui.ListBox"
] | import org.gwtbootstrap3.client.ui.ListBox; | import org.gwtbootstrap3.client.ui.*; | [
"org.gwtbootstrap3.client"
] | org.gwtbootstrap3.client; | 1,687,710 |
protected void startUp() {
deviceManager.addListener(this);
floodlightProvider.addOFMessageListener(OFType.PACKET_IN, this);
} | void function() { deviceManager.addListener(this); floodlightProvider.addOFMessageListener(OFType.PACKET_IN, this); } | /**
* Adds a listener for devicemanager and registers for PacketIns.
*/ | Adds a listener for devicemanager and registers for PacketIns | startUp | {
"repo_name": "CodEnFisH/palantir",
"path": "floodlight/src/main/java/net/floodlightcontroller/routing/ForwardingBase.java",
"license": "apache-2.0",
"size": 26867
} | [
"org.openflow.protocol.OFType"
] | import org.openflow.protocol.OFType; | import org.openflow.protocol.*; | [
"org.openflow.protocol"
] | org.openflow.protocol; | 1,682,890 |
Assert.fail( "Test 'ProbandService_getProbandGroupListTest.testSuccessPath()}' not implemented." );
}
| Assert.fail( STR ); } | /**
* Test succes path for service method <code>getProbandGroupList</code>
*
* Tests expected behaviour of service method.
*/ | Test succes path for service method <code>getProbandGroupList</code> Tests expected behaviour of service method | testSuccessPath | {
"repo_name": "phoenixctms/ctsms",
"path": "core/src/test/java/org/phoenixctms/ctsms/service/proband/test/ProbandService_getProbandGroupListTest.java",
"license": "lgpl-2.1",
"size": 1302
} | [
"org.testng.Assert"
] | import org.testng.Assert; | import org.testng.*; | [
"org.testng"
] | org.testng; | 204,197 |
public void addAttribute( final Object key, final Object attr ) {
if (attributes == null) {
attributes = new HashMap<>(3);
}
attributes.put(key, attr);
} | void function( final Object key, final Object attr ) { if (attributes == null) { attributes = new HashMap<>(3); } attributes.put(key, attr); } | /** Add an attribute to an instruction handle.
*
* @param key the key object to store/retrieve the attribute
* @param attr the attribute to associate with this handle
*/ | Add an attribute to an instruction handle | addAttribute | {
"repo_name": "mirkosertic/Bytecoder",
"path": "classlib/java.xml/src/main/resources/META-INF/modules/java.xml/classes/com/sun/org/apache/bcel/internal/generic/InstructionHandle.java",
"license": "apache-2.0",
"size": 8878
} | [
"java.util.HashMap"
] | import java.util.HashMap; | import java.util.*; | [
"java.util"
] | java.util; | 806,372 |
public final void testGetB() {
ECFieldF2m f = new ECFieldF2m(5);
BigInteger a = BigInteger.valueOf(5L);
BigInteger b = BigInteger.valueOf(19L);
EllipticCurve c = new EllipticCurve(f, a, b);
assertEquals(b, c.getB());
assertSame(b, c.getB());
} | final void function() { ECFieldF2m f = new ECFieldF2m(5); BigInteger a = BigInteger.valueOf(5L); BigInteger b = BigInteger.valueOf(19L); EllipticCurve c = new EllipticCurve(f, a, b); assertEquals(b, c.getB()); assertSame(b, c.getB()); } | /**
* Test for <code>getB()</code> method<br>
* Assertion: returns coefficient <code>b</code><br>
* Test preconditions: <code>ECFieldF2m</code> instance
* created using valid parameters<br>
* Expected: must return coefficient <code>b</code> which is equal
* to the one passed to the constructor; (both must refer
* the same object)
*/ | Test for <code>getB()</code> method Assertion: returns coefficient <code>b</code> Test preconditions: <code>ECFieldF2m</code> instance created using valid parameters Expected: must return coefficient <code>b</code> which is equal to the one passed to the constructor; (both must refer the same object) | testGetB | {
"repo_name": "AdmireTheDistance/android_libcore",
"path": "luni/src/test/java/tests/security/spec/EllipticCurveTest.java",
"license": "gpl-2.0",
"size": 24635
} | [
"java.math.BigInteger",
"java.security.spec.ECFieldF2m",
"java.security.spec.EllipticCurve"
] | import java.math.BigInteger; import java.security.spec.ECFieldF2m; import java.security.spec.EllipticCurve; | import java.math.*; import java.security.spec.*; | [
"java.math",
"java.security"
] | java.math; java.security; | 612,461 |
public String[] convertTypeNamesToSigs(char[][] typeNames) {
if (typeNames == null)
return CharOperation.NO_STRINGS;
int n = typeNames.length;
if (n == 0)
return CharOperation.NO_STRINGS;
String[] typeSigs = new String[n];
for (int i = 0; i < n; ++i) {
char[] typeSig = Signature.createCharArrayTypeSignature(typeNames[i], false);
// transforms signatures that contains a qualification into unqualified signatures
// e.g. "QX<+QMap.Entry;>;" becomes "QX<+QEntry;>;"
StringBuffer simpleTypeSig = null;
int start = 0;
int dot = -1;
int length = typeSig.length;
for (int j = 0; j < length; j++) {
switch (typeSig[j]) {
case Signature.C_UNRESOLVED:
if (simpleTypeSig != null)
simpleTypeSig.append(typeSig, start, j-start);
start = j;
break;
case Signature.C_DOT:
dot = j;
break;
case Signature.C_GENERIC_START:
int matchingEnd = findMatchingGenericEnd(typeSig, j+1);
if (matchingEnd > 0 && matchingEnd+1 < length && typeSig[matchingEnd+1] == Signature.C_DOT) {
// found Head<Param>.Tail -> discard everything except Tail
if (simpleTypeSig == null)
simpleTypeSig = new StringBuffer().append(typeSig, 0, start);
simpleTypeSig.append(Signature.C_UNRESOLVED);
start = j = matchingEnd+2;
break;
}
//$FALL-THROUGH$
case Signature.C_NAME_END:
if (dot > start) {
if (simpleTypeSig == null)
simpleTypeSig = new StringBuffer().append(typeSig, 0, start);
simpleTypeSig.append(Signature.C_UNRESOLVED);
simpleTypeSig.append(typeSig, dot+1, j-dot-1);
start = j;
}
break;
}
}
if (simpleTypeSig == null) {
typeSigs[i] = new String(typeSig);
} else {
simpleTypeSig.append(typeSig, start, length-start);
typeSigs[i] = simpleTypeSig.toString();
}
}
return typeSigs;
} | String[] function(char[][] typeNames) { if (typeNames == null) return CharOperation.NO_STRINGS; int n = typeNames.length; if (n == 0) return CharOperation.NO_STRINGS; String[] typeSigs = new String[n]; for (int i = 0; i < n; ++i) { char[] typeSig = Signature.createCharArrayTypeSignature(typeNames[i], false); StringBuffer simpleTypeSig = null; int start = 0; int dot = -1; int length = typeSig.length; for (int j = 0; j < length; j++) { switch (typeSig[j]) { case Signature.C_UNRESOLVED: if (simpleTypeSig != null) simpleTypeSig.append(typeSig, start, j-start); start = j; break; case Signature.C_DOT: dot = j; break; case Signature.C_GENERIC_START: int matchingEnd = findMatchingGenericEnd(typeSig, j+1); if (matchingEnd > 0 && matchingEnd+1 < length && typeSig[matchingEnd+1] == Signature.C_DOT) { if (simpleTypeSig == null) simpleTypeSig = new StringBuffer().append(typeSig, 0, start); simpleTypeSig.append(Signature.C_UNRESOLVED); start = j = matchingEnd+2; break; } case Signature.C_NAME_END: if (dot > start) { if (simpleTypeSig == null) simpleTypeSig = new StringBuffer().append(typeSig, 0, start); simpleTypeSig.append(Signature.C_UNRESOLVED); simpleTypeSig.append(typeSig, dot+1, j-dot-1); start = j; } break; } } if (simpleTypeSig == null) { typeSigs[i] = new String(typeSig); } else { simpleTypeSig.append(typeSig, start, length-start); typeSigs[i] = simpleTypeSig.toString(); } } return typeSigs; } | /**
* NOT API, public only for access by Unit tests.
* Converts these type names to unqualified signatures. This needs to be done in order to be consistent
* with the way the source range is retrieved.
* @see SourceMapper#getUnqualifiedMethodHandle
* @see Signature
*/ | NOT API, public only for access by Unit tests. Converts these type names to unqualified signatures. This needs to be done in order to be consistent with the way the source range is retrieved | convertTypeNamesToSigs | {
"repo_name": "elucash/eclipse-oxygen",
"path": "org.eclipse.jdt.core/src/org/eclipse/jdt/internal/core/SourceMapper.java",
"license": "epl-1.0",
"size": 55825
} | [
"org.eclipse.jdt.core.Signature",
"org.eclipse.jdt.core.compiler.CharOperation"
] | import org.eclipse.jdt.core.Signature; import org.eclipse.jdt.core.compiler.CharOperation; | import org.eclipse.jdt.core.*; import org.eclipse.jdt.core.compiler.*; | [
"org.eclipse.jdt"
] | org.eclipse.jdt; | 520,352 |
public static <T extends Object> List<T> asOrderedSet(Set<T> self) {
return OclCollections.asOrderedSet(self);
}
| static <T extends Object> List<T> function(Set<T> self) { return OclCollections.asOrderedSet(self); } | /**
* <p>
* Returns an OrderedSet that contains all the elements from self, with
* duplicates removed, in an order dependent on the particular concrete
* collection type.
* </p>
*
* @param self
* The {@link Set} representing self.
* @return An OrderedSet that contains all the elements from self, with
* duplicates removed, in an order dependent on the particular
* concrete collection type.
*/ | Returns an OrderedSet that contains all the elements from self, with duplicates removed, in an order dependent on the particular concrete collection type. | asOrderedSet | {
"repo_name": "dresden-ocl/dresdenocl",
"path": "plugins/org.dresdenocl.tools.codegen.ocl2java.types/src/org/dresdenocl/tools/codegen/ocl2java/types/util/OclSets.java",
"license": "lgpl-3.0",
"size": 28073
} | [
"java.util.List",
"java.util.Set"
] | import java.util.List; import java.util.Set; | import java.util.*; | [
"java.util"
] | java.util; | 2,183,682 |
public Protocol1BrickletName getProtocol1BrickletName(char port) throws TimeoutException, NotConnectedException {
ByteBuffer bb = ipcon.createRequestPacket((byte)9, FUNCTION_GET_PROTOCOL1_BRICKLET_NAME, this);
bb.put((byte)port);
byte[] response = sendRequest(bb.array());
bb = ByteBuffer.wrap(response, 8, response.length - 8);
bb.order(ByteOrder.LITTLE_ENDIAN);
Protocol1BrickletName obj = new Protocol1BrickletName();
obj.protocolVersion = IPConnection.unsignedByte(bb.get());
for(int i = 0; i < 3; i++) {
obj.firmwareVersion[i] = IPConnection.unsignedByte(bb.get());
}
obj.name = IPConnection.string(bb, 40);
return obj;
} | Protocol1BrickletName function(char port) throws TimeoutException, NotConnectedException { ByteBuffer bb = ipcon.createRequestPacket((byte)9, FUNCTION_GET_PROTOCOL1_BRICKLET_NAME, this); bb.put((byte)port); byte[] response = sendRequest(bb.array()); bb = ByteBuffer.wrap(response, 8, response.length - 8); bb.order(ByteOrder.LITTLE_ENDIAN); Protocol1BrickletName obj = new Protocol1BrickletName(); obj.protocolVersion = IPConnection.unsignedByte(bb.get()); for(int i = 0; i < 3; i++) { obj.firmwareVersion[i] = IPConnection.unsignedByte(bb.get()); } obj.name = IPConnection.string(bb, 40); return obj; } | /**
* Returns the firmware and protocol version and the name of the Bricklet for a
* given port.
*
* This functions sole purpose is to allow automatic flashing of v1.x.y Bricklet
* plugins.
*
* .. versionadded:: 2.0.0~(Firmware)
*/ | Returns the firmware and protocol version and the name of the Bricklet for a given port. This functions sole purpose is to allow automatic flashing of v1.x.y Bricklet plugins. .. versionadded:: 2.0.0~(Firmware) | getProtocol1BrickletName | {
"repo_name": "jaggr2/ch.bfh.fbi.mobiComp.17herz",
"path": "com.tinkerforge/src/com/tinkerforge/BrickMaster.java",
"license": "apache-2.0",
"size": 85810
} | [
"java.nio.ByteBuffer",
"java.nio.ByteOrder"
] | import java.nio.ByteBuffer; import java.nio.ByteOrder; | import java.nio.*; | [
"java.nio"
] | java.nio; | 2,709,362 |
@Override
public void appWasDownloaded(long galleryId) {
GallerySettings settings = loadGallerySettings();
galleryStorageIo.incrementDownloads(galleryId);
}
/**
* Returns the comments for an app
* @param galleryId gallery ID as received by
* {@link #getRecentGalleryApps()} | void function(long galleryId) { GallerySettings settings = loadGallerySettings(); galleryStorageIo.incrementDownloads(galleryId); } /** * Returns the comments for an app * @param galleryId gallery ID as received by * {@link #getRecentGalleryApps()} | /**
* record fact that app was downloaded
* @param galleryId id of app that was downloaded
*/ | record fact that app was downloaded | appWasDownloaded | {
"repo_name": "ram8647/appinventor-sources",
"path": "appinventor/appengine/src/com/google/appinventor/server/GalleryServiceImpl.java",
"license": "apache-2.0",
"size": 24408
} | [
"com.google.appinventor.shared.rpc.project.GallerySettings"
] | import com.google.appinventor.shared.rpc.project.GallerySettings; | import com.google.appinventor.shared.rpc.project.*; | [
"com.google.appinventor"
] | com.google.appinventor; | 2,777,607 |
@Override public T visitRuleModifiers(@NotNull ANTLRv4Parser.RuleModifiersContext ctx) { return visitChildren(ctx); } | @Override public T visitRuleModifiers(@NotNull ANTLRv4Parser.RuleModifiersContext ctx) { return visitChildren(ctx); } | /**
* {@inheritDoc}
*
* <p>The default implementation returns the result of calling
* {@link #visitChildren} on {@code ctx}.</p>
*/ | The default implementation returns the result of calling <code>#visitChildren</code> on ctx | visitOption | {
"repo_name": "ajosephau/generic_multiobjective_superoptimizer",
"path": "src/org/gso/antlrv4parser/ANTLRv4ParserBaseVisitor.java",
"license": "gpl-2.0",
"size": 15727
} | [
"org.antlr.v4.runtime.misc.NotNull"
] | import org.antlr.v4.runtime.misc.NotNull; | import org.antlr.v4.runtime.misc.*; | [
"org.antlr.v4"
] | org.antlr.v4; | 971,851 |
public static String getName(
ASN1ObjectIdentifier oid)
{
return (String)names.get(oid);
} | static String function( ASN1ObjectIdentifier oid) { return (String)names.get(oid); } | /**
* return the named curve name represented by the given object identifier.
*/ | return the named curve name represented by the given object identifier | getName | {
"repo_name": "onessimofalconi/bc-java",
"path": "core/src/main/java/org/bouncycastle/asn1/teletrust/TeleTrusTNamedCurves.java",
"license": "mit",
"size": 19936
} | [
"org.bouncycastle.asn1.ASN1ObjectIdentifier"
] | import org.bouncycastle.asn1.ASN1ObjectIdentifier; | import org.bouncycastle.asn1.*; | [
"org.bouncycastle.asn1"
] | org.bouncycastle.asn1; | 122,384 |
public Frame getFrame(final IERSConventions conventions, final boolean simpleEOP)
throws OrekitException {
throw new OrekitException(OrekitMessages.CCSDS_INVALID_FRAME, toString());
} | Frame function(final IERSConventions conventions, final boolean simpleEOP) throws OrekitException { throw new OrekitException(OrekitMessages.CCSDS_INVALID_FRAME, toString()); } | /**
* Get the frame corresponding to the CCSDS constant.
* @param conventions IERS conventions to use
* @param simpleEOP if true, tidal effects are ignored when interpolating EOP
* @return frame corresponding to the CCSDS constant
* @exception OrekitException if the frame cannot be retrieved or if it
* is a Local Orbital Frame
* @see #isLof()
*/ | Get the frame corresponding to the CCSDS constant | getFrame | {
"repo_name": "ProjectPersephone/Orekit",
"path": "src/main/java/org/orekit/files/ccsds/CCSDSFrame.java",
"license": "apache-2.0",
"size": 8354
} | [
"org.orekit.errors.OrekitException",
"org.orekit.errors.OrekitMessages",
"org.orekit.frames.Frame",
"org.orekit.utils.IERSConventions"
] | import org.orekit.errors.OrekitException; import org.orekit.errors.OrekitMessages; import org.orekit.frames.Frame; import org.orekit.utils.IERSConventions; | import org.orekit.errors.*; import org.orekit.frames.*; import org.orekit.utils.*; | [
"org.orekit.errors",
"org.orekit.frames",
"org.orekit.utils"
] | org.orekit.errors; org.orekit.frames; org.orekit.utils; | 788,326 |
public static BufferedImage readImage(final File imageFile) {
if (imageFile == null) {
throw new RuntimeException("Image file is null");
}
try {
BufferedImage img = ImageIO.read(imageFile);
if (img == null) {
throw new RuntimeException("Could not load image file: " + imageFile);
}
return img;
}
catch (IOException|OutOfMemoryError e) {
Log.error("Could not load file: " + imageFile.getAbsolutePath(), e);
throw new RuntimeException(e.getMessage(), e);
}
} | static BufferedImage function(final File imageFile) { if (imageFile == null) { throw new RuntimeException(STR); } try { BufferedImage img = ImageIO.read(imageFile); if (img == null) { throw new RuntimeException(STR + imageFile); } return img; } catch (IOException OutOfMemoryError e) { Log.error(STR + imageFile.getAbsolutePath(), e); throw new RuntimeException(e.getMessage(), e); } } | /**
* Lodads an image from the provided image file. If the passed in file is null a RuntimeException is thrown. If the
* image file cannot be read, a RuntimeException is also thrown.
* @param imageFile
* @return
*/ | Lodads an image from the provided image file. If the passed in file is null a RuntimeException is thrown. If the image file cannot be read, a RuntimeException is also thrown | readImage | {
"repo_name": "ikromin/jphotoframe",
"path": "src/main/java/net/igorkromin/jphotoframe/img/ImageUtil.java",
"license": "gpl-2.0",
"size": 4033
} | [
"java.awt.image.BufferedImage",
"java.io.File",
"java.io.IOException",
"javax.imageio.ImageIO",
"net.igorkromin.jphotoframe.Log"
] | import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; import javax.imageio.ImageIO; import net.igorkromin.jphotoframe.Log; | import java.awt.image.*; import java.io.*; import javax.imageio.*; import net.igorkromin.jphotoframe.*; | [
"java.awt",
"java.io",
"javax.imageio",
"net.igorkromin.jphotoframe"
] | java.awt; java.io; javax.imageio; net.igorkromin.jphotoframe; | 2,643,370 |
synchronized void afterRename(IFileSystemArtifact artifact) throws VilException {
List<VilException> errors = new ArrayList<VilException>();
scanAll(artifact.getPath().getAbsolutePath(), 0, ProgressObserver.NO_OBSERVER, null, errors);
// path cache happens automatically
} | synchronized void afterRename(IFileSystemArtifact artifact) throws VilException { List<VilException> errors = new ArrayList<VilException>(); scanAll(artifact.getPath().getAbsolutePath(), 0, ProgressObserver.NO_OBSERVER, null, errors); } | /**
* Called after rename in order to create the changed artifacts.
*
* @param artifact the renamed artifact
* @throws VilException in case of problems obtaining the path
*/ | Called after rename in order to create the changed artifacts | afterRename | {
"repo_name": "SSEHUB/EASyProducer",
"path": "Plugins/Instantiation/de.uni_hildesheim.sse.easy.instantiatorCore/src/net/ssehub/easy/instantiation/core/model/artifactModel/ArtifactModel.java",
"license": "apache-2.0",
"size": 21106
} | [
"java.util.ArrayList",
"java.util.List",
"net.ssehub.easy.basics.progress.ProgressObserver",
"net.ssehub.easy.instantiation.core.model.common.VilException"
] | import java.util.ArrayList; import java.util.List; import net.ssehub.easy.basics.progress.ProgressObserver; import net.ssehub.easy.instantiation.core.model.common.VilException; | import java.util.*; import net.ssehub.easy.basics.progress.*; import net.ssehub.easy.instantiation.core.model.common.*; | [
"java.util",
"net.ssehub.easy"
] | java.util; net.ssehub.easy; | 1,068,425 |
public void setLongPollTimeout(int longPollTimeout) {
Assert.isTrue(longPollTimeout > 0, "LongPollTimeout must be a positive value");
this.longPollTimeout = longPollTimeout;
} | void function(int longPollTimeout) { Assert.isTrue(longPollTimeout > 0, STR); this.longPollTimeout = longPollTimeout; } | /**
* Set the long poll timeout for the server.
* @param longPollTimeout the long poll timeout in milliseconds
*/ | Set the long poll timeout for the server | setLongPollTimeout | {
"repo_name": "mabernardo/spring-boot",
"path": "spring-boot-devtools/src/main/java/org/springframework/boot/devtools/tunnel/server/HttpTunnelServer.java",
"license": "apache-2.0",
"size": 14184
} | [
"org.springframework.util.Assert"
] | import org.springframework.util.Assert; | import org.springframework.util.*; | [
"org.springframework.util"
] | org.springframework.util; | 2,071,066 |
static InetAddress createHostNameFromIPAddress(String ipAddressString)
throws UnknownHostException {
InetAddress address = null;
if (Inet6Util.isValidIPV4Address(ipAddressString)) {
byte[] byteAddress = new byte[4];
String[] parts = ipAddressString.split("\\."); //$NON-NLS-1$
int length = parts.length;
if (length == 1) {
long value = Long.parseLong(parts[0]);
for (int i = 0; i < 4; i++) {
byteAddress[i] = (byte) (value >> ((3 - i) * 8));
}
} else {
for (int i = 0; i < length; i++) {
byteAddress[i] = (byte) Integer.parseInt(parts[i]);
}
}
// adjust for 2/3 parts address
if (length == 2) {
byteAddress[3] = byteAddress[1];
byteAddress[1] = 0;
}
if (length == 3) {
byteAddress[3] = byteAddress[2];
byteAddress[2] = 0;
}
address = new Inet4Address(byteAddress);
} else { // otherwise it must be ipv6
if (ipAddressString.charAt(0) == '[') {
ipAddressString = ipAddressString.substring(1, ipAddressString
.length() - 1);
}
StringTokenizer tokenizer = new StringTokenizer(ipAddressString,
":.%", true); //$NON-NLS-1$
ArrayList<String> hexStrings = new ArrayList<String>();
ArrayList<String> decStrings = new ArrayList<String>();
String scopeString = null;
String token = ""; //$NON-NLS-1$
String prevToken = ""; //$NON-NLS-1$
String prevPrevToken = ""; //$NON-NLS-1$
int doubleColonIndex = -1; // If a double colon exists, we need to
// insert 0s.
// Go through the tokens, including the separators ':' and '.'
// When we hit a : or . the previous token will be added to either
// the hex list or decimal list. In the case where we hit a ::
// we will save the index of the hexStrings so we can add zeros
// in to fill out the string
while (tokenizer.hasMoreTokens()) {
prevPrevToken = prevToken;
prevToken = token;
token = tokenizer.nextToken();
if (token.equals(":")) { //$NON-NLS-1$
if (prevToken.equals(":")) { //$NON-NLS-1$
doubleColonIndex = hexStrings.size();
} else if (!prevToken.equals("")) { //$NON-NLS-1$
hexStrings.add(prevToken);
}
} else if (token.equals(".")) { //$NON-NLS-1$
decStrings.add(prevToken);
} else if (token.equals("%")) { //$NON-NLS-1$
// add the last word before the % properly
if (!prevToken.equals(":") && !prevToken.equals(".")) { //$NON-NLS-1$ //$NON-NLS-2$
if (prevPrevToken.equals(":")) { //$NON-NLS-1$
hexStrings.add(prevToken);
} else if (prevPrevToken.equals(".")) { //$NON-NLS-1$
decStrings.add(prevToken);
}
}
// the rest should be the scope string
StringBuilder buf = new StringBuilder();
while (tokenizer.hasMoreTokens()) {
buf.append(tokenizer.nextToken());
}
scopeString = buf.toString();
}
}
if (prevToken.equals(":")) { //$NON-NLS-1$
if (token.equals(":")) { //$NON-NLS-1$
doubleColonIndex = hexStrings.size();
} else {
hexStrings.add(token);
}
} else if (prevToken.equals(".")) { //$NON-NLS-1$
decStrings.add(token);
}
// figure out how many hexStrings we should have
// also check if it is a IPv4 address
int hexStringsLength = 8;
// If we have an IPv4 address tagged on at the end, subtract
// 4 bytes, or 2 hex words from the total
if (decStrings.size() > 0) {
hexStringsLength -= 2;
}
// if we hit a double Colon add the appropriate hex strings
if (doubleColonIndex != -1) {
int numberToInsert = hexStringsLength - hexStrings.size();
for (int i = 0; i < numberToInsert; i++) {
hexStrings.add(doubleColonIndex, "0"); //$NON-NLS-1$
}
}
byte ipByteArray[] = new byte[16];
// Finally convert these strings to bytes...
for (int i = 0; i < hexStrings.size(); i++) {
Inet6Util.convertToBytes(hexStrings.get(i), ipByteArray, i * 2);
}
// Now if there are any decimal values, we know where they go...
for (int i = 0; i < decStrings.size(); i++) {
ipByteArray[i + 12] = (byte) (Integer.parseInt(decStrings
.get(i)) & 255);
}
// now check to see if this guy is actually and IPv4 address
// an ipV4 address is ::FFFF:d.d.d.d
boolean ipV4 = true;
for (int i = 0; i < 10; i++) {
if (ipByteArray[i] != 0) {
ipV4 = false;
break;
}
}
if (ipByteArray[10] != -1 || ipByteArray[11] != -1) {
ipV4 = false;
}
if (ipV4) {
byte ipv4ByteArray[] = new byte[4];
for (int i = 0; i < 4; i++) {
ipv4ByteArray[i] = ipByteArray[i + 12];
}
address = InetAddress.getByAddress(ipv4ByteArray);
} else {
int scopeId = 0;
if (scopeString != null) {
try {
scopeId = Integer.parseInt(scopeString);
} catch (Exception e) {
// this should not occur as we should not get into this
// function unless the address is in a valid format
}
}
address = InetAddress.getByAddress(ipByteArray, scopeId);
}
}
return address;
} | static InetAddress createHostNameFromIPAddress(String ipAddressString) throws UnknownHostException { InetAddress address = null; if (Inet6Util.isValidIPV4Address(ipAddressString)) { byte[] byteAddress = new byte[4]; String[] parts = ipAddressString.split("\\."); int length = parts.length; if (length == 1) { long value = Long.parseLong(parts[0]); for (int i = 0; i < 4; i++) { byteAddress[i] = (byte) (value >> ((3 - i) * 8)); } } else { for (int i = 0; i < length; i++) { byteAddress[i] = (byte) Integer.parseInt(parts[i]); } } if (length == 2) { byteAddress[3] = byteAddress[1]; byteAddress[1] = 0; } if (length == 3) { byteAddress[3] = byteAddress[2]; byteAddress[2] = 0; } address = new Inet4Address(byteAddress); } else { if (ipAddressString.charAt(0) == '[') { ipAddressString = ipAddressString.substring(1, ipAddressString .length() - 1); } StringTokenizer tokenizer = new StringTokenizer(ipAddressString, ":.%", true); ArrayList<String> hexStrings = new ArrayList<String>(); ArrayList<String> decStrings = new ArrayList<String>(); String scopeString = null; String token = STRSTRSTR:STR:STRSTR.STR%STR:STR.STR:STR.STR:STR:STR.STR0"); } } byte ipByteArray[] = new byte[16]; for (int i = 0; i < hexStrings.size(); i++) { Inet6Util.convertToBytes(hexStrings.get(i), ipByteArray, i * 2); } for (int i = 0; i < decStrings.size(); i++) { ipByteArray[i + 12] = (byte) (Integer.parseInt(decStrings .get(i)) & 255); } boolean ipV4 = true; for (int i = 0; i < 10; i++) { if (ipByteArray[i] != 0) { ipV4 = false; break; } } if (ipByteArray[10] != -1 ipByteArray[11] != -1) { ipV4 = false; } if (ipV4) { byte ipv4ByteArray[] = new byte[4]; for (int i = 0; i < 4; i++) { ipv4ByteArray[i] = ipByteArray[i + 12]; } address = InetAddress.getByAddress(ipv4ByteArray); } else { int scopeId = 0; if (scopeString != null) { try { scopeId = Integer.parseInt(scopeString); } catch (Exception e) { } } address = InetAddress.getByAddress(ipByteArray, scopeId); } } return address; } | /**
* Creates an InetAddress based on the {@code ipAddressString}. No error
* handling is performed here.
*/ | Creates an InetAddress based on the ipAddressString. No error handling is performed here | createHostNameFromIPAddress | {
"repo_name": "freeVM/freeVM",
"path": "enhanced/java/classlib/modules/luni/src/main/java/java/net/InetAddress.java",
"license": "apache-2.0",
"size": 50643
} | [
"java.util.ArrayList",
"java.util.StringTokenizer",
"org.apache.harmony.luni.util.Inet6Util"
] | import java.util.ArrayList; import java.util.StringTokenizer; import org.apache.harmony.luni.util.Inet6Util; | import java.util.*; import org.apache.harmony.luni.util.*; | [
"java.util",
"org.apache.harmony"
] | java.util; org.apache.harmony; | 2,518,001 |
protected void sendDispositionHeader(OutputStream out) throws IOException {
out.write(CONTENT_DISPOSITION_BYTES);
out.write(QUOTE_BYTES);
out.write(MultipartEncodingUtil.getAsciiBytes(getName()));
out.write(QUOTE_BYTES);
} | void function(OutputStream out) throws IOException { out.write(CONTENT_DISPOSITION_BYTES); out.write(QUOTE_BYTES); out.write(MultipartEncodingUtil.getAsciiBytes(getName())); out.write(QUOTE_BYTES); } | /**
* Write the content disposition header to the specified output stream
*
* @param out The output stream
* @throws IOException If an IO problem occurs.
*/ | Write the content disposition header to the specified output stream | sendDispositionHeader | {
"repo_name": "jprante/elasticsearch-client",
"path": "elasticsearch-client-http-netty/src/main/java/com/ning/http/multipart/Part.java",
"license": "apache-2.0",
"size": 13829
} | [
"java.io.IOException",
"java.io.OutputStream"
] | import java.io.IOException; import java.io.OutputStream; | import java.io.*; | [
"java.io"
] | java.io; | 2,340,427 |
@Test
public void testFailsWithRangeOfOneAndTwoNullValues() {
// create legal range
String[] range = new String[] { "item2" };
// create matcher with range
matcher = new IsDistributedAcrossRange<String>(Arrays.asList(range));
// create actual values
String[] actualValues = new String[] { null, null };
// test
assertFalse(matcher.matches(Arrays.asList(actualValues)));
}
| void function() { String[] range = new String[] { "item2" }; matcher = new IsDistributedAcrossRange<String>(Arrays.asList(range)); String[] actualValues = new String[] { null, null }; assertFalse(matcher.matches(Arrays.asList(actualValues))); } | /**
* Test that matcher fails with range of one value and two null values in
* matched collection.
*/ | Test that matcher fails with range of one value and two null values in matched collection | testFailsWithRangeOfOneAndTwoNullValues | {
"repo_name": "athrane/pineapple",
"path": "support/pineapple-hamcrest-support/src/test/java/com/alpha/pineapple/test/matchers/DistributedAcrossRangeTest.java",
"license": "gpl-3.0",
"size": 13724
} | [
"java.util.Arrays",
"org.junit.Assert"
] | import java.util.Arrays; import org.junit.Assert; | import java.util.*; import org.junit.*; | [
"java.util",
"org.junit"
] | java.util; org.junit; | 800,311 |
public List<BindingSet> querySPARQLTuples(String query, boolean includeInferred) {
Query q = repo.getConnection().prepareQuery(query);
q.setIncludeInferred(includeInferred);
if (!(q instanceof TupleQuery)) {
throw new IllegalArgumentException("SPARQL query is not a tuple query.");
}
QueryResultCollector resultCollector = new QueryResultCollector();
((TupleQuery) q).evaluate(resultCollector);
return resultCollector.getBindingSets();
} | List<BindingSet> function(String query, boolean includeInferred) { Query q = repo.getConnection().prepareQuery(query); q.setIncludeInferred(includeInferred); if (!(q instanceof TupleQuery)) { throw new IllegalArgumentException(STR); } QueryResultCollector resultCollector = new QueryResultCollector(); ((TupleQuery) q).evaluate(resultCollector); return resultCollector.getBindingSets(); } | /**
* Queries triple store and returns results.
*
* Depending on the type of the query the results will be as follows:
*
* TupleQuery: JSON
* GraphQuery: N-Triples
* BooleanQuery: Plain text
*
* @param query
* @param includeInferred
* @return
*/ | Queries triple store and returns results. Depending on the type of the query the results will be as follows: TupleQuery: JSON GraphQuery: N-Triples BooleanQuery: Plain text | querySPARQLTuples | {
"repo_name": "JulianSchuette/secunity",
"path": "webapp/secunity-backend/src/main/java/de/fhg/aisec/secunity/db/TripleStore.java",
"license": "mit",
"size": 20835
} | [
"java.util.List",
"org.openrdf.query.BindingSet",
"org.openrdf.query.Query",
"org.openrdf.query.TupleQuery",
"org.openrdf.query.resultio.helpers.QueryResultCollector"
] | import java.util.List; import org.openrdf.query.BindingSet; import org.openrdf.query.Query; import org.openrdf.query.TupleQuery; import org.openrdf.query.resultio.helpers.QueryResultCollector; | import java.util.*; import org.openrdf.query.*; import org.openrdf.query.resultio.helpers.*; | [
"java.util",
"org.openrdf.query"
] | java.util; org.openrdf.query; | 2,904,385 |
private boolean createBucket(String bucketName) {
CloseableHttpClient httpClient = HttpClientBuilder.create().build();
try {
HttpPost httpPost = new HttpPost("http://localhost:" + _couchbaseTestServer.getPort() + "/pools/default/buckets");
List<NameValuePair> params = new ArrayList<>(2);
params.add(new BasicNameValuePair("bucketType", "couchbase"));
params.add(new BasicNameValuePair("name", bucketName));
params.add(new BasicNameValuePair("authType", "sasl"));
params.add(new BasicNameValuePair("ramQuotaMB", "200"));
httpPost.setEntity(new UrlEncodedFormEntity(params, "UTF-8"));
//Execute and get the response.
HttpResponse response = httpClient.execute(httpPost);
log.info(String.valueOf(response.getStatusLine().getStatusCode()));
return true;
}
catch (Exception e) {
log.error("Failed to create bucket {}", bucketName, e);
return false;
}
} | boolean function(String bucketName) { CloseableHttpClient httpClient = HttpClientBuilder.create().build(); try { HttpPost httpPost = new HttpPost(STRbucketTypeSTRcouchbaseSTRnameSTRauthTypeSTRsaslSTRramQuotaMBSTR200STRUTF-8STRFailed to create bucket {}", bucketName, e); return false; } } | /**
* Implement the equivalent of:
* curl -XPOST -u Administrator:password localhost:httpPort/pools/default/buckets \ -d bucketType=couchbase \
* -d name={@param bucketName} -d authType=sasl -d ramQuotaMB=200
**/ | Implement the equivalent of: curl -XPOST -u Administrator:password localhost:httpPort/pools/default/buckets \ -d bucketType=couchbase \ -d name=bucketName -d authType=sasl -d ramQuotaMB=200 | createBucket | {
"repo_name": "pcadabam/gobblin",
"path": "gobblin-modules/gobblin-couchbase/src/test/java/org/apache/gobblin/couchbase/writer/CouchbaseWriterTest.java",
"license": "apache-2.0",
"size": 21719
} | [
"org.apache.http.client.methods.HttpPost",
"org.apache.http.impl.client.CloseableHttpClient",
"org.apache.http.impl.client.HttpClientBuilder"
] | import org.apache.http.client.methods.HttpPost; import org.apache.http.impl.client.CloseableHttpClient; import org.apache.http.impl.client.HttpClientBuilder; | import org.apache.http.client.methods.*; import org.apache.http.impl.client.*; | [
"org.apache.http"
] | org.apache.http; | 1,467,054 |
@Override
public boolean alarm() {
HttpPost post;
if (mThread == null) return true;
String threadName = mThread.getName();
// Synchronize here so that we are guaranteed to have valid mPendingPost and mPostLock
// executePostWithTimeout (which executes the HttpPost) also uses this lock
synchronized(getSynchronizer()) {
if (mMailbox.mType == Mailbox.TYPE_EAS_ACCOUNT_MAILBOX) {
userLog("ping is alarmed");
if (mHttpConn != null) {
mPostAborted = true;
mHttpConn.disconnect();
}
return true;
}
// Get a reference to the current post lock
post = mPendingPost;
if (post != null) {
if (Eas.USER_LOG) {
URI uri = post.getURI();
if (uri != null) {
String query = uri.getQuery();
if (query == null) {
query = "POST";
}
userLog(threadName, ": Alert, aborting ", query);
} else {
userLog(threadName, ": Alert, no URI?");
}
}
// Abort the POST
mPostAborted = true;
post.abort();
} else {
// If there's no POST, we're done
userLog("Alert, no pending POST");
return true;
}
}
// Wait for the POST to finish, and check the state
// every POST_LOCK_CHECK_TIMEOUT = 2s to exit this method early
int checkTime = 0;
State s;
while (checkTime < POST_LOCK_TIMEOUT) {
s = mThread.getState();
if ((s != State.TERMINATED) || ((mPendingPost != null) && (mPendingPost == post))) {
try {
Thread.sleep(POST_LOCK_CHECK_TIMEOUT);
} catch (InterruptedException e) {
Logging.d("InterruptedException catched: " + e.getMessage());
}
} else {
return true;
}
checkTime += POST_LOCK_CHECK_TIMEOUT;
}
s = mThread.getState();
if (Eas.USER_LOG) {
userLog(threadName + ": State = " + s.name());
}
synchronized (getSynchronizer()) {
// If the thread is still hanging around and the same post is pending, let's try to
// stop the thread with an interrupt.
if ((s != State.TERMINATED) && (mPendingPost != null) && (mPendingPost == post)) {
mStop = true;
mThread.interrupt();
userLog("Interrupting...");
// Let the caller know we had to interrupt the thread
return false;
}
}
// Let the caller know that the alarm was handled normally
return true;
} | boolean function() { HttpPost post; if (mThread == null) return true; String threadName = mThread.getName(); synchronized(getSynchronizer()) { if (mMailbox.mType == Mailbox.TYPE_EAS_ACCOUNT_MAILBOX) { userLog(STR); if (mHttpConn != null) { mPostAborted = true; mHttpConn.disconnect(); } return true; } post = mPendingPost; if (post != null) { if (Eas.USER_LOG) { URI uri = post.getURI(); if (uri != null) { String query = uri.getQuery(); if (query == null) { query = "POST"; } userLog(threadName, STR, query); } else { userLog(threadName, STR); } } mPostAborted = true; post.abort(); } else { userLog(STR); return true; } } int checkTime = 0; State s; while (checkTime < POST_LOCK_TIMEOUT) { s = mThread.getState(); if ((s != State.TERMINATED) ((mPendingPost != null) && (mPendingPost == post))) { try { Thread.sleep(POST_LOCK_CHECK_TIMEOUT); } catch (InterruptedException e) { Logging.d(STR + e.getMessage()); } } else { return true; } checkTime += POST_LOCK_CHECK_TIMEOUT; } s = mThread.getState(); if (Eas.USER_LOG) { userLog(threadName + STR + s.name()); } synchronized (getSynchronizer()) { if ((s != State.TERMINATED) && (mPendingPost != null) && (mPendingPost == post)) { mStop = true; mThread.interrupt(); userLog(STR); return false; } } return true; } | /**
* Try to wake up a sync thread that is waiting on an HttpClient POST and has waited past its
* socket timeout without having thrown an Exception
*
* @return true if the POST was successfully stopped; false if we've failed and interrupted
* the thread
*/ | Try to wake up a sync thread that is waiting on an HttpClient POST and has waited past its socket timeout without having thrown an Exception | alarm | {
"repo_name": "rex-xxx/mt6572_x201",
"path": "packages/apps/Exchange/exchange2/src/com/android/exchange/EasSyncService.java",
"license": "gpl-2.0",
"size": 120516
} | [
"com.android.emailcommon.Logging",
"com.android.emailcommon.provider.Mailbox",
"java.lang.Thread",
"org.apache.http.client.methods.HttpPost"
] | import com.android.emailcommon.Logging; import com.android.emailcommon.provider.Mailbox; import java.lang.Thread; import org.apache.http.client.methods.HttpPost; | import com.android.emailcommon.*; import com.android.emailcommon.provider.*; import java.lang.*; import org.apache.http.client.methods.*; | [
"com.android.emailcommon",
"java.lang",
"org.apache.http"
] | com.android.emailcommon; java.lang; org.apache.http; | 213,237 |
@Override
public void onStart() {
super.onStart();
getSupportActionBar().setTitle(R.string.mode_me2me);
// Load any previously-selected account and recents from Preferences.
SharedPreferences prefs = getPreferences(MODE_PRIVATE);
String selected = prefs.getString(PREFERENCE_SELECTED_ACCOUNT, null);
ArrayList<String> recents = new ArrayList<String>();
for (int i = 0;; i++) {
String prefName = PREFERENCE_RECENT_ACCOUNT_PREFIX + i;
String recent = prefs.getString(prefName, null);
if (recent != null) {
recents.add(recent);
} else {
break;
}
}
String[] recentsArray = recents.toArray(new String[recents.size()]);
mAccountSwitcher.setSelectedAndRecentAccounts(selected, recentsArray);
} | void function() { super.onStart(); getSupportActionBar().setTitle(R.string.mode_me2me); SharedPreferences prefs = getPreferences(MODE_PRIVATE); String selected = prefs.getString(PREFERENCE_SELECTED_ACCOUNT, null); ArrayList<String> recents = new ArrayList<String>(); for (int i = 0;; i++) { String prefName = PREFERENCE_RECENT_ACCOUNT_PREFIX + i; String recent = prefs.getString(prefName, null); if (recent != null) { recents.add(recent); } else { break; } } String[] recentsArray = recents.toArray(new String[recents.size()]); mAccountSwitcher.setSelectedAndRecentAccounts(selected, recentsArray); } | /**
* Called when the activity becomes visible. This happens on initial launch and whenever the
* user switches to the activity, for example, by using the window-switcher or when coming from
* the device's lock screen.
*/ | Called when the activity becomes visible. This happens on initial launch and whenever the user switches to the activity, for example, by using the window-switcher or when coming from the device's lock screen | onStart | {
"repo_name": "scheib/chromium",
"path": "remoting/android/java/src/org/chromium/chromoting/Chromoting.java",
"license": "bsd-3-clause",
"size": 29872
} | [
"android.content.SharedPreferences",
"java.util.ArrayList"
] | import android.content.SharedPreferences; import java.util.ArrayList; | import android.content.*; import java.util.*; | [
"android.content",
"java.util"
] | android.content; java.util; | 1,060,042 |
public List<String> getAllTemplates(){
return templateList;
} | List<String> function(){ return templateList; } | /**
* get all templates.
* @return templates list
*/ | get all templates | getAllTemplates | {
"repo_name": "Hasimir/dita-ot",
"path": "src/main/java/org/dita/dost/platform/Features.java",
"license": "apache-2.0",
"size": 5432
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 2,124,583 |
private void createExportedBatchClassFolder(final BatchSchemaService batchSchemaService, final String imageMagickBaseFolderParam,
final String isSearchSampleNameParam, final BatchClass batchClass, final String tempFolderLocation) throws IOException {
File copiedFolder = new File(tempFolderLocation);
if (copiedFolder.exists()) {
copiedFolder.delete();
}
copiedFolder.mkdirs();
BatchClassUtil.copyModules(batchClass);
BatchClassUtil.copyDocumentTypes(batchClass);
BatchClassUtil.copyScannerConfig(batchClass);
BatchClassUtil.exportEmailConfiguration(batchClass);
BatchClassUtil.exportUserGroups(batchClass);
BatchClassUtil.exportBatchClassField(batchClass);
BatchClassUtil.exportCMISConfiguration(batchClass);
File serializedExportFile = new File(EphesoftStringUtil.concatenate(tempFolderLocation, File.separator,
batchClass.getIdentifier(), SERIALIZATION_EXT));
try {
SerializationUtils.serialize(batchClass, new FileOutputStream(serializedExportFile));
File originalFolder = new File(EphesoftStringUtil.concatenate(batchSchemaService.getBaseSampleFDLock(), File.separator,
batchClass.getIdentifier()));
if (originalFolder.isDirectory()) {
final String[] folderList = originalFolder.list();
Arrays.sort(folderList);
for (int i = 0; i < folderList.length; i++) {
if (folderList[i].endsWith(SERIALIZATION_EXT)) {
// skip previous ser file since new is created.
} else if (FilenameUtils.getName(folderList[i]).equalsIgnoreCase(
batchSchemaService.getTestKVExtractionFolderName())
|| FilenameUtils.getName(folderList[i]).equalsIgnoreCase(batchSchemaService.getTestTableFolderName())
|| FilenameUtils.getName(folderList[i]).equalsIgnoreCase(
batchSchemaService.getFileboundPluginMappingFolderName())) {
// Skip this folder
continue;
} else if (FilenameUtils.getName(folderList[i])
.equalsIgnoreCase(batchSchemaService.getImagemagickBaseFolderName())
&& !EphesoftStringUtil.isNullOrEmpty(imageMagickBaseFolderParam)) {
FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder,
folderList[i]));
} else if (FilenameUtils.getName(folderList[i]).equalsIgnoreCase(batchSchemaService.getSearchSampleName())
&& !EphesoftStringUtil.isNullOrEmpty(isSearchSampleNameParam)) {
FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder,
folderList[i]));
} else if (!(FilenameUtils.getName(folderList[i]).equalsIgnoreCase(
batchSchemaService.getImagemagickBaseFolderName()) || FilenameUtils.getName(folderList[i])
.equalsIgnoreCase(batchSchemaService.getSearchSampleName()))) {
FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder,
folderList[i]));
}
}
}
} catch (FileNotFoundException e) {
// Unable to read serializable file
LOGGER.error(EphesoftStringUtil.concatenate("Error occurred while creating the serializable file. ", e.getMessage()), e);
foldersNotCopied.append(EphesoftStringUtil.concatenate(BATCH_CLASS_FOLDER, SEMI_COLON));
} catch (IOException e) {
// Unable to create the temporary export file(s)/folder(s)
LOGGER.error(EphesoftStringUtil.concatenate("Error occurred while creating the serializable file.", e.getMessage()), e);
}
}
/**
* This method copies the batch instance folder to the download folder.
*
* @param downloadFolder {@link File}
* @param batchInstance {@link BatchInstance}
* @param localFolderPath {@link String}
* @param baseFolderPath {@link String} | void function(final BatchSchemaService batchSchemaService, final String imageMagickBaseFolderParam, final String isSearchSampleNameParam, final BatchClass batchClass, final String tempFolderLocation) throws IOException { File copiedFolder = new File(tempFolderLocation); if (copiedFolder.exists()) { copiedFolder.delete(); } copiedFolder.mkdirs(); BatchClassUtil.copyModules(batchClass); BatchClassUtil.copyDocumentTypes(batchClass); BatchClassUtil.copyScannerConfig(batchClass); BatchClassUtil.exportEmailConfiguration(batchClass); BatchClassUtil.exportUserGroups(batchClass); BatchClassUtil.exportBatchClassField(batchClass); BatchClassUtil.exportCMISConfiguration(batchClass); File serializedExportFile = new File(EphesoftStringUtil.concatenate(tempFolderLocation, File.separator, batchClass.getIdentifier(), SERIALIZATION_EXT)); try { SerializationUtils.serialize(batchClass, new FileOutputStream(serializedExportFile)); File originalFolder = new File(EphesoftStringUtil.concatenate(batchSchemaService.getBaseSampleFDLock(), File.separator, batchClass.getIdentifier())); if (originalFolder.isDirectory()) { final String[] folderList = originalFolder.list(); Arrays.sort(folderList); for (int i = 0; i < folderList.length; i++) { if (folderList[i].endsWith(SERIALIZATION_EXT)) { } else if (FilenameUtils.getName(folderList[i]).equalsIgnoreCase( batchSchemaService.getTestKVExtractionFolderName()) FilenameUtils.getName(folderList[i]).equalsIgnoreCase(batchSchemaService.getTestTableFolderName()) FilenameUtils.getName(folderList[i]).equalsIgnoreCase( batchSchemaService.getFileboundPluginMappingFolderName())) { continue; } else if (FilenameUtils.getName(folderList[i]) .equalsIgnoreCase(batchSchemaService.getImagemagickBaseFolderName()) && !EphesoftStringUtil.isNullOrEmpty(imageMagickBaseFolderParam)) { FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder, folderList[i])); } else if (FilenameUtils.getName(folderList[i]).equalsIgnoreCase(batchSchemaService.getSearchSampleName()) && !EphesoftStringUtil.isNullOrEmpty(isSearchSampleNameParam)) { FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder, folderList[i])); } else if (!(FilenameUtils.getName(folderList[i]).equalsIgnoreCase( batchSchemaService.getImagemagickBaseFolderName()) FilenameUtils.getName(folderList[i]) .equalsIgnoreCase(batchSchemaService.getSearchSampleName()))) { FileUtils.copyDirectoryWithContents(new File(originalFolder, folderList[i]), new File(copiedFolder, folderList[i])); } } } } catch (FileNotFoundException e) { LOGGER.error(EphesoftStringUtil.concatenate(STR, e.getMessage()), e); foldersNotCopied.append(EphesoftStringUtil.concatenate(BATCH_CLASS_FOLDER, SEMI_COLON)); } catch (IOException e) { LOGGER.error(EphesoftStringUtil.concatenate(STR, e.getMessage()), e); } } /** * This method copies the batch instance folder to the download folder. * * @param downloadFolder {@link File} * @param batchInstance {@link BatchInstance} * @param localFolderPath {@link String} * @param baseFolderPath {@link String} | /**
* This method copies the exported batch class to the download folder.
*
* @param batchSchemaService {@link BatchSchemaService} instance of batch schema service
* @param imageMagickBaseFolderParam {@link String} the parameter value of checkbox for image magick base folder
* @param isSearchSampleNameParam {@link String} the parameter value of checkbox for lucene search classification
* @param batchClass {@link BatchClass} the batch class of batch instance
* @param tempFolderLocation {@link String} the temporary folder location
* @throws IOException if an exception occurs while creating the serialized file.
*/ | This method copies the exported batch class to the download folder | createExportedBatchClassFolder | {
"repo_name": "ungerik/ephesoft",
"path": "Ephesoft_Community_Release_4.0.2.0/source/gxt/gxt-batch-instance/src/main/java/com/ephesoft/gxt/batchinstance/server/CopyTroubleshootingArtifacts.java",
"license": "agpl-3.0",
"size": 30124
} | [
"com.ephesoft.dcma.batch.service.BatchSchemaService",
"com.ephesoft.dcma.da.domain.BatchClass",
"com.ephesoft.dcma.da.domain.BatchInstance",
"com.ephesoft.dcma.util.EphesoftStringUtil",
"com.ephesoft.dcma.util.FileUtils",
"com.ephesoft.gxt.core.server.BatchClassUtil",
"java.io.File",
"java.io.FileNotFoundException",
"java.io.FileOutputStream",
"java.io.IOException",
"java.util.Arrays",
"org.apache.commons.io.FilenameUtils",
"org.apache.commons.lang.SerializationUtils"
] | import com.ephesoft.dcma.batch.service.BatchSchemaService; import com.ephesoft.dcma.da.domain.BatchClass; import com.ephesoft.dcma.da.domain.BatchInstance; import com.ephesoft.dcma.util.EphesoftStringUtil; import com.ephesoft.dcma.util.FileUtils; import com.ephesoft.gxt.core.server.BatchClassUtil; import java.io.File; import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.util.Arrays; import org.apache.commons.io.FilenameUtils; import org.apache.commons.lang.SerializationUtils; | import com.ephesoft.dcma.batch.service.*; import com.ephesoft.dcma.da.domain.*; import com.ephesoft.dcma.util.*; import com.ephesoft.gxt.core.server.*; import java.io.*; import java.util.*; import org.apache.commons.io.*; import org.apache.commons.lang.*; | [
"com.ephesoft.dcma",
"com.ephesoft.gxt",
"java.io",
"java.util",
"org.apache.commons"
] | com.ephesoft.dcma; com.ephesoft.gxt; java.io; java.util; org.apache.commons; | 16,418 |
if (detector == null) {
// retrieve the language database embedded in the jar
// load the models inside an array then put them in
// the library
String[] models = new String[profiles.length];
for (int i = 0; i < profiles.length; i++) {
InputStream s = getClass().getClassLoader().
getResourceAsStream("cybozu/" + profiles[i]);
try {
models[i] = IOUtils.toString(s, "UTF-8");
} catch (IOException ex) {
Logger.getLogger(CybozuLanguageDetectorAnnotator.class.getName()).log(
Level.SEVERE, "Cannot load cybozu model " + profiles[i], ex);
}
}
DetectorFactory.loadProfile(Arrays.asList(models));
}
detector = DetectorFactory.create();
detector.append(text);
return detector.detect();
} | if (detector == null) { String[] models = new String[profiles.length]; for (int i = 0; i < profiles.length; i++) { InputStream s = getClass().getClassLoader(). getResourceAsStream(STR + profiles[i]); try { models[i] = IOUtils.toString(s, "UTF-8"); } catch (IOException ex) { Logger.getLogger(CybozuLanguageDetectorAnnotator.class.getName()).log( Level.SEVERE, STR + profiles[i], ex); } } DetectorFactory.loadProfile(Arrays.asList(models)); } detector = DetectorFactory.create(); detector.append(text); return detector.detect(); } | /**
* Wraps the Cybozu lybrary and detects the language over a specified
* text.
*
* @param text the text to analyze.
* @return the code of the language detected
* @throws LangDetectException when the model can't be loaded
*/ | Wraps the Cybozu lybrary and detects the language over a specified text | detect | {
"repo_name": "ailab-uniud/distiller-CORE",
"path": "src/main/java/it/uniud/ailab/dcore/wrappers/external/CybozuLanguageDetectorAnnotator.java",
"license": "gpl-2.0",
"size": 4719
} | [
"com.cybozu.labs.langdetect.DetectorFactory",
"java.io.IOException",
"java.io.InputStream",
"java.util.Arrays",
"java.util.logging.Level",
"java.util.logging.Logger",
"org.apache.commons.io.IOUtils"
] | import com.cybozu.labs.langdetect.DetectorFactory; import java.io.IOException; import java.io.InputStream; import java.util.Arrays; import java.util.logging.Level; import java.util.logging.Logger; import org.apache.commons.io.IOUtils; | import com.cybozu.labs.langdetect.*; import java.io.*; import java.util.*; import java.util.logging.*; import org.apache.commons.io.*; | [
"com.cybozu.labs",
"java.io",
"java.util",
"org.apache.commons"
] | com.cybozu.labs; java.io; java.util; org.apache.commons; | 1,529,136 |
public DiskDao getDiskDao() {
return getDao(DiskDao.class);
} | DiskDao function() { return getDao(DiskDao.class); } | /**
* Returns the singleton instance of {@link DiskDao}.
*
* @return the dao
*/ | Returns the singleton instance of <code>DiskDao</code> | getDiskDao | {
"repo_name": "jtux270/translate",
"path": "ovirt/3.6_source/backend/manager/modules/dal/src/main/java/org/ovirt/engine/core/dal/dbbroker/DbFacade.java",
"license": "gpl-3.0",
"size": 42484
} | [
"org.ovirt.engine.core.dao.DiskDao"
] | import org.ovirt.engine.core.dao.DiskDao; | import org.ovirt.engine.core.dao.*; | [
"org.ovirt.engine"
] | org.ovirt.engine; | 2,876,156 |
public UUID subjectIdPerCall(@Nullable UUID subjId) {
if (subjId != null)
return subjId;
return subjectIdPerCall(subjId, operationContextPerCall());
} | UUID function(@Nullable UUID subjId) { if (subjId != null) return subjId; return subjectIdPerCall(subjId, operationContextPerCall()); } | /**
* Gets subject ID per call.
*
* @param subjId Optional already existing subject ID.
* @return Subject ID per call.
*/ | Gets subject ID per call | subjectIdPerCall | {
"repo_name": "tkpanther/ignite",
"path": "modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java",
"license": "apache-2.0",
"size": 60051
} | [
"org.jetbrains.annotations.Nullable"
] | import org.jetbrains.annotations.Nullable; | import org.jetbrains.annotations.*; | [
"org.jetbrains.annotations"
] | org.jetbrains.annotations; | 1,765,350 |
private static final String tokenElementToString(Element e) {
return new StringBuilder()
.append("\n******************** TOKEN ********************\n")
.append(DOM2Writer.nodeToString(e))
.append("\n******************** TOKEN ********************")
.toString();
} | static final String function(Element e) { return new StringBuilder() .append(STR) .append(DOM2Writer.nodeToString(e)) .append(STR) .toString(); } | /**
* Token element to string.
*
* @param e
* the e
* @return the string
*/ | Token element to string | tokenElementToString | {
"repo_name": "OBHITA/Consent2Share",
"path": "DS4P/access-control-service/pep-client/src/main/java/gov/samhsa/acs/pep/wsclient/PepWebServiceClient.java",
"license": "bsd-3-clause",
"size": 13539
} | [
"org.apache.wss4j.common.util.DOM2Writer",
"org.w3c.dom.Element"
] | import org.apache.wss4j.common.util.DOM2Writer; import org.w3c.dom.Element; | import org.apache.wss4j.common.util.*; import org.w3c.dom.*; | [
"org.apache.wss4j",
"org.w3c.dom"
] | org.apache.wss4j; org.w3c.dom; | 2,706,670 |
public String getSimpleName() {
return CmsOrganizationalUnit.getSimpleName(m_name);
} | String function() { return CmsOrganizationalUnit.getSimpleName(m_name); } | /**
* Returns the simple name of this organizational unit.
*
* @return the simple name of this organizational unit.
*/ | Returns the simple name of this organizational unit | getSimpleName | {
"repo_name": "serrapos/opencms-core",
"path": "src/org/opencms/file/CmsProject.java",
"license": "lgpl-2.1",
"size": 14636
} | [
"org.opencms.security.CmsOrganizationalUnit"
] | import org.opencms.security.CmsOrganizationalUnit; | import org.opencms.security.*; | [
"org.opencms.security"
] | org.opencms.security; | 1,351,236 |
public void setContentView(View root) {
mRootView = root;
mWindow.setContentView(root);
}
| void function(View root) { mRootView = root; mWindow.setContentView(root); } | /**
* Set content view.
*
* @param root
* Root view
*/ | Set content view | setContentView | {
"repo_name": "kii-dev-jenkins/KiiFileStorageSampleApp",
"path": "src/com/kii/demo/ui/view/PopupWindows.java",
"license": "apache-2.0",
"size": 4114
} | [
"android.view.View"
] | import android.view.View; | import android.view.*; | [
"android.view"
] | android.view; | 1,523,280 |
public TcpDiscoveryIpFinder getIpFinder() {
return ipFinder;
} | TcpDiscoveryIpFinder function() { return ipFinder; } | /**
* Gets IP finder for IP addresses sharing and storing.
*
* @return IP finder for IP addresses sharing and storing.
*/ | Gets IP finder for IP addresses sharing and storing | getIpFinder | {
"repo_name": "vsisko/incubator-ignite",
"path": "modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java",
"license": "apache-2.0",
"size": 68315
} | [
"org.apache.ignite.spi.discovery.tcp.ipfinder.TcpDiscoveryIpFinder"
] | import org.apache.ignite.spi.discovery.tcp.ipfinder.TcpDiscoveryIpFinder; | import org.apache.ignite.spi.discovery.tcp.ipfinder.*; | [
"org.apache.ignite"
] | org.apache.ignite; | 583,433 |
@Override
protected JAXBContext createContext() throws JAXBException {
if (getContextPath() != null) {
return JAXBContext.newInstance(adapter.getSoapPackageName() + ":" + getContextPath());
} else {
return JAXBContext.newInstance();
}
} | JAXBContext function() throws JAXBException { if (getContextPath() != null) { return JAXBContext.newInstance(adapter.getSoapPackageName() + ":" + getContextPath()); } else { return JAXBContext.newInstance(); } } | /**
* Added the generated SOAP package to the JAXB context so Soap datatypes
* are available
*/ | Added the generated SOAP package to the JAXB context so Soap datatypes are available | createContext | {
"repo_name": "kevinearls/camel",
"path": "components/camel-soap/src/main/java/org/apache/camel/dataformat/soap/SoapJaxbDataFormat.java",
"license": "apache-2.0",
"size": 13243
} | [
"javax.xml.bind.JAXBContext",
"javax.xml.bind.JAXBException"
] | import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; | import javax.xml.bind.*; | [
"javax.xml"
] | javax.xml; | 1,482,287 |
public void setStartDate(String startDate) throws ParseException {
this.startDate = startDate;
setDateRange(dsSPS, Tags.SPSStartDate, startDate );
} | void function(String startDate) throws ParseException { this.startDate = startDate; setDateRange(dsSPS, Tags.SPSStartDate, startDate ); } | /**
* Set the start date.
* <p>
* Set both <code>startDate and startDateAsLong</code>.<br>
* If the parameter is null or empty, both values are set to <code>null</code>
*
* @param startDate The start Date to set.
* @throws ParseException
*/ | Set the start date. Set both <code>startDate and startDateAsLong</code>. If the parameter is null or empty, both values are set to <code>null</code> | setStartDate | {
"repo_name": "medicayun/medicayundicom",
"path": "dcm4jboss-all/trunk/dcm4jboss-web/src/java/org/dcm4chex/archive/web/maverick/mwl/model/MWLFilter.java",
"license": "apache-2.0",
"size": 7934
} | [
"java.text.ParseException",
"org.dcm4che.dict.Tags"
] | import java.text.ParseException; import org.dcm4che.dict.Tags; | import java.text.*; import org.dcm4che.dict.*; | [
"java.text",
"org.dcm4che.dict"
] | java.text; org.dcm4che.dict; | 2,547,498 |
List<AndesQueue> getAllQueuesStored() throws AndesException; | List<AndesQueue> getAllQueuesStored() throws AndesException; | /**
* Get all stored queues.
*
* @return list of queues
* @throws AndesException
*/ | Get all stored queues | getAllQueuesStored | {
"repo_name": "ThilankaBowala/andes",
"path": "modules/andes-core/broker/src/main/java/org/wso2/andes/kernel/AndesContextStore.java",
"license": "apache-2.0",
"size": 14264
} | [
"java.util.List"
] | import java.util.List; | import java.util.*; | [
"java.util"
] | java.util; | 1,638,905 |
public void clearTrash() {
final List<File> trashRoots = new ArrayList<>();
for (StorageDirectory sd : storageDirs) {
File trashRoot = getTrashRootDir(sd);
if (trashRoot.exists() && sd.getPreviousDir().exists()) {
LOG.error("Trash and PreviousDir shouldn't both exist for storage "
+ "directory " + sd);
assert false;
} else {
trashRoots.add(trashRoot);
}
} | void function() { final List<File> trashRoots = new ArrayList<>(); for (StorageDirectory sd : storageDirs) { File trashRoot = getTrashRootDir(sd); if (trashRoot.exists() && sd.getPreviousDir().exists()) { LOG.error(STR + STR + sd); assert false; } else { trashRoots.add(trashRoot); } } | /**
* Delete all files and directories in the trash directories.
*/ | Delete all files and directories in the trash directories | clearTrash | {
"repo_name": "Microsoft-CISL/hadoop-prototype",
"path": "hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockPoolSliceStorage.java",
"license": "apache-2.0",
"size": 31808
} | [
"java.io.File",
"java.util.ArrayList",
"java.util.List"
] | import java.io.File; import java.util.ArrayList; import java.util.List; | import java.io.*; import java.util.*; | [
"java.io",
"java.util"
] | java.io; java.util; | 1,786,398 |
public void setBackground(Color background)
{
super.setBackground(background);
if (filterComposite != null
&& (!useNewLook || useNativeSearchField(filterComposite)))
{
filterComposite.setBackground(background);
}
if (filterToolBar != null && filterToolBar.getControl() != null)
{
filterToolBar.getControl().setBackground(background);
}
} | void function(Color background) { super.setBackground(background); if (filterComposite != null && (!useNewLook useNativeSearchField(filterComposite))) { filterComposite.setBackground(background); } if (filterToolBar != null && filterToolBar.getControl() != null) { filterToolBar.getControl().setBackground(background); } } | /**
* Set the background for the widgets that support the filter text area.
*
* @param background
* background <code>Color</code> to set
*/ | Set the background for the widgets that support the filter text area | setBackground | {
"repo_name": "theanuradha/debrief",
"path": "org.mwc.cmap.NarrativeViewer/src/org/mwc/cmap/NarrativeViewer/FilteredGrid.java",
"license": "epl-1.0",
"size": 28954
} | [
"org.eclipse.swt.graphics.Color"
] | import org.eclipse.swt.graphics.Color; | import org.eclipse.swt.graphics.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 2,275,164 |
@Test(groups = "wso2.mb", description = "Send million messages and Receive them via AUTO_ACKNOWLEDGE subscribers " +
"and CLIENT_ACKNOWLEDGE", enabled = true)
public void performMillionMessageTenPercentReturnTestCase()
throws AndesClientConfigurationException, NamingException, JMSException, IOException,
AndesClientException {
// Creating a consumer client configuration
AndesJMSConsumerClientConfiguration consumerConfig = new AndesJMSConsumerClientConfiguration(ExchangeType.QUEUE, "MillionTenPercentAckMixReturnQueue");
consumerConfig.setAcknowledgeMode(JMSAcknowledgeMode.AUTO_ACKNOWLEDGE); // Consumer uses auto acknowledge mode
consumerConfig.setAcknowledgeAfterEachMessageCount(200); // Acknowledging messages only after message count
consumerConfig.setMaximumMessagesToReceived(EXPECTED_COUNT);
consumerConfig.setPrintsPerMessageCount(EXPECTED_COUNT / 10L);
AndesJMSConsumerClientConfiguration consumerReturnedConfig = new AndesJMSConsumerClientConfiguration(ExchangeType.QUEUE, "MillionTenPercentAckMixReturnQueue");
consumerConfig.setAcknowledgeMode(JMSAcknowledgeMode.CLIENT_ACKNOWLEDGE); // Consumer uses client acknowledge mode
consumerConfig.setAcknowledgeAfterEachMessageCount(100000); // Acknowledge messages only after message count
consumerReturnedConfig.setMaximumMessagesToReceived(NUMBER_OF_RETURNED_MESSAGES);
consumerReturnedConfig.setPrintsPerMessageCount(NUMBER_OF_RETURNED_MESSAGES / 10L);
// Creating a publisher client configuration
AndesJMSPublisherClientConfiguration publisherConfig = new AndesJMSPublisherClientConfiguration(ExchangeType.QUEUE, "MillionTenPercentAckMixReturnQueue");
publisherConfig.setNumberOfMessagesToSend(SEND_COUNT);
publisherConfig.setPrintsPerMessageCount(SEND_COUNT / 10L);
// Creating clients
AndesClient consumerClient = new AndesClient(consumerConfig, NUMBER_OF_AUTO_ACK_SUBSCRIBERS, true);
consumerClient.startClient();
AndesClient consumerReturnedClient = new AndesClient(consumerReturnedConfig, NUMBER_OF_CLIENT_ACK_SUBSCRIBERS, true);
consumerReturnedClient.startClient();
AndesClient publisherClient = new AndesClient(publisherConfig, NUMBER_OF_PUBLISHERS, true);
publisherClient.startClient();
AndesClientUtils.waitForMessagesAndShutdown(consumerClient, AndesClientConstants.DEFAULT_RUN_TIME);
AndesClientUtils.shutdownClient(consumerReturnedClient);
// Evaluation
long totalReceivedMessageCount = consumerClient.getReceivedMessageCount() + consumerReturnedClient.getReceivedMessageCount();
log.info("Total Non Returning Subscribers Received Messages [" + consumerClient.getReceivedMessageCount() + "]");
log.info("Total Returning Subscribers Received Messages [" + consumerReturnedClient.getReceivedMessageCount() + "]");
log.info("Total Received Messages [" + totalReceivedMessageCount + "]");
Assert.assertEquals(publisherClient.getSentMessageCount(), SEND_COUNT * NUMBER_OF_PUBLISHERS, "Message sending failed");
Assert.assertEquals(consumerClient.getReceivedMessageCount(), SEND_COUNT, "Did not receive expected message count.");
} | @Test(groups = STR, description = STR + STR, enabled = true) void function() throws AndesClientConfigurationException, NamingException, JMSException, IOException, AndesClientException { AndesJMSConsumerClientConfiguration consumerConfig = new AndesJMSConsumerClientConfiguration(ExchangeType.QUEUE, STR); consumerConfig.setAcknowledgeMode(JMSAcknowledgeMode.AUTO_ACKNOWLEDGE); consumerConfig.setAcknowledgeAfterEachMessageCount(200); consumerConfig.setMaximumMessagesToReceived(EXPECTED_COUNT); consumerConfig.setPrintsPerMessageCount(EXPECTED_COUNT / 10L); AndesJMSConsumerClientConfiguration consumerReturnedConfig = new AndesJMSConsumerClientConfiguration(ExchangeType.QUEUE, STR); consumerConfig.setAcknowledgeMode(JMSAcknowledgeMode.CLIENT_ACKNOWLEDGE); consumerConfig.setAcknowledgeAfterEachMessageCount(100000); consumerReturnedConfig.setMaximumMessagesToReceived(NUMBER_OF_RETURNED_MESSAGES); consumerReturnedConfig.setPrintsPerMessageCount(NUMBER_OF_RETURNED_MESSAGES / 10L); AndesJMSPublisherClientConfiguration publisherConfig = new AndesJMSPublisherClientConfiguration(ExchangeType.QUEUE, STR); publisherConfig.setNumberOfMessagesToSend(SEND_COUNT); publisherConfig.setPrintsPerMessageCount(SEND_COUNT / 10L); AndesClient consumerClient = new AndesClient(consumerConfig, NUMBER_OF_AUTO_ACK_SUBSCRIBERS, true); consumerClient.startClient(); AndesClient consumerReturnedClient = new AndesClient(consumerReturnedConfig, NUMBER_OF_CLIENT_ACK_SUBSCRIBERS, true); consumerReturnedClient.startClient(); AndesClient publisherClient = new AndesClient(publisherConfig, NUMBER_OF_PUBLISHERS, true); publisherClient.startClient(); AndesClientUtils.waitForMessagesAndShutdown(consumerClient, AndesClientConstants.DEFAULT_RUN_TIME); AndesClientUtils.shutdownClient(consumerReturnedClient); long totalReceivedMessageCount = consumerClient.getReceivedMessageCount() + consumerReturnedClient.getReceivedMessageCount(); log.info(STR + consumerClient.getReceivedMessageCount() + "]"); log.info(STR + consumerReturnedClient.getReceivedMessageCount() + "]"); log.info(STR + totalReceivedMessageCount + "]"); Assert.assertEquals(publisherClient.getSentMessageCount(), SEND_COUNT * NUMBER_OF_PUBLISHERS, STR); Assert.assertEquals(consumerClient.getReceivedMessageCount(), SEND_COUNT, STR); } | /**
* Send million messages and receive them via AUTO_ACKNOWLEDGE subscribers and CLIENT_ACKNOWLEDGE subscribers and
* check if AUTO_ACKNOWLEDGE subscribers receive all the messages.
*
* @throws AndesClientConfigurationException
* @throws NamingException
* @throws JMSException
* @throws IOException
* @throws AndesClientException
*/ | Send million messages and receive them via AUTO_ACKNOWLEDGE subscribers and CLIENT_ACKNOWLEDGE subscribers and check if AUTO_ACKNOWLEDGE subscribers receive all the messages | performMillionMessageTenPercentReturnTestCase | {
"repo_name": "milindaperera/product-ei",
"path": "integration/broker-tests/tests-integration/tests-amqp/src/test/java/org/wso2/mb/integration/tests/amqp/load/QueueAckMixTestCase.java",
"license": "apache-2.0",
"size": 6551
} | [
"java.io.IOException",
"javax.jms.JMSException",
"javax.naming.NamingException",
"org.testng.Assert",
"org.testng.annotations.Test",
"org.wso2.mb.integration.common.clients.AndesClient",
"org.wso2.mb.integration.common.clients.configurations.AndesJMSConsumerClientConfiguration",
"org.wso2.mb.integration.common.clients.configurations.AndesJMSPublisherClientConfiguration",
"org.wso2.mb.integration.common.clients.exceptions.AndesClientConfigurationException",
"org.wso2.mb.integration.common.clients.exceptions.AndesClientException",
"org.wso2.mb.integration.common.clients.operations.utils.AndesClientConstants",
"org.wso2.mb.integration.common.clients.operations.utils.AndesClientUtils",
"org.wso2.mb.integration.common.clients.operations.utils.ExchangeType",
"org.wso2.mb.integration.common.clients.operations.utils.JMSAcknowledgeMode"
] | import java.io.IOException; import javax.jms.JMSException; import javax.naming.NamingException; import org.testng.Assert; import org.testng.annotations.Test; import org.wso2.mb.integration.common.clients.AndesClient; import org.wso2.mb.integration.common.clients.configurations.AndesJMSConsumerClientConfiguration; import org.wso2.mb.integration.common.clients.configurations.AndesJMSPublisherClientConfiguration; import org.wso2.mb.integration.common.clients.exceptions.AndesClientConfigurationException; import org.wso2.mb.integration.common.clients.exceptions.AndesClientException; import org.wso2.mb.integration.common.clients.operations.utils.AndesClientConstants; import org.wso2.mb.integration.common.clients.operations.utils.AndesClientUtils; import org.wso2.mb.integration.common.clients.operations.utils.ExchangeType; import org.wso2.mb.integration.common.clients.operations.utils.JMSAcknowledgeMode; | import java.io.*; import javax.jms.*; import javax.naming.*; import org.testng.*; import org.testng.annotations.*; import org.wso2.mb.integration.common.clients.*; import org.wso2.mb.integration.common.clients.configurations.*; import org.wso2.mb.integration.common.clients.exceptions.*; import org.wso2.mb.integration.common.clients.operations.utils.*; | [
"java.io",
"javax.jms",
"javax.naming",
"org.testng",
"org.testng.annotations",
"org.wso2.mb"
] | java.io; javax.jms; javax.naming; org.testng; org.testng.annotations; org.wso2.mb; | 848,916 |
public void refreshEjb20Attributes() {
// after we have looped through the get methods,
// 'removedEjb20Attributes' will be left with the attributes that need to be removed
Collection removedEjb20Attributes = CollectionTools.collection(this.ejb20Attributes());
for (Iterator stream = this.ejb20GetMethods(); stream.hasNext(); ) {
MWMethod ejb20GetMethod = (MWMethod) stream.next();
MWMethod ejb20SetMethod = ejb20SetMethodFor(ejb20GetMethod);
if (ejb20SetMethod != null) {
this.refreshEjb20Attribute(ejb20GetMethod, ejb20SetMethod, removedEjb20Attributes);
}
}
this.removeEjb20Attributes(removedEjb20Attributes);
if (this.getSuperclass() != null) {
this.getSuperclass().refreshEjb20Attributes();
}
} | void function() { Collection removedEjb20Attributes = CollectionTools.collection(this.ejb20Attributes()); for (Iterator stream = this.ejb20GetMethods(); stream.hasNext(); ) { MWMethod ejb20GetMethod = (MWMethod) stream.next(); MWMethod ejb20SetMethod = ejb20SetMethodFor(ejb20GetMethod); if (ejb20SetMethod != null) { this.refreshEjb20Attribute(ejb20GetMethod, ejb20SetMethod, removedEjb20Attributes); } } this.removeEjb20Attributes(removedEjb20Attributes); if (this.getSuperclass() != null) { this.getSuperclass().refreshEjb20Attributes(); } } | /**
* synchronize the EJB 2.0 attributes with the abstract getters and
* setters; cascade up through superclasses
*/ | synchronize the EJB 2.0 attributes with the abstract getters and setters; cascade up through superclasses | refreshEjb20Attributes | {
"repo_name": "RallySoftware/eclipselink.runtime",
"path": "utils/eclipselink.utils.workbench/mappingsmodel/source/org/eclipse/persistence/tools/workbench/mappingsmodel/meta/MWClass.java",
"license": "epl-1.0",
"size": 121989
} | [
"java.util.Collection",
"java.util.Iterator",
"org.eclipse.persistence.tools.workbench.utility.CollectionTools"
] | import java.util.Collection; import java.util.Iterator; import org.eclipse.persistence.tools.workbench.utility.CollectionTools; | import java.util.*; import org.eclipse.persistence.tools.workbench.utility.*; | [
"java.util",
"org.eclipse.persistence"
] | java.util; org.eclipse.persistence; | 105 |
public static int groupingUnit2CDateUnit( GroupingUnitType groupingUnitType )
{
if ( groupingUnitType != null )
{
switch ( groupingUnitType.getValue( ) )
{
case GroupingUnitType.SECONDS :
return Calendar.SECOND;
case GroupingUnitType.MINUTES :
return Calendar.MINUTE;
case GroupingUnitType.HOURS :
return Calendar.HOUR_OF_DAY;
case GroupingUnitType.DAYS :
case GroupingUnitType.DAY_OF_MONTH :
return Calendar.DAY_OF_MONTH;
case GroupingUnitType.DAY_OF_WEEK :
return Calendar.DAY_OF_WEEK;
case GroupingUnitType.DAY_OF_YEAR :
return Calendar.DAY_OF_YEAR;
case GroupingUnitType.WEEKS :
case GroupingUnitType.WEEK_OF_MONTH :
return Calendar.WEEK_OF_MONTH;
case GroupingUnitType.WEEK_OF_YEAR :
return Calendar.WEEK_OF_YEAR;
case GroupingUnitType.MONTHS :
return Calendar.MONTH;
case GroupingUnitType.QUARTERS :
return CDateTime.QUARTER;
case GroupingUnitType.YEARS :
return Calendar.YEAR;
}
}
return Calendar.MILLISECOND;
} | static int function( GroupingUnitType groupingUnitType ) { if ( groupingUnitType != null ) { switch ( groupingUnitType.getValue( ) ) { case GroupingUnitType.SECONDS : return Calendar.SECOND; case GroupingUnitType.MINUTES : return Calendar.MINUTE; case GroupingUnitType.HOURS : return Calendar.HOUR_OF_DAY; case GroupingUnitType.DAYS : case GroupingUnitType.DAY_OF_MONTH : return Calendar.DAY_OF_MONTH; case GroupingUnitType.DAY_OF_WEEK : return Calendar.DAY_OF_WEEK; case GroupingUnitType.DAY_OF_YEAR : return Calendar.DAY_OF_YEAR; case GroupingUnitType.WEEKS : case GroupingUnitType.WEEK_OF_MONTH : return Calendar.WEEK_OF_MONTH; case GroupingUnitType.WEEK_OF_YEAR : return Calendar.WEEK_OF_YEAR; case GroupingUnitType.MONTHS : return Calendar.MONTH; case GroupingUnitType.QUARTERS : return CDateTime.QUARTER; case GroupingUnitType.YEARS : return Calendar.YEAR; } } return Calendar.MILLISECOND; } | /**
* Convert GroupingUnit type to CDateUnit type.
*
* @param groupingUnitType the GroupingUnit type.
* @return CDateUnit type of integer.
* @since 2.3, it is merged from <code>DataProcessor</code>, make the method to be a static usage.
*/ | Convert GroupingUnit type to CDateUnit type | groupingUnit2CDateUnit | {
"repo_name": "Charling-Huang/birt",
"path": "chart/org.eclipse.birt.chart.engine/src/org/eclipse/birt/chart/internal/datafeed/GroupingUtil.java",
"license": "epl-1.0",
"size": 4184
} | [
"com.ibm.icu.util.Calendar",
"org.eclipse.birt.chart.model.attribute.GroupingUnitType",
"org.eclipse.birt.chart.util.CDateTime"
] | import com.ibm.icu.util.Calendar; import org.eclipse.birt.chart.model.attribute.GroupingUnitType; import org.eclipse.birt.chart.util.CDateTime; | import com.ibm.icu.util.*; import org.eclipse.birt.chart.model.attribute.*; import org.eclipse.birt.chart.util.*; | [
"com.ibm.icu",
"org.eclipse.birt"
] | com.ibm.icu; org.eclipse.birt; | 118,356 |
public void setLineaGastoFamiliaPersistence(
LineaGastoFamiliaPersistence lineaGastoFamiliaPersistence) {
this.lineaGastoFamiliaPersistence = lineaGastoFamiliaPersistence;
} | void function( LineaGastoFamiliaPersistence lineaGastoFamiliaPersistence) { this.lineaGastoFamiliaPersistence = lineaGastoFamiliaPersistence; } | /**
* Sets the linea gasto familia persistence.
*
* @param lineaGastoFamiliaPersistence the linea gasto familia persistence
*/ | Sets the linea gasto familia persistence | setLineaGastoFamiliaPersistence | {
"repo_name": "RMarinDTI/CloubityRepo",
"path": "Servicio-portlet/docroot/WEB-INF/src/es/davinciti/liferay/service/base/CurrencyServiceBaseImpl.java",
"license": "unlicense",
"size": 52888
} | [
"es.davinciti.liferay.service.persistence.LineaGastoFamiliaPersistence"
] | import es.davinciti.liferay.service.persistence.LineaGastoFamiliaPersistence; | import es.davinciti.liferay.service.persistence.*; | [
"es.davinciti.liferay"
] | es.davinciti.liferay; | 2,247,448 |
public static void writeFile (CompoundTag tag, String path) {
writeFile(tag, new File(path));
}
| static void function (CompoundTag tag, String path) { writeFile(tag, new File(path)); } | /**
* Writes the given root CompoundTag to the given file.
*
* @param tag Tag to write.
* @param path Path to write to.
*/ | Writes the given root CompoundTag to the given file | writeFile | {
"repo_name": "darkhax/OpenNBT",
"path": "src/main/java/net/darkhax/opennbt/NBTHelper.java",
"license": "mit",
"size": 9097
} | [
"java.io.File",
"net.darkhax.opennbt.tags.CompoundTag"
] | import java.io.File; import net.darkhax.opennbt.tags.CompoundTag; | import java.io.*; import net.darkhax.opennbt.tags.*; | [
"java.io",
"net.darkhax.opennbt"
] | java.io; net.darkhax.opennbt; | 773,280 |
public static void uncheckedVoid(Callable<?> f) {
Handler.unchecked(f);
}
| static void function(Callable<?> f) { Handler.unchecked(f); } | /**
* This method accepts a <code>Callable</code> type value that contains a method call data, and calls the method and handles any
* exceptions that may be thrown by the method (lambda) expression.
*
* @param Callable function/method <code>Callable</code>
*/ | This method accepts a <code>Callable</code> type value that contains a method call data, and calls the method and handles any exceptions that may be thrown by the method (lambda) expression | uncheckedVoid | {
"repo_name": "casmong/general-java-utils",
"path": "com/research/innovate/microservice/template/Handler.java",
"license": "gpl-3.0",
"size": 1986
} | [
"java.util.concurrent.Callable"
] | import java.util.concurrent.Callable; | import java.util.concurrent.*; | [
"java.util"
] | java.util; | 2,264,864 |
@Metadata(label = "producer", description = "Sets whether date headers should be formatted according to the ISO 8601 standard.")
public void setFormatDateHeadersToIso8601(boolean formatDateHeadersToIso8601) {
getConfiguration().setFormatDateHeadersToIso8601(formatDateHeadersToIso8601);
}
// Implementation methods
// ------------------------------------------------------------------------- | @Metadata(label = STR, description = STR) void function(boolean formatDateHeadersToIso8601) { getConfiguration().setFormatDateHeadersToIso8601(formatDateHeadersToIso8601); } | /**
* Sets whether date headers should be formatted according to the ISO 8601
* standard.
*/ | Sets whether date headers should be formatted according to the ISO 8601 standard | setFormatDateHeadersToIso8601 | {
"repo_name": "objectiser/camel",
"path": "components/camel-jms/src/main/java/org/apache/camel/component/jms/JmsComponent.java",
"license": "apache-2.0",
"size": 83769
} | [
"org.apache.camel.spi.Metadata"
] | import org.apache.camel.spi.Metadata; | import org.apache.camel.spi.*; | [
"org.apache.camel"
] | org.apache.camel; | 2,455,546 |
public void registerInterruptListener(final AccessorySensorEventListener listener)
throws AccessorySensorException {
if (!mIsInterruptModeSupported) {
throw new IllegalStateException("Interrupt mode not supported");
}
// Rate is ignored in interrupt mode.
registerListener(listener, Sensor.SensorRates.SENSOR_DELAY_NORMAL,
Sensor.SensorInterruptMode.SENSOR_INTERRUPT_ENABLED);
} | void function(final AccessorySensorEventListener listener) throws AccessorySensorException { if (!mIsInterruptModeSupported) { throw new IllegalStateException(STR); } registerListener(listener, Sensor.SensorRates.SENSOR_DELAY_NORMAL, Sensor.SensorInterruptMode.SENSOR_INTERRUPT_ENABLED); } | /**
* Register a sensor event listener that gets new data when the sensor has
* new data. It is only possible to have one listener per sensor.
*
* @param listener The event listener.
*/ | Register a sensor event listener that gets new data when the sensor has new data. It is only possible to have one listener per sensor | registerInterruptListener | {
"repo_name": "einvalentin/buildwatch",
"path": "3rdParty/SmartExtensionUtils/src/com/sonyericsson/extras/liveware/extension/util/sensor/AccessorySensor.java",
"license": "apache-2.0",
"size": 12739
} | [
"com.sonyericsson.extras.liveware.aef.sensor.Sensor"
] | import com.sonyericsson.extras.liveware.aef.sensor.Sensor; | import com.sonyericsson.extras.liveware.aef.sensor.*; | [
"com.sonyericsson.extras"
] | com.sonyericsson.extras; | 1,427,988 |
protected static Authentication askForAuthentication(String host, String message) {
UserValidationDialog ui = new UserValidationDialog(null, host, message);
ui.open();
return ui.getAuthentication();
}
protected UserValidationDialog(Shell parentShell, String host, String message) {
super(parentShell);
this.host = host;
this.message = message;
setBlockOnOpen(true);
} | static Authentication function(String host, String message) { UserValidationDialog ui = new UserValidationDialog(null, host, message); ui.open(); return ui.getAuthentication(); } protected UserValidationDialog(Shell parentShell, String host, String message) { super(parentShell); this.host = host; this.message = message; setBlockOnOpen(true); } | /**
* Gets user and password from a user Must be called from UI thread
*
* @return UserAuthentication that contains the userid and the password or <code>null</code> if the dialog has been
* cancelled
*/ | Gets user and password from a user Must be called from UI thread | askForAuthentication | {
"repo_name": "Caleydo/caleydo",
"path": "org.caleydo.rcp/src/org/caleydo/core/internal/gui/UserValidationDialog.java",
"license": "bsd-3-clause",
"size": 4994
} | [
"org.eclipse.swt.widgets.Shell"
] | import org.eclipse.swt.widgets.Shell; | import org.eclipse.swt.widgets.*; | [
"org.eclipse.swt"
] | org.eclipse.swt; | 419,829 |
public static WritableRaster createWritableRaster(SampleModel sm,
Point location)
{
return new WritableRaster(sm, location);
} | static WritableRaster function(SampleModel sm, Point location) { return new WritableRaster(sm, location); } | /**
* Creates a new writable raster.
*
* @param sm the sample model.
* @param location
*
* @return The new writable raster.
*/ | Creates a new writable raster | createWritableRaster | {
"repo_name": "SanDisk-Open-Source/SSD_Dashboard",
"path": "uefi/gcc/gcc-4.6.3/libjava/classpath/java/awt/image/Raster.java",
"license": "gpl-2.0",
"size": 30991
} | [
"java.awt.Point"
] | import java.awt.Point; | import java.awt.*; | [
"java.awt"
] | java.awt; | 679,501 |
@Permission({ ServiceOperation.DO_PAYMENT, ServiceOperation.RECEIVE_PAYMENT })
@WebMethod
List<TransferTypeVO> searchTransferTypes(@WebParam(name = "params") TransferTypeSearchParameters params); | @Permission({ ServiceOperation.DO_PAYMENT, ServiceOperation.RECEIVE_PAYMENT }) List<TransferTypeVO> searchTransferTypes(@WebParam(name = STR) TransferTypeSearchParameters params); | /**
* Returns a list of transfer types for the given parameters
*/ | Returns a list of transfer types for the given parameters | searchTransferTypes | {
"repo_name": "robertoandrade/cyclos",
"path": "src/nl/strohalm/cyclos/webservices/accounts/AccountWebService.java",
"license": "gpl-2.0",
"size": 2592
} | [
"java.util.List",
"javax.jws.WebParam",
"nl.strohalm.cyclos.entities.services.ServiceOperation",
"nl.strohalm.cyclos.webservices.Permission",
"nl.strohalm.cyclos.webservices.model.TransferTypeVO"
] | import java.util.List; import javax.jws.WebParam; import nl.strohalm.cyclos.entities.services.ServiceOperation; import nl.strohalm.cyclos.webservices.Permission; import nl.strohalm.cyclos.webservices.model.TransferTypeVO; | import java.util.*; import javax.jws.*; import nl.strohalm.cyclos.entities.services.*; import nl.strohalm.cyclos.webservices.*; import nl.strohalm.cyclos.webservices.model.*; | [
"java.util",
"javax.jws",
"nl.strohalm.cyclos"
] | java.util; javax.jws; nl.strohalm.cyclos; | 2,317,699 |
public void checkDuplicateSynchronisationConnection(String entityAddress) throws BusinessValidationException {
if (synchronisationConnectionRepository.findByEntityAddress(entityAddress) != null) {
throw new BusinessValidationException(RestError.DUPLICATE, "SynchronisationConnection", entityAddress);
}
} | void function(String entityAddress) throws BusinessValidationException { if (synchronisationConnectionRepository.findByEntityAddress(entityAddress) != null) { throw new BusinessValidationException(RestError.DUPLICATE, STR, entityAddress); } } | /**
* Throws a {@link BusinessValidationException} if entityAddress is a duplicate SynchronisationConnection entityAddress.
*
* @param entityAddress an entityAddress
* @throws BusinessValidationException
*/ | Throws a <code>BusinessValidationException</code> if entityAddress is a duplicate SynchronisationConnection entityAddress | checkDuplicateSynchronisationConnection | {
"repo_name": "USEF-Foundation/ri.usef.energy",
"path": "usef-build/usef-workflow/usef-agr/src/main/java/energy/usef/agr/service/business/AggregatorValidationBusinessService.java",
"license": "apache-2.0",
"size": 3518
} | [
"energy.usef.core.exception.BusinessValidationException",
"energy.usef.core.exception.RestError"
] | import energy.usef.core.exception.BusinessValidationException; import energy.usef.core.exception.RestError; | import energy.usef.core.exception.*; | [
"energy.usef.core"
] | energy.usef.core; | 2,695,940 |
public ActionForward execute(Exception ex, ExceptionConfig ae,
ActionMapping mapping,
ActionForm formInstance,
HttpServletRequest request,
HttpServletResponse response)
throws ServletException {
// if there's already errors in the request, don't process
ActionErrors errors =
(ActionErrors) request.getAttribute(Globals.ERROR_KEY);
if (errors != null) {
return null;
}
ActionForward forward =
super.execute(ex, ae, mapping, formInstance, request, response);
ActionMessage error = null;
String property = null;
// log the exception to the default logger
logException(ex);
// Get the chained exceptions (causes) and add them to the
// list of errors as well
while (ex != null) {
String msg = ex.getMessage();
error = new ActionMessage("errors.detail", msg);
property = error.getKey();
ex = (Exception) ex.getCause();
if ((ex != null) && (ex.getMessage() != null)) {
// check to see if the child message is the same
// if so, don't store it
if (msg.indexOf(ex.getMessage()) == -1) {
storeException(request, property, error, forward);
}
} else {
storeException(request, property, error, forward);
}
}
return forward;
}
| ActionForward function(Exception ex, ExceptionConfig ae, ActionMapping mapping, ActionForm formInstance, HttpServletRequest request, HttpServletResponse response) throws ServletException { ActionErrors errors = (ActionErrors) request.getAttribute(Globals.ERROR_KEY); if (errors != null) { return null; } ActionForward forward = super.execute(ex, ae, mapping, formInstance, request, response); ActionMessage error = null; String property = null; logException(ex); while (ex != null) { String msg = ex.getMessage(); error = new ActionMessage(STR, msg); property = error.getKey(); ex = (Exception) ex.getCause(); if ((ex != null) && (ex.getMessage() != null)) { if (msg.indexOf(ex.getMessage()) == -1) { storeException(request, property, error, forward); } } else { storeException(request, property, error, forward); } } return forward; } | /**
* This method handles any java.lang.Exceptions that are not
* caught in previous classes. It will loop through and get
* all the causes (exception chain), create ActionErrors,
* add them to the request and then forward to the input.
*
* @see org.apache.struts.action.ExceptionHandler#execute
* (
* java.lang.Exception,
* org.apache.struts.config.ExceptionConfig,
* org.apache.struts.action.ActionMapping,
* org.apache.struts.action.ActionForm,
* javax.servlet.http.HttpServletRequest,
* javax.servlet.http.HttpServletResponse
* )
*/ | This method handles any java.lang.Exceptions that are not caught in previous classes. It will loop through and get all the causes (exception chain), create ActionErrors, add them to the request and then forward to the input | execute | {
"repo_name": "buptwufengjiao/J2EEApp",
"path": "src/web/org/appfuse/webapp/action/ActionExceptionHandler.java",
"license": "apache-2.0",
"size": 5129
} | [
"javax.servlet.ServletException",
"javax.servlet.http.HttpServletRequest",
"javax.servlet.http.HttpServletResponse",
"org.apache.struts.Globals",
"org.apache.struts.action.ActionErrors",
"org.apache.struts.action.ActionForm",
"org.apache.struts.action.ActionForward",
"org.apache.struts.action.ActionMapping",
"org.apache.struts.action.ActionMessage",
"org.apache.struts.config.ExceptionConfig"
] | import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.apache.struts.Globals; import org.apache.struts.action.ActionErrors; import org.apache.struts.action.ActionForm; import org.apache.struts.action.ActionForward; import org.apache.struts.action.ActionMapping; import org.apache.struts.action.ActionMessage; import org.apache.struts.config.ExceptionConfig; | import javax.servlet.*; import javax.servlet.http.*; import org.apache.struts.*; import org.apache.struts.action.*; import org.apache.struts.config.*; | [
"javax.servlet",
"org.apache.struts"
] | javax.servlet; org.apache.struts; | 671,484 |
@Override
@Test(expected = ItemNotSavedException.class)
public void testMergeNonExistent() {
getDao().merge(SingleUser.getInstance());
} | @Test(expected = ItemNotSavedException.class) void function() { getDao().merge(SingleUser.getInstance()); } | /**
* Overwritten method from {@link GenericDaoTest}. This method has to be called in a different way because an
* {@link UnsupportedOperationException} is expected.
*/ | Overwritten method from <code>GenericDaoTest</code>. This method has to be called in a different way because an <code>UnsupportedOperationException</code> is expected | testMergeNonExistent | {
"repo_name": "physalix-enrollment/physalix",
"path": "User/src/test/java/hsa/awp/user/dao/TestSingleUserDirectoryDao.java",
"license": "gpl-3.0",
"size": 15979
} | [
"org.junit.Test"
] | import org.junit.Test; | import org.junit.*; | [
"org.junit"
] | org.junit; | 259,674 |
private synchronized void initialize() throws IOException, LangDetectException {
if (initialized) {
return;
}
try (InputStream input = getClass().getResourceAsStream(LANGUAGE_LIST_RESOURCE)) {
List<String> languageList = IOUtils.readLines(input);
List<String> languageProfiles = new ArrayList<String>();
for (String language : languageList) {
languageProfiles.add(readProfileFromResource(language));
}
DetectorFactory.loadProfile(languageProfiles);
}
initialized = true;
} | synchronized void function() throws IOException, LangDetectException { if (initialized) { return; } try (InputStream input = getClass().getResourceAsStream(LANGUAGE_LIST_RESOURCE)) { List<String> languageList = IOUtils.readLines(input); List<String> languageProfiles = new ArrayList<String>(); for (String language : languageList) { languageProfiles.add(readProfileFromResource(language)); } DetectorFactory.loadProfile(languageProfiles); } initialized = true; } | /**
* Initialize language detection subsystem
*/ | Initialize language detection subsystem | initialize | {
"repo_name": "andreasbehnke/cee",
"path": "cee-parser-impl/src/main/java/org/cee/language/impl/LanguageDetectorImpl.java",
"license": "apache-2.0",
"size": 2887
} | [
"com.cybozu.labs.langdetect.DetectorFactory",
"com.cybozu.labs.langdetect.LangDetectException",
"java.io.IOException",
"java.io.InputStream",
"java.util.ArrayList",
"java.util.List",
"org.apache.commons.io.IOUtils"
] | import com.cybozu.labs.langdetect.DetectorFactory; import com.cybozu.labs.langdetect.LangDetectException; import java.io.IOException; import java.io.InputStream; import java.util.ArrayList; import java.util.List; import org.apache.commons.io.IOUtils; | import com.cybozu.labs.langdetect.*; import java.io.*; import java.util.*; import org.apache.commons.io.*; | [
"com.cybozu.labs",
"java.io",
"java.util",
"org.apache.commons"
] | com.cybozu.labs; java.io; java.util; org.apache.commons; | 1,654,844 |
@Override
public int size() {
int count = 0;
for (final Iterator<E> it=iterator(); it.hasNext();) {
it.next();
if (++count == Integer.MAX_VALUE) {
break;
}
}
return count;
} | int function() { int count = 0; for (final Iterator<E> it=iterator(); it.hasNext();) { it.next(); if (++count == Integer.MAX_VALUE) { break; } } return count; } | /**
* Returns the number of elements in this set. The default implementation counts the number of elements
* returned by the {@link #iterator() iterator}. Subclasses are encouraged to cache this value if they
* know that the underlying storage is immutable.
*
* @return the number of elements in this set.
*/ | Returns the number of elements in this set. The default implementation counts the number of elements returned by the <code>#iterator() iterator</code>. Subclasses are encouraged to cache this value if they know that the underlying storage is immutable | size | {
"repo_name": "Geomatys/sis",
"path": "core/sis-utility/src/main/java/org/apache/sis/internal/util/SetOfUnknownSize.java",
"license": "apache-2.0",
"size": 7103
} | [
"java.util.Iterator"
] | import java.util.Iterator; | import java.util.*; | [
"java.util"
] | java.util; | 197,581 |
EAttribute getWebService_Method(); | EAttribute getWebService_Method(); | /**
* Returns the meta object for the attribute '{@link fr.eyal.lib.datalib.genmodel.android.datalib.WebService#getMethod <em>Method</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return the meta object for the attribute '<em>Method</em>'.
* @see fr.eyal.lib.datalib.genmodel.android.datalib.WebService#getMethod()
* @see #getWebService()
* @generated
*/ | Returns the meta object for the attribute '<code>fr.eyal.lib.datalib.genmodel.android.datalib.WebService#getMethod Method</code>'. | getWebService_Method | {
"repo_name": "eyal-lezmy/Android-DataLib",
"path": "Android-DataLib-Generator/fr.eyal.datalib.generator/src/fr/eyal/lib/datalib/genmodel/android/datalib/DatalibPackage.java",
"license": "apache-2.0",
"size": 19274
} | [
"org.eclipse.emf.ecore.EAttribute"
] | import org.eclipse.emf.ecore.EAttribute; | import org.eclipse.emf.ecore.*; | [
"org.eclipse.emf"
] | org.eclipse.emf; | 2,169,922 |
@Override public void enterEqualsToExpression(@NotNull BramsprParser.EqualsToExpressionContext ctx) { } | @Override public void enterEqualsToExpression(@NotNull BramsprParser.EqualsToExpressionContext ctx) { } | /**
* {@inheritDoc}
* <p/>
* The default implementation does nothing.
*/ | The default implementation does nothing | exitSignExpression | {
"repo_name": "bcleenders/Bramspr",
"path": "src/bramspr/BramsprBaseListener.java",
"license": "mit",
"size": 21948
} | [
"org.antlr.v4.runtime.misc.NotNull"
] | import org.antlr.v4.runtime.misc.NotNull; | import org.antlr.v4.runtime.misc.*; | [
"org.antlr.v4"
] | org.antlr.v4; | 2,277,668 |
public Optional<ConceptSnapshot> getContainingConcept() {
return containingConcept;
} | Optional<ConceptSnapshot> function() { return containingConcept; } | /**
* This may return an empty, if the concept and/or matching component was not on the path
*/ | This may return an empty, if the concept and/or matching component was not on the path | getContainingConcept | {
"repo_name": "Apelon-VA/va-isaac-gui",
"path": "otf-util/src/main/java/gov/va/isaac/search/CompositeSearchResult.java",
"license": "apache-2.0",
"size": 10366
} | [
"gov.vha.isaac.ochre.api.component.concept.ConceptSnapshot",
"java.util.Optional"
] | import gov.vha.isaac.ochre.api.component.concept.ConceptSnapshot; import java.util.Optional; | import gov.vha.isaac.ochre.api.component.concept.*; import java.util.*; | [
"gov.vha.isaac",
"java.util"
] | gov.vha.isaac; java.util; | 2,534,733 |
public void write(StatementAbstractType statement) throws ProcessingException {
throw logger.notImplementedYet("StatementAbstractType");
} | void function(StatementAbstractType statement) throws ProcessingException { throw logger.notImplementedYet(STR); } | /**
* Write an {@code StatementAbstractType} to stream
*
* @param statement
* @param out
*
* @throws ProcessingException
*/ | Write an StatementAbstractType to stream | write | {
"repo_name": "anaerobic/keycloak",
"path": "saml/saml-core/src/main/java/org/keycloak/saml/processing/core/saml/v1/writers/SAML11AssertionWriter.java",
"license": "apache-2.0",
"size": 19194
} | [
"org.keycloak.dom.saml.v2.assertion.StatementAbstractType",
"org.keycloak.saml.common.exceptions.ProcessingException"
] | import org.keycloak.dom.saml.v2.assertion.StatementAbstractType; import org.keycloak.saml.common.exceptions.ProcessingException; | import org.keycloak.dom.saml.v2.assertion.*; import org.keycloak.saml.common.exceptions.*; | [
"org.keycloak.dom",
"org.keycloak.saml"
] | org.keycloak.dom; org.keycloak.saml; | 2,353,340 |
protected void addGlobalI18nMessage(String bundleName, FacesMessage.Severity severity, String summaryKey, Object ... summaryParams) {
addI18nMessage(null, bundleName, severity, summaryKey, summaryParams, null, null);
} | void function(String bundleName, FacesMessage.Severity severity, String summaryKey, Object ... summaryParams) { addI18nMessage(null, bundleName, severity, summaryKey, summaryParams, null, null); } | /**
* Shortcut to addI18nMessage(): global message with specified severity and including only a parameterized summary.
*
* @param bundleName
* The name of the bundle where to look for the message.
* @param severity
* The severity of the message (one of the severity levels defined by JSF).
* @param summaryKey
* The key that identifies the message that will serve as summary in the resource bundle.
* @param summaryParams
* The parameters for the summary message.
*
* @see br.ufes.inf.nemo.jbutler.ejb.controller.JSFController#addI18nMessage(java.lang.String, java.lang.String,
* javax.faces.application.FacesMessage.Severity, java.lang.String, java.lang.Object[], java.lang.String,
* java.lang.Object[])
*/ | Shortcut to addI18nMessage(): global message with specified severity and including only a parameterized summary | addGlobalI18nMessage | {
"repo_name": "manzoli2122/Vip",
"path": "src/br/ufes/inf/nemo/jbutler/ejb/controller/JSFController.java",
"license": "apache-2.0",
"size": 27672
} | [
"javax.faces.application.FacesMessage"
] | import javax.faces.application.FacesMessage; | import javax.faces.application.*; | [
"javax.faces"
] | javax.faces; | 2,678,043 |
@Test
public void test_setLocation()
{
String name[] = {TESTLOC_0_LABEL, TESTLOC_1_LABEL};
String lat[] = {TESTLOC_0_LAT, TESTLOC_1_LAT };
String lon[] = {TESTLOC_0_LON, TESTLOC_1_LON };
int n = name.length;
int i = new Random().nextInt(n);
setLocation(name[i], lat[i], lon[i]);
// TODO: verify action (may need to move this test to SuntimesActivityTest)
} | void function() { String name[] = {TESTLOC_0_LABEL, TESTLOC_1_LABEL}; String lat[] = {TESTLOC_0_LAT, TESTLOC_1_LAT }; String lon[] = {TESTLOC_0_LON, TESTLOC_1_LON }; int n = name.length; int i = new Random().nextInt(n); setLocation(name[i], lat[i], lon[i]); } | /**
* UI Test
* Set the location using the location dialog.
*/ | UI Test Set the location using the location dialog | test_setLocation | {
"repo_name": "forrestguice/SuntimesWidget",
"path": "app/src/androidTest/java/com/forrestguice/suntimeswidget/LocationDialogTest.java",
"license": "gpl-3.0",
"size": 12995
} | [
"java.util.Random"
] | import java.util.Random; | import java.util.*; | [
"java.util"
] | java.util; | 30,895 |
Path getPathForCharacterCode(int code) throws IOException;
void dispose();
| Path getPathForCharacterCode(int code) throws IOException; void dispose(); | /**
* Remove all cached resources.
*/ | Remove all cached resources | dispose | {
"repo_name": "kzganesan/PdfBox-Android",
"path": "library/src/main/java/org/apache/pdfbox/rendering/Glyph2D.java",
"license": "apache-2.0",
"size": 631
} | [
"android.graphics.Path",
"java.io.IOException"
] | import android.graphics.Path; import java.io.IOException; | import android.graphics.*; import java.io.*; | [
"android.graphics",
"java.io"
] | android.graphics; java.io; | 305,553 |
Collection<CaseInstance> getCaseInstancesByDefinition(String caseDefinitionId, List<CaseStatus> statuses, QueryContext queryContext); | Collection<CaseInstance> getCaseInstancesByDefinition(String caseDefinitionId, List<CaseStatus> statuses, QueryContext queryContext); | /**
* Returns all available case instances;
* @param caseDefinitionId case definition id
* @param statuses list of statuses that case should be in to match
* @param queryContext control parameters for the result e.g. sorting, paging
*
*/ | Returns all available case instances | getCaseInstancesByDefinition | {
"repo_name": "DuncanDoyle/jbpm",
"path": "jbpm-case-mgmt/jbpm-case-mgmt-api/src/main/java/org/jbpm/casemgmt/api/CaseRuntimeDataService.java",
"license": "apache-2.0",
"size": 14153
} | [
"java.util.Collection",
"java.util.List",
"org.jbpm.casemgmt.api.model.CaseStatus",
"org.jbpm.casemgmt.api.model.instance.CaseInstance",
"org.kie.api.runtime.query.QueryContext"
] | import java.util.Collection; import java.util.List; import org.jbpm.casemgmt.api.model.CaseStatus; import org.jbpm.casemgmt.api.model.instance.CaseInstance; import org.kie.api.runtime.query.QueryContext; | import java.util.*; import org.jbpm.casemgmt.api.model.*; import org.jbpm.casemgmt.api.model.instance.*; import org.kie.api.runtime.query.*; | [
"java.util",
"org.jbpm.casemgmt",
"org.kie.api"
] | java.util; org.jbpm.casemgmt; org.kie.api; | 1,031,452 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.