query stringlengths 8 1.54M | document stringlengths 9 312k | negatives listlengths 19 20 | metadata dict |
|---|---|---|---|
Return all the classNames, which is the keySet of the classMap | public Collection<String> getClassNames() {
return new ArrayList<>(this.classMap.keySet());
} | [
"Set<String> getClasses() {\n\t\treturn this.classes.keySet();\n\t}",
"private Map getFullClassCollection()\n {\n if(classKeyToClass == null)\n {\n classKeyToClass = new HashMap(101);\n }\n\n return classKeyToClass;\n }",
"public Set getClasses()\n\t{\n\t\tSet histog... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Return the loop mode for the config. | public boolean isLoopMode(); | [
"public void setLoopMode(boolean loopMode);",
"public int getLoopInterval()\r\n {\r\n return loopInterval;\r\n }",
"int getRepeatMode();",
"public LoopType getLoopType() {\n\t\treturn loopType;\n\t}",
"public boolean getLoop() {\n return this.loop.getValue();\n }",
"public void setL... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
return PersonBean from db by id | PersonBean getById(Long id); | [
"public Person getPersonById(Long id);",
"Person getPerson(Long id);",
"Person getPersonById(long id);",
"public Person getPerson(long id){\n return personRepository.findOne(id);\n }",
"public Person get( Integer id ) {\n\t\t// Retrieve existing person\n\t\tPerson person = (Person) entityManager.c... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Create an aliased gameparams.t_jumpdata table reference | public TJumpdata(Name alias) {
this(alias, T_JUMPDATA);
} | [
"public TJumpdata(String alias) {\n this(DSL.name(alias), T_JUMPDATA);\n }",
"public TJumpdata() {\n this(DSL.name(\"t_jumpdata\"), null);\n }",
"public CellTable<Map<String, Object>> createNewTable();",
"private void createJumpHistoryTableEntry(\n final long value\n ) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Starts this service to perform action Foo with the given parameters. If the service is already performing a task this action will be queued. | public static void startActionFoo(Context context, String param1, String param2) {
Intent intent = new Intent(context, BootCompletedIntentService.class);
intent.setAction(ACTION_FOO);
intent.putExtra(EXTRA_PARAM1, param1);
intent.putExtra(EXTRA_PARAM2, param2);
context.startServi... | [
"public static void startActionFoo(Context context, String param1, String param2) {\n Intent intent = new Intent(context, GcmIntentService.class);\n intent.setAction(ACTION_FOO);\n intent.putExtra(EXTRA_PARAM1, param1);\n intent.putExtra(EXTRA_PARAM2, param2);\n context.startServi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
initialize the X values for the Hazard Curve control Panel It will enable the user to set the X values | private void initX_ValuesControl(){
if(xValuesPanel == null)
xValuesPanel = new X_ValuesInCurveControlPanel(this,this);
if(!useCustomX_Values)
xValuesPanel.useDefaultX_Values();
else
xValuesPanel.setX_Values(function);
xValuesPanel.pack();
xValuesPanel.setVisible(true);
} | [
"public void setX_ValuesForHazardCurve(){\n useCustomX_Values = false;\n }",
"public void setX_ValuesForHazardCurve(ArbitrarilyDiscretizedFunc func){\n useCustomX_Values = true;\n function =func;\n }",
"private void setXAxisValues() throws VisADException {\n if (getGridDataInstance() == null) ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Installs listeners on the associated control panel of a ribbon band. | protected void installListeners() {
} | [
"protected void installListeners() {\n }",
"protected void installListeners() {\n Window topLevelWindows[] = EventQueueMonitor.getTopLevelWindows();\n if (topLevelWindows != null) {\n for (int i = 0; i < topLevelWindows.length; i++) {\n if (topLevelWindow... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the genomes passing through the node. | public HashSet<String> getGenomes() {
return genomes;
} | [
"public Vector getGenomes() {\n return genomes;\n }",
"public ArrayList<String> getGenomes() {\n return genomes;\n }",
"public abstract Set<Genome> getAvailableGenomes();",
"public synchronized Gene[] getGenes() {\n return m_genes;\n }",
"public T genome() {\n\t\treturn _genome;\n\t}",
"... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calulates the sum of one TableColumn. | private double getColmunSum(TableColumn<Component, String> column) {
double sum = 0;
for (Component component : components) {
sum += Double.parseDouble(column.getCellData(component).replace(',', '.'));
}
return sum;
} | [
"int getColumnSum(int col) {\n int colSum = 0;\n\n for (SheetRow row : rows) { // For row in sheet\n try {\n colSum += row.getValue(col); // Try to add the cell's value\n } catch (NumberFormatException e) { } // If NaN, catch, do nothing\n }\n\n retur... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Parses the generic signature of a field and creates the data structure representing the signature. | @DSGenerator(tool_name = "Doppelganger", tool_version = "2.0", generated_on = "2013-12-30 13:01:25.750 -0500", hash_original_method = "F697D7E02D0C8DEEF4B0854E9491CC15", hash_generated_method = "0985E3F05C2C68525EE88590F9B35C21")
public void parseForField(GenericDeclaration genericDecl,
String signatur... | [
"Type parseFieldTypeSignature() {\n\n switch (symbol) {\n case 'L':\n return parseClassTypeSignature();\n case '[':\n // ArrayTypeSignature ::= \"[\" TypSignature.\n scanSymbol();\n return new GenericArrayTypeImpl(parseTypeSignature());\n case ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the headerInstanceIndex value for this SmmCriteria. | public java.lang.Short getHeaderInstanceIndex() {
return headerInstanceIndex;
} | [
"public int getHeaderStyleIndex() {\n return headerStyleIndex >= 0 ? headerStyleIndex : (headerStyleIndex = styles != null && headerStyle != null ? styles.of(headerStyle) : -1);\n }",
"public java.lang.Short getHeaderInstanceRange() {\r\n return headerInstanceRange;\r\n }",
"public short get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the custom height of this spacer as the preferred field height. | public int getPreferredHeight() {
return this.height;
} | [
"public static int getFieldHeight() {\n return FIELD_HEIGHT;\n }",
"public int getPrefHeight() {\r\n if (ph == -1) {\r\n //compute it\r\n switch (stringer.drawLineType) {\r\n case ITechStringer.TYPE_0_SINGLE_LINE:\r\n case ITechStringer.TYPE_1_SINGLE_LINE_FX:\r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Start the verticle. This is called by Vert.x when the verticle instance is deployed. Don't call it yourself. If your verticle does things in its startup which take some time then you can override this method and call the startFuture some time later when start up is complete. | @Override
public void start(Future<Void> startFuture) throws Exception {
super.start(startFuture);
cH = config().getString("config.host", "localhost");
cP = config().getInteger("config.port", 9000);
router = Router.router(vertx);
router.route().handler(BodyHandler.create().se... | [
"@Override\n\tpublic void start(Future<Void> fut) {\n\n\t\tRouter router = Router.router(vertx);\n\n\t\trouter.route().handler(routingContext -> {\n\n\t\t // This handler will be called for every request\n\t\t HttpServerResponse response = routingContext.response();\n\t\t response.putHeader(\"content-type\", \"t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the name of the order. | public void setOrderName(String name) {
orderName = name;
} | [
"public void setName(String name) {\r\n _name = name;\r\n }",
"public void setName(String name) {\n NAME = name;\n }",
"@Override\n\tpublic void setName(java.lang.String name) {\n\t\t_unit.setName(name);\n\t}",
"public void setName(String name) {\n this.customername = name; ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructors Construct a new CacheItem using the key provided. | public CacheItem(String key) {
setKey(key);
setCreateTime(System.currentTimeMillis());
} | [
"ICacheEntry <K, V> newEntry (K k) throws CacheException;",
"public DiscoveryItem(String key) {\n this(key, null, 0, 0, null);\n }",
"public CacheTagImpl(String key) {\n this(key, ANY);\n }",
"public Item(String key) {\n this.key = key;\n if (key.startsWith(\"http://\")) {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Alter the effective line width of the visualization. | public void setLineWidth(float newWidth) {
Validate.nonNegative(newWidth, "new width");
this.effectiveLineWidth = newWidth;
} | [
"void setLineWidth(float width) { }",
"public void setLineWidth ( int width ) {\r\n\t\tline_width = width;\r\n\t}",
"private void updateLineWidth() {\r\n Node subtreeNode = (Node) getSubtree();\r\n Geometry lines = (Geometry) subtreeNode.getChild(linesChildPosition);\r\n assert effectiveLin... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns all rows from the utente table that match the criteria 'ute_carta_usa_per_premio = :uteCartaUsaPerPremio'. | public Utente[] findWhereUteCartaUsaPerPremioEquals(String uteCartaUsaPerPremio) throws UtenteDaoException
{
return findByDynamicSelect( SQL_SELECT + " WHERE ute_carta_usa_per_premio = ? ORDER BY ute_carta_usa_per_premio", new Object[] { uteCartaUsaPerPremio } );
} | [
"public Utente[] findWhereUtePerChiPrenotiEquals(String utePerChiPrenoti) throws UtenteDaoException\n\t{\n\t\treturn findByDynamicSelect( SQL_SELECT + \" WHERE ute_per_chi_prenoti = ? ORDER BY ute_per_chi_prenoti\", new Object[] { utePerChiPrenoti } );\n\t}",
"public Utente[] findWhereUteProfiloEquals(String uteP... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the value of the 'Uview id' attribute. If the meaning of the 'Uview id' attribute isn't clear, there really should be more of a description here... | String getUview_id(); | [
"String getService_uview_id();",
"java.lang.String getUdid();",
"int getVUid();",
"public String viewId() {\n return this.viewId;\n }",
"public static int getViewId() {\n\t\tviewId += 0x00000001;\n\t\treturn viewId;\n\t}",
"public String getViewId() {\n return viewId;\n }",
"public int get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Checks whether the 'room' field has been set. The room number | public boolean hasRoom() {
return fieldSetFlags()[1];
} | [
"public void setRoom(int value) {\n this.room = value;\n }",
"public int getRoomNumber() \n\t{\n\t\treturn roomNumber;\n\t}",
"public boolean hasRoom() {\n return fieldSetFlags()[3];\n }",
"public int getRoomNumber() {\r\n\t\treturn this.roomNumber;\r\n\t}",
"public void setRoomNum(int roomNum)\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Parses the id token JWT | private GoogleIdJWTClaims parseIdToken(String idToken) throws IllegalArgumentException {
if (idToken == null) {
throw new IllegalArgumentException("Missing id token");
}
return jwtDecoder.decodeClaims(idToken, GoogleIdJWTClaims.class);
} | [
"public static UserIdentity parseToken(String token) {\n try {\n Claims body = Jwts.parser()\n .setSigningKey(JwtUtils.jwtSecret)\n .parseClaimsJws(token)\n .getBody();\n \n if( log.isDebugEnabled() ) \n {\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
generation of random protocol number | private String setProtocolNumber() {
Random rnd = new Random();
return Integer.toString(rnd.nextInt(999999));
} | [
"public static String generatePeerId() {\n\t\tchar[] chars = \"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz\".toCharArray();\n\t\tRandom rando = new Random();\n\t\tStringBuilder sb = new StringBuilder();\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tsb.append(chars[rando.nextInt(chars.length)]);\n\t\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sends a message to Kafka topic 'orderreceived' | private void sendOrderReceivedMessage(String orderId) {
String orderURI = orderEndpoint + "/" + orderId;
OrderReceived orderReceived = new OrderReceived();
orderReceived.setOrderUri(orderURI);
ordersMessageProducer.sendMessage(orderId, orderReceived);
} | [
"@Override\n\tpublic void sendOrder(Order order) {\n\t\ttry \n\t\t{\n\t\t\tConnection connection = connectionFactory.createConnection();\n\t\t\tSession session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);\n\t\t\tMessageProducer messageProducer = session.createProducer(queue);\n\t\t\tTextMessage mess... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Setter of globalSettingsPath attribute of mvnservercreden Ant task what is used to specify custom Maven global setting file. | public void setGlobalSettingsPath( final String globalSettingsPath) {
if (( globalSettingsPath != null) && (globalSettingsPath.trim().length() > 0)) {
this.globalSettingsPath = globalSettingsPath.trim();
}
else {
throw new IllegalArgumentException(
"Value of globalSettingsPath attribute c... | [
"private static String getGlobalConfigPath () {\n if(Utilities.isUnix()) {\n return \"/etc/subversion\"; // NOI18N\n } else if (Utilities.isWindows()){\n return WINDOWS_GLOBAL_CONFIG_DIR;\n } \n return \"\"; // NOI18N\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Delete's all folders on this filesystem. Reset's version to 0. | public void reset() {
if (!isLoaded())
throw new RuntimeException("Using nonloaded filesystem.");
changed = true;
folders = new Folder[0];
version = 0;
} | [
"public void deleteAllFolders() {\n\t\tif (!isLoaded())\n\t\t\tthrow new RuntimeException(\"Using nonloaded filesystem.\");\n\t\tfolders = new Folder[0];\n\t\tchanged = true;\n\t}",
"public void clear() {\n File[] files = cacheDir.listFiles();\n for (File f : files)\n f.delete();\n }",... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the chartOfAccountsCode attribute value. | public void setChartOfAccountsCode(String chartOfAccountsCode) {
this.chartOfAccountsCode = chartOfAccountsCode;
} | [
"public void setChartOfAccountsCode(String chartOfAccountsCode) {\n this.chartOfAccountsCode = chartOfAccountsCode;\n }",
"@Override\n\tpublic void setAccountCode(java.lang.String accountCode) {\n\t\t_lineaGastoCategoria.setAccountCode(accountCode);\n\t}",
"public void setOrganizationChartOfAccountsCo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Processes the classes contained inside the cu adding them to the astStorage as ClassAST objects classes, interfaces, enums and annotation types are considered to be classes for metric evaluation. This will pick up any nested classes as well. as ClassAST objects | public void processClasses(CompilationUnit cu) {
if(cu.getStorage().get().getFileName().equals("package-info.java")) {
this.packageInfo = cu;
}else {
this.cus.add(cu);
}
for(TypeDeclaration<?> node : cu.findAll(TypeDeclaration.class)) {
this.classes.put(node.getNameAsString(), new ClassAST(node, thi... | [
"void initClasses() {\n\t\tif (programUnit == null) return;\n\n\t\t// Add all classes\n\t\tList<BdsNode> cdecls = BdsNodeWalker.findNodes(programUnit, ClassDeclaration.class, true, true);\n\t\tfor (BdsNode n : cdecls) {\n\t\t\tClassDeclaration cd = (ClassDeclaration) n;\n\t\t\tbdsvm.addType(cd.getType());\n\t\t}\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Method to Store Book Issue Details... / When IssuePanel_D FinalSubmit > What will Happen ...? Tables Affected : 1) tbl_books 2) bktrans Steps: 1) Select any 1 ACCNO from tbl_books where tbl_books.accid = GIVEN_ACCID and Status = 'A' 2) Update tbl_books set Status = 'I' which has tbl_books.accid = GIVEN and tbl_books.ac... | private void btnBkShow_Go3ActionPerformed(java.awt.event.ActionEvent evt) {
try {
p("1");
Connection con = getDbConnObj();
if (con == null) {
throw new Exception("OOPs... Connection Error, Check and Retry !");
}
Statement st = con.creat... | [
"public void issueBook() {\n\t\t JTextField callno = new JTextField();\r\n\t\t JTextField name = new JTextField();\r\n\t\t JTextField id = new JTextField(); \r\n\t\t JTextField contact = new JTextField(); \r\n\t\t Object[] issued = {\r\n\t\t\t\t \"Bookcallno:\",callno,\r\n\t\t\t\t \"Student ID:\",id,\r\n\t\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the log date. | public String getDate() {
return logDate;
} | [
"public java.lang.String getLogDate() {\n return logDate;\n }",
"public String getLogDate() {\n\t\treturn logDate;\n\t}",
"public java.util.Calendar getLogDate() {\n return logDate;\n }",
"public static String getLogDateFormat() {\n return ConfigurationHolder.getString(\"ocsp.log-da... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ Default exit sequence for state State1 | private void exitSequence_mainRegion_State1() {
nextStateIndex = 0;
stateVector[0] = State.$NullState$;
} | [
"private void exitSequence_main_region_Failed() {\n\t\tnextStateIndex = 0;\n\t\tstateVector[0] = State.$NullState$;\n\t}",
"private void exitSequence_mainRegion_State2() {\n\t\texitSequence_mainRegion_State2__region0();\n\t}",
"private void enterSequence_mainRegion_State1_default() {\n\t\tnextStateIndex = 0;\n\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Handle the onStart movies fragment | @Override
public void onStart() {
spiceManager.start(getActivity());
if( mMoviesAdapter.getCount() <= 0 ){
updateMovies(MovieContract.DEFAULT_PAGE);
}
super.onStart();
} | [
"@Override\n public void onVideoStarted() {\n }",
"public void onVideoStarted () {}",
"@Override\r\n public void onVideoStarted() {\n }",
"@Override\n public void onLoadMovie(Movie movie) {\n Log.i(TAG, \"onLoadMovie: loading videos for movie \" + movie);\n new Asy... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets temporary user object | public void setTemporaryUser(User user) {
this.temporaryUser = user;
} | [
"public void updateCurrentTrempitUser() {\n\n // create the trempituser object\n TrempitUser currentUser = new TrempitUser();\n currentUser.setFullName(Profile.getCurrentProfile().getName());\n currentUser.setId(Long.valueOf(Profile.getCurrentProfile().getId()));\n\n // update the... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
ceci est un constructeur permettant de convertir les elements xml en AudioBook | public AudioBook (Element xmlElement) throws Exception {
super(xmlElement);
this.setLanguage(xmlElement.getElementsByTagName("language").item(0).getTextContent());
this.setCategory(xmlElement.getElementsByTagName("category").item(0).getTextContent());
} | [
"public XmlConverter() {\n\t\tinit();\t\t\t\n\t}",
"public AudioBookImporter(){\n\t\t\n\t}",
"public XmlAdaptedMedicine() {}",
"@Override\n public void buildFromXml(Element element) {\n if ( ! (element.getSubpieces().size() == element.getSubelements().size()) ) {\n throw new RuntimeExcept... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
SEARCH /_search/gazetteSetups/:query > search for the gazetteSetup corresponding to the query. | @RequestMapping(value = "/_search/gazetteSetups/{query}",
method = RequestMethod.GET,
produces = MediaType.APPLICATION_JSON_VALUE)
@Timed
public List<GazetteSetup> searchGazetteSetups(@PathVariable String query) {
return StreamSupport
.stream(gazetteSetupSearchRepository.sear... | [
"private void searchFor(String query) {\n AnalyticsHelper.sendEvent(SCREEN_LABEL, \"Search\", \"\");\n Bundle args = new Bundle(1);\n if (query == null) {\n query = \"\";\n }\n args.putString(ARG_QUERY, query);\n mQuery = query;\n\n }",
"List<Bed> search(Str... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the material of this reference | public Material getMaterial() {
return this.material;
} | [
"public java.lang.String getMaterial() {\r\n return material;\r\n }",
"public String getMaterial() {\n return material;\n }",
"public Material getMaterial() {\n return material;\n }",
"public Material getMaterial()\n {\n if (materials.length == 0) return null;\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Sets the technology category id. | public void setTechnologyCategoryId(Integer technologyCategoryId) {
this.technologyCategoryId = technologyCategoryId;
} | [
"public void setIdCategory(Short idCategory) {\r\n this.idCategory = idCategory;\r\n }",
"public void setId(int id) {\n this.categoryid = id; // id is parameter in integer type\n }",
"public void setCatId(int value) {\n this.catId = value;\n }",
"public void setCategor... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__TransformationList__Group__1__Impl" $ANTLR start "rule__TransformationList__Group__2" ../fr.tpt.aadl.ramses.transformation.trc.xtext.ui/srcgen/fr/tpt/aadl/ramses/transformation/trc/xtext/ui/contentassist/antlr/internal/InternalTRC.g:1821:1: rule__TransformationList__Group__2 : rule__TransformationList... | public final void rule__TransformationList__Group__2() throws RecognitionException {
int stackSize = keepStackSize();
try {
// ../fr.tpt.aadl.ramses.transformation.trc.xtext.ui/src-gen/fr/tpt/aadl/ramses/transformation/trc/xtext/ui/contentassist/antlr/internal/InternalTRC.g:1... | [
"public final void rule__TransformationList__Group__1() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \n try {\n // ../fr.tpt.aadl.ramses.transformation.trc.xtext.ui/src-gen/fr/tpt/aadl/ramses/transformation/trc/xtext/ui/contentassist/antlr/internal/Int... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
post: value added to tree so as to preserve binary search tree | private SearchTreeNode<E> add(SearchTreeNode<E> root, E value) {
if (root == null) {
root = new SearchTreeNode<E>(value);
} else if (root.data.compareTo(value) > 0) {
root.left = add(root.left, value);
} else if (root.data.compareTo(value) < 0) {
root.right = ... | [
"private SearchTreeNode<E> add(SearchTreeNode<E> root, E value) {\n if (root == null) {\n root = new SearchTreeNode<>(value);\n } else if (root.data.compareTo(value) > 0) {\n root.left = add(root.left, value);\n } else if (root.data.compareTo(value) < 0) {\n roo... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method removes the realized information for the given requirement | @DELETE
@Path("/{requirementId}/realized")
@Produces(MediaType.APPLICATION_JSON)
@ApiOperation(value = "This method removes the realized information for the given requirement.")
@ApiResponses(value = {
@ApiResponse(code = HttpURLConnection.HTTP_OK, message = "Returns the ... | [
"void unsetRequired();",
"public void deleteDataRequirement(Field dReqToDelete);",
"void removeHas_certainty(Object oldHas_certainty);",
"public void clearMinRequired() {\n unlogChange(\"minRequired\");\n getJSONObject().remove(\"minRequired\");\n cacheRemoveValue(CacheKey.minRequired);\n }",
"voi... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Unit test that ensures that no exception is thrown when a valid ticket is created without error. | @Test
@Tag("unit")
@DisplayName("Creates a valid Ticket without an error.")
void successfullyCreatesValidTicket() {
assertDoesNotThrow(() -> new Ticket("", "", "", "", 0, 0, "2020-01-22"));
} | [
"@Test\n\tpublic void createTicketTest() {\n\t\tService.createTicket(new TicketCreation(), \"username\");\n\t\tMockito.verify(TicketDao, times(1)).createTicket(Mockito.any(TicketCreation.class), Mockito.anyString());\n\t}",
"@Test\n public void autoIDExceptionTest() {\n\n Assertions.assertDoesNotThrow((... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns an enumeration of the dependencies of this target. | public Enumeration getDependencies()
{
return dependencies.elements();
} | [
"EDependencies getDependencies();",
"public List<Dependency> getDependencies() {\n return dependencies;\n }",
"List<ArtifactDependency> getDependencies();",
"public int getDependencies() {\n // the only dependency that's interesting is a dependency on local variables\n return positionE... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns color of the card | public Color color(){
return PackedCard.color(this.nbCard);
} | [
"public String getCardColor(){\n\t\treturn this.color;\n\t}",
"public CardColor getColor() {\n return this.color;\n }",
"public ColorDevCard getColor() {\n return cardColor;\n }",
"public int getColor( )\r\n {\r\n return color;\r\n }",
"public static Card.Color color(int pkCar... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calls getNext on the generate operator inside the nested physical plan. Converts the generated tuple into the proper format, i.e, (key,indexedTuple(value)) | @Override
public Result getNext(Tuple t) throws ExecException {
Result inp = null;
Result res = null;
while (true) {
inp = processInput();
if (inp.returnStatus == POStatus.STATUS_EOP || inp.returnStatus == POStatus.STATUS_ERR)
break;
... | [
"public abstract Tuple getNextTuple();",
"public abstract tuple getNextTuple();",
"@Override\n public void nextTuple() {\n\n if(isDone()) return;\n\n if(isBatchEmit()){\n List<T> tuples = prepareBatch();\n collector.emit(new Values(tuples), UUID.randomUUID());\n }el... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
one time only buy one lemon($5), Input: [5,5,5,10,20] Output: true general solution: can suilable to all number money | public boolean lemonadeChange(int[] bills) {
if(bills.length==0 || bills[0]>5)
return false;
//Queue<Integer> cash = new PriorityQueue<>(Collections.reverseOrder());
List<Integer> cash = new ArrayList<>();
for(int i=0; i<bills.length;++i){
int change = bills[i]-5;
if(change == 0){
cash.add(bills[i]);
c... | [
"private static void singleBet(int number) {\n int[] newBet = {number};\n if (insideBet(newBet)) {\n bet = bet * 36;\n money = bet + money;\n }\n }",
"public boolean lemonadeChange(int[] bills) {\n if(bills.length == 0 || bills[0] != 5)return false;\n in... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
sortExpiryAscending //Helper method for sorting list based on their expiray (descending) | private void sortExpiryDescending() {
Collections.sort(mFenceArrayList, new Comparator<Fence>() {
@Override
public int compare(Fence f1, Fence f2) {
Long t1 = f1.getExpiaryTimeMilliSec();
Long t2 = f2.getExpiaryTimeMilliSec();
return t2.co... | [
"public void sortListByDate() {\n list.sort(compareDate);\n }",
"public ArrayList<Expense> sortByDate() {\n ArrayList<Expense> expenseSortDateList = new ArrayList<>();\n expenseSortDateList = this.expenseList;\n Comparator<Expense> comparator = Comparator.comparing(Expense::getDate)... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method will Insert new Phone Number Entry in table company.phone_number_info | public void addPhoneNumber(Address address)
{
Connection conn = null;
PreparedStatement stmt = null;
try
{
conn = ConnectionObj.getConnection();
stmt = conn.prepareStatement("INSERT INTO phone_number_info (`person_id`, `phone_number`, `created_date`) values (?, ?, curdate())");
... | [
"public void insertPhoneNumber(String pNum){\n ContentValues cv = new ContentValues();\n cv.put(USERS_PHONE_NUMBER, pNum);\n this.openWriteableDB();\n long rowId = db.insert(DATES_TABLE, null, cv);\n this.closeDB();\n }",
"public void doInsertPhone() {\n\n if (validIBA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This accessor method returns the Account clientFunds static field. | public double getClientFunds() {
return clientFunds;
} | [
"public ArrayList<ClientModel> getClientsBudget() {\n\t\t\n\t\treturn clients;\n\t}",
"java.util.List<cosmos.base.v1beta1.CoinOuterClass.Coin> \n getFundsList();",
"public List<FundInWallet> getFunds() {\n\t\treturn funds;\t\t\t\n\t}",
"@java.lang.Override\n public java.util.List<? extends cosmos.ba... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
/ This is searching for any Firebat Units in the specified List and returns the ones that are found in a List. If none is found it simply returns the first Unit in the List as a List. check if the given list contains any Units | protected List<Unit> getFirebats(List<Unit> units)
{
if (units.isEmpty())
return units;
List<Unit> firebats = new LinkedList<Unit>();
for (Unit u : units)
{
// check if Type is Firebat if so add it to the List
if (u.getType() == UnitType.Terran_Firebat)
firebats.add(u);
}
/... | [
"public List<Unit> getAllUnits(){\r\n \tList<Unit> allUnits = new ArrayList<Unit>();\r\n \tfor(java.util.Map.Entry<String, Faction> key : factions.entrySet()) {\r\n \t\tallUnits.add((Unit)factions.get(key).getAllUnitsFromFaction());\r\n \t}\r\n \tassert allUnits.size() == getNbOfUnits();\r\n \tret... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
dado un usuario, selecciona los roles que ya le han sido asignados | public List<RolXUsuario> rolesAsignados(int offset, int limit, String usuarioId); | [
"public void seteoRolesSeleccionados(){\r\n\r\n for (int i = 0; i < selectedRoles.size(); i++) { //lista de roles seleccionado es un String\r\n addRolUser(selectedRoles.get(i));\r\n }\r\n selectedRoles.clear();//luego de agregados los roles a la lista de usuarios borro los datos\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns a range of all the categories. Useful when paginating results. Returns a maximum of end start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtilALL_POS will return the full result set. If order... | @Override
public List<Category> findAll(int start, int end) {
return findAll(start, end, null);
} | [
"@Override\n\tpublic List<Category> findAll(\n\t\tint start, int end, OrderByComparator<Category> orderByComparator) {\n\n\t\treturn findAll(start, end, orderByComparator, true);\n\t}",
"@Override\n\tpublic List<Category> findAll(\n\t\tint start, int end, OrderByComparator<Category> orderByComparator,\n\t\tboolea... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
This method was generated by MyBatis Generator. This method corresponds to the database table session_ssl_status | public SessionSslStatusExample() {
oredCriteria = new ArrayList<Criteria>();
} | [
"SessionStatus getStatus();",
"protected String getSessionVariableForSslVersion() {\n final String sslVersion = \"Ssl_version\";\n LOGGER.debug(\"Reading MySQL Session variable for Ssl Version\");\n Map<String, String> sessionVariables =\n querySystemVariables(SQL_SHOW_SESSION_... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
ActivityFactory. create activities with the given place | public interface ActivityFactory {
HelloActivity helloActivity(final BasePlace place);
GoodbyeActivity goodbyeActivity(final BasePlace place);
} | [
"Activities createActivities();",
"Activity createActivity();",
"void create(SportActivity activity);",
"public SportActivity createSportActivity(SportActivity sportActivity);",
"ActivityToActivity createActivityToActivity();",
"AbstractActivity createAbstractActivity();",
"ActivityConcept createActivit... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Registering twice the same default rule set results in no addition | @Test
public void testDuplicateRegisterDefault() {
final RuleSet ruleSet = createEmptyTestRuleSet();
this.ruleSetManager.registerDefaultRuleSet(ruleSet);
this.ruleSetManager.registerDefaultRuleSet(ruleSet);
Assert.assertEquals("Only one rule set should have been registered", 1,
... | [
"@Test\n public void testDuplicateUnregisterDefault() {\n final RuleSet ruleSet = createEmptyTestRuleSet();\n this.ruleSetManager.registerRuleSet(ruleSet);\n\n this.ruleSetManager.unregisterDefaultRuleSet(ruleSet);\n this.ruleSetManager.unregisterDefaultRuleSet(ruleSet);\n Asse... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Computes reference to new file with new rotate number, because old file was filled. | private File getRotationFile(File file){
System.out.println("Начата ротация: ");
File parent = file.getParentFile();
File ret;
String withoutExtension = getWithoutExtension(file.getName());
String extension = getExtension(file.getName());
if (isContainsC... | [
"private synchronized void updateFilename()\n\t{\n\t\tCalendar cal = Calendar.getInstance();\n\t\tDate date = cal.getTime();\n\n\t\tcal.add(Calendar.DATE, 1);\n\t\tcal.set(Calendar.HOUR_OF_DAY, 0);\n\t\tcal.set(Calendar.MINUTE , 0);\n\t\tcal.set(Calendar.SECOND, 0);\n\n\t\tfilename = prefix + dateFormat.format(date... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check if the given word is a SPELL modifier | protected boolean isModifier(String word)
{
return m_listModifiers.contains(word);
} | [
"protected boolean isModifier( String word )\r\n\t{\r\n\t\treturn m_listModifiers.contains(word);\r\n\t}",
"private boolean isWord(String word) {\n\t\treturn dict.isWord(word);\n\t}",
"boolean isWord(String potentialWord);",
"private boolean canSpellWord(String letters, String word) {\n\n // if the len... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleMorphiaModel" $ANTLR start "entryRuleAttribute" InternalPlayMorphiaModel.g:301:1: entryRuleAttribute returns [EObject current=null] : iv_ruleAttribute= ruleAttribute EOF ; | public final EObject entryRuleAttribute() throws RecognitionException {
EObject current = null;
EObject iv_ruleAttribute = null;
try {
// InternalPlayMorphiaModel.g:301:50: (iv_ruleAttribute= ruleAttribute EOF )
// InternalPlayMorphiaModel.g:302:2: iv_ruleAttribute= ru... | [
"public final EObject entryRuleAttribute() throws RecognitionException {\n EObject current = null;\n\n EObject iv_ruleAttribute = null;\n\n\n try {\n // InternalDotLanguage.g:490:50: (iv_ruleAttribute= ruleAttribute EOF )\n // InternalDotLanguage.g:491:2: iv_ruleAttribute=... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the node_2 of this dictionary data. | @Override
public java.lang.String getNode_2() {
return _dictData.getNode_2();
} | [
"public Node getNode2(){\n\t\treturn node2;\n\t}",
"public Node getNode2() {\n return node2;\n }",
"public AbstractNode getNode2() {\n\t\treturn this.node2;\n\t}",
"public Node getNode2() {\n\t\tif (this.n2 == null)\n\t\t\tSystem.out.println(\"NODE 2 IS NULLL!!!!!!\");\n\t\treturn this.n2;\n\t}",
... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Quote any characters in s that are not permitted by the given mask pair | private static String quote(String s,long lowMask,long highMask){
int n=s.length();
StringBuffer sb=null;
boolean allowNonASCII=((lowMask&L_ESCAPED)!=0);
for(int i=0;i<s.length();i++){
char c=s.charAt(i);
if(c<'\u0080'){
if(!match(c,lowMask,highMas... | [
"private String filterInvalidChars(String raw) {\n int lraw = raw.length();\n StringBuffer sb = new StringBuffer(lraw);\n char ch;\n for (int i = 0; i < lraw; i++) {\n switch ((ch = raw.charAt(i))) {\n case ' ' :\n sb.append('_');\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
returns color in an array of three ints: R, G, and B | public int[] getColor() {
int[] retVal = new int[3];
retVal[0] = r;
retVal[1] = g;
retVal[2] = b;
return retVal;
} | [
"public int[] getColor() {\n\n int[] retVal = new int[3];\n retVal[0] = r;\n retVal[1] = g;\n retVal[2] = b;\n\n return retVal;\n }",
"int[] getPossibleColors();",
"public Color[] getColors();",
"public int[] getColorIndices();",
"public static int[] getPixelData(int ar... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "ruleDependency" $ANTLR start "entryRuleBaseBinaryDependency" ../assignment6_configurator_DSL/srcgen/org/xtext/example/assignment6/parser/antlr/internal/InternalConfiguratorDSL.g:984:1: entryRuleBaseBinaryDependency returns [EObject current=null] : iv_ruleBaseBinaryDependency= ruleBaseBinaryDependency EOF ; | public final EObject entryRuleBaseBinaryDependency() throws RecognitionException {
EObject current = null;
EObject iv_ruleBaseBinaryDependency = null;
try {
// ../assignment6_configurator_DSL/src-gen/org/xtext/example/assignment6/parser/antlr/internal/InternalConfiguratorDSL.g:985... | [
"public final EObject entryRuleBinaryDependency() throws RecognitionException {\n EObject current = null;\n\n EObject iv_ruleBinaryDependency = null;\n\n\n try {\n // ../assignment6_configurator_DSL/src-gen/org/xtext/example/assignment6/parser/antlr/internal/InternalConfiguratorDSL.g... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Called when AxisProxy bounds may have changed. | protected void resetAxisProxyBounds()
{
_axisBoxPainter.configureAxisProxyForAxis(_axisProxyX, AxisType.X);
_axisBoxPainter.configureAxisProxyForAxis(_axisProxyY, AxisType.Y);
_axisBoxPainter.configureAxisProxyForAxis(_axisProxyZ, AxisType.Z);
} | [
"public void bindBounds() {\n\n if(app.settings().isPlotBoundsComputed()) {\n computeBounds();\n }\n\n xAxis.setLowerBound(xMin);\n xAxis.setUpperBound(xMax);\n yAxis.setLowerBound(yMin);\n yAxis.setUpperBound(yMax);\n\n }",
"public void updateBounds() {\n\t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Gets the value of the 'field228' field | public java.lang.CharSequence getField228() {
return field228;
} | [
"public java.lang.CharSequence getField228() {\n return field228;\n }",
"public java.lang.CharSequence getField229() {\n return field229;\n }",
"java.lang.String getField1538();",
"public java.lang.CharSequence getField248() {\n return field248;\n }",
"public java.lang.CharSequence getField229()... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Adds a path with the specified label which ends at the specified Node. DOES NOT add a path if one with the same label already exists | public boolean addPath(L label, N node) {return paths.putIfAbsent(label, node) == null;} | [
"public N pathEnd(L label) {return paths.get(label);}",
"public INode addOrGetNode(String label);",
"public void replacePath(L oldLabel, L newLabel) {paths.put(newLabel, paths.remove(oldLabel));}",
"void addPath(Path p);",
"public static HW8.Path getPathWithEnd(int node, List<HW8.Path> paths) {\r\n f... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The service loader is used to loader which is defined in spring context | public interface ISpringServiceLoader extends IServiceLoader {
String NAME = "Spring";
} | [
"SpringLoader getSpringLoader();",
"void setSpringLoader(final SpringLoader springLoader);",
"public ContainerLoader getLoader();",
"private void setupLoader() {\n if (classpath != null && loader == null) {\n loader = getProject().createClassLoader(classpath);\n loader.setThrea... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calls method report if a certain amount of time specified by reportingIntervall in milliseconds has passed since the last reporting. | public void reportIfNeeded() {
if (lastReport == null || new Date().getTime() - lastReport.getTimestamp() > reportingIntervall) {
report();
}
} | [
"int getReportTime();",
"public void maybeReportExecutionTooSlow(long now, List<ExecutionTask> tasksToReport) {\n if (!_slowExecutionReported && (_state == ExecutionTaskState.IN_PROGRESS || _state == ExecutionTaskState.ABORTING) && now > _alertTimeMs) {\n tasksToReport.add(this);\n // Mute the task t... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Set delayed activation of flagged window until focusedWindow is available and equals trigger frame. | private void setDelayedActivation(Window flagActivateWindow, JInternalFrame flagActivateInternalFrame,
Window activateTriggerFrame)
{
this.flagActivateWindow = flagActivateWindow;
this.flagActivateInternalFrame = flagActivateInternalFrame;
this.activateTriggerFrame... | [
"public void windowFocus(boolean focused);",
"public void showWindow() {\n setVisible(true);\n toFront();\n \n if (UITools.isRunningOnKDE()) {\n new FocusWindowInKdeThread().start();\n }\n }",
"private void doSetFocus() {\n Timer focusTimer = new Timer(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Test the RNASeq differential gene expression example under normal circumstances. | @Test
public void testRnaSeqDgeExampleNormal() {
final RnaSeqDgeExample example = Guice.createInjector(new TestGuiceModule()).getInstance(RnaSeqDgeExample.class);
addDummyOutput(example.workflowFactory, 7);
assertTrue(example.runExample(Constants.THE_HYVE_GALAXY_URL));
} | [
"@Test\n public void testRnaSeqDgeExampleReturningFalse() {\n final RnaSeqDgeExample example = Guice.createInjector(new TestGuiceModule()).getInstance(RnaSeqDgeExample.class);\n addDummyOutput(example.workflowFactory, 0);\n DummyWorkflow.setReturnedResult(false);\n assertFalse(example... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Performs onthefly validation of the form field 'licenseServerPath'. | public void doCheckLicenseServerPath(StaplerRequest req, StaplerResponse rsp, @QueryParameter final String value) throws IOException, ServletException {
new FormFieldValidator(req,rsp,null) {
/**
* The real check goes here. In the end, depending on which
* m... | [
"public FormValidation doCheckServerUrl(@QueryParameter String serverUrl) {\n return FormValidation.validateRequired(serverUrl);\n }",
"boolean isAgencyLogoPathValid() {\n boolean valid = true;\n\n if (defaultLogoRB.isSelected()) {\n agencyLogoPathFieldValidationLabel.se... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Check if SQLite database is running in native mode or purejava | public static boolean isNativeMode() {
return SQLiteJDBCLoader.isNativeMode();
} | [
"public static boolean isNativeMode() throws Exception {\n // load the driver\n initialize();\n return extracted;\n }",
"boolean supports(Database database);",
"private Boolean checkForLegacyDb() {\n return mContext.getDatabasePath(DATABASE_NAME).exists();\n }",
"public boole... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Takes current estimation (local function) and the actual measurement and adapts the local parameters accordingly. | public abstract void adapt( Statistic<Data> measurement ); | [
"protected abstract void calibrate(double currentValue);",
"public interface ILocalFitParams {\n \n public void setY(double[] y);\n \n public double[] getY();\n \n public void setSig(double[] sig);\n \n public double[] getSig();\n \n public void setParams(double[] params);\n \n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
String sql = "select m.id, m.datemaintence,m.expiratedate, m.description from maintence m, equipment e where m.equip_id = e.id" + " and e.id = ? and m.datemaintence = (SELECT MAX(expiratedate) from maintence where maintence.id = m.id)"; | public Maintenance recoveryMaintenanceOfEquip(Equipment equip) {
String sql = "select m.id, m.datemaintence,m.expiratedate, m.description from maintence m, equipment e "
+ " where m.equip_id = e.id and e.id = ? order by m.datemaintence DESC limit 1 ";
System.out.println(sql);
try {
ResultSet rs = dat... | [
"@Query(\"select max(date) from AccessHistoryItem where ip=?1\")\n LocalDateTime findMaxDateByIp(String ip);",
"public List getForLastMonthsummery(Date date,String sid,String wid) {String qry=\"select i ,sum(l.qty) \"\n// + \" from InventoryJournal c join c.lines l join l.item i \"\n// ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Retrieve user by mail | @SuppressWarnings("Duplicates")
public User findByMail(String mail){
DataSource dataSource = new DataSource();
try{
PreparedStatement statement = dataSource.getConnection().prepareStatement("SELECT * FROM users WHERE users.mail = ?;");
statement.setString(1, mail);
... | [
"public User getUser(String email){\r\n\t\treturn map.get(email);\r\n\t}",
"public User findByDriver(String mail);",
"User find(String email);",
"String getUserIdByEmail(String email);",
"User findUserByEmail(String email) throws Exception;",
"public UserProfile getByEmail(String email);",
"CmUser findB... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
method getSilicateMax Return the 'silicateMax' class variable as a String | public String getSilicateMax(String s) {
return ((silicateMax != FLOATNULL) ? new Float(silicateMax).toString() : "");
} | [
"public float getSilicateMax() {\n return silicateMax;\n }",
"java.lang.String getMaxValue();",
"java.lang.String getRetMax();",
"java.lang.String getQualityMax();",
"public String getNitrateMax(String s) {\n return ((nitrateMax != FLOATNULL) ? new Float(nitrateMax).toString() : \"\");\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
End class. A description of the supported maze file types. | @Override
public String getFileTypeDescription()
{
return "Maze files (.maz, .mz2)";
} | [
"FileType getType();",
"public void setFileTypes(int types) { fileTypes = types; }",
"public int getFileTypes() { return fileTypes; }",
"String getDefaultFiletype();",
"HashMap<String, ArrayList<String>> getSupportedFiletypes();",
"public static HashMap<String, String> getMimeTypes() {\r\n if (mime... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Creates a new X837Pro_2010BB_N4_PayerCityStateZIPCode RecordBuilder | public static net.explorys.samhat.z12.r837.X837Pro_2010BB_N4_PayerCityStateZIPCode.Builder newBuilder() {
return new net.explorys.samhat.z12.r837.X837Pro_2010BB_N4_PayerCityStateZIPCode.Builder();
} | [
"public static net.explorys.samhat.z12.r837.X837Pro_2010BB_N4_PayerCityStateZIPCode.Builder newBuilder(net.explorys.samhat.z12.r837.X837Pro_2010BB_N4_PayerCityStateZIPCode other) {\n return new net.explorys.samhat.z12.r837.X837Pro_2010BB_N4_PayerCityStateZIPCode.Builder(other);\n }",
"public net.explorys.samh... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Tests the creation of new vectors | @Test
public void newVectorTest() {
for (int x = -10; x<10; x++) {
for (int y = -10; y<10; y++) {
Vector v = new Vector(x,y);
Vector v2 = new Vector(v);
v2.add(v);
v2 = v2.add(v);
v2 = v2.add(v2);
assertTrue(v.equals(new Vector(x,y)));
assertTrue(v2.equals(v.add(v).add(v).add... | [
"public void testGetVectorFactory()\n {\n this.testSetVectorFactory();\n }",
"@Test\r\n public void testAddVector() throws Exception {\r\n System.out.println(\"AddVector\");\r\n int[] T = {1,2,3};\r\n int []T2 = {4,5,6};\r\n VectorHelper instance = new VectorHelper();\r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Centers the passed integer in the passed space. | static public String center(int intIn, int len)
{
String str = String.valueOf(intIn);
return center(str, len);
} | [
"void center(int areaWidth, int areaHeight);",
"public void addCenter(int i){\n\tsynchroCenters.add(new Integer(i));\n }",
"void placeCenter(int x, int y) {\n placeCenter(pl(x, y));\n }",
"public void centerOnEntity(Entity entity){\r\n\t\txOffset = entity.getX() - game.getWidth() / 2 + entity.get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
methods to back to Spinner model Returns the current year of the monthView. Callback for spinner model. return the current year of the monthView. | private int getYear() {
Calendar cal = monthView.getCalendar();
return cal.get(Calendar.YEAR);
} | [
"private int getSelectedYear() {\n return selectedYear;\n }",
"private static void getCurrentMonthYear() {\n\n Calendar cal = Calendar.getInstance();\n currentMonth = cal.get(Calendar.MONTH) + 1;\n currentYear = cal.get(Calendar.YEAR);\n }",
"public YearMonth getYearMonth() {\n... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Calculate Efficiency of team member by current work done and expected work done . | private String calculateEfficiencyStatus(BigDecimal projectId) {
log.debug("calculateEfficiencyStatus.START");
LanguageDao languageDao = new LanguageDao();
ModuleDao moduleDao = new ModuleDao();
List<Module> modules = moduleDao.getModuleByProject(projectId);
TaskDao taskDao ... | [
"private void calculateBaseVacationByWorkedHours() {\n // ...\n }",
"Efficiency getWinterEfficiency();",
"double calculateCost() {\n double cost = 0;\n InspectionDTO[] DTOArray = this.currentInspectionChecklist.inspectionDTOArray;\n for (int i = 0; i <= DTOArray.length - 1; i++) {... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the sync client or not. | public Boolean getIsSync()
{
return isSync;
} | [
"boolean getIsSync();",
"public java.lang.Boolean getIsClient()\n {\n return isClient;\n }",
"public boolean isClient() {\n return client;\n }",
"public ISynchronizeClient getSynchronizeClient() {\r\n\t\treturn mySynchronizeClient;\r\n\t}",
"boolean getIsLocalClient();",
"public boolean get... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Container's getter for ExternalUserOrganizationVo1. | public ViewObjectImpl getExternalUserOrganizationVo1() {
return (ViewObjectImpl)findViewObject("ExternalUserOrganizationVo1");
} | [
"public ViewObjectImpl getExternalUserVO1() {\n return (ViewObjectImpl)findViewObject(\"ExternalUserVO1\");\n }",
"public ViewObjectImpl getcontractNumberOrganizationVO1() {\n return (ViewObjectImpl)findViewObject(\"contractNumberOrganizationVO1\");\n }",
"public java.lang.String getOrganiza... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Show the standard error message for when a thing is null and should not be. | public static void errorNull(CommandSender sender, String thingDescription, String thingId) {
sender.sendMessage(ChatColor.RED + "There is no " + thingDescription + " named \"" + thingId + "\"!");
} | [
"@Override\n public void printErrorMessage() {\n AthenaUi athenaUi = new AthenaUi();\n athenaUi.printEmptyTaskListException();\n }",
"public static void errorEmptyInput() {\n System.out.print(RED + \"\\tSorry, your field empty :( \" + RESET);\n }",
"public static void errorNotNull(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Checks for default values. | public void checkDefaults() {
Iterator types = getIteratorListOfSecondChild( "defaults" );
while( types.hasNext() ) {
Element type = ( Element )types.next();
String id = type.getAttributeValue( "id" );
String value = type.getAttributeValue( "value" );
... | [
"public boolean hasDefaultValues()\r\n\t{\r\n\t\tif (stepName != null)\r\n\t\t\treturn false;\r\n\r\n\t\tif (stepDisplayName != null)\r\n\t\t\treturn false;\r\n\r\n\t\tif (stepDescription != null)\r\n\t\t\treturn false;\r\n\r\n\t\tif (roleId != null)\r\n\t\t\treturn false;\r\n\r\n\t\tif (userId != null)\r\n\t\t\tre... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Stores both the Representation and the Metadata of the parsed Entity to the parsed yard. This Method also updated the modification date of the Metadata. | private void storeEntity(Yard entityhubYard, Entity entity) throws YardException{
if(entity != null){
entityhubYard.store(entity.getRepresentation());
entity.getMetadata().set(NamespaceEnum.dcTerms+"modified", new Date());
entityhubYard.store(entity.getMetadata());
}
... | [
"void saveMetaData() {\n\t\tlogger.info(\"Saving MetaData to disk\");\n\t\tJStickies.saveFile(metaDataFile, this);\n\t}",
"@objid (\"002e1c6a-ead5-106a-bf4f-001ec947cd2a\")\n public void save() {\n CatalogWriter catalogWriter = new CatalogWriter();\n try {\n catalogWriter.writeCatalog(... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get list of project by type, delivery unit | public List<ProjectDTO> getProjectListByType(String duName, String projectType, int month, int year); | [
"List<Project> getProjectList();",
"Set<Project> getProjects(Long testplanID);",
"String getProjectTypeId();",
"List<DeliveryType> findAll();",
"private ProjectItemDaoJpa getProjectItemDao(String type) {\n switch (type) {\n case \"task\":\n case \"task_content\":\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Get the chunk input stream for the given key in the given Infinispan CacheStore | public StoreChunkInputStream(final CacheStore blobCache, final String key) {
logger = Logger.getLogger(getClass());
this.blobCache = blobCache;
this.key = key;
} | [
"public synchronized InputStream read(BigInteger key, BigInteger id) throws IOException {\r\n\t\t\r\n\t\tMap<BigInteger, StoreEntry> store = trans.get(key);\r\n\t\tif(store == null)\r\n\t\t\tthrow new IOException(\"The store does't exist (\"+key.toString()+\").\");\r\n\t\t\r\n\t\tStoreEntry entry = store.get(id);\r... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Called to determine whether the given line of text is a "tshout" and to further process it if it is. | private boolean handleTShout(String line){
if (line.indexOf("t-shouts: ") == -1)
return false;
Matcher matcher = TSHOUT_REGEX.matcher(line);
if (!matcher.matches())
return false;
String username = matcher.group(1);
String titles = matcher.group(2);
String message = matcher.grou... | [
"private boolean handleShout(String line){\n if (line.indexOf(\"shouts: \") == -1)\n return false;\n \n Matcher matcher = SHOUT_REGEX.matcher(line);\n if (!matcher.matches())\n return false;\n\n String username = matcher.group(1);\n String titles = matcher.group(2);\n String message =... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Getter for payment reference. | public String getPaymentReference() {
return paymentReference;
} | [
"public java.lang.String getPaymentRef() {\n return paymentRef;\n }",
"public java.lang.String getPaymentRef() {\n return paymentRef;\n }",
"public java.lang.String getPaymentRefNo()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.S... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns an observable which converts all messages to an Option value. The returned observable terminates once error or finish is received. Its dual is the dematerialize method. Note, before 0.97, this materialize sequence never terminated, but consulting with Rx, I changed its behavior to terminating. For unterminating... | @Nonnull
public static <T> Observable<Option<T>> materialize(
@Nonnull final Observable<? extends T> source) {
return new Observable<Option<T>>() {
@Override
@Nonnull
public Closeable register(@Nonnull final Observer<? super Option<T>> observer) {
return source.register(new Observer<T>() {
... | [
"@Nonnull\r\n\tpublic static <T> Observable<T> dematerialize(\r\n\t\t\t@Nonnull final Observable<? extends Option<T>> source) {\r\n\t\treturn new Observable<T>() {\r\n\t\t\t@Override\r\n\t\t\t@Nonnull \r\n\t\t\tpublic Closeable register(@Nonnull final Observer<? super T> observer) {\r\n\t\t\t\treturn source.registe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Open gallary to pick image | private void openGallary() {
Intent gallary = new Intent(Intent.ACTION_PICK, MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
startActivityForResult(gallary, PICK_IMAGE);
} | [
"private void pickImage() {\n\t\ttheImageFile = OpenOrSave.open();\n\t\tif (theImageFile != null) {\n\t\t\tString theFileName = theImageFile.getName();\n\t\t\ttheImagePath.setText(theFileName);\n\t\t\tgoButton.setEnabled(true);\n\t\t}\n\t}",
"public void openImage() {\n\t\tJFileChooser fileChooser = getImageChoos... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Removes the e s f order where code = &63; from the database. | @Override
public ESFOrder removeByCode(String code)
throws NoSuchOrderException, SystemException {
ESFOrder esfOrder = findByCode(code);
return remove(esfOrder);
} | [
"public void removeBycode(String code);",
"@Transactional\n public void removeByCode(final String code) {\n// final Query query = new Query().setFilter(new PropertyFilter(Verifycode.CODE, FilterOperator.EQUAL, code));\n try {\n final List<Verifycode> results = verifycodeMapper.getByCod... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the help bubble close CSS class name. | String helpBubbleClose(); | [
"String helpMessageIcon();",
"public java.lang.String getCLOSE_ICON_TEXT() {\r\n return CLOSE_ICON_TEXT;\r\n }",
"public java.lang.String getCLOSE_ICON() {\r\n return CLOSE_ICON;\r\n }",
"public java.lang.String getHELP_ICON() {\r\n return HELP_ICON;\r\n }",
"public String getH... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Metodo de Editar Datos del Empleado. | private void editar(){
EmpleadoLogica cl = new EmpleadoLogica();
cl.setIdempleado(this.jFTFCodigo.getText());
cl.setNombre(this.jTFNombre.getText());
cl.setApellido(this.jTFApellido.getText());
cl.setTelefono(this.jFTFTelefono.getText());
cl.setDireccion(this.jTADireccion... | [
"public void editar() {\n try {\n ClienteDao fdao = new ClienteDao();\n fdao.Atualizar(cliente);\n\n JSFUtil.AdicionarMensagemSucesso(\"Cliente editado com sucesso!\");\n\n } catch (RuntimeException e) {\n JSFUtil.AdicionarMensagemErro(\"ex.getMessage()\");\... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Fonction pour run avec une liste d'expression, ecris une trace de debug en console, et le resultat dans un fichier | public static void run (List<Exp_asml> list_asmt,PrintStream arm_file, boolean debug)
{
PrintStream debug_out=System.out;
bigInts = new ArrayList<Label_Int>();
int size = list_asmt.size();
if(debug){
debug_out.println("###################");
debug_out.println("Arbre ASML en entrée");
for(int i=0;i<siz... | [
"public void printExpressions() {\r\n }",
"public static void printWhoPrintsToSTDErr(Runnable r){\n\t\t try(FilterSession fs = ConsoleFilterPlugin.getStdErrOutputFilter().newFilter(Filters.filterOutAllClasses(\".*\")).withOnSwallowed(c->{\n \tConsoleFilterPlugin.stdOut().println(\"Logging STDErr:\" + c... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__Ceffective__Group__1" $ANTLR start "rule__Ceffective__Group__1__Impl" InternalCeffective.g:726:1: rule__Ceffective__Group__1__Impl : ( 'Ceffective' ) ; | public final void rule__Ceffective__Group__1__Impl() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalCeffective.g:730:1: ( ( 'Ceffective' ) )
// InternalCeffective.g:731:1: ( 'Ceffective' )
{
// InternalCeffecti... | [
"public final void rule__Ceffective__Group__0() throws RecognitionException {\n\n \t\tint stackSize = keepStackSize();\n \t\n try {\n // InternalCeffective.g:691:1: ( rule__Ceffective__Group__0__Impl rule__Ceffective__Group__1 )\n // InternalCeffective.g:692:2: rule__Ceffe... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Constructor override for the second task. When supplied and keyword and a pagenumber will do an initial run of methods in order to print a series of results to the screen. | public MainProg(String keyword, String pagenumber){
this.setKeyword(keyword);
this.setPagenumber(pagenumber);
this.createURL();
this.getRedirectURL();
this.getPageURL();
results = this.getPageInfo(this.getSearchDocument());
this.printOutResults();
} | [
"public ParallelScanner(int nthreads){\r\n\t\t_numberThreads = nthreads;\r\n\t}",
"public PagedResult() {\r\n // Empty\r\n }",
"public PageCrawler() {\n this(new CrawlSettings());\n }",
"public void startSearch() {\r\n\r\n\t\tList<Page> pagesList = new LinkedList<Page>();\r\n\r\n\t\tpagesList = ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
this method is used to log out from the facebook login | public static void logoutFacebook()
{
APP_LOGS.debug("facebook user Log out by the logoutFacebook method");
getlinktextobject("MY_ACCOUNT_LINK").click();
APP_LOGS.debug("My Account link clicked");
driver.findElement(By.cssSelector("#f_logout > img")).click();
try {
Thread.sleep(3000);
} catch (In... | [
"public void logoutUserFacebook() {\r\n\t\t// Clearing all data from Shared Preferences\r\n\t\teditor.putBoolean(IS_LOGINFACEBOOK, false);\r\n\t\teditor.putString(KEY_EMAIL, \"\");\r\n\t\teditor.putString(KEY_ID_USER_FRIKIADOS, \"\");\r\n\t\teditor.putString(KEY_FB_USER_ID, \"\");\r\n\t\teditor.putString(KEY_NICKNA... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
Returns the function type of this history interface request field. | @Override
public java.lang.String getFunctionType() {
return _historyInterfaceRequestField.getFunctionType();
} | [
"public FunctionType getType();",
"public String getFunType() {\r\n return funType;\r\n }",
"@Override\n\tpublic void setFunctionType(java.lang.String functionType) {\n\t\t_historyInterfaceRequestField.setFunctionType(functionType);\n\t}",
"public char getFunctionType() {\r\n return functionT... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
The default constructor is being set to private so that no Tester instances can be created. | private Tester() {
} | [
"public SwerveAutoTest() {\n // Initialize base classes.\n // All via self-construction.\n\n // Initialize class members.\n // All via self-construction.\n }",
"public tester() {\r\n }",
"public CompteurInstanceTest()\n {\n }",
"public TestManager() {\n }",
"protec... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
$ANTLR end "rule__SendSignal__Group__2__Impl" $ANTLR start "rule__SendSignal__Group__3" InternalDroneScript.g:4685:1: rule__SendSignal__Group__3 : rule__SendSignal__Group__3__Impl ; | public final void rule__SendSignal__Group__3() throws RecognitionException {
int stackSize = keepStackSize();
try {
// InternalDroneScript.g:4689:1: ( rule__SendSignal__Group__3__Impl )
// InternalDroneScript.g:4690:2: rule__SendSignal__Group__3__Impl
... | [
"public final void rule__SendStmt__Group__3() throws RecognitionException {\r\n\r\n \t\tint stackSize = keepStackSize();\r\n \t\r\n try {\r\n // InternalGo.g:9698:1: ( rule__SendStmt__Group__3__Impl )\r\n // InternalGo.g:9699:2: rule__SendStmt__Group__3__Impl\r\n ... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |
precondition: 0 <= index < 7 postcondition: Returns true if the given card can be legally moved to the top of the given pile param card the card for which adding it to the pile will be determined param index the pile number selected | private boolean canAddToPile(Card card, int index)
{
if(card!=null && !getPile(index).isEmpty())
{
Card pile=getPile(index).peek();
if(pile.isFaceUp() && card.getRank()+1==pile.getRank())
{
if(pile.getSuit().equals("h") || pile.getSuit().equals("d"... | [
"private void addToPile(Stack<Card> cards, int index)\n {\n for(int i=0; i<cards.size(); i++)\n {\n if(!cards.isEmpty())\n {\n getPile(index).push(cards.pop());\n i--;\n }\n }\n }",
"private boolean checkPile(List<Card> card... | {
"objective": {
"paired": [],
"self": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} |